A stockout occurs when demand exceeds available fuel. A gas station then loses immediate sales and risks damaging customer trust and future business. Ordering too little risks shortages; ordering too much adds inventory holding costs. Because deliveries take an uncertain number of days, today’s ordering decision affects whether fuel is available to meet later demand. section 6.6
Listing 6.4 Environment configuration and state representation
@dataclass
class GasStationConfig:
"""Configuration class for gas station inventory environment parameters."""
max_inventory: int = 10 #A
initial_inventory: int = 4 #B
planning_horizon: int = 30 #C
demand_mean: float = 2.0 #D
demand_std_dev_factor: float = 0.5 #E
demand_min: float = 0.0 #F
demand_max: float = 10.0 #F
delivery_delay_mean: int = 2 #G
min_delivery_delay: int = 1 #H
profit_per_tank: float = 100.0 #I
stockout_penalty: float = 80.0 #J
holding_cost_per_tank: float = 5.0 #K
ordering_cost: float = 20.0 #L
The environment configuration assigns stockouts a penalty alongside fuel profits, holding costs, and ordering costs. section 6.6

