Field solvers
Warning
This section is currently in development.
Electromagnetic
- class picmistandard.PICMI_ElectromagneticSolver(**extra_data: Any)[source]
Base class for all PICMI classes using Pydantic for validation and extensibility.
This class allows code-specific extensions (e.g., warpx_* kwargs) via Pydantic’s extra fields mechanism while maintaining type safety for standard attributes.
Implementation specific documentation
Electromagnetic field solver.
The advance method used to solve Maxwell’s equations. The default method is code dependent.
Method options:
‘Yee’: standard solver using the staggered Yee grid (https://doi.org/10.1109/TAP.1966.1138693)
‘CKC’: solver with the extended Cole-Karkkainen-Cowan stencil with better dispersion properties (https://doi.org/10.1103/PhysRevSTAB.16.041303)
‘Lehe’: CKC-style solver with modified dispersion (https://doi.org/10.1103/PhysRevSTAB.16.021301)
‘PSTD’: Spectral solver with finite difference in time domain, e.g., Q. H. Liu, Letters 15 (3) (1997) 158–165
‘PSATD’: Spectral solver with analytic in time domain (https://doi.org/10.1016/j.jcp.2013.03.010)
‘DS’: Directional Splitting after Yasuhiko Sentoku (https://doi.org/10.1140/epjd/e2014-50162-y)
‘ECT’: Enlarged Cell Technique solver, allowing internal conductors (https://doi.org/10.1109/APS.2005.1551259)
- field methods_list: list[str] = ['Yee', 'CKC', 'Lehe', 'PSTD', 'PSATD', 'GPSTD', 'DS', 'ECT']
- field grid: PICMI_Cartesian1DGrid | PICMI_Cartesian2DGrid | PICMI_Cartesian3DGrid | PICMI_CylindricalGrid [Required]
Grid object for the diagnostic
- field method: Literal['Yee', 'CKC', 'Lehe', 'PSTD', 'PSATD', 'GPSTD', 'DS', 'ECT'] | None = None
The advance method use to solve Maxwell’s equations. The default method is code dependent.
- field stencil_order: Sequence[int] | None = None
Vector of integers. Order of stencil for each axis (-1=infinite)
- field cfl: float | None = None
Fraction of the Courant-Friedrich-Lewy criteria [1]
- field source_smoother: PICMI_BinomialSmoother | None = None
Smoother instance. Smoother object to apply to the sources
- field field_smoother: PICMI_BinomialSmoother | None = None
Smoother instance. Smoother object to apply to the fields
- field subcycling: int | None = None
Level of subcycling for the GPSTD solver
- field galilean_velocity: Sequence[float] | None = None
Vector of floats. Velocity of Galilean reference frame [m/s]
- field divE_cleaning: bool | None = None
Solver uses div(E) cleaning if True
- field divB_cleaning: bool | None = None
Solver uses div(B) cleaning if True
- field pml_divE_cleaning: bool | None = None
Solver uses div(E) cleaning in the PML if True
- field pml_divB_cleaning: bool | None = None
Solver uses div(B) cleaning in the PML if True
Electrostatic
- class picmistandard.PICMI_ElectrostaticSolver(**extra_data: Any)[source]
Base class for all PICMI classes using Pydantic for validation and extensibility.
This class allows code-specific extensions (e.g., warpx_* kwargs) via Pydantic’s extra fields mechanism while maintaining type safety for standard attributes.
Implementation specific documentation
Electrostatic field solver.
- field methods_list: list[str] = ['FFT', 'Multigrid']
- field grid: PICMI_Cartesian1DGrid | PICMI_Cartesian2DGrid | PICMI_Cartesian3DGrid | PICMI_CylindricalGrid [Required]
Grid instance. Grid object for the diagnostic
- field method: Literal['FFT', 'Multigrid'] | None = None
String. One of ‘FFT’, or ‘Multigrid’
- field required_precision: float | None = None
Level of precision required for iterative solvers
- field maximum_iterations: int | None = None
Maximum number of iterations for iterative solvers
Magnetostatic
- class picmistandard.PICMI_MagnetostaticSolver(**extra_data: Any)[source]
Base class for all PICMI classes using Pydantic for validation and extensibility.
This class allows code-specific extensions (e.g., warpx_* kwargs) via Pydantic’s extra fields mechanism while maintaining type safety for standard attributes.
Implementation specific documentation
Magnetostatic field solver.
- field methods_list: list[str] = ['FFT', 'Multigrid']
- field grid: PICMI_Cartesian1DGrid | PICMI_Cartesian2DGrid | PICMI_Cartesian3DGrid | PICMI_CylindricalGrid [Required]
Grid instance. Grid object for the diagnostic
- field method: Literal['FFT', 'Multigrid'] | None = None
String. One of ‘FFT’, or ‘Multigrid’
Smoothing
- class picmistandard.PICMI_BinomialSmoother(*, n_pass: Sequence[int] | None = None, compensation: Sequence[bool] | None = None, stride: Sequence[int] | None = None, alpha: Sequence[float] | None = None, **extra_data: Any)[source]
Base class for all PICMI classes using Pydantic for validation and extensibility.
This class allows code-specific extensions (e.g., warpx_* kwargs) via Pydantic’s extra fields mechanism while maintaining type safety for standard attributes.
Implementation specific documentation
Describes a binomial smoother operator (applied to grids).
- field n_pass: Sequence[int] | None = None
Vector of integers. Number of passes along each axis
- field compensation: Sequence[bool] | None = None
Vector of booleans, optional. Flags whether to apply compensation along each axis
- field stride: Sequence[int] | None = None
Vector of integers, optional. Stride along each axis
- field alpha: Sequence[float] | None = None
Vector of floats, optional. Smoothing coefficients along each axis