Loading [MathJax]/extensions/TeX/AMSsymbols.js
Automatic Differentiation
 
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
Loading...
Searching...
No Matches

◆ ub_constrain() [12/14]

template<typename T , typename U , typename Lp , require_convertible_t< return_type_t< T, U >, Lp > * = nullptr>
auto stan::math::ub_constrain ( const std::vector< T > &  x,
const std::vector< U > &  ub,
Lp &  lp 
)
inline

Specialization of ub_constrain to apply a container of upper bounds elementwise to each input element.

Template Parameters
TA Any type with a Scalar scalar_type.
UA type inheriting from EigenBase or a standard vector.
LpScalar, should be convertable from T and the scalar type of U
Parameters
[in]xunconstrained input
[in]ubupper bound on output
[in,out]lpreference to log probability to increment
Returns
lower-bound constrained value corresponding to inputs

Definition at line 232 of file ub_constrain.hpp.