All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class Jampack.Rot

java.lang.Object
   |
   +----Jampack.Rot

public class Rot
extends Object
Rot generates and manipulates plane rotations. Given a 2-vector compontents are x and y, there is a unitary matrix P such that
      P|x| =  |   c      s||x| = |z|
       |y|    |-conj(s)  c||y|   |0|
The number c, which is always real, is the cosine of the rotation. The number s, which may be complex is the sine of the rotation.

Comments: This suite will eventually contain methods for real rotations (two are already in place). The only difference between real and complex rotations is that si and zi are zero for the former. The final routines will do the efficient thing.


Variable Index

 o c
The cosine of the rotation
 o si
The imaginary part of the sine of the rotation
 o sr
The real part of the sine of the rotation
 o zi
The imaginary part of the first component of the transformed vector
 o zr
The real part of the first component of the transformed vector

Constructor Index

 o Rot()

Method Index

 o ap(Zmat, Rot, int, int, int, int)
Multiplies columns (ii1:ii2,jj1) and A(ii2:ii2,jj1) of a Zmat (altered) by a plane rotation.
 o aph(Zmat, Rot, int, int, int, int)
Multiplies columns (ii1:ii2,jj1) and A(ii2:ii2,jj1) of a Zmat (altered) by the conjugate transpose of plane rotation.
 o genc(double, double)
Given a real 2-vector, genc returns a real plane rotation P such that
      P|x| =  | c  s||x| = |z|
       |y|    |-s  c||y|   |0|
 o genc(double, double, double, double)
Given the real and imaginary parts of a 2-vector, genc returns a plane rotation P such that
      P|x| =  |   c      s||x| = |z|
       |y|    |-conj(s)  c||y|   |0|
 o genc(Rot, double, double)
Given a real 2-vectc, genc generates a real plane rotation P such that
      P|x| =  | c  s||x| = |z|
       |y|    |-s  c||y|   |0|
 o genc(Rot, double, double, double, double)
Given the real and imaginary parts of a 2-vector, genc generates a plane rotation P such that
      P|x| =  |   c      s||x| = |z|
       |y|    |-conj(s)  c||y|   |0|
 o genc(Rot, Zmat, int, int, int)
Given a Zmat A, genc generates a plane rotation that on premultiplication into rows ii1 and ii2 annihilates A(ii2,jj).
 o genc(Zmat, int, int, int)
Given a Zmat A, genc returns a plane rotation that on premultiplication into rows ii1 and ii2 annihilates A(ii2,jj).
 o genr(double, double)
Given a real 2-vector, genr returns a plane rotation such that
      |x y|P = |x y|| c  s||x| = |z 0|
                    |-s  c||y|
 o genr(double, double, double, double)
Given the real and imaginary parts of a 2-vector, genr returns a plane rotation such that
      |x y|P = |x y||   c      s||x| = |z 0|
                    |-conj(s)  c||y|
 o genr(Rot, double, double)
Given a real 2-vector, genr generates a plane rotation such that
      |x y|P = |x y|| c  s||x| = |z 0|
                    |-s  c||y|
 o genr(Rot, double, double, double, double)
Given the real and imaginary parts of a 2-vector, genr generates a plane rotation such that
      |x y|P = |x y||   c      s||x| = |z 0|
                    |-conj(s)  c||y|
 o genr(Rot, Zmat, int, int, int)
Given a Zmat A, genr returns a plane rotation that on postmultiplication into column jj1 and jj2 annihilates A(ii,jj2).
 o genr(Zmat, int, int, int)
Given a Zmat A, genr returns a plane rotation that on postmultiplication into column jj1 and jj2 annihilates A(ii,jj2).
 o pa(Rot, Zmat, int, int, int, int)
Multiplies rows (ii1,jj1:jj2) and (ii2,jj1:jj2) of a Zmat (altered) by a plane rotation.
 o pha(Rot, Zmat, int, int, int, int)
Multiplies rows (ii1,jj1:jj2) and (ii2,jj1:jj2) of a Zmat (altered) by the conjugate transpose of a plane rotation.

Variables

 o c
 protected double c
The cosine of the rotation

 o sr
 public double sr
The real part of the sine of the rotation

 o si
 public double si
The imaginary part of the sine of the rotation

 o zr
 public double zr
The real part of the first component of the transformed vector

 o zi
 public double zi
The imaginary part of the first component of the transformed vector

Constructors

 o Rot
 public Rot()

Methods

 o genc
 public static Rot genc(double xr,
                        double xi,
                        double yr,
                        double yi)
Given the real and imaginary parts of a 2-vector, genc returns a plane rotation P such that
      P|x| =  |   c      s||x| = |z|
       |y|    |-conj(s)  c||y|   |0|

Parameters:
xr - The real part of the first component of the 2-vector
xi - The imaginary part of the first component of the 2-vector
yr - The real part of the second component of the 2-vector
yi - The imaginary part of the second component of the 2-vector
Returns:
The rotation
 o genc
 public static void genc(Rot P,
                         double xr,
                         double xi,
                         double yr,
                         double yi)
Given the real and imaginary parts of a 2-vector, genc generates a plane rotation P such that
      P|x| =  |   c      s||x| = |z|
       |y|    |-conj(s)  c||y|   |0|

Parameters:
P - The rotation (must be initialized)
xr - The real part of the first component of the 2-vector
xi - The imaginary part of the first component of the 2-vector
yr - The real part of the second component of the 2-vector
yi - The imaginary part of the second component of the 2-vector
 o genc
 public static Rot genc(double x,
                        double y)
Given a real 2-vector, genc returns a real plane rotation P such that
      P|x| =  | c  s||x| = |z|
       |y|    |-s  c||y|   |0|

Parameters:
x - The first component of the two vector
y - The second component of the two vector
Returns:
The rotation
 o genc
 public static void genc(Rot P,
                         double x,
                         double y)
Given a real 2-vectc, genc generates a real plane rotation P such that
      P|x| =  | c  s||x| = |z|
       |y|    |-s  c||y|   |0|

Parameters:
P - The plane rotation
x - The first component of the two vector
y - The second component of the two vector
 o genc
 public static Rot genc(Zmat A,
                        int ii1,
                        int ii2,
                        int jj)
Given a Zmat A, genc returns a plane rotation that on premultiplication into rows ii1 and ii2 annihilates A(ii2,jj). The element A(ii2,jj) is overwriten by zero and the element A(ii1,jj) is overwritten by its transformed value.

Parameters:
A - The Zmat (altered)
ii1 - The row index of the first element
ii2 - The row index of the second element (the one that is annihilated
jj - The column index of the elements
Returns:
The plane rotation
 o genc
 public static void genc(Rot P,
                         Zmat A,
                         int ii1,
                         int ii2,
                         int jj)
Given a Zmat A, genc generates a plane rotation that on premultiplication into rows ii1 and ii2 annihilates A(ii2,jj). The element A(ii2,jj) is overwriten by zero and the element A(ii1,jj) is overwritten by its transformed value.

Parameters:
P - The plane rotation (must be initialized)
A - The Zmat (altered)
ii1 - The row index of the first element
ii2 - The row index of the second element (the one that is annihilated
jj - The column index of the elements
 o genr
 public static Rot genr(double xr,
                        double xi,
                        double yr,
                        double yi)
Given the real and imaginary parts of a 2-vector, genr returns a plane rotation such that
      |x y|P = |x y||   c      s||x| = |z 0|
                    |-conj(s)  c||y|

Parameters:
xr - The real part of the first component of the 2-vector
xi - The imaginary part of the first component of the 2-vector
yr - The real part of the second component of the 2-vector
yi - The imaginary part of the second component of the 2-vector
Returns:
The rotation
 o genr
 public static void genr(Rot P,
                         double xr,
                         double xi,
                         double yr,
                         double yi)
Given the real and imaginary parts of a 2-vector, genr generates a plane rotation such that
      |x y|P = |x y||   c      s||x| = |z 0|
                    |-conj(s)  c||y|

Parameters:
P - The plane rotation (must be initialized)
xr - The real part of the first component of the 2-vector
xi - The imaginary part of the first component of the 2-vector
yr - The real part of the second component of the 2-vector
yi - The imaginary part of the second component of the 2-vector
Returns:
The rotation
 o genr
 public static Rot genr(Zmat A,
                        int ii,
                        int jj1,
                        int jj2)
Given a Zmat A, genr returns a plane rotation that on postmultiplication into column jj1 and jj2 annihilates A(ii,jj2). The element A(ii,jj2) is overwirten by zero and the element A(ii,jj1) is overwritten by its transformed value.

Parameters:
A - The Zmat (altered)
ii - The index of the row containing the elements
jj1 - The column index of the first element
jj2 - The column index of the second element (the one that is annihilated)
Returns:
The rotation
 o genr
 public static void genr(Rot P,
                         Zmat A,
                         int ii,
                         int jj1,
                         int jj2)
Given a Zmat A, genr returns a plane rotation that on postmultiplication into column jj1 and jj2 annihilates A(ii,jj2). The element A(ii,jj2) is overwirten by zero and the element A(ii,jj1) is overwritten by its transformed value.

Parameters:
P - The rotation
A - The Zmat (altered)
ii - The index of the row containing the elements
jj1 - The column index of the first element
jj2 - The column index of the second element (the one that is annihilated)
 o genr
 public static Rot genr(double x,
                        double y)
Given a real 2-vector, genr returns a plane rotation such that
      |x y|P = |x y|| c  s||x| = |z 0|
                    |-s  c||y|

Parameters:
x - The first component of the 2-vector
y - The second component of the 2-vector
Returns:
The rotation
 o genr
 public static void genr(Rot P,
                         double x,
                         double y)
Given a real 2-vector, genr generates a plane rotation such that
      |x y|P = |x y|| c  s||x| = |z 0|
                    |-s  c||y|

Parameters:
P - The rotation
x - The first component of the 2-vector
y - The second component of the 2-vector
 o pa
 public static void pa(Rot P,
                       Zmat A,
                       int ii1,
                       int ii2,
                       int jj1,
                       int jj2)
Multiplies rows (ii1,jj1:jj2) and (ii2,jj1:jj2) of a Zmat (altered) by a plane rotation.

Parameters:
P - The plane rotation
A - The Zmat (altered)
ii1 - The row index of the first row.
ii2 - The row index of the second row.
jj1 - The first index of the range of the rows
jj2 - The second index of the range of the rows
 o pha
 public static void pha(Rot P,
                        Zmat A,
                        int ii1,
                        int ii2,
                        int jj1,
                        int jj2)
Multiplies rows (ii1,jj1:jj2) and (ii2,jj1:jj2) of a Zmat (altered) by the conjugate transpose of a plane rotation.

Parameters:
P - The plane rotation
A - The Zmat (altered)
ii1 - The row index of the first row.
ii2 - The row index of the second row.
jj1 - The first index of the range of the rows
jj2 - The second index of the range of the rows
 o ap
 public static void ap(Zmat A,
                       Rot P,
                       int ii1,
                       int ii2,
                       int jj1,
                       int jj2)
Multiplies columns (ii1:ii2,jj1) and A(ii2:ii2,jj1) of a Zmat (altered) by a plane rotation.

Parameters:
A - The Zmat (altered)
P - The rotation
ii1 - The first index of the column range
ii2 - The second index of the column range
jj1 - The index of the first column
jj2 - The index of the second column
 o aph
 public static void aph(Zmat A,
                        Rot P,
                        int ii1,
                        int ii2,
                        int jj1,
                        int jj2)
Multiplies columns (ii1:ii2,jj1) and A(ii2:ii2,jj1) of a Zmat (altered) by the conjugate transpose of plane rotation.

Parameters:
A - The Zmat (altered)
P - The rotation
ii1 - The first index of the column range
ii2 - The second index of the column range
jj1 - The index of the first column
jj2 - The index of the second column

All Packages  Class Hierarchy  This Package  Previous  Next  Index