- Notifications
You must be signed in to change notification settings - Fork2
Easy Galaxy: A Flexible Interface for Stellar Population Synthesis Models
License
boada/easyGalaxy
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
EzGal calculates observables (apparent magnitude, absolute magnitude, k-corrections, e-corrections, masses, mass-to-light-ratios, and distance moduli) of stellar populations as a function of redshift, given the formation redshift. It can also generate spectral-energy distributions (SEDs) of complex-stellar populations (CSPs) from simple-stellar populations (SSPs). It takes as a primary input grids of SEDs as a function of age which can be read from plain text files, the Bruzual and Charlot binary ised files, and its own format stored in binary fits tables. It can pre-grid observables as a function of redshift and formation redshift and store the results in its own fits files to perform quick lookups later.
pip install ezgal
importezgalfrompylabimport*# load an EzGal model filemodel=ezgal.model('bc03_ssp_z_0.02.fits' )# get a grid of redshifts out to the desired formation redshiftzf=3zs=model.get_zs(zf )# plot mass-to-light ratio evolution versus redshift for three filtersplot(zs,model.get_rest_ml_ratios(zf,filters='sloan_i',zs=zs ),'k-',label='Sloan i' )plot(zs,model.get_rest_ml_ratios(zf,filters='ks',zs=zs ),'r--',label='2MASS Ks' )plot(zs,model.get_rest_ml_ratios(zf,filters='ch2',zs=zs ),'b:',label='IRAC ch2' )# and set labels for the plotxlabel('z' )ylabel('M/L Ratio' )# how about a legend?legend()# all doneshow()
Which makes:
Full API documentation can be viewed online inhtml andpdf formats.
python test.py
Conor Mancone and Anthony Gonzalez
We gratefully acknowledge the authors of the primary model sets included in this project for giving us permission to redistribute their work in this way. We especially thank Charlie Conroy, Maurizio Salaris, Santi Cassisi, St´efane Charlot, Gustavo Bruzual, and Claudia Maraston for their input on this project. We are also grateful to our many collaborators - Adam Stanford, Peter Eisenhardt, Yen-Ting Lin, Greg Snyder, and others who have tested EzGal extensively and provided us with invaluable feedback.
MIT
About
Easy Galaxy: A Flexible Interface for Stellar Population Synthesis Models
Resources
License
Stars
Watchers
Forks
Packages0
Languages
- Python100.0%