I have a function defined in a C header file, where the array of m_parameters[] is defined elsewhere (just a list of numbers):
inline double Par3D::getValue(const double& x, const double& t ) const { double g1 = m_parameters[3] + m_parameters[4]*TMath::ATan(m_parameters[5]*(t-0.3)) ; double g0 = m_parameters[0] + m_parameters[1]*TMath::ATan(m_parameters[2]*(t-0.3)) ; return g0 + g1*TMath::ATan(m_parameters[6]*(x-0.3)) ; } This function is called repeatedly in a larger program. I get different results if I just put the expressions for g0 and g1 directly in the argument of the return. Is that to be expected?
Many thanks.