B-3.2 Encryption

1.
Suppose we have an (n −1)-degree polynomial M ∈R⟨n,t⟩ whose coefficients represent the plaintext numbers to encrypt.
2.
Randomly pick an (n −1)-degree polynomial A ∈R⟨n,q⟩ as a one-time random public mask (denoted as A ←$R⟨n,q⟩).
3.
Randomly pick a small polynomial E ∈R⟨n,q⟩ as a one-time noise, whose n coefficients are small numbers in ℤq randomly sampled from the Gaussian distribution χσ (denoted as E ←χσR⟨n,q⟩).
4.
Scale M by Δ, which is to compute Δ ⋅M. This converts M ∈R⟨n,t⟩ into Δ ⋅M ∈R⟨n,q⟩.
5.
Compute B = A ⋅S + Δ ⋅M + E mod R⟨n,q⟩ (i.e., reduce the degree by n and the coefficient by modulo q).
6.
The final ciphertext is (A,B).

The RLWE encryption formula is summarized as follows:

⟨Summary B-3.2⟩ RLWE Encryption

Initial Setup: Δ = ⌊q t⌋, S ←$R⟨n,𝑡𝑒𝑟𝑛⟩

Encryption Input: M ∈R⟨n,t⟩, A ←$R⟨n,q⟩, E ←χσR⟨n,q⟩

1.
Scale up M→ΔM  ∈R⟨n,q⟩
2.
Compute B = A ⋅S + ΔM + E  mod R⟨n,q⟩
3.
𝖱𝖫𝖶𝖤S,σ(ΔM + E) = (A,B)  ∈R⟨n,q⟩2