morphogen.dynamics.results¶
The results of a run of OpenRadioss read back (read_explicit_run()): the nominal
stress and strain of the morphology over time (the reaction forces of its loaded faces
over the area of the face of its box, the displacement of the driven face over the
length of the box), its energies, the fields of its animations on its mesh (the
displacement, the von Mises stress, the plastic strain, the energy density, the
pressure and the status of each element), and the values that sum a test up
(summary(): the peak stress, the absorbed energy, the plateau stress and the
densification strain of a crushing, the equilibrium of the faces, the rebound of an
impact).
The forces come from the time history (th_to_csv) when its columns name the nodes of
the loaded faces, else from the reaction forces of the animations (anim_to_vtk), on
the nodes that the manifest of the run names; write_frames() writes the fields of
each animation as a .vtu file of tetrahedra (the bricks split in six) for the 3D views
of morphoGen.
- morphogen.dynamics.results.FIELDS = {'contact': (('cont',), ('contour',)), 'displacement': (('disp',), ()), 'energy_density': (('ener',), ('hourg',)), 'plastic_strain': (('epsp', 'plastic'), ()), 'pressure': (('pres',), ()), 'reaction': (('reac',), ()), 'status': (('off', 'status', 'delet'), ('offset',)), 'velocity': (('vel',), ('accel',)), 'von_mises': (('vonm', 'von_mises', 'von mises', 'vonmises', 'von-mises'), ())}¶
The fields of the animations, by the words of their names in the files of anim_to_vtk (lower case), and the words that exclude a name
- morphogen.dynamics.results.CELL_FIELDS = ('von_mises', 'plastic_strain', 'energy_density', 'pressure')¶
The fields of the elements kept in the frames written for the 3D views
- morphogen.dynamics.results.KUHN = array([[0, 1, 2, 6], [0, 2, 3, 6], [0, 3, 7, 6], [0, 7, 4, 6], [0, 4, 5, 6], [0, 5, 1, 6]])¶
The 6 tetrahedra of a hexahedron in VTK’s order (along its diagonal 0-6; positive)
- morphogen.dynamics.results.SOLID_TYPES = (12, 10, 24)¶
VTK’s types of the solid cells
- class morphogen.dynamics.results.ExplicitFrame(time: float, displacement: ndarray | None, reaction: ndarray | None, cells: dict[str, ~numpy.ndarray]=<factory>, status: ndarray | None = None)[source]¶
Bases:
objectAn animation of a run on the mesh of the run: its time, the displacement and reaction force of each node (None when the animation has none), the fields of the elements and their status (1 active, 0 deleted).
- class morphogen.dynamics.results.ExplicitResult(directory: ~pathlib.Path, manifest: dict, mesh: dict, curves: dict[str, ~numpy.ndarray], energies: dict[str, ~numpy.ndarray], frames: list[~morphogen.dynamics.results.ExplicitFrame], source: str, warnings: list[str] = <factory>)[source]¶
Bases:
objectThe results of a run (see the module): its
manifest, itsmesh(nodes, elements, phases and loaded faces), itscurves(time, displacement, strain, forces and nominal stresses of the upper and lower faces), itsenergies(time -> internal, kinetic… when the time history gives them), itsframesand thesourceof its forces.- property name: str¶
- morphogen.dynamics.results.read_frames(directory, manifest: dict, mesh: dict, paths) tuple[list[ExplicitFrame], list[str]][source]¶
The animations (legacy VTK files of anim_to_vtk) on the mesh of the run: their nodes matched by their identifiers (an array named like NODE_ID), by their order when they are as many, else by their positions in the first animation; their elements likewise (ELEMENT_ID).
- morphogen.dynamics.results.read_explicit_run(directory) ExplicitResult[source]¶
The results of a run of OpenRadioss in
directory(see the module), from its manifest and mesh (morphogen.io.write_radioss()), its animations converted to VTK and its time history converted to CSV (morphogen.dynamics.convert_outputs()).
- morphogen.dynamics.results.summary(result: ExplicitResult) dict[source]¶
The values that sum a run up, in the units of the run: the final and peak nominal stresses and strains, the energy absorbed per unit volume of the box (the integral of the nominal stress over the nominal strain) and per unit mass, the mean gap between the stresses of the two faces over the second half of the run (the equilibrium of a quasi-static test: small when the waves have settled), the plateau stress (the mean between 20 and 40 % strain, after Ashby) and the densification strain (where the energy efficiency, the absorbed energy over the stress, peaks: Avalle et al., 2001) of a crushing; for an impact, the peak force on the wall and the kinetic energies; the energies at the end when the time history gives them; the size of the run.
- morphogen.dynamics.results.display_cells(elements: ndarray) tuple[ndarray, ndarray][source]¶
The tetrahedra that draw a mesh (its tetrahedra, or six per brick) and the element of each.
- morphogen.dynamics.results.write_frames(result: ExplicitResult, folder, *, prefix: str = 'frame') list[Path][source]¶
Write each animation of a run as
<prefix>_0001.vtu… infolder: the elements still active (the bricks split in six tetrahedra), their phase and fields, the displacement of the nodes, the box (morphoGen’s 3D views draw the last one).
- morphogen.dynamics.results.frames_mesh(result: ExplicitResult)[source]¶
The mesh of the frames as a
TetMesh(the bricks split in six), for the videos ofmorphogen.viz.video.
- morphogen.dynamics.results.write_tables(result: ExplicitResult, folder) list[Path][source]¶
The curves and energies of a run as
curves.csvandenergies.csv.