Skip to main content
Sandbox Physics
Stochastic thermodynamics

L3 · Chapter 4

How the Jarzynski equality and the Crooks relation recover free energy from irreversible pulls

The mean work always exceeds the free-energy change, and the excess depends on how fast you pull. Average differently, taking the exponential of minus the work, and the dissipation cancels exactly, leaving the equilibrium free energy. The price is that this average rests almost entirely on rare pulls that happened to cost very little.

An average that cancels the dissipation

Start from equilibrium, repeat the same pulling protocol many times and record the work WW of each pull. Jarzynski showed in 1997 that the average of e−W/kBTe^{-W/k_BT} equals e−ΔF/kBTe^{-\Delta F/k_BT} exactly, however fast you pull. Eq. (58) of the Seifert review derives it for Langevin dynamics.

Because the exponential is convex, the average of an exponential is never smaller than the exponential of the average. Applied to the left-hand side this gives ⟨W⟩≥ΔF\langle W\rangle\ge\Delta F: the second law follows from the equality.

Check it with the Gaussian of Chapter 3. The exponential average of a Gaussian variable can be computed directly and gives ΔF=⟨W⟩−Var⁡W/2kBT\Delta F=\langle W\rangle-\operatorname{Var}W/2k_BT. With Var⁡W=2kBT Wd\operatorname{Var}W=2k_BT\,W_d the right-hand side is exactly ⟨W⟩−Wd\langle W\rangle-W_d.

⟨e−W/kBT⟩=e−ΔF/kBT⟹⟨W⟩≥ΔF\left\langle e^{-W/k_BT}\right\rangle=e^{-\Delta F/k_BT}\quad\Longrightarrow\quad \langle W\rangle\ge\Delta F
The brackets average over many independent pulls, each of which must start in equilibrium.

Source: C. Jarzynski · U. Seifert

Running the pull backwards

The reverse protocol starts in equilibrium at the end point and drags the trap back along the same path. The Crooks relation connects the two sets of pulls: the probability of forward work WW divided by the probability of reverse work −W-W equals e(W−ΔF)/kBTe^{(W-\Delta F)/k_BT}.

Where the two distributions cross the ratio is one, and the work there is ΔF\Delta F. Flip the sign of the reverse work, plot both histograms together and read off the crossing. The logarithm of the ratio is a straight line in WW with slope 1/kBT1/k_BT. With 40 000 simulated pulls in each direction, the fitted slope is 0.992±0.0070.992\pm0.007 and the crossing is at 2.40 kBT2.40\,k_BT, against the exact 2.41 kBT2.41\,k_BT.

PF(W)PR(−W)=e(W−ΔF)/kBT\frac{P_{\rm F}(W)}{P_{\rm R}(-W)}=e^{(W-\Delta F)/k_BT}
Eq. (61) of the Seifert review. Multiply both sides by PR(−W)e−W/kBTP_{\rm R}(-W)e^{-W/k_BT} and integrate over WW to recover the Jarzynski equality.
-4048work
Analytic Gaussian work distributions for the default Lab settings, work in units of kBTk_BT: forward pulls (cyan) and reverse pulls with the sign of the work flipped (amber). They cross at the free-energy change ΔF=2.41 kBT\Delta F=2.41\,k_BT (dashed line).

Source: G. E. Crooks · U. Seifert

A few pulls carry the whole average

In the exponential average, cheap pulls weigh far more than expensive ones. For a Gaussian, completing the square in e−W/kBTP(W)e^{-W/k_BT}P(W) gives another Gaussian of the same width centred at ΔF−Wd\Delta F-W_d. An accurate estimate needs enough pulls near that point.

The fraction of pulls below that centre is Φ ⁣(−2Wd/kBT)\Phi\!\left(-\sqrt{2W_d/k_BT}\right). At the default Wd=2.10 kBTW_d=2.10\,k_BT it is about 2%, roughly 4 pulls out of 200. In the Lab’s default record the single heaviest pull carries 38% of the exponential sum.

Raise the speed to 40 μm/s40\,\mu\mathrm{m/s} and Wd=6.36 kBTW_d=6.36\,k_BT; the fraction drops to 1.8×10−41.8\times10^{-4}. Two hundred pulls usually contain none, and the forward estimate comes out high: the default record gives 4.38 kBT4.38\,k_BT. Even 20 000 pulls give 3.00 kBT3.00\,k_BT. The reverse estimate errs the other way, 0.39 kBT0.39\,k_BT for the same record, and the Crooks crossing lies between them.

e−W/kBTP(W)∝exp⁡ ⁣[−(W−ΔF+Wd)24kBT Wd]e^{-W/k_BT}P(W)\propto\exp\!\left[-\frac{\big(W-\Delta F+W_d\big)^2}{4k_BT\,W_d}\right]
This holds for a Gaussian. A measured work distribution with a longer low-work tail is easier to average; one with a shorter tail is harder.

Source: U. Seifert

Worked example: four numbers from the default record

The Lab’s default record has 200 pulls in each direction. The forward mean work is 4.41 kBT4.41\,k_BT, an upper bound on ΔF\Delta F. The forward Jarzynski estimate is 2.08 kBT2.08\,k_BT, the reverse estimate 2.23 kBT2.23\,k_BT and the Crooks crossing 2.30 kBT2.30\,k_BT. The exact value is fL=2.41 kBTfL=2.41\,k_BT.

The forward estimate is low by 0.33 kBT0.33\,k_BT. Resampling the 200 pulls gives a statistical uncertainty of about 0.4 kBT0.4\,k_BT, so the miss is not unusual. Repeating the whole experiment with 40 random seeds gives a mean forward error of +0.10 kBT+0.10\,k_BT with a standard deviation of 0.29 kBT0.29\,k_BT; direct Gaussian sampling predicts +0.08±0.37 kBT+0.08\pm0.37\,k_BT. The crossing errs by −0.03±0.21 kBT-0.03\pm0.21\,k_BT, steadier than the forward estimate.

Two lessons carry over. A one-way estimate is high on average, by an amount that shrinks with the number of pulls. Using both directions is usually steadier. The last chapter measures how fast the bias falls with the number of pulls.

Try it in the Lab

Read a free energy from irreversible pulls

  1. In the Uphill drag preset, predict the order of the mean work, the Jarzynski estimate and the crossing, then compare them with the exact value.
  2. Watch the chart of the estimate as pulls accumulate and find where the curve jumps. Each jump is a single pull that cost unusually little.
  3. Switch to Rare pulls decide and resample several times. Is the forward estimate always above ΔF\Delta F? Is the crossing? Explain with the fraction formula of this chapter.

Exercises with explained answers

  1. Use the convexity of the exponential to derive the second law from the Jarzynski equality.

    Show the answer

    A convex function satisfies ⟨eX⟩≥e⟨X⟩\langle e^{X}\rangle\ge e^{\langle X\rangle}. With X=−W/kBTX=-W/k_BT this gives e−ΔF/kBT≥e−⟨W⟩/kBTe^{-\Delta F/k_BT}\ge e^{-\langle W\rangle/k_BT}; taking logarithms gives ⟨W⟩≥ΔF\langle W\rangle\ge\Delta F.

  2. Show that the probability of a pull doing at least ζ\zeta less work than ΔF\Delta F is at most e−ζ/kBTe^{-\zeta/k_BT}. What is the bound for 5 kBT5\,k_BT?

    Show the answer

    Write the equality as ⟨e−(W−ΔF)/kBT⟩=1\langle e^{-(W-\Delta F)/k_BT}\rangle=1. Keep only pulls with W<ΔF−ζW<\Delta F-\zeta: each contributes more than eζ/kBTe^{\zeta/k_BT}, so their probability times eζ/kBTe^{\zeta/k_BT} cannot exceed 1. For 5 kBT5\,k_BT the bound is about 0.00670.0067. Single pulls can beat the second law, but large violations become exponentially rare.

  3. In a fast-pull experiment the forward Jarzynski estimate is 4.38 kBT4.38\,k_BT and the reverse estimate 0.39 kBT0.39\,k_BT. What would you report?

    Show the answer

    The two one-way estimates are biased in opposite directions, so the true value should lie between them. Use both data sets together, for example by reading the Crooks crossing, and report a resampling uncertainty. If that uncertainty is still too large, pull more slowly or collect more pulls.

Sources and what we recomputed

  1. U. Seifert, Stochastic thermodynamics, fluctuation theorems and molecular machines, arXiv:1205.4176v1; Reports on Progress in Physics 75, 126001 (2012)

    Version 1, 18 May 2012. Section 2: overdamped Langevin dynamics, Eq. (14) for the heat released into the medium and Eqs. (15)–(19) for the first law along one trajectory. Section 4: Eqs. (58) and (61), the Jarzynski and Crooks relations. Section 6.2: entropy production for master equations, Eqs. (120)–(129). Section 7.2: relative-entropy bounds on dissipation, Eqs. (146)–(150). Section 7.3: measurement and feedback, Eqs. (151)–(163).

  2. C. Jarzynski, A nonequilibrium equality for free energy differences, arXiv:cond-mat/9610209v1; Physical Review Letters 78, 2690–2693 (1997)

    Version 1, 30 October 1996. The equality between the exponential average of work over repeated switching from equilibrium and the equilibrium free-energy difference. We read the abstract and the setup; the derivation in this course is the Langevin version given in the Seifert review.

  3. G. E. Crooks, Entropy production fluctuation theorem and the nonequilibrium work relation for free energy differences, arXiv:cond-mat/9901352v4; Physical Review E 60, 2721–2726 (1999)

    Version 4. The ratio of forward and time-reversed work distributions. We use the relation in the form of Seifert Eq. (61) and test it on simulated pulls; we did not reproduce the paper’s own examples.

FeedbackSomething broken, confusing, or missing on this page?Tell us
What kind of feedback?

Sent with this page’s address, its Lab ID, the site language and your device type. Please leave out personal details. Feedback is kept for up to 12 months.Privacy policy