Solvers

The solver block selects the algorithm that solves each time step's system. The type is required and case-sensitive, and must match the time integrator:

type valueSolverPair with
Hessian minimizerNewton's method (Hessian minimizer)quasi static, Newmark
explicit solverExplicit lumped-mass updatecentral difference
steepest descentMatrix-free steepest descentimplicit schemes

Hessian minimizer

Newton's method with a configurable step and optional backtracking line search.

solver:
  type: Hessian minimizer
  step: full Newton
  minimum iterations: 1
  maximum iterations: 16
  relative tolerance: 1.0e-10
  absolute tolerance: 1.0e-06
KeyRequiredDefaultMeaning
stepyesNewton step type (see Steps)
minimum iterationsyesminimum nonlinear iterations per step
maximum iterationsyesmaximum nonlinear iterations per step
absolute toleranceyesabsolute residual-norm convergence tolerance
relative toleranceyesrelative residual-norm convergence tolerance
linear solver absolute toleranceno0.0absolute tolerance for the inner CG linear solve
linear solver relative tolerancenosqrt(eps)relative tolerance for the inner CG linear solve
use line searchnofalseenable backtracking line search
line search backtrack factorno0.5step-reduction factor per backtrack
line search decrease factorno1.0e-04Armijo sufficient-decrease coefficient
line search maximum iterationsno16maximum backtracking iterations

explicit solver

Single-shot explicit update for central-difference dynamics; no nonlinear iteration or tolerances. Requires only a step, which is explicit.

solver:
  type: explicit solver
  step: explicit

steepest descent

Matrix-free steepest descent with a mandatory line search.

solver:
  type: steepest descent
  step: steepest descent
  minimum iterations: 1
  maximum iterations: 32
  relative tolerance: 1.0e-10
  absolute tolerance: 1.0e-06
KeyRequiredDefaultMeaning
stepyessteepest descent
minimum iterationsyesminimum iterations per step
maximum iterationsyesmaximum iterations per step
absolute toleranceyesabsolute convergence tolerance
relative toleranceyesrelative convergence tolerance
line search backtrack factorno0.5step-reduction factor per backtrack
line search decrease factorno1.0e-04Armijo sufficient-decrease coefficient
line search maximum iterationsno16maximum backtracking iterations
energy stagnation windowno0 (disabled)mesh smoothing only: window length for the energy stagnation exit
energy stagnation toleranceno1.0e-06mesh smoothing only: relative energy decrease below which a window counts as stalled

Energy stagnation exit (mesh smoothing)

A mesh being smoothed can reach the energy floor its topology permits long before the residual tolerances are met: near that floor the solver keeps reducing the gradient without reducing the energy, since the remedy is topology modification with an external tool, not more iterations. With energy stagnation window set to $W > 0$, the solve stops once the energy decrease over the last $W$ iterations, relative to the current energy, stays below energy stagnation tolerance for $W$ consecutive iterations. The energy still recoverable past that point is of the order of the tolerance times the energy itself. On trigger the step is accepted as converged, a message advising topology modification is logged, and the solver's stagnated flag is raised. The criterion applies to mesh smoothing models with the steepest descent solver only; setting the keys anywhere else aborts. See examples/ems/awful-cube/awful-cube-lbfgs.yaml.

Steps

The step key inside solver names the update direction. It is required and case-sensitive:

step valueStepNotes
full NewtonNewton step from the tangent (Hessian)for Hessian minimizer
explicitExplicit lumped-mass updatefor explicit solver
steepest descentNegative-gradient stepfor steepest descent
lbfgsLimited-memory BFGS quasi-Newton stepfor Hessian minimizer
KeyRequiredDefaultApplies toMeaning
step lengthno1.0all stepsscaling applied to the computed step
memoryno10lbfgsnumber of stored curvature pairs

Canonical examples

  • Newton (implicit): examples/single/implicit-dynamic-solid
  • Explicit: examples/single/explicit-dynamic-solid
  • Quasi-static Newton: examples/single/static-solid