0

From Somewhat Practical Fully Homomorphic Encryption section 2.1

"Let $q > 1$ be an integer, then by $\mathbb{Z}_q$ we denote the set of integers $(−q/2, q/2]$. Note that we really simply consider $\mathbb{Z}_q$ to be a set, and as such should not be confused with the ring $\frac{\mathbb{Z}}{q\mathbb{Z}}$. Similarly, we denote with $R_{q}$ the set of polynomials in $R$ with coefficients in $\mathbb{Z}_q$. For $a \in \mathbb{Z}$ we denote by $[a]_{q}$ the unique integer in $\mathbb{Z}_q$ with $[a]_{q} = a \bmod q$"

I'm wondering how the operation $a \bmod q$ has to be performed.

For example, given $q = 7$. The $\mathbb{Z}_q$ set would be $(-3, -2, -1, 0, 1, 2, 3)$. If I perform the operation $ 6 \bmod 7$ in a "traditional" way, it would result in 6, which is not in the set $\mathbb{Z}_q$

  • 1
    But $6 \equiv -1 ({\rm mod} 7)$. It's just a relabelling of the equivalence classes. – K. Jiang Sep 03 '23 at 08:37
  • Any sequence of $q$ consecutive integers is a complete residue system, i.e. every integer is congruent to exactly one integer in the systems, so they may be used as normal forms for modular arithmetic. To convert from the standard residue system to this balanced system: if $,a\bmod q > q/2,$ then subtract $q$ from it to balance it. In your example $, 6 \to 6-7 = -1\ \ $ – Bill Dubuque Sep 03 '23 at 15:51

0 Answers0