property galois.ReedSolomon.is_narrow_sense : bool

Indicates if the Reed-Solomon code is narrow sense, meaning the roots of the generator polynomial are consecutive powers of \(\alpha\) starting at 1, i.e. \(\alpha, \alpha^2, \dots, \alpha^{2t - 1}\).

Examples

In [1]: rs = galois.ReedSolomon(15, 9); rs
Out[1]: <Reed-Solomon Code: [15, 9, 7] over GF(2^4)>

In [2]: rs.is_narrow_sense
Out[2]: True

In [3]: rs.roots
Out[3]: GF([ 2,  4,  8,  3,  6, 12], order=2^4)

In [4]: rs.field.primitive_element**(np.arange(1, 2*rs.t + 1))
Out[4]: GF([ 2,  4,  8,  3,  6, 12], order=2^4)

Last update: Nov 10, 2022