Feature branch (on math):
https://github.com/stan-dev/math/tree/feature/issue-191-gp-squared_exponential
If anyone wants to help, we need to add tests for derivatives in rev, fwd, and mix for the function. The implementation should be complete now.
To add this to the Stan language, it's going to be straightforward. We just need to add these function signatures:
1. matrix cov_sq_exp(real[], real, real)
2. matrix cov_sq_exp(vector[], real, real)
3. matrix cov_sq_exp(row_vector[], real, real)
4. matrix cov_sq_exp(matrix[], real, real)
5. matrix cov_sq_exp(real[], real[], real, real)
6. matrix cov_sq_exp(vector[], vector[], real, real)
7. matrix cov_sq_exp(row_vector[], row_vector[], real, real)
8. matrix cov_sq_exp(matrix[], matrix[], real, real)
I just want to make sure it's tested under those signatures in the math library before propagating all the way through to develop. After tests are in, we can do some custom gradients instead of relying on autodiff.
Also, I had been thinking about extending for:
- sigma: real[]
- length scale: real[] or vector or matrix.
But, I want to wait for the first implementation to go out.
Daniel