Top
Back: 5.1.85 nres
Forward: 5.1.87 nvars
FastBack: 5. Functions and system variables
FastForward: 6. Tricks and pitfalls
Up: 5.1 Functions
Top: Singular 2-0-4 Manual
Contents: Table of Contents
Index: F. Index
About: About This Document

5.1.86 nrows

Syntax:

nrows ( matrix_expression )
nrows ( intmat_expression )
nrows ( intvec_expression )
nrows ( module_expression )
nrows ( vector_expression )

Type:

int

Purpose:

returns the number of rows of a matrix, an intmat or an intvec, resp. the minimal rank of a free module in which the given module or vector lives (the index of the last non-zero component).

Note:

Use ncols to get the number of columns of a given matrix or intmat.

Example:
 
  ring R;
  matrix M[2][3];
  nrows(M);
→ 2
  nrows(freemodule(4));
→ 4
  module m=[0,0,1];
  nrows(m);
→ 3
  nrows([0,x,0]);
→ 2

See gen; matrix; module; ncols; vector.


Top Back: 5.1.85 nres Forward: 5.1.87 nvars FastBack: 5. Functions and system variables FastForward: 6. Tricks and pitfalls Up: 5.1 Functions Top: Singular 2-0-4 Manual Contents: Table of Contents Index: F. Index About: About This Document
            User manual for Singular version 2-0-4, October 2002, generated by texi2html.