1 #ifndef STAN_MATH_REV_MAT_FUN_TCROSSPROD_HPP 2 #define STAN_MATH_REV_MAT_FUN_TCROSSPROD_HPP 35 (M.rows() * M.cols()) *
sizeof(
vari*)));
37 for (
int m = 0; m < M.rows(); ++m)
38 for (
int n = 0; n < M.cols(); ++n)
39 vs[pos++] = M(m, n).vi_;
40 for (
int m = 0; m < M.rows(); ++m)
42 for (
int m = 0; m < M.rows(); ++m) {
43 for (
int n = 0; n < m; ++n) {
45 vs + m * M.cols(), vs + n * M.cols(), M.cols()));
46 MMt(n, m) = MMt(m, n);
The variable implementation base class.
static STAN_THREADS_DEF AutodiffStackStorage * instance_
Eigen::Matrix< fvar< T >, R, R > tcrossprod(const Eigen::Matrix< fvar< T >, R, C > &m)
Independent (input) and dependent (output) variables for gradients.
Eigen::Matrix< var, Eigen::Dynamic, Eigen::Dynamic > matrix_v
The type of a matrix holding var values.
void * alloc(size_t len)
Return a newly allocated block of memory of the appropriate size managed by the stack allocator...