class neso_fame.mesh.Prism(LazilyOffsetable)

Representation of a triangular or rectangular (or other) prism.

This is represented by a number quads making up its faces. The remaining two faces are made up of the edges of these quads at s=0 and s=1 and are normal to the x3-direction. This will most often be used for hexahedrons and, occasionally, triangular prisms.

Note

When creating a 6-face prism (hexahedron), the first two sides must be opposite each other (meaning that the final two sides will also be opposite each other). I should probably change this so that they should be in order, instead.

Public members

custom_poloidal_mapping : None | Callable[[_SupportsArray[dtype[Any]] | _NestedSequence[_SupportsArray[dtype[Any]]] | bool | int | float | complex | str | bytes | _NestedSequence[bool | int | float | complex | str | bytes], _SupportsArray[dtype[Any]] | _NestedSequence[_SupportsArray[dtype[Any]]] | bool | int | float | complex | str | bytes | _NestedSequence[bool | int | float | complex | str | bytes]], SliceCoords] = None

Custom mapping between reference coordinates and real coordinates on the poloidal plane. This is useful for triangular prisms where all three faces are curved or if you want more control over the placement of interior quadrature points.

sides : tuple[Quad, ...]

Shapes defining the edges of the hexahedron

Constructors

Prism(sides: tuple[Quad, ...], ...)

Initialize self. See help(type(self)) for accurate signature.

Special methods

__iter__() Iterator[Quad]

Iterate over the four quads defining the faces of the hexahedron.

__repr__()

Return repr(self).

__eq__(other)

Return self==value.

__hash__()

Return hash(self).

Methods

corners() Coords

Return the points corresponding to the vertices of the hexahedron.

subdivide(num_divisions: int) Iterator[Prism]

Split the prism into the specified number of pieces.

poloidal_map(s: numpy.typing.ArrayLike, t) SliceCoords

Calculate positions on the poloidal (x3) cross-section of this prism.

make_flat_faces() Prism

Create a new prism where sides don’t curve in the poloidal plane.

Properties

property x3_offset : float

Return the offset in the x3 direction.

property is_offset : bool

Indicate whether the object has been offset.


Last update: Nov 07, 2024