1 #ifndef STAN_MATH_PRIM_MAT_FUN_PROMOTE_ELEMENTS_HPP 2 #define STAN_MATH_PRIM_MAT_FUN_PROMOTE_ELEMENTS_HPP 19 template <
typename T,
typename S,
int R,
int C>
21 Eigen::Matrix<S, R, C> > {
28 inline static Eigen::Matrix<T, R, C>
29 promote(
const Eigen::Matrix<S, R, C>& u) {
30 Eigen::Matrix<T, Eigen::Dynamic, Eigen::Dynamic> t(u.rows(), u.cols());
31 for (
int i = 0; i < u.size(); ++i)
44 template <
typename T,
int R,
int C>
46 Eigen::Matrix<T, R, C> > {
53 inline static const Eigen::Matrix<T, R, C>&
54 promote(
const Eigen::Matrix<T, R, C>& u) {
(Expert) Numerical traits for algorithmic differentiation variables.