Go to the first, previous, next, last section, table of contents.

Initializing vector elements

Function: void gsl_vector_set_all (gsl_vector * v, double x)
This function sets all the elements of the vector v to the value x.

Function: void gsl_vector_set_zero (gsl_vector * v)
This function sets all the elements of the vector v to zero.

Function: int gsl_vector_set_basis (gsl_vector * v, size_t i)
This function makes a basis vector by setting all the elements of the vector v to zero except for the i-th element which is set to one.


Go to the first, previous, next, last section, table of contents.