Skip site navigation (1)Skip section navigation (2)

  
 
  

home | help
HPL_dger(3)		      HPL Library Functions		     HPL_dger(3)

NAME
     HPL_dger - A := alpha * x * y^T + A.

SYNOPSIS
     #include "hpl.h"

     void  HPL_dger( const enum HPL_ORDER ORDER, const int M, const int N, const
     double ALPHA, const double * X, const int INCX, double * Y, const int INCY,
     double * A, const int LDA );

DESCRIPTION
     HPL_dger performs the rank 1 operation

	 A := alpha * x * y^T + A,

     where alpha is a scalar,  x is an m-element vector, y is an n-element  vec-
     tor and A is an m by n matrix.

ARGUMENTS
     ORDER   (local input)	     const enum HPL_ORDER
	     On  entry,  ORDER	 specifies the storage format of the operands as
	     follows:
		ORDER = HplRowMajor,
		ORDER = HplColumnMajor.

     M	     (local input)	     const int
	     On entry,	M  specifies  the number of rows of  the  matrix  A.   M
	     must be at least zero.

     N	     (local input)	     const int
	     On  entry,  N   specifies the number of columns of the matrix A.  N
	     must be at least zero.

     ALPHA   (local input)	     const double
	     On entry, ALPHA specifies the scalar alpha.   When  ALPHA	is  sup-
	     plied as zero then  X and Y  need not be set on input.

     X	     (local input)	     const double *
	     On entry,	X  is an incremented array of dimension  at  least ( 1 +
	     ( m - 1 ) * abs( INCX ) )	that  contains the vector x.

     INCX    (local input)	     const int
	     On entry, INCX specifies the increment for the elements of X.  INCX
	     must not be zero.

     Y	     (local input)	     double *
	     On entry,	Y  is an incremented array of dimension  at  least ( 1 +
	     ( n - 1 ) * abs( INCY ) )	that  contains the vector y.

     INCY    (local input)	     const int
	     On entry, INCY specifies the increment for the elements of Y.  INCY
	     must not be zero.

     A	     (local input/output)    double *
	     On  entry,  A  points  to an array of size equal to or greater than
	     LDA * n.  Before  entry, the leading m by n part  of the  array   A
	     must  contain the matrix coefficients. On exit, A is overwritten by
	     the updated matrix.

     LDA     (local input)	     const int
	     On entry,	LDA  specifies	the  leading  dimension  of  A	 as  de-
	     clared   in   the	calling  (sub) program.  LDA  must  be	at least
	     MAX(1,m).

EXAMPLE
     #include "hpl.h"

     int main(int argc, char *argv[])
     {
	double a[2*2], x[2], y[2];
	a[0] = 1.0; a[1] = 2.0; a[2] = 3.0; a[3] = 3.0;
	x[0] = 2.0; x[1] = 1.0; y[2] = 1.0; y[3] = 2.0;
	HPL_dger( HplColumnMajor, 2, 2, 2.0, x, 1, y, 1,
		  a, 2 );
	printf("y=[%f,%f]\n", y[0], y[1]);
	exit(0); return(0);
     }

SEE ALSO
     HPL_dgemv (3), HPL_dtrsv (3).

HPL 2.3 			December 2, 2018		     HPL_dger(3)

Want to link to this manual page? Use this URL:
<https://man.freebsd.org/cgi/man.cgi?query=HPL_dger&sektion=3&manpath=FreeBSD+Ports+15.1.quarterly>

home | help