fixed incorrect metal mass fraction array for Freedman lowT opacity t…#994
Open
Debraheem wants to merge 2 commits into
Open
fixed incorrect metal mass fraction array for Freedman lowT opacity t…#994Debraheem wants to merge 2 commits into
Debraheem wants to merge 2 commits into
Conversation
…ables (#993) Co-authored-by: Emily Sandford <emily@Emilys-MacBook-Air.local> Louis Siebenaler (cc'd) and I noticed a problem with the preprocessing & evaluation of the Freedman11 low-temperature opacity tables. Specifically, the "Z" values associated with each table, as e.g. enumerated in $MESA_DIR/kap/public/kap_def.f90, num_kap_lowT_Zs(i) = 7 kap_lowT_Zs(1:num_kap_lowT_Zs(i), i) = [ 0.01d0, 0.02d0, 0.04d0, 0.100d0, 0.200d0, 0.63d0, 1.00d0 ] are not metal mass fractions. Rather, they are related to number fractions; for example, a Freedman [M/H] value of -0.3 corresponds to a metal number fraction of 10**(-0.3)solar = 0.5solar; [M/H]=0 corresponds to a solar number fraction, etc. It appears that there was a decision made to equate the solar metal number fraction with a metal mass fraction of 0.02 and scale the other values in the array accordingly. The metal mass fraction array should instead look something like this (with small variations possible depending on which protosolar abundance table you work with; the below values are based on Lodders 2003 table 2): [M/H] = [-0.3, 0.0, 0.3, 0.7, 1.0, 1.5, 1.7] Z = [0.0075, 0.0148, 0.029, 0.0698, 0.1303, 0.3215, 0.4288]
…ersion, add known_bugs/changelog docs, fix kap preprocessor typos and missing kap file build call introduced by 0030af6 ("kap: port preprocessor to new build system", update atm test output).
Member
Author
|
commit incoming, once git lfs let's me upload these files. |
Member
Author
|
I think this pr is the simplest way of changing the opacities from [M/H] to Z but it only does 6 sig figs in Z, using the file names. Is this enough, should the file be named such that they include near full precision names? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
(#993) @esandford
Co-authored-by: Emily Sandford emily@Emilys-MacBook-Air.local
Louis Siebenaler (cc'd) and I noticed a problem with the preprocessing & evaluation of the Freedman11 low-temperature opacity tables. Specifically, the "Z" values associated with each table, as e.g. enumerated in $MESA_DIR/kap/public/kap_def.f90, num_kap_lowT_Zs(i) = 7
kap_lowT_Zs(1:num_kap_lowT_Zs(i), i) = [ 0.01d0, 0.02d0, 0.04d0, 0.100d0, 0.200d0, 0.63d0, 1.00d0 ]
are not metal mass fractions. Rather, they are related to number fractions; for example, a Freedman [M/H] value of -0.3 corresponds to a metal number fraction of 10**(-0.3)solar = 0.5solar; [M/H]=0 corresponds to a solar number fraction, etc. It appears that there was a decision made to equate the solar metal number fraction with a metal mass fraction of 0.02 and scale the other values in the array accordingly.
The metal mass fraction array should instead look something like this (with small variations possible depending on which protosolar abundance table you work with; the below values are based on Lodders 2003 table 2): [M/H] = [-0.3, 0.0, 0.3, 0.7, 1.0, 1.5, 1.7]
Z = [0.0075, 0.0148, 0.029, 0.0698, 0.1303, 0.3215, 0.4288]