Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Begin The Great Documention #779

Open
wants to merge 7 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions astero/defaults/astero_pgstar.defaults
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,11 @@
echelle_file_dir = 'png'
echelle_file_prefix = 'echelle'
echelle_best_model_file_prefix = ''

! ! if non-empty save best chi^2 model file
! ! e.g. 'best_model_echelle'
! ! note: this is enabled even if echelle_file_flag = .false.

echelle_file_interval = 5 ! output when mod(model_number,echelle_file_interval)==0
echelle_file_width = -1 ! negative means use same value as for window
echelle_file_aspect_ratio = -1 ! negative means use same value as for window
Expand Down Expand Up @@ -72,9 +74,11 @@
ratios_file_dir = 'png'
ratios_file_prefix = 'ratios'
ratios_best_model_file_prefix = ''

! ! if non-empty save best chi^2 model file
! ! e.g., 'best_model_ratios'
! ! note: this is enabled even if ratios_file_flag = .false.

ratios_file_interval = 5 ! output when mod(model_number,ratios_file_interval)==0
ratios_file_width = -1 ! negative means use same value as for window
ratios_file_aspect_ratio = -1 ! negative means use same value as for window
Expand Down
4 changes: 2 additions & 2 deletions docs/source/developing/test_suite.rst
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ When a test is run through ``each_test_run``, a file ``testhub.yml``
will be produced. This is the information that will be reported to
the TestHub by ``mesa_test``. The file will look similar to this:

.. code-block:: none
.. code-block:: yaml

---
test_case: make_co_wd
Expand Down Expand Up @@ -346,7 +346,7 @@ For example, in ``c13_pocket``, the ``run_star_extras`` sets::

which results in the additional output

.. code-block:: none
.. code-block:: yaml

- inlist: inlist_c13_pocket_header
...
Expand Down
6 changes: 4 additions & 2 deletions docs/source/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,10 @@ MESA is written primarily in Fortran with a modular, flexible design that facili

🚀 New to MESA? Start with the :ref:`Quickstart<quickstart:Quickstart>` guide to set up and run your first models.

📖 Experienced users may find the :ref:`Reference and Defaults<reference:Reference and Defaults>` page most valuable for exploring the code’s features and input parameters. The :ref:`Test Suite<test_suite:Test Suite>` provides example problems for testing and showcasing MESA, serving as a project starting point but often requiring modifications for science-grade accuracy.
📖 Experienced users may find the :ref:`Reference and Defaults<reference:Reference and Defaults>`
page most useful for exploring the code’s features and input parameters.
The :ref:`Test Suite<test_suite:Test Suite>` provides example problems for testing and showcasing MESA,
serving as a project starting point but often requiring modifications for science-grade accuracy.

Check out the full documentation below.

Expand All @@ -31,4 +34,3 @@ Check out the full documentation below.
faq
known_bugs
news

13 changes: 8 additions & 5 deletions docs/source/installation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ system. There's a template to get you started at
:file:`$MESA_DIR/utils/makefile_header_non_mesasdk`.

Regardless of whether you use the MESA SDK or ifort, and whether your
machine runs MacOS or linux, the output of MESA should be bit-for-bit
machine runs MacOS or Linux, the output of MESA should be bit-for-bit
identical. If it's not, this is considered to be a bug. (This has
been the case since Release 5819 in early January 2014.)

Expand Down Expand Up @@ -98,11 +98,11 @@ startup file in an existing one).
Here is an example from a machine that uses bash as its shell (and hence
uses export to set variables):

.. code-block:: bash
.. code-block:: shell

# set MESA_DIR to be the directory to which you downloaded MESA
# The directory shown is only an example and must be modified for your particular system.
export MESA_DIR=/Users/jschwab/Software/mesa-r21.12.1
export MESA_DIR=/Users/my_username/Software/mesa-r24.08.1

# set OMP_NUM_THREADS to be the number of cores on your machine
export OMP_NUM_THREADS=2
Expand All @@ -115,9 +115,12 @@ uses export to set variables):
# add shmesa (the MESA command line tool) to your PATH
export PATH=$PATH:$MESA_DIR/scripts/shmesa

Note (Jan 2025): due to some changes in MacOS 15.2/15.3, if you see the error `ld: library 'z' not found` on a Mac you may also need to add:
Note (Jan 2025): due to some changes in MacOS 15.2/15.3,
if you see the error
`ld: library 'z' not found`
on a Mac you may also need to add:

.. code-block:: bash
.. code-block:: shell

export SDKROOT=$(xcrun --sdk macosx --show-sdk-path)

Expand Down
2 changes: 1 addition & 1 deletion docs/source/summer_schools.rst
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ We aim for 50-50 gender representation (50% men, 50% women and gender minorities

6 months out (February)
-----------------------
- post the Summer School website. Bill Wolf (MESAev) has been the web manager for many Summer Schools
- post the Summer School website. Bill Wolf (MESAdev) has been the web manager for many Summer Schools

- assign TAs to lecturers. We recommend assigning one first-time TA, one returning TA, and one very experienced TA per lecturer. This ensures that new TAs receive excellent training while the more experienced TAs can provide leadership on the development of exercises and management of the group. Please be aware that it has not been a requirement historically that the lecturers have any experience with MESA. It is the lecturers' jobs to develop the scientific program and contribute their subject expertise. It is the TAs jobs to turn the lecturers' science into accessible, MESA-based exercises.

Expand Down
21 changes: 11 additions & 10 deletions kap/defaults/kap.defaults
Original file line number Diff line number Diff line change
Expand Up @@ -493,11 +493,12 @@
! -------------

! These are arrays of size(10) that can be used to pass in custom information to kap ::
! ::

kap_ctrl(:) = 0d0
kap_integer_ctrl(:) = 0
kap_logical_ctrl(:) = .false.
kap_character_ctrl(:) = ''
kap_ctrl(:) = 0d0
kap_integer_ctrl(:) = 0
kap_logical_ctrl(:) = .false.
kap_character_ctrl(:) = ''


! Extra inlist controls
Expand All @@ -507,13 +508,13 @@
! It works recursively, so the extras can read extras too.


! read_extra_kap_inlist(1..5)
! ~~~~~~~~~~~~~~~~~~~~~~~~~~~
! extra_kap_inlist_name(1..5)
! ~~~~~~~~~~~~~~~~~~~~~~~~~~~
! read_extra_kap_inlist(1..5)
! ~~~~~~~~~~~~~~~~~~~~~~~~~~~
! extra_kap_inlist_name(1..5)
! ~~~~~~~~~~~~~~~~~~~~~~~~~~~

! If ``read_extra_kap_inlist(i)`` is true, then read ``&eos`` from the file ``extra_kap_inlist_name(i)``.
! ::
! If ``read_extra_kap_inlist(i)`` is true, then read ``&eos`` from the file ``extra_kap_inlist_name(i)``.
! ::

read_extra_kap_inlist(:) = .false.
extra_kap_inlist_name(:) = 'undefined'
Expand Down
28 changes: 18 additions & 10 deletions star/defaults/controls.defaults
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,7 @@
! log_directory
! ~~~~~~~~~~~~~

! for data files about the run
! directory for data files about the run

! ::

Expand All @@ -226,7 +226,7 @@
! do_history_file
! ~~~~~~~~~~~~~~~

! history file is created if this is true
! a history file is created if this is true

! ::

Expand Down Expand Up @@ -1115,7 +1115,7 @@
! ~~~~~~~~~~~~~~~~~~~~~~~~~~

! stop when the center entropy is above/below the upper/lower limit.
! in kerg per baryon
! in kerg per baryon, where kerg = (erg K^-1)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not just

Suggested change
! in kerg per baryon, where kerg = (erg K^-1)
! in erg per kelvin per baryon

or

Suggested change
! in kerg per baryon, where kerg = (erg K^-1)
! in (erg K^-1) per baryon

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree with you @warrickball ! It's just that kerg gets used all over in Mesa documentation and output headers, so I think we should correct these all at once. Should we do it in this PR?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, if it's a reasonably common unit, perhaps we don't need to change it, but I'd never encountered it before.

If we are going to change it in a lot of places at once, I agree with doing it in a separate PR.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

comment from the peanut gallery. i disagree with adding per baryon. electrons, leptons, have an entropy that is added to the total. photons, bosons, also have an entropy that is added in. an entropy of mixing is also added. none of these other contributions to the total entropy have baryons associated with them.


! ::

Expand All @@ -1129,7 +1129,7 @@
! ~~~~~~~~~~~~~~~~~~~~~~~

! stop when the max entropy is above/below the upper/lower limit.
! in kerg per baryon
! in kerg per baryon, where kerg = (erg K^-1)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As above:

Suggested change
! in kerg per baryon, where kerg = (erg K^-1)
! in erg per kelvin per baryon

or

Suggested change
! in kerg per baryon, where kerg = (erg K^-1)
! in (erg K^-1) per baryon


! ::

Expand Down Expand Up @@ -1183,7 +1183,7 @@
! Lower limits on surface mass fractions.
! Stop when surface abundance drops below this limit.
! Can have up to ``num_xa_surface_limits`` of these (see ``star_def`` for value)
! ``xa_surface_lower_limit_species`` contains an isotope name as defined in ``chem_def.f``
! ``xa_surface_lower_limit_species`` contains an isotope name as defined in ``chem_def.f90``
! ``xa_surface_lower_limit`` contains the lower limit value

! ::
Expand Down Expand Up @@ -1246,7 +1246,7 @@
! HB_limit
! ~~~~~~~~

! For detecting horizontal branch.
! For detecting when the model has completed the horizontal branch.
! Only applies when center abundance by mass of h1 is < 1d-4.
! Stop when the center abundance by mass of he4 drops below this limit.

Expand Down Expand Up @@ -1298,6 +1298,8 @@
! star_species_mass_max_limit_iso
! ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

! Stop when a particular species mass in units of Msun exceeds these limits.

! ::

star_species_mass_min_limit = 0
Expand Down Expand Up @@ -1972,6 +1974,9 @@
! ~~~~~~~~~~~~~~~~~~~~~~

! stop when Lnuc/L is greater than this limit.
! Here, Lnuc refers to the total thermal power from all burning, including photodisintegrations,
! ``power_nuc_burn`` in the history_columns.list file.
! L is the luminosity at the photosphere.

! ::

Expand All @@ -1982,6 +1987,9 @@
! ~~~~~~~~~~~~~~~~~~~~~~

! stop when Lnuc/L is less than this limit.
! Here, Lnuc refers to the total thermal power from all burning, including photodisintegrations,
! ``power_nuc_burn`` in the history_columns.list file.
! L is the luminosity at the photosphere.

! ::

Expand Down Expand Up @@ -2022,7 +2030,7 @@
! Pgas_div_P_limit
! ~~~~~~~~~~~~~~~~

! criteria for stopping on Pgas/P
! criteria for stopping when Pgas/P <= Pgas_div_P_limit
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For parity with other similar controls

Suggested change
! criteria for stopping when Pgas/P <= Pgas_div_P_limit
! stop when Pgas/P <= Pgas_div_P_limit


! ::

Expand All @@ -2032,7 +2040,7 @@
! Pgas_div_P_limit_max_q
! ~~~~~~~~~~~~~~~~~~~~~~

! stop if Pgas/P < this limit at any location with ``q <= Pgas_div_P_limit_max_q``
! stop if Pgas/P < Pgas_div_P_limit at any location with ``q <= Pgas_div_P_limit_max_q``
! values near unity skip the outer envelope

! ::
Expand Down Expand Up @@ -4109,8 +4117,8 @@

D_mix_rotation_min_tau_full_off = 0d0

! D_mix_rotation_max_tau_full_on
! ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
! D_mix_rotation_max_tau_full_on
! ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

! Use rotational components of ``D_mix`` for locations where tau >= this.
! For numerical stability, turn off rotational part of ``D_mix`` at very low tau.
Expand Down
2 changes: 2 additions & 0 deletions star/defaults/star_job.defaults
Original file line number Diff line number Diff line change
Expand Up @@ -689,6 +689,8 @@
! set hydrogen and helium mass fractions according to the following:
! If no h2 in current net, then this will be added to h1.
! If no he3 in current net, then this will be added to he4.
! When ``set_uniform_initial_composition = .false.``, defer to
! composition controls in &controls.defaults.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Though we aren't being very consistent about monospace yet, I think this should be

Suggested change
! composition controls in &controls.defaults.
! composition controls in ``star/defaults/controls.defaults``.


! ::

Expand Down
3 changes: 2 additions & 1 deletion star/defaults/star_job_dev.defaults
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,8 @@

save_photo_number = -1
save_photo_filename = ''
! !save_photo_when_terminate = .true.

! ! save_photo_when_terminate = .true.

! create_merger_model !!! EXPERIMENTAL
! ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Expand Down
2 changes: 1 addition & 1 deletion star/test_suite/hb_2M/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ We specify the output. We define a LOG directory for this part of the evolution,

.. literalinclude:: ../../../star/test_suite/hb_2M/inlist_to_ZACHeB
:start-after: output controls
:end-before: ! FOR DEBUGGING
:end-before: end of


Evolution along the CHeB
Expand Down