Real constants and sections#

Some elements need geometric data the mesh doesn’t carry — a shell thickness, a truss cross-section area, a beam inertia tensor, a point mass. In MAPDL that data goes into a real-constant set, identified by a REAL id and attached to each element through its REAL stamp. femorph-solver reproduces the convention with femorph_solver.Model.r() and real().

R and REAL#

m = femorph_solver.Model()
m.et(1, "SHELL181")
m.mat(1)
m.mp("EX", 1, 2.1e11)
m.mp("PRXY", 1, 0.30)
m.mp("DENS", 1, 7850.0)

m.real(1)             # REAL,1 — stamp the id for subsequent E,...
m.r(1, 0.005)         # R,1,0.005 — 5 mm thickness

# ... n(), e() ...

Model.r() stores the positional values on the grid; the element kernel pulls them out as a 1-D array and indexes them by the layout documented in its theory page.

Per-element-type layouts#

Element

Positional layout

Notes

LINK180

r = [AREA, ADDMAS, ISTRN]

Only AREA is mandatory. ADDMAS and ISTRN are parsed but not yet used.

COMBIN14

r = [K, CV1, CV2, IL]

K is the spring constant (mandatory). CV1 / CV2 damping and IL initial length are parsed but not used in the current \(K_e\) path.

MASS21

r = [MASSX, MASSY, MASSZ]

MASSX is mandatory; MASSY / MASSZ default to MASSX when omitted.

BEAM188

r = [AREA, IZZ, IYY, J]

AREA cross-sectional area; IZZ / IYY the two bending inertias about the element’s local axes; J the Saint-Venant torsion constant.

PLANE182

r = [THK]

Out-of-plane thickness; default 1.0.

SHELL181

r = [THICKNESS]

Through-thickness dimension. Mandatory.

SOLID185 / SOLID186 / SOLID187

(none)

Solid elements carry no real constants; geometry is fully determined by the nodes.

CDB decks round-trip the positional layout exactly — an element carrying REAL,2 in the input deck ends up with m.real_constants[2] populated in the correct order.

Introspection#

m.real_constants
# {1: array([0.005])}              # SHELL181 thickness
# {2: array([1.0e-4, 8.3e-9, 8.3e-9, 1.7e-8])}   # BEAM188 section

# Which real id does an element use?
m.grid.cell_data["ansys_real_constant"]

Sections (future)#

MAPDL’s SECTYPE / SECDATA commands for beam cross-sections are not yet consumed by femorph-solver. A CDB with only R data works today; a CDB using SECTYPE,...,BEAM,RECT + SECDATA for a beam section does not (yet) translate into BEAM188 real constants. Both paths will eventually share a common intermediate representation.

See also#

  • MaterialsMP properties (EX, PRXY, DENS etc).

  • Element library — per-element documentation including the exact real-constant layout.