Annus Mirabilis · Interactive critical edition in preparation
Counting configurations and osmotic pressure
Compare independently placed particles with one locked cluster.
Statistical mechanics derivation
The configuration integral laboratory
Predict before the numbers
Doubling the volume available to two independent particles multiplies the number of position arrangements by 2, 4, or 8?
The result appears when you choose, say you have one in mind, or skip.
Worked example: 2 independent particles in a volume 2 times larger have 4 times as many position arrangements, and the free energy changes by −5.61 × 10⁻²¹ J.
Step 1: one particle in the accessible volume V*
Its possible positions are proportional to the room it has.
Integral over (x₁, y₁, z₁)
B₁ = ∫ dx₁ dy₁ dz₁ = V*
Factor ratio: 2
Step 1 of 4
| Particle count | 2 |
|---|---|
| Volume expansion ratio V/V₀ | 2 |
| Position arrangement factor | 4 |
| Free-energy difference ΔF | −5.61085 × 10−21 J |
| Ideal pressure p | 4.0473725 × 10−9 Pa |
| Locked-cluster pressure | 2.0236863 × 10−9 Pa |
| Volume-independent factor J | symbolic (cancels in derivative) |
| Momentum integrals | symbolic (cancels in derivative) |
| Free-energy offset F₀ | symbolic (cancels in derivative) |
Counting where independent particles can be, not how they move, gives the pressure they exert. Twice the room gives each particle twice the places to be, and two particles four times the arrangements.
§2 derives osmotic pressure from the molecular-kinetic theory without any picture of how the particles move. The free energy is F = −(RT/N) lg B, where B is an integral over every possible state of the system. For n particles held in a volume V* by a semipermeable wall, moving independently in a homogeneous liquid with no forces on them, §2 shows that the integral splits into a factor J that depends neither on where the particles are nor on V*, times one factor of V* for each particle: B = J V*n. Then F = −(RT/N){lg J + n lg V*}, and the pressure is p = −∂F/∂V* = (RT/N)(n/V*), in modern symbols NpkBT/V. So suspended bodies and dissolved molecules of equal number exert the same osmotic pressure at high dilution. The lab's default is two particles in 2 × 10−12 m³, twice the starting volume, at 293.15 K: the free energy falls by 5.61 × 10−21 J, and the pressure is 4.05 × 10−9 Pa. With 100 particles it is 2.02 × 10−7 Pa, fifty times as much. Lock the two particles into one rigid cluster and they have only one placement to make: the free energy falls by half as much, 2.81 × 10−21 J, and the pressure is 2.02 × 10−9 Pa, that of a single particle.
Start with one particle in a box of volume V. The number of places it can be is proportional to V: twice the volume, twice the places. A second particle that moves independently of the first has its own V places, so the pair has V × V = V² arrangements, and twice the volume gives four times as many. For Np particles the count is VNp, and the rest of the integral, everything about velocities and the liquid's own molecules, is the volume-independent factor J. The free energy uses the logarithm of the count, and the logarithm turns the product into a sum: ln(J VNp) = ln J + Np ln V. So F = −kBT(ln J + Np ln V), writing kB for Einstein's R/N. Pressure is how fast the free energy falls as the volume grows, p = −∂F/∂V. The ln J term does not change with V, so it drops out, and the derivative of Np ln V is Np/V, leaving p = NpkBT/V. Now put in the default. kBT = 1.381 × 10−23 × 293.15 = 4.047 × 10−21 J, and doubling the volume changes F by −2 × 4.047 × 10−21 × ln 2 = −5.61 × 10−21 J. The pressure in 2 × 10−12 m³ is 2 × 4.047 × 10−21/(2 × 10−12) = 4.05 × 10−9 Pa. For a locked cluster the count is V, not V², so the change is −kBT ln 2 = −2.81 × 10−21 J and the pressure is kBT/V = 2.02 × 10−9 Pa: half, because one unit is placed instead of two. Nothing in the argument used the particles' size or how they move, which is why a suspended grain and a dissolved molecule count the same.
Modern qualifications
Einstein's printed §2 writes the entropy as S = E/T + 2κ lg ∫e−E/2κT dp1 … dpl, with 2κN = R, so his κ is half of the modern kB; B stands for the integral, J for the volume-independent factor, V* for the volume inside the semipermeable wall, n for the number of particles, and lg for the natural logarithm. A footnote says the section presupposes his papers on the foundations of thermodynamics of 1902 and 1903, and that the paper's results can be understood without it. The rigid cluster is a comparison authored for this site: it shows that pressure counts independently placed units, not constituents, the point the light-quanta paper's §5 makes with its exponent n.
What this model assumes
• Independence of particle positions (the §2 premise).
• Dilution (no excluded volume interactions).
• Uniform potential inside the accessible volume.
• Thermal equilibrium.
• The volume-independent factor J does not depend on volume V.
Not modeled: interactions between particles; excluded volume effects; external potential fields; non-ideal solutions; quantum statistics; momentum integrals beyond their cancellation in the derivative; molecular dynamics or collision trajectories; cluster formation or breakup kinetics.
Show which code computes these numbers
Configuration volume term, factor ratio and locked cluster pressure are computed by src/physics/reference/diffusion/routeA.ts.
Live terms bind particleCount, volume, temperature, and freeEnergy.
Show the code
The site’s own reference code for this law, in TypeScript. It computes the numbers above when the page runs it, and it is what the page uses wherever a FrankenSim result is not available.
configurationVolumeTerm · src/physics/reference/diffusion/routeA.ts · this site’s source, as built · sha256:5efc881026d009ea6b258be1989aa5d7c2a99f1725fce0ea2429a0e57be5404f
This function computes the listed outputs when it runs.
In words
For Np independent particles the volume-dependent free energy is minus k_B T times Np times the logarithm of the volume, and the change between two volumes is minus k_B T Np ln(V/V0). Differentiating gives the pressure Np k_B T / V, which is the ideal osmotic law arrived at by counting configurations rather than by assuming it. All four are returned separately: Np ln V, the free-energy term, the difference between two volumes, and the pressure.
Implementation
export function configurationVolumeTerm(
{ Np, V, V0, T }: { Np: number; V: number; V0: number; T: number },
set: ConstantSet,
): ConfigurationVolume | RouteAEvaluation {
if (
!Number.isSafeInteger(Np) ||
Np < 0 ||
![V, V0, T].every((v) => Number.isFinite(v) && v > 0)
) {
return outside(
"freeEnergy",
"configurationVolumeTerm",
"Np a nonnegative integer, V > 0, V0 > 0, T > 0",
"Use a whole particle count and positive volumes and temperature.",
"input",
set,
);
}
const kT = thermalConstant(set).value * T;
const symbolic = (
expressionRef: string,
unspecifiedSymbols: readonly string[],
): ScientificResult =>
Object.freeze({
...identity("freeEnergy", "configurationVolumeTerm"),
status: "symbolic" as const,
expressionRef,
unspecifiedSymbols,
});
return Object.freeze({
npLnV: number("freeEnergy", "configurationVolumeTerm", Np * Math.log(V), set),
freeEnergyTerm: number("freeEnergy", "configurationVolumeTerm", -kT * Np * Math.log(V), set),
deltaF: number("freeEnergy", "configurationVolumeTerm", -kT * Np * Math.log(V / V0), set),
pressure: number("osmoticPressure", "configurationVolumeTerm", (Np * kT) / V, set),
volumeIndependentFactor: symbolic("configuration-factor-J", ["J"]),
momentumIntegrals: symbolic("momentum-integrals", ["p"]),
freeEnergyOffset: symbolic("free-energy-offset", ["F0"]),
});
}The site’s own reference code for this law, in TypeScript. It computes the numbers above when the page runs it, and it is what the page uses wherever a FrankenSim result is not available.
configurationFactorRatio · src/physics/reference/diffusion/routeA.ts · this site’s source, as built · sha256:c43183b40c6387e4f2e0a7fc010ad221c0076449787b4d5d2f52374e165081b1
This function computes the listed outputs when it runs.
In words
The configuration factor is the volume ratio to the power of the particle count, which is the probability in Boltzmann's relation once it is compared with a reference state. The function returns it three ways, because at any interesting count only some of them exist: an exact decimal for a count up to 12, the natural and base-ten logarithms always, and the plain double when one can hold it. The ratio arrives as a decimal STRING and is refused if it is not an exact decimal, so the exact answer is exact.
Implementation
export function configurationFactorRatio(
Np: number,
ratio: string,
): FactorRatio | RouteAEvaluation {
if (!Number.isSafeInteger(Np) || Np < 0 || !isExactDecimal(ratio) || Number(ratio) <= 0) {
return outside(
"freeEnergy",
"configurationFactorRatio",
"Np a nonnegative integer and ratio a positive exact decimal",
"Give the volume ratio as an exact decimal string.",
);
}
const ln = Np * Math.log(Number(ratio));
const log10 = ln / Math.LN10;
let decimal: string | undefined;
if (Np <= 12) {
decimal = "1";
for (let i = 0; i < Np; i++) decimal = multiplyExactDecimal(decimal, ratio);
}
// r ** Np is correctly rounded, where exp(Np ln r) drifts (exp(500 ln 2) is off in the 14th
// digit though 2^500 is exact) and can land just under the largest double for a ratio that
// overflows it (Np = 1024, r = 2). Overflow, underflow to 0 and a subnormal result are not the
// ratio, so each reports null and the logarithms stand.
const dbl = Number(ratio) ** Np;
return Object.freeze({
...(decimal === undefined ? {} : { decimal }),
ln,
log10,
representableDouble: Number.isFinite(dbl) && dbl >= SMALLEST_NORMAL_DOUBLE ? dbl : null,
});
}The site’s own reference code for this law, in TypeScript. It computes the numbers above when the page runs it, and it is what the page uses wherever a FrankenSim result is not available.
lockedClusterPressure · src/physics/reference/diffusion/routeA.ts · this site’s source, as built · sha256:4701dd45ce653f169f66b47d6c2a29963ef53bfb8e35998832fe669eb2f23ef0
This function computes the listed outputs when it runs.
In words
Lock every particle into a single unit and the configuration factor is the volume ratio itself rather than the ratio to the power of the count, so the pressure is k_B T / V instead of Np k_B T / V. For a cubic millimetre at 290.15 K that is 4.006 times 10^-12 Pa, smaller by exactly the particle count. The two readings are returned side by side, which is what lets a reader see that the pressure is a statement about independence rather than about the particles being there.
Implementation
export function lockedClusterPressure(
V: number,
T: number,
set: ConstantSet,
): LockedCluster | RouteAEvaluation {
if (![V, T].every((v) => Number.isFinite(v) && v > 0)) {
return outside(
"osmoticPressure",
"lockedClusterPressure",
"V > 0 and T > 0",
"Use a positive volume and temperature.",
"input",
set,
);
}
const kT = thermalConstant(set).value * T;
return Object.freeze({
locked: number("osmoticPressure", "lockedClusterPressure", kT / V, set, {
modelIdentity: "locked-cluster",
modelNote:
"Perfectly locked particles move as one unit, so the factor ratio is V/V0 and the pressure is k_B T / V.",
}),
independent: outside(
"osmoticPressure",
"lockedClusterPressure",
"independence-premise-removed",
"The independent-particle pressure N_p k_B T / V is not defined once particles are locked as one unit. Pressure counts independently placed units.",
"model",
set,
),
});
}The explanation
Full explanation
Hold the temperature and volume fixed while changing what counts as an independently placed unit. The counterexample changes the independence assumption, not merely the drawing.
Show every step of the investigation
Follow one particle, two particles, the logarithm for many particles, and finally the volume derivative. Inspect the named assumptions before interpreting the pressure.
An explanatory model, not an observation of nature. This embed starts from the laboratory’s worked defaults, not a saved run. Presentation options change the surrounding guide, never the numerical inputs.