Files
pokerfreak/src/preflop/width_factor.rs
T
mmintelandClaude Opus 5.5 ec800a1672 Preflop charts and exploitation layer
Hand percentiles (169-class equity ranking, Omaha-5 structural score with
empirical CDF), position/situation inference, position x situation charts,
all-in-or-fold charts, pot-odds all-in calls, advise(); exploit style
classification, threshold adjustment and villain range guess.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-28 12:00:21 +01:00

20 lines
733 B
Rust

//! Chart width multipliers that depend on the table and the game, not on the position.
use crate::variant::HoleUsage;
/// By number of seats (index = seats). Shorthanded tables play wider, full ring tighter;
/// the six-max charts are the reference (1.0).
const BY_SEATS: [f64; 11] = [1.0, 1.0, 1.5, 1.25, 1.1, 1.05, 1.0, 0.97, 0.93, 0.9, 0.9];
/// Omaha hands run closer in equity, so the same percentile share is played a bit wider.
fn by_hole_usage(usage: HoleUsage) -> f64 {
match usage {
HoleUsage::BestFiveOfAll => 1.0,
HoleUsage::ExactlyTwoHole => 1.1,
}
}
pub fn width_factor(seats: u8, usage: HoleUsage) -> f64 {
BY_SEATS.get(seats as usize).copied().unwrap_or(0.9) * by_hole_usage(usage)
}