trafficFlowRegime_count
plain-language theorem explainer
The theorem states that the inductive type of traffic flow regimes has exactly five elements. Highway traffic modelers fixing the configuration dimension to five would cite this cardinality result when enumerating dynamical regimes. The proof is a one-line decision procedure that directly computes the size from the five constructors.
Claim. The finite type of traffic flow regimes has cardinality five: $ |TrafficFlowRegime| = 5 $.
background
TrafficFlowRegime is an inductive type whose five constructors are freeFlow, synchronizedFlow, stopAndGo, jammed, and incidentDriven; the type derives DecidableEq, Repr, BEq, and Fintype instances. The module sets these five regimes equal to configDim D = 5 for highway-flow modeling. The sole upstream dependency is the inductive definition of TrafficFlowRegime itself.
proof idea
The proof is a one-line wrapper that invokes the decide tactic. This tactic enumerates the five constructors of the inductive type and confirms the cardinality equals five.
why it matters
The result populates the five_regimes field inside the downstream TrafficFlowRegimesCert definition. It fixes the discrete count of regimes at five, aligning the transportation module with the Recognition Science pattern of configuration dimensions that appear as small integers (cf. D = 3 in the spatial case). No open scaffolding remains in this declaration.
Switch to Lean above to see the machine-checked source, dependencies, and usage graph.