Open nichollsh opened 7 months ago
Amazing! Does this work neatly together with Mors?
Yes I think so. Mors provides us with the band-integrated fluxes, which are then used to scale the spectrum. Currently we've been semi-manually obtaining spectra from Muscles (etc.) but this could make it much simpler by taking the stellar parameters from the configuration file.
The main downside is that it increases the number of dependencies.
I've tested this in a standalone notebook by using the Baraffe tracks to get Teff and logg at a given age, and then using these to find the appropriate spectrum.
Seems to work, although it's quite slow since this python package downloads the spectra via FTP from the PHOENIX database as required.
I still think this is worth thinking about, but it needs more investigation.
The library mentioned above gets PHOENIX spectra from the Goettingen spectral library. However, this doesn't seem to cover wavelengths below 60 nm. For escape calculations we will want wavelengths shorter than this.
The BT-Settl models cover ~1e-4 to ~1e5 nm, which is better (and also overkill).
Can view/obtain these here: http://svo2.cab.inta-csic.es/theory/newov2/index.php
And also potentially from here: https://zenodo.org/records/8015969
I have scraped the model spectra from the website above for the BT-Settl CIFIST grid. This covers a wide range of Teff and log(g). It also covers X-ray and EUV.
These are stored as individual npy files, packaged into a single tar.gz file on OSF. https://osf.io/8r2sw/
We could easily write a script to take Teff and log(g) from an evolution track, and then interpolate or find the appropriate spectrum from this grid. The file size is only ~1 GB.
Also check out: https://msg.readthedocs.io/en/stable
It would be very easy to generalise the 'get stellar spectrum' script in
tools/
to cover a much wider range of stars by using the following Python library: https://github.com/bmorris3/expectoParticularly useful for modelling planets around less well-studied stars (e.g. LP 791-18)