phoebe-project / phoebe2

PHOEBE - Eclipsing Binary Star Modeling Software
http://phoebe-project.org
GNU General Public License v3.0
76 stars 28 forks source link

Atmosphere parameters out of bounds #864

Open MinyuLi opened 1 month ago

MinyuLi commented 1 month ago

When I set R1=0.126, then run_compute. The function does not return, and the I get this log warning: WARNING : Atmosphere parameters out of bounds: ldatm=ck2004, teff=[10426.], logg=[5.01315196], abun=[0.]

When I use a greater R1=0.146, run_compute can work well. Does R1 have a lower limitation? How do I fix the problem so that the smaller R1 will work correctly? Thanks a lot!

amiszuda commented 1 month ago

The first case falls outside of logg bounds the ck2004 models were calculated for. Try changing the atmosphere option to "blackbody" which should solve the issue.

aprsa commented 1 month ago

Just to corroborate what @amiszuda had said: indeed, ck2004 model atmospheres cover logg values up to 5.0. Thus, if you go above 5.0, you will not be able to use ck2004. That said, the upcoming phoebe release will feature extrapolation and gradual blending into the blackbody regime that will be particularly well suited for the example you mention here. If you want to try it out but don't want to wait till the official release, you can do so by checking out the feature-blending branch on github. Of course, all usual caveats apply: use extreme caution as this is not a formally released/supported version as of yet.

amiszuda commented 1 month ago

Good to hear from you @aprsa about the upcoming blending option - any informal info on when to expect them? Sorry for the offtopic, btw

MinyuLi commented 1 month ago

Thank you all for the answers! Follow the guide here: http://phoebe-project.org/docs/2.4/examples/extinction_wd_subdwarf I add the codes below. Then the logg can be greater than 5.0:

b.set_value_all('atm', component='primary', value='blackbody')
b.set_value_all('ld_mode', component='primary', value='manual')
b.set_value_all('ld_func', component='primary', value='quadratic')
b.set_value('ld_coeffs', component='primary', dataset='lc01', value=[0.2665,0.2544])
b.set_value_all('ld_mode_bol@primary','manual')
b.set_value_all('ld_func_bol@primary','quadratic')
b.set_value('ld_coeffs_bol', component='primary', value=[0.1421,0.3693])
b.set_value_all('atm', component='secondary', value='phoenix')
b.set_value('abun', component='secondary', value=-1.55)