Materials and sections
Materials, geometric sections, and equivalent-rigidity sections, plus the five-accessor rigidity contract every element consumes.
Asap.Steel_Nmm — Constant
Structural steel in N–mm units: E = 200e3 N/mm², G = 77e3 N/mm², ρ = 8e-5 kg/mm³ (legacy value), ν = 0.3.
Asap.Steel_kNm — Constant
Structural steel in kN–m units: E = 200e6 kN/m², G = 77e6 kN/m², ρ = 80 kg/m³ (legacy value), ν = 0.3.
Asap.Material — Type
Material{T<:Real}A linear-elastic structural material.
A Material carries the four scalar properties that linear member analysis can ever consume: stiffness in normal action (E), stiffness in shear (G), mass density (ρ), and the ratio that couples them (ν). It is immutable — to analyze a design change, construct a new Material.
Asap is units-agnostic: choose any consistent unit system (e.g. kN–m, N–mm, kip–in) and use it everywhere. Dimensions below are written in bracket notation.
Fields
E::T: Young's (elastic) modulus — normal stress per unit normal strain [force/length²]G::T: shear modulus — shear stress per unit shear strain [force/length²]ρ::T: mass density — used for self-weight and (future) dynamic analysis [mass/length³]ν::T: Poisson's ratio — transverse contraction per unit axial extension [unitless]. For isotropic materialsG = E / (2(1 + ν)).
Constructors
Material(E, G, ρ, ν) # all four properties explicit
Material(E, ρ, ν) # isotropic: G derived as E / (2(1 + ν))Arguments are promoted to a common scalar type, so Material(200e6, 80, 0.3) and Material(200e6, 80.0, 0.3) are equivalent.
Examples
julia> steel = Material(200e6, 77e6, 8.0, 0.3) # kN, m: E in kN/m²
julia> concrete = Material(30e6, 2.4, 0.2) # G derived isotropicallySee also Section, RigiditySection.
Asap.AbstractSection — Type
AbstractSection{T<:Real}Supertype of all cross-sections.
A section's entire contract with the analysis layer is the rigidity accessor interface — five functions returning the only quantities a linear member stiffness matrix (or self-weight computation) ever consumes:
| Accessor | Meaning | Dimension |
|---|---|---|
EA | axial rigidity | [force] |
EIx | flexural rigidity, strong axis | [force·length²] |
EIy | flexural rigidity, weak axis | [force·length²] |
GJ | torsional rigidity | [force·length²] |
ρA | mass per unit length | [mass/length] |
Kernels never read struct fields — they call these accessors. Any type implementing all five is a valid section, which is what lets a classical geometric Section and an effective-stiffness RigiditySection (cracked concrete, homogenized members) be used interchangeably anywhere.
Asap.RigiditySection — Type
RigiditySection{T} <: AbstractSection{T}A cross-section defined directly by its rigidities — the products the stiffness matrix actually consumes — rather than by geometry and material.
This is the natural abstraction wherever an "equivalent stiffness" is the meaningful quantity:
- Cracked/effective concrete sections: build from ACI 318-19 stiffness modifiers (e.g. EI_eff = 0.35·Ec·Ig for beams, 0.70·Ec·Ig for columns), a Branson/Bischoff effective moment of inertia, or a full transformed-section analysis. For linear analysis this is exactly as expressive as any equivalent-E or transformed-I formulation, because only the products enter the equations.
- Homogenized/composite members, where no single (E, I) pair exists.
- Optimization parameterizations where rigidities are the design variables.
Because rigidities are stored, there is no meaningful area or material to derive mass from — so mass per unit length ρA is stored explicitly (do not back it out of the rigidities).
Fields
EA::T: axial rigidity — force per unit axial strain [force]EIx::T: flexural rigidity about the strong axis [force·length²]EIy::T: flexural rigidity about the weak axis [force·length²]GJ::T: torsional rigidity [force·length²]ρA::T: mass per unit length, for self-weight and dynamics [mass/length]
Examples
julia> Ec, Ig, A, ρc = 30e6, 8e-4, 0.12, 2.4e3;
julia> cracked_beam = RigiditySection(Ec * A, 0.35 * Ec * Ig, 0.35 * Ec * Ig,
0.1 * Ec * Ig, ρc * A)See also Section, AbstractSection.
Asap.Section — Type
Section{T} <: AbstractSection{T}A cross-section defined by its geometry and its Material — the standard modeling workflow when section dimensions and material are known separately.
Rigidities are derived on demand: EA(sec) = sec.material.E * sec.A, etc. If you instead know effective rigidities directly (cracked concrete, transformed sections, optimization parameterizations), use RigiditySection.
Fields
material::Material{T}: the section's material (provides E, G, ρ)A::T: cross-sectional area [length²]Ix::T: second moment of area about the strong bending axis (local x-axis convention of the legacy library, paired with bending in the local x–y plane) [length⁴]Iy::T: second moment of area about the weak bending axis [length⁴]J::T: St. Venant torsional constant [length⁴]
Constructors
Section(material, A, Ix, Iy, J) # full frame section
Section(material, A) # axial-only (truss) section: Ix = Iy = J = 0The axial-only form replaces the legacy TrussSection: a truss element only ever queries EA/ρA, so zero flexural/torsional properties are simply never read.
Examples
julia> steel = Material(200e6, 77e6, 8.0, 0.3);
julia> w = Section(steel, 1e-2, 8e-5, 3e-5, 5e-7) # a wide-flange, kN–m
julia> bar = Section(steel, 5e-3) # truss bar, axial only