MOCASSIN 2.02 manual

Output files

MOCASSIN produces several output files at various times during the simulation. This will be contained in a subdirectory named output/. The files ionratio.out, lineFlux.out, temperature.out, (tau.out), ionDen.out and SED.out are all produced by the output_mod module.

The plot.out and grid4.out files are produced by the mocassinPlot file


ionratio.out contains the volume averaged ionic fractions. Different authors is the past have used slightly different definitions of this quantity in their models. Please refer to Ercolano et al. (2003) for further information on the description used by MOCASSIN.

The first two columns of the ionratio.out file give the atomic number of the element and its ionisation stage (1 for neutral, 2 for singly ionised etc.), and the third column gives the required quantity. If a multiChemistry model is being run, then the results will be given for each individual component.


The file lineFlux.out contains the volume integrated intensities of all the emission lines calculated by MOCASSIN. These are all given relative to Hβ, which is in absolute units.

The first two columns give the element and ion number, these are followed by MOCASSIN codes for the levels of the transition; these are followed by the wavelength in [A]. The wavelength column is followed by the analytical and Monte Carlo line intensities relative to Hβ, which is given in absolute units at the top of each region. Finally the last column gives the ratio of the two previous columns. NOTE that the Monte Carlo line intensities are only calculated if the debug keyword is included in the input file. In normal mode only the intensities calculated using the formal solution (which are in general more accurate) will be available.

If a multiChemistry model is being run, then the results will be given for each individual component.


The file temperature.out contains the mean electronic temperatures weighted by the ionic species (see Ercolano et al., 2003 for definition). This file has the same structure as the ionratio.out file.

If a multiChemistry model is being run, then the results will be given for each individual component.


Please see Section 2.3 of Ercolano, Barlow and Sugerman (2007) for a description of this quantity. The first column contains Energy [Ryd] the second column contains wavelength [μm] the third column contains equivalent tau [see paper] and the fourth column contains Fλ0 [see paper]. Note that in the case of diffuse illumination this is the only meaningful quantity - see discussion in paper.


The file tauNu.out contains the frequency dependent optical depth tau(nu) [which includes ALL opacity sources] at the edge of the grid in the three positive axial directions starting from the origin of the axes.


THIS FILE IS NOT PRODUCED ANY MORE IN VERSIONS >= 2.02.49 PLEASE CONTACT ME IF YOU NEED IT. The file tau.out contains the run of the optical depth from the centre of the nebula to the outer edge along the three axial directions. The optical depths are calculated at the neutral hydrogen ionisation threshold, nu = 1.0 Ryd (13.6 eV), at the neutral Helium ionisation threshold, nu = 1.8 Ryd, and at the singly ionised Helium ionisation threshold, nu = 4.0 Ryd. The first column of the file gives the distance in [cm] from the centre of the nebula and the second column gives the optical depth from the centre to that point. This file is not always calculated correctly if the internal switches are not set up properly. Please use equivalentTau. See description above.


The file ionDen.out contains the ionic fractions at each grid cell. The first three columns give the x-, y- and z-axis indices of the cell, the fourth and fifth columns give the atomic number and the ionisation stage of the element (as above, 1 for atom, 2 for singly ionised etc.) and, finally, the sixth column gives the corresponding ionic fraction.

This file is only written out if you enable the debug keyword in the input file.


This file contains the emerging spectral energy distribution from the grid. As indicated in the files' header column 1 and column 2 contain the frequency [Ryd] and wavelength [μm] grid, column 3 contains the direction averaged SED per unit direction (must multiply by π to obtain the total overall directions); the following columns contain the SED emerging in any given line of sight as requested by the user in the file with the inclination keyword.

The grid files and photoSource.out

As we have already mentioned elsewhere, grid files are also written out after each iteration by routines contained in the grid_mod module. These are needed by the warm start driver (mocassinWarm) to re-initialise an interrupted simulation. These files are formatted such that they can be written out and read back in quickly and therefore they may not be very clear to the human eye. However, most of the information they contain is also given in a more intelligible form in the other output files listed above, dust temperatures are an exception as discussed in plotting dust temperatures. Gas-only simulations will result in 4 grid files being written out: grid0.out, grid1.out, grid2.out and grid3.out.

The first line of the grid0.out file gives the number of grids included (mother+ subgrids), on the next line are the x-, y- and z-axes points in the mother grid, followed by the outer radius in [cm]. The next few lines list the x-axis points, then the y-axis points and, finally, the z-axis points. The rest of the file contains the convergence info for each grid cell. The active index of the cell in the first column, whether it has converged (1=yes,0=no), and whether it is a black cell (i.e. if could not be reached by any photons, 1=black, 0=normal). Cells that have a 0 index are inactive cells; cells with a negative index are cells that have been replaced by a subgrid, whose index is equal to the absolute value of the negative mother-cell index. In the case of multiGrid simulations, the file will loop around all subgrids included.

The grid1.out file contains the electron temperatures, electron densities and hydrogen densities for each grid cell in each grid. As for the grid0.out file, this information is given for each grid cell, with the last index varying the fastest (i.e. (1,1,1), (1,1,2), etc.).

The file grid2.out contains the ionic fractions at each grid cell for the ions included in the simulation. These are given in order of increasing atomic number and ionisation stage, with each element occupying one line. The grid cell indices vary in the same fashion as in the grid1.out file.

The file grid3.out contains a list of the specified simulation parameters in a fixed order (the keywords are indicated on the right of each value). NOTE that it is not possible any more to change nuStepSize from the file. If you wish to change this parameter (you shouldn't need to), this is defined in the set_input_mod module.

Dust-only simulations only produce grid0.out, grid3.out and dustGrid.out

The file dustGrid.out contains the dust number density at each cell followed by the grain temperatures for each grain size of each grain species. For each cell Ndust is written on one line and this is followed by n_size+1 lines of n_species+1 columns containing the individual grain temperatures for each size and species, where n_size=number of size bins and n_species=number of grain species included. The average temperature for the grain mixture weighted by the size distribution and the species abundances is given at (0,0).

Dust+gas simulations will produce all the files above.

grid4.out is written out by mocassinPlot and it just contains the volume of each gridcell in [e45 cm3], which is needed for visualisation purposes.

The ionising source(s) input parameters are written out to a file named photoSource.out.


The mocassinPlot driver produces also an output file, containing the luminosities of each individual grid volume element in the required emission lines. This file, named plot.out, is written in a format which should be easily readable into a data visualisation software, such as IDL or PDL. A grid4.out is also written out, containing the volume of each gridcell in [e45 cm3].

« 5.1 Input filescontents 6.1 Analytical and Monte Carlo line fluxes »