Thursday, December 25, 2008

energy

I once heard that the standby/clock display on a microwave oven uses more energy than the oven uses to cook food. I find that unlikely, so let's do a quick calculation. The microcontroller used to drive the clock or whatever's on display shouldn't draw more than a few mA, 10 at most, or else it's a piece of shit. Most LEDs (I'll assume it was an LED display, because segment LCDs consume next to nothing) are rated for 20 mA average current, though in many cases they're used with less. High-efficiency LEDs can glow sufficiently brightly with as little as 2 mA. Let's assume 20mA per LED (worst case scenario), and a display made up of 4 standard 7-segment digits and 2 dots. Now, not all LEDs are simultaneously lit, because the clock doesn't show 88:88. To find out how many LEDs are lit on average, I built the following table:

Digit Number of Segments
0 6
1 2
2 5
3 5
Partial Total 18
4 4
5 5
Partial Total 27
6 6
7 3
8 7
9 6
Total 49

Note, totally off-topic, that 4, 5 and 6 are the only digits whose 7-segment representation has the same number of segments as the digit value.
Given a 24-hour clock (the worst case scenario), the sum for all 24 hours is: 6*10 for the leading zero plus 49 for the following early hours, plus 2*10 for the leading one plus 49 for the following mid hours, plus 5*4 for the leading 2 plus 18 for the following late hours. That's 216, so diving by 24 we get 9 LEDs lit on average to display the hours.
The minutes are just as easy to calculate: There's an average of 27/6+49/10 (for the first, second digits), that is 9.4 LEDs on average. The two points average 1 if they blink, 2 if they don't (worst case, which is what we choose).
In total there are 20.4 LEDs lit, that's an average current of 410mA, holy shit that's fucking much. In reality the current is significantly lower, but this is a worst-case calculation. So the display uses at most 420mA, microcontroller included. Suppose it's supplied with 5V, that's 2.1 watts. Assuming a supply efficiency of around 50%, the standby-mode clock eats about 4W averaged over a whole day, neglecting the small intervals the oven is used for cooking.
Now for the cooking. My oven has settings for 800W, 640W and 320W or something like this. I don't know if that's the useful power or the total power drawn. For the worst-case we're discussing I'll assume it's the total power. I always use it on 800W for about 1-2 minutes. So let's say the oven is used for 10 minutes a day (an average family might use it for 20-30 minutes a day). The display eats up 4W*24(hours)*60min=5760 watt-minutes. The cooking eats up 800W*10min=8000 watt-minutes, which is more. There, the display does NOT consume more energy than the oven-proper. If I only used the oven for 5 minutes a day, and the display was a really lousy one like the one described above then yes, the display might have consumed about as much energy as the cooking. Note, my oven displays a singe 0 when not in use, so that uses more than 3 times less energy. It still eats up quite a lot of energy, which sucks, but still significantly less than the oven-proper, so there goes the propaganda down the drain.

Thursday, December 18, 2008

honk

I was relaxing in the bar, calmly enjoying my beer. Outside, the traffic was horrible. The intersection was almost blocked and the drivers were angry. A car blew its horn. I thought I saw the lights in the bar blink. It was obviously just a brain glitch. Surely the lights can't dim when a car is honking outside, can they? A great thought came to my mind. What if they actually could? I mean, when a lightning bolt hits a powerline or transformer station, the lights most certainly blink. They dim a little. The same thing happens when someone in the building is welding - the welder draws a lot of current so the line voltage decreases significantly. The question is, when a tram or trolleybus or even a train goes past the building, does it create enough of a disturbance for the lights to noticeably blink? In most cases, I guess it doesn't. But do the lights blink unnoticeably? Possibly. It's not necessarily an electrical disturbance that can cause the lights to blink. Air currents for instance do modify the light output of all devices, be them incandescent lamps, fluorescents, LEDs, whatever, simply because light output is dependent on temperature, no matter how slightly. Me shouting at the lightbulb can potentially alter its output. By how much, that's another discussion. It's certainly not noticeable, but is it measurable? If it's not directly measurable, is it at least statistically measurable? How many photons a second does a lightbulb's output vary with when a car honks outside? I don't know. Fewer than air currents cause? Electrical disturbances from people turning their TV on or off in the next building? I don't know. It's an interesting thought. My guess is about 5.

Wednesday, December 17, 2008

elevator

It's said that people who live on the first and second floors die older, because they rarely take the elevator and thus have more healthy exercise. On two occasions today I shared the elevator with people who ascended just one floor. A few days ago the elevator was nonfunctional. It was stuck at the second floor. I can't be totally sure, but my guess is that someone walked into the building, took the elevator to the second floor, got out and instead of closing the door in a civilized fashion, they kicked the fuck out of it. The door bounced back just as someone else was calling the elevator and the interlock was closing. It didn't have enough time to close so the door got stuck open. Then again, the interlock might have just been defective, not allowing the external door to open, and the person getting out might have manually opened it, got out in a civilized fashion and left it locked (it can only be overriden from the inside). If the first scenario actually happened (I don't claim it did), I can only wonder how could someone be so lazy as to take the elevator to the second floor, and at the same time blast the shit out of the door. Maybe they were in a hurry.

whistle

I've found this slightly evolved interface. It lets you whistle in commands. Plus, it uses %.2f and $_ and _#_, which makes it even cooler. And it's not 2.0.
Which reminds me: Can you whistle 2400 baud? 9600? 14400?

Thursday, December 11, 2008

netbooks

Laptops are now called notebooks, because they get too hot to hold in one's lap. From the article: "A study by State University of New York researchers found that heat generated from laptops can raise the temperature of the scrotum, potentially putting sperm count at risk." Small laptops are now called netbooks (Firefox 3 spellchecker underlines the word red) because well, I don't know why. Maybe it's because they have a network interface, as opposed to normal laptops which somehow don't. There is some truth to that: my laptop's internal wireless card failed a few months after purchase. Fuck warranty, I wouldn't have been able to use my computer for a month or so while they repaired it. I tapped the card firmly and it started working again, it worked for another week and then it finally kicked the bucket. Given the low price of PCMCIA or USB wireless cards, fuck it. Maybe I'll reflow the solder some time (fuck BGAs and fuck RoHS (I wonder what they use to replace the Pb in CRT glass - you know, the Pb that shields you from the X-rays generated in the CRT)).
Anyway, thank Microsoft for indirectly limiting netbook performance.

Sunday, November 30, 2008

techmangle

I'm watching this show on the DARPA Urban Challenge. Some team's truck, which is supposed to drive itself through a city environment, is hitting some wall. The team decide the sensors are functioning perfectly, therefore it's clearly a software problem. The software guy calmly informs his team that he can quickly reprogram the car and fix the shit. Then we see the guy inserting a line of code in some if () block. There's only one problem. The code is clearly using OpenGL to draw some lines. Whaaaaat? Nice.
This reminded me of another show I saw some years ago, where they were talking about realistically rendering moving water using computers. They took the Navier-Stokes equations that describe liquid motion and "simplified" them by either making them a puzzle and shooting out pieces, or by deleting the right hand side. This "simplification" supposedly allowed the simulation/rendering program to run at reasonable speed.

Wednesday, November 26, 2008

hmel

Part of any self-respecting ev0lvεd interf☺ce is an XML-based back-end.
I overheard the word "XML" in a conversation. It triggered the following thought: if the famous software is pronounced "teh", then how do they usually pronounce "XML" in Germany, or, for that matter, in Greece? achh em ell? och më lë? hmel? Kindly share the information if you have it. I'm really curious. Yeah.