Skip to content

Update docs for gc model and fix issue #210

Byung Kyu Na requested to merge update_doc_hybrid into devel
  • Update doc strings for gc model (models, propagators, accumulation kernels, pusher kernels ...)

  • fix issue #210 (closed)

When calling kinetic_class, if background distribution function is not specified in parameters.yml, pass None as f0_params.

        # marker arrays and plasma parameters of kinetic species
        if 'kinetic' in self.params:

            for species, val in self.kinetic.items():

                if self.params['kinetic'][species]['markers']['type'] in ['control_variate', 'delta_f']:
                    assert 'background' in self.params['kinetic'][species], \
                        f'If a control variate or delta-f method is used, a maxwellians background must be given!'
                    
                if 'background' in self.params['kinetic'][species]:
                    f0_params = val['params']['background']
                else:
                    f0_params = None

                kinetic_class = getattr(particles, val['space'])

                val['obj'] = kinetic_class(species,
                                           **val['params']['phys_params'],
                                           **val['params']['markers'],
                                           derham=self.derham,
                                           domain=self.domain,
                                           mhd_equil=self.mhd_equil,
                                           epsilon=self.equation_params[species]['epsilon_unit'],
                                           units_basic=self.units,
                                           f0_params=f0_params)
Edited by Byung Kyu Na

Merge request reports