Choosing a solver

All algorithms use the same entry point:

sol = solve(ops, SVM(basis = 50))

Problem-level options such as state, tol, window, init, and verbose belong to solve. Algorithm options belong to the method structs.

SVM

SVM is stochastic basis growth. It draws candidates, scores each with the incremental whitened eigensolver, and commits the best admissible function.

optionmeaning
basisnumber of growth steps
candidatescandidates scored per step
scaleGaussian length scale or :auto
samplerquasi-random sampler
indep_tolCholesky-residual independence cutoff

candidates = 1 is accept-first stochastic growth. Larger values are more expensive but usually produce better bases.

Refine

Refine revisits existing basis slots and tries replacements. It requires an initial basis, either through init = sol or a pipeline.

optionmeaning
sweepscyclic refinement passes
candidatesreplacements tried per slot
scalereplacement length scale
indep_tolindependence cutoff

Variational

Variational jointly optimizes all Gaussian parameters with LBFGS and ForwardDiff/Hellmann-Feynman gradients.

optionmeaning
basisnumber of functions
scalecold-start length scale
maxiterLBFGS iteration cap
gtolgradient tolerance
gradientgradient backend, currently AutoDiff()

GrowVariational

GrowVariational adds one function at a time, then jointly optimizes the current basis after each addition.

optionmeaning
basisfinal number of functions
candidatescandidates per growth step
scalecandidate length scale
maxiter_stepLBFGS iterations per step
gtolgradient tolerance

Pipelines

Use to warm-start methods left to right:

sol = solve(ops, SVM(40) → Refine(2) → Variational(40))

Single-scale stochastic sampling can saturate at the wrong energy on multiscale systems. Gradient methods move Gaussians where fixed-scale sampling cannot reach. The recommended default workflow is SVM → Refine → Variational, with explicit scale values for hard systems.

Cost

methodrough cost
SVMO(k^2) per candidate with the incremental eigensolver
Refineup to O(k^4) per sweep in the current implementation
VariationalO(iter * n_param * k^3) engine cost
GrowVariationalrepeated variational solves over growing k