- ←Prev
- AST
A Library for Handling
World Coordinate Systems
in Astronomy - Next→
- TOC ↑
Description:
This function creates a new
Mapping which connects specified inputs within a supplied
Mapping to the corresponding outputs of the supplied Mapping. This is only possible if
the specified inputs correspond to some subset of the Mapping outputs. That is, there
must exist a subset of the Mapping outputs for which each output depends only on the
selected Mapping inputs, and not on any of the inputs which have not been selected.
Also, any output which is not in this subset must not depend on any of the
selected inputs. If these conditions are not met by the supplied Mapping, then a
NULL Mapping pointer is returned.
Synopsis
void astMapSplit( AstMapping
this, int nin,
const int in, int
out, AstMapping
map
)
Parameters:
this
Pointer to the Mapping to be split.
nin
The number of
inputs to pick from "
this"
.
in
Pointer to an array holding the indices within
the supplied Mapping of the inputs which are to be picked from the Mapping. This
array should have
"
nin
"
elements. If
"
Nin"
is the number of inputs of the
supplied Mapping, then each element should have a value in the range 1 to Nin.
out
Pointer to an array in which to return the indices of the outputs of the
supplied Mapping which are fed by the picked inputs. A value of one is used to
refer to the first Mapping output. The supplied array should have a length at
least equal to the number of outputs in the supplied Mapping. The number of
values stored in the array on exit will equal the number of outputs in the
returned Mapping. The i’
th element in the returned array holds the index within
the supplied Mapping which corresponds to the i’
th output of the returned
Mapping.
map
Address of a location at which to return a pointer to the
returned Mapping. This Mapping will have "
nin"
inputs (the number of outputs
may be different to "
nin"
). NULL is returned if the supplied Mapping has
no subset of outputs which depend only on the selected inputs. The returned
Mapping is a deep copy of the required parts of the supplied Mapping.
Notes:
Copyright (C) 2021 East Asian Observatory
- ←Prev
- AST
A Library for Handling
World
Coordinate Systems
in Astronomy - Next→
- TOC ↑