Pages

Sunday, February 5, 2023

Chilling Reports

This weekend, Mt. Washington in New Hampshire set a record for the lowest measured wind chill. I've always been a bit bothered by the idea of wind chill, since it doesn't represent what temperature it is, but instead what temperature it feels like, which seems a bit subjective. I thought I'd take a closer look at how wind chill is calculated.

There are several different models for calculating wind chill, but the principle is the same: In calm conditions, a boundary of warmer air will build up between your body and the colder air, which will slow the heat loss, but strong winds will replace that boundary with the cold air, cooling you faster. In spite of this faster cooling, you'll never get colder than the actual temperature of the air, so if you sit on top of Mt. Washington you can rest assured you won't go all the way to -108°F, but instead stay at a balmy -47°F.

Thinking about it a bit more, I suppose my real problem with wind chill is that it's using the wrong units for what it's measuring: Wind chill is meant to convey the rate of heat loss, so that's how it should be measured. That's what the original model, called the wind chill index, measured with units of kilocalories/hour/meter^2. What's nice about this is that you can clearly see that your total energy loss will depend on how long you're outside, and how exposed you are.

If you look at the Wikipedia page above, you can see the different equations for the wind chill index and the wind chill temperature. On the surface they look similar, but the wind chill temperature has a very unusual 0.16 power, which only makes me more uncomfortable with the measure. We can look at how the two compare for a range of temperature and wind speed values:


The shapes are similar, but the wind chill index has more of a bulge, indicating that it is more sensitive to the wind speed than the wind chill temperature.

The Wikipedia article states "Many formulas exist for wind chill because, unlike temperature, wind chill has no universally agreed upon standard definition or measurement. All the formulas attempt to qualitatively predict the effect of wind on the temperature humans perceive." It seems a bit silly to tout a record based on an arbitrary perception of temperature – Ever since chemo, I've found myself more easily chilled than I used to be, so maybe I'll define my own wind chill measure: The usual wind chill temperature, minus 5 degrees. New record set!

Sunday, January 29, 2023

Banditopod

Recently as part of my research, I've been trying to measure a probability distribution – specifically, the chances that we've seen a certain signal in LISA. The trouble is, there are many random noise factors that go into the calculation of whether we see the signal or not, so it's not a straight equation I can plug things into. Instead we need to sample it many times to estimate the distribution, and this can be expensive. My colleague Henri suggested I could use a technique called Markov Chain Monte Carlo (MCMC). I thought to get a better feel for the method, I'd try out a simple example here.

There's a traditional problem in probability theory called the "two-armed bandit." Imagine a slot machine with two levers – You insert a coin and choose which lever to pull. Each arm has a certain probability of paying out, but the only way to find out is by playing, and looking at how often you win or lose. What then is the best strategy for choosing a lever? You may have gotten lucky your first few pulls of one lever and overestimated its chances of winning.

We can make this more like my research by extending to a multi-armed bandit – Each arm represents a set of parameters we're searching for, and we want to pick the arm with the biggest payout/best fit to the data. Still to be answered though is how we pick which arm to play: Imagine a set of players, who can choose an arm at each step based on the wins/loses they've seen. Each one is more likely to pick an arm with lots of wins, but might try another arm just in case. Now, if we look at the estimated probabilities for each arm as time goes on, we might think we'd get a good idea of the true values:

The blue line is the true probability for each arm, and the orange dots are the estimates based on the average number of wins. The dots are jumping around so much though that it's hard to see how well we're doing. Instead of animating in time, we can try looking at how frequently we play each arm:

Pretty quickly, each arm gets a consistent rate of pulls, but it looks like we're undersampling the highest-probability arms. I think this may be due to the top-probability arms having fairly similar values – As I pointed out above, we can't tell whether we have the best lever, or just a streak of luck, so we hedge our bets. A common technique with MCMC is run a "burn in" for a while to let the players move around the parameter space, then reset the probability estimates and continue running.

As a final view of the data, we look at how the players distribute themselves among the arms through time [NB: The x-values are off by 1 compared to the earlier plot due to the way I gave the distribution to the MCMC tool I used]:

It starts off fairly flat – the parameter exploration I was talking about – but after a certain point, the distribution establishes itself, and from there the shape simply scales upward. However, even if you could afford to play tens of thousands of times, I think you'll be hard-pressed to find a slot machine paying out as frequently as these!

Sunday, December 11, 2022

Tactical Sailing

Marika is an avid sailor, and former Fleet Captain of the University of Michigan Sailing Club. In hearing about her exploits on the high seas (or Huron River, as the case may be), I've often thought about the mechanics of sailing. Specifically, I was curious if I could model the forces involved in maneuvers like tacking and jibing.

The model I came up with was to consider two connected forces on the boat: wind hitting the sail, and drag from the water. When wind hits the sail, the air bounces off, imparting momentum in the direction of the surface of the sail. The magnitude of the momentum transferred will be proportional to the dot product of the sail direction and the wind direction – maximum is when the wind hits the full face and zero when it's perpendicular. The drag from the water will be similar to the wind hitting the sail, but this time we're looking at the shape of the hull for each bit of water that hits the boat. Both these forces depend on and change the velocity of the boat, so we iterate the calculation until we find the equilibrium. To do that, we need to come up with a model for the hull of the boat.

I couldn't find any existing mathematical models for hull shape, but looking at common designs, I came up with this concept: Take two halves of an ellipse with semi-axes a and b, and put them a distance W apart. As long as W is less than 2a, the halves will intersect at each end. Now measure L from one end, and cut the remainder off. Using numbers for the width and length from here, and picking a and b that seemed reasonable, here's what I came up with:


Now to the simulation: We consider a wind going from left to right and try different orientations of the boat and sail. For each case, we start with zero velocity and calculate forces from wind and drag. Those forces give a new velocity, and we repeat until there's little change. The final velocity is shown by the arrow. Now, I didn't want to spend a lot of time figuring out the exact momentum transfer for the wind and drag, so I fudged the scaling to get reasonable results. Even with this super simple model though, we can see cases where it's possible to sail into the wind! (Look for the arrow pointing left.)


As with all of my posts, I don't recommend trying this yourself based on my calculations, but I'm hoping Marika will give me some experimental experience in the future!