> Gotit! Try letter xor column :)

Wow, very good! I could not figure this out myself. Here is the very 
simple formula:

def encode(letter, column)
   (letter-?a + 1)^column
end

encode(?z, 1)
encode(?a, 2)
encode(?c, 3)
encode(?h, 4)

gives the correct result.

martinus