cosmic.checkstate.set_checkstates(timestep_conditions=[])[source]

Set the time resolution of the bcm array for different states of the evolution

Parameters:
timestep_conditionslist, optional

A nested list of conditions and the time resolution (dtp, in Myr) to use when they are met, e.g.

>>> timestep_conditions = [['20.0<mass_1<25.5', '15.5>mass_2>10.0', 'dtp=1.0'],
...                        ['kstar_1=14', 'lum_1>10.0', 'kstar_2!=13', 'dtp=0.01'],
...                        ['2>=binstate>=1', 'dtp=None']]

Each sublist contains exactly one dtp and any number of conditions, which are combined in an AND fashion. Supported operators are =, !=, <, <=, > and >=. A column can have both a lower and upper bound, given either as a chained comparison or as two separate conditions, plus one !=. A sublist with only a dtp always applies, and if several sublists apply then the last one is used. dtp=None ends the time resolution so that only the final state is printed. Default is an empty list (no dynamic dtp setting).

Raises:
ValueError

If more than 15 sublists are given, a column is not in CHECKSTATE_COLUMNS, an operator is not supported, the same bound is set twice for a column in one sublist, or a sublist does not have exactly one valid dtp