Opm::utils Namespace Reference
Function Documentation◆ arithmeticAverage()
template<typename T , typename Tresult >
Computes the arithmetic average: a_A(t_1, t_2) = (t_1 + t_2)/2. Referenced by Opm::EulerUpstreamResidualDetails::UpdateForCell< UpstreamSolver, PressureSolution >::operator()(). ◆ geometricAverage()
template<typename T >
Computes the geometric average: a_G(t_1, t_2) = \sqrt{t_1 t_2}. Since we use std::sqrt(), this function will only compile when T is convertible to and from double. ◆ harmonicAverage()
template<typename T >
Computes the harmonic average: a_H(t_1, t_2) = \frac{2}{1/t_1 + 1/t_2} = \frac{2 t_1 t_2}{t_1 + t_2}. |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||