pub struct Parameters {}Expand description
The derived strategy parameters for dimension n and population size λ, computed
exactly as in Table 1 of Hansen (2016), equations (48)–(58).
Fields§
§n: usizeThe dimension n.
lambda: usizeThe population size λ (48): 4 + ⌊3 ln n⌋ by default.
mu: usizeThe number of positive weights μ = ⌊λ/2⌋.
weights: Vec<f64>The recombination weights w_1 ≥ … ≥ w_λ (53): the first μ are positive and sum to
one, the rest are non-positive (“active” CMA).
mu_eff: f64The variance effective selection mass μ_eff = (Σ w_i)² / Σ w_i² over the positive
weights.
mu_eff_negative: f64The variance effective selection mass of the negative weights, μ_eff^-.
c_m: f64The learning rate of the mean, c_m = 1 (54).
c_sigma: f64The cumulation constant of the step-size path, c_σ (55).
d_sigma: f64The step-size damping d_σ (55).
c_c: f64The cumulation constant of the rank-one path, c_c (56).
c_1: f64The rank-one learning rate c_1 (57).
c_mu: f64The rank-μ learning rate c_μ (58).
chi_n: f64E‖N(0, I)‖ ≈ √n (1 - 1/(4n) + 1/(21n²)).
Implementations§
Source§impl Parameters
impl Parameters
Sourcepub fn default_lambda(n: usize) -> usize
pub fn default_lambda(n: usize) -> usize
The default population size 4 + ⌊3 ln n⌋ (48).
Sourcepub fn new(n: usize, lambda: usize) -> Self
pub fn new(n: usize, lambda: usize) -> Self
Computes every parameter for dimension n and population size lambda.
§Panics
Panics if n == 0 or lambda < 2.
Sourcepub fn weight_sum(&self) -> f64
pub fn weight_sum(&self) -> f64
The sum of all weights Σ w_j, which enters the decay factor of (47).
Sourcepub fn eigen_interval(&self) -> u64
pub fn eigen_interval(&self) -> u64
The number of generations between eigendecompositions,
max(1, ⌊1 / (10 n (c_1 + c_μ))⌋) (Appendix B.2).