Ring Homomorphism Integer to Vectors

67 Views Asked by At

I am currently working on homomorphic encryption with the Microsoft SEAL library and I am looking for a way to encode one fixed-point number as multiple integers (integer vector of length $k$), so that addition and multiplications are valid. First thing I do is to scale the fixed-point number to an integer and work on from there.

My Question: Given rings $(\mathbb{Z}/n\mathbb{Z}, +,\cdot)$ and $(\{\mathbb{Z}/n\mathbb{Z}\}^k,+,\cdot)$, I am looking for a ring homomorphism $ \phi: \{\mathbb{Z}/n\mathbb{Z}\} \rightarrow \{\mathbb{Z}/n\mathbb{Z}\}^k$ but I can't seem to find find a trivial one and I tried extensively. Is there one I am overlooking?

Tested Solution 1: One trick was to encode one scaled integer using the Chinese Remainder theorem, which yields $m$ isomorph rings, on which I can perform additions and multiplications and in the end decode the correct result with the extended euclidean algorithm (if I choose the moduli accordingly). I tried this out and this works already, but I am interested whether there are more solutions.

Possible Other Solutions: So I have thought about taking $s$ unscaled fixed-point numbers that I want to encode as a vector and perform a discrete fourier analysis (DFT) and sample the $r$ largest (complex) frequencies and cast them to an integer. Since DFT is linear, I should also be able to perform additions and multiplications and still obtain the correct result on decoding. However, I see some problems with noise introduction due to the truncation of the frequencies and the integer casting of the frequency amplitude.

I hope this question isn't too confusing since I am not very educated with algebra and this seems address a niche I guess only a very few of you are working on.

Thank you in advance!

1

There are 1 best solutions below

1
On

Any ring homomorphism (or even any additive group homomorphism) with domain $\mathbb{Z} / n \mathbb{Z}$ is completely determined by the image of the multiplicative unit.

Since ring homomorphisms map multiplicative units to multiplicative units, there is only one possible function to consider, and it turns out to be a ring homomorphism. This function is the "diagonal" map

$$ x \mapsto (\underbrace{x, x, \ldots, x}_{k \text{ copies}}) $$