FEA
This sub-module of TopOpt defines the finite-element analysis solvers used inside topology optimization. The solver dispatches on two orthogonal axes: the physics (LinearElasticity or HeatTransfer) and the linear-system algorithm (DirectSolver, CGAssemblySolver, or CGMatrixFreeSolver).
Abstract types
TopOpt.FEA.AbstractFEASolver — Type
AbstractFEASolverAbstract type for all FEA solvers in TopOpt. GenericFEASolver is the concrete implementation.
TopOpt.FEA.AbstractPhysics — Type
AbstractPhysicsAbstract type for the physics model dispatched on by GenericFEASolver. Subtypes: LinearElasticity (structural mechanics, dim DOFs/node) and HeatTransfer (heat conduction, 1 DOF/node).
TopOpt.FEA.LinearElasticity — Type
LinearElasticityPhysics tag for structural-mechanics problems. Selects linear-elasticity element matrices and assembly (dim DOFs per node).
TopOpt.FEA.HeatTransfer — Type
HeatTransferPhysics tag for heat-conduction problems. Selects heat-transfer element matrices and assembly (1 DOF per node).
TopOpt.FEA.AbstractLinearSolver — Type
AbstractLinearSolverAbstract type for the linear-system algorithm used inside GenericFEASolver. Subtypes: DirectSolver (factorization), CGAssemblySolver (CG with an assembled sparse matrix), CGMatrixFreeSolver (matrix-free CG).
TopOpt.FEA.SolverResult — Type
SolverResultAbstract type for the result returned by an FEA solver.
Linear solvers
TopOpt.FEA.DirectSolver — Type
DirectSolverDirect linear solver using Cholesky (or QR) factorization. The most robust option for small to medium problems.
TopOpt.FEA.CGAssemblySolver — Type
CGAssemblySolverConjugate-gradient solver with an assembled sparse matrix. Suitable for larger problems where a factorization is too expensive in memory.
TopOpt.FEA.CGMatrixFreeSolver — Type
CGMatrixFreeSolverMatrix-free conjugate-gradient solver. Avoids assembling the global stiffness matrix entirely, applying element matrices on the fly. Does not yet support inhomogeneous Dirichlet BCs.
FEA solver
TopOpt.FEA.GenericFEASolver — Type
GenericFEASolverUnified FEA solver with orthogonal physics and linear-solver dispatch. Use the FEASolver factory constructor instead of constructing this directly.
TopOpt.FEA.FEASolver — Function
FEASolver(Physics, Solver, problem; kwargs...) -> GenericFEASolver
FEASolver(Solver, problem; kwargs...) -> GenericFEASolverFactory constructor for the unified FEA solver. The second form infers the physics type from the problem type. Keyword arguments: quad_order, xmin, penalty, prev_penalty, qr, cg_max_iter, abstol, preconditioner, conv.
Matrix-free operators
TopOpt.FEA.MatrixFreeOperator — Type
MatrixFreeOperatorLinear operator that applies the global stiffness matrix without assembling it, by looping over element matrices. Used by CGMatrixFreeSolver.
TopOpt.FEA.MatrixOperator — Type
MatrixOperatorLinear operator wrapping an assembled matrix for use with IterativeSolvers' cg!.
Convergence criteria
TopOpt.FEA.ConvergenceCriteria — Type
ConvergenceCriteriaAbstract type for CG convergence criteria. Subtypes: DefaultCriteria, EnergyCriteria.
TopOpt.FEA.DefaultCriteria — Type
DefaultCriteriaDefault CG convergence criterion based on the residual norm.
TopOpt.FEA.EnergyCriteria — Type
EnergyCriteriaEnergy-based CG convergence criterion, checking the relative energy norm. Useful for stiff systems where the residual norm is a poor indicator.
Forward simulation
TopOpt.FEA.simulate — Function
simulate(solver, x)Run a forward FEA solve for the design x and return the displacement/temperature field. Convenience wrapper around the solver call operator.