← Home
petri-nets ode monte-carlo incidence-reduction stochastic

March Madness Without Monte Carlo

In The Incidence Reduction, the tic-tac-toe ODE under uniform rates ranked cells by their incidence degree, the number of arcs to terminal transitions. It does that approximately on the game net and exactly on the decoupled analysis net. The integers are structural, arc counts in the bipartite graph that you can read without simulating.

That result used continuous dynamics only. Here we ask the discrete question: when do continuous and stochastic methods agree on a Petri net, and when do they diverge? On the three nets below the answer turned on two properties of the net, and the incidence matrix C is the object both methods are built from.

Three Nets, Two Methods

We built three NCAA tournament ranking models with go-pflow, each encoding bracket competition as a Petri net, with the same win probabilities and different topologies. They were built on Selection Sunday 2026 to fill brackets, from hand-estimated 0–100 team stats pushed through a logistic, so the percentages below describe the model, not the tournament. The code is examples/marchmadness2026/main.go in the petri-pilot repository; the model numbers below are that file's, which also has Models 1, 3, 5 and 7. That repository is not publicly reachable at the moment, so a reader can't follow the link yet. No test asserts any of the tables. They are the program's printed output, taken from the example's notes, and they were not re-run for this revision.

Three test case net structures

Model 4: Independent chains. Eight teams, five rounds each. Each team's tokens flow through a linear pipeline — advance (rate proportional to win probability) or eliminate (rate proportional to loss probability). No shared places between teams. 100 tokens per team. Gillespie stochastic simulation.

Model 2: Coupled competition. Teams in the same region share catalytic arcs. A clash transition requires tokens from both competitors: propensity = rate x tokens_A x tokens_B. Both teams' token counts appear in the rate law. ~90 tokens per team. Gillespie stochastic simulation.

Model 6: Structural bracket. A proper bracket encoded as a Petri net. Each possible matchup has two transitions (one per winner). 96 places, 240 transitions, 960 arcs. Each team starts with exactly 1 token. Discrete round-by-round MC.

Two methods solve each model:

Same nets, same rates, same initial state. Do they produce the same rankings?

Model 4: perfect agreement. All 8 teams rank identically.

Model 2: 15 of 16 rankings disagree, and the dynamics differ in kind, not just in order:

Team            ODE Tokens   MC Mean    Rank shift
Duke                 112.8       0.3     -4
Arizona              106.5       0.2     -6
Houston               95.6       0.1    -13
Gonzaga               66.7       0.8    +12
Alabama               65.0       0.6    +12

The ODE predicts smooth competitive equilibrium. The MC shows cascading elimination — winners gain tokens, losers hit zero and stay there. Rich-get-richer dynamics that the mean-field ODE cannot capture.

Model 6: perfect agreement despite coupling. ODE championship values (scaled by 100) match MC win percentages within noise:

Team          ODE (x100)  MC Champ%
Duke              27.7      27.8
Arizona           17.5      18.4
Michigan          10.8      11.9
Houston           10.6       9.8

All 16 teams agree on championship ranking.

That one surprised us. Model 6 has coupled transitions (both teams must have a token for a matchup to fire), yet ODE and MC converge, so coupling alone doesn't cause disagreement.

The Two-Axis Rule

The resolution takes two questions.

Agreement characterization

Axis 1: Coupling. Does any transition have two or more input arcs from places with variable token counts? If not, the kinetics are linear (first-order), the Chemical Master Equation closes at the first moment, and the ODE equals the MC mean exactly. Model 4 lives here.

Axis 2: Token count. Do the coupled places hold more than 1 token? If no, the mass-action product collapses:

propensity = rate x tokens_A x tokens_B = rate x 1 x 1 = rate

The nonlinear product degenerates to a binary indicator: either both teams are alive (propensity = rate) or at least one is eliminated (propensity = 0). With nothing in between, there is no room for rich-get-richer feedback, partial depletion or correlation between pools. Model 6 lives here.

On these three nets, disagreement needed both conditions, nonlinear coupling and multi-token pools. The rule is read off three nets plus the chemical-kinetics theory below. We haven't tried it on a net it wasn't built from.

Net property ODE/MC agreement Why
Linear topology (at most 1 variable input) Agree in the mean First-order kinetics; CME closes at first moment
Nonlinear + binary tokens {0,1} Agree Product collapses to indicator
Nonlinear + high tokens + positive feedback Disagree Rich-get-richer amplifies fluctuations

This is a specific instance of the relationship between the Chemical Master Equation (exact stochastic dynamics) and the macroscopic rate equation (ODE, mean-field approximation) in chemical kinetics. Linear reaction networks agree exactly. Nonlinear networks agree in the thermodynamic limit (molecule counts tending to infinity). Our bracket finding adds a case not usually emphasized: bimolecular reactions with single-molecule reactants also agree (to within half a point here), because mass-action degenerates to an indicator.

The Incidence Matrix as Bridge

The incidence matrix C of the bracket net (96 places x 240 transitions) encodes the complete structure:

C[p][t] = output_weight(t -> p) - input_weight(p -> t)

Every column of C is a state-change vector: when transition t fires, the marking changes by exactly that column. This single matrix defines both simulation methods:

The program extracts C with go-pflow's IncidenceMatrix, and the drain counts read off it show the bracket's geometry. For each team's place at each round, count the transitions with C[p][t] < 0:

Round      R1 drains  R2 drains  F4 drains  Final drains
Every team      2          4          8          16

The doubling (2 -> 4 -> 8 -> 16) follows from how the net is built: each possible matchup is two transitions, and a team's possible opponents go 1, 2, 4, 8 from the first round to the final. With uniform rates, every team gets 6.25% = 1/16 championship probability. Pure topology gives no advantage because the bracket is symmetric.

The analytical formula is a forward propagation. For each round, take each matchup and weight the advancement probability by the opponent's survival:

P(team reaches R+1) = P(team in R) x sum over opponents [P(opp in R) x P(win | opp)]

It takes one pass per round and no simulation. Two things about it matter. First, the multiplication P(team) × P(opp) is exact only because two teams that can meet always come out of disjoint halves of the bracket, so their survivals are independent. That is a property of brackets, not of C in general. Second, the code doesn't read the matchups off C. It loops over the same list of games that built the net, and C is used only for the drain counts. Reading them off C would be mechanical, since each matchup is a pair of columns sharing the same two input places, but that routine isn't written.

Three-Way Comparison

Three methods converge

            Analytical   ODE        MC
Team        (C + rates)  (Model 6)  (10k sims)
----------  ----------   ---------  ----------
Duke           28.76%      28.32%      29.4%
Arizona        18.13%      17.86%      17.9%
Michigan       11.21%      11.04%      11.1%
Houston        10.25%      10.09%       9.8%
Florida         8.86%       8.73%       8.9%
Purdue          5.39%       5.31%       5.3%

The three agree to within about half a point. The analytical column is exact for this bracket. The ODE sits just below it, and the example's notes put the ~0.4-point gap down to finite integration time (the solve stops at t = 500). We haven't checked that by integrating longer. The MC scatters around it with sampling noise. This table and the Model 6 table above come from different runs of the program: the ODE is deterministic, yet Duke's ODE value is 27.7 in one and 28.32 in the other. Read each table on its own, not against the other.

The bridge diagram draws the relationship:

Incidence matrix as universal bridge

C defines the ODE (dm/dt = C . v) and the MC (delta_m = C . e_t) directly. The analytical formula is computed from the game list that C was built from. Our reading of why all three agree is that they compute the same function:

P(champ) = product across rounds [ sum over opponents (P(opp present) x P(win | opp)) ]

That function is fixed by which transitions connect which places (C) and the rate vector r, the team strengths as win probabilities. It is an explanation, not a derivation. Nobody has shown that the mass-action ODE on this net converges to the propagation formula, only that the numbers land within half a point of it.

Replacing Simulation

On the bracket, the exact calculation can stand in for the simulation entirely.

Each region has 4 teams and two rounds of regional play, and any of the 4 can come out of it. The program computes each region's winner distribution exactly (two first-round games, then the four possible second-round pairings) and collapses it to four winners with their probabilities. It then enumerates the 4^4 = 256 combinations of regional winners, and inside each one sums the two semifinals and four possible finals in closed form.

The program prints the exact and MC columns side by side for the championship, the final and the Final Four. The championship column sums to 100% by construction, with no sampling noise and no convergence criterion. Nothing asserts that the exact and MC columns match. It is printed output, which we haven't re-run here.

The cost the program reports is 256 configurations against 10,000 simulations × 15 games = 150,000 coin flips. A configuration isn't the same unit of work as a coin flip, but it is a few hundred times fewer steps, and the answer is exact.

This is not a novel technique for bracket prediction. FiveThirtyEight did the same analytical calculation for March Madness brackets. They were explicit about it: "Most of our sports forecasts rely on Monte Carlo simulations, but March Madness is different; because the structure of the tournament is a single-elimination bracket, we're able to directly calculate the chance of teams advancing to a given round." The formula is identical — a system of conditional probabilities, propagated forward round by round.

The difference we were after is where the bracket structure lives. FiveThirtyEight hand-coded it: procedural loops over rounds and matchups, with the bracket tree implicit in the control flow. The Petri net makes it declarative. You define places and transitions (Duke_r1, Kansas_r1, Duke_over_Kansas, Kansas_over_Duke), and the incidence matrix C falls out as a byproduct. The intent is that the advancement formula would fall out of reading C too, through a generic "propagate through C" routine in place of bracket-specific code. As built, it doesn't. Our propagation and enumeration loop over the bracket's game and region lists just as FiveThirtyEight's loops do, and the independence they rely on is a bracket fact.

Both approaches are synthesis. Someone decided the bracket has 16 teams, 4 rounds and specific matchup pairings, and neither discovers this from data. The declarative version does produce one object, C, that more than one method consumes: the ODE and the MC both run on the same net. Change the bracket structure (add a play-in round, reseed after regionals) and C changes while those two run unchanged. The enumeration hard-codes four regions of four and would have to be rewritten.

How the structure gets recognized is where we hoped to differ most. FiveThirtyEight looked at a bracket and saw "single elimination, so I can multiply conditional probabilities", a person recognizing a pattern and writing code to exploit it. The hope for the Petri-net route is that you read the structure instead: encode the domain, extract C, check the two axes. What the two-axis rule tells you is that the ODE and the MC will agree here (binary tokens, no feedback). It does not tell you a closed form exists. That also needs the sub-bracket independence above, which we recognized the same way FiveThirtyEight did. For now C exhibits the agreement condition, and a person still supplies the closed form.

The Boundary

This connects three results about what the incidence matrix reveals.

The Incidence Reduction showed that the tic-tac-toe ODE with uniform rates ranks cells by incidence degree: approximately on the game net, exactly on the decoupled analysis net. The integers are structural arc counts that the ODE reads back.

Earned Compression found that three formalisms (ODE, tropical analysis, zero-knowledge proofs) locate the same ρ boundary in a net, the line between what compresses algebraically and what requires discrete reasoning. As revised, that post says the agreement follows from one sink-property definition, so it isn't three independent discoveries.

Here the same matrix C underlies the ODE and the MC, and the two-axis rule (coupling × token count) is a proposed test for when they agree, checked on three nets. When they agree and the structure also admits a closed form, as the bracket does, simulation is doing no work the closed form can't.

A boundary with the same flavour as earned compression's, declared vs emergent constraints, shows up here. It is not the same boundary. Earned compression's ρ boundary is read off C, while this one is about whether C plus rates is enough. But they point the same way. For nets with declared structure (the bracket topology is explicit in C) and binary tokens (the nonlinearity is inert), a closed form makes simulation redundant. The bracket is a declared constraint system with binary state, and C encodes it completely.

For nets with emergent structure, where the constraint patterns arise from dynamics rather than topology, C alone is insufficient, and you need the ODE or the MC to find what C can't tell you statically. The coffee shop model's resource competition and the coupled competition model's rich-get-richer cascades are dynamics that live in the flow, not the graph. The two-axis rule sorted the three nets here correctly. Whether it sorts nets it wasn't read off is not yet tested.

References

What Changed

(2026-11-12.) Checked against examples/marchmadness2026/main.go and its notes in petri-pilot, go-pflow's IncidenceMatrix, and The Incidence Reduction and Earned Compression as revised since. Nothing was re-run.

  1. The formula doesn't read C. The post said the forward propagation identifies matchups from C and that a generic "propagate through C" routine would work on any net. In the code, the propagation and the 256-configuration enumeration both loop over the bracket's hand-built game and region lists. C is extracted only for the drain counts, and the independence the formula relies on is a bracket property. The post now says so, and says the two-axis rule predicts ODE/MC agreement, not that a closed form exists.
  2. Two runs in one post. The Model 6 table (Duke ODE 27.7, MC 27.8) and the three-way table (Duke ODE 28.32, MC 29.4) can't come from one run of a deterministic ODE with a fixed seed. Both are kept and labelled as separate runs.
  3. What's checked. No test asserts any table. Only the championship column's sum is printed, not a per-round 100%. The ODE gap's attribution to finite integration time is the notes' claim, unchecked. The two-axis rule is read off three nets. "Three orders of magnitude" is now "a few hundred times fewer steps", with the units named.
  4. Code location. The models live in petri-pilot, which isn't publicly reachable at the moment; the post says so rather than implying a reader can follow it.
  5. Upstream results. The incidence-degree recovery is approximate on the game net and exact on the analysis net. Earned compression's three formalisms agree through one definition, so they aren't independent.

Related: The Incidence Reduction · Earned Compression · Tropical Petri Nets · Tic-Tac-Toe Model · Coffee Shop Model

×

Follow on Mastodon