1DSPR2(1) BLAS routine DSPR2(1)
2
3
4
6 DSPR2 - the symmetric rank 2 operation A := alpha*x*y' + alpha*y*x' +
7 A,
8
10 SUBROUTINE DSPR2(UPLO,N,ALPHA,X,INCX,Y,INCY,AP)
11
12 DOUBLE PRECISION ALPHA
13
14 INTEGER INCX,INCY,N
15
16 CHARACTER UPLO
17
18 DOUBLE PRECISION
19 AP(*),X(*),Y(*)
20
22 DSPR2 performs the symmetric rank 2 operation
23
24 where alpha is a scalar, x and y are n element vectors and A is an n by
25 n symmetric matrix, supplied in packed form.
26
27
29 UPLO - CHARACTER*1.
30 On entry, UPLO specifies whether the upper or lower triangular
31 part of the matrix A is supplied in the packed array AP as fol‐
32 lows:
33
34 UPLO = 'U' or 'u' The upper triangular part of A is supplied
35 in AP.
36
37 UPLO = 'L' or 'l' The lower triangular part of A is supplied
38 in AP.
39
40 Unchanged on exit.
41
42 N - INTEGER.
43 On entry, N specifies the order of the matrix A. N must be at
44 least zero. Unchanged on exit.
45
46 ALPHA - DOUBLE PRECISION.
47 On entry, ALPHA specifies the scalar alpha. Unchanged on exit.
48
49 X - DOUBLE PRECISION array of dimension at least
50 ( 1 + ( n - 1 )*abs( INCX ) ). Before entry, the incremented
51 array X must contain the n element vector x. Unchanged on exit.
52
53 INCX - INTEGER.
54 On entry, INCX specifies the increment for the elements of X.
55 INCX must not be zero. Unchanged on exit.
56
57 Y - DOUBLE PRECISION array of dimension at least
58 ( 1 + ( n - 1 )*abs( INCY ) ). Before entry, the incremented
59 array Y must contain the n element vector y. Unchanged on exit.
60
61 INCY - INTEGER.
62 On entry, INCY specifies the increment for the elements of Y.
63 INCY must not be zero. Unchanged on exit.
64
65 AP - DOUBLE PRECISION array of DIMENSION at least
66 ( ( n*( n + 1 ) )/2 ). Before entry with UPLO = 'U' or 'u',
67 the array AP must contain the upper triangular part of the sym‐
68 metric matrix packed sequentially, column by column, so that AP(
69 1 ) contains a( 1, 1 ), AP( 2 ) and AP( 3 ) contain a( 1, 2 )
70 and a( 2, 2 ) respectively, and so on. On exit, the array AP is
71 overwritten by the upper triangular part of the updated matrix.
72 Before entry with UPLO = 'L' or 'l', the array AP must contain
73 the lower triangular part of the symmetric matrix packed sequen‐
74 tially, column by column, so that AP( 1 ) contains a( 1, 1 ),
75 AP( 2 ) and AP( 3 ) contain a( 2, 1 ) and a( 3, 1 ) respec‐
76 tively, and so on. On exit, the array AP is overwritten by the
77 lower triangular part of the updated matrix.
78
79 Level 2 Blas routine.
80
81 -- Written on 22-October-1986. Jack Dongarra, Argonne National
82 Lab. Jeremy Du Croz, Nag Central Office. Sven Hammarling, Nag
83 Central Office. Richard Hanson, Sandia National Labs.
84
85
86
87BLAS routine November 2006 DSPR2(1)