Stan Math Library
4.9.0
Automatic Differentiation
|
Eigen::Matrix< return_type_t< T_x, T_sigma >, Eigen::Dynamic, Eigen::Dynamic > stan::math::gp_dot_prod_cov | ( | const std::vector< T_x > & | x, |
const T_sigma & | sigma | ||
) |
Returns a dot product covariance matrix.
A member of Stan's Gaussian Process Library.
\(k(x,x') = \sigma^2 + x \cdot x'\)
A dot product covariance matrix is the same covariance matrix as in bayesian regression with \(N(0,1)\) priors on regression coefficients and a \(N(0,\sigma^2)\) prior on the constant function. See Rasmussen and Williams et al 2006, Chapter 4.
T_x | type of std::vector of double |
T_sigma | type of sigma |
x | std::vector of elements that can be used in transpose and multiply This function assumes each element of x is the same size. |
sigma | constant function that can be used in stan::math::square |
std::domain_error | if sigma < 0, nan, inf or x is nan or infinite |
Definition at line 100 of file gp_dot_prod_cov.hpp.