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

◆ positive_free()

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

Return the unconstrained value corresponding to the specified positive-constrained value.

The transform is the inverse of the transform \(f\) applied by positive_constrain(T), namely

\(f^{-1}(x) = \log(x)\).

The input is validated using check_positive().

Parameters
yInput scalar.
Returns
Unconstrained value that produces the input when constrained.
Template Parameters
TType of scalar.
Exceptions
std::domain_errorif the variable is negative

Definition at line 29 of file positive_free.hpp.