All Packages Class Hierarchy This Package Previous Next Index
Interface CH.epfl.lcvm.mccc.Matrix
- public interface Matrix
A general Matrix interface.
-
add(Matrix)
- Add the given matrix to the current matrix
-
copy()
- So, it appears that clone doesn't really support polymorphic
copying correctly (in java 1.1) so until it does we will use this...
-
copyColumns(int, int)
- Slice the matrix columnise and return a copy of the specified columns
-
copyRows(int, int)
- Slice the matrix rowise and return a copy of the specified rows
-
determinant()
- Compute the determinant of the matrix
-
getColumns()
- Get the number of columns
-
getElement(int, int)
- Returns the element at the specified row and column
-
getRows()
- Get the number of rows
-
infinityNorm()
- Get the infinity norm of the matrix
-
multiply(double)
- Multiply the current matrix by the given scalar
-
multiply(Matrix)
- Post multiply the current matrix by the given matrix
-
nullSpaceBasis()
- Return a matrix whose columns are a basis of the null space
of the matrix.
-
oneNorm()
- Get the one norm of the matrix
-
setElement(int, int, double)
- Sets the element at the specified row and column
-
solve(Matrix)
- Solve the linear system AX=B and return X.
-
subtract(Matrix)
- Subtract the given matrix from the current matrix
-
toArray()
- Returns the native array representation of the matrix
-
transpose()
- Transpose the current matrix
getElement
public abstract double getElement(int row,
int column)
- Returns the element at the specified row and column
- Parameters:
- row - The row of the desired element
- column - The column of the desired element
- Returns:
- the element at the specified coordinates.
setElement
public abstract void setElement(int row,
int column,
double value)
- Sets the element at the specified row and column
- Parameters:
- row - The row of the desired element
- column - The column of the desired element
- value - The value to place into the array
add
public abstract void add(Matrix B)
- Add the given matrix to the current matrix
- Parameters:
- B - The matrix to be added
subtract
public abstract void subtract(Matrix B)
- Subtract the given matrix from the current matrix
- Parameters:
- B - The matrix to be added
multiply
public abstract void multiply(Matrix B)
- Post multiply the current matrix by the given matrix
- Parameters:
- B - The matrix to be multiplied by
multiply
public abstract void multiply(double x)
- Multiply the current matrix by the given scalar
- Parameters:
- x - The scalar to be multiplied by
transpose
public abstract void transpose()
- Transpose the current matrix
getRows
public abstract int getRows()
- Get the number of rows
- Returns:
- The number of rows
getColumns
public abstract int getColumns()
- Get the number of columns
- Returns:
- The number of columns
infinityNorm
public abstract double infinityNorm()
- Get the infinity norm of the matrix
- Returns:
- The infinity norm of the matrix
oneNorm
public abstract double oneNorm()
- Get the one norm of the matrix
- Returns:
- The one norm of the matrix
copy
public abstract Matrix copy()
- So, it appears that clone doesn't really support polymorphic
copying correctly (in java 1.1) so until it does we will use this...
- Returns:
- A copy of the matrix
copyRows
public abstract Matrix copyRows(int start,
int end)
- Slice the matrix rowise and return a copy of the specified rows
- Parameters:
- start - The starting row
- end - The ending row
- Returns:
- A copy of the matrix with just the given rows (inclusive)
copyColumns
public abstract Matrix copyColumns(int start,
int end)
- Slice the matrix columnise and return a copy of the specified columns
- Parameters:
- start - The starting column
- end - The ending column
- Returns:
- A copy of the matrix with just the given columns (inclusive)
solve
public abstract Matrix solve(Matrix B) throws SolverException
- Solve the linear system AX=B and return X. The method is up to the
derived class. The solution matrix X has as many columns as B.
- Returns:
- The solution X
- Throws: SolverException
- The exception thrown when the solver fails
nullSpaceBasis
public abstract Matrix nullSpaceBasis() throws MCCCException
- Return a matrix whose columns are a basis of the null space
of the matrix. Only guarenteed to work if the matrix is
Nx(N+M) and has rank N.
- Returns:
- The basis of the null space.
- Throws: MCCCException
- The exception thrown when the method fails
determinant
public abstract double determinant() throws SolverException
- Compute the determinant of the matrix
- Returns:
- The determinant of the matrix
- Throws: SolverException
- The exception thrown when the solver fails
toArray
public abstract double[][] toArray()
- Returns the native array representation of the matrix
- Returns:
- A double[][] representation of the matrix
All Packages Class Hierarchy This Package Previous Next Index