Required
mesh| Type: | UnstructuredMesh |
| Description: | The mesh to attach the material to. |
fill_value specified.def attach_material_to_mesh(
mesh: UnstructuredMesh,
materials: material.Material | list[material.Material],
index_field: str | None = None,
fill_value: float = 0.0,
clear_elemental_nodal_fields: bool = False,
) -> None: ...| Type: | UnstructuredMesh |
| Description: | The mesh to attach the material to. |
| Type: | material.Material | list[material.Material] |
| Description: | A single material or a list of materials to attach. |
| Type: | str | None |
| Default value: | None |
| Description: | The name of the field that maps the materials to the mesh elements. This should be an unsigned integer field that indicates which material each element should use. If None, it is assumed that there is only one material and all elements use it. |
| Type: | float |
| Default value: | 0.0 |
| Description: | The value to fill in for parameters that are not present in a material. |
| Type: | bool |
| Default value: | False |
| Description: | If True, all existing elemental nodal fields in the mesh will be cleared before attaching the material. This might be useful to keep mesh size down, and to allow material extraction for mesh qc. |
Nonedef split_acoustic_elastic_material_dicts(
material_dict: dict[str, npt.NDArray],
) -> tuple[dict[str, npt.NDArray], dict[str, npt.NDArray], npt.NDArray]: ...| Type: | dict[str, npt.NDArray] |
| Description: | A dictionary containing material properties, where the keys are the names of the material properties and the values are numpy arrays. The dictionary must contain a 'fluid' field that indicates whether the material is acoustic (fluid) or elastic (solid). |
tuple[dict[str, npt.NDArray], dict[str, npt.NDArray], npt.NDArray]def to_material(
mesh: UnstructuredMesh, ignore_fields: typing.Sequence[str] | None = None
) -> material.Material: ...| Type: | UnstructuredMesh |
| Description: | The mesh. |
| Type: | typing.Sequence[str] | None |
| Default value: | None |
| Description: | A list of fields to ignore when creating the material. |
material.Materialdef to_materials(
mesh: UnstructuredMesh, ignore_fields: typing.Sequence[str] | None = None
) -> tuple[
material.Material | None, material.Material | None, npt.NDArray
]: ...| Type: | UnstructuredMesh |
| Description: | The mesh. |
| Type: | typing.Sequence[str] | None |
| Default value: | None |
| Description: | A list of fields to ignore when creating the material. |
tuple[material.Material | None, material.Material | None, npt.NDArray]def transform_material(
mesh: UnstructuredMesh,
m: type[material.Material],
reduction_method: (
typing.Literal["remove-components", "force"] | None
) = None,
) -> UnstructuredMesh: ...| Type: | UnstructuredMesh |
| Description: | The mesh. |
| Type: | type[material.Material] |
| Description: | The desired material. |
| Type: | typing.Literal['remove-components', 'force'] | None |
| Default value: | None |
| Description: | Method to move between incompatible symmetry classes. None will only move to symmetries that are equal or more permissive, while remove-components will drop components that are found to match the new material's constraints as necessary, and thus leading to loss of free parameters but not of information. The option "force" will take all information necessary to construct the new parameter set without verification, leading to loss of information. |
UnstructuredMesh