Automatic Differentiation
 
Loading...
Searching...
No Matches
operator_divide_equal.hpp
Go to the documentation of this file.
1#ifndef STAN_MATH_REV_CORE_OPERATOR_DIVIDE_EQUAL_HPP
2#define STAN_MATH_REV_CORE_OPERATOR_DIVIDE_EQUAL_HPP
3
7
8namespace stan {
9namespace math {
10template <typename T>
12 const var_value<T>& b) {
13 vi_ = divide(*this, b).vi_;
14 return *this;
15}
16
17template <typename T>
19 T b) {
20 if (b == 1.0) {
21 return *this;
22 }
23 vi_ = divide(*this, b).vi_;
24 return *this;
25}
26
27template <typename T>
28inline var_value<T>&
30 const var_value<T>& b) {
31 vi_ = divide(*this, b).vi_;
32 return *this;
33}
34
35template <typename T>
36inline var_value<T>&
38 if (b == 1.0) {
39 return *this;
40 }
41 vi_ = divide(*this, b).vi_;
42 return *this;
43}
44
45} // namespace math
46} // namespace stan
47#endif
auto divide(T_a &&a, double d)
Returns the elementwise division of the kernel generator expression.
Definition divide.hpp:20
The lgamma implementation in stan-math is based on either the reentrant safe lgamma_r implementation ...
Definition fvar.hpp:9