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

◆ diag_matrix() [3/3]

template<typename EigVec , require_eigen_vector_t< EigVec > * = nullptr>
Eigen::Matrix< value_type_t< EigVec >, Eigen::Dynamic, Eigen::Dynamic > stan::math::diag_matrix ( const EigVec &  v)
inline

Return a square diagonal matrix with the specified vector of coefficients as the diagonal values.

Template Parameters
EigVectype of the vector (must be derived from Eigen::MatrixBase and have one compile time dimmension equal to 1)
Parameters
[in]vSpecified vector.
Returns
Diagonal matrix with vector as diagonal values.

Definition at line 21 of file diag_matrix.hpp.