M4RI
20140914
|
Permutation matrices. More...
#include <m4ri/mzd.h>
Go to the source code of this file.
Data Structures | |
struct | mzp_t |
Permutations. More... | |
Typedefs | |
typedef struct mzp_t | mzp_t |
Permutations. | |
Functions | |
mzp_t * | mzp_init (rci_t length) |
void | mzp_free (mzp_t *P) |
mzp_t * | mzp_init_window (mzp_t *P, rci_t begin, rci_t end) |
Create a window/view into the permutation P. More... | |
void | mzp_free_window (mzp_t *condemned) |
Free a permutation window created with mzp_init_mzp_t_window(). More... | |
mzp_t * | mzp_copy (mzp_t *P, const mzp_t *Q) |
copy permutation Q to P More... | |
void | mzp_set_ui (mzp_t *P, unsigned int value) |
Set the permutation P to the identity permutation. The only allowed value is 1. More... | |
void | mzd_apply_p_left (mzd_t *A, mzp_t const *P) |
void | mzd_apply_p_left_trans (mzd_t *A, mzp_t const *P) |
void | mzd_apply_p_right (mzd_t *A, mzp_t const *P) |
void | mzd_apply_p_right_trans (mzd_t *A, mzp_t const *P) |
void | mzd_apply_p_right_even_capped (mzd_t *A, mzp_t const *P, rci_t start_row, rci_t start_col) |
void | mzd_apply_p_right_trans_even_capped (mzd_t *A, mzp_t const *P, rci_t start_row, rci_t start_col) |
void | mzd_apply_p_right_trans_tri (mzd_t *A, mzp_t const *Q) |
void | mzp_print (mzp_t const *P) |
void | _mzd_compress_l (mzd_t *A, rci_t r1, rci_t n1, rci_t r2) |
Permutation matrices.
Compresses the matrix L in a step in blockwise-recursive PLE decomposition.
A | Matrix. |
r1 | Rank of left matrix. |
n1 | Column cut which separates left and right matrix. |
r2 | Rank of right matrix. |
We are compressing this matrix
r1 n1 ------------------------------------------ | \ \____|___ | A01 | | \ | \ | | r1------------------------------------------ | | | | \ \_____ | | L1| | | \ \________| | | | | L2| | ------------------------------------------
to this matrix
r1 n1 ------------------------------------------ | \ \____|___ | A01 | | \ | \ | | r1------------------------------------------ | \ | | \_____ | | \ | | \________| | | | | | ------------------------------------------
Apply the permutation P to A from the left.
This is equivalent to row swaps walking from 0 to length-1.
A | Matrix. |
P | Permutation. |
Apply the permutation P to A from the left but transpose P before.
This is equivalent to row swaps walking from length-1 to 0.
A | Matrix. |
P | Permutation. |
Apply the permutation P to A from the right.
This is equivalent to column swaps walking from length-1 to 0.
A | Matrix. |
P | Permutation. |
Apply the permutation P to A from the right starting at start_row.
This is equivalent to column swaps walking from length-1 to 0.
A | Matrix. |
P | Permutation. |
start_row | Start swapping at this row. |
start_col | Start swapping at this column. |
Apply the permutation P to A from the right but transpose P before.
This is equivalent to column swaps walking from 0 to length-1.
A | Matrix. |
P | Permutation. |
Apply the mzp_t P to A from the right but transpose P before.
This is equivalent to column swaps walking from 0 to length-1.
A | Matrix. |
P | Permutation. |
void mzd_apply_p_right_trans_even_capped | ( | mzd_t * | A, |
mzp_t const * | P, | ||
rci_t | start_row, | ||
rci_t | start_col | ||
) |
Apply the permutation P^T to A from the right starting at start_row.
This is equivalent to column swaps walking from 0 to length-1.
A | Matrix. |
P | Permutation. |
start_row | Start swapping at this row. |
start_col | Start swapping at this column. |
Apply the permutation P to A from the right, but only on the upper the matrix A above the main diagonal.
This is equivalent to column swaps walking from length-1 to 0.
A | Matrix. |
Q | Permutation. |
copy permutation Q to P
P | Target permutation matrix (may be NULL) |
Q | Source permutation matrix (must not be NULL) |
void mzp_free | ( | mzp_t * | P | ) |
void mzp_free_window | ( | mzp_t * | condemned | ) |
Free a permutation window created with mzp_init_mzp_t_window().
condemned | Permutation Matrix |
Construct an identity permutation.
length | Length of the permutation. |
Create a window/view into the permutation P.
Use mzp_free_mzp_t_window() to free the window.
P | Permutation matrix |
begin | Starting index (inclusive) |
end | Ending index (exclusive) |
void mzp_set_ui | ( | mzp_t * | P, |
unsigned int | value | ||
) |
Set the permutation P to the identity permutation. The only allowed value is 1.
P | Permutation |
value | 1 |