Stan Math Library
4.9.0
Automatic Differentiation
Loading...
Searching...
No Matches
diagonal.hpp
Go to the documentation of this file.
1
#ifndef STAN_MATH_PRIM_FUN_DIAGONAL_HPP
2
#define STAN_MATH_PRIM_FUN_DIAGONAL_HPP
3
4
#include <
stan/math/prim/fun/Eigen.hpp
>
5
#include <
stan/math/prim/meta.hpp
>
6
7
namespace
stan
{
8
namespace
math {
9
18
template
<
typename
T, require_matrix_t<T>* =
nullptr
>
19
inline
auto
diagonal
(
const
T& m) {
20
return
m.diagonal();
21
}
22
23
}
// namespace math
24
}
// namespace stan
25
26
#endif
Eigen.hpp
stan::math::diagonal
auto diagonal(T &&a)
Diagonal of a kernel generator expression.
Definition
diagonal.hpp:136
stan
The lgamma implementation in stan-math is based on either the reentrant safe lgamma_r implementation ...
Definition
unit_vector_constrain.hpp:15
meta.hpp
stan
math
prim
fun
diagonal.hpp
[
Stan Home Page
]
© 2011–2019, Stan Development Team.