Template Function GridKit::Math::ramp
Defined in File CommonMath.hpp
Function Documentation
-
template<class ScalarT>
inline ScalarT GridKit::Math::ramp(const ScalarT x) Smooth one-sided ramp function.
Smooth approximation to max(x, 0), using a stable softplus form with the same scale as the rest of CommonMath.
- Template Parameters:
ScalarT – - scalar data type
- Parameters:
x – [in] - expected to be of order 1
- Returns:
value of the smooth ramp function