C++
C#
VB
JScript
All

# row

Copyright (C) 2005 IENT-RWTH Aachen

template<class G> inline typename MatrixRow< Matrix<G> >::self row( Matrix<G> &X, typename Matrix<G>::int_type n)
template<class G> inline typename MatrixRow<const Matrix<G> >::self row(const Matrix<G> &X, typename Matrix<G>::int_type n)

Isolates a row

Parameters

X | The matrix
n | Position of the row

Returns

A vector representing the n-th row of X

Example

    DenseMatrix<int>::self X(2,2,"1 2 3 4");
    cout << row(X,0) << endl; // [1 2]

See Also

rows, col, cols