Is this calculation correct ?

OK - I see how this could work with one voltage divider and one analog input.

Pelleplutt's images have clued me in (I think) on how this type of encoder works. I've never used encoders before, but if these encoders operate in a way that they could be considered a 2-bit binary switch then all thats needed is to calulate the voltage level (Vout) for each position of the binary switch. See the Resistive Divider formula 1/2 way down the page here. Vin = 5V, R1 = total resistance on Vin side of the switch, R2 = total resistance on GND side of the switch. Since the encoder switches are used one at a time, it is assumed that all encoders not in use are returned to the off or "0" position.

Looks like a good job for Qwseyvnd to calculate all the voltages. Then these numbers can be converted to its corresponing ADC code (0-5V gives 0-1023 digital code).

With 4 encoders, there are 16 possible values (64 counts/step).
With 20 encoders, there are 80 possible values (12.8 counts/step).