4.1.5.1.3 pde.backends.torch.operators.cylindrical_sym module
This module implements differential operators on spherical grids.
Cylindrical Laplace using torch. |
|
Cylindrical gradient operator using torch. |
|
Cylindrical gradient squared operator using torch. |
|
Cylindrical divergence operator using torch. |
- class CylindricalDivergence(grid, bcs, *, dtype=<class 'numpy.float64'>)[source]
Bases:
TorchOperatorCylindrical divergence operator using torch.
The cylindrical grid assumes polar symmetry, so that fields only depend on the radial coordinate r and the axial coordinate z. Here, the first axis is along the radius, while the second axis is along the axis of the cylinder. The radial discretization is defined as \(r_i = (i + \frac12) \Delta r\) for \(i=0, \ldots, N_r-1\).
Initialize the Cylindrical divergence operator.
- Parameters:
grid (
GridBase) – The grid on which the operator actsbcs (
BoundariesListor None) – The boundary conditions applied to the field. If None, no boundary conditions are enforced.dtype (AnyDType) – The data type of the field
- class CylindricalGradient(grid, bcs, *, dtype=<class 'numpy.float64'>)[source]
Bases:
TorchOperatorCylindrical gradient operator using torch.
The cylindrical grid assumes polar symmetry, so that fields only depend on the radial coordinate r and the axial coordinate z. Here, the first axis is along the radius, while the second axis is along the axis of the cylinder. The radial discretization is defined as \(r_i = (i + \frac12) \Delta r\) for \(i=0, \ldots, N_r-1\).
Initialize the Cylindrical gradient operator.
- Parameters:
grid (
GridBase) – The grid on which the operator actsbcs (
BoundariesListor None) – The boundary conditions applied to the field. If None, no boundary conditions are enforced.dtype (AnyDType) – The data type of the field
- class CylindricalGradientSquared(grid, bcs, *, central=True, dtype=<class 'numpy.float64'>)[source]
Bases:
TorchOperatorCylindrical gradient squared operator using torch.
The cylindrical grid assumes polar symmetry, so that fields only depend on the radial coordinate r and the axial coordinate z. Here, the first axis is along the radius, while the second axis is along the axis of the cylinder. The radial discretization is defined as \(r_i = (i + \frac12) \Delta r\) for \(i=0, \ldots, N_r-1\).
Initialize the Cylindrical gradient squared operator.
- Parameters:
grid (
GridBase) – The grid on which the operator actsbcs (
BoundariesListor None) – The boundary conditions applied to the field. If None, no boundary conditions are enforced.central (bool) – Whether to use central differences. If False, forward and backward differences are used.
dtype (AnyDType) – The data type of the field
- class CylindricalLaplacian(grid, bcs, *, dtype=<class 'numpy.float64'>)[source]
Bases:
TorchOperatorCylindrical Laplace using torch.
The cylindrical grid assumes polar symmetry, so that fields only depend on the radial coordinate r and the axial coordinate z. Here, the first axis is along the radius, while the second axis is along the axis of the cylinder. The radial discretization is defined as \(r_i = (i + \frac12) \Delta r\) for \(i=0, \ldots, N_r-1\).
Initialize the Cylindrical Laplacian operator.
- Parameters:
grid (
GridBase) – The grid on which the operator actsbcs (
BoundariesListor None) – The boundary conditions applied to the field. If None, no boundary conditions are enforced.dtype (AnyDType) – The data type of the field