Documentation of 'mikera.matrixx.impl.ARectangularMatrix' Java class
ARectangularMatrix
mikera.matrixx.impl

Class ARectangularMatrix

    • Method Detail

      • rowCount

        public final int rowCount()
        Description copied from interface: IMatrix
        Gets the number of rows in this matrix (dimension 0)
        Returns:
      • columnCount

        public final int columnCount()
        Description copied from interface: IMatrix
        Gets the number of columns in this matrix (dimension 1)
        Returns:
      • isSquare

        public final boolean isSquare()
        Description copied from interface: IMatrix
        Checks if this is a square matrix
        Specified by:
        isSquare in interface IMatrix
        Overrides:
        isSquare in class AMatrix
        Returns:
        true if square, false otherwise
      • getShape

        public final int[] getShape()
        Description copied from interface: INDArray
        Returns the shape of the array as an array of ints. WARNING: May return the internal int[] array describing the shape. Modifying this may cause undefined behaviour. If you want to guarantee a new int[] array that can be safely modified, use getShapeClone() instead
        Specified by:
        getShape in interface INDArray
        Overrides:
        getShape in class AMatrix
      • getShapeClone

        public final int[] getShapeClone()
        Description copied from interface: INDArray
        Returns the shape of the array as an array of ints, guaranteed to be a new array i.e. will perform a defensive copy of any internal shape array if required.
        Specified by:
        getShapeClone in interface INDArray
        Overrides:
        getShapeClone in class AMatrix
      • set

        public void set(int i,
                        int j,
                        double value)
        Description copied from interface: INDArray
        Sets a value at a given position in a mutable 2D array
        Specified by:
        set in interface INDArray
        Specified by:
        set in interface IMatrix
        Specified by:
        set in class AMatrix
      • bandLength

        public final int bandLength(int band)
        Description copied from class: AMatrix
        Returns the length of a band of the matrix. Returns 0 if the band is outside the matrix.
        Overrides:
        bandLength in class AMatrix
        Returns:
      • getShape

        public final int getShape(int dim)
        Description copied from interface: INDArray
        Returns the dimension size for a specific dimension in the array's shape
        Specified by:
        getShape in interface INDArray
        Overrides:
        getShape in class AMatrix
      • checkSquare

        public int checkSquare()
        Description copied from class: AMatrix
        Checks if a matrix is square. Returns the size if true, throws an exception otherwise;
        Overrides:
        checkSquare in class AMatrix
        Returns:
      • checkColumn

        public final int checkColumn(int column)
        Description copied from class: AMatrix
        Checks if the given column index is valid for this matrix. Throws an exception if not.
        Overrides:
        checkColumn in class AMatrix
        Returns:
        the number of columns in this matrix
      • checkRow

        public final int checkRow(int row)
        Description copied from class: AMatrix
        Checks if the given rows index is valid for this matrix. Throws an exception if not.
        Overrides:
        checkRow in class AMatrix
        Returns:
        the number of rows in this matrix
      • isSameShape

        public final boolean isSameShape(AMatrix m)
        Description copied from class: AMatrix
        Returns true iff this matrix is exactly the same shape as another matrix
        Overrides:
        isSameShape in class AMatrix
        Returns:
      • elementCount

        public final long elementCount()
        Description copied from interface: INDArray
        Returns the total number of elements in this array. Equivalent to the product of all dimension sizes.
        Specified by:
        elementCount in interface INDArray
        Overrides:
        elementCount in class AMatrix
      • getElement

        public final double getElement(long i)
        Description copied from interface: INDArray
        Gets a specific element of this array, indexed in row-major order
        Specified by:
        getElement in interface INDArray
        Overrides:
        getElement in class AMatrix
        Returns:
        The element value

DMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.