1 #ifndef STAN_MATH_REV_SCAL_FUN_LGAMMA_HPP
2 #define STAN_MATH_REV_SCAL_FUN_LGAMMA_HPP
6 #include <boost/math/special_functions/digamma.hpp>
7 #include <boost/math/special_functions/gamma.hpp>
14 class lgamma_vari :
public op_v_vari {
16 lgamma_vari(
double value, vari* avi) :
17 op_v_vari(value, avi) {
37 return var(
new lgamma_vari(lgamma_a, a.
vi_));
fvar< T > lgamma(const fvar< T > &x)
Independent (input) and dependent (output) variables for gradients.
var lgamma(const var &a)
The log gamma function for variables (C99).
vari * vi_
Pointer to the implementation of this variable.
double val() const
Return the value of this variable.
fvar< T > digamma(const fvar< T > &x)