Skip to main content

detect_geometric

Function detect_geometric 

Source
pub fn detect_geometric(v: &[i64]) -> Option<(i64, i64)>
Expand description

If v is an exact geometric progression base · ratioⁱ (≥3 elements, confirmed by replaying the decoder’s wrapping arithmetic), return (base, ratio).