1 //////////////////////////////////////////////////////////////////////////////////////
2 // This file is distributed under the University of Illinois/NCSA Open Source License.
3 // See LICENSE file in top directory for details.
4 //
5 // Copyright (c) 2016 Jeongnim Kim and QMCPACK developers.
6 //
7 // File developed by: Ye Luo, yeluo@anl.gov, Argonne National Laboratory
8 //
9 // File created by: Ye Luo, yeluo@anl.gov, Argonne National Laboratory
10 //////////////////////////////////////////////////////////////////////////////////////
11 
12 
13 #include "catch.hpp"
14 
15 #include "Numerics/Bessel.h"
16 
17 namespace qmcplusplus
18 {
19 TEST_CASE("Bessel", "[numerics]")
20 {
21   double bessel_array[100];
22   bessel_steed_array_cpu(10, 1.0, bessel_array);
23 
24   REQUIRE(bessel_array[0] == Approx(0.84147098480789650670));
25   REQUIRE(bessel_array[1] == Approx(0.30116867893975678925));
26   REQUIRE(bessel_array[3] == Approx(9.006581117112515480e-03));
27   REQUIRE(bessel_array[5] == Approx(9.256115861125815763e-05));
28   REQUIRE(bessel_array[7] == Approx(4.790134198739488623e-07));
29   REQUIRE(bessel_array[10] == Approx(7.116552640047313024e-11));
30 }
31 
32 } // namespace qmcplusplus
33