Ipelib

Public Member Functions | Public Attributes | Related Functions | List of all members
ipe::Linear Class Reference
Ipe Geometry

`#include <ipegeo.h>`

## Public Member Functions
| Linear ()
| Linear (Angle angle)
| Linear (double m11, double m21, double m12, double m22)
| Linear (String str)
Linear | inverse () const
bool | isIdentity () const
Vector | operator* (const Vector &rhs) const
bool | operator== (const Linear &rhs) const
double | determinant () const

## Public Attributes
double | a [4]

## Related Functions
(Note that these are not member functions.)
Stream & | operator<< (Stream &stream, const Linear &rhs)
Vector | operator* (const Vector &rhs) const
Linear | operator* (const Linear &lhs, const Linear &rhs)

## Detailed Description

Linear transformation in the plane (2x2 matrix).

## Constructor & Destructor Documentation

## ◆ Linear() [1/4]

ipe::Linear::Linear | ( |  | ) |
| inline

Create identity matrix.

Referenced by ipe::Segment::snap().

## ◆ Linear() [2/4]

Linear::Linear | ( | Angle | angle | ) |
| explicit

Create matrix representing a rotation by angle.

## ◆ Linear() [3/4]

ipe::Linear::Linear | ( | double | m11,
|  | double | m21,
|  | double | m12,
|  | double | m22
| ) |  |
| inline explicit

Create linear matrix with given coefficients.

## ◆ Linear() [4/4]

Linear::Linear | ( | String | str | ) |
| explicit

Parse string.

## Member Function Documentation

## ◆ inverse()

Linear Linear::inverse | ( |  | ) | const

Return inverse.

References a, and ipe::Matrix::Matrix().

Referenced by ipe::Arc::bbox().

## ◆ isIdentity()

bool ipe::Linear::isIdentity | ( |  | ) | const
| inline

Is this the identity matrix?

## ◆ operator*()

Vector ipe::Linear::operator* | ( | const Vector & | rhs | ) | const
| inline

## ◆ operator==()

bool ipe::Linear::operator== | ( | const Linear & | rhs | ) | const
| inline

Check for equality of two linear matrices.

References a.

## ◆ determinant()

double ipe::Linear::determinant | ( |  | ) | const
| inline

Return determinant of a linear matrix.

## Friends And Related Function Documentation

## ◆ operator<<()

Stream & operator<< | ( | Stream & | stream,
|  | const Linear & | rhs
| ) |  |
| related

## ◆ operator*() [1/2]

Vector operator* | ( | const Vector & | rhs | ) | const
| related

Linear matrix times vector.

References ipe::Vector::x, and ipe::Vector::y.

## ◆ operator*() [2/2]

Linear operator* | ( | const Linear & | lhs,
|  | const Linear & | rhs
| ) |  |
| related

Linear matrix multiplication.

References a.

## Member Data Documentation

## ◆ a

double ipe::Linear::a[4]

Referenced by inverse(), ipe::Matrix::Matrix(), operator*(), and operator==().

The documentation for this class was generated from the following files:

- ipegeo.h
- ipegeo.cpp