Pipelined scaling of signed residue numbers with the mixed-radix conversion in the programmable gate array