Automatic Differentiation
 
Loading...
Searching...
No Matches
identity_constrain.hpp
Go to the documentation of this file.
1#ifndef STAN_MATH_PRIM_CONSTRAINT_IDENTITY_CONSTRAIN_HPP
2#define STAN_MATH_PRIM_CONSTRAINT_IDENTITY_CONSTRAIN_HPP
3
5
6namespace stan {
7namespace math {
8
21template <bool Jacobian = false, typename T, typename... Types,
22 require_all_not_var_matrix_t<T, Types...>* = nullptr>
23inline auto identity_constrain(T&& x, Types&&... /* args */) {
24 return promote_scalar_t<return_type_t<T, Types...>, T>(x);
25}
26
27} // namespace math
28} // namespace stan
29
30#endif
typename return_type< Ts... >::type return_type_t
Convenience type for the return type of the specified template parameters.
require_all_not_t< is_var_matrix< std::decay_t< Types > >... > require_all_not_var_matrix_t
Require none of the types satisfy is_var_matrix.
typename promote_scalar_type< std::decay_t< T >, std::decay_t< S > >::type promote_scalar_t
auto identity_constrain(T &&x, Types &&...)
Returns the result of applying the identity constraint transform to the input.
The lgamma implementation in stan-math is based on either the reentrant safe lgamma_r implementation ...