 LAPACK  3.10.0 LAPACK: Linear Algebra PACKage

## ◆ slarfy()

 subroutine slarfy ( character UPLO, integer N, real, dimension( * ) V, integer INCV, real TAU, real, dimension( ldc, * ) C, integer LDC, real, dimension( * ) WORK )

SLARFY

Purpose:
``` SLARFY applies an elementary reflector, or Householder matrix, H,
to an n x n symmetric matrix C, from both the left and the right.

H is represented in the form

H = I - tau * v * v'

where  tau  is a scalar and  v  is a vector.

If  tau  is  zero, then  H  is taken to be the unit matrix.```
Parameters
 [in] UPLO ``` UPLO is CHARACTER*1 Specifies whether the upper or lower triangular part of the symmetric matrix C is stored. = 'U': Upper triangle = 'L': Lower triangle``` [in] N ``` N is INTEGER The number of rows and columns of the matrix C. N >= 0.``` [in] V ``` V is REAL array, dimension (1 + (N-1)*abs(INCV)) The vector v as described above.``` [in] INCV ``` INCV is INTEGER The increment between successive elements of v. INCV must not be zero.``` [in] TAU ``` TAU is REAL The value tau as described above.``` [in,out] C ``` C is REAL array, dimension (LDC, N) On entry, the matrix C. On exit, C is overwritten by H * C * H'.``` [in] LDC ``` LDC is INTEGER The leading dimension of the array C. LDC >= max( 1, N ).``` [out] WORK ` WORK is REAL array, dimension (N)`

Definition at line 107 of file slarfy.f.

108 *
109 * -- LAPACK test routine --
110 * -- LAPACK is a software package provided by Univ. of Tennessee, --
111 * -- Univ. of California Berkeley, Univ. of Colorado Denver and NAG Ltd..--
112 *
113 * .. Scalar Arguments ..
114  CHARACTER UPLO
115  INTEGER INCV, LDC, N
116  REAL TAU
117 * ..
118 * .. Array Arguments ..
119  REAL C( LDC, * ), V( * ), WORK( * )
120 * ..
121 *
122 * =====================================================================
123 *
124 * .. Parameters ..
125  REAL ONE, ZERO, HALF
126  parameter( one = 1.0e+0, zero = 0.0e+0, half = 0.5e+0 )
127 * ..
128 * .. Local Scalars ..
129  REAL ALPHA
130 * ..
131 * .. External Subroutines ..
132  EXTERNAL saxpy, ssymv, ssyr2
133 * ..
134 * .. External Functions ..
135  REAL SDOT
136  EXTERNAL sdot
137 * ..
138 * .. Executable Statements ..
139 *
140  IF( tau.EQ.zero )
141  \$ RETURN
142 *
143 * Form w:= C * v
144 *
145  CALL ssymv( uplo, n, one, c, ldc, v, incv, zero, work, 1 )
146 *
147  alpha = -half*tau*sdot( n, work, 1, v, incv )
148  CALL saxpy( n, alpha, v, incv, work, 1 )
149 *
150 * C := C - v * w' - w * v'
151 *
152  CALL ssyr2( uplo, n, -tau, v, incv, work, 1, c, ldc )
153 *
154  RETURN
155 *
156 * End of SLARFY
157 *
real function sdot(N, SX, INCX, SY, INCY)
SDOT
Definition: sdot.f:82
subroutine saxpy(N, SA, SX, INCX, SY, INCY)
SAXPY
Definition: saxpy.f:89
subroutine ssymv(UPLO, N, ALPHA, A, LDA, X, INCX, BETA, Y, INCY)
SSYMV
Definition: ssymv.f:152
subroutine ssyr2(UPLO, N, ALPHA, X, INCX, Y, INCY, A, LDA)
SSYR2
Definition: ssyr2.f:147
Here is the call graph for this function: