In the 1860's the physicist James Clerk Maxwell came up with the paradox
regarding the second law of thermodynamics.
This paradox came to be called Maxwell's Demon.
The paradox concerns two rooms of gas
very much like what we saw in the NetLogo model in the previous subunit.
As before the rooms are connected by a wall with an opening in it.
This time however there is a track door on the opening that can be opened or closed by a demon,
not the scary kind of demon, but simply a very smart, very small being
who can measure the speed of the molecules as they whiz past him.
In Maxwell's formulation, this demon opens the door
to let the fast molecules go from the left side to the right side
and closes it when the fast molecule was coming from the right towards the left.
Similarly, he let slow molecules go from right to left but not vice versa.
After some time there'll be many more fast molecules on the right side and slow molecules on the left side.
The system will be more ordered because he sorted the slow molecules from the fast molecules.
And this means that overall entropy of the system will be decreased.
Here's the NetLogo model of Maxwell's Demon also from the NetLogo model library.
It's also from the GasLab section, and it's called GasLab Maxwell's Demon.
Let's do setup.
Here again are the molecules, these little green dots that fly around,
colliding with one another, transfering energy to one another according to the laws of physics,
but this time we're going to have a demon in the middle.
We can't actually see him, but we can see the trap door.
And the demon's going to measure the speed of the particles
and only let fast ones go to the right and slow ones go to the left.
So let's do go.
As they collide with each other, they uh, some of them gain energy, some of them lose energy,
and the red ones are the faster ones, the blue ones are the slower ones,
and the green ones are in the middle.
And gradually the demon is letting the faster ones go over this side,
and the slower ones go over this side.
So you can see that the average speed of the right side is going up,
and the average speed of the left side is going down.
If I speed this up some, let it run for a little while.
We're actually able to see it better.
So now you can see that on average
the right side is starting to move a lot faster than the left side.
So in this case we get the opposite effect of what we saw in the previous NetLogo model.
Here the gas starts out very disordered with high entropy and gradually becomes very ordered.
Namely, the fast particles have been sorted away from the slow particles.
And the entropy decreases.
Now according to the second law of thermodynamics, some work has to be done to reduce entropy.
Where is the work here?
The demon does open and close the door, which takes work,
but Maxwell was able to argue that the door could be cleverly set up
so that opening and closing it would require very little work
as compared with the amount that entropy goes down as a result.
In fact in the years since Maxwell proposed this paradox,
some feasible designs for such a door have been proposed.
Maxwell's paradox is that no other work has been done.
In his own words, "The hot system, that is the right side, has gotten hotter
and the cold, that is the left side, has gotten colder,
and yet no work has been done,
only the intelligence of a very observant and neat-fingered being has been employed."
Maxwell's own view on the second law was that it was not a law at all,
but rather what he called "a statistical certainty,"
one that holds for a large collection of molecules not individual molecules themselves.
That is, it's possible in principle that entropy could decrease on its own,
thus violating the second law.
But in practice this is never seen because it is statistically so much more likely for entropy to increase.
We'll see why that is in the next subunit.
After the publication of his book "Theory of Heat,"
this paradox became very well-known and argued about in the science community.
Some people took it as a refutation of the second law,
but others, the defender of the second law of thermodynamics as a true law of nature.
These skeptics thought that something fishy was going on,
something was being swept under the rug.
This state of affair lasted for many years.
In 1929 Hungarian physicist Leo Szilard had a suggestion for what was being swept under the rug.
Namely, it was the demon's intelligence,
or more precisely the act of obtaining information from measurement.
Szilard proposed that this act of measurement itself takes energy
even if the process is hidden inside the brain of the demon,
and the amount of energy it takes exactly compensates for the decrease in entropy in the gas.
Szilard's famous paper,
"On the Decrease of Entropy in a Thermodynamic System by the Intervention of Intelligent Beings,"
was the first time that entropy was linked to information.
This is a link that becomes fundamental in many areas, but it took a jump for Szilard to make it.
Maxwell didn't see the intelligence or the observing power of his demon
as related to the thermodynamics of the system.
There was a strong intuition that the physical realm of the gas
and the mental realm of the demon were wholely separate in terms of the notion of energy.
But Szilard saw that accounting for the measurement process
in which the demon decides whether a particle is fast or slow
is essential in understanding the thermodynamics of the entire system.
Szilard also came up with the notion of a bit of information,
where a bit measures the amount of information needed to answer a fast or slow,
or yes or no, or any question that has two possible answers.
The field of computer science of course adopted this terminology of bits
for describing computer memory, which consists of ones and zeroes.
Many people took off from Szilard's original insight, in particular,
the physicist Rolf Landauer and the mathematician Charles Emmett,
who along with other people pioneered the new field called the physics of information,
and came up with the radical idea that information itself is a physical property.
This idea had profound implications for the limits of what can be computed
in terms of the limits of thermodynamics.
The physics of information has taken off in the form of many different books
and has been applied to quantum mechanics, electronics,
in which nanoscale Maxwell's demons can actually be built,
and more recently biology, in which the idea of Maxwell's demon
as a fundamental mechanism in biological systems has been proposed.
If you want to go further in understanding the implications of Maxwell'd Demon
in the physics of information, there are two great books
that have been edited by Harvey Left and Andrew Rex, both called Maxwell's Demon,
Maxwell's Demon 1 and Maxwell's Demon 2.
These can get a little bit technical but are great reading
if you want to deeply understand the topics involved here
and the continuing controversies about Maxwell's Demon and the second law of thermodynamics.