Example: Representing a Primitive Element

The code below defines a variable alph that represents a primitive element of the field GF(24).

m = 4; % Or choose any positive integer value of m.
alph = gf(2,m) % Primitive element in GF(2^m)

The output is

alph = GF(2^4) array. Primitive polynomial = D^4+D+1 (19 decimal)
 
Array elements = 
 
     2

The Galois array alph represents a primitive element because of the correspondence between


© 1994-2005 The MathWorks, Inc.