85 SUBROUTINE zlatsp( UPLO, N, X, ISEED )
105 parameter( eye = ( 0.0d0, 1.0d0 ) )
109 DOUBLE PRECISION alpha, alpha3, beta
110 COMPLEX*16 a, b, c, r
123 alpha = ( 1.d0+sqrt( 17.d0 ) ) / 8.d0
124 beta = alpha - 1.d0 / 1000.d0
125 alpha3 = alpha*alpha*alpha
129 DO 10 j = 1, n*( n+1 ) / 2
135 IF( uplo.EQ.
'U' )
THEN
141 a = alpha3*
zlarnd( 5, iseed )
142 b =
zlarnd( 5, iseed ) / alpha
148 x( jj ) =
zlarnd( 2, iseed )
153 x( jj ) =
zlarnd( 2, iseed )
155 x( jj ) =
zlarnd( 2, iseed )
156 IF( abs( x( jj+( j-3 ) ) ).GT.abs( x( jj ) ) )
THEN
157 x( jj+( j-4 ) ) = 2.0d0*x( jj+( j-3 ) )
159 x( jj+( j-4 ) ) = 2.0d0*x( jj )
168 a = alpha3*
zlarnd( 5, iseed )
169 b =
zlarnd( 5, iseed ) / alpha
175 x( jj ) =
zlarnd( 2, iseed )
183 x( jj ) =
zlarnd( 2, iseed )
184 x( jj-j ) =
zlarnd( 2, iseed )
185 IF( abs( x( jj ) ).GT.abs( x( jj-j ) ) )
THEN
186 x( jj-1 ) = 2.0d0*x( jj )
188 x( jj-1 ) = 2.0d0*x( jj-j )
190 jj = jj - j - ( j-1 )
192 ELSE IF( j.EQ.1 )
THEN
193 x( jj ) =
zlarnd( 2, iseed )
205 a = alpha3*
zlarnd( 5, iseed )
206 b =
zlarnd( 5, iseed ) / alpha
212 x( jj ) =
zlarnd( 2, iseed )
217 x( jj ) =
zlarnd( 2, iseed )
219 x( jj ) =
zlarnd( 2, iseed )
220 IF( abs( x( jj-( n-j-2 ) ) ).GT.abs( x( jj ) ) )
THEN
221 x( jj-( n-j-2 )+1 ) = 2.0d0*x( jj-( n-j-2 ) )
223 x( jj-( n-j-2 )+1 ) = 2.0d0*x( jj )
232 a = alpha3*
zlarnd( 5, iseed )
233 b =
zlarnd( 5, iseed ) / alpha
239 x( jj ) =
zlarnd( 2, iseed )
247 x( jj ) =
zlarnd( 2, iseed )
248 x( jj+( n-j+1 ) ) =
zlarnd( 2, iseed )
249 IF( abs( x( jj ) ).GT.abs( x( jj+( n-j+1 ) ) ) )
THEN
250 x( jj+1 ) = 2.0d0*x( jj )
252 x( jj+1 ) = 2.0d0*x( jj+( n-j+1 ) )
254 jj = jj + ( n-j+1 ) + ( n-j )
256 ELSE IF( j.EQ.n )
THEN
257 x( jj ) =
zlarnd( 2, iseed )