Logo Search packages:      
Sourcecode: jblas version File versions  Download package

DoubleMatrix org::jblas::la::DoubleMatrix::put ( int[]  rindices,
int[]  cindices,
DoubleMatrix  x 
) [inline]

Put a sub-matrix as specified by the indices.

Definition at line 756 of file DoubleMatrix.java.

References checkColumns(), checkRows(), get(), isScalar(), put(), and scalar().

                                                                            {
        if (x.isScalar()) {
            return put(rindices, cindices, x.scalar());
        }
        x.checkRows(rindices.length);
        x.checkColumns(cindices.length);

        for (int i = 0; i < rindices.length; i++) {
            for (int j = 0; j < cindices.length; j++) {
                put(rindices[i], cindices[j], x.get(i, j));
            }
        }

        return this;
    }


Generated by  Doxygen 1.6.0   Back to index