This software quickly computes magnitudes and spectra of rotating stellar models. The models incorporate Roche mass distribution (where all mass is at the center of the star), solid body rotation, and collinearity of effective gravity and energy flux.
The following instructions describe how to install PARS on macOS 10.15.4. These may have to be modified for other operating systems.
- git
- python
Go to the web page with the latest release, download the source code as a tar.gz file, put the file in the directory where you want to install PARS.
Un-compress the file, go to the software's top directory and install PARS.
tar -xf paint_atmospheres-x.x.x.tar.gz
cd paint_atmospheres-x.x.x
pip install .
Go to the directory where you want to install PARS, clone it in that directory, go to the software's top directory and install PARS.
cd <directory name>
git clone https://github.com/mlipatov/paint_atmospheres
cd paint_atmospheres
pip install .
Place a file with limb darkening information from atmosphere models in the data directory.
cp ~/im01k2.pck ./data
Print the command line syntax for the executables.
calc_limbdark -h
calc_star -h
calc_spectra -h
The following instructions describe how to access the functionality of PARS in several different ways.
Compute fits of intensity versus viewing angle from the limb darkening information.
calc_limbdark data/im01k2.pck data/limbdark_m01.pkl 0.1 0.4
Perform the inclination-independent computations for a stellar model.
calc_star 'data/limbdark_m01.pkl' 'data/vega.pkl' 0.6151 40.346 2.165 2.815 2.3694e19 100
Perform the inclination-dependent computations.
mkdir data/vega
calc_spectra 'data/vega.pkl' 'data/vega/' -i 0.088418
Look at the resulting spectrum.
cat data/vega/*.txt | more
Move a file with a filter transmission curve into the filter directory.
mv data/Generic_Bessell.V.dat data/filters/
Compute fits of filtered intensity versus the cosine of the viewing angle, then follow the same steps as above.
calc_limbdark data/im01k2.pck data/limbdark_m01f.pkl 0.1 0.4 -f data/filters/
calc_star 'data/limbdark_m01.pkl' 'data/vega.pkl' 0.6151 40.346 2.165 2.815 2.3694e19 100
calc_spectra 'data/vega.pkl' 'data/vega/' -i 0.088418
cat data/vega/*.txt | more
Go to the directory with scripts, run a script, look at the result.
cd pa/usr/
python 09_colormag_inclinations.py
ls ../../vega_colormag.pdf
These create figures 3 - 10 in [LB] (see References below).
- Intensity vs. viewing angle, goodness of fit checks: 1 followed by 2
- Temperature error
- Error due to interpolation in temperature and gravity
- Convergence of the longitudinal integral
- Error in the longitudinal integral
- Comparison with an observed spectrum
- Color-magnitude diagram for a range of inclinations
- Planetary transits
Unzip the file with brown dwarf plane-parallel atmospheres in CSV file format.
cd paint_atmospheres/data/
tar -xf bd_atmospheres.zip
Compute fits of intensity versus viewing angle from the limb darkening information.
python ../pa/usr/brown_dwarfs/calc_limbdark_bd.py
Compute the spectra of the T7 dwarf in Tannock et al. (2021) for the two extreme inclinations; plot.
python calc_bd.py bd_pkl/J0348-6022_few/ bd_spectra/J0348-6022_few/ 4.3e-6 3 9 -o 0.42
plot_bd.py ../../../data/bd_spectra/J0348-6022_few/ -d 10 --ratio
Calculate and plot the spectrum of the rapidly rotating L3.5 BD (note that the cloud-free Sonora atmospheres that we use are technically not appropriate for objects this hot).
calc_star data/limbdark_BD_00.pkl data/bd_pkl/J0407+1546.pkl 0.324443 0.0000977095 0.064 0.1 3.086e19 100
calc_spectra data/bd_pkl/J0407+1546.pkl data/bd_spectra/J0407+1546/ -i 0.000 1.5707963267948966 2
python plot_bd.py ../../../data/bd_spectra/J0407+1546/ -d 10
Calculate and plot the spectrum of Beta Pictoris b at 10 pc and two inclinations (luminosity is calculated from equatorial radius, not average).
calc_star data/limbdark_BD_00.pkl data/bd_pkl/betapicb.pkl 0.244337 0.000173182 0.0123 0.15 3.086e19 100
calc_spectra data/bd_pkl/betapicb.pkl data/bd_spectra/betapicb/ -i 0 1.5707963267948966 2
python plot_bd.py ../../../data/bd_spectra/betapicb/ -d 10
Calculate the models and the spectra.
python calc_bd.py bd_pkl/J0348-6022_400/ bd_spectra/J0348-6022_400/ 1.8e-7 11 21 -o 0.1 0.5 4
python calc_bd.py bd_pkl/J0348-6022_600/ bd_spectra/J0348-6022_600/ 9.3e-7 11 21 -o 0.1 0.5 4
python calc_bd.py bd_pkl/J0348-6022_880/ bd_spectra/J0348-6022_880/ 4.3e-6 11 25 -o 0.1 0.5 7
python calc_bd.py bd_pkl/J0348-6022_1500/ bd_spectra/J0348-6022_1500/ 3.6e-5 11 47 -o 0.1 0.5 4
python calc_bd.py bd_pkl/J0348-6022_2200/ bd_spectra/J0348-6022_2200/ 1.7e-4 11 43 -o 0.1 0.5 4
Plot.
python plot_T7.py 400
python plot_T7.py 600
python plot_T7.py 880
python plot_T7.py 1500
python plot_T7.py 880 # now that all the anisotropy ratios and rmsd values have been calculated
calc_spectra data/bd_pkl/J0348-6022/rotating/J0348-6022.pkl data/bd_spectra/J0348-6022_movie/txt/ -i 0.000 1.5707963267948966 150
python plot_bd_inclinations.py ../../../data/bd_spectra/J0348-6022_movie/txt ../../../data/bd_spectra/J0348-6022_movie/jpg 6000 -t
cd ../../../data/bd_spectra/J0348-6022_movie/
ffmpeg -framerate 10 -pattern_type glob -i '*.jpeg' -c:v libx264 -pix_fmt yuv420p -vf pad="width=ceil(iw/2)*2:height=ceil(ih/2)*2" ../J0348-6022_movie.mp4
- Timothy D. Brandt
- Mikhail Lipatov
- Lipatov M & Brandt TD, arXiv:2007.12779 [LB]
- Espinosa Lara F & Rieutord M (2011), A&A, 533, A43
- Castelli F & Kurucz RL (2004), arXiv:astro-ph/0405087
- Wolfram World: Cubic Formula
- Wikipedia: Bilinear interpolation: Algorithm
- Wikipedia: Newton's Method
- Press WH et al, Numerical Recipes, 3rd ed. (2007)
If you use PARS in your work, please cite the article that describes it. Thank you!