[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

psychoceramics: 6bar6code6



Learn something new every day!

Michael Moroney explained:
: The UPC on consumer products has a bar code such that each digit 0-9 is
: represented by 4 bars, two light and two dark bars alternating.  Each digit
: is 7 times the width of the narrowest bar's width and each bar can be 1, 2,
: 3 or 4 times this width. Additionally there are two possible code for each
: digit, with each code the "negative" of each other (light and dark reversed).

Oh, that's cute.  In other words, within the 7 units are six points 
for a possible edge, exactly three of which must be edges.  (Every 
fourth edge in a block is mere formatting.)  That means there are 
twenty possible codes (6!/3!3!):
		---|||		|||---
		--|-||		||-|--
		--||-|		|-||--
		--|||-		-|||--
		-|--||		||--|-
		-|-|-|		|-|-|-
		-|-||-		-||-|-
		-||--|		|--||-
		|---||		||---|
		|--|-|		|-|--|
where `|' is an edge and `-' is a non-edge.  So if a code appears invalid, 
it is backward; and that tells the reader which digit goes first, without 
needing an asymmetrical frame.  How elegant!

(I tried to reverse-engineer the actual code assignments, but my eye
keeps going out of phase.  Could some weisenheimer have deliberately
assigned `6' to the code that most resembles the frame-bars?)

Anton Sherwood   *\\*   +1 415 267 0685   *\\*   DAS--@n--.com