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

◆ cov_matrix_constrain() [2/5]

template<typename T , require_eigen_col_vector_t< T > * = nullptr>
Eigen::Matrix< value_type_t< T >, Eigen::Dynamic, Eigen::Dynamic > stan::math::cov_matrix_constrain ( const T &  x,
Eigen::Index  K,
return_type_t< T > &  lp 
)
inline

Return the symmetric, positive-definite matrix of dimensions K by K resulting from transforming the specified finite vector of size K plus (K choose 2).

Template Parameters
Ttype of the vector (must be derived from Eigen::MatrixBase and have one compile-time dimension equal to 1)
Parameters
xThe vector to convert to a covariance matrix.
KThe dimensions of the resulting covariance matrix.
lpReference
Exceptions
std::domain_errorif (x.size() != K + (K choose 2)).

Definition at line 65 of file cov_matrix_constrain.hpp.