Throughout this section, we have assumed that the residues are positive integers. For example, the possible residues modulo are assumed to be . This system is called the canonical (i.e., unsigned) residue representation. On the other hand, there is also a counterpart system that assumes signed (i.e., centered) residues 1, with the residues centered around , and the total number of residues is the same, namely . In both systems, a modulo operation changes a given value to another value within the system’s residue range such that: (1) if the given value is greater than the upper bound of the residue range, the value is subtracted by the modulus ; (2) if the value is less than the lower bound of the residue range, the value is increased by the modulus . The only difference between these two (canonical and centered) systems is their upper bounds and lower bounds: and in the canonical residue system, whereas and in the centered residue system. The canonical residue representation assumes that , whereas the centered residue system assumes that .
In both systems, the same properties hold for addition, subtraction, multiplication, and division (when the divisor is invertible). This can be proved using the reasoning from §A-1.2: any two congruent residues differ by an integer multiple of in either representation.
Also, the same property holds for an inverse: an inverse of modulo is such that .
Using a signed residue representation is useful in certain cases. In an example of canonical (i.e., unsigned) residue representation, suppose we have the relation and we know that in a given application, is guaranteed to be within the range (i.e., ). Then, = , and thus we can remove the modulo operation, simplifying the relation. Now, suppose a different example of centered (i.e., signed) residue representation where we have the relation , and we know that in a given application, is guaranteed to be within the range . Then, . However, notice that if the relation were in a canonical residue representation, then we cannot remove the modulo operation because if is negative, then this becomes smaller than the lower bound of the canonical residue system (i.e., ), and thus a modulo reduction (i.e., addition by one or more ) is needed.
In §D-5.8, we design the FastBConvEx operation based on this beneficial property of centered residue representation: in this algorithm design, we can simplify to because we know that .