Skip to content

Quantum Jump Simulation

This notebook guide specifies a reproducible quantum-jump simulation for a decaying two-level atom. The goal is to simulate individual conditional trajectories, average many trajectories to recover the Lindblad master equation, and verify the jump waiting-time distribution against an analytic result.

As of this review, no executable notebook under notebooks/density-open-systems/quantum-jump-simulation/ is promoted as a reproduced artifact. This page is the admission contract for that notebook: it states the model, algorithm, validation tests, convergence checks, and outputs required before numerical figures from the notebook should be cited.

The notebook should demonstrate how to:

  • simulate quantum-jump trajectories for a finite-dimensional open system;
  • distinguish conditioned pure-state trajectories from the unconditional density matrix;
  • average trajectories to recover a master-equation solution;
  • generate and validate waiting-time histograms;
  • check time-step and trajectory-number convergence;
  • record random seeds and solver tolerances;
  • diagnose normalization, positivity, and rate-convention mistakes.

The first version should stay deliberately small: a two-level atom with spontaneous emission is enough to expose the essential algorithm.

Use a dedicated directory:

notebooks/density-open-systems/quantum-jump-simulation/
quantum-jump-simulation.ipynb
README.md

The opening notebook cell or README.md should state:

  • Python and package versions;
  • random number generator and seed;
  • basis ordering;
  • time unit and rate convention;
  • whether rates are included in collapse operators;
  • time step or adaptive waiting-time method;
  • number of trajectories;
  • binning rule for waiting-time histograms;
  • acceptance tolerances for validation tests;
  • date and commit identifier when the notebook is promoted.

Use a two-level atom with

σ−=∣g⟩⟨e∣,σ+=∣e⟩⟨g∣.\sigma_-=\lvert g\rangle\langle e\rvert, \qquad \sigma_+=\lvert e\rangle\langle g\rvert.

For the baseline benchmark, work in the interaction picture with no drive:

H=0,L=Γ σ−.H=0, \qquad L=\sqrt{\Gamma}\,\sigma_-.

The unconditional master equation is

dρdt=ΓD[σ−]ρ,\frac{d\rho}{dt} = \Gamma\mathcal D[\sigma_-]\rho,

where

D[L]ρ=LρL†−12{L†L,ρ}.\mathcal D[L]\rho = L\rho L^\dagger - \frac12\{L^\dagger L,\rho\}.

Starting from the excited state,

ρ(0)=∣e⟩⟨e∣,\rho(0)=\lvert e\rangle\langle e\rvert,

the analytic excited-state population is

pe(t)=e−Γt.p_e(t) = e^{-\Gamma t}.

This is the main validation curve.

Between jumps, a pure state evolves under the effective Hamiltonian

Heff=H−iℏ2L†L.H_{\mathrm{eff}} = H - \frac{i\hbar}{2} L^\dagger L.

For a short time step dtdt, the unnormalized no-jump state is

∣ψ~(t+dt)⟩=(I−iℏHeffdt)∣ψ(t)⟩.\lvert\tilde\psi(t+dt)\rangle = \left( I - \frac{i}{\hbar} H_{\mathrm{eff}}dt \right) \lvert\psi(t)\rangle.

Its norm squared is the no-jump probability to first order in dtdt:

pno=⟨ψ~(t+dt)∣ψ~(t+dt)⟩.p_{\mathrm{no}} = \langle\tilde\psi(t+dt) \vert \tilde\psi(t+dt)\rangle.

The jump probability is

pjump=dt ⟨ψ(t)∣L†L∣ψ(t)⟩+O(dt2).p_{\mathrm{jump}} = dt\, \langle\psi(t)\vert L^\dagger L\vert\psi(t)\rangle +O(dt^2).

If a jump occurs, update

∣ψ⟩⟼L∣ψ⟩⟨ψ∣L†L∣ψ⟩.\lvert\psi\rangle \longmapsto \frac{ L\lvert\psi\rangle }{ \sqrt{\langle\psi\vert L^\dagger L\vert\psi\rangle} }.

If no jump occurs, normalize ∣ψ~(t+dt)⟩\lvert\tilde\psi(t+dt)\rangle.

The first implementation may use a fixed small time step. The pseudocode should be written in the notebook before helper functions obscure the logic:

set Gamma, dt, t_final, n_traj, seed
define basis states, sigma_minus, L
for each trajectory:
psi starts in excited state
for each time step:
compute p_jump = dt * <psi|L_dagger L|psi>
draw a uniform random number
if the random number is below p_jump:
apply jump and record jump time
otherwise:
apply no-jump evolution and normalize
store excited-state population for this trajectory
average stored populations over trajectories
compare average with exp(-Gamma t)

The notebook may later add an exact waiting-time method, but the fixed-step method is easier to audit and is sufficient for the first reproducible version if convergence is checked.

For an initially excited atom with no drive, the first jump time has survival probability

S(t)=e−Γt.S(t) = e^{-\Gamma t}.

The waiting-time density is

w(t)=−dSdt=Γe−Γt.w(t) = -\frac{dS}{dt} = \Gamma e^{-\Gamma t}.

The mean waiting time is

⟨t⟩=1Γ.\langle t\rangle = \frac{1}{\Gamma}.

The notebook should collect first-jump times from many trajectories and compare a normalized histogram with w(t)w(t). It should also compare the empirical mean with 1/Γ1/\Gamma and report a sampling uncertainty.

For each trajectory rr, form the pure-state density matrix

ρr(t)=∣ψr(t)⟩⟨ψr(t)∣.\rho_r(t) = \lvert\psi_r(t)\rangle\langle\psi_r(t)\rvert.

The Monte Carlo estimate of the unconditional state is

ρˉN(t)=1N∑r=1Nρr(t).\bar\rho_N(t) = \frac{1}{N} \sum_{r=1}^{N} \rho_r(t).

The validation target is the master-equation solution

ρME(t)=eLtρ(0),\rho_{\mathrm{ME}}(t) = e^{\mathcal L t}\rho(0),

or the analytic amplitude-damping solution for this two-level benchmark. A practical error metric is

ϵN(t)=∥ρˉN(t)−ρME(t)∥1.\epsilon_N(t) = \lVert \bar\rho_N(t) - \rho_{\mathrm{ME}}(t) \rVert_1.

The notebook should plot or tabulate the maximum error over the chosen time grid and show that the error decreases statistically as NN increases.

The notebook must include at least three convergence checks.

Run the same random seed structure or independent seeds for several time steps:

Gamma * dt = 1e-2
Gamma * dt = 5e-3
Gamma * dt = 2.5e-3

Check:

  • total jump probability per step remains small;
  • averaged pe(t)p_e(t) changes little as dtdt decreases;
  • waiting-time histograms do not shift systematically;
  • no trajectory produces a jump probability greater than one.

Run several trajectory counts:

N = 100
N = 1000
N = 10000

The error should decrease approximately like N−1/2N^{-1/2} once time-step bias is small. The notebook should not claim high precision from a small number of trajectories.

For every stored trajectory,

⟨ψ(t)∣ψ(t)⟩=1\langle\psi(t)\vert\psi(t)\rangle = 1

after normalization. For the ensemble average,

Tr⁡ρˉN(t)=1,ρˉN(t)≥0\operatorname{Tr}\bar\rho_N(t)=1, \qquad \bar\rho_N(t)\ge0

up to roundoff. These checks should be automated.

A promoted notebook should pass the following tests:

TestExpected result
excited populationtrajectory average agrees with e−Γte^{-\Gamma t} within tolerance
first-jump histogramagrees with Γe−Γt\Gamma e^{-\Gamma t} within sampling error
mean first-jump timeagrees with 1/Γ1/\Gamma within sampling error
ensemble traceequals 11 up to numerical tolerance
ensemble positivitysmallest eigenvalue is not significantly negative
no-jump normdecreases monotonically before normalization for the decay benchmark
seed reproducibilityrerunning with the saved seed reproduces stored summary data

The notebook should store numerical tolerances next to the tests rather than leaving them implicit.

After the decay benchmark passes, add a driven two-level atom in a rotating frame:

H=ℏΩ2(σ++σ−),L=Γσ−.H = \frac{\hbar\Omega}{2} (\sigma_+ + \sigma_-), \qquad L=\sqrt{\Gamma}\sigma_-.

The unconditional dynamics should be compared with a direct master-equation solver from Solving Lindblad Equations. This extension produces multiple jumps per trajectory and more interesting waiting-time statistics, but it should not replace the analytically solvable decay benchmark.

  • Forgetting whether Γ\sqrt{\Gamma} is included in LL.
  • Failing to normalize the no-jump state after each step.
  • Using a time step large enough that jump probabilities are not small.
  • Averaging state vectors instead of density matrices.
  • Comparing a single trajectory with the master-equation solution.
  • Treating the jump record as unique physics rather than an unraveling selected by photon counting.
  • Ignoring detector efficiency while interpreting simulated jumps as observed clicks.
  • Reporting a waiting-time histogram without binning and sampling uncertainty.

For the decay model with H=0H=0 and L=Γσ−L=\sqrt{\Gamma}\sigma_-, show that an initially excited no-jump state has norm squared e−Γte^{-\Gamma t} before normalization.

Solution

The effective Hamiltonian is

Heff=−iℏ2Γσ+σ−.H_{\mathrm{eff}} = - \frac{i\hbar}{2} \Gamma\sigma_+\sigma_-.

Acting on ∣e⟩\lvert e\rangle,

σ+σ−∣e⟩=∣e⟩.\sigma_+\sigma_-\lvert e\rangle = \lvert e\rangle.

Therefore the unnormalized no-jump state is

∣ψ~(t)⟩=e−Γt/2∣e⟩.\lvert\tilde\psi(t)\rangle = e^{-\Gamma t/2} \lvert e\rangle.

Its norm squared is

⟨ψ~(t)∣ψ~(t)⟩=e−Γt.\langle\tilde\psi(t)\vert\tilde\psi(t)\rangle = e^{-\Gamma t}.

Derive the waiting-time density w(t)=Γe−Γtw(t)=\Gamma e^{-\Gamma t} from the survival probability.

Solution

The survival probability is the probability that no jump has occurred up to time tt:

S(t)=e−Γt.S(t)=e^{-\Gamma t}.

The probability density for the first jump is the rate at which survival probability is lost:

w(t)=−dSdt=Γe−Γt.w(t) = - \frac{dS}{dt} = \Gamma e^{-\Gamma t}.

Why must the notebook average ∣ψr⟩⟨ψr∣\lvert\psi_r\rangle\langle\psi_r\rvert rather than ∣ψr⟩\lvert\psi_r\rangle?

Solution

The unconditional state is a density operator:

ρ(t)=E[∣ψr(t)⟩⟨ψr(t)∣].\rho(t) = \mathbb E \left[ \lvert\psi_r(t)\rangle \langle\psi_r(t)\rvert \right].

State vectors have arbitrary phases and represent conditioned pure states. Averaging the vectors themselves is not a physical density matrix and can give meaningless cancellations. Averaging projectors gives the ensemble state.

If the trajectory estimate of an observable has standard deviation ss over NN trajectories, how should its standard error scale with NN?

Solution

For independent trajectories, the standard error of the sample mean is

sN.\frac{s}{\sqrt N}.

Thus increasing the number of trajectories by a factor of 100100 reduces Monte Carlo sampling error by a factor of about 1010, once time-step bias is negligible.

  • J. Dalibard, Y. Castin, and K. Molmer, “Wave-function approach to dissipative processes in quantum optics,” Physical Review Letters 68, 580-583 (1992).
  • K. Molmer, Y. Castin, and J. Dalibard, “Monte Carlo wave-function method in quantum optics,” Journal of the Optical Society of America B 10, 524-538 (1993).
  • H. J. Carmichael, An Open Systems Approach to Quantum Optics, Springer (1993).
  • M. B. Plenio and P. L. Knight, “The quantum-jump approach to dissipative dynamics in quantum optics,” Reviews of Modern Physics 70, 101-144 (1998).
  • H. M. Wiseman and G. J. Milburn, Quantum Measurement and Control, Cambridge University Press (2010).
  • H.-P. Breuer and F. Petruccione, The Theory of Open Quantum Systems, Oxford University Press (2002).