Documentation style

This describes the style conventions used in the MESA documentation.

Here is a link to a reStructured Text primer.

Click “View page source” in the upper right to see the rst file corresponding to this page.


Write module names as literals. My favorite module is eos.

Option names also literals like my_option. Ideally someday these would become hyperlinks to their reference entries.


References should be written in the usual astrophysics style – like Dotter et al. (2009) – and hyperlinked to either their ADS entry (preferred) or a DOI.


Common astrophysics symbols have substitutions already defined in

Symbol Substitution
\({\rm M}_\odot\) |Msun|
\({\rm L}_\odot\) |Lsun|
\({\rm R}_\odot\) |Rsun|
\(T_{\rm eff}\) |Teff|
\(\chi^2\) |chi^2|

Instrument Papers

Instrument papers should be indicated using the abbreviated form MESA I, etc. (This is achieved using the substitution |MESA I|.)