- publishing free software manuals
GNU Scientific Library Reference Manual - Third Edition (v1.12)
by M. Galassi, J. Davies, J. Theiler, B. Gough, G. Jungman, P. Alken, M. Booth, F. Rossi
Paperback (6"x9"), 592 pages, 60 figures
ISBN 0954612078
RRP £24.95 ($39.95)

Get a printed copy>>>

8.4.3 Initializing matrix elements

Function: void gsl_matrix_set_all (gsl_matrix * m, double x)
This function sets all the elements of the matrix m to the value x.
Function: void gsl_matrix_set_zero (gsl_matrix * m)
This function sets all the elements of the matrix m to zero.
Function: void gsl_matrix_set_identity (gsl_matrix * m)
This function sets the elements of the matrix m to the corresponding elements of the identity matrix, m(i,j) = \delta(i,j), i.e. a unit diagonal with all off-diagonal elements zero. This applies to both square and rectangular matrices.
ISBN 0954612078GNU Scientific Library Reference Manual - Third Edition (v1.12)See the print edition