Specify the system, preparation and measured work
Let a classical system have Hamiltonian \(H(z,\lambda)\), with microstate \(z\) and an externally set parameter \(\lambda\). Initially it is sampled from the canonical equilibrium distribution at \(\lambda_A\) and temperature \(T\). A prescribed protocol \(\lambda(t)\) carries it to \(\lambda_B\). Work done on the system along one trajectory is the inclusive parameter work
If \(\lambda\) is a trap centre, the generalised force in this convention is the derivative of energy with respect to that centre. A transducer reporting the opposite force exerted by the system on the actuator needs a sign change. For a stochastic subsystem in contact with a heat bath, a change of subsystem energy also includes heat. It is not generally equal to the measured protocol work. Specify the tip, trap, sample and bath boundary before turning a force trace into a work distribution.
Every run must begin from the same equilibrium preparation, not simply from whichever end state the previous protocol produced. The final state immediately after a fast drive need not be equilibrium. The free energy being inferred refers to equilibrium endpoint Hamiltonians at the same temperature. Equilibrating after the drive exchanges heat but involves no additional protocol work when the control is held fixed. Changing control during that relaxation would define a different protocol.
A Hamiltonian proof using phase-space volume
First treat an isolated driven Hamiltonian system after canonical preparation. Work along a trajectory equals \(H_B(z_f)-H_A(z_i)\). Multiply \(e^{-\beta W}\) by the initial canonical weight and integrate over initial phase space. The dependence on initial energy cancels. Hamiltonian dynamics preserves phase-space volume and is invertible, so change variables from initial to final point to obtain
Thus the Jarzynski equality follows without assuming the driving is slow. This proof requires the mapping to cover the relevant final phase space with the stated measure; idealised instantaneous removal of infinitely high constraints can create subtleties of support. For a weakly coupled thermal environment include bath variables in the Hamiltonian derivation or use a stochastic dynamics satisfying appropriate local detailed balance. Arbitrary feedback, nonequilibrium initial preparation or an unmodelled strong bath coupling does not automatically obey this simple subsystem formula.
Jensen's inequality gives
with equality for a deterministically reversible work distribution in the relevant limit. An individual run may give less work than \(\Delta F\), sometimes even work of the opposite sign. This does not violate the ensemble inequality. The exponential average weights such small-work events more strongly than their raw frequency indicates. The larger the typical dissipated work, the more difficult a direct estimate often becomes.
Solve a complete finite-time example analytically
Take one overdamped particle equilibrated in a one-dimensional harmonic trap \(H(x,\lambda)=k(x-\lambda)^2/2\) at \(\lambda=0\). Suddenly shift the centre to \(d\) while the particle position cannot respond. The endpoint free energy is unchanged by translation in an unbounded uniform bath. Initial \(x\) is Gaussian with mean zero and variance \(k_BT/k\). During the instantaneous shift
Work is Gaussian with mean \(kd^2/2\), variance \(kd^2k_BT\), and \(\Delta F=0\). Evaluating the Gaussian moment generates \(e^{-\beta\langle W\rangle+\beta^2\operatorname{var}W/2}=1\), verifying the equality exactly at arbitrary shift distance. The mechanism is visible in the trajectories: particles already on the downstream side can lose potential energy in the sudden control shift, contributing negative work and disproportionately large exponential weights.
For \(d=2\sqrt{k_BT/k}\), the mean work is two thermal energies and the standard deviation is also two thermal energies. The probability of negative work is about 0.159. For \(d=5\sqrt{k_BT/k}\), mean work is \(12.5k_BT\), standard deviation \(5k_BT\), and negative work occurs only about 0.0062 of the time. Typical runs can all show substantial positive work even though the correct free-energy change for the whole translation is zero.
The most important work values for the exponential average are not simply all values below zero. Multiplying a Gaussian \(P(W)\) by \(e^{-\beta W}\) shifts its peak to \(\langle W\rangle-\beta\operatorname{var}W\), which for this trap shift is \(-\langle W\rangle\). In the five-width shift example that important region is five standard deviations below the ordinary work mean. Observing a few negative work values can still leave the estimate badly biased if the most heavily weighted part remains unsampled.
Compare forward and reverse trajectory probabilities
Define the reverse protocol by reversing the order of control values, and reverse momenta and any time-odd external parameters as required by microscopic time reversal. Prepare its initial system independently in equilibrium at \(B\). Under microscopic reversibility the probability ratio of a forward path and its time-reversed counterpart has a boundary weight from the initial ensembles and a conditional path weight tied to heat exchange. These combine to give \(e^{\beta(W-\Delta F)}\). Grouping paths by work produces the Crooks relation
Where the two work densities coincide, \(W=\Delta F\). Integrating the relation against \(e^{-\beta W}\) recovers Jarzynski. The reverse work axis must be reflected: a crossing of two histograms plotted with the same unflipped work sign generally has no such interpretation. A finite bin estimates an integral over a work interval, so discretisation and sparse counts modify a naive pointwise log-ratio fit.
For a more general measured Gaussian forward work distribution with mean \(5.0k_BT\) and variance \(4.0(k_BT)^2\), the equality predicts \(\Delta F=3.0k_BT\) if the Gaussian law including tails is justified. With equal-variance reverse statistics, the corresponding mean of \(-W_R\) is \(1.0k_BT\). The two densities cross at \(3.0k_BT\). Plotting \(\log[P_F(W)/P_R(-W)]\) against \(W\) should give slope \(\beta\), providing a check on independent force and temperature calibration. Good agreement over a tiny overlap range does not constrain remote tails strongly.
Use the finite estimator honestly
From independent forward works \(W_i\), estimate \(\Delta F\) as minus \(k_BT\) times the logarithm of their mean exponential weight. The sample mean of weights is unbiased under correct sampling, but its logarithm is nonlinear. Jensen implies the finite-sample free-energy estimate is biased upward on average under the ideal assumptions. A single dataset can fluctuate either way. An ordinary mean-work error bar does not describe uncertainty in an exponential moment.
For Gaussian work the squared coefficient of variation of one exponential weight is \(e^{\beta^2\operatorname{var}W}-1\). With \(d=2\) thermal widths it equals
To estimate the mean weight to ten percent relative standard error by independent averaging would require roughly 5360 runs under that distribution. At five thermal widths the required count is dramatically higher. The nominal number of runs is not a sufficient convergence diagnostic: inspect the fraction of weight carried by the largest events and compare independent batches.
For numerical stability shift all dimensionless logarithmic weights by their largest value before exponentiating, then add it back after taking the logarithm. This prevents overflow without repairing missing rare events. Bootstrapping a dataset with no observations in the relevant tail cannot generate them. More gradual driving, intermediate equilibrium windows or a bidirectional estimator using forward and reverse overlap can reduce the difficulty. Each approach requires its own equilibrium preparations and sufficient overlap, not just a different final formula applied to the same deficient sample.
Discretise a real force trace without changing the work definition
For a measured optical trap centre \(\lambda_j\) and positions \(x_j\), actual control updates and acquisition clocks may be staggered. If the control moves instantaneously from \(\lambda_j\) to \(\lambda_{j+1}\) at fixed \(x_j\), its exact contribution is \(H(x_j,\lambda_{j+1})-H(x_j,\lambda_j)\). A smoothly moving control instead uses an integral of the measured generalised force, with a quadrature matched to timestamps and sampling bandwidth. A midpoint convention applied to an unresolved abrupt jump can miss a finite quadratic term.
For the harmonic trap the instantaneous work above is exactly \(k[(\lambda_j+\lambda_{j+1})/2-x_j](\lambda_{j+1}-\lambda_j)\). Taking only the initial force would give a difference \(k(\lambda_{j+1}-\lambda_j)^2/2\) per jump. Over many short smooth increments this bias may vanish under refinement, but for a deliberate quench it is the entire mean work if the initial mean displacement is zero. The distinction can be checked by reversing the jump and independently measuring the equilibrium spatial variance.
Derive the dissipated work for a constant-speed pull
Between infinitely slow displacements and a sudden quench lies an exactly soluble finite-duration example. For a harmonic trap translated at constant velocity \(u\) in an overdamped bath, the mean coordinate obeys \(\zeta\,d\langle x\rangle/dt=-k(\langle x\rangle-\lambda)\). Begin equilibrated at zero and set \(\lambda(t)=ut\) for \(0<t<t_f\). The mean lag \(\lambda-\langle x\rangle\) obeys a first-order equation and grows from zero toward \(u\tau\), with \(\tau=\zeta/k\). The mean force exerted by the actuator in this sign convention is \(k(\lambda-\langle x\rangle)\). Integrating the product of this force with control speed gives
The free-energy change for translating this uniform trap is zero. At a fixed displacement \(d=ut_f\), taking \(t_f\ll\tau\) gives \(kd^2/2\), precisely the sudden-quench mean. As \(t_f\gg\tau\) the main term is \(\zeta d^2/t_f\), tending to zero for a quasistatic pull. Simply keeping speed fixed while taking a longer time is a different limit because the endpoint then moves farther.
The fluctuating part of \(x(t)\) around its deterministic mean remains an equilibrium Ornstein–Uhlenbeck process in this additive linear model. Work is a linear functional of that Gaussian process and is therefore Gaussian. Its variance follows by integrating its covariance twice, giving \(\operatorname{var}W=2k_BT\langle W\rangle\). This recovers the exponential equality at every pull duration and supplies a nontrivial benchmark for a stochastic integrator. The probability of extracting work can be computed from the resulting Gaussian tail without assuming a second ensemble.
For a pull of two thermal widths completed in one relaxation time, use \(\zeta d^2/t_f=kd^2=4k_BT\). The bracketed dimensionless fraction is \(1-(1-e^{-1})=e^{-1}\), so mean work is \(1.47k_BT\) and standard deviation about \(1.72k_BT\). A sudden pull of the same distance has higher mean \(2k_BT\). A pull lasting five relaxation times reduces the mean to \(4k_BT[5-(1-e^{-5})]/25=0.641k_BT\). These changes predict which protocol will yield a usable work-overlap region for a finite number of trials.
A measurement can test this crossover without fitting free energy at all. Calibrate stiffness from an equilibrium position distribution, obtain the relaxation time from a correlation or driven response and predict the entire mean-work curve versus duration. Then assess Jarzynski estimates independently. Failure of the predicted variance-to-mean relation can reveal nonharmonic confinement, non-Gaussian bath forces, actuator timing offsets or insufficient equilibration. It need not invalidate the fluctuation identity itself.
A two-outcome work distribution shows how rare events restore equality
A particularly transparent work distribution comes from a sudden change in a two-level system. Initially its ground energy is zero and upper energy \(2k_BT\). In a sudden protocol move the upper level to zero while leaving the initial ground energy unchanged. The initial upper probability is
Work can take only two values: zero for an initially ground system and minus two thermal energies for a particle initially upper. Both new energy levels are degenerate, so the exact equilibrium partition ratio is
The exponential average equals \((1-p)+pe^2=1.762\), giving \(\Delta F=-0.566k_BT\). Mean work is only \(-0.238k_BT\), greater than this equilibrium free-energy change as required. With five independent realisations the probability of observing no upper preparation is
More than half such tiny samples would report zero work every time and infer a free-energy change of zero. A bootstrap resampling those five identical observations would report no empirical uncertainty at all, spectacularly missing the known sampling limitation.
Increase the initial gap to \(6k_BT\) before the same quench to degeneracy. The initial upper probability falls to 0.00247, but its exponential weight rises to \(e^6\). Its mean contribution to the exponential estimator remains near one. Even one hundred runs then miss this branch with probability about 0.78. Equality relies on the true preparation probability of a rare event combined with its enormous statistical weight. A finite dataset cannot certify absence of the branch by having no observations of it.
The reverse experiment begins with two equally populated degenerate states and raises one level. It samples the formerly rare branch far more easily. Reflect its raw works onto the forward work axis and compare point masses, not unrelated smooth histogram densities. A forward and reverse data combination then constrains the free-energy difference much more effectively. A fitted reverse sample must still begin at equilibrium in the degenerate endpoint; carrying the low excited-state fraction over from the forward final state would destroy its intended initial ensemble.
Instrumental work noise is amplified by the exponential
Suppose each genuine trajectory work is recorded with an independent Gaussian error of mean zero and variance \(s_W^2\). The arithmetic mean work stays unbiased. The mean exponential weight is multiplied by \(\exp(\beta^2s_W^2/2)\), so a naive Jarzynski estimate of free energy shifts downward by \(\beta s_W^2/2\) in energy units in the infinite-record limit. This systematic shift is distinct from the finite-record logarithm bias, which tends upward on average for ideal correctly measured weights.
For rms measurement error \(0.5k_BT\), this Gaussian-noise effect is \(-0.125k_BT\). A small positive finite-sampling bias can accidentally cancel it, producing an apparently correct number with both the work measurement and ensemble estimate wrong. Vary the number of independent trajectories and the instrument noise separately. Calibrate work reconstruction on repeated known control or force signals to estimate the error distribution rather than assuming it is Gaussian from its rms alone.
If measurement error correlates with the trajectory—for example a saturated force transducer clips the largest restoring forces—the factorisation above fails. Errors in low-work tails can matter most even if a force trace looks accurate over the bulk of ordinary values. Compare independent sensors or forward and reverse force calibrations across the full visited range. A threshold discarding negative work as unphysical would systematically delete exactly the values the equality needs.
A related problem occurs when temperature itself is inferred from the same finite fluctuation record. Temperature uncertainty affects both the exponent and conversion of the final logarithm to energy. A Gaussian work model gives an analytic sensitivity, but outside that model propagate uncertainty by re-evaluating the full weighted estimator over independently plausible temperatures and work calibrations. Treat correlations between calibration and work estimates appropriately; merely quoting the precision of the bath set point does not establish the temperature of a fast, weakly equilibrated preparation.
Verify a stochastic work protocol on a two-state network
A small simulated system with discrete energies and heat-bath jumps supplies an independent test of a coupled dynamics and work implementation. At each step change a control value instantaneously while preserving current state; record the corresponding energy difference as parameter work. Then allow a period of fixed-control stochastic relaxation whose transition probabilities preserve the new canonical distribution. Energy change during that relaxation is heat, not additional protocol work. Define the reverse process by precisely reversing the sequence of controlled changes and using an independent equilibrium start at its endpoint.
An exact proof for such a process does not require a continuum limit. After one energy change, multiplying the previous equilibrium weights by the exponential work converts them into unnormalised canonical weights of the new levels. A stochastic transition preserving these new weights leaves that weighted distribution unchanged. Apply the same argument successively and sum the final weighted probabilities to retrieve the ratio of endpoint partition functions. Each trajectory can jump many times, but the weighted identity follows from a short sequence of matrix operations.
This proof is a practical verification tool. Enumerate all paths of a two-state system over a few control steps and compare the exact weighted sum with a Monte Carlo estimate. Test a deliberately coarse but precisely specified sequence before refining the time mesh. If direct enumeration fails, inspect signs, equilibrium preparation, order of control and relaxation, and whether the transition kernel truly preserves the prescribed endpoint weights. If enumeration succeeds while sampled averages disagree, inspect rare weights and independent batch variability before modifying the underlying dynamics.
Why postselection changes a work experiment
The standard work equality assumes a specified forward protocol and its initial equilibrium ensemble. Suppose an operator begins with an equilibrium distribution in the harmonic trap but keeps only trajectories whose initial displacement already points toward the intended final centre. Those retained starts are not a canonical ensemble for the original unrestricted trap. The conditional work distribution is systematically shifted toward smaller work, so inserting it into the ordinary exponential average generally produces a biased apparent free-energy change. This selection problem arises even if no macroscopic control action visibly changes between the retained runs.
For a sudden positive shift \(d\), work decreases linearly with initial \(x\). Conditioning on \(x>0\) deletes precisely the high-work half of a symmetric Gaussian preparation. More generally, groups selected with probabilities depending on the measured initial state should be recombined using the true group frequencies if the aim is to estimate the unconditional work moment. An equal-weight average of two conditionally estimated free energies is not equivalent to averaging their exponential weights, because the logarithm is nonlinear.
If the feedback actually chooses the direction of a subsequent shift after measuring the initial position, the protocol itself is now correlated with the state. For example, shifting the trap toward the initial displacement on each run reduces average mechanical work relative to a fixed-direction protocol. The additional information and the measurement/control apparatus are part of the thermodynamic accounting. A direct substitution into the no-feedback equalities derived above would address the wrong experiment. A full information-thermodynamic treatment needs specified measurement probabilities and a well-defined corresponding reverse procedure.
A simple experimental guard is to record every attempted run, including rejected starts, along with selection and trigger conditions. Verify the initial position and energy distributions both before and after data-quality cuts. A cut based on electronic saturation can remove a physically important work tail even if it has no deliberate feedback purpose. Conversely, discarding runs for an independent external electronics failure can be statistically benign when independence is demonstrated. The fact that a cut is operationally convenient is not evidence for such independence.
The same reasoning applies to chained protocols. A sequence of small equilibrium windows can improve overlap, but each initial distribution must be re-equilibrated or appropriately reweighted. Starting each window immediately after the previous rapid drive changes its preparation. A complete path-level method may still treat the sequence consistently; multiplying independent endpoint estimates derived under a false equilibrium assumption generally does not. An explicit record of state preparation, control timing and retained trajectories is as central to a fluctuation-relation measurement as an accurate mechanical force calibration.
A useful stationary control keeps the trap centre fixed but processes position and force data through the same analysis pipeline as a moving-trap run. Correct inclusive parameter work is then zero on every trajectory because the control never changes, even though the particle exchanges random heat with the bath and its potential energy fluctuates. A processed nonzero work distribution in this test reveals that the analysis integrated a different quantity, confused particle displacement with actuator displacement or introduced artificial control noise. Conversely a real translating-trap experiment can finish with the same mean potential energy it had initially after equilibration, while having delivered positive net work and dissipated heat. Tracking both control displacement and particle displacement makes these statements testable trajectory by trajectory where the specified stochastic energy convention permits.
Determine which rare work values dominate a free-energy estimate
Change the preparation gap and the number of repetitions. Compare the average work, the exact free-energy change and the chance of missing the rare branch entirely.
Tutorial · A stiffness quench changes the equilibrium free energy
An equilibrated classical harmonic trap has stiffness \(k\). It is suddenly changed to \(2k\) at the same centre. Derive mean work, exact free-energy difference and verify the exponential equality without assuming Gaussian work.
Integrate the Gaussian position rather than a guessed Gaussian work law
Work is \(W=kx^2/2\), so mean work is \(k_BT/2\). The configurational partition function scales as \(k^{-1/2}\), giving \(\Delta F=(k_BT/2)\log2=0.3466k_BT\). The exponential-weight average is the integral of \(e^{-\beta kx^2/2}\) against the original position density proportional to \(e^{-\beta kx^2/2}\). The combined Gaussian integral yields
The work is nonnegative and chi-square distributed, not Gaussian. Its mean excess above \(\Delta F\) is about \(0.1534k_BT\).
Tutorial · Estimate a crossing with uncertainty
Measured forward and sign-reflected reverse densities have equal-variance Gaussian shapes with means 6.0 and 2.0 thermal energies. Their standard deviations are both 2.0 thermal energies. Find the crossing, verify the expected logarithmic slope and explain how an unmodelled force offset would affect a displacement protocol.
Complete the square and track the offset through both protocols
The ratio of the two Gaussian densities has logarithmic slope \((6-2)/4=1\) per thermal energy and vanishes at their midpoint \(4.0k_BT\). This is consistent with a free-energy change of four thermal energies. If fitted means have independent standard errors 0.2 and 0.3 thermal energies, their midpoint has standard error \(\sqrt{0.2^2+0.3^2}/2=0.18k_BT\) under the equal-variance model. Unknown unequal variances or poor histogram overlap require a more general fit.
An additive force calibration offset integrated over a known displacement adds a constant work shift proportional to that displacement. The reverse protocol has opposite displacement and hence opposite offset in its raw work, which becomes the same shift after reflecting its work axis. The crossing moves with both histograms and their difference need not reveal the calibration error. Independent force-zero checks matter.
Tutorial · Why an unchanged average dissipated work is insufficient
Two protocols with the same endpoints have the same mean work above equilibrium free-energy change. One has a narrow distribution near that mean and a very rare low-work tail; the other has a broader nearly Gaussian shape. Can equal mean dissipation guarantee comparable convergence of a unidirectional free-energy estimate?
Compare the quantities that govern the estimator
The mean work determines only the first moment. The exponential estimator depends on the entire distribution and its variance depends on the second exponential moment \(\langle e^{-2\beta W}\rangle\), which can differ greatly at fixed \(\langle W\rangle\) and fixed Jarzynski average. A rare low-work tail can dominate both the true mean weight and its sampling error. Identical mean dissipation does not determine its scale or frequency.
Compare forward and reverse overlap over the actual important work interval, analyse independent batches and vary protocol speed. In a proposed experiment verify initial equilibrium at each endpoint, acquisition of the full work history and calibration of temperature and control force. Convergence of a mean mechanical work with repeated trials answers a different question from convergence of an exponential estimate of equilibrium free energy.
Jarzynski · original nonequilibrium equality for free-energy differences
Crooks · entropy production and the forward/reverse work relation