1HPL_dger(3)                  HPL Library Functions                 HPL_dger(3)
2
3
4

NAME

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

SYNOPSIS

9       #include "hpl.h"
10
11       void  HPL_dger(  const  enum HPL_ORDER ORDER, const int M, const int N,
12       const double ALPHA, const double * X, const int INCX, double * Y, const
13       int INCY, double * A, const int LDA );
14

DESCRIPTION

16       HPL_dger performs the rank 1 operation
17
18           A := alpha * x * y^T + A,
19
20       where  alpha  is a scalar,  x is an m-element vector, y is an n-element
21       vector and A is an m by n matrix.
22

ARGUMENTS

24       ORDER   (local input)           const enum HPL_ORDER
25               On entry, ORDER  specifies the storage format of  the  operands
26               as follows:
27                  ORDER = HplRowMajor,
28                  ORDER = HplColumnMajor.
29
30       M       (local input)           const int
31               On  entry,   M  specifies  the number of rows of  the matrix A.
32               M must be at least zero.
33
34       N       (local input)           const int
35               On entry, N  specifies the number of columns of the  matrix  A.
36               N must be at least zero.
37
38       ALPHA   (local input)           const double
39               On  entry,  ALPHA specifies the scalar alpha.   When  ALPHA  is
40               supplied as zero then  X and Y  need not be set on input.
41
42       X       (local input)           const double *
43               On entry,  X  is an incremented array of dimension  at  least (
44               1 + ( m - 1 ) * abs( INCX ) )  that  contains the vector x.
45
46       INCX    (local input)           const int
47               On  entry,  INCX specifies the increment for the elements of X.
48               INCX must not be zero.
49
50       Y       (local input)           double *
51               On entry,  Y  is an incremented array of dimension  at  least (
52               1 + ( n - 1 ) * abs( INCY ) )  that  contains the vector y.
53
54       INCY    (local input)           const int
55               On  entry,  INCY specifies the increment for the elements of Y.
56               INCY must not be zero.
57
58       A       (local input/output)    double *
59               On entry,  A  points  to an array of size equal to  or  greater
60               than  LDA  * n.  Before  entry, the leading m by n part  of the
61               array  A  must contain the matrix coefficients. On exit,  A  is
62               overwritten by the updated matrix.
63
64       LDA     (local input)           const int
65               On  entry,   LDA  specifies  the  leading  dimension  of  A  as
66               declared  in  the  calling  (sub) program.  LDA  must   be   at
67               least MAX(1,m).
68

EXAMPLE

70       #include "hpl.h"
71
72       int main(int argc, char *argv[])
73       {
74          double a[2*2], x[2], y[2];
75          a[0] = 1.0; a[1] = 2.0; a[2] = 3.0; a[3] = 3.0;
76          x[0] = 2.0; x[1] = 1.0; y[2] = 1.0; y[3] = 2.0;
77          HPL_dger( HplColumnMajor, 2, 2, 2.0, x, 1, y, 1,
78                    a, 2 );
79          printf("y=[%f,%f]\n", y[0], y[1]);
80          exit(0); return(0);
81       }
82

SEE ALSO

84       HPL_dgemv (3), HPL_dtrsv (3).
85
86
87
88HPL 2.2                        February 24, 2016                   HPL_dger(3)
Impressum