A Monte Carlo decision lab Interactive simulation

Which route wins
in your world?

Which route would you choose before knowing the weather? Monte Carlo means trying many randomly chosen possibilities and comparing the results. A rough estimate can help you choose. Telling two very close options apart takes more samples. Here, every route faces the same weather in each trial.

Outer passage leads this sample. Dock 5, Channel 7.313, Outer passage 7.875. Points per trip.

Runs on your device. No accounts or AI calls.
Your harbor75% calm on each leg
Three routes out of a small harborDock is a guaranteed delivery. Channel needs one calm leg. The outer passage needs two, unless you bank cargo at its checkpoint. Select a route using the buttons below. 112ChannelOuter passageDockFar portCheckpoint N
Ready to explore. Original toy world. Numbered gates are independent weather draws. The map illustrates discrete rules.

Choose a route and commit. The trip’s hidden weather is drawn separately from the simulations.

Your last ten voyages

Exploration under these rules, not a controlled comparison. Changing the world clears this log.

  1. No voyages yet.

Make it your world

All stormsAll calm
Cargo delivered on success

Try a different question

These controls change a real local simulation.

Try possible futures before choosing

Compare the routes

16 trials tried; 48 route checks. Dock always returns 5. Outer passage has the highest average in this sample.

Complete: 16 trials.

Dock

5points / trip

16 × 5 points

Channel

7.313points / trip

3 × 0 points; 13 × 9 points

Outer passage

Highest estimate

7.875points / trip

7 × 0 points; 9 × 14 points

Each trial uses one randomly drawn weather pair for all routes. Count × cargo shows how many trials returned each amount. Each average is total cargo divided by the number of trials. Dock’s return is exact; Channel and Outer use sampled averages. The separate exact-answer panel calculates probabilities from your rules.

The uncertainty ranges overlap, so these samples do not establish a clear winner. More samples may separate them. Very close options can be hard to tell apart; this small example also has exact answers.

How uncertain is the estimate?

Dock: exact 5. Channel: 3.359 to 9. Outer passage: 1.726 to 14. Conservative 95% simultaneous coverage at the four checkpoints; assumptions below.

More trials usually narrow the range of plausible averages. The estimate itself can still move away from the exact answer on a particular run. These cautious ranges allow for checking three routes at four fixed sample counts. They rely on bounded scores and independent weather draws, approximated here by a repeatable random-number generator. Each route's range is worked out from that route's own possible scores and cut off at its highest one, so with the starting rules Channel's never goes above 9. They describe sampling noise, not whether your forecast is right. Editing or restarting begins a separate experiment.

Plan for reliable cargo and a changing forecast

These exact calculations explain your small world. They use the forecast, not the weather secretly drawn for an actual trip. On narrow screens, scroll the tables sideways. With a keyboard, focus a table and use the arrow keys.

Open this section to compare goals and stress-test the forecast.

Inspect a particular possibility

Follow one of the futures.

The first 16 sampled weather pairs stay available. Every completed sample contributes to the averages.

Run a batch, then inspect a future.

    A precise answer to the wrong question

    What if the forecast is wrong?

    Keep the sampler’s calm chance at 75%, but change the actual toy world to 50%. More samples cannot repair the old assumption.

    The simulator and actual trips currently use the same weather model.

    Try the idea somewhere else

    A delivery robot has three choices.

    Park for 5 points. Pass one gate for 9. Pass two for 14. Each independent gate opens 60% of the time. Which choice has the highest average score?

    Make a prediction. You can change your answer.

    Keep the code, inspect the method

    Save an experiment above. Download the original sampler, notebook tools and replay runner into the same folder as voyage.json. Run node replay.mjs voyage.json. Or reopen the JSON in this lesson. Scores are recomputed, rather than trusted from the file.

    Same seed, same rules, same result. Actual voyages use a separate random seed. Sample averages compare expected cargo. The delivery target compares reliability. These are different objectives. Each batch compares a fixed continuation policy. Monte Carlo tree search also builds and guides a search tree; this lesson uses flat route sampling.

    Method reference: OpenSpiel’s rollout evaluator. Interaction inspiration: Bret Victor and Seeing Theory. Jonathan Simone, Simone Systems Research. First edition, October 2026. I direct AI coding agents that write and test the code for this site. See the colophon. Sampler licensed MIT.

    Runs entirely in your browser. This small example teaches a planning technique used in AI. Not yet evaluated with learners.