M4RIE  0.20111004
 All Data Structures Files Functions Variables Typedefs Macros Groups Pages
Functions
Assignment and basic manipulation

Functions

static void mzd_poly_randomize (mzd_poly_t *A)
 Fill matrix A with random elements. More...
 
void mzd_slice_set_ui (mzd_slice_t *A, word value)
 Return diagonal matrix with value on the diagonal. More...
 
static word mzd_slice_read_elem (const mzd_slice_t *A, const rci_t row, const rci_t col)
 Get the element at position (row,col) from the matrix A. More...
 
static void mzd_slice_add_elem (mzd_slice_t *A, const rci_t row, const rci_t col, word elem)
 At the element elem to the element at position (row,col) in the matrix A. More...
 
static void mzd_slice_write_elem (mzd_slice_t *A, const rci_t row, const rci_t col, word elem)
 Write the element elem to the position (row,col) in the matrix A. More...
 
static void mzd_slice_randomize (mzd_slice_t *A)
 Fill matrix A with random elements. More...
 
void mzed_randomize (mzed_t *A)
 Fill matrix A with random elements. More...
 
mzed_tmzed_copy (mzed_t *B, const mzed_t *A)
 Copy matrix A to B. More...
 
void mzed_set_ui (mzed_t *A, word value)
 Return diagonal matrix with value on the diagonal. More...
 
static word mzed_read_elem (const mzed_t *A, const rci_t row, const rci_t col)
 Get the element at position (row,col) from the matrix A. More...
 
static void mzed_add_elem (mzed_t *A, const rci_t row, const rci_t col, const word elem)
 At the element elem to the element at position (row,col) in the matrix A. More...
 
static void mzed_write_elem (mzed_t *A, const rci_t row, const rci_t col, const word elem)
 Write the element elem to the position (row,col) in the matrix A. More...
 

Detailed Description

Function Documentation

static void mzd_poly_randomize ( mzd_poly_t A)
inlinestatic

Fill matrix A with random elements.

Parameters
AMatrix
Todo:
Allow the user to provide a RNG callback.
static void mzd_slice_add_elem ( mzd_slice_t A,
const rci_t  row,
const rci_t  col,
word  elem 
)
inlinestatic

At the element elem to the element at position (row,col) in the matrix A.

Parameters
ATarget matrix.
rowStarting row.
colStarting column.
elemfinite field element.
Todo:
This function is considerably slower than it needs to be.
static void mzd_slice_randomize ( mzd_slice_t A)
inlinestatic

Fill matrix A with random elements.

Parameters
AMatrix
Todo:
Allow the user to provide a RNG callback.
static word mzd_slice_read_elem ( const mzd_slice_t A,
const rci_t  row,
const rci_t  col 
)
inlinestatic

Get the element at position (row,col) from the matrix A.

Parameters
ASource matrix.
rowStarting row.
colStarting column.
Todo:
This function is considerably slower than it needs to be.
void mzd_slice_set_ui ( mzd_slice_t A,
word  value 
)

Return diagonal matrix with value on the diagonal.

If the matrix is not square then the largest possible square submatrix is used.

Parameters
AMatrix.
valueFinite Field element.
static void mzd_slice_write_elem ( mzd_slice_t A,
const rci_t  row,
const rci_t  col,
word  elem 
)
inlinestatic

Write the element elem to the position (row,col) in the matrix A.

Parameters
ATarget matrix.
rowStarting row.
colStarting column.
elemfinite field element.
Todo:
This function is considerably slower than it needs to be.
static void mzed_add_elem ( mzed_t A,
const rci_t  row,
const rci_t  col,
const word  elem 
)
inlinestatic

At the element elem to the element at position (row,col) in the matrix A.

Parameters
ATarget matrix.
rowStarting row.
colStarting column.
elemfinite field element.
mzed_t* mzed_copy ( mzed_t B,
const mzed_t A 
)

Copy matrix A to B.

Parameters
BMay be NULL for automatic creation.
ASource matrix.
void mzed_randomize ( mzed_t A)

Fill matrix A with random elements.

Parameters
AMatrix
Todo:
Allow the user to provide a RNG callback.
static word mzed_read_elem ( const mzed_t A,
const rci_t  row,
const rci_t  col 
)
inlinestatic

Get the element at position (row,col) from the matrix A.

Parameters
ASource matrix.
rowStarting row.
colStarting column.
void mzed_set_ui ( mzed_t A,
word  value 
)

Return diagonal matrix with value on the diagonal.

If the matrix is not square then the largest possible square submatrix is used.

Parameters
AMatrix
valueFinite Field element
static void mzed_write_elem ( mzed_t A,
const rci_t  row,
const rci_t  col,
const word  elem 
)
inlinestatic

Write the element elem to the position (row,col) in the matrix A.

Parameters
ATarget matrix.
rowStarting row.
colStarting column.
elemfinite field element.