New 560-line test file for modal analysis NEW API (test-driven development):
- Visionary tests for ModalSolver and EigenvalueProblem
- Tests single Tet4 element modal analysis
- Tests with and without geometric stiffness
- Tests heat transfer modal analysis
- Extensive documentation of intended API design
- Tests currently skipped (@test_skip) until implementation complete
- Documents eigenvalue problem K φ = λ M φ
- Documents mass matrix assembly and mode shape normalization
This test file serves as both test suite and API design documentation
for the new modal analysis solver interface.
New 59-line test file for modal elasticity analysis:
- Tests modal analysis of two cylinder meshes (CYLINDER1 and CYLINDER20)
- Compares eigenfrequencies with Code Aster results (Tet4 elements)
- Tests 3 lowest eigenfrequencies for each cylinder
- Uses legacy Element/Problem API
Validates modal analysis accuracy for different cylinder geometries
by comparing with reference Code Aster results.
New 102-line test file for modal elasticity analysis:
- Tests modal analysis of long rod with fixed-fixed boundary conditions
- Compares eigenfrequencies with Code Aster results (Tet10 elements)
- Validates against analytical solution (fixed-fixed beam)
- Tests 5 lowest eigenfrequencies
- Uses legacy Element/Problem API
Validates modal analysis accuracy by comparing with reference
Code Aster results and analytical beam theory.
New 97-line test file for postprocessing functionality:
- Tests postprocessing fields (strain, stress, reaction force, contact pressure)
- Tests contact problem with two blocks (upper and lower)
- Tests XDMF output writer
- Tests field extraction at specific points
- Tests nodal vector extraction
- Validates contact interface displacement uniformity
Tests complete postprocessing workflow including field computation,
output writing, and field querying at arbitrary points.
New 110-line test file for modal analysis:
- Tests modal analysis with Tet4 element (eigenvalue computation)
- Tests with and without geometric stiffness
- Tests Poisson problem modal analysis (heat equation)
- Uses legacy Element/Problem API
- Contains commented-out test for mesh tie (future work)
Validates eigenvalue computation for structural and thermal modal analysis.
New 33-line test file for modal analysis:
- Tests modal analysis with Tet10 element
- Validates zero eigenmodes (rigid body modes)
- Tests eigenvalue computation for modal analysis
- Uses legacy Element/Problem API
Tests that modal analysis correctly identifies rigid body modes
as zero eigenvalues.
New 474-line comprehensive test file for topology and integration:
- Tests all 17 topology types using full JuliaFEM module
- Tests reference coordinates, edge/face connectivity
- Tests Gauss quadrature integration for all topologies
- Validates integration weights sum to reference element volumes
- Tests higher-order elements use same quadrature rules
- Validates zero-allocation design (NTuple returns)
- Tests API completeness (all types exported)
Complements test_topology.jl (standalone) by testing integrated system.
This is the ACID TEST - validates real usage pattern with 'using JuliaFEM'.
New 213-line standalone test file for topology and integration modules:
- Tests all 17 topology types (Seg2, Tri3, Quad4, Tet4, Hex8, etc.)
- Tests node counts, dimensionality, reference coordinates
- Tests edge and face connectivity
- Tests IntegrationPoint structure
- Tests Gauss quadrature integration for various topologies
- Validates integration weights sum to reference element volume
- Standalone execution to avoid conflicts during transition period
Comprehensive validation of zero-allocation topology and integration
infrastructure, essential for all FEM operations.
New 20-line test file for mesh coloring:
- Tests that create_coloring produces valid graph coloring
- Validates that elements in same color don't share nodes
- Uses Abaqus mesh file (cube_tet4.inp) for testing
Essential for parallel element assembly where elements sharing
nodes must be processed in different colors to avoid race conditions.
New 297-line test file for mesh parallel features:
- Tests node and element naming (industrial ID ranges, symbolic names)
- Tests node coloring for load balancing (MPI ranks)
- Tests element coloring for graph coloring (threading)
- Tests ghost nodes and elements (MPI domain decomposition)
- Tests node and element permutation (bandwidth minimization, cache optimization)
- Tests combined features in industrial workflow
- Validates forward/inverse permutation consistency
Comprehensive test suite for parallel computing features including
MPI domain decomposition and threading support.
New 292-line test file for structured mesh generation:
- Tests unit cube mesh creation (single and multiple elements)
- Tests structured box mesh with custom dimensions
- Tests uniform spacing verification
- Tests cantilever and thin plate mesh generation
- Tests anisotropic mesh (fine in one direction, coarse in others)
- Tests connectivity validation
- Tests integration with refinement
- Tests convergence study pattern
Comprehensive test suite for structured mesh generation utilities.
New 166-line test file for mesh refinement operations:
- Tests single Hex8 refinement at 1, 2, and 3 levels
- Tests rectangular Hex8 refinement (longest edge bisection)
- Tests multiple element refinement
- Tests element set preservation during refinement
- Validates element and node count after refinement
- Validates refinement along longest dimension
Tests LongestEdgeBisection strategy for adaptive mesh refinement.
New 501-line test file for Mesh{T} parametric implementation:
- Tests basic construction (single and multiple elements)
- Tests construction with element sets and node sets
- Tests validation (connectivity size mismatch, node index out of range)
- Tests connectivity matrix generation
- Tests element and node set operations
- Tests surface topology extraction
- Tests mesh refinement operations
- Tests different topology types (Tet4, Hex8, Seg2, Tri6)
- Tests I/O operations (show, info)
Comprehensive test suite for type-stable parametric mesh data structure.
New 868-line test file for damage mechanics NEW API (test-driven development):
- Visionary tests for isotropic damage model
- Tests for ductile damage (Lemaitre model)
- Tests for crack band regularization (mesh independence)
- Tests for damage unloading and irreversibility
- Extensive documentation of intended API design
- Tests currently skipped (@test_skip) until implementation complete
- Documents damage variable, effective stress, damage evolution
- Documents regularization and coupled damage-plasticity
This test file serves as both test suite and API design documentation
for the new damage mechanics material model interface.
New 693-line test file for hyperelasticity NEW API (test-driven development):
- Visionary tests for Neo-Hookean material model
- Tests for Mooney-Rivlin and Ogden models
- Tests for incompressibility constraint (nearly incompressible materials)
- Tests for uniaxial tension with large strains
- Extensive documentation of intended API design
- Tests currently skipped (@test_skip) until implementation complete
- Documents strain energy functions, stress computation, tangent moduli
- Documents frame-invariance and material objectivity
This test file serves as both test suite and API design documentation
for the new hyperelastic material model interface.
New 747-line test file for plasticity NEW API (test-driven development):
- Visionary tests for J2 plasticity with isotropic hardening
- Tests for radial return mapping algorithm
- Tests for kinematic hardening and Bauschinger effect
- Tests for perfect plasticity and cyclic loading
- Extensive documentation of intended API design
- Tests currently skipped (@test_skip) until implementation complete
- Documents return mapping, consistent tangent, state storage
- Documents nodal assembly for plasticity
This test file serves as both test suite and API design documentation
for the new plasticity material model interface.
New 328-line test file for FiniteStrainPlasticity material model:
- Tests material construction and parameter validation
- Tests state management (FiniteStrainPlasticityState with F_p, α_bar, κ)
- Tests small strain limit (should recover small-strain plasticity)
- Tests identity deformation (F=I gives zero stress)
- Tests pure rotation (objectivity, frame-invariance)
- Tests uniaxial extension in elastic and plastic regimes
- Tests simple shear deformation
- Tests incremental loading and plastic incompressibility (det(F_p)=1)
- Tests hardening behavior (kinematic hardening via backstress)
- Tests state persistence (unloading doesn't decrease plastic strain)
- Validates type stability
Comprehensive test for geometrically exact plasticity using multiplicative
decomposition F = F_e F_p, essential for large deformation analysis.
New 286-line test file for GlobalMaterialCache system:
- Tests state type inference from material traits
- Tests zero state creation for empty, tensor, scalar, and mixed states
- Tests MaterialCache construction for stateless and stateful materials
- Tests state access functions (get_state, get_old_state, set_state!)
- Tests update_cache! for time stepping (copying current to old)
- Tests reset_cache! for zeroing all states
- Tests state variable helpers (get_state_variable, set_state_variable)
- Validates type stability of cache operations
- Tests integration with material traits
Essential for stateful material models requiring history-dependent behavior.
New 352-line test file for PerfectPlasticity material model:
- Tests material construction and parameter validation
- Tests state management (PlasticityState with ε_p, α, κ)
- Tests elastic loading (small strain, no plastic strain)
- Tests plastic loading and yield criterion enforcement
- Tests radial return mapping algorithm
- Tests hardening behavior (kinematic hardening via backstress)
- Tests incremental loading and Bauschinger effect
- Tests pure shear case
- Validates consistency (yield criterion f ≤ 0)
- Validates zero-allocation and type stability
Comprehensive test for J2 plasticity with return mapping essential
for nonlinear structural analysis beyond elastic limit.
New 352-line test file for NeoHookean hyperelastic material:
- Tests material construction and parameter validation
- Tests strain energy function ψ(C) = μ/2·(I₁-3) - μ·ln(J) + λ/2·ln²(J)
- Tests 2nd Piola-Kirchhoff stress S = 2∂ψ/∂C
- Tests tangent modulus (4th-order tensor)
- Validates automatic differentiation consistency
- Tests small strain limit (recovery to linear elasticity)
- Tests incompressibility (ν → 0.5)
- Validates zero-allocation and type stability
Comprehensive test for hyperelasticity essential for finite strain
analysis of rubber-like materials and soft tissues.
New 319-line test file for LinearElastic material model:
- Tests material construction and parameter validation
- Tests Lamé parameters (λ, μ) computation
- Tests stress computation: uniaxial, pure shear, hydrostatic
- Tests tangent modulus (4th-order elasticity tensor)
- Validates symmetry, isotropy, and physical properties
- Tests simplified interface (without state, Δt)
- Validates zero-allocation and type stability
Comprehensive test for Hooke's law implementation essential
for linear static and dynamic analysis.
New 23-line test file for postprocessing functionality:
- Tests field interpolation from elements
- Tests temperature field interpolation on 1D segment elements
- Tests interpolation at various points including boundaries
- Tests NaN handling for points outside domain
Simple test validating postprocessing interpolation works correctly.
New 255-line test file for zero-allocation integration points API:
- Tests get_gauss_points! function for all topologies
- Validates zero-allocation performance requirement
- Tests return types (NTuple of (weight, ξ) pairs)
- Tests integration point counts for different Gauss orders
- Validates weight sums equal reference element volumes
- Tests usage in assembly loop pattern
- Includes performance benchmarking
Comprehensive test ensuring integration points API provides
zero-allocation compile-time resolved quadrature points.
New 263-line test file for strain tensor computation:
- Tests ε = ½(∇u + ∇u^T) from displacement gradients
- Tests uniaxial extension case
- Tests pure shear deformation
- Tests rigid body translation (should produce zero strain)
- Validates symmetry property (ε = ε^T)
- Tests type stability and zero-allocation performance
- Includes performance benchmark (< 200 ns target)
Comprehensive test for strain computation essential for solid
mechanics and material model evaluation.
New 384-line test file for Jacobian matrix computation:
- Tests J = ∂x/∂ξ mapping between parametric and physical coordinates
- Tests identity, scaled, and rotated element transformations
- Tests 2D triangles and 3D tetrahedra
- Tests physical derivatives: dN/dx = J⁻¹ · dN/dξ
- Validates element quality detection (det(J) > 0)
- Tests consistency with manual calculations
- Validates type stability and zero-allocation performance
- Tests both NTuple and Vector interfaces
Comprehensive test for Jacobian computation essential for coordinate
transformation and integration in FEM assembly.
New 561-line test file for deformation gradient computation:
- Tests F = ∂x/∂X = I + ∂u/∂X for finite strain mechanics
- Tests identity case (u = 0 → F = I)
- Tests pure translation (rigid body motion)
- Tests pure stretch and simple shear cases
- Tests small vs finite strain difference
- Validates physical constraints (det(F) > 0)
- Tests Hex8 and Tet10 elements
- Validates zero-allocation performance
Comprehensive test for deformation gradient computation essential
for finite strain analysis and hyperelastic materials.
New 312-line test file for single-element patch test:
- Tests core assembly infrastructure with single Tet10 element
- Validates material model (LinearElastic) stress computation
- Tests strain computation from displacement gradients
- Validates zero-allocation in assembly helpers
- Tests type stability with @inferred checks
- Validates stiffness matrix symmetry and positive definiteness
- Tests uniaxial tension case with known analytical solution
Fundamental validation test isolating assembly implementation
from mesh complexities and solver issues.
New 234-line test file for interpolate_fields functions:
- Tests single-field scalar interpolation (Temperature)
- Tests single-field vector interpolation (Displacement 2D/3D)
- Tests multi-field interpolation (Temperature + Displacement)
- Tests field value and gradient extraction
- Tests individual field extraction (interpolate_field)
- Tests value-only extraction (interpolate_field_value)
- Validates zero-allocation for all interpolation functions
- Tests NamedTuple return types with proper field structure
Comprehensive test ensuring field interpolation works correctly
for all field types and maintains zero-allocation performance.
New 218-line test file for extract_element_dofs functions:
- Tests single-field scalar extraction (Temperature)
- Tests single-field vector extraction (Displacement 2D/3D)
- Tests multi-field extraction (Temperature + Displacement)
- Tests non-contiguous DOF indices
- Tests both flat and structured extraction variants
- Validates zero-allocation for all extraction functions
- Tests NamedTuple return types with proper field names
Comprehensive test ensuring DOF extraction works correctly for
all field types and maintains zero-allocation performance.
New 425-line test file for Element construction API:
- Tests separation of concerns: Topology + Basis + Integration + Fields
- Tests 2D/3D elements: Triangles, Tetrahedra, Quadrilaterals, Hexahedra
- Tests P1 and P2 variants with correct node counts
- Validates backward compatibility aliases (Tet4, Tri3, Quad4, Hex8)
- Tests topology properties independent of basis degree
- Tests type-stable NamedTuple fields (100× faster than Dict)
- Tests integration point storage in elements
- Validates zero-allocation element access
Comprehensive test demonstrating new Element API architecture with
proper separation of concerns and type stability.
New 285-line test file verifying CElement uses real Lagrange basis:
- Tests Tri3 and Tet4 linear interpolation (exact at nodes)
- Tests gradient computation for scalar and vector DOFs
- Validates partition of unity property (sum of basis = 1)
- Tests linear reproduction (linear functions reproduced exactly)
- Tests deformation gradient for VectorDOF{2}
- Verifies basis functions from basis_generated.jl, not stubs
Ensures CElement correctly uses actual Lagrange basis functions
with proper mathematical properties.
New 118-line minimal test demonstrating complex multi-physics:
- Tests 4-field THME system (Temperature, Displacement, Pressure,
Electric potential) in under 100 lines of code
- Demonstrates all 6 bidirectional couplings (12 coupling blocks)
- Shows that complex physics does not require complex code
- Validates thermal expansion, Biot poroelasticity, thermal pressurization,
electro-osmotic, Seebeck/Peltier, and piezoelectric coupling
- Tests simultaneous assembly of all physics in one element loop
- Demonstrates type-safe field access and local-to-global mapping
Minimal but complete demonstration of multi-field Element API for
geothermal, nuclear waste, CO2 sequestration, and smart materials.
New 399-line test file demonstrating ultimate multi-physics coupling:
- Tests 4-field system: Temperature (vertices), Displacement (vertices),
Pore pressure (cells), Electric potential (edges)
- Implements fully coupled THM-E system with off-diagonal blocks
- Demonstrates thermal-mechanical coupling (K_uT)
- Demonstrates poroelastic coupling (K_up, K_pu)
- Tests simultaneous assembly in one pass for all fields
- Validates global DOF numbering across different entity types
- Shows type-safe field access: elem.dof_indices.T, .u, .p, .φ
Ultimate demonstration of multi-field Element API for complex
coupled physics: geomechanics, CO2 sequestration, nuclear waste,
electrokinetic remediation, geothermal energy.
New 166-line test file for variadic MixedDOF type system:
- Tests type-level multi-field composition with @MixedDOF macro
- Validates DOF indices structure (tuple of tuples, not NamedTuple)
- Tests DOF sharing between elements for different entity types
- Compares MixedDOF (vararg) vs NamedTuple approaches
- Demonstrates 4-field mixed system: Temperature, Displacement,
Pressure, Electric potential on different entities
Validates variadic approach to multi-field elements where DOF types
are mixed as type parameters rather than named fields.