boundary_conditions
moment_kinetics.boundary_conditions
— ModuleFunctions for applying boundary conditions
moment_kinetics.boundary_conditions.enforce_boundary_conditions!
— Methodenforce boundary conditions in vpa and z on the evolved pdf; also enforce boundary conditions in z on all separately evolved velocity space moments of the pdf
moment_kinetics.boundary_conditions.enforce_initial_tapered_zero_incoming!
— MethodSet up an initial condition that tries to be smoothly compatible with the sheath boundary condition for ions, by setting f(±(v_parallel-u0)<0) where u0=0 at the sheath boundaries and for z<0 increases linearly to u0=vpa.L at z=0, while for z>0 increases from u0=-vpa.L at z=0 to zero at the z=z.L/2 sheath.
To be applied to 'full-f' distribution function on vparallel grid (not wparallel grid).
moment_kinetics.boundary_conditions.enforce_neutral_boundary_conditions!
— Methodenforce boundary conditions on neutral particle distribution function
moment_kinetics.boundary_conditions.enforce_neutral_wall_bc!
— Methodenforce the wall boundary condition on neutrals; i.e., the incoming flux of neutrals equals the sum of the ion/neutral outgoing fluxes
moment_kinetics.boundary_conditions.enforce_neutral_z_boundary_condition!
— Methodenforce boundary conditions on neutral particle f in z
moment_kinetics.boundary_conditions.enforce_r_boundary_condition!
— Methodenforce boundary conditions on f in r
moment_kinetics.boundary_conditions.enforce_v_boundary_condition_local!
— Methodmoment_kinetics.boundary_conditions.enforce_vperp_boundary_condition!
— Functionenforce zero boundary condition at vperp -> infinity
moment_kinetics.boundary_conditions.enforce_z_boundary_condition!
— Methodenforce boundary conditions on ion particle f in z
moment_kinetics.boundary_conditions.enforce_z_boundary_condition_moments!
— Methodenforce the z boundary condition on the evolved velocity space moments of f
moment_kinetics.boundary_conditions.enforce_zero_incoming_bc!
— Methodenforce a zero incoming BC in z for given species pdf at each radial location
moment_kinetics.boundary_conditions.skip_f_electron_bc_points_in_Jacobian
— Methodskip_f_electron_bc_points_in_Jacobian(iz, ivperp, ivpa, z, vperp, vpa)
This function returns true
when the grid point specified by iz
, ivperp
, ivpa
would be set by the boundary conditions on the electron distribution function. When this happens, the corresponding row should be skipped when adding contributions to the Jacobian matrix, so that the row remains the same as a row of the identity matrix, so that the Jacobian matrix does not modify those points. Returns false
otherwise.
moment_kinetics.boundary_conditions.vpagrid_to_dzdt
— Methodcreate an array of dz/dt values corresponding to the given vpagrid values