[Mesa-users] Track the density of elements
Francis Timmes
fxt44 at mac.com
Thu Jun 11 05:06:02 EDT 2020
hi ebrahim,
please cc mesa-users on all replies so that we can track progress.
a perusal of star_data.inc shows
! composition variables: xa(j,k) holds mass fraction of species j for location k
one example of how to access this pointer structure is in
$MESA_DIR/star/test_suite/1M_pre_ms_to_wd/src/run_star_extras.f90
where the central he4 mass fraction is isolated
he_cntr = s% xa(s% net_iso(ihe4),nz)
good luck!
fxt
> On Jun 10, 2020, at 11:00 PM, Ebrahim Hassani <ee.haji at gmail.com> wrote:
>
> Dear Francis,
>
> Thank you for the prompt reply,
>
> Would you please help me with an example.
> For instance, how can I calculate the number density of helium elements in each cell while star evolving?
> I need to use parameters from "star_data.inc" file and implement them in "run_star_extras.f".
>
> Is it correct to write:
> n_He = N_A * rho * (X_He / A_He)
> where
> A_He = 4 (or A_He = 3 for Helium-3 )?
> What about X_He, which variable from "star_data.inc" file stands for X_He?
>
> Yours sincerely,
>
> Ebrahim
> hi ebrahim,
>
> the mass fractions of each isotope X_i in the reaction network being are readily available.
> if by the "density of the elements" you mean the number density in each isotope, then
>
> n_i = N_A * rho * X_i / A_i
>
> where N_A is the avogadro number, rho is the baryon mass density, and A_i is the atomic number of isotope i.
>
> fxt
>
>
>
>
>>
>>> On Jun 9, 2020, at 11:54 PM, Ebrahim Hassani via Mesa-users <mesa-users at lists.mesastar.org> wrote:
>>>
>>> Dear Mesa-user
>>>
>>> Would you please help me know how to calculate the density of elements (e.g. Hydrogen, Helium, Carbon and etc.) at the radius r while star evolving?
>>> I searched "star_data.inc" to find appropriate parameters to use in "run_star_extras.f", but I couldn't find it. I want to use these parameters in "run_star_extras.f" file.
More information about the Mesa-users
mailing list