Pages

Sunday, April 9, 2023

Anneal Before Zod

Almost a year ago, I promised to talk about annealing, and now I'm finally getting around to it! I mentioned that you might be more familiar with it than you think, and that's because it's behind something often referred to as the Brazil Nut Effect. I'm not a big fan of mixed nuts, but I do like granola:

Granola will typically have a variety of sizes of cluster, and shaking the bag causes the larger clusters to rise to the top. This happens because the smaller clusters can pack together more densely, and by having those lower in the bag, the system is in a lower energy state. What's interesting is how we got to that lower energy – By shaking the bag, we're adding energy. This seems counterintuitive, but it's the process behind annealing.

If we imagine a potential energy plot like the one I showed a few weeks ago, we can think about how to find the lowest energy state:

We could think about rolling a ball over these hills – We'd like it to settle in the lowest troughs, around 7.5 or 10, but it could get stuck in the ones at 2 and 13, analogous to the large clusters being stuck at the bottom of the bag. To solve this, we can give the ball a temperature, which represents an average velocity. By increasing the temperature, we can get the ball to explore the full range of states, then cool it down gradually to allow it to settle in the lowest-energy position. In the graph below, I've done this with several balls, initially spaced across the full range. The red line shows the temperature, which rises and falls.

A few balls still get trapped in the higher energy states, but the majority find those central troughs. Every time I shake a container to get things to settle, I think about this effect – Maybe now you will too!

No comments:

Post a Comment