\Zxing\Common\ReedsolomonGenericGF

<p>This class contains utility methods for performing mathematical operations over the Galois Fields. Operations use a given primitive polynomial in calculations.</p>

Throughout this package, elements of the GF are represented as an {@code int} for convenience and speed (but at the cost of memory).

Summary

Methods
Properties
Constants
__construct()
Init()
addOrSubtract()
getZero()
getOne()
buildMonomial()
exp()
log()
inverse()
multiply()
getSize()
getGeneratorBase()
toString()
$AZTEC_DATA_12
$AZTEC_DATA_10
$AZTEC_DATA_6
$AZTEC_PARAM
$QR_CODE_FIELD_256
$DATA_MATRIX_FIELD_256
$AZTEC_DATA_8
$MAXICODE_FIELD_64
No constants found
No protected methods found
No protected properties found
N/A
No private methods found
$expTable
$logTable
$zero
$one
$size
$primitive
$generatorBase
N/A

Properties

$AZTEC_DATA_12

$AZTEC_DATA_12 : 

Type

$AZTEC_DATA_10

$AZTEC_DATA_10 : 

Type

$AZTEC_DATA_6

$AZTEC_DATA_6 : 

Type

$AZTEC_PARAM

$AZTEC_PARAM : 

Type

$QR_CODE_FIELD_256

$QR_CODE_FIELD_256 : 

Type

$DATA_MATRIX_FIELD_256

$DATA_MATRIX_FIELD_256 : 

Type

$AZTEC_DATA_8

$AZTEC_DATA_8 : 

Type

$MAXICODE_FIELD_64

$MAXICODE_FIELD_64 : 

Type

$expTable

$expTable : 

Type

$logTable

$logTable : 

Type

$zero

$zero : 

Type

$one

$one : 

Type

$size

$size : 

Type

$primitive

$primitive : 

Type

$generatorBase

$generatorBase : 

Type

Methods

__construct()

__construct(  $primitive,   $size,   $b) 

Create a representation of GF(size) using the given primitive polynomial.

Parameters

$primitive
$size
$b

Init()

Init() 

addOrSubtract()

addOrSubtract(  $a,   $b) : \Zxing\Common\Reedsolomon\sum/difference

Implements both addition and subtraction -- they are the same in GF(size).

Parameters

$a
$b

Returns

\Zxing\Common\Reedsolomon\sum/difference —

of a and b

getZero()

getZero() 

getOne()

getOne() 

buildMonomial()

buildMonomial(  $degree,   $coefficient) : \Zxing\Common\Reedsolomon\the

Parameters

$degree
$coefficient

Returns

\Zxing\Common\Reedsolomon\the —

monomial representing coefficient * x^degree

exp()

exp(  $a) : \Zxing\Common\Reedsolomon\2

Parameters

$a

Returns

\Zxing\Common\Reedsolomon\2 —

to the power of a in GF(size)

log()

log(  $a) : \Zxing\Common\Reedsolomon\base

Parameters

$a

Returns

\Zxing\Common\Reedsolomon\base —

2 log of a in GF(size)

inverse()

inverse(  $a) : \Zxing\Common\Reedsolomon\multiplicative

Parameters

$a

Returns

\Zxing\Common\Reedsolomon\multiplicative —

inverse of a

multiply()

multiply(  $a,   $b) : integer

Parameters

$a
$b

Returns

integer —

product of a and b in GF(size)

getSize()

getSize() 

getGeneratorBase()

getGeneratorBase() 

toString()

toString()