Posted by: thebylog | March 26, 2014

New blog

I now blog at the bylog redux.

Posted by: thebylog | May 1, 2012

Risk Probabilities

A couple weeks ago, I was talking to my father and he mentioned that he had recently played a game of Risk. A natural question arose: What is the probability of succeeding when you attack with three dice against two defending dice? I thought long enough about an analytical solution to deduce that it would not be very easy (maybe I am wrong?), so I simulated it. The results:

  • You will lose two armies 25.66% of the time
  • You will lose one army 32.75% of the time
  • You will lose zero armies 41.59% of the time

Because you need to know.

[Of course, you can find this sort of thing on the web. Here, for instance, is a table that suggests that if you have five or more armies, you have a better than 50% chance of winning, as long as your opponent has no more armies than you.]

Posted by: thebylog | October 21, 2010

World Statistics Day and Bad Guessing

Yesterday was 20.10.2010 on the European calendar, and it was declared by the United Nations to be World Statistics Day. In honor of this, the Statistics Department at Miami hosted an event that included two talks and a reception.

We did our best to publicize the event, but we really had little idea about how many people would attend.

So, about 45 minutes before it started, I sent the following note to our faculty:

In the spirit of this international day of statistics, please send me your confidence limits for the number of people attending our stat day event (I will count at roughly 4:30). For instance, if you think that no less than 100 and no more than 130 will come, your interval would be (100,130).

Whoever has the narrowest interval that captures the true number attending is the winner. No word on a prize, so honor will have to do.

In total, seven intervals were put forth:

(20,50)
(35,55)
(50,70)
(50,75)
(50,150)
(55,65)
(57,70)

The actual number of people attending: 41.

The second interval in the list above was the winner, because it was the narrowest that covered the true value. Overall, only 2/7 covered the actual value of 41 which suggests that as a group we were overconfident in our ability to accurately predict. Our intervals should have been wider to accommodate our uncertainty.

At any rate, I enjoyed the event quite a lot. The talks were excellent, the food good, and the fraternization heartwarming.

P.S. To be technically correct, I should have referred to “prediction limits” instead of “confidence limits” in my e-mail.

Americans like to bang on soccer. It’s boring, too low-scoring, overrun by boorish hooligan-fanatics, yada yada yada.

But here’s the thing, World Cup games more often pass my “heart-pounding test” than NFL games or NBA playoff games.

I usually use my “heart-pounding test” to assess how much I like certain board games, like Settlers of Catan or Acquire. When my heart pounds like crazy at some point during the course of the contest, I know I really like it.

And when I apply the same test to sporting events, the World Cup beats the socks off of the NBA playoffs.

People say that the lack of scoring in soccer is a weakness. But I actually find the opposite to be true. In what other sport is there such tension for so much of the game? Since so much of the game is spent with the score so close, excitement is generated by the fact that at any moment, a game-changing play might occur.

In the NBA or NFL, scoring happens so frequently that only at the end of a tight game is the same level of competitive interest reached.

World Cup soccer works because the muted scoring rate a) results in more close games, and b) heightens the drama throughout the whole game since a game-changer could happen anytime.

Posted by: thebylog | June 16, 2010

Why We Should Teach Our Son to Sit Still in Church

I don’t want to make a habit of teaching Xavier to do or refrain from particular actions without good reasons.

We are just beginning to parent Xavier. When he was an infant, all you can do is love him and meet his needs. But somewhere along the line – I don’t know where exactly and this concerns me – it became necessary to begin to purposefully shape his character in important ways, while still loving on him like crazy.

For instance, it is critical for a child to learn to control their bodies because of the ill effects a lack of control will have when they grow older. Take for example men and sex. A man’s failure to control his body in this arena can have devastating consequences on both himself and the people he loves.

This is why I want to teach Xavier to behave in church.

Perhaps it is melodramatic to connect grown-up self-control with a child sitting still for an extended period, but as I think about why it is important, this is the larger principle that presents itself to my mind. If we probe deeper yet, I want to connect this instruction with Christ Himself, since Jesus is, as usual, our model. He showed nearly superhuman self-control in the days and hours leading up to his torture and death.

Sure, I may be overstating things: Hey there, little guy, why don’t you man up with the self-control thing like Jesus when he was contemplating the sins of the whole world being laid upon his back?. Yeah, well, I know. Yet this kind of self-discipline is vital for a man of God.

Bottom line: I aim to teach Xavier self-control, and learning to behave in church is a little piece of that larger puzzle.

When presented with a choice, there’s a theory of behavior which suggests that a rational agent chooses the action with the most perceived benefit.

Say you’re on a diet. If the perceived benefit of losing weight outweighs the dissatisfaction incurred by the diet, the theory says a rational person will stick with it. But when the diet becomes too demanding for you–the forbidden food too alluring or the required food too distasteful–the misery overtakes perceived benefit and you compromise your weight loss goals in favor of two more pieces of pizza.

So for dieting, the key is to find a strategy that is effective and sustainable, while incurring as little dissatisfaction as possible. Personally, I think such a strategy is The WHEN DIET, but this post isn’t about weight loss.

It’s about the spiritual disciplines; for instance, prayer, fasting, and meditative Scripture reading.

Can we explain Christians’ lack in these disciplines (including mine) simply as a failure of will? Are we just not trying hard enough?

Maybe.

Or maybe the benefit of daily meditation doesn’t outweigh the misery (effort) required to perform it.

But for a Christian, this is absurd. I know it. If you’re a Christian, you know it. You know that meditating on God and His Word, for instance, is a great way to fan the flame of your relationship with Christ, and you know that the benefits of such a relationship are eternal and life-changing.

But even though you and I know it, we don’t usually act like we know it. The theory, then, says that despite what we say that we know, we actually think that the effort it takes to meditate outweighs the benefits.

What we have here, I propose, is a problem of calibration.

Romans 12:2 And be not conformed to this world: but be ye transformed by the renewing of your mind, that ye may prove what is that good, and acceptable, and perfect, will of God.

I’m not going to rule out a lack of personal discipline entirely, but I think the larger issue for me is that my mind is not renewed to the point that I can discern in my spirit what God’s will is for me. In other words, my mind needs to be recalibrated so that my heart and God’s are in closer alignment.

That’s my theory.

If my mind is uncalibrated, the only way I can do what I should do is to overcome my apathy, try harder, and JUST DO IT–all on my own or with token prayers.

But renewing my mind means drawing closer to Christ and allowing him to recalibrate my “benefit” and “effort” so that the former outweighs the latter. The theory is that the doing becomes much more natural. That’s a much less discouraging, far more inviting prospect.

It is not a magic bullet, but it does put my focus in the right place.

Posted by: thebylog | April 16, 2010

Traveling Yard Saler’s Problem

The Traveling Salesman Problem (TSP) is a very famous and hard optimization problem. Given a list of destinations and the pairwise distances between them, the solution is the shortest route beginning and ending at the originating destination while visiting every other destination exactly once.

This evening my wife made a list of nine yard sales she wants to visit tomorrow. Here they are, numbered in the order she gave them to me:

Eyeballing it, I guessed a shortest route solution of 1 7 3 6 2 10 8 9 5 4 1 (i.e. beginning at our house, 1, and continuing to 7, then 3, …, until returning to 1. According to Google Maps, this route covers 28.6 miles and takes 1 hour and 10 minutes.

Using a very nice TSP solver, the route actually producing the minimum driving time is:

This second map reorders the numbers, so my eyeballed guess at a solution in terms of these new numbers is 1 2 4 3 5 9 10 8 7 6 1 versus the optimal solution of 1 2 3 4 5 6 7 8 9 10 1. The biggest difference between the optimized route and my guess is that, instead of going from 5 to 9 like I figured it would do, it takes her from 5 all the way out to 6 before coming back and eventually returning to 1. I think this is because there is no good, direct route from 6 back to home. The optimized route covers 27.3 miles and should take about 1 hour and 3 minutes.

So I saved her roughly 7 minutes! Alas, it took me well over 7 minutes to produce the optimized route. I got a kick out of it though.

On the other hand, if she would have visited the yard sales in the order she happened to write them down (i.e. 1 2 3 4 5 6 7 8 9 10 1, using the first map’s numbers again), the distance would have been 37.4 miles with an estimated time of 1 hour and 26 minutes.

Posted by: thebylog | March 30, 2010

Are you for liberty or not?

There’s a certain sort of person who agitates for the legalization of marijuana, which is an ostensibly libertarian move granting more freedom to an activity that proponents says is more benign than alcohol. But interestingly, the same type supports the nascent movement to regulate food and food constituents that are deemed abhorrent (trans fat, sodium, etc.). This strikes me as a contradiction, though I grant that the issues involved are not precisely alike.

Posted by: thebylog | February 20, 2010

Marketing

I wrote recently about a strategy of weight loss and weight maintenance that I think is very reasonable.

I feel sort of like a late-night infomercial hawking a fitness gimmick, but since I’m not and since the WHEN Diet is easily case as a weight management lifestyle and is based upon optimization arguments, I will write more about it anyway.

My previous post on the subject closed with this attempt at a tagline: “Hunger in the evening is just ounces leaving the body.”

As a memorable slogan, that’s pretty bad (not that I have any right to coin such a phrase). I like what it says but it doesn’t, shall we say, roll off the tongue. Not quite like “Pain is just weakness leaving the body.”

The other night Amy and I were talking about it, and we came up with this:

Hungry in the morning, dieters take warning.
Hungry at noon, dieters doom.
But hungry at night, dieters delight.

This succinctly sums up the WHEN strategy, I think. Whether its any better than my first try … that’s up to you to judge.

Posted by: thebylog | February 11, 2010

Knowledge Security

Paradoxically, it’s the people that know the most who probably ask the most questions in class. They are more secure in their knowledge, which gives them freedom to expose their ignorance. This in contrast with someone who may not understand but does not want to broadcast this to everyone by asking a question.

As a student, the issue is acknowledging this pride as an impediment to learning and dealing with it.

As a teacher, the question is how to foster an environment so that even people insecure in their knowledge will be comfortable asking questions and showing their ignorance.

Older Posts »

Categories

Follow

Get every new post delivered to your Inbox.