C# Класс R3.Math.Mobius

Показать файл Открыть проект Примеры использования класса

Private Properties

Свойство Тип Описание
DivideQuat Vector3D
MultQuat Vector3D

Открытые методы

Метод Описание
Apply ( System.Numerics.Complex z ) : System.Numerics.Complex

Applies a Mobius transformation to a complex number.

Apply ( Vector3D z ) : Vector3D

Applies a Mobius transformation to a vector.

Use the complex number version if you can.

ApplyInfiniteSafe ( Vector3D z ) : Vector3D
ApplyToInfinite ( ) : Vector3D

Applies a Mobius transformation to the point at infinity.

ApplyToQuaternion ( Vector3D q ) : Vector3D

Applies a Mobius transformation to a quaternion with a zero k component (handled as a vector). The complex Mobius coefficients are treated as quaternions with zero j,k values. This is also infinity safe.

CreateFromIsometry ( Geometry g, double angle, System.Numerics.Complex P ) : Mobius
Elliptic ( Geometry g, System.Numerics.Complex fixedPlus, double angle ) : void
Geodesic ( Geometry g, System.Numerics.Complex p1, System.Numerics.Complex p2 ) : void

Move from a point p1 -> p2 along a geodesic. Also somewhat from Don.

Hyperbolic ( Geometry g, System.Numerics.Complex fixedPlus, double scale ) : void
Hyperbolic2 ( Geometry g, System.Numerics.Complex fixedPlus, System.Numerics.Complex point, double offset ) : void

Allow a hyperbolic transformation using an absolute offset. offset is specified in the respective geometry.

Identity ( ) : Mobius
Inverse ( ) : Mobius

Returns a new Mobius transformation that is the inverse of us.

Isometry ( Geometry g, double angle, System.Numerics.Complex P ) : void

This will calculate the Mobius transform that represents an isometry in the given geometry. The isometry will rotate CCW by angle A about the origin, then translate the origin to P (and -P to the origin).

MapPoints ( System.Numerics.Complex z1, System.Numerics.Complex z2, System.Numerics.Complex z3 ) : void

This transform will map z1 to Zero, z2 to One, and z3 to Infinity. http://en.wikipedia.org/wiki/Mobius_transformation#Mapping_first_to_0.2C_1.2C_.E2.88.9E If one of the zi is ∞, then the proper formula is obtained by first dividing all entries by zi and then taking the limit zi → ∞

MapPoints ( System.Numerics.Complex z1, System.Numerics.Complex z2, System.Numerics.Complex z3, System.Numerics.Complex w1, System.Numerics.Complex w2, System.Numerics.Complex w3 ) : void

This transform will map the z points to the respective w points.

Mobius ( System.Numerics.Complex z1, System.Numerics.Complex z2, System.Numerics.Complex z3 ) : System.Diagnostics

This transform will map z1 to Zero, z2, to One, and z3 to Infinity.

Mobius ( System.Numerics.Complex a, System.Numerics.Complex b, System.Numerics.Complex c, System.Numerics.Complex d ) : System.Diagnostics
Normalize ( ) : void

Normalize so that ad - bc = 1

PureTranslation ( Geometry g, System.Numerics.Complex p1, System.Numerics.Complex p2 ) : void

The pure translation (i.e. moves the origin straight in some direction) that takes p1 to p2. I borrowed this from Don's hyperbolic applet.

Round ( int digits ) : void

This is only here for a numerical accuracy hack. Please don't make a habit of using!

Scale ( double scale ) : Mobius
ScaleComponents ( System.Numerics.Complex k ) : void
ToString ( ) : string
Unity ( ) : void

The identity Mobius transformation.

UpperHalfPlane ( ) : void

This will transform the unit disk to the upper half plane.

operator ( ) : Mobius

Приватные методы

Метод Описание
DivideQuat ( Vector3D a, Vector3D b ) : Vector3D
MultQuat ( Vector3D a, Vector3D b ) : Vector3D

Описание методов

Apply() публичный Метод

Applies a Mobius transformation to a complex number.
public Apply ( System.Numerics.Complex z ) : System.Numerics.Complex
z System.Numerics.Complex
Результат System.Numerics.Complex

Apply() публичный Метод

Applies a Mobius transformation to a vector.
Use the complex number version if you can.
public Apply ( Vector3D z ) : Vector3D
z Vector3D
Результат Vector3D

ApplyInfiniteSafe() публичный Метод

public ApplyInfiniteSafe ( Vector3D z ) : Vector3D
z Vector3D
Результат Vector3D

ApplyToInfinite() публичный Метод

Applies a Mobius transformation to the point at infinity.
public ApplyToInfinite ( ) : Vector3D
Результат Vector3D

ApplyToQuaternion() публичный Метод

Applies a Mobius transformation to a quaternion with a zero k component (handled as a vector). The complex Mobius coefficients are treated as quaternions with zero j,k values. This is also infinity safe.
public ApplyToQuaternion ( Vector3D q ) : Vector3D
q Vector3D
Результат Vector3D

CreateFromIsometry() публичный статический Метод

public static CreateFromIsometry ( Geometry g, double angle, System.Numerics.Complex P ) : Mobius
g Geometry
angle double
P System.Numerics.Complex
Результат Mobius

Elliptic() публичный Метод

public Elliptic ( Geometry g, System.Numerics.Complex fixedPlus, double angle ) : void
g Geometry
fixedPlus System.Numerics.Complex
angle double
Результат void

Geodesic() публичный Метод

Move from a point p1 -> p2 along a geodesic. Also somewhat from Don.
public Geodesic ( Geometry g, System.Numerics.Complex p1, System.Numerics.Complex p2 ) : void
g Geometry
p1 System.Numerics.Complex
p2 System.Numerics.Complex
Результат void

Hyperbolic() публичный Метод

public Hyperbolic ( Geometry g, System.Numerics.Complex fixedPlus, double scale ) : void
g Geometry
fixedPlus System.Numerics.Complex
scale double
Результат void

Hyperbolic2() публичный Метод

Allow a hyperbolic transformation using an absolute offset. offset is specified in the respective geometry.
public Hyperbolic2 ( Geometry g, System.Numerics.Complex fixedPlus, System.Numerics.Complex point, double offset ) : void
g Geometry
fixedPlus System.Numerics.Complex
point System.Numerics.Complex
offset double
Результат void

Identity() публичный статический Метод

public static Identity ( ) : Mobius
Результат Mobius

Inverse() публичный Метод

Returns a new Mobius transformation that is the inverse of us.
public Inverse ( ) : Mobius
Результат Mobius

Isometry() публичный Метод

This will calculate the Mobius transform that represents an isometry in the given geometry. The isometry will rotate CCW by angle A about the origin, then translate the origin to P (and -P to the origin).
public Isometry ( Geometry g, double angle, System.Numerics.Complex P ) : void
g Geometry
angle double
P System.Numerics.Complex
Результат void

MapPoints() публичный Метод

This transform will map z1 to Zero, z2 to One, and z3 to Infinity. http://en.wikipedia.org/wiki/Mobius_transformation#Mapping_first_to_0.2C_1.2C_.E2.88.9E If one of the zi is ∞, then the proper formula is obtained by first dividing all entries by zi and then taking the limit zi → ∞
public MapPoints ( System.Numerics.Complex z1, System.Numerics.Complex z2, System.Numerics.Complex z3 ) : void
z1 System.Numerics.Complex
z2 System.Numerics.Complex
z3 System.Numerics.Complex
Результат void

MapPoints() публичный Метод

This transform will map the z points to the respective w points.
public MapPoints ( System.Numerics.Complex z1, System.Numerics.Complex z2, System.Numerics.Complex z3, System.Numerics.Complex w1, System.Numerics.Complex w2, System.Numerics.Complex w3 ) : void
z1 System.Numerics.Complex
z2 System.Numerics.Complex
z3 System.Numerics.Complex
w1 System.Numerics.Complex
w2 System.Numerics.Complex
w3 System.Numerics.Complex
Результат void

Mobius() публичный Метод

This transform will map z1 to Zero, z2, to One, and z3 to Infinity.
public Mobius ( System.Numerics.Complex z1, System.Numerics.Complex z2, System.Numerics.Complex z3 ) : System.Diagnostics
z1 System.Numerics.Complex
z2 System.Numerics.Complex
z3 System.Numerics.Complex
Результат System.Diagnostics

Mobius() публичный Метод

public Mobius ( System.Numerics.Complex a, System.Numerics.Complex b, System.Numerics.Complex c, System.Numerics.Complex d ) : System.Diagnostics
a System.Numerics.Complex
b System.Numerics.Complex
c System.Numerics.Complex
d System.Numerics.Complex
Результат System.Diagnostics

Normalize() публичный Метод

Normalize so that ad - bc = 1
public Normalize ( ) : void
Результат void

PureTranslation() публичный Метод

The pure translation (i.e. moves the origin straight in some direction) that takes p1 to p2. I borrowed this from Don's hyperbolic applet.
public PureTranslation ( Geometry g, System.Numerics.Complex p1, System.Numerics.Complex p2 ) : void
g Geometry
p1 System.Numerics.Complex
p2 System.Numerics.Complex
Результат void

Round() публичный Метод

This is only here for a numerical accuracy hack. Please don't make a habit of using!
public Round ( int digits ) : void
digits int
Результат void

Scale() публичный статический Метод

public static Scale ( double scale ) : Mobius
scale double
Результат Mobius

ScaleComponents() публичный Метод

public ScaleComponents ( System.Numerics.Complex k ) : void
k System.Numerics.Complex
Результат void

ToString() публичный Метод

public ToString ( ) : string
Результат string

Unity() публичный Метод

The identity Mobius transformation.
public Unity ( ) : void
Результат void

UpperHalfPlane() публичный Метод

This will transform the unit disk to the upper half plane.
public UpperHalfPlane ( ) : void
Результат void

operator() публичный статический Метод

public static operator ( ) : Mobius
Результат Mobius