Open maxbriel opened 8 months ago
Small update: This also occurs for some BHs.
Adding an update: I have also noticed this behavior is happening for ECSN when use_interp_values = True
. This is causing problems later in the evolution, because the resulting NS masses are NaN, which is crashing the evolution in the detached step.
@philipp-rajah Here's a full example. I've send you the population.ini
import numpy as np
import os
from posydon.config import PATH_TO_POSYDON, PATH_TO_POSYDON_DATA
import pandas as pd
from posydon.binary_evol.binarystar import BinaryStar, SingleStar
from posydon.binary_evol.simulationproperties import SimulationProperties
from posydon.popsyn.io import simprop_kwargs_from_ini
sim_kwargs = simprop_kwargs_from_ini('population.ini', verbose=True)
metallicity = {'metallicity':1}
sim_kwargs['step_HMS_HMS'][1].update(metallicity)
sim_kwargs['step_CO_HeMS'][1].update(metallicity)
sim_kwargs['step_CO_HMS_RLO'][1].update(metallicity)
sim_kwargs['step_CO_HeMS_RLO'][1].update(metallicity)
sim_kwargs['step_detached'][1].update(metallicity)
sim_kwargs['step_disrupted'][1].update(metallicity)
sim_kwargs['step_merged'][1].update(metallicity)
sim_kwargs['step_initially_single'][1].update(metallicity)
sim_pop = SimulationProperties(**sim_kwargs)
sim_pop.load_steps(verbose=False)
STAR1 = SingleStar(**{'mass': 7.592921,
'state': 'H-rich_Core_H_burning'})
STAR2 = SingleStar(**{'mass':5.038679 ,
'state': 'H-rich_Core_H_burning'})
BINARY = BinaryStar(STAR1, STAR2,
**{'time': 0.0, 'state': 'detached', 'event': 'ZAMS', 'orbital_period':5.537807, 'eccentricity': 0.0},
properties = sim_pop)
BINARY.evolve()
As we discussed, we could think of combining the classifiers for SN_type and CO_type into one, which avoids undefined combinations. A deeper thought brought me to the point, that this won't necessarily help us to infer the interpolation class better:
We decided to implement a 'quick fix' for the issue to push the system into the manual remnant mass calculation, if SN_type and CO_type do not match.
However, this is not the preferred solution. It's preferred to solve the issue at the interpolator.
@mkruckow I do not get any out of hull warnings for the example binary above.
For systems with state=NS and SN_Type=WD, no mass is present in the MODELxx. Is this expected behaviour for the models, when the state and SN type do not match?
Should we recalculate the mass with the state/SN_type based on the preSN model parameters?