morphogen.contact.experiments

Ready-made tests of a sample between rigid tools (see morphogen.contact): its compression between two platens, on which it rubs and under which its own walls may close on themselves (a foam, a lattice, a porous solid that densifies), and its indentation by a sphere or a cone.

Both build a ContactProblem of the mesh of the sample with rigid obstacles, follow it in steps and give the curves that the tests measure: the nominal stress against the nominal strain of a compression, the force against the depth of an indentation with the modulus that it reads (Hertz, Sneddon; the slope of the unloading: Oliver and Pharr 1992).

morphogen.contact.experiments.INDENTERS = ('sphere', 'cone')

The indenters of indentation()

class morphogen.contact.experiments.CompressionResult(strain: ndarray, stress: ndarray, force: ndarray, area: ndarray, self_area: ndarray, friction: ndarray, section: float, height: float, result: ContactResult, problem: ContactProblem)[source]

Bases: object

The compression of a sample between two platens. At each step: the nominal strain (the approach of the platens over the height of the sample: negative), the force that the sample exerts on the moving platen (positive), the nominal stress (minus this force over the section of the box of the sample: negative), the area in contact with the platens (steps x 2: the fixed one, the moving one; reference area), the area of the walls of the sample in contact with themselves (self_area, of one of the two sides) and the energy that friction dissipated (friction). section and height: those of the box of the sample. result: the steps of the problem ( ContactResult: reactions, works, the slave points at the end); problem: the problem (write() for its fields).

property modulus: float

its stress over its strain.

Type:

The apparent modulus of the first step

tangent() → ndarray[source]

The tangent modulus of each step: the change of the stress over that of the strain (one value per step; stiffening as the walls close).

rows() → list[dict][source]

One row per step: strain, stress, force, the areas in contact (with the fixed platen, with the moving one, of the sample with itself) and the energy dissipated by friction.

morphogen.contact.experiments.compression(mesh: TetMesh, materials, strain: float, *, axis: int = 2, friction: float = 0.0, self_contact: bool = True, self_friction: float | None = None, steps: int = 20, kinematics: str = 'finite', fields: bool = False, stiffness: float | None = None, points: str = 'gauss', **options) → CompressionResult[source]

Compress a sample between two rigid platens across axis: the platens are the planes of the two faces of the box of the mesh (that of the solid of a porous sample: conforming_mesh(..., phases="solid")), the lower one fixed, the upper one brought down by -strain times the height of the box (strain: the nominal strain, negative) in steps steps.

The free surface of the sample presses on the platens with Coulomb’s friction (0: lubricated platens, the sample widens freely; with friction it barrels) and, with self_contact, on itself with self_friction (by default that of the platens): the walls of the pores that close, the struts of a lattice that meet. stiffness: the penalty of all these contacts (see Pair); points: their contact points, "gauss" or "nodes" (a sample that meets a platen, or itself, by corners or edges); kinematics: "finite" strains (the default) or "small" ones; fields: keep the displacements of each step. The other options: those of ContactProblem (bulk, augmentations, tolerance, neighbours) and of its run() (tol, max_newton, max_cuts).

Two nodes of the base hold the sample against the rigid motions along the platens (the forces that they take are those that the platens would otherwise have to: none for a sample that widens evenly).

class morphogen.contact.experiments.IndentationResult(depth: ndarray, force: ndarray, area: ndarray, pressure: ndarray, modulus: ndarray, indenter: str, stiffness: float | None, unloading_modulus: float | None, radius_of_indenter: float | None, thickness: float, base: str, result: ContactResult, problem: ContactProblem)[source]

Bases: object

The indentation of a sample. At each step: the depth of the indenter under the surface, the force on it, the area of the contact (the reference area of the points that press), its radius (of the disc of the same area), the largest pressure and the hardness (the mean pressure, force over area); modulus: the reduced modulus E / (1 - ν²) of the homogeneous half-space that would take the force at that depth (Hertz for a sphere, Sneddon for a cone: that of the sample while the contact is small against it and against its heterogeneities). With an unloading: stiffness, the slope of the force at its start, and unloading_modulus, S sqrt(π) / (2 sqrt(A)) (Oliver and Pharr 1992: the area is that of the points, known to a ring of them). radius_of_indenter (a sphere), thickness (of the sample under its face) and base: those of the test. result and problem: as for a compression.

layer_modulus(poisson: float) → ndarray[source]

The reduced modulus read from the force of a sphere with the base of the sample taken into account: modulus over the factor by which a rigid base under a layer of the thickness of the sample, of Poisson’s ratio poisson, multiplies Hertz’s force (layer_correction(): bonded for a fixed base, free to slide for a smooth one). A sample wide against its thickness.

property radius: ndarray
property hardness: ndarray
rows() → list[dict][source]

One row per step: depth, force, area and radius of the contact, largest and mean pressures, and the reduced modulus read from the force.

morphogen.contact.experiments.indentation(mesh: TetMesh, materials, depth: float, *, indenter: str = 'sphere', radius: float | None = None, half_angle: float = 70.3, point=None, axis: int = 2, friction: float = 0.0, steps: int = 10, unload: bool = False, base: str = 'fixed', kinematics: str = 'finite', fields: bool = False, stiffness: float | None = None, **options) → IndentationResult[source]

Indent the upper face of a sample (across axis) to a depth by a rigid indenter: a "sphere" of radius, or a "cone" of half_angle (degrees from its axis; 70.3: the cone of the same area as the pyramids of Berkovich and Vickers), at point of the face (two coordinates along it; by default its middle), in steps steps, then out again in as many with unload.

base: the lower face is "fixed" (glued) or "smooth" (it slides on its support); the other faces are free. friction: that of the indenter. stiffness, kinematics, fields and the other options: as for compression().