Background: 3 of 9 Barcode Alphabet
What is the formula behind the alphabet and digits in a 3 of 9 bar code?
For example, ASCII has a relatively clear arrangement. Numbers start at 33, capitals at 65, lowercase at 97. From these starting points you can infer the ASCII code for any number or letter. The start point for each range is also a multiple of 32 + 1.
Bar codes seem random and lacking sequence. If we use the syntax from the second link, this is the first six characters in 3 of 9:
A 100-01 B 010-01 C 110-00 D 001-01 E 101-00 F 011-00
I see no pattern here; what is it? I'm as much interested in the designer's intended pattern behind these as I am in someone devising an algorithm of their own that can give you the above code for a given character based on its sequence.
I struggled with where to put this question; is it history, computer science, information science? I chose Programmers because a StackExchange search had the most barcode hits here, and because I wanted to specifically relate it to ASCII to explain what sort of formula/explanation I'm looking for.
For the curious, here's the full list of all basic characters in Code 39: http://jsfiddle.net/b9chris/LnX2e/2/
(the source lines are taken from my C# barcode lib)
You'll notice that the simplified syntax proposed can confuse the issue a bit, because it might imply that every character is a 5-bit number with a dash position. The final 4 characters have numerous dashes (wide gaps). Really, these codes are best thought of as 9-bit numbers that happen to have most odd bits set to 0 for the majority of symbols. Here they are as 9-bit numbers: http://jsfiddle.net/b9chris/LnX2e/1/