Abstract data types and protocols#
- class sigmaepsilon.mesh.typing.ABC_PolyCell[source]#
Helper class that provides a standard way to create an ABC using inheritance.
- class sigmaepsilon.mesh.typing.CellDataProtocol(*args, **kwargs)[source]#
A generic protocol class for storing cell-related data in a mesh.
- property container: PolyDataLike#
Returns the container object of the block.
- property has_frames: bool#
Ought to return True if the cells are equipped with frames, False if they are not.
- property pointdata: PointDataLike#
Returns the hosting pointdata.
- class sigmaepsilon.mesh.typing.GeometryProtocol(*args, **kwargs)[source]#
Protocol for Geometry classes.
- classmethod approximator(*args, **kwargs) Callable [source]#
Returns a callable object that can be used to approximate over nodal values of one or more cells.
- classmethod master_center() ndarray [source]#
Returns the coordinates of the master element.
- Return type:
- classmethod master_coordinates() ndarray [source]#
Returns the coordinates of the master element.
- Return type:
- classmethod shape_function_derivatives(x: float | Iterable[float], *args, **kwargs) ndarray [source]#
Evaluates shape function derivatives wrt. the master element or the local coordinate frames of some cells. To control the behaviour, either ‘jac’ or ‘wrt’ can be provided.
- class sigmaepsilon.mesh.typing.PointDataProtocol(*args, **kwargs)[source]#
A protocol class for storing point-related data in a mesh.
- property frame: ReferenceFrame#
Ought to return a frame of reference.
- class sigmaepsilon.mesh.typing.PolyCellProtocol(*args, **kwargs)[source]#
A generic protocol class for polygonal cell containers.
- property db: CellDataProtocol[PolyDataLike, PointDataLike]#
Returns the database of the block.
- loc_to_glob(x: Iterable | ndarray, ec: ndarray | None = None) ndarray [source]#
Maps local coordinates in the master domain to global cooridnates. The basis of the transformation is ‘ec’, which is the node coordinates array of the cells of shape (nE, nNE, nD), where ‘nE’, ‘nNE’ and ‘nD’ are the number of cells, nodes per cell and local spatial dimensions.
- local_coordinates() ndarray [source]#
Ought to return the coordinates of the cells in their local coordinate systems.
- topology() TopologyArray [source]#
Ought to return the topology associated with the object.
- class sigmaepsilon.mesh.typing.PolyDataProtocol(*args, **kwargs)[source]#
A generic protocol class for polygonal mesh containers.
- cellblocks(*args, **kwargs) Iterable[PolyDataLike] [source]#
Ought to return PolyData blocks with attached CellData.
- property celldata: PolyCellLike#
Ought to return the attached celldata.
- coords(*args, **kwargs) ndarray [source]#
Ought to return the coordiantes associated with the object.
- property frame: ReferenceFrame | CartesianFrame#
Ought to return the frame of the attached pointdata
- nodal_distribution_factors(*args, **kwargs) ndarray | csr_matrix [source]#
Ought to return nodal distribution factors for every node of every cell in the block.
- pointblocks(*args, **kwargs) Iterable[PolyDataLike] [source]#
Ought to return PolyData blocks with attached PointData.
- property pointdata: PointDataLike#
Ought to return the attached pointdata.
- source(*args, **kwargs) PolyDataLike | None [source]#
Ought to return the object that holds onto point data.
- topology(*args, **kwargs) ndarray | TopologyArray [source]#
Ought to return the topology associated with the object.