|
FRODO Version 2.19.1
An open-source framework for Distributed Constraint Optimization (DCOP)
|
A matrix over a finite field. More...

Public Member Functions | |
| Matrix (BigInteger[][] A, BigInteger mod) | |
| Constructor. | |
| Matrix (int m, int n, BigInteger mod) | |
| Constructor. | |
| Matrix (BigInteger[] v, BigInteger costModulo) | |
| Constructs a row vector. | |
| String | toString () |
| Matrix | inverse () |
| BigInteger[][] | getArray () |
| BigInteger[][] | getArrayCopy () |
| Matrix | solve (Matrix B) |
| Solves A*X = B, assuming this matrix is square and invertible. | |
| int | getRowDimension () |
| int | getColumnDimension () |
| Matrix | getMatrix (final int[] r, final int j0, final int j1) |
| Get a submatrix. | |
| Matrix | times (final Matrix B) |
| Multiplication. | |
| void | set (int i, int j, BigInteger s) |
| Sets a coefficient. | |
Static Public Member Functions | |
| static Matrix | identity (final int m, final int n, BigInteger mod) |
| Generates an identity matrix. | |
Protected Attributes | |
| BigInteger[][] | A |
| The coefficients. | |
| final int | m |
| The number of rows. | |
| final int | n |
| The number of columns. | |
| final BigInteger | mod |
| The prime modulus used for finite-field arithmetic. | |
A matrix over a finite field.
| frodo2.algorithms.mpc_discsp.Matrix.Matrix | ( | BigInteger | A[][], |
| BigInteger | mod ) |
Constructor.
| A | The coefficients |
| mod | The prime modulus |
Referenced by getMatrix(), identity(), inverse(), frodo2.algorithms.mpc_discsp.LUdecomposition.LUdecomposition(), frodo2.algorithms.mpc_discsp.LUdecomposition.solve(), solve(), and times().
| frodo2.algorithms.mpc_discsp.Matrix.Matrix | ( | int | m, |
| int | n, | ||
| BigInteger | mod ) |
| frodo2.algorithms.mpc_discsp.Matrix.Matrix | ( | BigInteger[] | v, |
| BigInteger | costModulo ) |
Constructs a row vector.
| v | the elements |
| costModulo | the prime modulo |
| BigInteger[][] frodo2.algorithms.mpc_discsp.Matrix.getArray | ( | ) |
References A.
Referenced by getMatrix(), frodo2.algorithms.mpc_discsp.MPC_DisCSP4< V extends Addable< V > >.notifyIn(), frodo2.algorithms.mpc_discsp.LUdecomposition.solve(), and times().
| BigInteger[][] frodo2.algorithms.mpc_discsp.Matrix.getArrayCopy | ( | ) |
Referenced by frodo2.algorithms.mpc_discsp.LUdecomposition.LUdecomposition().
| int frodo2.algorithms.mpc_discsp.Matrix.getColumnDimension | ( | ) |
References n.
Referenced by frodo2.algorithms.mpc_discsp.LUdecomposition.solve().
| Matrix frodo2.algorithms.mpc_discsp.Matrix.getMatrix | ( | final int[] | r, |
| final int | j0, | ||
| final int | j1 ) |
Get a submatrix.
| r | Array of row indices. |
| j0 | Initial column index |
| j1 | Final column index |
References A, getArray(), Matrix(), and mod.
Referenced by frodo2.algorithms.mpc_discsp.LUdecomposition.solve().

| int frodo2.algorithms.mpc_discsp.Matrix.getRowDimension | ( | ) |
References m.
Referenced by frodo2.algorithms.mpc_discsp.LUdecomposition.solve().
|
static |
Generates an identity matrix.
| m | The number of rows |
| n | The number of columns |
| mod | The prime modulus |
References A, m, Matrix(), mod, and n.
Referenced by frodo2.algorithms.mpc_discsp.MPC_DisCSP4< V extends Addable< V > >.init(), and inverse().

| Matrix frodo2.algorithms.mpc_discsp.Matrix.inverse | ( | ) |
References identity(), m, Matrix(), mod, and solve().
Referenced by frodo2.algorithms.mpc_discsp.MPC_DisCSP4< V extends Addable< V > >.init().

| void frodo2.algorithms.mpc_discsp.Matrix.set | ( | int | i, |
| int | j, | ||
| BigInteger | s ) |
Sets a coefficient.
| i | row number |
| j | column number |
| s | value |
References A.
Referenced by frodo2.algorithms.mpc_discsp.MPC_DisCSP4< V extends Addable< V > >.init().
Solves A*X = B, assuming this matrix is square and invertible.
| B | right-hand-side matrix |
Reimplemented in frodo2.algorithms.mpc_discsp.LUdecomposition.
References Matrix(), mod, and frodo2.algorithms.mpc_discsp.LUdecomposition.solve().
Referenced by inverse().

Multiplication.
| B | the other matrix |
References A, getArray(), m, Matrix(), mod, and n.
Referenced by frodo2.algorithms.mpc_discsp.MPC_DisCSP4< V extends Addable< V > >.init(), and frodo2.algorithms.mpc_discsp.MPC_DisCSP4< V extends Addable< V > >.notifyIn().

| String frodo2.algorithms.mpc_discsp.Matrix.toString | ( | ) |
|
protected |
The coefficients.
Referenced by getArray(), getArrayCopy(), getMatrix(), identity(), frodo2.algorithms.mpc_discsp.LUdecomposition.LUdecomposition(), Matrix(), Matrix(), set(), frodo2.algorithms.mpc_discsp.LUdecomposition.solve(), and times().
|
protected |
The number of rows.
Referenced by getArrayCopy(), getRowDimension(), identity(), inverse(), frodo2.algorithms.mpc_discsp.LUdecomposition.LUdecomposition(), Matrix(), Matrix(), frodo2.algorithms.mpc_discsp.LUdecomposition.solve(), and times().
|
protected |
The prime modulus used for finite-field arithmetic.
Referenced by getMatrix(), identity(), inverse(), frodo2.algorithms.mpc_discsp.LUdecomposition.LUdecomposition(), Matrix(), Matrix(), frodo2.algorithms.mpc_discsp.LUdecomposition.solve(), solve(), and times().
|
protected |
The number of columns.
Referenced by getArrayCopy(), getColumnDimension(), identity(), frodo2.algorithms.mpc_discsp.LUdecomposition.LUdecomposition(), Matrix(), Matrix(), frodo2.algorithms.mpc_discsp.LUdecomposition.solve(), and times().