I'm trying to generate a coordinate pair lookup table to compress a 4D array structure into a 1D representation. Instead of rewriting my question all over again, I have already asked this on stack overflow. Here is the link to my post: http://stackoverflow.com/questions/36416290/implementing-a-lookup-table
Any help on this would be appreciative. Also if you refer to the last paragraph or statement from my question, about converting this 256 element array of a structure holding 2 enumerations or (unsigned) values into an array of 256 unsigned char where each char would represent the pair value. This would be even better! However implementing the algorithm to generate the pattern of this look up table is the higher priority.