Expand description
Real finite-element subsystem (element library, global assembly, static solve,
Newmark-β time integration, Newton–Raphson nonlinear solve). Backs the structural
NonlinearStatic / LinearDynamic / NonlinearDynamic analysis types. Split into
its own library submodule (PROJECT RULE §11); carries its own reference tests
(cantilever tip deflection, axial/two-bar truss, SDOF Newmark, cubic-spring Newton).
Real finite-element subsystem for structural static / dynamic / nonlinear analysis.
This is a genuine, deterministic FE stack — no fabricated numbers, no hard-coded
reference answers. Every result is produced by assembling element matrices into a
global system and solving it with the crate’s dense linear solvers
(crate::solvers::linear_algebra::lu). It backs the previously-NotImplemented
AnalysisType variants (NonlinearStatic, LinearDynamic, NonlinearDynamic).
§Model
A planar (2-D) frame model with a uniform 3 DOF per node layout
(ux, uy, θz). Global DOF index for node n: ux = 3n, uy = 3n+1, θz = 3n+2.
Two element families are provided:
- [
FeElement::Truss] — pin-jointed axial bar, element stiffnesskₑ = (EA/L)·[[1,−1],[−1,1]]in the axial coordinate, rotated into global(ux,uy)DOFs by direction cosines. Rotational DOFs are untouched (the caller constrains them for a pure truss). - [
FeElement::Frame] — 2-node Euler–Bernoulli beam-column: axialEA/Lplus the 4×4 bending block withEI/L³terms, assembled as a 6×6 local matrix and rotated into global coordinates. Consistent 6×6 mass is provided.
§Solvers
- [
solve_static] —K u = Fwith boundary conditions applied by row/column elimination (exact reactions), solved via LU. - [
newmark_linear] — average-acceleration Newmark-β (β=¼, γ=½) time integration ofM ü + C u̇ + K u = F(t). - [
newton_raphson] — Newton iterationR(u) = f_int(u) − F_ext → 0with a caller-supplied tangent. - [
newmark_nonlinear] — Newmark with an inner Newton–Raphson iteration each step (composition of the two above) forM ü + C u̇ + f_int(u) = F(t).
Structs§
- FeModel
- A complete finite-element model: nodes, elements, prescribed-displacement constraints and applied nodal loads.
- FeNode
- A structural node in the planar (2-D) frame model. Coordinates in metres.
- FeStatic
Result - Result of a linear-static FE solve.
- GeoNonlinear
Bar - A single-DOF geometrically-nonlinear axial bar (fixed–free), Green–Lagrange strain.
- Newmark
Result - Time-history response from a Newmark integration.
Enums§
- FeElement
- A 2-node structural finite element. All elements live in the uniform
3-DOF-per-node layout
(ux, uy, θz).
Functions§
- assemble_
loads - Assemble the global load vector
F(lengthn) from the model’s nodal loads. - assemble_
mass - Assemble the global mass matrix
M(row-majorn×n). Frame elements use their consistent mass; truss elements use lumped mass. - assemble_
stiffness - Assemble the global stiffness matrix
K(row-majorn×n). - newmark_
linear - Average-acceleration Newmark-β (β=¼, γ=½ by default) integration of
M ü + C u̇ + K u = F(t)on an already-reducedn-DOF system (no constraints).force(t)returns the length-nload vector. Unconditionally stable; the effective stiffness is factored once and reused every step. - newmark_
nonlinear - Newmark-β integration with an inner Newton–Raphson iteration each step for
M ü + C u̇ + f_int(u) = F(t).internal(u)=f_int,tangent(u)=∂f_int/∂u. The step residual isG(u) = M a(u) + C v(u) + f_int(u) − F(t+dt)wherea,vfollow the Newmark relations; the effective tangent isKₜ + a0·M + a1·C. - newton_
raphson - Newton–Raphson solve of
R(u) = f_int(u) − F_ext = 0. - solve_
static - Solve
K u = Fwith the model’s displacement boundary conditions applied by row/column elimination (partitioning into free / constrained DOFs). Reactions are recovered exactly from the assembled full stiffness.