Struct GammaTerms
pub struct GammaTerms {
pub own: Vec<(Option<RiskAxis>, f64)>,
pub cross: Vec<(Option<RiskAxis>, Option<RiskAxis>, f64)>,
pub closure: f64,
}Expand description
The second-order term split exactly by the axis groups that moved.
With q(v) = vᵀ H v from one second-order pass along v, and d_a the
move restricted to the inputs of group a (an axis, or None for the
inputs on no axis), each own term is ½ q(d_a) and each cross term is
d_aᵀ H d_b = ½ [q(d_a + d_b) − q(d_a) − q(d_b)], the polarisation
identity. The terms sum to ½ q(Σ d_a), the one-pass quadratic, within
round-off, and no Hessian is assembled: 1 + m + m(m − 1)/2 directional
passes for m moved groups. A group with no moved input contributes
exactly zero and is left out.
Fields§
§own: Vec<(Option<RiskAxis>, f64)>½ d_aᵀ H d_a per moved group, in RiskAxis::ALL order with
None last.
cross: Vec<(Option<RiskAxis>, Option<RiskAxis>, f64)>d_aᵀ H d_b per moved pair, the first group earlier in the same
order; one symmetric number per pair.
closure: f64The one-pass quadratic less the sum of the terms: round-off, reported as a health check rather than hidden.
Implementations§
Trait Implementations§
§impl Clone for GammaTerms
impl Clone for GammaTerms
§fn clone(&self) -> GammaTerms
fn clone(&self) -> GammaTerms
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more