IBM Research

PUZZLE   IBM-132

5-ops implementation of erasure code

IBM Research · Ponder This · 2009-04

IBM Ponder This #132 · April 2009

Design a storage system that encodes 24 information bits on 8 disks of 4 bits each, such that:

  1. Combining the 8*4 bits into a 32 bits number (taking a nibble from each disk), a function f from 24 bits to 32 can be computed using only 5 operations, each of which is out of the set {+, -, *, /, %, &, |, ~} (addition; subtraction, multiplication; integer division, modulo; bitwise-and; bitwise-or; and bitwise-not) on variable length integers. In other words, if every operation takes a nanosecond, the function can be computed in 5 nanoseconds.
  2. One can recover the original 24 bits even after any 2 of the 8 disks crash (making them unreadable and hence loosing 2 nibbles).

Clue #1 (04/06): f(x) = ((((x * c1) & c2) * c3) & c4) % c5;

Update (04/07): When you read the data, you know which two disks have failed.

Clue #2 (updated 04/24): c1 = (2^792-1)/(2^33-1); c2 = (2^816-1)/(2^34-1); c4 = (2^1088-1)/(2^34-1)

Solution

Best opened after a real attempt

To be added.