src/utils/matrix/MMatrix.java
public void put(int index, Matrix matrix) throws MatrixException {
        if (!matrices.containsKey(index) && depth > 0 && matrices.size() >= depth) throw new MatrixException("MMatrix is exceeding defined depth.");
        if (rows == -1 && columns == -1) {
            rows = matrix.getTotalRows();
            columns = matrix.getTotalColumns();
            referenceMatrix = matrix;
        }
        else if (rows != matrix.getTotalRows() || columns != matrix.getTotalColumns()) throw new MatrixException("Number of rows and columns are not matching for inserted matrices.");
        matrices.put(index, matrix);
    }
/**
     * Puts matrix into specific index.
     *
     * @param index index
     * @param matrix matrix
     * @throws MatrixException throws exception if matrix is exceeding its depth.
     */
Puts matrix into specific index.
@param index index
@param matrix matrix
@throws MatrixException throws exception if matrix is exceeding its depth.
Puts matrix into specific index . @param index index @param matrix matrix @throws MatrixException throws exception if matrix is exceeding its depth .
public void put(int index, Matrix matrix) throws MatrixException {
        if (!matrices.containsKey(index) && depth > 0 && matrices.size() >= depth) throw new MatrixException("MMatrix is exceeding defined depth.");
        if (rows == -1 && columns == -1) {
            rows = matrix.getTotalRows();
            columns = matrix.getTotalColumns();
            referenceMatrix = matrix;
        }
        else if (rows != matrix.getTotalRows() || columns != matrix.getTotalColumns()) throw new MatrixException("Number of rows and columns are not matching for inserted matrices.");
        matrices.put(index, matrix);
    }
public void put ( int index , Matrix matrix ) throws MatrixException { if ( ! matrices . containsKey ( index ) && depth > 0 && matrices . size ( ) >= depth ) throw new MatrixException ( "MMatrix is exceeding defined depth." ) ; if ( rows == - 1 && columns == - 1 ) { rows = matrix . getTotalRows ( ) ; columns = matrix . getTotalColumns ( ) ; referenceMatrix = matrix ; } else if ( rows != matrix . getTotalRows ( ) || columns != matrix . getTotalColumns ( ) ) throw new MatrixException ( "Number of rows and columns are not matching for inserted matrices." ) ; matrices . put ( index , matrix ) ; }
Puts matrix into specific index.
Puts matrix into specific index .