32#pragma omp declare target
35#pragma omp end declare target
67 real** offload_array) {
70 switch(offload_data->
type) {
81 print_err(
"Error: Unrecognized atomic reaction data type.");
88 *
sizeof(
real) / (1024.0*1024.0) );
105 real** offload_array) {
106 switch(offload_data->
type) {
127 real* offload_array) {
129 switch(offload_data->
type) {
137 print_err(
"Error: Unrecognized atomic reaction data type.");
167 real* sigma,
int z_1,
int a_1,
int z_2,
int a_2,
real E_coll_per_amu,
174 sigma, z_1, a_1, z_2, a_2, E_coll_per_amu, reac_type,
183 if(err || sigma[0] < 0.0) {
217 real* sigmav,
int z_1,
int a_1,
real m_1,
int z_2,
int a_2,
225 sigmav, z_1, a_1, m_1, z_2, a_2, E, T_e, T_0, n_i,
234 if(err || sigmav[0] < 0.0) {
263 real* ratecoeff,
int z_1,
int a_1,
real E,
real mass,
int nspec,
264 const int* znum,
const int* anum,
real T_0,
real* n_0,
271 ratecoeff, z_1, a_1, E, mass, nspec, znum, anum, T_0, n_0,
280 if(err || ratecoeff[0] < 0.0) {
309 real* ratecoeff,
int z_1,
int a_1,
real E,
real mass,
int nion,
310 const int* znum,
const int* anum,
real T_e,
real* n_i,
317 ratecoeff, z_1, a_1, E, mass, nion, znum, anum, T_e, n_i,
326 if(err || ratecoeff[0] < 0.0) {
Main header file for ASCOT5.
static int ASIGMA_EXTRAPOLATE
a5err asigma_eval_sigma(real *sigma, int z_1, int a_1, int z_2, int a_2, real E_coll_per_amu, asigma_reac_type reac_type, asigma_data *asigma_data)
Evaluate atomic reaction cross-section.
a5err asigma_eval_cx(real *ratecoeff, int z_1, int a_1, real E, real mass, int nspec, const int *znum, const int *anum, real T_0, real *n_0, asigma_data *asigma_data)
Evaluate charge exchange rate coefficient.
void asigma_extrapolate(int extrapolate)
Toggle extrapolation when evaluating cross sections.
void asigma_free_offload(asigma_offload_data *offload_data, real **offload_array)
Free offload array and reset parameters.
int asigma_init(asigma_data *asigma_data, asigma_offload_data *offload_data, real *offload_array)
Initializes atomic reaction data struct on target.
a5err asigma_eval_sigmav(real *sigmav, int z_1, int a_1, real m_1, int z_2, int a_2, real E, real T_e, real T_0, real n_i, asigma_reac_type reac_type, asigma_data *asigma_data)
Evaluate atomic reaction rate coefficient.
a5err asigma_eval_bms(real *ratecoeff, int z_1, int a_1, real E, real mass, int nion, const int *znum, const int *anum, real T_e, real *n_i, asigma_data *asigma_data)
Evaluate beam stopping rate coefficient.
int asigma_init_offload(asigma_offload_data *offload_data, real **offload_array)
Load atomic reaction data and prepare parameters.
Header file for asigma.c.
asigma_reac_type
Reaction types for atomic reaction data.
void asigma_loc_free_offload(asigma_loc_offload_data *offload_data, real **offload_array)
Free offload array and reset parameters.
a5err asigma_loc_eval_cx(real *ratecoeff, int z_1, int a_1, real E, real mass, int nspec, const int *znum, const int *anum, real T_0, real *n_0, int extrapolate, asigma_loc_data *asigma_data)
Evaluate atomic reaction rate coefficient.
a5err asigma_loc_eval_sigma(real *sigma, int z_1, int a_1, int z_2, int a_2, real E_coll_per_amu, int reac_type, int extrapolate, asigma_loc_data *asigma_data)
Evaluate atomic reaction cross-section.
void asigma_loc_init(asigma_loc_data *asigma_data, asigma_loc_offload_data *offload_data, real *offload_array)
Initialize atomic reaction data struct on target.
a5err asigma_loc_eval_sigmav(real *sigmav, int z_1, int a_1, real m_1, int z_2, int a_2, real E, real T_e, real T_0, real n_i, int reac_type, int extrapolate, asigma_loc_data *asigma_data)
Evaluate atomic reaction rate coefficient.
int asigma_loc_init_offload(asigma_loc_offload_data *offload_data, real **offload_array)
Initialize local file atomic data and check inputs.
a5err asigma_loc_eval_bms(real *ratecoeff, int z_1, int a_1, real E, real mass, int nion, const int *znum, const int *anum, real T_e, real *n_i, int extrapolate, asigma_loc_data *asigma_data)
Evaluate beam stopping rate coefficient.
Header file for asigma_loc.c.
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.
Macros for printing console output.
#define print_out(v,...)
Print to standard output.
#define print_err(...)
Print to standard error.
Atomic reaction simulation data.
asigma_loc_data asigma_loc
Atomic reaction offload data.
asigma_loc_offload_data asigma_loc