51 real** offload_array) {
54 switch(offload_data->
type) {
79 print_err(
"Error: Unregonized plasma data type.");
86 *
sizeof(
real) / (1024.0*1024.0) );
103 real** offload_array) {
104 switch(offload_data->
type) {
107 &(offload_data->
plasma_1D), offload_array);
136 real* offload_array) {
138 switch(offload_data->
type) {
141 &(offload_data->
plasma_1D), offload_array);
156 print_err(
"Error: Unregonized plasma data type.");
160 pls_data->
type = offload_data->
type;
188 switch(pls_data->
type) {
236 switch(pls_data->
type) {
285 switch(pls_data->
type) {
333 switch(pls_data->
type) {
362 const real* mass = NULL;
363 switch(pls_data->
type) {
392 const real* charge = NULL;
393 switch(pls_data->
type) {
420 const int* znum = NULL;
421 switch(pls_data->
type) {
448 const int* anum = NULL;
449 switch(pls_data->
type) {
Main header file for ASCOT5.
#define MAX_SPECIES
Maximum number of plasma species.
Header file containing physical and mathematical constants.
unsigned long int a5err
Simulation error flag.
static DECLARE_TARGET_SIMD a5err error_raise(error_type type, int line, error_file file)
Raise a new error.
const real * plasma_get_species_mass(plasma_data *pls_data)
Get mass of all plasma species.
const int * plasma_get_species_znum(plasma_data *pls_data)
Get charge number of ion species.
int plasma_get_n_species(plasma_data *pls_data)
Get the number of plasma species.
const real * plasma_get_species_charge(plasma_data *pls_data)
Get charge of all plasma species.
a5err plasma_eval_temp(real *temp, real rho, real r, real phi, real z, real t, int species, plasma_data *pls_data)
Evaluate plasma temperature.
int plasma_init_offload(plasma_offload_data *offload_data, real **offload_array)
Load plasma data and prepare parameters.
a5err plasma_eval_densandtemp(real *dens, real *temp, real rho, real r, real phi, real z, real t, plasma_data *pls_data)
Evaluate plasma density and temperature for all species.
int plasma_init(plasma_data *pls_data, plasma_offload_data *offload_data, real *offload_array)
Initialize plasma data struct on target.
a5err plasma_eval_dens(real *dens, real rho, real r, real phi, real z, real t, int species, plasma_data *pls_data)
Evaluate plasma density.
const int * plasma_get_species_anum(plasma_data *pls_data)
Get atomic mass number of ion species.
void plasma_free_offload(plasma_offload_data *offload_data, real **offload_array)
Free offload array and reset parameters.
Header file for plasma.c.
void plasma_1DS_free_offload(plasma_1DS_offload_data *offload_data, real **offload_array)
Free offload array and reset parameters.
a5err plasma_1DS_eval_densandtemp(real *dens, real *temp, real rho, plasma_1DS_data *plasma_data)
Evaluate plasma density and temperature for all species.
a5err plasma_1DS_eval_dens(real *dens, real rho, int species, plasma_1DS_data *plasma_data)
Evaluate plasma density.
int plasma_1DS_init_offload(plasma_1DS_offload_data *offload_data, real **offload_array)
Initialize 1DS plasma data and check inputs.
a5err plasma_1DS_eval_temp(real *temp, real rho, int species, plasma_1DS_data *plasma_data)
Evaluate plasma temperature.
void plasma_1DS_init(plasma_1DS_data *plasma_data, plasma_1DS_offload_data *offload_data, real *offload_array)
Initialize magnetic field data struct on target.
Header file for plasma_1DS.c.
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.
a5err plasma_1D_eval_dens(real *dens, real rho, int species, plasma_1D_data *pls_data)
Evaluate plasma density.
a5err plasma_1D_eval_densandtemp(real *dens, real *temp, real rho, plasma_1D_data *pls_data)
Evaluate plasma density and temperature for all species.
void plasma_1D_free_offload(plasma_1D_offload_data *offload_data, real **offload_array)
Free offload array and reset parameters.
a5err plasma_1D_eval_temp(real *temp, real rho, int species, plasma_1D_data *pls_data)
Evaluate plasma temperature.
int plasma_1D_init_offload(plasma_1D_offload_data *offload_data, real **offload_array)
Initialize 1D plasma data and check inputs.
Header file for plasma_1D.c.
void plasma_1Dt_free_offload(plasma_1Dt_offload_data *offload_data, real **offload_array)
Free offload array and reset parameters.
int plasma_1Dt_init_offload(plasma_1Dt_offload_data *offload_data, real **offload_array)
Initialize 1Dt plasma data and check inputs.
a5err plasma_1Dt_eval_densandtemp(real *dens, real *temp, real rho, real t, plasma_1Dt_data *pls_data)
Evaluate plasma density and temperature for all species.
a5err plasma_1Dt_eval_temp(real *temp, real rho, real t, int species, plasma_1Dt_data *pls_data)
Evaluate plasma temperature.
a5err plasma_1Dt_eval_dens(real *dens, real rho, real t, int species, plasma_1Dt_data *pls_data)
Evaluate plasma density.
void plasma_1Dt_init(plasma_1Dt_data *pls_data, plasma_1Dt_offload_data *offload_data, real *offload_array)
Initialize magnetic field data struct on target.
Macros for printing console output.
#define print_out(v,...)
Print to standard output.
#define print_err(...)
Print to standard error.
plasma_1Dt_data plasma_1Dt
plasma_1DS_data plasma_1DS
plasma_1DS_offload_data plasma_1DS
plasma_1D_offload_data plasma_1D
plasma_1Dt_offload_data plasma_1Dt