pub fn d_i_m_t_0_i<T: Num>(q: R, p: R, m: T, beta: R) -> C