ASCOT5
Loading...
Searching...
No Matches
plasma_1D.h
Go to the documentation of this file.
1
5#ifndef PLASMA_1D_H
6#define PLASMA_1D_H
7#include "../ascot5.h"
8#include "../error.h"
9
23
27typedef struct {
28 int n_rho;
32 real charge[MAX_SPECIES];
33 int anum[MAX_SPECIES];
34 int znum[MAX_SPECIES];
40
42 real** offload_array);
44 real** offload_array);
45
46void plasma_1D_init(plasma_1D_data* pls_data,
47 plasma_1D_offload_data* offload_data,
48 real* offload_array);
49GPU_DECLARE_TARGET_SIMD_UNIFORM(pls_data)
50a5err plasma_1D_eval_temp(real* dens, real rho, int species,
51 plasma_1D_data* pls_data);
52DECLARE_TARGET_END
53GPU_DECLARE_TARGET_SIMD_UNIFORM(pls_data)
54a5err plasma_1D_eval_dens(real* temp, real rho, int species,
55 plasma_1D_data* pls_data);
56DECLARE_TARGET_END
57GPU_DECLARE_TARGET_SIMD_UNIFORM(pls_data)
59 plasma_1D_data* pls_data);
60DECLARE_TARGET_END
61
62#endif
Main header file for ASCOT5.
double real
Definition ascot5.h:85
#define MAX_SPECIES
Maximum number of plasma species.
Definition ascot5.h:95
Error module for ASCOT5.
unsigned long int a5err
Simulation error flag.
Definition error.h:17
void plasma_1D_init(plasma_1D_data *pls_data, plasma_1D_offload_data *offload_data, real *offload_array)
Initialize magnetic field data struct on target.
Definition plasma_1D.c:114
DECLARE_TARGET_END a5err plasma_1D_eval_dens(real *temp, real rho, int species, plasma_1D_data *pls_data)
Evaluate plasma density.
Definition plasma_1D.c:185
DECLARE_TARGET_END a5err plasma_1D_eval_densandtemp(real *dens, real *temp, real rho, plasma_1D_data *pls_data)
Evaluate plasma density and temperature for all species.
Definition plasma_1D.c:225
void plasma_1D_free_offload(plasma_1D_offload_data *offload_data, real **offload_array)
Free offload array and reset parameters.
Definition plasma_1D.c:97
a5err plasma_1D_eval_temp(real *dens, real rho, int species, plasma_1D_data *pls_data)
Evaluate plasma temperature.
Definition plasma_1D.c:145
int plasma_1D_init_offload(plasma_1D_offload_data *offload_data, real **offload_array)
Initialize 1D plasma data and check inputs.
Definition plasma_1D.c:39
1D plasma parameters on the target
Definition plasma_1D.h:27
1D plasma parameters that will be offloaded to target
Definition plasma_1D.h:13