Skip to content
Tutorials Center
My learning

Topics

Lesson 22 of 41 ยท Scheduling and Critical Path

Monte Carlo Schedule Simulation

Learn how Monte Carlo simulation forecasts project duration: sample activity durations from ranges, run thousands of trials, read P50 and P90 dates and find what drives the risk.

CPM gives one finish date. PERT gives a mean and a standard deviation by looking at the critical path alone. Both can be misleading because the real project has several near-critical paths, and any of them can turn out longest on a given day. Monte Carlo simulation handles this by brute force: instead of computing one answer, it plays out the project thousands of times with randomly drawn durations and records how long each run takes. The result is a distribution of finish dates and honest answers to "how likely are we to make this date?"

The idea in four steps

  1. Give each activity a range, such as optimistic, most likely and pessimistic (the same three numbers used in PERT), and a distribution shape (triangular is common).
  2. For one trial, draw a random duration for every activity and run the CPM forward pass.
  3. Record the project duration. Repeat thousands of times.
  4. Analyze the recorded durations: percentiles, histogram, probability of meeting a date.
flowchart LR
    A[Ranges per activity] --> B[Draw random durations]
    B --> C[Run CPM forward pass]
    C --> D[Record project duration]
    D --> E{Enough trials?}
    E -- No --> B
    E -- Yes --> F[Percentiles and risk drivers]

Each trial is one possible future of the project.

A simulation in Python

Using the website project with ranges: (optimistic, most likely, pessimistic). The seed makes the result repeatable.

Python Simulate the website project

Press Run (or Ctrl + Enter) to see the result here.

Program input ยท what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with input()), it gets the next line from this box.

Reading the results

  • P50: half of the trials finished by this date. Committing to P50 means a coin flip.
  • P80 or P90: a date you would meet 80% or 90% of the time. Executives usually want one of these for commitments.
  • The difference between P90 and the CPM date is a measure of the schedule risk the single-point plan hides.
Python Probability of meeting a deadline

Press Run (or Ctrl + Enter) to see the result here.

Program input ยท what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with input()), it gets the next line from this box.

The deterministic most-likely path (37 days) usually has a probability well below 50% of being met. That is the "merge bias": when paths join, the project is as late as the latest of them, so the average is later than any single path suggests.

Histograms

Python Text histogram of finish dates

Press Run (or Ctrl + Enter) to see the result here.

Program input ยท what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with input()), it gets the next line from this box.

Which activities drive the risk? (sensitivity)

Beyond the date, simulation tells you criticality index (the share of trials in which an activity was on the critical path) and which activities' durations correlate most with the total. These are the activities to manage, speed up or investigate.

Python Criticality index

Press Run (or Ctrl + Enter) to see the result here.

Program input ยท what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with input()), it gets the next line from this box.

You will typically see D (Front end) critical in a decent share of trials even though CPM said it had 2 days of float. That is exactly the information a single-date schedule hides.

Using simulation well

  • Garbage in, garbage out: the ranges come from people. Calibrate against past actuals.
  • Include risk events, not just estimate uncertainty: "supplier is late" with a probability and an impact.
  • Correlation matters: if one team is slow, all its tasks are likely slow. Ignoring that understates the spread.
  • Choose a confidence level with the sponsor and state it: "80% likely by 15 October".
  • Use the same technique for cost to get a funded budget at P80, then hold contingency to match.
  • Re-run as actuals arrive: the remaining uncertainty shrinks, and the forecast converges.
  • Tools: spreadsheet add-ins, scheduling tools with simulation, or your own few lines of code like the above.

Check your understanding

Quick check ยท 4 questions

of 4 answered You scored / 4 ยท perfect!

  1. 1. What does a P80 finish date mean?

    It is the 80th percentile of the simulated durations.
  2. 2. Why is the CPM date from most-likely durations often too optimistic?

    The merge effect pushes the average completion past the deterministic date.
  3. 3. A criticality index of 40% for an activity means...

    It is the share of simulated runs where the activity drove the finish date.
  4. 4. Why set a random seed in a simulation script?

    A fixed seed gives the same random draws each run.

Summary

  • Monte Carlo draws durations from ranges, runs CPM many times and reports a distribution of finish dates.
  • Commit to P80 or P90 dates, not P50 or the deterministic date.
  • Criticality index shows which activities really drive risk.
  • Calibrate inputs, model correlation and risk events, and re-run as the project progresses.

Next: Risk Management Process