| ASCOT5
    | 
Simulate guiding centers using fixed time-step. More...
#include <stdio.h>#include <stdlib.h>#include <omp.h>#include <math.h>#include "../ascot5.h"#include "../endcond.h"#include "../consts.h"#include "../physlib.h"#include "../simulate.h"#include "../particle.h"#include "../wall.h"#include "../diag.h"#include "../B_field.h"#include "../E_field.h"#include "../rfof.h"#include "../plasma.h"#include "simulate_gc_fixed.h"#include "step/step_gc_rk4.h"#include "mccc/mccc.h"Go to the source code of this file.
| Macros | |
| #define | DUMMY_TIMESTEP_VAL 1.0 | 
| Functions | |
| real | simulate_gc_fixed_inidt (sim_data *sim, particle_simd_gc *p, int i) | 
| Calculates time step value. | |
| void | simulate_gc_fixed (particle_queue *pq, sim_data *sim) | 
| Simulates guiding centers using fixed time-step. | |
Simulate guiding centers using fixed time-step.
Definition in file simulate_gc_fixed.c.
| #define DUMMY_TIMESTEP_VAL 1.0 | 
Dummy time step value
Definition at line 29 of file simulate_gc_fixed.c.
| real simulate_gc_fixed_inidt | ( | sim_data * | sim, | 
| particle_simd_gc * | p, | ||
| int | i ) | 
Calculates time step value.
The time step is calculated as a user-defined fraction of gyro time, whose formula accounts for relativity, or an user defined value is used as is depending on simulation options.
| sim | pointer to simulation data struct | 
| p | SIMD array of markers | 
| i | index of marker for which time step is assessed | 
Definition at line 249 of file simulate_gc_fixed.c.
| void simulate_gc_fixed | ( | particle_queue * | pq, | 
| sim_data * | sim ) | 
Simulates guiding centers using fixed time-step.
The simulation includes:
The simulation is carried until all markers have met some end condition or are aborted/rejected. The final state of the markers is stored in the given marker array. Other output is stored in the diagnostic array.
The time-step is user-defined either directly or as a fraction of gyrotime.
| pq | particles to be simulated | 
| sim | simulation data | 
Definition at line 49 of file simulate_gc_fixed.c.