Contents


NAME

     srotmg - Construct  a  Gentleman's  modified  Given's  plane
     rotation

SYNOPSIS

     SUBROUTINE SROTMG(D1, D2, B1, B2, PARAM)

     REAL D1, D2, B1, B2
     REAL PARAM(*)

     SUBROUTINE SROTMG_64(D1, D2, B1, B2, PARAM)

     REAL D1, D2, B1, B2
     REAL PARAM(*)

  F95 INTERFACE
     SUBROUTINE ROTMG(D1, D2, B1, B2, PARAM)

     REAL :: D1, D2, B1, B2
     REAL, DIMENSION(:) :: PARAM

     SUBROUTINE ROTMG_64(D1, D2, B1, B2, PARAM)

     REAL :: D1, D2, B1, B2
     REAL, DIMENSION(:) :: PARAM

  C INTERFACE
     #include <sunperf.h>

     void srotmg(float d1, float d2, float b1,  float  b2,  float
               *param);

     void srotmg_64(float d1, float d2, float b1, float b2, float
               *param);

PURPOSE

     srotmg Construct Gentleman's modified a Given's plane  rota-
     tion that will annihilate an element of a vector.

ARGUMENTS

     D1 (input/output)
               On entry,  the  first  diagonal  entry  in  the  H
               matrix.  On exit, changed to reflect the effect of
               the transformation.
     D2 (input/output)
               On entry, the  second  diagonal  entry  in  the  H
               matrix.  On exit, changed to reflect the effect of
               the transformation.

     B1 (input/output)
               On entry, the first element of the vector to which
               the  H  matrix  is  applied.   On exit, changed to
               reflect the effect of the transformation.

     B2 (input)
               On entry, the second  element  of  the  vector  to
               which the H matrix is applied.  Unchanged on exit.

     PARAM (output)
               On exit, PARAM(1) describes the form of the  rota-
               tion  matrix  H,  and  PARAM(2..5)  contain  the H
               matrix.

               If PARAM(1) = -2 then H = I  and  no  elements  of
               PARAM are modified.

               If PARAM(1) = -1 then PARAM(2) = h11,  PARAM(3)  =
               h21, PARAM(4) = h12, and PARAM(5) = h22.

               If PARAM(1) = 0 then h11 = h22  =  1,  PARAM(3)  =
               h21, and PARAM(4) = h12.

               If PARAM(1) = 1 then h12 = 1, h21 = -1, PARAM(2) =
               h11, and PARAM(5) = h22.