org.das2.math.matrix
Class ArrayMatrix

java.lang.Object
  extended by org.das2.math.matrix.Matrix
      extended by org.das2.math.matrix.ArrayMatrix

public class ArrayMatrix
extends Matrix


Field Summary
 
Fields inherited from class org.das2.math.matrix.Matrix
nCol, nRow
 
Constructor Summary
ArrayMatrix(double[] array, int rows, int columns)
           
ArrayMatrix(int rows, int columns)
           
ArrayMatrix(Matrix m)
           
 
Method Summary
 void copy(Matrix m)
           
 double get(int row, int col)
           
 void rowTimes(int row, double s)
           
 void rowTimesAddTo(int srcRow, double s, int dstRow)
           
 void set(int row, int col, double d)
           
 void swapRows(int row1, int row2)
           
 
Methods inherited from class org.das2.math.matrix.Matrix
columnCount, rowCount, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ArrayMatrix

public ArrayMatrix(int rows,
                   int columns)

ArrayMatrix

public ArrayMatrix(double[] array,
                   int rows,
                   int columns)

ArrayMatrix

public ArrayMatrix(Matrix m)
Method Detail

copy

public void copy(Matrix m)
Overrides:
copy in class Matrix

get

public double get(int row,
                  int col)
Specified by:
get in class Matrix

rowTimes

public void rowTimes(int row,
                     double s)
Specified by:
rowTimes in class Matrix

rowTimesAddTo

public void rowTimesAddTo(int srcRow,
                          double s,
                          int dstRow)
Specified by:
rowTimesAddTo in class Matrix

set

public void set(int row,
                int col,
                double d)
Specified by:
set in class Matrix

swapRows

public void swapRows(int row1,
                     int row2)
Specified by:
swapRows in class Matrix