Twenty-node isoparametric solid with eight corners and twelve edge nodes. The implementation uses complete 3×3×3 integration.
01 Model and scope
Eight corner and twelve edge functions provide a quadratic serendipity interpolation without face or interior nodes. Geometry and displacement share that interpolation; all 27 quadrature contributions depend on the local Jacobian, so midside placement and connectivity affect the result.
Route assumptions and calculation checks
- Midside-node ordering is part of the Gmsh-compatible connectivity contract.
- Quadratic edges are curved only when midside coordinates follow the intended geometry.
- A linear registry row does not imply general nonlinear or contact coverage.
Useful foundations and prerequisites
02 Essential equations and symbols
Definitions and conventions
- Nₐ
- Shape function for corner or edge node a.
- (rₐ,sₐ,tₐ)
- Parent-coordinate signs for a corner.
- Reference-to-physical Jacobian.
- The complete 3 × 3 × 3 integration rule.
03 Step by step derivation
Follow the assumptions, equations and discrete operations in order. The full explanation stays visible.
1 · Topology, node order, and DOFs
HEX20 has eight corners and twelve midside edge nodes, with no face-centre or interior nodes. QF Solver follows Gmsh's second-order incomplete-hexahedron ordering (element type 17). Each of the twenty nodes contributes three translations, giving a 60-entry element vector. Edge ordering is part of connectivity correctness.
Reordering only the twelve midside nodes changes the geometry and displacement field, even if the eight corners still look correct.
2 · Corner and edge shape functions
The serendipity basis uses a quadratic correction at each corner and a parabolic factor along each edge. The edge formula is written for a free parent coordinate; the other two coordinates are fixed at the edge signs. There are no face or volume bubbles in this 20-node family.
3 · Isoparametric map and 27-point stiffness
The same basis interpolates x and u. The Jacobian varies over a distorted cell, and physical derivatives are evaluated at the integration points. The production rule is complete 3×3×3 Gauss integration: three Gauss points along each parent direction, 27 total.
The implementation checks the determinant at all 27 Gauss points and rejects non-positive or near-zero values. A finite sample set is not a global positivity proof for every curved mapping.
4 · Mass and constitutive integration
Consistent mass is integrated from NᵀN with the same 27-point rule and requires positive density. The nonlinear trial-state/tangent path keeps a state at each integration point. Optional row-sum mass lumping exists as a helper; do not infer that a lumped modal route is qualified unless a registry row says so.
5 · Proof obligations and limitations
The meaningful checks are not only matrix symmetry: verify partition of unity, affine reproduction, six free rigid modes, mass positivity, Jacobian orientation, and mesh-order conversion. A curved edge requires a physically placed midside node; a straight midside placement produces straight edges. The 3×3×3 rule and a passing patch do not establish all nonlinear, contact, or distorted-cell combinations. Consult the versioned maturity row for the exact scope.
04 Algorithm and implementation
Source excerpt · v0.2.11
The element validates geometry, forms the physical B matrix at every Gauss point, and accumulates the 60 × 60 stiffness using the local Jacobian determinant.
Functions shown: stiffness
def stiffness(self, coords: np.ndarray) -> np.ndarray:
stiffness = np.zeros((60, 60), dtype=float)
for _, weight, b_matrix, determinant in self.integration_data(coords):
stiffness += weight * determinant * (
b_matrix.T @ self.material.elasticity_matrix @ b_matrix
)
return symmetrize(stiffness)05 Verification and limitations
QUALIFIED_BOUNDED · nonlinear extensions remain narrower
Linear elasticity and bounded J2 extension evidence; inspect the exact row before applying it.
Each reference supports its own model, observable and analysis route. Read the original contract and limitations before transferring a conclusion.