blimix: Joe as a South Park character (South Park)
Interviewer: We need someone with experience at intercepting and decrypting communications.

Me: [Smiles.] I'm kind of a big name in the field.

Interviewer: Oh?

Me: My name is Eve.

Interviewer: ...

Interviewer: You're hired.
blimix: Joe by a creek in the woods (Default)
A question for computer people: I have need of a program to optimize something, and its general form seems like a program that must have been written a thousand times already, so I'd like to save some time by not doing it all from scratch. Any leads (on existing programs or well regarded algorithms) would be appreciated. (Note that while I can program, I am not experienced in any modern environments. I wouldn't even know if what I'm looking for is a standard library function.)

The program needs to organize a set of roughly sixty elements into five groups. Each pair of elements has a numerical rating of the desirability of their being in the same group. Find the grouping that maximizes total desirability. Complicating matters is that there are three types of elements: Each group is to have one element of the first type, three of the second type, and eight of the third type.

Since there's no practical difference between group 1 and group 5, I could do an end-run around that requirement by running a smaller version of the program, um, 16!/6^5 = 168,168,000 times, once for each possible grouping of the first and second types of elements. Okay, maybe not.

I don't even know whether this is np-hard. My first visualization of a non-brute-force solution strikes me as way too complicated to bother coding. Total permutations = 40!/8!^5 * 16!/6^5 = about 1.3 * 10^33, so a brute force program finishing in a day would judge about 1.5 * 10^28 permutations per second. My computer isn't quite that fast.
blimix: Joe by a creek in the woods (Window)
So I had this awesome idea:

A usual trick for shifting to an earlier sleep cycle (or for treating seasonal affective disorder) is to spend some time looking at a light box shortly after waking up. If you have a light box. And if you have time. And if it doesn't bore you silly.

But a little bit (400 lux) of blue light is as effective as a lot (10,000 lux) of white light. And I spend hours staring at a light source -- my monitor -- most days. My monitor's brightness, 290 cd/m2, converts to 912 lux, which I assume means that it can give me 304 lux of blue. So how about this: Read all of my morning daily stuff (Livejournal, comics, news, FML, etc.) on a bright blue background! (And this is the perfect excuse to do things my mother told me not to: Sit too close to the screen, and have the lights off in the process! (Diluting the blue light with white reduces its effectiveness.))

It doesn't take any time out of my day at all, and requires no new equipment!

How to change to a blue background. )
blimix: Joe by a creek in the woods (Hat)
I just read Mark Haddon, The Curious Incident of the Dog in the Night-Time. It's a very engrossing and quick read; I rarely finish a book in a day.

I wouldn't have spent the whole day at home, but I have another cold. Drat.

Today, I cleaned some of the dust from my programming skill (the FreeCell simulation didn't count; I'm talking about stuff that needs debugging), and created a sorely needed update to a program I had written long ago, which will only be of interest to people who are very much into the game "Might and Magic VII". I haven't spent an afternoon programming in quite a while, and would even call it pleasant, if it weren't for the debugging.

I mean, really. You know that moment when you save your program, breathe a sigh of satisfaction, and are about to compile it for the first time? The rational part of you knows that there will be errors. But there's this tiny voice saying, "I'm not aware of any bugs, so maybe it'll just work!" And even though you would sooner expect pigs to fly, it still sets you up for disappointment when you see that screen full of errors. But those are just the easy ones. Once it compiles, then you get to wonder why the search is stopping after only eleven characters (because it thinks ASCII 255 is an EOF), why your output file is missing about a third of its length (because I had "!=" instead of "=="), and how you managed to overlook all those silly mistakes (by way of being sick and tired).

I just remembered the other pitfall of programming: Suddenly realizing that you haven't eaten anything all day but the white chocolate M&M's within reach of the keyboard. I'd better make some real food.
Page generated Aug. 24th, 2025 01:20 am
Powered by Dreamwidth Studios