Gyselalib++
 
Loading...
Searching...
No Matches
singlemodeperturbinitialization.hpp
1// SPDX-License-Identifier: MIT
2
3#pragma once
4
5#include <paraconf.h>
6
7#include "geometry.hpp"
8#include "iinitialization.hpp"
9#include "paraconfpp.hpp"
10#include "species_info.hpp"
11
14{
15 DConstFieldSpVxVy m_fequilibrium;
16
17 host_t<IFieldMemSp> m_init_perturb_mode;
18
19 host_t<DFieldMemSp> m_init_perturb_amplitude;
20
21public:
31 DFieldXY perturbation,
32 int const perturb_mode,
33 double const perturb_amplitude) const;
34
42 DConstFieldSpVxVy fequilibrium,
43 host_t<IFieldMemSp> init_perturb_mode,
44 host_t<DFieldMemSp> init_perturb_amplitude);
45
46 ~SingleModePerturbInitialization() override = default;
47
53 DFieldSpXYVxVy operator()(DFieldSpXYVxVy allfdistribu) const override;
54
64 DConstFieldSpVxVy allfequilibrium,
65 IdxRangeSp idx_range_kinsp,
66 PC_tree_t const& yaml_input_file);
67};
An abstract class that allows for initializing a distribution function.
Definition iinitialization.hpp:11
A class that initializes the distribution function as a perturbed Maxwellian.
Definition singlemodeperturbinitialization.hpp:20
void perturbation_initialization(DFieldXY perturbation, int const perturb_mode, double const perturb_amplitude) const
Initialization of the perturbation.
SingleModePerturbInitialization(DConstFieldSpVxVy fequilibrium, host_t< IFieldMemSp > init_perturb_mode, host_t< DFieldMemSp > init_perturb_amplitude)
Creates an instance of the SingleModePerturbInitialization class.
static SingleModePerturbInitialization init_from_input(DConstFieldSpVxVy allfequilibrium, IdxRangeSp idx_range_kinsp, PC_tree_t const &yaml_input_file)
Read init_perturb_mode and init_perturb amplitude in a YAML input file to initialize the perturbation...
DFieldSpXYVxVy operator()(DFieldSpXYVxVy allfdistribu) const override
Initializes the distribution function as as a perturbed Maxwellian.