Expand description
Rounding-error bounds, and the failure of sums whose Ewald parts cancel.
treams-rs extension: treams returns the sum of its parts without a bound.
Structsยง
- Checked ๐
- The components of a sum that
cancellationchecks: the value unless the sum vanishes by symmetry (vanishes), which returns it as an exact zero, and each derivative that such a sum does not return as zero either, with the scalesof its slot (derivative_scale). - Rounding ๐
- First-order bounds on the absolute rounding errors of a jetโs value and of each of its derivatives, in units of epsilon.
Constantsยง
- AUTOMATIC_
GROWTH ๐ - The largest
Re(1 / (2 eta^2))of the automatic split (resolve_split):16 / pifrom|k L| = 8on, with a relative margin of 1e-12 for its rounding. - EARLY_
FAILURE_ ๐LOSS - The loss beyond which a complete sum below every automatic split fails early, while its real-space terms still add up.
- MAX_
LOSS ๐ - Largest rounding error bound of a 1D spherical sum relative to
max(|S|, 1), and largest loss of any sum to thecancellationof its Ewald parts relative to the scale of a component, before it fails. - TERM_
ULPS ๐ - Relative rounding error of every Ewald term and of the self term, in ulps, that
cancellationcounts.
Functionsยง
- below_
automatic ๐ - Whether the split
etalies below every automatic one (AUTOMATIC_GROWTH). - cancellation ๐
- The predicted absolute rounding errors, in units of epsilon, of the value and
derivatives of
sum(phasetimes the Ewaldpartsand the self termother), or a failure where they cancel beyond use: where the error of acheckedcomponent plus the truncationtailof parts that did not converge to the complete sum (Shells::tail) exceedsMAX_LOSSof its scale,max(|S|, 1)for the value and|dS| + max(|S|, 1) sfor a derivative (S = 0for a sum that vanishes by symmetry). Each component predicts the bounds of the real-space Kambe integrals (SmallSplitKambe) plusTERM_ULPStimes the moduli of the terms and of the self term, and an ulp of each compensated part (Shells). - derivative_
scale ๐ - The scale
sof the derivative in jet slotslotof a sum withdimlattice dimensions and the wavenumberk, on which it counts|dS| + max(|S|, 1) s:1 / |k|for the wavenumber and the Bloch vector,|k|for the shift and the lattice vectors. - too_
small ๐ - The failure of a sum whose cancelling Ewald parts lose
lossofmax(|S|, 1), or of aderivativeon its scale|dS| + max(|S|, 1) s.