A Quick Introduction to MESA

We would really like to hit the ground running, so please try to install MESA before arriving at TSI. You will need to install the MESA SDK (various compilers and libraries to use MESA) and MESA itself. If you have Mac you will need to install Xcode first. If you have Linux, you should be good to go. If you have Windows, sorry ... you will need install Linux to run MESA, but you can still do the globular cluster analysis using other people's models. We will also assume that you are a bit familar with python to do plots, but we can help with that.

The MESA software and detailed instructions for getting it to work are located at http://mesa.sourceforge.net/index.html. For your convenience we have linked for files here; you can find the links below.

Table of Contents

Lecture 1 --- Stars: Physics

MESA Best Practices

We will start with the directory in the test suite called "1M_pre_ms_to_wd" and learn about how to create stars, control MESA and change its output.

  1. Create a directory in "mesa/star" called "tsi2017"
  2. Copy "1M_pre_ms_to_wd" from the "test_suite" into "tsi2017". For example
    cp -rp test_suite/1M_pre_ms_to_wd tsi2017/lab1a
    
  3. Make changes
  4. Because we are building up a series of changes, let's copy what we have done so far to a new directory before we run it.
    cp -rp lab1a lab1b
    
  5. Go to lab1a, make "./mk" and run "./rn".
  6. Repeat from Step 3 in lab1b directory.

Lab 1 (Monday AM): The Evolution of a Solar-Mass Star

Other Masses

Here are some movies for several different masses to highlight the differences in the stellar evolution:

  1. 1 solar mass
  2. 10 solar masses
  3. 15 solar masses
  4. 20 solar masses

Homework

Choose groups of four to do the homework together. Each of you need to have a working MESA on your computer. If you don't, join a group of four.
  1. Copy your final minilab directory into a new directory called "homework". Add this file history_columns.list to the directory.
  2. With your partners, choose an initial mass between 0.7 and 1 solar masses
  3. Choose two different initial metalicities between 2e-4 to 0.06.
  4. Choose two different initial helium abundances between 0.24 to 0.32. For example, add
    initial_y = 0.25
    
    just below the initial_z line.
  5. If you want to coordinate with other groups to do the same Y and Z but different masses, that would be great.
  6. Upload your history.data to the shared Google folder. Please create a unique directory of the form z_0.02_y_0.25_m_0.9.
  7. When you are done, you should have a grid of metallicities and heliums for the same initial mass that you can plot together.
  8. How does the turn off time depend on Y and Z? How does the tip of the RGB and HB luminosity depend on Y and Z?

Lecture 2 --- Stars: Observations

Lab 2 (Tuesday AM/PM): Deconstructing the Colour-Magnitude Diagrams of Globular Clusters

Look at the "raw data" for two globular clusters.

One ingredient missing from MESA to understand observations are stellar atmopsheres. The conversion from luminosity and effective temperature to the observed fluxes in range of photon energies is usually called the bolometric correction. We call it "painting."

To paint your stars, you will need painthistory.py and a database of spectral models.

colmag.Castelli.HSTACSWFC3.Vega.M0.5.txt
colmag.Castelli.HSTACSWFC3.Vega.M0.txt
colmag.Castelli.HSTACSWFC3.Vega.M-0.5.txt
colmag.Castelli.HSTACSWFC3.Vega.M-0.75.txt
colmag.Castelli.HSTACSWFC3.Vega.M-1.txt
colmag.Castelli.HSTACSWFC3.Vega.M-1.25.txt
colmag.Castelli.HSTACSWFC3.Vega.M-1.5.txt
colmag.Castelli.HSTACSWFC3.Vega.M-2.txt

How to paint your history files?

  1. Choose the spectral model with the metallicity closest to your star. The quantity between the M and the .txt is [M/H]. The formula is [M/H] = log10 Z/0.02
  2. Run for example:
    python painthistory.py history.data colmag.Castelli.HSTACSWFC3.Vega.M-2.txt paintedhistoryM-2.data
    
  3. Save your painted history to the Google folder in the same directory as your history.data file.
  4. Look in the painted history file. There is data about the stellar properties and the magnitudes in various filters for HST. We want F606W and F814W. Plot F606W vs F606W-F814W for your history. Save the plot as cmd.png in your model's directory on the Google folder.
  5. And ultimately we want to compare the results with the data.

  6. Please pick a cluster for your team from this website. Download the zpt data file from the appropriate directory.
  7. You can get more information about your cluster from here.
  8. From the table you are interested in Rsun and E(B-V). Some handy information is A814W = 1.744 E(B-V) and A606W = 2.772 E(B-V), so E(814W-606W) = 1.028 E(B-V).

  9. Make a plot like this (I used NGC0104R.RDVIQ.cal.adj.zpt).
  10. The colour-magnitude diagram of NGC 104

    I used ctioga2 to do this, as so

    ctioga2 --line-style no --marker Circle --marker-scale 0.2 --name NGC104 NGC0104R.RDVIQ.cal.adj.zpt@6:4 --xrange 0.3:2 --yrange 25:10 -x 'F606W-F814W (a.k.a. V-I)' -y 'F606W (a.k.a. V)'
    
    To get ctioga2 you can run sudo apt-get install ctioga2 or sudo gem install ctioga2.

  11. Try to overplot your painted history on your colour-magnitude diagram. How should you shift the y-coordinates of your model? Can you also shift the x-coordinates? Pay special attention to the bendy bits (e.g. turn-off) and the various clumpy places.

    Here is a plot that I made of a bunch of your models.
    Some model colour-magnitude diagrams
    and here is the ctioga2 command:

    ctioga2 --name plot  t1##5.data@'$10-$11:$11' -x F606W-F814W -y F814W --yrange 14:-6
    

  12. Create a folder on the Google drive with the name of your cluster.
  13. Upload your best fitting model (history.data and paintedhistory.data) and the plot of the cluster data to the folder. Note the mass, helium and metallicity of the model and the amount that you shifted the y-axis in a README.txt file.

The Models

To make things easier we have precalculated a grid of metallicities, heliums and masses for you to use at newmodels and you can use the models in the Google folder that our students produced too.

Lab 3 (Tuesday PM): Changing the Physics with run_star_extras

A second example that you can look at here, changes the wind on the AGB from the Reimers model to the Schröder and Cuntz model.

MESA SDK

Linux:

http://www.astro.wisc.edu/~townsend/resource/download/mesasdk/mesasdk-x86_64-linux-20160129.tar.gz

Mac OS (Mavericks and earlier):

http://www.astro.wisc.edu/~townsend/resource/download/mesasdk/mesasdk-x86_64-osx-10.6-10.9-20160404.dmg

Mac OS (Yosemite and later):

http://www.astro.wisc.edu/~townsend/resource/download/mesasdk/mesasdk-x86_64-osx-10.10-20160404.dmg

MESA Source Code

http://sourceforge.net/projects/mesa/files/releases/mesa-r9793.zip/download