Welcome
... to the homepage of MESA, modules for experiments in stellar astrophysics.
MESA Forum
Why A New 1D Stellar Evolution Code?
What Can It Do?
Instrument Papers
Manifesto
Download, install, and run
MESA C++ Interface and Interactive Python Driver
How do you say that?
What does thread-safe mean?
MESA Forum and mesa-users Mailing List
We are pleased to announce the opening of the MESA Forum, where you can upload your published results and inlists, upload & download tools, find examples, read a FAQ, and have discussions with other users:
Registration (upper right corner) is not mandatory to view pages, but is required to post material on pages.
The mesa-users@lists.sourceforge.net listserv will continue to exist and be used. Here are sites that let you browse and search previous messages.
Why A New 1D Stellar Evolution Code?
Stellar evolution calculations remain a basic tool of broad impact for astrophysics. New observations constantly test the models, even in 1D. The continued demand requires the construction of a general, modern stellar evolution code that combines the following advantages:
Openness: anyone can download sources from the website.
Modularity: independent modules for physics and for numerical algorithms; the parts can be used stand-alone.
Comprehensive Microphysics: up-to-date, wide-ranging, flexible, and independently useable microphysics modules.
Modern Techniques: advanced AMR, fully coupled solution for composition and abundances, mass loss and gain, etc.
Performance: runs well on a personal computer and makes effective use of parallelism with multi-core architectures.
Wide Applicability: capable of calculating the evolution of stars in a wide range of environments.
What Can It Do?
Here are some movies made using png output from mesa/star (see How to use MESA star).This movie has more than you ever wanted to know about the evolution of a 1 Msun star from pre-main sequence to cool white dwarf. (61MB)

This one shows the evolution of a 16 Msun star from zams to core collapse
(initial Z = 0.02 and zams uniform rotation = 0.5 of critical). (13MB)

3Msun from ZAMS through core He burning. (6MB)
8Msun from ZAMS through core He burning. (6MB)
25Msun from ZAMS through core He burning. (5MB)
1Msun: Helium core flash; 1Msun, Z=0.02. (12MB)
Now for something completely different, here is a movie showing rapid accretion of pure helium onto a neutron star envelope leading to Type I X-ray bursts. (10MB)
Here are a few plots from the 1st Instrument Paper.
Finally, here’s a movie made by Josiah Schwab using PDF files created using Tioga.
Evolution of a 1 MSun Star. (2.6MB)

To make movies like this yourself, see Josiah’s How to Make a Movie with MESA + Tioga.
Instrument papers
Now there is a 2nd instrument paper. It is available here: MESA instrument paper 2
The 1st one is available here: MESA instrument paper 1
You should take a look at them both before you use MESA.
The picture shows the intense authors hard at work making final edits.

A late night session working on the paper around Bill’s dining room table with a projector, a makeshift screen, and ample red wine (left to right, Frank Timmes, Aaron Dotter, Falk Herwig, Lars Bildsten, and Bill Paxton). Photo taken by Bill’s patient wife, Kathlyn, who deserves a great deal of credit for the existence of MESA.
MESA Manifesto
The MESA Manifesto discusses the motivation for the
MESA project, outlines a MESA code of conduct, and describes
the establishment of a MESA Council. Before using MESA, you need to download and read
the manifesto document. Here’s a brief extract.
Users are encouraged to add to the capabilities of MESA, which will remain a community resource.
However, use of MESA requires adherence to the MESA code of conduct:
That all publications and presentations (research, educational, or outreach) deriving from the use of MESA acknowledge the Paxton et al. (2010) publication and MESA website.
That user modifications and additions are given back to the community.
That users alert the MESA Council about their publications, either pre-release or at the time of publication.
That users make available in a timely fashion (e.g., online at the MESA website)
all information needed for others to recreate their MESA results—“open know how” to match “open source.”
That users agree to help others learn MESA, giving back as the project progresses.
Users are requested to identify themselves by joining one of the MESA mailing-lists:
MESA-users—for all active users of mesa; questions, comments, and discussion
MESA-news—for people interested in following developments in mesa but who are not active users
Download, install, and run
In the menu on the left, click “getting started” for information about downloading and installing MESA.
If you want to use the 1D stellar evolution package, visit “how to use MESA star”.
MESA C++ Interface and Interactive Python Driver
Thanks to Kent Budge, a C++ interface for MESA is now available at MESA++. It features an interactive Python driver that you may find fun to play with.
How do you say that?
Say MAY-sa.
What does “thread-safe” mean?
“Thread-safe” simply means that users can take advantage of multicore processors.
For example, during stellar evolution, you need to evaluate the eos at lots of points:
do k = 1, num_zones
call eos(T(k), rho(k), ....)
end do
Most fortran compilers (ifort and gfortran and others) support OpenMP, so the loop can be made to run in parallel by adding 2 lines of magic:
!$OMP PARALLEL DO PRIVATE (k)
do k = 1, num_zones
call eos(T(k), rho(k), ....)
end do
!$OMP END PARALLEL DO
Now, if I have 4 cores, I’ll have 4 threads of execution evaluating the eos.
However, for it to work, the implementation needs to be thread-safe.
In practice this means, making shared data read-only after initialization.
Working memory must be allocated from the stack (as local variables of routines)
or allocated dynamically (using fortran95’s allocate primitive).
So, basically it boils down to avoiding common blocks and save’s.
It’s easy to arrange for this in new code; it can be nasty converting old code however.
Stellar evolution is a good candidate for making use of many cores.
Just wrapping “parallel” directives around some loops does it
if the system is designed with that in mind—and MESA is.
But there is still much to be done to make good use of more than
3 or 4 cores in MESA/star.
It will be an ongoing effort to improve
the design of the code in that area; help with that is welcomed!
website design by
Andreas Viklund