Then at 140 system 30 computes f(xi) and gj (xi) where f(x) equals (ao +a1 x1 + . . . ak-1 xk-1) mod p and gj.sup.(x) =(bjo +bj 1x+ . . . bj(m-1) xm-1) mod p; where p is the smallest prime number greater than the number of mail pieces and the largest of the ordered numbers a and b.