XGCa
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
cpp_f0profile.hpp
Go to the documentation of this file.
1 #ifndef CPP_F0_PROFILE_HPP
2 #define CPP_F0_PROFILE_HPP
3 #include "space_settings.hpp"
4 
5 // structure for single value equilbirum profile with linear interpolation
6 template<class Device>
7 class OneProfile {
8 
9  /* assume shape = -1 and use linear interpolation
10  int shape;
11  double inx[5];
12  double iny[4];
13  double sv[6];
14  */
15 
16  // for linear interpolation
17  int lin_n;
18  double lin_min, lin_del;
19  Kokkos::View<double*,Kokkos::LayoutRight,Device> lin_v;
20 
21 
22  public:
23  // Constructor
24  OneProfile(const int n_in, const double min_in, const double del_in, double *v_in);
25  // Default constructor
27 
28  KOKKOS_INLINE_FUNCTION void interpol(const Simd<double>& psi, Simd<double>& v, Simd<double>& dvdp) const;
29 };
30 
31 template<class Device>
32 class F0Profile {
33  public:
34 
37 
38  OneProfile<Device> density_prf, temp_prf; // den, temp, flow(ToDo)
39 
40  //Constructor
41  F0Profile(double out_f, double out_w, double priv_f, double priv_w, int lin_n,
42  double lin_min0, double lin_del0, double *lin_v0,
43  double lin_min1, double lin_del1, double *lin_v1);
44  //Default constructor
46 
47  KOKKOS_INLINE_FUNCTION void get_profile(const MagneticField<Device> &magnetic_field, const Simd<double>& psi,
48  const Simd<double>& r, const Simd<double>& z,
49  Simd<double>& f0den, Simd<double>& f0dden,
50  Simd<double>& f0temp, Simd<double>& f0dtemp) const; //SK: add flow later
51 
52 };
53 
54 
55 #include "cpp_f0profile.tpp"
56 
57 #endif
double lin_del
Definition: cpp_f0profile.hpp:18
Definition: cpp_magnetic_field.hpp:9
int lin_n
Definition: cpp_f0profile.hpp:17
F0Profile()
Definition: cpp_f0profile.hpp:45
double eq_priv_flux_decay_width
Definition: cpp_f0profile.hpp:36
OneProfile()
Definition: cpp_f0profile.hpp:26
KOKKOS_INLINE_FUNCTION void interpol(const Simd< double > &psi, Simd< double > &v, Simd< double > &dvdp) const
Definition: cpp_f0profile.tpp:20
OneProfile< Device > temp_prf
Definition: cpp_f0profile.hpp:38
KOKKOS_INLINE_FUNCTION void get_profile(const MagneticField< Device > &magnetic_field, const Simd< double > &psi, const Simd< double > &r, const Simd< double > &z, Simd< double > &f0den, Simd< double > &f0dden, Simd< double > &f0temp, Simd< double > &f0dtemp) const
Definition: cpp_f0profile.tpp:65
Definition: cpp_f0profile.hpp:7
Kokkos::View< double *, Kokkos::LayoutRight, Device > lin_v
profile data for interpolation
Definition: cpp_f0profile.hpp:19
double eq_priv_flux_decay_factor
Definition: cpp_f0profile.hpp:36
OneProfile< Device > density_prf
Definition: cpp_f0profile.hpp:38
double lin_min
Definition: cpp_f0profile.hpp:18
double eq_out_decay_width
Definition: cpp_f0profile.hpp:35
double eq_out_decay_factor
Definition: cpp_f0profile.hpp:35
Definition: cpp_f0profile.hpp:32