6 Frequency Selection
Frequency selection expression consists of two specifications separated by colon (’:’) in the
form:
SPWSPEC[:FREQSPEC]
where SPW is the spectral window specification and FREQSPEC is the optional frequency
specification for selection within the selected spectral windows. When channel specification is
omitted, all channels of the selected SPW are selected.
SPWSPEC and FREQSPEC allow use of semi-colon separated lists. As a result, list of
SPWSPEC can be given in two ways: (1) a semi-colon separated list, (2) coma separated list. This
allows simple selections to remain simple and more complex selections consistent with the syntax
for FREQSPEC list.
The full syntax is shown in the Railroad Diagram format in Table 6 and explained in the
following sections.
Table 6: Railroad diagrams for the syntax of full frequency selection expression.
6.1 Spectral Window Specification Syntax
Spectral windows (SPW) specification can be of the following types:
- an integer ID
- a name (as a literal string (section 1.4) for exact match or a regular expression/pattern)
- a frequency value (value with a unit).
6.1.1 Selection by ID
SPWSPEC can be single integer, a list or a range of integers. It can also be a list of boolean
expressions involving IDs. E.g.
- spwspec=”>ID” will select all SPWs with ID greater than the specified value.
- spwspec=”<ID” will select all SPWs with ID lesser than the specified value.
- spwspec=1,2,3 selects spectral window IDs 1,2 and 3
- spwspec=1;2;3 same as above. This style can be used along with FREQSPEC
- spwspec=1~3 same as above
6.1.2 Selection By Name
SPWSPEC can be a name or a list of names which will be matched against the NAME
column of the SPECTRAL_WINDOW. The name can be a string for literal matching, or a
regular expression or a pattern. All SPWs that match the given name will be selected.
E.g.
- spwspec=”LBAND” will select a SPW named “LBAND”.
- spwspec=”SUBBAND*” will select all SPWs with the name starting with “SUBBAND”.
- spwspec=”SUBBAND*0” will select all SPWs with name starting with “SUBBAND” and
ending with “0”.
6.1.3 Selection By Frequency
SPWSPEC can also be constructed using the reference frequency of the SPWs. The reference
frequency is defined as the average of the frequency corresponding to the first and the last channel
for each SPW. A single frequency specification is used for exact match with the reference
frequency. A range (section 1.2) of frequencies are used to select all SPWs with the reference
frequencies within the given range. The allowed units are Hz, KHz, MHz, GHz or THz.
E.g.
- spwspec=”>FREQ” will select all SPWs, the reference frequencies of which are greater
than the given frequency converted to Hz.
- spwspec=”<FREQ” will select all SPWs, the reference frequencies of which are greater
than the given frequency converted to Hz.
- spwspec=327MHz selects spectral window with a reference frequency equal to 327.0
MHz
- spwspec=327~610MHz selects all spectral windows with reference frequencies in the
range [327.0, 610.0] MHz.
- spwspec=1421MHz, 1422MHz, 1423MHz selects SPWs with reference frequency
1421.0, 1422.0 and 1423.0 MHz.
- spwspec=1421MHz; 1422MHz; 1423MHz same as above. This style can be used
along with FREQSPEC.
- spwspec=>327MHz selects all spectral windows with reference frequency greater than
327.0 MHz
- spwspec=<327MHz selects all spectral windows with reference frequency less than
327.0 MHz
6.2 Channel Specification Syntax
Channel specification
(referred to as FREQSPEC in the following description) is a START, STOP, STEP tuple
corresponding to the first frequency channel, the last frequency channel and the step size to
increment from the first to the last channel. The START and STOP part of the tuple can be range
(section 1.2) specification for the range [START, STOP] followed by an optional STEP
size.
START and STOP part of the tuple can be specified as a single integer or physical quantity or
as a range (section 1.2) of integers or physical quantities. A single integer is treated as a channel
index and the tuple corresponds to [ID,ID,1]. A single physical quantity is matched with the exact
frequency value of the channels and tuple of matched channel index is constructed as [ID,ID,1]. A
range (section 1.2) of integers given as N0~N1 is used to construct a tuple [N0,N1,1]. Similarly for
a range of physical quantities.
If a START,STOP part of the tuple specification is followed by ”^STEP”, the STEP is used as the
third value of the tuple. STEP specification is a single integer or physical quantity. E.g. 0~10^2 is
converted to a START, STOP, STEP tuple [0,10,2].
A channel selection expression is a semi-colon separated list of channel specifications.
E.g.
- chanspec=1;2;3 selects channels 1,2 and 3.
- chanspec=1~3 selects channels 1,2 and 3.
- chanspec=0~10^2 selects channels in the range [0,10] with a step size of 2
- chanspec=1421MHz selects a frequency channel corresponding to the frequency
1421.0 MHz
- chanspec=1421~1500MHz selects all channels in the range [1412.0, 1500.0] MHz
- chanspec=1421~1500MHz^10KHz selects all channels in the range [1421.0, 1500.0]
MHz in steps of 10 KHz.
- chanspec=1421~1500MHz^10KHz
; 0~10^2 ; 20 ; 30; 40 selects all channels in the range [1421.0, 1500.0] MHz
in steps of 10KHz, all channels with indexes in the range [0,10] in steps of 2 channels
and channels 10, 20 and 30.
6.3 Frequency Selection Syntax
The specifications for SPW and channels can be combined to form a fully qualified frequency
selection expression of the form SPWSPEC[:FREQSPEC] (square brackets indicate that
:FREQSPEC is optional). A frequency selection expression is a comma-separated list of
SPWSPEC[:FREQSPEC] specifications. Channel selections apply to all SPWs selected by the
SPWSPEC on the left of ’:’. E.g.
- freq=LBAND:1421~1500MHz^10KHz , 327MHz:300~400MHz, 0~4:0~10^2 ,
5:20;30;40
selects
- all channels corresponding to channels in the range [1421.0, 1500.0] MHz for the
SPW named ”LBAND”, and
- all channels corresponding to the range [300.0, 400.0]MHz for the SPW with a
reference frequency of 327.0 MHz, and
- Channels in the range [0,10] in steps of 2 for all SPWs with IDs in the range [0,4],
and
- Channels 20, 30 and 40 for SPW 5
- freq=1421Mhz;1422Mhz;1423Mhz : 0;1;2;10~20;30~100~10 ,0~3:10~30
selects
- Channels 0, 1, 2 for SPWs with reference frequency of 1421.0, 1422.0 and 1423.0
MHz.
- Channels 10 to 20 in step of 1 channel for SPWs with reference frequency of
1421.0, 1422.0 and 1423.0 MHz.
- Channels 30 to 100 in steps of 10 channel for SPWs with reference frequency of
1421.0, 1422.0 and 1423.0 MHz.
- Channels 10 to 30 in step of 1 channel for SPW IDs 0 to 3 in step of 1.
Figure 1 shows an example frequency setup to motivate the need to separate the full frequency
selection expression into SPWSPEC and FREQSPEC parts. SPW0 covers the frequency range
1.0–2.0 GHz with SPW1 overlapping in the range 1.6–1.7 GHz, with a reference frequency of
1.5 GHz and 1.65 GHz respectively. With independent specifications for SPW and channel
selection, selection expressions can be constructed to select channels from SPW0 or SPW1 or
from SPW0 and SPW1. E.g.
- freq= ⋆ : 1.6~1.7GHz will select all channels from SPW0 and SPW1 that are in the
range
- freq= 1.5~1.65GHz : 1.6~1.7GHz is the same as above (selecting SPWs via
reference frequency specification)
- freq=1.5GHz : 1.6~1.7GHz will select all channels from only SPW0 that are in the
range
- freq=0 : 1.6~1.7GHz will select all channels from only SPW0 that are in the range
- freq=1.65GHz : 1.6~1.7GHz same as above, with SPW1 selected via integer ID
- freq=1 : 1.6~1.7GHz same as above, with SPW1 selected via integer ID
6.3.1 Notes
- For channel specifications of the type N1~N2:c0;c1;c2;c3MHz the list of channel
selection is applied to all SPWs in the range [N0, N1]. c3 is converted from physical
units to channel index by using the channel width from SPW N1. Is it better to use the
min. chan. among the selected SPWs?
- If channel range is out of bounds, it will be brought within bounds per SPW. If the lower
limit of a range is greater than the available outer limit, exception is generated. If the
lower limit is less than zero, it is set to zero. If upper limit is greater than the available
outer limit, it is set to the available outer limit.
If a single channel specification is greater than the available outer limit, an exception is
thrown. If it is less than zero, it is set to zero.
- For ranges of physical values, it is assumed that the spectral window sub-table’s
CHAN_FREQ column has ordered list of channel frequencies.