morphogen.laser.architectures

Architectures treated pixel by pixel: a morphology on the laser grid of a sheet.

A laser treats a sheet through its thickness by squares about the size of its spot, the pixel (1 mm by default: the smallest feature a spot of 1 mm treats), over sheets much larger than any specimen (tens of centimetres: hundreds of pixels a side). A design is an integer array (ny, nx) of phases on that grid, row i at y = (i + ½) pixel and column j at x = (j + ½) pixel; phase 0 is the untreated sheet (Phase, the phases of wang_phases() or contrast_phases()). Any morphology of morphoGen (a Boolean model, a tessellation, a random field, a lattice…) becomes a design by pixelate(), the majority phase of each pixel.

Treatment (treatment_measures()). Each pixel can be treated, but heat diffuses: an untreated pixel next to a treated one sits in its heat-affected zone (tempered, partly transformed), and an untreated pixel enclosed by treated ones may not stay untreated at all. The measures: the treated share; the treated length drawn by raster lines one spot wide, its time at the speed of the beam, the switches of the beam along the lines; the connectivity of each phase (whether it spans the design along x and y); the untreated pixels next to the treatment and those enclosed by it.

The sheet (sheet_tests()). A design repeated over the sheet is periodic: the cell of nx x ny pixels (PeriodicCell, elements of half a pixel by default, so that the pixels fall on the elements), each Gauss point with the phase of its pixel (design_membrane()), pulled in several directions (cell_test()): the yield and tensile strengths, the failure strain (the first of the maximum of the nominal stress and of the fracture of a brittle phase, failure_measures()), the energy absorbed up to it and Lankford’s coefficient of the sheet in each direction, and their spreads over the directions.

Tracks (track_membrane()). Smooth tracks of constant width along polylines (corrugations, oblique families), and their periodic images over a cell (periodic_lines()): each Gauss point mixes the flow stresses and Young’s moduli of the untreated and treated phases by the share of its region inside the tracks (band_fractions()). Phases may differ in stiffness as well as in strength (young: one modulus per phase), which separates the two contrasts.

morphogen.laser.architectures.pixelate(image, shape) → ndarray[source]

The phases (integer labels) of an image on a grid of shape = (ny, nx) pixels covering the same extent: the most frequent label of the image points whose centres fall in each pixel (the lowest label on a tie). An image coarser than the grid is sampled at the pixel centres.

morphogen.laser.architectures.spot_opening(design, width: int = 2, *, periodic: bool = True) → ndarray[source]

The part of a design (treated: phase > 0) that a square spot of width cells draws, its morphological opening (periodic: through the edges of the cell; otherwise the spot may overhang them), the treated cells keeping their phase.

morphogen.laser.architectures.treatment_measures(design, *, pixel: float = 1.0, spot: float = 1.0, speed: float = 10.0, periodic: bool = True) → dict[source]

The laser treatment of a design (see the module): treated share; length (m) of the raster lines one spot wide that treat it, time (min) at speed (mm/s), switches of the beam along the rows (per m² of sheet); whether the treated and the untreated phases span the design along x and along y (hard_spans, soft_spans: pairs of booleans); the shares of the untreated pixels with a treated neighbour (heat_affected) and with treated pixels on all four sides (enclosed), among the untreated ones.

morphogen.laser.architectures.design_membrane(mesh, design, *, pixel: float = 1.0, phases=None, origin=(0.0, 0.0), young=210000.0, poisson: float = 0.3, thickness: float = 1.0, fracture_radius: float | None = 1.5) → Membrane[source]

The membrane of a mesh whose Gauss points take the phase of their pixel of the design (from origin, repeated beyond it), with the flow law, the critical strain and Young’s modulus of the phase (phases: wang_phases() by default; young: one modulus, or one per phase).

morphogen.laser.architectures.sheet_tests(design, *, pixel: float = 1.0, phases=None, angles=(0.0, 45.0, 90.0), element: float | None = None, max_strain: float = 0.3, fracture_radius: float | None = 1.5, young: float = 210000.0, thickness: float = 1.0) → dict[source]

The sheet of a periodic design pulled in each direction of angles (degrees from x; see the module): {"directions": {angle: measures}, ...} with, for each direction, the yield and tensile strengths (MPa), the failure strain, the energy up to it (MJ/m³), Lankford’s coefficient, whether a brittle phase broke first, and the result of the test; and over the directions the means and spreads (max − min over the mean) of the yield strength, the failure strain and the energy.

morphogen.laser.architectures.periodic_lines(lines, a1, a2, box, reach: float = 0.0) → list[source]

The polylines lines (mm) and their images by the lattice of a1 and a2 that come within reach of the box (x0, x1, y0, y1): the tracks of a pattern repeated over the sheet, as they cross a periodic cell.

morphogen.laser.architectures.track_membrane(mesh, lines, width, *, phases=None, kinds=None, young=210000.0, poisson: float = 0.3, thickness: float = 1.0, fracture_radius: float | None = 1.5, subdivisions: int = 4) → Membrane[source]

The membrane of a mesh crossed by tracks along the polylines lines (their centre lines; see the module), width mm wide (one width, or one per line): the share w_k of the region of each Gauss point inside the tracks of each treated phase k (kinds: the phase of each line, 1 by default; phases: the untreated first, wang_phases() by default) mixes the flow stress of the untreated phase with that of the treated phase of the largest share as (1 − w) σ_0 + w σ_k (w the sum of the shares), and Young’s moduli (young: one modulus, or one per phase) by the shares; a point mostly inside a track takes the critical strain of that phase. Several kinds: a track whose treatment changes along it, tracks of several treatments.