Automatic Differentiation
 
Loading...
Searching...
No Matches
integrate_1d_adapter.hpp
Go to the documentation of this file.
1#ifndef STAN_MATH_PRIM_FUNCTOR_INTEGRATE_1D_ADAPTER_HPP
2#define STAN_MATH_PRIM_FUNCTOR_INTEGRATE_1D_ADAPTER_HPP
3
4#include <ostream>
5#include <vector>
6
13template <typename F>
15 const F& f_;
16
17 explicit integrate_1d_adapter(const F& f) : f_(f) {}
18
19 template <typename T_a, typename T_b, typename T_theta>
20 auto operator()(const T_a& x, const T_b& xc, std::ostream* msgs,
21 const std::vector<T_theta>& theta,
22 const std::vector<double>& x_r,
23 const std::vector<int>& x_i) const {
24 return f_(x, xc, theta, x_r, x_i, msgs);
25 }
26};
27
28#endif
auto operator()(const T_a &x, const T_b &xc, std::ostream *msgs, const std::vector< T_theta > &theta, const std::vector< double > &x_r, const std::vector< int > &x_i) const
Adapt the non-variadic integrate_1d arguments to the variadic integrate_1d_impl interface.