# FunctionMaps.jl

## What is FunctionMaps.jl

FunctionMaps is a submodule of DomainSets as of version 0.7.10. The module collects all functionality in the package that relates to functions in the sense of a map between spaces. It defines properties such as the jacobian etcetera.

The module is expected to be moved into a separate package in the future and will be independently documented.

## Public API Reference

### Functions

DomainSets.FunctionMaps.canonicalmapMethod
canonicalmap([ctype::CanonicalType, ]map)

Return an associated canonical map, if any, of the given map.

Optionally, a canonical type argument may specify an alternative canonical map. Canonical maps help with converting between equal maps of different types.

DomainSets.FunctionMaps.diffvolumeMethod
diffvolume(m[, x])

Compute the differential volume (at a point x). If J is the Jacobian matrix, possibly rectangular, then the differential volume is sqrt(det(J'*J)).

If the map is square, then the differential volume is the absolute value of the Jacobian determinant.

DomainSets.FunctionMaps.jacdetMethod
jacdet(m[, x])

Return the determinant of the jacobian as a map. The two-argument version evaluates the jacobian determinant at a point x.

DomainSets.FunctionMaps.leftinverseMethod
leftinverse(m[, x])

Return a left inverse of the given map. This left inverse mli is not unique, but in any case it is such that (mli ∘ m) * x = x for each x in the domain of m.

The two-argument function applies the left inverse to the point x.

DomainSets.FunctionMaps.rightinverseMethod
rightinverse(m[, x])

Return a right inverse of the given map. This right inverse mri is not unique, but in any case it is such that (m ∘ mri) * y = y for each y in the range of m.

The two-argument function applies the right inverse to the point x.

### Types

DomainSets.FunctionMaps.MapRefType
MapRef(m)

A reference to a map.

In a function call, MapRef(x) can be used to indicate that x should be treated as a map, e.g., foo(x, MapRef(m)).

## Internal API Reference

This is an exhaustive list of all non-exported constants, types and functions in FunctionMaps.jl.

Warning

Unexported functions and types are subject to change across different releases of the package, even if the release is said to be non-breaking.

### Functions

DomainSets.FunctionMaps.interval_mapMethod

Map the interval [a,b] to the interval [c,d].

This function deals with infinite intervals, and the type of the map returned may depend on the value (finiteness) of the given endpoints.

DomainSets.FunctionMaps.to_matrixMethod
to_matrix(::Type{T}, A[, b])

Convert the A in the affine map A*x or A*x+b with domaintype T to a matrix.

DomainSets.FunctionMaps.to_vectorMethod
to_vector(::Type{T}, A[, b])

Convert the b in the affine map A*x or A*x+b with domaintype T to a vector.

### Types

DomainSets.FunctionMaps.AbstractAffineMapType

An affine map has the general form y = A*x + b.

We use affinematrix(m) and affinevector(m) to denote A and b respectively. Concrete subtypes include linear maps of the form y = A*x and translations of the form y = x + b.

DomainSets.FunctionMaps.AngleMapType

AngleMap is a left inverse of UnitCircleMap. A 2D vector x is projected onto the intersection point with the unit circle of the line connecting x to the origin. The angle of this point, scaled to the interval [0,1), is the result.

DomainSets.FunctionMaps.LazyMapType

A lazy map has an action that is defined in terms of other maps. Those maps are stored internally, and the action of the lazy map is computed on-the-fly and only when invoked.