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

◆ identity_constrain()

template<bool Jacobian = false, typename T , typename... Types, require_all_not_var_matrix_t< T, Types... > * = nullptr>
auto stan::math::identity_constrain ( T &&  x,
Types &&  ... 
)
inline

Returns the result of applying the identity constraint transform to the input.

This promotes the input to the least upper bound of the input types.

Template Parameters
Jacobianif true, increment log density accumulator with log absolute Jacobian determinant of constraining transform
Ttype of value to promote
TypesOther types.
Parameters
[in]xobject
Returns
transformed input

This specialization handles convert Eigen matrices of doubles to var matrix types.

Template Parameters
TAny type.
TypesAny type with one of T and Types being a var_value matrix.
Parameters
[in]xobject
Returns
transformed input

Definition at line 23 of file identity_constrain.hpp.