morphogen.contact.surfaces¶
The surfaces that touch: faces of a tetrahedral mesh, pairs of them, rigid obstacles, and bodies meshed apart brought into one mesh.
- class morphogen.contact.surfaces.Surface(faces: ndarray)[source]¶
Bases:
objectFaces of a tetrahedral mesh that may touch others: rows of three nodes (4-node tetrahedra) or of six (10-node ones: the corners, then the middles of the edges 0-1, 1-2 and 2-0), their normals out of the body.
- classmethod of(mesh: TetMesh, where=None, phases=None) Surface[source]¶
The free faces of a mesh (those of one element only: its outside, the walls of its pores, the lips of its cracks): all of them, those of the elements of the
phasesgiven, those whose centroids (rows)wherekeeps.
- property n_faces: int¶
- property order: int¶
1 for faces of three nodes, 2 for faces of six.
- points(nodes: ndarray, rule: str = 'gauss')[source]¶
The integration points of the faces: their faces, coordinates (ξ, η) and weights (their shares of the areas of the faces in the positions
nodes: the area element of each on a curved face of six nodes), three per face of three nodes, six per face of six.rule:"gauss", points inside the faces, or"nodes": the vertices of the faces of three nodes; the vertices, the middles of the edges and the centroids of those of six (a corner or an edge of a body is then a contact point).
- positions(nodes: ndarray, face, xi, eta) ndarray[source]¶
The positions of points of the faces (rows) in the positions
nodes.
- class morphogen.contact.surfaces.Pair(slave: Surface, master: Surface | None = None, friction: float = 0.0, stiffness: float | None = None, tangential: float | None = None, depth: float | None = None, symmetric: bool = False, points: str = 'gauss')[source]¶
Bases:
objectTwo surfaces that may touch: the integration points of the faces of
slaveare kept out ofmaster(and those ofmasterout ofslavetoo withsymmetric: two passes, for bodies of like stiffness and meshes).slavealone (masterNone): a surface that may touch itself, the walls of pores or the struts of a lattice (every face against the others, those that share a node with it left out).friction: Coulomb’s coefficient.stiffness: the penalty, a pressure per unit of penetration (by default ten times the stiffest Young’s modulus over the size of the faces; the two passes of a symmetric pair, or the two sides of a surface that touches itself, share it);tangential: that of the stick (by default the penalty).depth: the deepest penetration looked for (by default half the size of the faces): a point deeper behind a face is taken to be across a wall, not through it.points: the slave points,"gauss"(inside the faces) or"nodes"(at their nodes: for a surface whose corners or edges meet the master first, which points inside its faces would let through; the weight of a point is then the share of its face that the master sees, the cosine of the angle of their normals, and a point of the rim of the slave still faces the master a twentieth of a face beyond its rim).- property own: bool¶
Whether the surface touches itself.
- class morphogen.contact.surfaces.Obstacle(kind: int, surface: Surface, point: tuple, axis: tuple = (0.0, 0.0, 1.0), size: float = 0.0, inside: bool = False, friction: float = 0.0, stiffness: float | None = None, tangential: float | None = None, motion: object = None, name: str = '', points: str = 'gauss')[source]¶
Bases:
objectA rigid obstacle that the integration points of the faces of
surfacestay out of, with Coulomb’sfrictionon it;stiffnessandtangential: as for aPair.motion: its translation, a vector grown with the load factor (load factor x motion) or a function of the load factor returning one; the force that the body exerts on it is a result of each step.The kinds (
plane(),sphere(),cylinder(),cone()): a plane (a point and its normal, out of the obstacle: a platen), a sphere (its centre and radius), a cylinder without ends (a point of its axis, its axis and radius), a cone (its apex, its axis from the apex into the cone and its half-angle, in degrees: an indenter).inside: the body is held within the sphere or the cylinder (a die).points: the points of the surface kept out of it,"gauss"or"nodes"(as for aPair: a body that meets a platen by a corner or an edge).
- morphogen.contact.surfaces.assemble(meshes, phases=None) TetMesh[source]¶
Bodies meshed apart as one mesh, for their contact: the nodes and elements of the
meshesone after the other (nothing is merged: nodes at the same place stay apart), in the box of them all;phases: a phase per mesh in place of their own (by default each mesh keeps its phases).