salvus.mesh.data_structures.salvus_mesh.serialization.vtk_utils
salvus.mesh.data_structures.salvus_mesh.serialization.vtk_utils salvus mesh data_structures salvus_mesh serialization vtk_utils Utils for VTK serialization.
Functions
interpolate_to_lagrange()
interpolate_to_lagrange()def interpolate_to_lagrange(
n_dim: typing.Literal[2, 3],
model_order: int,
conn: npt.NDArray,
field: npt.NDArray,
) -> npt.NDArray: ...Interpolate a field from the GLL basis to an equidistantly-spaced basis.
Meant to be run on a field that is in VTK Lagrange ordering.
Parameters
n_dimtyping.Literal[2, 3] — The dimension of the field.model_orderint — The model order of the field.connnpt.NDArray — The connectivity array in VTK ordering. The inverse of this permutation will be used to re-construct the tensor product ordering.fieldnpt.NDArray — The nodal field to interpolate. Can be either a scalar or vector field (e.g. coordinates) — differentiated by the dimensionality of the array. Leading dimension must be the individual node values, the optional trailing dimension is for vector fields.
Returns npt.NDArray — The field interpolated to the equidistantly spaced basis.