« Tarot spread generator | Home | Stimulants »

Plaid code

Thu 19 May 2011 by mskala Tags used: ,

Fans of my fiction writing will doubtless remember my theory that in the Future, girls' school-uniform skirts will be made of "smart fiber," capable of changing colour under computer control to act as a sort of display screen, and the wearers will use that to encode personal information into the plaid stripes of something like a present-day 2D barcode. Such technology already exists today (it's closely related to "e-paper"), though it isn't cheap and rugged enough yet for serious use in clothing.

Well, in one of my nefarious projects I recently had occasion to actually use a data-to-tartan encoding scheme, and you might find the results interesting. Here's a sample:

[Plaid code swatches]

See if you can reverse-engineer the encoding that generated those swatches. It's quite simple, and has an historical basis.

4 comments

A. Fountain
Looks like a Roman numeral sequence. White line for one, blue line for five, white-on-red for ten. I can't quite figure out how 19 fits into the pattern, though.
A. Fountain - 2011-05-19 17:05
Matt
Very good! 19 isn't any exception, the same rules determine it that determine the others. Looking at 4 and 9 might be instructive.
Matt - 2011-05-19 17:20
A. Fountain
Ah. I think I get it. Symmetrical from center. 19 = XIX (XIXIX) = red-white-red (red-white-red-white-red).

Which then makes 2 and 3 special cases.
A. Fountain - 2011-05-19 19:19
Matt
2 is to 1 as 20 is to 10 (and 30 would fit the same pattern if we went that far). Probably a good way to think of it is that when the substring gets flipped around to make it a palindrome, that operation works on *groups* of letters in the numeral, not on *individual* letters. The reason for that is I didn't want to have a 1=1, 2=3, 3=5 situation.
Matt - 2011-05-19 19:39


(optional field)
(optional field)
Answer "bonobo" here to fight spam. ここに「bonobo」を答えてください。SPAMを退治しましょう!
I reserve the right to delete or edit comments in any way and for any reason.