Re-factor initialization of kinetic species
Bug description / feature request:
-
The initial conditions of a kinetic species are not clear from
parameters.yml
; there isinit
andbackground
, which have to be consistent at the moment (-> source of error). -
Tests for correct particle binning (e.g of density
n
) are missing. -
console_diagn.py
should be more flexible when reading parameters forfull-f
(not all params have to be in the file, defaults should be taken).
Expected behavior:
Easy to understand parameters.yml
and kinetic initialization.
Proposed solution:
- Stay with
init
andbackground
in the parameter file, butinit
should always be a perturbation w.r.t tobackground
, to mirror the fluid init. The same functionsModesSin
,TorusModesCos
etc. should be possible choices for kinetic perturbations.
- Maybe only one class
Maxwellian6D
is needed instead ofMaxwellian6DUniform
andMaxwellian6DPerturbed
. Propose to renameMaxwellian6DPerturbed
->Maxwellian6D
which can call the availableinitial/perturbations.py
in the definition of the moments.
- Write unit tests under
kinetic_backgrounds
that assert the correct binning of simple Maxwellians.