XGCa
field.hpp
Go to the documentation of this file.
1 #ifndef FIELD_HPP
2 #define FIELD_HPP
3 #include "space_settings.hpp"
4 #include "NamelistReader.hpp"
5 
6 #include "globals.hpp"
7 #include "gyro_radius.hpp"
8 
9 /* VarType specifies whether the field is a vector, a 2D vector, or a scalar
10  * */
11 enum class VarType{
12  Vector,
13  Vector2D,
14  Scalar
15 };
16 
17 /* Compile-time function to use 2D vector if field-following planes are not used (i.e. XGCa) */
18 template<PhiInterpType PIT> constexpr VarType vec2d_if_axisym();
19 template<> constexpr VarType vec2d_if_axisym<PhiInterpType::Planes>(){return VarType::Vector;}
20 template<> constexpr VarType vec2d_if_axisym<PhiInterpType::None>(){return VarType::Vector2D;}
21 
22 /* Coordinate correction for field interpolations */
24  const double gamma_psi;
25 
26  public:
27  double r0;
28  double r1;
29  double z0;
30  double z1;
31 
32  KOKKOS_INLINE_FUNCTION FieldCorrection(const SimdVector2D& gradpsi, int i_simd)
33  : gamma_psi(1.0/gradpsi.magnitude(i_simd)) {}
34 
35  KOKKOS_INLINE_FUNCTION void set(int i_simd, double basis, const SimdVector2D &gradpsi){
36  r0 = basis + (1.0-basis) * gamma_psi * gradpsi.r[i_simd];
37  r1 = (1.0-basis) * gamma_psi * gradpsi.z[i_simd];
38  z0 = (1.0-basis) * gamma_psi *(-gradpsi.z[i_simd]);
39  z1 = basis + (1.0-basis) * gamma_psi * gradpsi.r[i_simd];
40  }
41 };
42 
43 
44 template<VarType VT, PhiInterpType PIT>
45 struct Field{};
46 
47 //Struct used for E_phi_ff, dAs_phi_ff, dAh_phi_ff, As_phi_ff, Ah_phi_ff. 3 vector components, 2 contributing planes
48 template<>
50  double V[3][2];
51 
52  static constexpr PhiInterpType PIT = PhiInterpType::Planes;
53  static constexpr VarType VT = VarType::Vector;
54 
55  static constexpr int NDIM(){return 3;}
56  static constexpr int NPHI(){return 2;}
57  static constexpr int SIZE(){return NDIM()*NPHI();}
58 
66  KOKKOS_INLINE_FUNCTION void gather(SimdVector& vec, int i_simd, double wp, const SimdPhiWeights<get_phi_wt_usage(PIT)>& phi_wts, const FieldCorrection& corr) const{
67  const double& phi_w0 = phi_wts.phi.w[0][i_simd];
68  const double& phi_w1 = phi_wts.phi.w[1][i_simd];
69  vec.r[i_simd] += wp*(phi_w0*( corr.r0*V[PIR][0] + corr.z0*V[PIZ][0] )
70  + phi_w1*( corr.r0*V[PIR][1] + corr.z0*V[PIZ][1] ) );
71  vec.z[i_simd] += wp*(phi_w0*( corr.r1*V[PIR][0] + corr.z1*V[PIZ][0] )
72  + phi_w1*( corr.r1*V[PIR][1] + corr.z1*V[PIZ][1] ) );
73  vec.phi[i_simd] += wp*(phi_w0* V[PIP][0]
74  + phi_w1* V[PIP][1] );
75  }
76 
85  KOKKOS_INLINE_FUNCTION void gather(SimdVector& vec, int i_simd, double wp, const SimdGyroWeights<GyroKin>& rho_wts, const SimdPhiWeights<get_phi_wt_usage(PIT)>& phi_wts, const FieldCorrection& corr, const Field<VarType::Vector,PhiInterpType::Planes>& field2) const{
86  const double& phi_w0 = phi_wts.phi.w[0][i_simd];
87  const double& phi_w1 = phi_wts.phi.w[1][i_simd];
88 #ifdef NEWGYROMATRIX
89  const double& rho_w00 = rho_wts.rho_wts[0].w[0][i_simd];
90  const double& rho_w01 = rho_wts.rho_wts[0].w[1][i_simd];
91  const double& rho_w10 = rho_wts.rho_wts[1].w[0][i_simd];
92  const double& rho_w11 = rho_wts.rho_wts[1].w[1][i_simd];
93 #else
94  const double& rho_w00 = rho_wts.rho_wts.w[0][i_simd];
95  const double& rho_w01 = rho_wts.rho_wts.w[1][i_simd];
96  const double& rho_w10 = rho_wts.rho_wts.w[0][i_simd]; // = w00
97  const double& rho_w11 = rho_wts.rho_wts.w[1][i_simd]; // = w01
98 #endif
99 
100  vec.r[i_simd] += wp*(phi_w0*( corr.r0*(rho_w00*V[PIR][0] + rho_w01*field2.V[PIR][0])
101  + corr.z0*(rho_w00*V[PIZ][0] + rho_w01*field2.V[PIZ][0]) )
102  + phi_w1*( corr.r0*(rho_w10*V[PIR][1] + rho_w11*field2.V[PIR][1])
103  + corr.z0*(rho_w10*V[PIZ][1] + rho_w11*field2.V[PIZ][1]) ) );
104  vec.z[i_simd] += wp*(phi_w0*( corr.r1*(rho_w00*V[PIR][0] + rho_w01*field2.V[PIR][0])
105  + corr.z1*(rho_w00*V[PIZ][0] + rho_w01*field2.V[PIZ][0]) )
106  + phi_w1*( corr.r1*(rho_w10*V[PIR][1] + rho_w11*field2.V[PIR][1])
107  + corr.z1*(rho_w10*V[PIZ][1] + rho_w11*field2.V[PIZ][1]) ) );
108  vec.phi[i_simd] += wp*(phi_w0* (rho_w00*V[PIP][0] + rho_w01*field2.V[PIP][0])
109  + phi_w1* (rho_w10*V[PIP][1] + rho_w11*field2.V[PIP][1]) );
110  }
111 };
112 
113 // Returns false if any value is not finite
114 KOKKOS_INLINE_FUNCTION bool isfinite(const Field<VarType::Vector,PhiInterpType::Planes>& f){
115  return (isfinite(f.V[0][0]) && isfinite(f.V[0][1]) && isfinite(f.V[1][0]) &&
116  isfinite(f.V[1][1]) && isfinite(f.V[2][0]) && isfinite(f.V[2][1]));
117 }
118 
119 //Struct used for E00_ff. 2 vector components, 2 contributing planes
120 template<>
122  double V[2][2];
123 
124  static constexpr PhiInterpType PIT = PhiInterpType::Planes;
125  static constexpr VarType VT = VarType::Vector2D;
126 
127  static constexpr int NDIM(){return 2;}
128  static constexpr int NPHI(){return 2;}
129  static constexpr int SIZE(){return NDIM()*NPHI();}
130 
138  KOKKOS_INLINE_FUNCTION void gather(SimdVector& vec, int i_simd, double wp, const SimdPhiWeights<get_phi_wt_usage(PIT)>& phi_wts, const FieldCorrection& corr) const{
139  const double& phi_w0 = phi_wts.phi.w[0][i_simd];
140  const double& phi_w1 = phi_wts.phi.w[1][i_simd];
141  vec.r[i_simd] += wp*(phi_w0*( corr.r0*V[PIR][0] + corr.z0*V[PIZ][0] )
142  + phi_w1*( corr.r0*V[PIR][1] + corr.z0*V[PIZ][1] ) );
143  vec.z[i_simd] += wp*(phi_w0*( corr.r1*V[PIR][0] + corr.z1*V[PIZ][0] )
144  + phi_w1*( corr.r1*V[PIR][1] + corr.z1*V[PIZ][1] ) );
145  }
146 };
147 
148 //Struct used for ddpotdt_phi_ff, As_phi_ff, Ah_phi_ff for EM. 2 contributing planes
149 template<>
151  double S[2];
152 
153  static constexpr PhiInterpType PIT = PhiInterpType::Planes;
154  static constexpr VarType VT = VarType::Scalar;
155 
156  static constexpr int NDIM(){return 1;}
157  static constexpr int NPHI(){return 2;}
158  static constexpr int SIZE(){return NDIM()*NPHI();}
159 
166  KOKKOS_INLINE_FUNCTION void gather(Simd<double>& sca, int i_simd, double wp, const SimdPhiWeights<get_phi_wt_usage(PIT)>& phi_wts) const{
167  const double& phi_w0 = phi_wts.phi.w[0][i_simd];
168  const double& phi_w1 = phi_wts.phi.w[1][i_simd];
169  sca[i_simd] += wp* ( phi_w0*S[0] + phi_w1*S[1] );
170  }
171 
179  KOKKOS_INLINE_FUNCTION void gather(Simd<double>& sca, int i_simd, double wp, const SimdGyroWeights<GyroKin>& rho_wts, const SimdPhiWeights<get_phi_wt_usage(PIT)>& phi_wts, const Field<VarType::Scalar,PhiInterpType::Planes>& field2) const{
180  const double& phi_w0 = phi_wts.phi.w[0][i_simd];
181  const double& phi_w1 = phi_wts.phi.w[1][i_simd];
182 #ifdef NEWGYROMATRIX
183  const double& rho_w00 = rho_wts.rho_wts[0].w[0][i_simd];
184  const double& rho_w01 = rho_wts.rho_wts[0].w[1][i_simd];
185  const double& rho_w10 = rho_wts.rho_wts[1].w[0][i_simd];
186  const double& rho_w11 = rho_wts.rho_wts[1].w[1][i_simd];
187 #else
188  const double& rho_w00 = rho_wts.rho_wts.w[0][i_simd];
189  const double& rho_w01 = rho_wts.rho_wts.w[1][i_simd];
190  const double& rho_w10 = rho_wts.rho_wts.w[0][i_simd]; // = w00
191  const double& rho_w11 = rho_wts.rho_wts.w[1][i_simd]; // = w01
192 #endif
193 
194  sca[i_simd] += wp* ( phi_w0*rho_w00*S[0]
195  + phi_w1*rho_w10*S[1]
196  + phi_w0*rho_w01*field2.S[0]
197  + phi_w1*rho_w11*field2.S[1]);
198  }
199 
200  // Scatter
201  KOKKOS_INLINE_FUNCTION void scatter(const SimdPhiWeights<get_phi_wt_usage(PIT)>& phi_wts, int i_simd, double wp){
202  const double& phi_w0 = phi_wts.phi.w[0][i_simd];
203  const double& phi_w1 = phi_wts.phi.w[1][i_simd];
204  access_add(&(S[0]), wp*phi_w0);
205  access_add(&(S[1]), wp*phi_w1);
206  }
207 
208  // Scatter (gyrokinetic)
209  KOKKOS_INLINE_FUNCTION void scatter(const SimdGyroWeights<GyroKin>& rho_wts, const SimdPhiWeights<get_phi_wt_usage(PIT)>& phi_wts, int i_simd, double wp, Field<VarType::Scalar,PhiInterpType::Planes>& field2){
210  const double& phi_w0 = phi_wts.phi.w[0][i_simd];
211  const double& phi_w1 = phi_wts.phi.w[1][i_simd];
212 #ifdef NEWGYROMATRIX
213  const double& rho_w00 = rho_wts.rho_wts[0].w[0][i_simd];
214  const double& rho_w01 = rho_wts.rho_wts[0].w[1][i_simd];
215  const double& rho_w10 = rho_wts.rho_wts[1].w[0][i_simd];
216  const double& rho_w11 = rho_wts.rho_wts[1].w[1][i_simd];
217 #else
218  const double& rho_w00 = rho_wts.rho_wts.w[0][i_simd];
219  const double& rho_w01 = rho_wts.rho_wts.w[1][i_simd];
220  const double& rho_w10 = rho_wts.rho_wts.w[0][i_simd]; // = w00
221  const double& rho_w11 = rho_wts.rho_wts.w[1][i_simd]; // = w01
222 #endif
223 
224  access_add(&(S[0]), wp*phi_w0*rho_w00);
225  access_add(&(S[1]), wp*phi_w1*rho_w10);
226  access_add(&(field2.S[0]), wp*phi_w0*rho_w01);
227  access_add(&(field2.S[1]), wp*phi_w1*rho_w11);
228  }
229 
231  S[0] += rhs.S[0];
232  S[1] += rhs.S[1];
233  return *this;
234  }
235 
236  // Atomic += wrapper
237 /* KOKKOS_INLINE_FUNCTION void access_add_field(const Field<VarType::Scalar,PhiInterpType::Planes>& rhs){
238  access_add(&(S[0]), rhs.S[0]);
239  access_add(&(S[1]), rhs.S[1]);
240  }
241 
242  // Default constructor
243  KOKKOS_INLINE_FUNCTION Field<VarType::Scalar,PhiInterpType::Planes>(){}
244 
245  // Constructor set to scalar
246  KOKKOS_INLINE_FUNCTION Field<VarType::Scalar,PhiInterpType::Planes>(double initval){
247  S[0] = initval;
248  S[1] = initval;
249  }*/
250 };
251 
252 // Struct used for E_rho, dEr_B2, dEz_B2, and du2_E_rho. 2 vector components (r,z)
253 template<>
255  double E[2];
256 
257  static constexpr PhiInterpType PIT = PhiInterpType::None;
258  static constexpr VarType VT = VarType::Vector2D;
259 
260  static constexpr int NDIM(){return 2;}
261  static constexpr int NPHI(){return 1;}
262  static constexpr int SIZE(){return NDIM()*NPHI();}
263 
270  KOKKOS_INLINE_FUNCTION void gather(SimdVector& vec, int i_simd, double wp, const FieldCorrection& corr) const{
271  vec.r[i_simd] += wp*( corr.r0*E[PIR] + corr.z0*E[PIZ] );
272  vec.z[i_simd] += wp*( corr.r1*E[PIR] + corr.z1*E[PIZ] );
273  }
274 
283  KOKKOS_INLINE_FUNCTION void gather(SimdVector& vec, int i_simd, double wp, const SimdGyroWeights<GyroKin>& rho_wts, const FieldCorrection& corr, const Field<VarType::Vector2D,PhiInterpType::None>& field2) const{
284  const double& rho_w00 = rho_wts.rho_wts.w[0][i_simd];
285  const double& rho_w01 = rho_wts.rho_wts.w[1][i_simd];
286  vec.r[i_simd] += wp*( corr.r0*(rho_w00*E[PIR] + rho_w01*field2.E[PIR])
287  +corr.z0*(rho_w00*E[PIZ] + rho_w01*field2.E[PIZ]) );
288  vec.z[i_simd] += wp*( corr.r1*(rho_w00*E[PIR] + rho_w01*field2.E[PIR])
289  +corr.z1*(rho_w00*E[PIZ] + rho_w01*field2.E[PIZ]) );
290  }
291 
292 };
293 
294 // Struct for vector without planar interpolation
295 template<>
297  double V[3];
298 
299  static constexpr PhiInterpType PIT = PhiInterpType::None;
300  static constexpr VarType VT = VarType::Vector;
301 
302  static constexpr int NDIM(){return 3;}
303  static constexpr int NPHI(){return 1;}
304  static constexpr int SIZE(){return NDIM()*NPHI();}
305 
312  KOKKOS_INLINE_FUNCTION void gather(SimdVector& vec, int i_simd, double wp) const{
313  vec.r[i_simd] += wp*V[PIR];
314  vec.z[i_simd] += wp*V[PIZ];
315  vec.phi[i_simd] += wp*V[PIP];
316  }
317 };
318 
319 // Struct for scalar without planar interpolation (i.e. just a double)
320 template<>
322  double S;
323 
324  static constexpr PhiInterpType PIT = PhiInterpType::None;
325  static constexpr VarType VT = VarType::Scalar;
326 
327  static constexpr int NDIM(){return 1;}
328  static constexpr int NPHI(){return 1;}
329  static constexpr int SIZE(){return NDIM()*NPHI();}
330 
336  KOKKOS_INLINE_FUNCTION void gather(Simd<double>& sca, int i_simd, double wp) const{
337  sca[i_simd] += wp*S;
338  }
339 
340  KOKKOS_INLINE_FUNCTION void gather(Simd<double>& sca, int i_simd, double wp, const SimdPhiWeights<get_phi_wt_usage(PIT)>& phi_wts) const{
341  gather(sca, i_simd, wp);
342  }
343 
344  KOKKOS_INLINE_FUNCTION void gather(Simd<double>& sca, int i_simd, double wp, const SimdGyroWeights<GyroKin>& rho_wts, const SimdPhiWeights<get_phi_wt_usage(PIT)>& phi_wts, const Field<VarType::Scalar,PIT>& field2) const{
345  const double& rho_w0 = rho_wts.rho_wts.w[0][i_simd];
346  const double& rho_w1 = rho_wts.rho_wts.w[1][i_simd];
347 
348  sca[i_simd] += wp*(rho_w0*S + rho_w1*field2.S);
349  }
350 
351  // Scatter
352  KOKKOS_INLINE_FUNCTION void scatter(const SimdPhiWeights<get_phi_wt_usage(PIT)>& phi_wts, int i_simd, double wp){
353  access_add(&S, wp);
354  }
355 
356  // Scatter (gyrokinetic)
357  KOKKOS_INLINE_FUNCTION void scatter(const SimdGyroWeights<GyroKin>& rho_wts, const SimdPhiWeights<get_phi_wt_usage(PIT)>& phi_wts, int i_simd, double wp, Field<VarType::Scalar,PhiInterpType::None>& field2){
358  const double& rho_w00 = rho_wts.rho_wts.w[0][i_simd];
359  const double& rho_w01 = rho_wts.rho_wts.w[1][i_simd];
360  access_add(&( S),wp*rho_w00);
361  access_add(&(field2.S),wp*rho_w01);
362  }
363 
364  /* Cleaner access patterns if interacting with the same type */
365 
366  KOKKOS_INLINE_FUNCTION void operator += (const Field<VarType::Scalar,PhiInterpType::None>& rhs){
367  S += rhs.S;
368  }
369 
370  /* Cleaner access patterns if interacting with a double */
371 
372  // Conversion to double
373  KOKKOS_INLINE_FUNCTION explicit operator double() const {
374  return S;
375  }
376 
377  // Assignment from double
378  KOKKOS_INLINE_FUNCTION void operator = (const double val) {
379  S = val;
380  }
381 
382  // Add double
383  KOKKOS_INLINE_FUNCTION void operator += (const double val){
384  S += val;
385  }
386 
387 /* // Atomic += wrapper
388  KOKKOS_INLINE_FUNCTION void access_add_field(const Field<VarType::Scalar,PhiInterpType::None>& rhs){
389  access_add(&(S), rhs.S);
390  }
391 
392  // Default constructor
393  KOKKOS_INLINE_FUNCTION Field<VarType::Scalar,PhiInterpType::None>(){}
394 
395  // Constructor set to scalar
396  KOKKOS_INLINE_FUNCTION Field<VarType::Scalar,PhiInterpType::None>(double initval){
397  S = initval;
398  }*/
399 };
400 
402 
403 #endif
KOKKOS_INLINE_FUNCTION void access_add(T *addr, T val)
Definition: access_add.hpp:40
Definition: field.hpp:23
const double gamma_psi
Definition: field.hpp:24
double z0
Definition: field.hpp:29
double r1
Definition: field.hpp:28
double r0
Definition: field.hpp:27
double z1
Definition: field.hpp:30
KOKKOS_INLINE_FUNCTION void set(int i_simd, double basis, const SimdVector2D &gradpsi)
Definition: field.hpp:35
KOKKOS_INLINE_FUNCTION FieldCorrection(const SimdVector2D &gradpsi, int i_simd)
Definition: field.hpp:32
constexpr VarType vec2d_if_axisym()
VarType
Definition: field.hpp:11
KOKKOS_INLINE_FUNCTION bool isfinite(const Field< VarType::Vector, PhiInterpType::Planes > &f)
Definition: field.hpp:114
Field< VarType::Scalar, PhiInterpType::None > ScalarField
Definition: field.hpp:401
@ PIP
phi coordinate
Definition: globals.hpp:208
@ PIR
r coordinate
Definition: globals.hpp:206
@ PIZ
z coordinate
Definition: globals.hpp:207
PhiInterpType
Definition: globals.hpp:95
constexpr KOKKOS_INLINE_FUNCTION PhiWtUsage get_phi_wt_usage(PhiInterpType PIT)
Definition: grid_weights.hpp:15
static constexpr int NDIM()
Definition: field.hpp:327
double S
Definition: field.hpp:322
static constexpr int SIZE()
Definition: field.hpp:329
static constexpr int NPHI()
Definition: field.hpp:328
KOKKOS_INLINE_FUNCTION void gather(Simd< double > &sca, int i_simd, double wp) const
Definition: field.hpp:336
KOKKOS_INLINE_FUNCTION void scatter(const SimdGyroWeights< GyroKin > &rho_wts, const SimdPhiWeights< get_phi_wt_usage(PIT)> &phi_wts, int i_simd, double wp, Field< VarType::Scalar, PhiInterpType::None > &field2)
Definition: field.hpp:357
KOKKOS_INLINE_FUNCTION void gather(Simd< double > &sca, int i_simd, double wp, const SimdGyroWeights< GyroKin > &rho_wts, const SimdPhiWeights< get_phi_wt_usage(PIT)> &phi_wts, const Field< VarType::Scalar, PIT > &field2) const
Definition: field.hpp:344
KOKKOS_INLINE_FUNCTION void gather(Simd< double > &sca, int i_simd, double wp, const SimdPhiWeights< get_phi_wt_usage(PIT)> &phi_wts) const
Definition: field.hpp:340
KOKKOS_INLINE_FUNCTION void scatter(const SimdPhiWeights< get_phi_wt_usage(PIT)> &phi_wts, int i_simd, double wp)
Definition: field.hpp:352
KOKKOS_INLINE_FUNCTION void gather(Simd< double > &sca, int i_simd, double wp, const SimdGyroWeights< GyroKin > &rho_wts, const SimdPhiWeights< get_phi_wt_usage(PIT)> &phi_wts, const Field< VarType::Scalar, PhiInterpType::Planes > &field2) const
Definition: field.hpp:179
static constexpr int SIZE()
Definition: field.hpp:158
static constexpr int NDIM()
Definition: field.hpp:156
KOKKOS_INLINE_FUNCTION void gather(Simd< double > &sca, int i_simd, double wp, const SimdPhiWeights< get_phi_wt_usage(PIT)> &phi_wts) const
Definition: field.hpp:166
KOKKOS_INLINE_FUNCTION void scatter(const SimdGyroWeights< GyroKin > &rho_wts, const SimdPhiWeights< get_phi_wt_usage(PIT)> &phi_wts, int i_simd, double wp, Field< VarType::Scalar, PhiInterpType::Planes > &field2)
Definition: field.hpp:209
KOKKOS_INLINE_FUNCTION void scatter(const SimdPhiWeights< get_phi_wt_usage(PIT)> &phi_wts, int i_simd, double wp)
Definition: field.hpp:201
double S[2]
Definition: field.hpp:151
Field< VarType::Scalar, PhiInterpType::Planes > & operator+=(const Field< VarType::Scalar, PhiInterpType::Planes > &rhs)
Definition: field.hpp:230
static constexpr int NPHI()
Definition: field.hpp:157
static constexpr int NDIM()
Definition: field.hpp:260
double E[2]
Definition: field.hpp:255
static constexpr int NPHI()
Definition: field.hpp:261
KOKKOS_INLINE_FUNCTION void gather(SimdVector &vec, int i_simd, double wp, const FieldCorrection &corr) const
Definition: field.hpp:270
static constexpr int SIZE()
Definition: field.hpp:262
KOKKOS_INLINE_FUNCTION void gather(SimdVector &vec, int i_simd, double wp, const SimdGyroWeights< GyroKin > &rho_wts, const FieldCorrection &corr, const Field< VarType::Vector2D, PhiInterpType::None > &field2) const
Definition: field.hpp:283
static constexpr int NPHI()
Definition: field.hpp:128
static constexpr int SIZE()
Definition: field.hpp:129
KOKKOS_INLINE_FUNCTION void gather(SimdVector &vec, int i_simd, double wp, const SimdPhiWeights< get_phi_wt_usage(PIT)> &phi_wts, const FieldCorrection &corr) const
Definition: field.hpp:138
static constexpr int NDIM()
Definition: field.hpp:127
static constexpr int NDIM()
Definition: field.hpp:302
static constexpr int NPHI()
Definition: field.hpp:303
KOKKOS_INLINE_FUNCTION void gather(SimdVector &vec, int i_simd, double wp) const
Definition: field.hpp:312
static constexpr int SIZE()
Definition: field.hpp:304
static constexpr int SIZE()
Definition: field.hpp:57
KOKKOS_INLINE_FUNCTION void gather(SimdVector &vec, int i_simd, double wp, const SimdGyroWeights< GyroKin > &rho_wts, const SimdPhiWeights< get_phi_wt_usage(PIT)> &phi_wts, const FieldCorrection &corr, const Field< VarType::Vector, PhiInterpType::Planes > &field2) const
Definition: field.hpp:85
static constexpr int NPHI()
Definition: field.hpp:56
KOKKOS_INLINE_FUNCTION void gather(SimdVector &vec, int i_simd, double wp, const SimdPhiWeights< get_phi_wt_usage(PIT)> &phi_wts, const FieldCorrection &corr) const
Definition: field.hpp:66
double V[3][2]
Definition: field.hpp:50
static constexpr int NDIM()
Definition: field.hpp:55
Definition: field.hpp:45
Definition: gyro_radius.hpp:84
SimdLinearWeights rho_wts
Definition: gyro_radius.hpp:87
Simd< double > w[2]
Definition: linear_weights.hpp:48
Definition: grid_weights.hpp:18
Definition: simd.hpp:139
Simd< double > z
Definition: simd.hpp:141
Simd< double > r
Definition: simd.hpp:140
Definition: simd.hpp:149
Simd< double > z
Definition: simd.hpp:151
Simd< double > r
Definition: simd.hpp:150
Simd< double > phi
Definition: simd.hpp:152