Peano
CCZ4Kernels.h
Go to the documentation of this file.
1 //
2 // ExaHyPE2 CCZ4 implementation
3 //
4 #pragma once
5 
6 
7 #include <cmath>
8 #include "tarch/tarch.h"
9 #include "tarch/CompilerSpecificSettings.h"
10 #include "tarch/multicore/multicore.h"
11 #include "tarch/accelerator/accelerator.h"
12 
13 
14 namespace applications {
15  namespace exahype2 {
16  namespace ccz4 {
17 
21  #if defined(WITH_OPENMP)
22  #pragma omp declare simd
23  #endif
24  static inline void ncp(double* BgradQ, const double* const Q, const double* const gradQSerialised, const int normal,
25  const int CCZ4LapseType,
26  const double CCZ4ds,
27  const double CCZ4c,
28  const double CCZ4e,
29  const double CCZ4f,
30  const double CCZ4bs,
31  const double CCZ4sk,
32  const double CCZ4xi,
33  const double CCZ4mu,
34  const double CCZ4SO
35  );
36 
53  #if defined(WITH_OPENMP)
54  #pragma omp declare simd
55  #endif
56  static inline void source(double* S, const double* const Q,
57  const int CCZ4LapseType,
58  const double CCZ4ds,
59  const double CCZ4c,
60  const double CCZ4e,
61  const double CCZ4f,
62  const double CCZ4bs,
63  const double CCZ4sk,
64  const double CCZ4xi,
65  const double CCZ4itau,
66  const double CCZ4eta,
67  const double CCZ4k1,
68  const double CCZ4k2,
69  const double CCZ4k3,
70  const double CCZ4SO
71  );
72 
73  #if defined(WITH_OPENMP)
74  #pragma omp declare simd
75  #endif
76  static inline double maxEigenvalue(
77  const double* const Q,
78  int normal,
79  const double CCZ4e,
80  const double CCZ4ds,
81  const double CCZ4GLMc,
82  const double CCZ4GLMd
83  );
84 
85 
89  #if defined(WITH_OPENMP)
90  #pragma omp declare simd
91  #endif
92  static inline double maxEigenvalue(
93  const double* const Q,
94  int normal,
95  const double CCZ4e,
96  const double CCZ4ds,
97  const double CCZ4GLMc,
98  const double CCZ4GLMd
99  );
100 
105  void admconstraints(double* constraints, const double* const Q, const double* const gradQSerialised);
106 
110  void ThetaOutputNCP(double* NCPterm, const double* const Q, const double* const gradQSerialised, int normal);
116  void TestingOutput(double* terms, const double* const Q, const double* const gradQSerialised);
117 
122  void Psi4Calc(double* Psi4, const double* const Q, const double* const gradQSerialised, double* coor);
123 
124 
132  void enforceCCZ4constraints(double* NOALIAS newQ);
133 
139  const double* NOALIAS oldQ,
140  double* NOALIAS dQdt,
141  double timeStepSize
142  );
143  }
144  }
145 }
146 
147 #include "CCZ4Kernels.cpph"
148 
149 
150 
constexpr double timeStepSize
list coor
Definition: CSVConvert.py:67
static void source(double *S, const double *const Q, const int CCZ4LapseType, const double CCZ4ds, const double CCZ4c, const double CCZ4e, const double CCZ4f, const double CCZ4bs, const double CCZ4sk, const double CCZ4xi, const double CCZ4itau, const double CCZ4eta, const double CCZ4k1, const double CCZ4k2, const double CCZ4k3, const double CCZ4SO)
The source term is one out of two terms that we use in our CCZ4 formulation.
static void ncp(double *BgradQ, const double *const Q, const double *const gradQSerialised, const int normal, const int CCZ4LapseType, const double CCZ4ds, const double CCZ4c, const double CCZ4e, const double CCZ4f, const double CCZ4bs, const double CCZ4sk, const double CCZ4xi, const double CCZ4mu, const double CCZ4SO)
void enforceCCZ4constraints(double *NOALIAS newQ)
A postprocessing routine which pushes the volume solution back into the area of the CCZ4 constraints.
void admconstraints(double *constraints, const double *const Q, const double *const gradQSerialised)
This is a postprocessing routine to monitor if the physical constraints are fulfilled.
void TestingOutput(double *terms, const double *const Q, const double *const gradQSerialised)
A temporary test function, to output some testing values 0,1 entries: Hamilton constraint related ter...
void Psi4Calc(double *Psi4, const double *const Q, const double *const gradQSerialised, double *coor)
This function is for the calculation of psi4, a quantity related to gravitional wave.
static double maxEigenvalue(const double *const Q, int normal, const double CCZ4e, const double CCZ4ds, const double CCZ4GLMc, const double CCZ4GLMd)
void ThetaOutputNCP(double *NCPterm, const double *const Q, const double *const gradQSerialised, int normal)
A temporary test function, to output Hamilton constraint related term in theta, 1 terms: RPlusTwoNabl...
This code is taken from the original ExaHyPE project written by colleagues from the University of Tre...
Definition: CCZ4Kernels.h:14
Definition: ccz4.py:1