5constexpr double Pi = 3.14159265358979;
7int main(
int argc,
char **argv) {
12 test_setup(argc, argv);
17 for (
int iter = 0; iter < 3; iter++) {
25 p2[{0,0,0,0}] = lattice.volume();
34 if (fabs(sum) < 1e-10) {
37 hila::out0 <<
"First FFT FAILED; limit 1e-10" << std::endl;
41 f2[
ALL] = lattice.volume();
52 if (fabs(sum / tnorm) < 1e-10) {
55 hila::out0 <<
"Second FFT FAILED, limit 1e-10" << std::endl;
60 double d = X.coordinate(e_x)*2.0*Pi/lattice.size(e_x);
67 p2[{1,0,0,0}] = lattice.volume();
73 if (fabs(sum) > 1e-10) {
hila::arithmetic_type< T > squarenorm(const Array< n, m, T > &rhs)
Return square norm of Array.
Array< n, m, T > cos(Array< n, m, T > a)
Cosine.
Array< n, m, T > sin(Array< n, m, T > a)
Sine.
The field class implements the standard methods for accessing Fields. Hilapp replaces the parity acce...
double squarenorm() const
Squarenorm.
constexpr Parity ALL
bit pattern: 011
void FFT_field(const Field< T > &input, Field< T > &result, const CoordinateVector &directions, fft_direction fftdir=fft_direction::forward)
std::ostream out0
This writes output only from main process (node 0)
void finishrun()
Normal, controlled exit - all nodes must call this. Prints timing information and information about c...