Boltzmann entropy when a restriction is removed (source code)

= Boltzmann entropy when a restriction is removed
{c}
{title2=$\Delta S=k_B\ln(\Omega_f/\Omega_i)$}

In <Boltzmann entropy of a two-box occupancy>, impose an initial restriction that all labels are left. There is one allowed coarse <microstate>. Remove that restriction, allowing all occupancy values: the allowed set is now the union of every occupancy <macrostate>, containing $2^N$ strings. If the final description assigns equal <probability> to this whole set, its <Boltzmann entropy> change is
$$
\Omega_i=1,\qquad \Omega_f=\sum_{k=0}^N\binom Nk=2^N,\qquad
\Delta S=k_B\ln\frac{\Omega_f}{\Omega_i}=Nk_B\ln2.
$$
The counting identity is the <binomial theorem>. For twenty labels, $\Delta S=20k_B\ln2\approx13.862944k_B$. This final description fixes neither box occupancy; it is coarser than the particular <macrostate> $k=10$, whose <Boltzmann entropy> is $k_B\ln184\,756$. The two counts answer different questions, so substituting the balanced <macrostate> for the full allowed set would change the calculation.

For four labels, the initial all-left string is `0000`; removing the restriction makes all sixteen strings available. The $k=2$ column has only six strings. Accordingly, the whole allowed set has <Boltzmann entropy> $k_B\ln16=4k_B\ln2$, while the balanced <macrostate> has <Boltzmann entropy> $k_B\ln6$.

\Image[/entropy-two-box-configuration-count.png]
{title=Sixteen configurations of four labeled particles grouped by left occupancy, compared with the all-left restriction}

Removing a barrier changes the allowed set immediately, but it does not instantaneously randomize the actual <probability distribution>. Motion and equilibration must make those configurations accessible. The counting result illustrates the configurational contribution to <free expansion>; it does not describe the relaxation time or every contribution to the <entropy> of a real <gas>.