galois.GLFSR(feedback_poly: Poly, state: ArrayLike | None = None)

Constructs a Galois LFSR from its feedback polynomial f(x).

Parameters:
feedback_poly: Poly

The feedback polynomial f(x)=c0xnc1xn1cn2x2cn1x+1.

state: ArrayLike | None = None

The initial state vector S=[S0,S1,,Sn2,Sn1]. The default is None which corresponds to all ones.

Notes

A Galois LFSR may be constructed from its characteristic polynomial c(x) by passing in its reciprocal as the feedback polynomial. This is because f(x)=xnc(x1).