Saturday, February 4, 2017

From Hot To Cold?

EDIT: D'oh! Added a bunch about energy hypersurfaces that makes it all clearer and more correct!

Imagine you have a room with a tank of water. The ambient temperature of its room is, say, 20 C. Right now the water in the tank is still and all the same temperature (thermal & mechanical equilibrium). Below the tank is a heating element (right now this element is off), above the tank a refrigeration unit (right now this unit is off). You watch me twist knobs so that the following is true: the temperature of the layer of water on the heating element will rise (perhaps slowly) to some value greater than 20 C but the temperature of the layer of water near the refrigeration unit will remain constant at 20 C. What will happen? Of course, the water will convect. This is called "Rayleigh-Bénard Convection". Essentially, I am moving energy out of into the plate and out of the refrigerator, losing some to the inward turning motion of the fluid.

None of this is controversial. There is a temperature difference and a flow. In the study of Rayleigh-Bénard Convection, this temperature difference gives the key qualitative facts about the flow. The temperature difference controls the flow (holding other things constant). But the temperature difference does not cause the flow, even holding other things constant. The continuous energy input to maintain the temperature difference causes the flow. How is this different?

There's an economic analogy - money supply changes may control trade in a monetary economy, but it does not cause it. Desire for income causes trade. But analogy isn't enough.

Look outside the room. There's a column of air that reaches all the way up into space. Let's say the air is also still and at constant temperature (because the Earth rotates this isn't quite true, but the conditions can be obtained in a lab). There is a very distinct pressure difference in this air column. The air on the ground has exactly 1 atmosphere of pressure. This pressure declines exponentially until air molecules get so scarce that it's best to just call it a vacuum. There is a pressure difference. Yet there is no flow - air is not constantly being sucked into space. Mechanical equilibrium is consistent with potential differences.

You might say that in this case it is because the pressure potential is balanced by the gravitational potential. This won't work. In Rayleigh-Bénard Convection, the temperature potential is balanced by the gravitational potential (this is the key to analysis, in fact). But in one there is mechanical equilibrium and in the other there is not.

What happened in the Rayleigh-Bénard case then? Simple: in Rayleigh-Bénard Convection there is net energy movement. The opening paragraph was comparative statics: we move from a static condition of thermal equilibrium to a static condition of linear temperature difference. In both the thermal equilibrium and Rayleigh-Bénard Convection cases, molecular chaos gives rise to large scale order. In the thermal equilibrium cases, the order is completely described by mechanical equilibrium. In Rayleigh-Bénard Convection, there is a much richer set of large scale equilibrium states - and it is impossible to tell which one you'll end up in when starting from the mechanical equilibrium state!

To do comparative statics, we need to go back to statics again. Let's go over Boltzmann's H-"Theorem"* which tells us what we need. To do this we need to bring in some statistical mechanics concepts. We start with a "microstate". A "microstate" is a big data structure that tells us everything about a physical system to the finest detail (for historical reasons, we will use a vector as our data structure). A "macrostate" is then a function of microstates. An interesting macrostate tells us something about the system. So-called "sufficient" macrostates tell us everything that we can know about a system. In the classical setting, the sufficient macrostates are exactly the classical thermodynamic potentials, as proven by Mandelbrot. I will ignore this and just give a clear example

Look at this square. Your location (a two dimensional vector of integers) gives your microstate. The macrostates are given by capital letter. In the above drawing, there are 625 microstates and 6 macro states. This is an "energy hypersurface", each square is a possible state with the same energy. In the Rayleigh-Bénard Convection example, there is a rise in energy of the system. This takes the system to a new energy hypersurface with more squares. To make things round, we'll make it 8 new macrostates with 10,000 microstates. This table gives the breakdown:

Macrostate Side Length Number Of Microstates H
A' 1 1 0
B' 1 3 .123...
C' 2 12 .278...
D' 3 33 .391...
E' 6 120 .536...
F' 12 456 .686...
G' 25 1875 .844...
H' 50 7500 1

Again, slowly. There are 8 macrostates and 10,000 microstates (add them up if you don't believe me). I normalize the entropy so that the largest macrostate has unit entropy**. Entropy is now, as Boltzmann promised, a measure of uncertainty. If I measure a system to be in macrostate A', I know exactly the microstate. If I measure a system to be in macrostate H', I know only that it is in one of 7,500 microstates. Notice that state [1,1] means different things in the original drawing and the higher energy hypersurface. I note these new states with a prime. This is a different data structure than a pure vector, but in the usual theory one does this just with vectors.

Now we need a transition rule. One possible rule is that the system can move in any cardinal direction that doesn't exit the system. What happens when I run this system starting in macrostate A'?

It climbs up to the maximum entropy macrostate, just as Clausius intended. This is Boltzmann's H Curve! This device was introduced in his letter to Nature in 1895. It's a great illustration of his goals and vision.

Wait, can I do this, just make up a transition rule? Well, I'm a mathematician, of course I can. Boltzmann did not have the necessary mathematical tools to see when this was physically realistic though. The first person to give a microphysically realistic situation that results in a dynamic like this (the technical term is 'Markovian') was Yakov Sinai in 1963 - 70 years later. From simulations and improvements in mathematical theory, we know that there ain't no rule sayin' a dog can't play soccer isn't quite a physical law saying a physical system has to behave like this. Some complex systems have weird conserved quantities and fail to behave like the H curve above ("thermalize"). But we will assume we have such a system for now.

Just looking at the above figure, we can see H does not always increase. What happens in the long run? To illustrate this, I let the simulation go a long time (in comparison with the number of microstates), then downsampled for legibility:

We spend most of our time at the maximum entropy state, sometimes dipping down into lower equilibrium states. But given we are in an non-maximal entropy macrostate, we expect to go straight back to the maximum entropy macrostate. This can be a source of flow! In the literature, these are called the "Onsager reciprocal relation". We can check to make sure that the amount of time is the number of states in each macrostate.


Now we can come back to explaining the existence of flow in Rayleigh-Bénard Convection experiments. It starts off like the drawing above. In thermal equilbrium, the tank of water is in the maximum entropy macrostate - which in the drawing is macrostate F. When I changed the boundary conditions so that there is net energy flow, the fluid moved to a new energy hypersurface. Let's say that it moved it to macrostate A'. The number of potential states changed with the entropy. The fluid moved from the mechanical equilibrium macrostate F to macrostate A' (by fiat) to the convective macrostate H' (by H-"Theorem").*** In doing so, the entropy increased. This is the first H curve I drew. It's all as Gibbs could have told you: flow is a fundamentally statistical mechanical property.

* Why the scare-quotes? Well, for one, Boltzmann didn't prove this even by his own standards of rigor. For two, though my model can be tied up with the Perron–Frobenius theorem, the physical ideas are not always amenable to strict mathematical analysis. Boltzmann's statistical mechanics ideas were not at all easy to be really formalized. Finally, there are many H-Theorems with different proofs.

**Normalizing the entropy is equivalent to choosing Boltzmann's constant. There is something unphysical about my states. Each state is exponentially larger than the previous (about five times bigger) but in real mechanical systems we expect states to grow faster - Stirling's approximation is H ~ n log(n) rather than H ~ log(n). So in my example, H is roughly linear, but really we expect almost all the H on the maximum entropy state. I couldn't think of an easy geometric way of illustrating this (though I think Knuth gives one in "Why Pi?"). This doesn't effect the qualitative conclusions.

*** Caveat: the Rayleigh-Bénard Convection maximum entropy macrostates are no longer unique which makes the drawings more complicated without changing the essential point.

No comments:

Post a Comment