A-5.2 Coefficient Rotation

Coefficient rotation is a process of shifting the entire coefficients of a polynomial (either to the left or right) in a polynomial ring. In order to rotate the entire coefficients of a polynomial by h positions to the left, we multiply xh to the polynomial.

For example, suppose we have a polynomial as follows:

f(x) = c0 + c1x1 + c2x2 +    + chxh +    + cn1xn1 Rn,q

To shift the entire coefficients of f to the left by h positions (i.e., shift f’s h-th coefficient to the constant term), we compute f xh, which is:

Summary A-5.2 Polynomial Rotation

Give the (n 1)-degree polynomial:

f(x) = c0 + c1x1 + c2x2 +    + chxh +    + cn1xn1 Rn,q

The coefficients of f(x) can be rotated to the left by h positions by multiplying to f(x) by xh as follows:

f(x) xh = c0 xh + c1x1 xh + c2x2 xh +    + chxh xh +    + cn1xn1 xh ch + ch+1x + ch+2x2 +    + cn1xn1h c0xnh    ch1xn1 Rn,q

Note that multiplying the two polynomials f and xh will have a congruent polynomial in Rn,q. Therefore, the rotated polynomial, which is the result of f xh, will also have a congruent polynomial in Rn,q.

Note that the coefficient signs change when they rotate around the boundary of xn(= 1), as the computation is done in the polynomial ring Zq[x](xn + 1).

A-5.2.1 Example

Suppose we have a polynomial f 8(x4 + 1) as follows:

8 = {4,3,2,1,0,1,2,3}

f = 2 + 3x 4x2 x3

The polynomial ring 8(x4 + 1) has the following 4 congruence relationships:

x4 1

x4 x1 1 x1

x3 x1

x4 1

x4 x3 1 x3

x x3

x4 1

x4 x2 1 x2

x2 x2

Then, based on the coefficient rotation technique in Summary A-5.2.1, rotating 1 position to the left is equivalent to computing f x1 as follows:

f x1 = 2 (x1) + 3x (x1) 4x2 (x1) x3 (x1)

2x3 + 3 4x1 x2

= 3 4x1 x2 2x3

As another example, rotating 3 positions to the left is equivalent to computing f x3 as follows:

f x3 = 2 (x3) + 3x (x3) 4x2 (x3) x3 (x3)

2x 3x2 + 4x3 1

= 1 2x 3x2 + 4x3

= 1 2x 3x2 + (4 4 mod 8)x3

1 2x 3x2 4x3