the Boltzmann entropy formula
/ BOLTS-mahn /
This is the bridge from the microscopic world to thermodynamics. Entropy, that abstract thermodynamic quantity, turns out to be nothing more than the logarithm of the number of microscopic ways a macrostate can be realized. More ways, more entropy. The equation is carved on Boltzmann's tombstone in Vienna: S = k log W.
Precisely, S = k_B ln W, where W (or Omega) is the multiplicity, the number of accessible microstates of the macrostate, and k_B = 1.381 x 10^-23 J/K is Boltzmann's constant. The logarithm makes entropy additive, or extensive: two independent systems have W = W_1 W_2, so S = S_1 + S_2. The formula is defined for the microcanonical ensemble, where all microstates are equally probable; it is the special case of the more general Gibbs entropy S = -k_B sum p_i ln p_i when every p_i equals 1/W.
This one equation founds statistical mechanics: temperature emerges as 1/T = (dS/dE), and pressure and chemical potential follow the same way, so all of thermodynamics is derived by counting. An honest caveat: W depends on choosing a thin energy window, and quantum-mechanically on discrete states. Classically you need Planck's constant h to dice phase space into countable cells and a factor 1/N! for identical particles, or the entropy is ill-defined up to a constant, which is the root of the Gibbs paradox.
For N spins in a magnetic field, the macrostate with n spins up has W = N! / (n! (N-n)!) microstates, so S = k_B times the logarithm of that binomial coefficient.
Entropy peaks where the binomial coefficient does, at n = N/2, the most disordered arrangement.
Entropy is a property of the macrostate, not of any single microstate; S = k_B ln W counts how many microstates share the macrostate, so a microstate 'has' no entropy.