Class MatrixFunctions

java.lang.Object
mgui.interfaces.Utility
mgui.geometry.util.MatrixFunctions

public class MatrixFunctions
extends Utility
Utility class providing functions on Jama matrices.
Since:
1.0
Version:
1.0
Author:
Andrew Reid
  • Constructor Summary

    Constructors
    Constructor Description
    MatrixFunctions()  
  • Method Summary

    Modifier and Type Method Description
    static java.util.ArrayList<java.lang.Double> getColumnMaxes​(Jama.Matrix M)
    Returns the maximums of the columns of M.
    static java.util.ArrayList<java.lang.Double> getColumnMeans​(Jama.Matrix M)
    Returns the means of the columns of M.
    static java.util.ArrayList<java.lang.Double> getColumnMins​(Jama.Matrix M)
    Returns the minimums of the columns of M.
    static java.util.ArrayList<java.lang.Double> getColumns​(Jama.Matrix M, int col)
    Returns col as an ArrayList.
    static java.util.ArrayList<java.lang.Double> getColumnSums​(Jama.Matrix M)
    Returns the sums of the columns of M.
    static double getMaxForColumn​(Jama.Matrix M, int col)
    Returns the maximum of col.
    static double getMaxForRow​(Jama.Matrix M, int row)
    Returns the maximum of row.
    static double getMeanForColumn​(Jama.Matrix M, int col)
    Returns the mean of col.
    static double getMeanForRow​(Jama.Matrix M, int row)
    Returns the mean of row.
    static double getMinForColumn​(Jama.Matrix M, int col)
    Returns the minimum of col.
    static double getMinForRow​(Jama.Matrix M, int row)
    Returns the minimum of row.
    static java.util.ArrayList<java.lang.Double> getRow​(Jama.Matrix M, int row)
    Returns row as an ArrayList.
    static java.util.ArrayList<java.lang.Double> getRowMaxes​(Jama.Matrix M)
    Returns the maximums of the rows of M.
    static java.util.ArrayList<java.lang.Double> getRowMeans​(Jama.Matrix M)
    Returns the means of the rows of M.
    static java.util.ArrayList<java.lang.Double> getRowMins​(Jama.Matrix M)
    Returns the minimums of the rows of M.
    static java.util.ArrayList<java.lang.Double> getRowSums​(Jama.Matrix M)
    Returns the sums of the rows of M.
    static double getSumForColumn​(Jama.Matrix M, int col)
    Returns the sum of col.
    static double getSumForRow​(Jama.Matrix M, int row)
    Returns the sum of row.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • MatrixFunctions

      public MatrixFunctions()
  • Method Details

    • getRow

      public static java.util.ArrayList<java.lang.Double> getRow​(Jama.Matrix M, int row)
      Returns row as an ArrayList.
      Parameters:
      M -
      row -
      Returns:
    • getColumns

      public static java.util.ArrayList<java.lang.Double> getColumns​(Jama.Matrix M, int col)
      Returns col as an ArrayList.
      Parameters:
      M -
      row -
      Returns:
    • getMaxForRow

      public static double getMaxForRow​(Jama.Matrix M, int row)
      Returns the maximum of row.
      Parameters:
      M - A 2D matrix
      row -
      Returns:
    • getRowMaxes

      public static java.util.ArrayList<java.lang.Double> getRowMaxes​(Jama.Matrix M)
      Returns the maximums of the rows of M.
      Parameters:
      M - A 2D matrix
      Returns:
    • getMaxForColumn

      public static double getMaxForColumn​(Jama.Matrix M, int col)
      Returns the maximum of col.
      Parameters:
      M - A 2D matrix
      row -
      Returns:
    • getColumnMaxes

      public static java.util.ArrayList<java.lang.Double> getColumnMaxes​(Jama.Matrix M)
      Returns the maximums of the columns of M.
      Parameters:
      M - A 2D matrix
      Returns:
    • getMinForRow

      public static double getMinForRow​(Jama.Matrix M, int row)
      Returns the minimum of row.
      Parameters:
      M - A 2D matrix
      row -
      Returns:
    • getRowMins

      public static java.util.ArrayList<java.lang.Double> getRowMins​(Jama.Matrix M)
      Returns the minimums of the rows of M.
      Parameters:
      M - A 2D matrix
      Returns:
    • getMinForColumn

      public static double getMinForColumn​(Jama.Matrix M, int col)
      Returns the minimum of col.
      Parameters:
      M - A 2D matrix
      row -
      Returns:
    • getColumnMins

      public static java.util.ArrayList<java.lang.Double> getColumnMins​(Jama.Matrix M)
      Returns the minimums of the columns of M.
      Parameters:
      M - A 2D matrix
      Returns:
    • getMeanForRow

      public static double getMeanForRow​(Jama.Matrix M, int row)
      Returns the mean of row.
      Parameters:
      M - A 2D matrix
      row -
      Returns:
    • getRowMeans

      public static java.util.ArrayList<java.lang.Double> getRowMeans​(Jama.Matrix M)
      Returns the means of the rows of M.
      Parameters:
      M - A 2D matrix
      Returns:
    • getMeanForColumn

      public static double getMeanForColumn​(Jama.Matrix M, int col)
      Returns the mean of col.
      Parameters:
      M - A 2D matrix
      row -
      Returns:
    • getColumnMeans

      public static java.util.ArrayList<java.lang.Double> getColumnMeans​(Jama.Matrix M)
      Returns the means of the columns of M.
      Parameters:
      M - A 2D matrix
      Returns:
    • getSumForRow

      public static double getSumForRow​(Jama.Matrix M, int row)
      Returns the sum of row.
      Parameters:
      M - A 2D matrix
      row -
      Returns:
    • getRowSums

      public static java.util.ArrayList<java.lang.Double> getRowSums​(Jama.Matrix M)
      Returns the sums of the rows of M.
      Parameters:
      M - A 2D matrix
      Returns:
    • getSumForColumn

      public static double getSumForColumn​(Jama.Matrix M, int col)
      Returns the sum of col.
      Parameters:
      M - A 2D matrix
      row -
      Returns:
    • getColumnSums

      public static java.util.ArrayList<java.lang.Double> getColumnSums​(Jama.Matrix M)
      Returns the sums of the columns of M.
      Parameters:
      M - A 2D matrix
      Returns: