plate
gripyth.meshing.plate
Meshing of simple plate specimens.
FUNCTION | DESCRIPTION |
---|---|
default_elem_sets |
Returns the default elements sets to select either all or none of them. |
default_node_sets |
Returns the default node sets to select edges and corners. |
rectangular |
Meshes a rectangular 2d plate specimen. |
rectangular_notched |
Meshes a rectangular plate with a notch (for the phase-field). |
rectilinear_mesh |
Creates a 2d rectilinear mesh from 1d |
default_elem_sets
Returns the default elements sets to select either all or none of them.
default_node_sets
Returns the default node sets to select edges and corners.
rectangular
rectangular(
L: float = 1.0,
B: float = 1.0,
t: float = 1.0,
Nx: int = 10,
Ny: int = 10,
) -> tuple[Mesh, Geometry]
Meshes a rectangular 2d plate specimen.
rectangular_notched
rectangular_notched(
L: float = 1.0,
B: float = 1.0,
t: float = 1.0,
Lref_x: float = 0,
Lref_y: float = 0,
Nx: int = 10,
Ny: int = 10,
Nref_x: int = 0,
Nref_y: int = 0,
x_notch: float = 0.5,
Lnotch_y: float = 0.0,
y_notch: float = 0.0,
Lnotch_x: float = 0.0,
sharp=False,
) -> tuple[Mesh, Geometry]
Meshes a rectangular plate with a notch (for the phase-field).
Parameters:
L
: plate lengthB
: plate widtht
: out-of-plane thicknessLref_x
: refinement length in x-direction (in center)Lref_y
: refinement length in y-direction (in center)Nx
: elements in x-directionNy
: elements in y-directionNref_x
: elements in the refined zone (x-direction)Nref_y
: elements in refined zone (y-direction)x_notch
: x-coordinate of the notchLnotch_y
: length of notch in y-direction, (x_notch, 0) → (x_notch, Lnotch_y)y_notch
: y-coordinate of the notchLnotch_x
: length of notch in x-direction, (y_notch, 0) → (y_notch, Lnotch_x)sharp
: Duplicate nodes across the notch?
rectilinear_mesh
rectilinear_mesh(
x: NDArray[float64], y: NDArray[float64]
) -> tuple[NDArray[float64], NDArray[int32]]
Creates a 2d rectilinear mesh from 1d x
and y
discretizations.
x
and y
are points on the x- and y-axis defining the boundary locations
between mesh elements. The values are assumed to be monotonically
increasing. The mesh nodes are the intersection points of these boundaries,
the mesh elements the rectangular areas between them. There will be one
node for each combination (x, y), and one less element in each direction.
Nodes are numbered along the y-axis first, followed by the nodes at higher x-coordinates. For example, these are the node numbers for a 3×2 mesh:
Returns:
nodes
: The node coordinates as a 2d array with the (0-based) node number used as the first index and the node coordinates (x, y) referenced by the second.elements
: The nodal connectivity of the elements as a 2d array, the first index enumerating the elements, the second going over the four corners of the element in counter-clockwise order, and each entry being an index intonodes
.