[Mesa-users] Heavy element profile
Evan Bauer
ebauer at physics.ucsb.edu
Fri Jan 11 15:45:18 EST 2019
Hi Claudio,
I agree with Frank that for you application, it sounds like you’re better off using the accretion controls.
But I also think it might be helpful to explain a little more why MESA isn’t behaving as you expected. The basic problem is that X, Y, and Z aren’t the fundamental composition variables in the star pointer. They are calculated based on the entire network of isotope mass fractions each step. So if you want to change composition by hand, you need to edit s% xa (see $MESA_DIR/star/public/star_data.inc). Then you’ll see X, Y, and Z in your model change accordingly.
Cheers,
Evan
> On Jan 11, 2019, at 6:12 AM, Francis Timmes via Mesa-users <mesa-users at lists.mesastar.org> wrote:
>
> one could try accreting material of a specified composition
>
> http://mesa.sourceforge.net/controls_defaults.html#composition_controls
>
> fxt
>
>
>
>
>> On Jan 11, 2019, at 3:06 AM, valletta <valletta at physik.uzh.ch> wrote:
>>
>> Dear MESA users
>>
>> Hello. I am modelling the evolution of a giant planet, I start the model with a given composition of X, Y and Z, constant through the envelope. Now I need to modify these compositions at every time-step, depending on the accretion of heavy element by the planet, and the amount of X,Y and Z must depend on the position of the layer in the envelope (so, a non-constant profile through the envelope). My idea to do that was to go in the run_star_extras file and write something like
>>
>> for(i = 1, i< layer number)
>>
>> s% x(i) = new x(i)
>> s% y(i) = new y(i)
>> s% z(i) = 1 - new x - new y
>>
>> the problem that I have is that these values are not saved by mesa, but at every time step the code restart from the initial profile of X,Y and Z.
>>
>> Thank you in advance for every help
>>
>> Best,
>> Claudio
>> _______________________________________________
>> mesa-users at lists.mesastar.org
>> https://lists.mesastar.org/mailman/listinfo/mesa-users
>>
>
> _______________________________________________
> mesa-users at lists.mesastar.org
> https://lists.mesastar.org/mailman/listinfo/mesa-users
>
More information about the Mesa-users
mailing list