Class MrpRes

  • All Implemented Interfaces:
    java.io.Serializable

    public abstract class MrpRes
    extends java.lang.Object
    implements java.io.Serializable
    The values returned by the evaluator and the base type for internal types.
    See Also:
    Serialized Form
    • Constructor Detail

      • MrpRes

        public MrpRes()
    • Method Detail

      • getDimensions

        public abstract Dimensions getDimensions()
        The Dimension of the object. Use getDimensions().order() to tell if this object represents a scaler (0), vector (1) or matrix (2).
        Returns:
        an object representing the dimensions
      • doubleValue

        public double doubleValue()
        If the result is a scaler return the value
        Returns:
        result of a scaler computation.
      • toArrayMat

        public abstract double[][] toArrayMat()
        If the result is a matrix return a two dimensional array of doubles. Returns null for vectors and scalers.
        Returns:
        a new matrix
      • toArrayVec

        public abstract double[] toArrayVec()
        If the result is a vector return a one dimensional array of doubles. Returns null for matrices and a single element vector for scalers.
        Returns:
        a new vector
      • toFlatternedArray

        public abstract double[] toFlatternedArray()
        Create a one dimensional array. Scaler values will give an an array with a single element, vector arguments give an array of the same length, matrix arguments return elements in row major order.
        Returns:
        a new one dimensional array
        Since:
        Jep 4.0/Extensions 2.1