1#ifndef STAN_MATH_PRIM_FUN_MDIVIDE_RIGHT_SPD_HPP
2#define STAN_MATH_PRIM_FUN_MDIVIDE_RIGHT_SPD_HPP
26template <
typename EigMat1,
typename EigMat2,
27 require_all_eigen_t<EigMat1, EigMat2>* =
nullptr>
28inline Eigen::Matrix<return_type_t<EigMat1, EigMat2>,
29 EigMat1::RowsAtCompileTime, EigMat2::ColsAtCompileTime>
31 static constexpr const char* function =
"mdivide_right_spd";
33 const auto& A_ref =
to_ref(A);
void check_symmetric(const char *function, const char *name, const matrix_cl< T > &y)
Check if the matrix_cl is symmetric.
Eigen::Matrix< return_type_t< EigMat1, EigMat2 >, EigMat1::RowsAtCompileTime, EigMat2::ColsAtCompileTime > mdivide_right_spd(const EigMat1 &b, const EigMat2 &A)
Returns the solution of the system xA=b where A is symmetric positive definite.
void check_multiplicable(const char *function, const char *name1, const T1 &y1, const char *name2, const T2 &y2)
Check if the matrices can be multiplied.
Eigen::Matrix< return_type_t< EigMat1, EigMat2 >, EigMat1::RowsAtCompileTime, EigMat2::ColsAtCompileTime > mdivide_left_spd(const EigMat1 &A, const EigMat2 &b)
Returns the solution of the system Ax=b where A is symmetric positive definite.
ref_type_t< T && > to_ref(T &&a)
This evaluates expensive Eigen expressions.
void check_not_nan(const char *function, const char *name, const T_y &y)
Check if y is not NaN.
The lgamma implementation in stan-math is based on either the reentrant safe lgamma_r implementation ...