next up previous
Next: Representing Coordinate Systems
Up: Overview of AST Concepts
Previous: Mappings Available

Compound Mappings  

The Mappings described in [*] provide a set of basic building blocks from which more complex Mappings may be constructed. The key to doing this is a type of Mapping called a CmpMap, or compound Mapping. A CmpMap's role is, in principle, very simple: it allows any other pair of Mappings to be joined together into a single entity which behaves as if it were a single Mapping. A CmpMap is therefore a container for another pair of Mappings.

A pair of Mappings may be combined using a CmpMap in either of two ways. The first of these, in series, is illustrated in the following Figure.


  
Figure: A CmpMap (compound Mapping) composed of two component Mappings joined in series. The output coordinates of the first Mapping feed into the input coordinates of the second one, so that the whole entity behaves like a single Mapping.
\begin{figure}
\includegraphics [scale=1.0]{sun210_figures/series.eps}

 \end{figure}

Here, the transformations implemented by each component Mapping are performed one after the other, with the output from the first Mapping feeding into the second. The second way, in parallel, is shown in the Figure below.

  
Figure: A CmpMap composed of two Mappings joined in parallel. Each component Mapping acts on a complementary subset of the input and output coordinates.
\begin{figure}
\includegraphics [scale=1.0]{sun210_figures/parallel.eps}

 \end{figure}

In this case, each Mapping acts on a complementary subset of the input and output coordinates.

The CmpMap forms the key to building arbitrarily complex Mappings because it is itself a form of Mapping. This means that a CmpMap may contain other CmpMaps as components (e.g. the Figure below). This nesting of CmpMaps can be repeated indefinitely, so that complex Mappings may be built in a hierarchical manner out of simper ones. This gives AST great flexibility in the coordinate transformations it can describe.


  
Figure: CmpMaps (compound Mappings) may be nested in order to construct complex Mappings out of simpler building blocks.
\begin{figure}
\includegraphics [scale=0.8]{sun210_figures/complex.eps}

 \end{figure}

Further reading: For a more complete description of CmpMaps, see [*]. Also see the CmpMap entry in [*].



next up previous
Next: Representing Coordinate Systems
Up: Overview of AST Concepts
Previous: Mappings Available

AST A Library for Handling World Coordinate Systems in Astronomy
Starlink User Note 210
R.F. Warren-Smith & D.S. Berry
30th April 2003
E-mail:ussc@star.rl.ac.uk

Copyright (C) 2003 Central Laboratory of the Research Councils