[Mesa-users] error when try to make a solor-like star to accrete material which is like to earth(with inlist)
李宗恒
lzh17513652589 at 163.com
Fri Aug 8 01:51:11 UTC 2025
hello mesa_users:
following is my issue
mesa-r23051
mesasdk-x86_64-linux-23.7.3.tar
when I try to make the sun-like star to accrete earth-like materials(several earth-masses),some error come out
retry: adjust_correction failed in eval_equations -- give up in solver 159
retry: get_T_tau -- L <= 0 226
The inlist is in the attachment.
the composition I used is showing in the part of run_star_extras
integerfunction extras_finish_step(id)
use atm_lib!!!, only: atm_option, atm_option_str
use kap_def!!!, only: kap_lowT_option, lowT_AESOPUS
integer, intent(in) :: id
integer :: ierr
real(dp) :: envelope_mass_fraction, L_He, L_tot, min_center_h1_for_diff, &
critmass, feh, rot_full_off, rot_full_on, frac2,m_limit
real(dp), parameter :: huge_dt_limit = 3.15d16! ~1 Gyr
real(dp), parameter :: new_varcontrol_target = 1d-3
real(dp), parameter :: Zsol = 0.0142
real(dp) :: center_h1, center_h1_old, center_he4, center_he4_old
type (star_info), pointer :: s
logical :: diff_test1, diff_test2, diff_test3
character (len=strlen) :: photoname, stuff
real(dp) :: da_dt, term2, term3, a, dI_dt, t, t_1, I_current, I_prev,delta_t,fe_grad,o_grad
integer::k
ierr = 0
call star_ptr(id, s, ierr)
if (ierr /= 0) return
extras_finish_step = keep_going
call store_extra_info(s)
m_limit = 1.0d0*Msun + 1d0*m_earth
if (s% star_age >1d7 .and. s% mstar < m_limit .and. s% x_logical_ctrl(3))then
write(*,*)"********accreting**********"
s% accrete_same_as_surface = .false.
s% accrete_given_mass_fractions = .true.
s% num_accretion_species = 4
s% accretion_species_id(1) = 'o16'
s% accretion_species_xa(1) = 0.3
s% accretion_species_id(2) = 'mg24'
s% accretion_species_xa(2) = 0.2
s% accretion_species_id(3) = 'si28'
s% accretion_species_xa(3) = 0.2
s% accretion_species_id(4) = 'fe56'
s% accretion_species_xa(4) = 0.3
s% mass_change = 1d-11
write(*,*)"mstar=,m_limit=",s% mstar,m_limit
write(*,*)"********accreting*********"
else
write(*,*)"mstar=",s% mstar
s% mass_change = 0
endif
But if I use Jupiter composition ,everything is fine
s% accrete_same_as_surface = .false.
s% accrete_given_mass_fractions = .true.
s% num_accretion_species = 4
s% accretion_species_id(1) = 'h1'
s% accretion_species_xa(1) = 0.75
s% accretion_species_id(2) = 'he4'
s% accretion_species_xa(2) = 0.2
s% accretion_species_id(3) = 'li7'
s% accretion_species_xa(3) = 1d-9
s% accretion_species_id(4) = 'fe56'
s% accretion_species_xa(4) = 0.04999999d0
s% mass_change = 1d-11
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.mesastar.org/pipermail/mesa-users/attachments/20250808/090665f5/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: inlist_template_lowintermass
Type: application/octet-stream
Size: 14897 bytes
Desc: not available
URL: <https://lists.mesastar.org/pipermail/mesa-users/attachments/20250808/090665f5/attachment.obj>
More information about the Mesa-users
mailing list