ASCOT5
Loading...
Searching...
No Matches
wall.h
Go to the documentation of this file.
1
9#ifndef WALL_H
10#define WALL_H
11
12#include "ascot5.h"
13#include "offload_acc_omp.h"
14#include "wall/wall_2d.h"
15#include "wall/wall_3d.h"
16
28
45
60
61int wall_init_offload(wall_offload_data* offload_data, real** offload_array,
62 int** int_offload_array);
63void wall_free_offload(wall_offload_data* offload_data, real** offload_array,
64 int** int_offload_array);
65
66int wall_init(wall_data* w, wall_offload_data* offload_data,
67 real* offload_array, int* int_offload_array);
68
69GPU_DECLARE_TARGET_SIMD_UNIFORM(w)
70int wall_hit_wall(real r1, real phi1, real z1, real r2, real phi2, real z2,
71 wall_data* w, real* w_coll);
72DECLARE_TARGET_END
73
74GPU_DECLARE_TARGET_SIMD_UNIFORM(w)
76DECLARE_TARGET_END
77#endif
Main header file for ASCOT5.
double real
Definition ascot5.h:85
2D wall data parameters
Definition wall_2d.h:23
2D wall offload data
Definition wall_2d.h:13
3D wall data parameters
Definition wall_3d.h:38
3D wall offload data
Definition wall_3d.h:16
Wall model simulation data.
Definition wall.h:55
wall_type type
Definition wall.h:56
wall_3d_data w3d
Definition wall.h:58
wall_2d_data w2d
Definition wall.h:57
Wall model offload data.
Definition wall.h:38
int offload_array_length
Definition wall.h:42
int int_offload_array_length
Definition wall.h:43
wall_3d_offload_data w3d
Definition wall.h:41
wall_type type
Definition wall.h:39
wall_2d_offload_data w2d
Definition wall.h:40
DECLARE_TARGET_END int wall_get_n_elements(wall_data *w)
Return the number of wall elements.
Definition wall.c:187
int wall_hit_wall(real r1, real phi1, real z1, real r2, real phi2, real z2, wall_data *w, real *w_coll)
Check if a given directed line segment intersects the wall.
Definition wall.c:163
void wall_free_offload(wall_offload_data *offload_data, real **offload_array, int **int_offload_array)
Free offload array and reset parameters.
Definition wall.c:91
int wall_init_offload(wall_offload_data *offload_data, real **offload_array, int **int_offload_array)
Load wall data and prepare parameters.
Definition wall.c:42
int wall_init(wall_data *w, wall_offload_data *offload_data, real *offload_array, int *int_offload_array)
Initialize wall data struct on target.
Definition wall.c:119
wall_type
Wall model types.
Definition wall.h:24
@ wall_type_2D
Definition wall.h:25
@ wall_type_3D
Definition wall.h:26
Header file for wall_2d.c.
Header file for wall_3d.c.