HyPar  1.0
Finite-Difference Hyperbolic-Parabolic PDE Solver on Cartesian Grids
vlasov.h
Go to the documentation of this file.
1 
24 #include <stdbool.h>
25 
26 #ifdef fftw
27 #ifdef serial
28 #include <fftw3.h>
29 #else
30 #include <fftw3-mpi.h>
31 #endif
32 #endif
33 
37 #define _VLASOV_ "vlasov"
38 
39 /* define ndims and nvars for this model */
40 #undef _MODEL_NDIMS_
41 #undef _MODEL_NVARS_
42 
43 #define _MODEL_NDIMS_ 2
44 
45 #define _MODEL_NVARS_ 1
46 
47 
53 /* \brief Structure containing variables and parameters for the Vlasov equation
54  * This structure contains the physical parameters, variables, and function pointers
55  * specific to the Vlasov equation.
56 */
57 typedef struct vlasov_parameters {
58 
61 
63  int ndims_x;
64 
66  int ndims_v;
67 
70 
73 
76 
79 
81  double *e_field;
82 
84  double *potential;
85 
87  void *m;
88 
89 #ifdef fftw
90 
92  double *sum_buffer;
94  fftw_plan plan_forward_e;
96  fftw_plan plan_backward_e;
98  fftw_complex *phys_buffer_e;
100  fftw_complex *fourier_buffer_e;
102  ptrdiff_t alloc_local;
104  ptrdiff_t local_ni, local_i_start;
106  ptrdiff_t local_no, local_o_start;
107 
109  fftw_plan plan_forward_phi;
111  fftw_plan plan_backward_phi;
113  fftw_complex *phys_buffer_phi;
115  fftw_complex *fourier_buffer_phi;
116 #endif
117 
118 } Vlasov;
119 
121 int VlasovInitialize (void*,void*);
123 int VlasovCleanup (void*);
Definition: vlasov.h:57
double * potential
Definition: vlasov.h:84
int self_consistent_electric_field
Definition: vlasov.h:60
int VlasovInitialize(void *, void *)
int VlasovCleanup(void *)
Definition: VlasovCleanup.c:10
double * e_field
Definition: vlasov.h:81
int npts_local_x
Definition: vlasov.h:69
long npts_global_x
Definition: vlasov.h:72
long npts_global_x_wghosts
Definition: vlasov.h:78
void * m
Definition: vlasov.h:87
int ndims_v
Definition: vlasov.h:66
int npts_local_x_wghosts
Definition: vlasov.h:75
int ndims_x
Definition: vlasov.h:63