Stan Math Library
5.0.0
Automatic Differentiation
|
#include <stan/math/rev/meta.hpp>
#include <stan/math/rev/core.hpp>
#include <stan/math/prim/fun/Eigen.hpp>
#include <stdexcept>
#include <vector>
Go to the source code of this file.
Namespaces | |
namespace | stan |
The lgamma implementation in stan-math is based on either the reentrant safe lgamma_r implementation from C or the boost::math::lgamma implementation. | |
namespace | stan::math |
Matrices and templated mathematical functions. | |
Functions | |
template<typename F > | |
void | stan::math::gradient (const F &f, const Eigen::Matrix< double, Eigen::Dynamic, 1 > &x, double &fx, Eigen::Matrix< double, Eigen::Dynamic, 1 > &grad_fx) |
Calculate the value and the gradient of the specified function at the specified argument. | |
template<typename F , typename EigVec , typename InputIt , require_eigen_vector_vt< std::is_arithmetic, EigVec > * = nullptr> | |
void | stan::math::gradient (const F &f, const EigVec &x, double &fx, InputIt first_grad_fx, InputIt last_grad_fx) |
Calculate the value and the gradient of the specified function at the specified argument. | |