mfc.group
Class Moebius

java.lang.Object
  extended bymfc.matrix.AbstractComplex2By2
      extended bymfc.group.Moebius
All Implemented Interfaces:
java.lang.Cloneable, java.io.Serializable
Direct Known Subclasses:
MoebiusTransform

public class Moebius
extends AbstractComplex2By2
implements java.io.Serializable

This class represents linear fractional transformations or Möbius transformations.

a z + b
z |->  
c z + d

All methods of Complex2By2 try to avoid the creation of temporarily used objects in their internal computations, unless the opposite is stated in their describtions.

This class has final member objects, which are used as dummy variables. Thus, it is definitely not thread-safe.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class mfc.matrix.AbstractComplex2By2
aIm, aRe, bIm, bRe, cIm, cRe, dIm, dRe, EPS, EPSILON, EPSSQR
 
Constructor Summary
Moebius()
           
Moebius(AbstractComplex2By2 m)
           
Moebius(Complex A, Complex B, Complex m)
          creates loxodromic transformation s with the two different fix points A and B, such that: (s(z)-B)/(s(z)-A)=m(z-B)/(z-A)
Moebius(Complex a, Complex b, Complex c, Complex d)
           
Moebius(double ar, double ai, double br, double bi, double mr, double mi)
          creates loxodromic transformation s with the two different fix points A=(ar,ai) and B=(br,bi), such that: (s(z)-B)/(s(z)-A)=m(z-B)/(z-A)
Moebius(double ar, double ai, double br, double bi, double cr, double ci, double dr, double di)
           
 
Method Summary
 Moebius adjoined()
          Returns adjoined of this.
 Complex applyDifferentialTo(Complex z)
          evaluates differential of instance at z and returns the result
 void applyDifferentialTo(Complex z, Complex r)
          evaluates differential of instance at z and assigns r with the result
 Complex applyInverseDifferentialTo(Complex z)
          evaluates differential of inverse of instance at z and returns the result
 void applyInverseDifferentialTo(Complex z, Complex r)
          evaluates differential of inverse of instance at z and assigns r with the result
 Complex applyInverseTo(Complex z)
          applies inverse of instance to z and returns the result
 void applyInverseTo(Complex z, Complex r)
          applies inverse of instance to z and assigns r with the result
 Complex applyTo(Complex z)
          applies instance to z and returns the result
 void applyTo(Complex z, Complex r)
          applies instance to z and assigns r with the result
 void applyTo(ComplexProjective1 v)
          Apply this to a ComplexProjective1.
 void applyTo(ComplexProjective1 v, ComplexProjective1 w)
          Apply this to a ComplexProjective1.
 void assign(Complex a, Complex b, Complex m)
          set instance to the loxodromic transformation s with the two different fix points A and B, such that: (s(z)-B)/(s(z)-A)=m(z-B)/(z-A)
 void assign(Complex a, Complex b, Complex c, Complex d)
          Assign this with prescribed entries.
 void assign(Complex a, Complex b, Complex c, Complex A, Complex B, Complex C)
          Set this to moebius transform which maps a onto A, b onto B, and c onto C.
 void assign(ComplexProjective1 a, ComplexProjective1 b, ComplexProjective1 c)
          assigns this with the Moebius transform wich maps (0,1) to a, (1,1) to b and (1,0) (=infinity) to c uses tons of new Complex numbers - optimize!!
 void assign(ComplexProjective1 fixPoint1, ComplexProjective1 fixPoint2, double lambdaRe, double lambdaIm)
          Assign this by prescribing its fixed points and the eigenvalues lambda, 1/lambda of the corresponding 2×2-matrix.
 void assign(double ar, double ai, double br, double bi, double mr, double mi)
          set instance to the loxodromic transformation s with the two different fix points A=(ar,ai) and B=(br,bi), such that: (s(z)-B)/(s(z)-A)=m(z-B)/(z-A)
 void assign(double ar, double ai, double br, double bi, double cr, double ci, double dr, double di)
          Assign this with prescribed entries.
 void assign(Moebius m)
          Assign this with the given transformation.
 void assignAdjoined()
          Assign this with its own adjoined.
 void assignDivide(Complex c)
          Assign this with the product of itself and the inverse of c.
 void assignDivide(Moebius m)
          Assign this with the product of itself and the inverse of m.
 void assignDivide(Moebius a, Moebius b)
          Assign this with the product of a and the inverse of b.
 void assignEuclideanLogScaleRotation(ComplexProjective1 center, double logScale, double angle)
          Assign this with a Euclidean scale-rotation.
 void assignIdentity()
          Assign this with the identity transformation
 void assignInvert()
          Assign this with its own inverse.
 void assignInvert(Moebius m)
          Assign this with the inverse of m.
 void assignSphericalLogScaleRotation(ComplexProjective1 center, double logScale, double angle)
          Assign this with a sperical scale-rotation.
 void assignTimes(Moebius a)
          Assign this with the product of itself and a.
 void assignTimes(Moebius a, Moebius b)
          Assign this with the product of a and b.
 Moebius divide(AbstractComplex2By2 a)
          Returns ratio of this and a.
 Complex[] getFixPoints()
          returns array of fixpoints of instance, if its number is either 1 or 2.
 int getFixPoints(Complex[] fp)
          assigns array fp with fix points of instance and returns the number of fixpoints, which can be either 1, 2, or infinity.
 double getRadiusOfMappedCircle(Complex centerOfCircle, double radiusOfCircle, Complex centerOfMappedCircle)
          computes the image of a circle given by center and radius.
 Moebius invert()
          Returns inverse of this.
 boolean isElliptic()
           
 boolean isHyperbolic()
           
 boolean isLoxodromic()
          we call a moebius loxodromic if its norm is not 1, this is not standart.
 boolean isParabolic()
           
 Moebius times(AbstractComplex2By2 a)
          Returns product of this with a.
static void times(Moebius a, Moebius b, Moebius c)
          Multiplies a and b and store the result in c.
 
Methods inherited from class mfc.matrix.AbstractComplex2By2
abs, absSqr, assign, assignAdjoined, assignAdjoinedWith, assignAdjugate, assignAdjugate, assignByColumn, assignByEigenvectors, assignByEigenvectors, assignConjugate, assignConjugate, assignConjugateWith, assignDivide, assignDivide, assignDivide, assignDivide, assignDivide, assignDivide, assignDivide, assignInvert, assignMinus, assignMinus, assignMinus, assignMinus, assignMinus, assignMinus, assignMinus, assignMinus, assignNeg, assignNeg, assignNormalizeDeterminant, assignNormalizeDeterminant, assignPlus, assignPlus, assignPlus, assignPlus, assignPlus, assignPlus, assignPlus, assignPlus, assignStar, assignStar, assignTimes, assignTimes, assignTimes, assignTimes, assignTimes, assignTimes, assignTimes, assignTimes, assignTranspose, assignTranspose, assignZero, determinant, determinant, dist, distSqr, divide, equals, getA, getA, getB, getB, getC, getC, getD, getD, getEigenValues, getEigenValues, getEigenValues, minus, norm, normSqr, plus, setA, setB, setC, setD, times, times, toString, trace, trace
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Moebius

public Moebius()

Moebius

public Moebius(double ar,
               double ai,
               double br,
               double bi,
               double cr,
               double ci,
               double dr,
               double di)

Moebius

public Moebius(Complex a,
               Complex b,
               Complex c,
               Complex d)

Moebius

public Moebius(AbstractComplex2By2 m)

Moebius

public Moebius(double ar,
               double ai,
               double br,
               double bi,
               double mr,
               double mi)
creates loxodromic transformation s with the two different fix points A=(ar,ai) and B=(br,bi), such that: (s(z)-B)/(s(z)-A)=m(z-B)/(z-A)

m=(mr,mi) is the square of one of the eigenvalues of the element of SL2C which represents s.


Moebius

public Moebius(Complex A,
               Complex B,
               Complex m)
creates loxodromic transformation s with the two different fix points A and B, such that: (s(z)-B)/(s(z)-A)=m(z-B)/(z-A)

m is the square of one of the eigenvalues of the element of SL2C which represents s.

Method Detail

assign

public void assign(double ar,
                   double ai,
                   double br,
                   double bi,
                   double cr,
                   double ci,
                   double dr,
                   double di)
Assign this with prescribed entries.

Overrides:
assign in class AbstractComplex2By2

assign

public void assign(Complex a,
                   Complex b,
                   Complex c,
                   Complex d)
Assign this with prescribed entries.

Overrides:
assign in class AbstractComplex2By2

assign

public void assign(Moebius m)
Assign this with the given transformation.


assign

public final void assign(double ar,
                         double ai,
                         double br,
                         double bi,
                         double mr,
                         double mi)
set instance to the loxodromic transformation s with the two different fix points A=(ar,ai) and B=(br,bi), such that: (s(z)-B)/(s(z)-A)=m(z-B)/(z-A)

m=(mr,mi) is the square of one of the eigenvalues of the element of SL2C which represents s.


assignIdentity

public void assignIdentity()
Assign this with the identity transformation

Overrides:
assignIdentity in class AbstractComplex2By2

assign

public final void assign(Complex a,
                         Complex b,
                         Complex m)
set instance to the loxodromic transformation s with the two different fix points A and B, such that: (s(z)-B)/(s(z)-A)=m(z-B)/(z-A)

m is the square of one of the eigenvalues of the element of SL2C which represents s.


assign

public void assign(ComplexProjective1 fixPoint1,
                   ComplexProjective1 fixPoint2,
                   double lambdaRe,
                   double lambdaIm)
            throws java.lang.IllegalArgumentException

Assign this by prescribing its fixed points and the eigenvalues lambda, 1/lambda of the corresponding 2×2-matrix.

If fixPoint1 and fixPoint2 correspond to the complex numbers z1 and z2, then this is set to the transformation T with

      T(z) - z2           2  z - z2
      ---------  =  lambda   ------  . 
      T(z) - z1              z - z1
 

Parameters:
fixPoint1 - a ComplexProjective1: the first fix point
fixPoint2 - a ComplexProjective1: the second fix point
lambdaRe - a double: real part of lambda
lambdaIm - a double: imaginary part of lambda
Throws:
java.lang.IllegalArgumentException - if lambdaRe == 0.0 && lambdaIm == 0.0 or if the fix points coincide.

assignEuclideanLogScaleRotation

public void assignEuclideanLogScaleRotation(ComplexProjective1 center,
                                            double logScale,
                                            double angle)

Assign this with a Euclidean scale-rotation.

One fix point is center, the other is at infinity.

Parameters:
center - a ComplexProjective1: center of the scale-rotation
logScale - a double: the logarithmic scale
angle - a double: the angle of rotation

assignSphericalLogScaleRotation

public void assignSphericalLogScaleRotation(ComplexProjective1 center,
                                            double logScale,
                                            double angle)

Assign this with a sperical scale-rotation.

One fix point is center, the other is the point diametrically opposite on the Riemann sphere.

Parameters:
center - a ComplexProjective1: center of the scale-rotation
logScale - a double: the logarithmic scale
angle - a double: the angle of rotation

assign

public final void assign(Complex a,
                         Complex b,
                         Complex c,
                         Complex A,
                         Complex B,
                         Complex C)
Set this to moebius transform which maps a onto A, b onto B, and c onto C. this methods creates manny temporarily used objects and therefore it needs to be optimized.


assign

public final void assign(ComplexProjective1 a,
                         ComplexProjective1 b,
                         ComplexProjective1 c)
assigns this with the Moebius transform wich maps (0,1) to a, (1,1) to b and (1,0) (=infinity) to c uses tons of new Complex numbers - optimize!!


assignInvert

public void assignInvert(Moebius m)
Assign this with the inverse of m.


assignInvert

public void assignInvert()
Assign this with its own inverse.

Overrides:
assignInvert in class AbstractComplex2By2

invert

public Moebius invert()
Returns inverse of this.


assignAdjoined

public void assignAdjoined()
Assign this with its own adjoined.

Overrides:
assignAdjoined in class AbstractComplex2By2

adjoined

public Moebius adjoined()
Returns adjoined of this.


assignTimes

public void assignTimes(Moebius a)
Assign this with the product of itself and a.


times

public static void times(Moebius a,
                         Moebius b,
                         Moebius c)
Multiplies a and b and store the result in c.


assignTimes

public void assignTimes(Moebius a,
                        Moebius b)
Assign this with the product of a and b.


times

public Moebius times(AbstractComplex2By2 a)
Returns product of this with a.


assignDivide

public void assignDivide(Moebius m)
Assign this with the product of itself and the inverse of m.


assignDivide

public void assignDivide(Complex c)
Assign this with the product of itself and the inverse of c.

Overrides:
assignDivide in class AbstractComplex2By2

assignDivide

public void assignDivide(Moebius a,
                         Moebius b)
Assign this with the product of a and the inverse of b.


divide

public Moebius divide(AbstractComplex2By2 a)
Returns ratio of this and a.


applyTo

public void applyTo(ComplexProjective1 v,
                    ComplexProjective1 w)
Apply this to a ComplexProjective1.

Parameters:
w - a ComplexProjective1: used to hand over the result

applyTo

public void applyTo(ComplexProjective1 v)
Apply this to a ComplexProjective1.


applyTo

public final void applyTo(Complex z,
                          Complex r)
applies instance to z and assigns r with the result


applyTo

public final Complex applyTo(Complex z)
applies instance to z and returns the result


applyInverseTo

public final void applyInverseTo(Complex z,
                                 Complex r)
applies inverse of instance to z and assigns r with the result


applyInverseTo

public final Complex applyInverseTo(Complex z)
applies inverse of instance to z and returns the result


applyDifferentialTo

public final void applyDifferentialTo(Complex z,
                                      Complex r)
evaluates differential of instance at z and assigns r with the result


applyDifferentialTo

public final Complex applyDifferentialTo(Complex z)
evaluates differential of instance at z and returns the result


applyInverseDifferentialTo

public final void applyInverseDifferentialTo(Complex z,
                                             Complex r)
evaluates differential of inverse of instance at z and assigns r with the result


applyInverseDifferentialTo

public final Complex applyInverseDifferentialTo(Complex z)
evaluates differential of inverse of instance at z and returns the result


isElliptic

public final boolean isElliptic()

isParabolic

public final boolean isParabolic()

isHyperbolic

public final boolean isHyperbolic()

isLoxodromic

public final boolean isLoxodromic()
we call a moebius loxodromic if its norm is not 1, this is not standart.


getFixPoints

public final int getFixPoints(Complex[] fp)
assigns array fp with fix points of instance and returns the number of fixpoints, which can be either 1, 2, or infinity. In the last case 0 is returned. if a needed entry of the array fp is null an instance of Complex is created.


getFixPoints

public final Complex[] getFixPoints()
returns array of fixpoints of instance, if its number is either 1 or 2. if instance is the identity the method returns null


getRadiusOfMappedCircle

public final double getRadiusOfMappedCircle(Complex centerOfCircle,
                                            double radiusOfCircle,
                                            Complex centerOfMappedCircle)
computes the image of a circle given by center and radius.

Parameters:
centerOfCircle - center of circle which is to map
radiusOfCircle - radius of circle which is to map
centerOfMappedCircle - center of mapped circle
Returns:
radius of mapped circle