pymor.models.transforms

Module Contents

class pymor.models.transforms.BilinearTransformation(x, name=None)[source]

Bases: MoebiusTransformation

The bilinear transform also known as Tustin’s method.

The bilinear transform can be seen as the first order approximation of the natural logarithm that maps the z-plane onto the s-plane. The approximation is given by

\[z = \frac{1+xs}{1-xs},\]

where x is an arbitrary number. Usually, this is chosen as the step size of the numerical integration trapezoid rule, i.e. the sampling time of a discrete-time LTIModel.

Parameters

x

An arbitrary number that defines the BilinearTransformation.

name

Name of the transform.

class pymor.models.transforms.CayleyTransformation(name=None)[source]

Bases: MoebiusTransformation

Maps the upper complex half-plane to the unit disk.

The Cayley transform is defined as

\[f(s) = \frac{s-i}{s+i}.\]

Parameters

name

Name of the transform.

class pymor.models.transforms.MoebiusTransformation(coefficients, normalize=False, name=None)[source]

Bases: pymor.core.base.ImmutableObject

Maps the Riemann sphere onto itself.

A Moebius transformation

\[M(s) = \frac{as+b}{cs+b}\]

is determined by the coefficients \(a,b,c,d\in\mathbb{C}\). The Moebius transformations form a group under composition, therefore the __matmul__ operator is defined to yield a MoebiusTransformation if both factors are MoebiusTransformations.

Parameters

coefficients

A tuple, list or NumPy array containing the four coefficients a,b,c,d.

normalize

If True, the coefficients are normalized, i.e., \(ad-bc=1\). Defaults to False.

name

Name of the transformation.

Methods

from_points

Constructs a Moebius transformation from three points and their images.

inverse

Returns the inverse Moebius transformation by applying the inversion formula.

classmethod from_points(w, z=(0, 1, np.inf), name=None)[source]

Constructs a Moebius transformation from three points and their images.

A Moebius transformation is completely determined by the images of three distinct points on the Riemann sphere under transformation.

Parameters

w

A tuple, list or NumPy array of three complex numbers that are transformed.

z

A tuple, list or NumPy array of three complex numbers represent the images of w. Defaults to (0, 1, np.inf).

name

Name of the transformation.

Returns

M

The corresponding MoebiusTransformation.

inverse(normalize=False)[source]

Returns the inverse Moebius transformation by applying the inversion formula.

Parameters

normalize

If True, the coefficients are normalized, i.e., \(ad-bc=1\). Defaults to False.

Returns

M

The inverse MoebiusTransformation.