145 SUBROUTINE sggbak( JOB, SIDE, N, ILO, IHI, LSCALE, RSCALE, M, V,
154 INTEGER IHI, ILO, INFO, LDV, M, N
157 REAL LSCALE( * ), RSCALE( * ), V( LDV, * )
163 LOGICAL LEFTV, RIGHTV
180 rightv = lsame( side,
'R' )
181 leftv = lsame( side,
'L' )
184 IF( .NOT.lsame( job,
'N' ) .AND. .NOT.lsame( job,
'P' ) .AND.
185 $ .NOT.lsame( job,
'S' ) .AND. .NOT.lsame( job,
'B' ) )
THEN
187 ELSE IF( .NOT.rightv .AND. .NOT.leftv )
THEN
189 ELSE IF( n.LT.0 )
THEN
191 ELSE IF( ilo.LT.1 )
THEN
193 ELSE IF( n.EQ.0 .AND. ihi.EQ.0 .AND. ilo.NE.1 )
THEN
195 ELSE IF( n.GT.0 .AND. ( ihi.LT.ilo .OR. ihi.GT.max( 1, n ) ) )
198 ELSE IF( n.EQ.0 .AND. ilo.EQ.1 .AND. ihi.NE.0 )
THEN
200 ELSE IF( m.LT.0 )
THEN
202 ELSE IF( ldv.LT.max( 1, n ) )
THEN
206 CALL xerbla(
'SGGBAK', -info )
216 IF( lsame( job,
'N' ) )
224 IF( lsame( job,
'S' ) .OR. lsame( job,
'B' ) )
THEN
230 CALL sscal( m, rscale( i ), v( i, 1 ), ldv )
238 CALL sscal( m, lscale( i ), v( i, 1 ), ldv )
246 IF( lsame( job,
'P' ) .OR. lsame( job,
'B' ) )
THEN
254 DO 40 i = ilo - 1, 1, -1
255 k = int( rscale( i ) )
258 CALL sswap( m, v( i, 1 ), ldv, v( k, 1 ), ldv )
265 k = int( rscale( i ) )
268 CALL sswap( m, v( i, 1 ), ldv, v( k, 1 ), ldv )
278 DO 80 i = ilo - 1, 1, -1
279 k = int( lscale( i ) )
282 CALL sswap( m, v( i, 1 ), ldv, v( k, 1 ), ldv )
288 DO 100 i = ihi + 1, n
289 k = int( lscale( i ) )
292 CALL sswap( m, v( i, 1 ), ldv, v( k, 1 ), ldv )
subroutine xerbla(srname, info)
subroutine sggbak(job, side, n, ilo, ihi, lscale, rscale, m, v, ldv, info)
SGGBAK
subroutine sscal(n, sa, sx, incx)
SSCAL
subroutine sswap(n, sx, incx, sy, incy)
SSWAP