]>
git.proxmox.com Git - ceph.git/blob - ceph/src/boost/libs/math/test/compile_test/naive_monte_carlo_incl_test.cpp
2 * Copyright Nick Thompson, 2017
3 * Use, modification and distribution are subject to the
4 * Boost Software License, Version 1.0. (See accompanying file
5 * LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
9 #pragma warning(disable:4459)
12 #if !defined(_MSC_VER) || (_MSC_VER >= 1900)
14 #include <boost/math/quadrature/naive_monte_carlo.hpp>
15 #include "test_compile_result.hpp"
17 using boost::math::quadrature::naive_monte_carlo
;
18 void compile_and_link_test()
20 auto g
= [&](std::vector
<double> const & x
)
24 std::vector
<std::pair
<double, double>> bounds
{{0, 1}, {0, 1}, {0, 1}};
25 naive_monte_carlo
<double, decltype(g
)> mc(g
, bounds
, 1.0);
27 auto task
= mc
.integrate();
28 check_result
<double>(task
.get());
32 void compile_and_link_test()