QMCPACK
TestGetVecRngComplex< T > Struct Template Reference
+ Inheritance diagram for TestGetVecRngComplex< T >:
+ Collaboration diagram for TestGetVecRngComplex< T >:

Public Types

using ref = RngReferenceVector< T >
 
using VT = typename T::value_type
 

Public Member Functions

void operator() ()
 

Detailed Description

template<typename T>
struct qmcplusplus::TestGetVecRngComplex< T >

Definition at line 147 of file test_RandomForTest.cpp.

Member Typedef Documentation

◆ ref

using ref = RngReferenceVector<T>

Definition at line 149 of file test_RandomForTest.cpp.

◆ VT

using VT = typename T::value_type

Definition at line 150 of file test_RandomForTest.cpp.

Member Function Documentation

◆ operator()()

void operator() ( )
inline

Definition at line 152 of file test_RandomForTest.cpp.

References qmcplusplus::Units::distance::A, B(), qmcplusplus::CHECK(), qmcplusplus::checkArray, RandomForTest< VT >::getRngVecComplex(), and qmcplusplus::n.

153  {
154  using ref = RngReferenceVector<T>;
155  testing::RandomForTest<VT> rng_for_test;
156  std::vector<T> rng_vector = rng_for_test.getRngVecComplex(2);
157  auto checkArray = [](auto A, auto B, int n) {
158  for (int i = 0; i < n; ++i)
159  {
160  CHECK(A[i] == ComplexApprox(B[i]));
161  }
162  };
163  checkArray(rng_vector.data(), ref::vec.data(), 2);
164  }
CHECK(log_values[0]==ComplexApprox(std::complex< double >{ 5.603777579195571, -6.1586603331188225 }))
double B(double x, int k, int i, const std::vector< double > &t)

The documentation for this struct was generated from the following file: