[ Bottom of Page | Previous Page | Next Page | Contents | Index | Library Home | Legal | Search ]

Technical Reference: Base Operating System and Extensions, Volume 2

SROTMG or DROTMG Subroutine

Purpose

Constructs a modified Givens transformation.

Library

BLAS Library (libblas.a)

FORTRAN Syntax


SUBROUTINE SROTMG(D1,D2,X1,X2,PARAM)
REAL D1, D2, X1, X2, PARAM(5)

SUBROUTINE DROTMG(D1,D2,X1,X2,PARAM)
DOUBLE PRECISION D1,D2,X1,X2,PARAM(5)

Description

The SROTMG or DROTMG subroutine constructs a modified Givens transformation. The input quantities D1, D2, X1, and X2 define a 2-vector in partitioned form:

---  ---     ---           ---    ---    ---
|  a1  |     |  sqrt(D1)  0   |   |   X1   |
|      |  =  |                |   |        |
|  a2  |     |   0   sqrt(D2) |   |   X2   |
---  ---     ---           ---    ---    ---

The subroutines determine the modified Givens rotation matrix H that transforms X2 and, thus, a2 to 0. A representation of this matrix is stored in the array PARAM as follows:

Case 1: PARAM(1) = 1.0
   PARAM(2) = H(1,1)
   PARAM(5) = H(2,2)

Case 2: PARAM(1) = 0.0
   PARAM(3) = H(2,1)
   PARAM(4) = H(1,2)

Case 3: PARAM(1) = -1.0
   H(1,1) = PARAM(2)
   H(2,1) = PARAM(3) 
   H(1,2) = PARAM(4) 
   H(2,2) = PARAM(5) 

Case 4: PARAM(1) = -2.0
   H = I (Identity matrix)

Note: Locations in PARAM not listed are left unchanged.

Parameters

D1 Nonnegative scalar; modified on exit to reflect the results of the transformation.
D2 Scalar; can be negative on entry; modified on exit to reflect the results of the transformation.
X1 Scalar; modified on exit to reflect the results of the transformation.
X2 Scalar; unchanged on exit.
PARAM Vector of dimension (5); values on entry are unused; modified on exit as described above.

Related Information

The SROTM and DROTM (SROTM or DROTM Subroutine) subroutines apply the Modified Givens Transformation.

[ Top of Page | Previous Page | Next Page | Contents | Index | Library Home | Legal | Search ]