This routine decodes the value of a single component in a
SCUBA data-spec SCULIB_DECODE_COMPONENT
[1] "" select all data
[2] "index" select data at position index
[3] "index1,index2" select data at positions index1 and index2
[4] "index1:index2" select all data in the range index1 to index2
or any combination of 2, 3 and 4 separated by commas. Example component values are:-
"" select all data
"1,5" select data at indices 1 and 5
"5:10,16" select data at indices 5 through 10 and 16
Errors will occur if:-
You mix the format with selection by index.
Any index selected lies outside the range 1 to N.
In a selection range index2 is less than index1.
The component does not conform to the design syntax.
Output from the routine is in the form of a mask array SELECT. Data indices selected will be marked as 1 in SELECT, while indices not selected will be zeroes.