Buying a new TV set

I had hoped to replace my old CRT in a few years when the pace of innovation on the LCD side had settled down, the standards have really established themselves, more HD content feeds are available, and the prices are lower than now. But no, the CRT called it quits a few weeks ago (no more vertical beam deflection) and we are forced to buy now.

Well, shucks.

I won’t repeat what’s been discussed to death in the various videophile sites and price-comparison fora. Just one simple question:

Why don’t hand the shops out simple 1:1 scale paper pictures of the various TV sizes? It is really hard to picture how the set you see in the showroom will look like in your living room and thus decide which size you want to buy.

Thus I spent yesterday evening getting the measurements of 32, 37 and 42 inch TVs and cutting cardboard as mockups. Holding these against the wall almost instantly told us what size we really need/want.

So dear Philips, Sony, Toshiba & co: what about it?

East / West and counter-intuitive train stations

I was booking train tickets from Vienna to Budapest this week and noticed the following absurdity:

My train from Vienna to Budapest leaves at Wien Westbahnhof and arrives at Budapest Keleti pályaudvar. In other words, I’m leaving from the western train terminal in Vienna and will arrive at the eastern train station in Budapest.

So far, so good.

It’s just that Budapest is straight to the east of Vienna.

(Yes, there are good reasons for that, for the Vienna side it’s that the train is coming from Zurich. In Budapest Keleti seems to be the default station for international trains.)

Dusting off old files

Today I was trying to free up the IDE disk of my old PC to be used inside an USB enclosure as external disk for our laptops. This is pure archeology: backups of prehistoric home-directories are contained in disk-images of slightly less ancient hardware. Some of the files are there in duplicates, as I made backup copies long time ago.

One of the more interesting things I stumbled upon were the files containing my master thesis in Mathematics. That document was written in LaTeX and handed in in 1996. I haven’t touched TeX for a long time now and had no idea whether my files from back then would still work on a current Linux box.

So I installed the Ubuntu LaTeX packages on my laptop to a) test the TeX processing and to check how good the current LaTeX to HTML conversion tools work.

Everything worked surprisingly smooth except for a non-standard package I used to format and include C source code: tgrind.

It seems like the current version is no longer compatible to what I used back then, at least it doesn’t define the \tagrind macro. Luckily I had the full disk image of my old box, thus I could copy in the missing style and macro files.

Adding them to my TeX distribution made everything work. The speed on current hardware is not bad, too: a complete TeX run takes only a third of a second on my laptop. Well, the 486DX2-66 I used back then was a magnitude or two slower.

So here are the results:

Statistics and the Wall Street crash

I stumbled on an article about Nassim Taleb’s book “The Black Swan” recently. Quick summary: It’s very easy to make mistakes when applying the mathematical theory of statistics to the real world. Not everything in the world can be described as independent random variables with clearly defined properties.

So whenever you put real money behind your statistical reasoning, you better be really sure that your calculations are correct and that all the preconditions regarding applicability of the theory are met.

Furthermore, the rare event you are tempted to ignore (the “this won’t happen in my lifetime” syndrome) may have such bad results that you just shouldn’t discount it.

All this reminded me a bit of what I wrote 12 years ago in my master thesis on Pseudorandom Number Generation:

Classic statistical tests examine if the test statistic does not deviate from its expected value too much. If we are only interested in the expected outcome of a similar simulation problem, such one-level statistical tests are all we need in order to be confident about the accuracy of the simulation.

On the other hand we might be interested in the distribution of the simulation’s outcome. For this goal hitting the expected value is not enough, the variance of the result is now important, too. Thus we will demand the same behaviour from the test statistic, too.

Let us illustrate this principle with an example. We want to test the well known strategy of doubling the ante in a game of roulette. It is supposed to guarantee winning the initial ante and works like this: If we do not win in the first round (and therefore win twice the ante) the ante is doubled for the next round. If this round is won, we get back four times the initial ante while we invested three times the initial ante resulting in a net win of one ante. In case of bad luck we double the ante again hoping for eight times the ante for an investment of seven. As we hope that we will finally win before our capital is drained a net win seems to be certain.

In order to simulate this we need random numbers to determine whether we will win the current bet. The probabilities are 18/37 for winning and 19/37 for losing each round, respectively. It seems to be natural to use the lengths of runs as a test statistic to test our source of PRN for its fitness to simulate a real roulette table. The probability that the maximal run length in 500 tries is greater than 15, is smaller than all usual values for α, so according to the corresponding statistical test we should reject all sequences where such runs do occur.

When we now run the simulation with these prescreened sequences we will never ever experience a loss as long as we have enough money for 15 steps of doubling the ante. Thus we should conclude that the strategy works. As we know, this is not true. So what went wrong with our simulation ?

The statistical test considered it equally important whether the sequence in question was “well-behaved” or not, whereas the simulation assigned completely different weights to those cases. Thus the area that the test considered to be insignificant (smaller than α) played a major role in the simulation (more than 1/2).

There are some other cases of simulations where we are not so much interested in the average case, but in the extreme ones. Consider for example all those safety measures in power plants or other machinery where a rare sequence of occurrences might lead to catastrophic results. When simulating these security systems one must not a priori exclude unusual sequences.

Please note that the distinction between level-1 and level-2 tests (tests which test the distribution of the results of a level-1 test) is arbitrary. The test statistic of a level-2 test is just another function of the underlying set of PRN, too.

A rant

I’m using the AvantGo client on my nokia phone to read newspapers on the subway from/to work (and while waiting for Clemens to go to sleep). Yesterday, it stopped working. Today I debugged it and discovered that the nameservers of A1 (Mobilkom Austria) simply cannot resolve avantgo.com. The domain is fine, and IP connectivity towards them is also OK via the cell phone.

So I called up their hotline. So far, they can reproduce the problem. No solution, other than entering the IP address in the browser. If this isn’t just a bug, but a deliberate blocking, I’m going to raise hell. I’m in a bad mood.

[Update: they managed to fix this within a day. Good.]


And today’s Microsoft patchday seem to have broken switching from internal to external screen on my Thinkpad.

Great.

I’m downloading the latest Lenovo updates at speeds worthy of last century. Let’s see if that helps.

Please welcome: Elena

Just in case somebody was wondering why my blogging was non-existent recenty:

Elena

Born on May 22th, she certainly made my life even more interesting and, in close coordination with Clemens, the two children manage to consume my energy and spare time.

Up to date picture are at my gallery.