Applies the modified Givens transformation.
SUBROUTINE SROTM(N,X,INCX,Y,INCY,PARAM)
INTEGER N, INCX, INCY
REAL X(*), Y(*), PARAM(5)
SUBROUTINE DROTM(N,X,INCX,Y,INCY,PARAM) INTEGER N,INCX,INCY DOUBLE PRECISION X(*),Y(*),PARAM(5)
Let H denote the modified Givens transformation defined by the parameter array PARAM. The SROTM or DROTM subroutine computes:
--- --- --- --- | x | | x | | | := H * | | | y | | y | --- --- --- ---
where H is a 2 x 2 matrix with the components defined by the elements of the array PARAM as follows:
if PARAM(1) == 0.0 H(1,1) = H(2,2) = 1.0 H(2,1) = PARAM(3) H(1,2) = PARAM(4)
if PARAM(1) == 1.0 H(1,2) = H(2,1) = -1.0 H(1,1) = PARAM(2) H(2,2) = PARAM(5)
if PARAM(1) == -1.0 H(1,1) = PARAM(2) H(2,1) = PARAM(3) H(1,2) = PARAM(4) H(2,2) = PARAM(5)
if PARAM(1) == -2.0 H = I (Identity matrix)
If N <= 0 or H is an identity matrix, the subroutines return immediately.
The SROTMG or DROTMG (SROTMG or DROTMG Subroutine) subroutine builds the PARAM array prior to use by the SROTM or DROTM subroutine.