com.planeth.common.math
Class Matrix

java.lang.Object
  extended bycom.planeth.common.math.Matrix
All Implemented Interfaces:
java.lang.Cloneable

public class Matrix
extends java.lang.Object
implements java.lang.Cloneable

Matrix implementation.

Author:
Andreas Grässer, gal@planet-h.com.
created May 15, 2005

Constructor Summary
Matrix(double[][] coefs)
          Constructor for Matrix.
 
Method Summary
 void addWith(Matrix matrix)
          Adds this Matrix with the passed matrix
 java.lang.Object clone()
           
 double[][] getCoefs()
          Returns the coefs.
 void multipyWith(Matrix matrix)
          Multiplies this Matrix with the passed matrix
 java.lang.String toString()
          Returns the String interpretation of the matrix
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Matrix

public Matrix(double[][] coefs)
Constructor for Matrix.

Parameters:
coefs - the coefficients for the matrix
Method Detail

toString

public java.lang.String toString()
Returns the String interpretation of the matrix


multipyWith

public void multipyWith(Matrix matrix)
Multiplies this Matrix with the passed matrix

Parameters:
matrix - Matrix to multiply

addWith

public void addWith(Matrix matrix)
Adds this Matrix with the passed matrix

Parameters:
matrix - Matrix to add

clone

public java.lang.Object clone()
See Also:
Object.clone()

getCoefs

public double[][] getCoefs()
Returns the coefs.

Returns:
Returns the coefs.