MCNP Guide
Running MCNP and Understanding Output
How to find k-effective, read a tally block, and recognise a failed run
What you'll learn
- Navigate an output file by print table number, and turn tables on or off from the input deck.
- Find the final combined k-effective and say which estimators went into it.
- Read a tally block as energy bin bound, mean, and relative error, and confirm the volume used for an
f4. - Recognise the common failure signatures: lost particles, zero tallies, high relative error, and missing cross sections.
Before you start
What the output file is
A finished run leaves a text output file whose path you named with o=. That file is the primary record: version and library banner, a problem summary, every print table you asked for, the tally blocks, the statistical checks, and any warnings MCNP decided to keep. Machine-readable companions — MCTAL for tallies, MESHTAL for mesh tallies, PTRAC for tracks, RUNTPE for a restart — sit beside it when you request them. This page is about reading the text file.
The command line that produces it is covered on Running MCNP; the short form is enough here. o= names the output file. n= is a filename prefix — MCNP appends o, r, and m to it — not a second spelling of o=. tasks sets the thread count, ip opens the interactive plotter, and c continues from a RUNTPE.
# Basic run
mcnp6 i=input o=output
# Interactive plotter
mcnp6 ip i=input
# Multiple tasks
mcnp6 i=input o=output tasks 4
# Continue run
mcnp6 c i=input o=output2 r=runtpeThe header names the code version, the input file, the history count, the random-number seed, and which cross-section tables the run actually loaded. The library line is worth a glance before you dig into results: it is where a mismatched suffix first shows up.
Code Name & Version = MCNP6, 1.0
_/ _/ _/_/_/ _/ _/ _/_/_/
_/_/ _/_/ _/ _/_/ _/ _/ _/
_/ _/ _/ _/ _/ _/ _/ _/_/_/
_/ _/ _/ _/ _/_/ _/
_/ _/ _/_/_/ _/ _/ _/
Input File: example_input
Number of histories: 1000000
Random number generator seed: 19073486523876
Cross-section tables: .80c from ENDF/B-VII.1Print table 60 is the problem summary: each cell with its material, densities, volume, mass, and importance. When an f4 volume looks wrong later, this table is the first place to check whether MCNP computed a volume you did not expect.
1cells and surfaces print table 60
cell mat atom density gram density volume mass pieces importance
1 1 1 4.79853E-02 1.12000E+00 1.00000E+03 1.12000E+03 1 1.0000E+00
2 2 2 1.00309E-01 1.00000E+00 2.00000E+03 2.00000E+03 1 1.0000E+00
3 3 0 0.00000E+00 0.00000E+00 0.00000E+00 0.00000E+00 0 0.0000E+00Tables are numbered. The ones you reach for most often are 60 (problem summary), 110 (cross-section table summary), 126 and 128 (activity), 130 (tally bins), and 160 (TFC bin summary). A PRINT card in the data section turns individual tables on or off — positive numbers request them, negative numbers suppress them.
c Print specific tables
PRINT 60 110 126 128
c Suppress some tables
PRINT -85 -86 -130Where k-effective lives
For a kcode run the answer you care about first is k-effective. Near the end of the output, MCNP prints a line that reports the final estimated combined collision/absorption/track-length keff — three estimators folded into one number with a combined uncertainty. Searching the file for final estimated jumps straight to it.
Before you trust that line, check that the inactive cycles finished their job and that the three estimators agree within their combined uncertainty. The cycle-by-cycle keff table above the final line shows the source settling; if it is still drifting when active cycles begin, the combined answer is early. A pure eigenvalue deck with no tally cards will not print the ten statistical checks that accompany tallies — those appear once you add an f4 or f7.
Tally results and the ten checks
Each tally block opens with the tally number, the history count, the tally type, and the particles it scored. For an f4, MCNP then prints the volume it used — check it. If it could not compute the volume it says so and stops; if you supplied one on a vol or sd card, this is where you confirm you supplied the right one.
1tally 4 nps = 1000000
tally type 4 track length estimate of particle flux.
particle(s): neutrons
volumes
cell: 1
5.26814E-01
cell 1
energy
1.0000E-03 4.32106E-03 0.0021
1.0000E-02 1.89234E-02 0.0018
1.0000E-01 5.67891E-02 0.0015
1.0000E+00 3.45678E-02 0.0019
1.0000E+01 1.23456E-02 0.0023
total 1.26947E-01 0.0012Each row is the upper bound of an energy bin, the mean in neutrons/cm² per source particle, and the relative error. The total row is the sum of the bins above it, so adding the column up is a quick way to confirm you are reading the right block. Anything above the top bin bound is not scored at all, which is why the identity holds. Relative error should be below 0.1 for a result you can use, and it is normally smallest on the total because that bin collects the most scores.
Below the tallies, MCNP runs ten statistical checks on the tally fluctuation chart (TFC) bin of each tally.
results of 10 statistical checks for the estimated answer for the
tally fluctuation chart (tfc) bin of tally 4
tfc bin --mean-- ---------relative error--------- ----variance of the variance---- --figure of merit-- -pdf-
behavior behavior value decrease decrease rate value decrease decrease rate value behavior slope
desired random <0.10 yes 1/sqrt(nps) <0.10 yes 1/nps constant random >3.00
observed random 0.0012 yes yes 0.0001 yes yes constant random 5.12
passed? yes yes yes yes yes yes yes yes yes yesThe TFC bin is the one MCNP tracks cycle by cycle. For a tally with energy bins that is the total bin by default, so the 0.0012 here is the same relative error as the total row above — a cross-check worth making, because the two blocks disagreeing means you are reading output from two different tallies.
Warnings and failure signatures
A run that finishes is not the same as a run you can use. Lost particles almost always mean a geometry hole — a cell definition that does not cover the space it claims. Zero tallies usually mean the source and the tally region never meet. High relative error means too few scores in that bin; more histories, or a better estimator, are the fix. Missing cross sections need an xsdir path (or a ZAID) that actually exists. Importance assignments that do not match the geometry kill particles in cells you meant to score.
Fatal errors name a cause — geometry, materials, a bad truncation on a continuation line — and the message almost always points at a card. Warnings are quieter: read every one before you quote a number. For geometry debugging, a VOID card and an explicit print of cell volumes are the usual first moves; for data problems, confirm the libraries listed in the header against the ZAIDs in the deck.
The pin cell's output
Once the pin cell on Example: Pin Cell has run, the output has a short checklist. Find the final combined keff first — with reflective boundaries that value is a k∞, not the keff of a finite core, and it should sit well above one for fresh fuel at this enrichment. Then open the f4 flux and f7 heating tallies: confirm the volumes MCNP used, that the relative errors on the totals are small, and that the ten statistical checks pass.
If keff is absurdly low, the usual culprits are a missing mt on the water, a density sign flipped on a cell card, or a ksrc point that never sat inside fuel. If a tally is zero, check that the cell numbers on the tally cards still match the cells in the deck. The example page lists the expected physics and statistics for this model once those checks are clean.
Card semantics on this page follow MCNP6.3.1 Theory & User Manual (LA-UR-24-24602 Rev. 1), §2.6.4 Estimated Relative Errors in the MCNP Code, §2.6.9 Forming Statistically Valid Confidence Intervals and §5.13.3 PRINT: Printed Output Tables.
Full reference list on the attribution page.
Check yourself
- Navigate an output file by print table number?
- Find the final combined k-effective, and say what the three estimators are?
- Read a tally block as bin bound, mean, and relative error, and confirm the volume used for an
f4? - Match the TFC bin relative error against the total row of the tally?
- Recognise lost particles, zero tallies, and missing cross sections from their output signatures?