Automatic Differentiation
 
Loading...
Searching...
No Matches

◆ corr_free()

template<typename T >
T stan::math::corr_free ( const T &  y)
inline

Return the unconstrained scalar that when transformed to a valid correlation produces the specified value.

This function inverts the transform defined for corr_constrain(T), which is the inverse hyperbolic tangent,

\( f^{-1}(y) = \mbox{atanh}\, y = \frac{1}{2} \log \frac{y + 1}{y - 1}\).

Template Parameters
TType of correlation
Parameters
[in]ycorrelation
Returns
free scalar that transforms to the specified input

Definition at line 28 of file corr_free.hpp.