create_timesteps_array

legwork.evol.create_timesteps_array(a_i, beta, ecc_i=None, t_evol=None, n_step=100, timesteps=None)[source]

Create an array of timesteps

Parameters
a_ifloat/array

Initial semi-major axis

betafloat/array

Constant defined in Peters and Mathews (1964) Eq. 5.9. See legwork.utils.beta()

ecc_ifloat/array

Initial eccentricity

t_evolfloat/array

Amount of time for which to evolve each binaries. Required if timesteps is None. If None, then defaults to merger times.

n_stepsint

Number of timesteps to take between t=0 and t=``t_evol``. Required if timesteps is None. Defaults to 100.

timestepsfloat/array

Array of exact timesteps to output when evolving each binary. Must be monotonically increasing and start with t=0. Either supply a 1D array to use for every binary or a 2D array that has a different array of timesteps for each binary. timesteps is used in place of t_evol and n_steps and takes precedence over them. Note that these are not the timesteps that will be taken whilst the sources are evolved since these are determined adaptively during the integration by scipy’s odeint

Returns
timestepsfloat/array

Array of timesteps for each binary