SimScan.h

Classes

SimScan -- a representation of the choice of telescope configuration used to produce a scan of observations. (full description)

class SimScan

Interface

Public Members
SimScan()
SimScan(const Vector<uInt> dds, const Vector<uInt> ants, const Vector<uInt> flds, uInt fieldrep=1, uInt srcid=0, uInt subary=0, uInt procid=0)
SimScan(const Vector<uInt> dds, const Vector<uInt> ants, const Quantity& inttime, uInt srcid=0, const Quantity& gaptime=Quantity(0.0, "s"), uInt subary=0, uInt procid=0)
SimScan(const Vector<uInt> dds, const Vector<uInt> ants, const Vector<uInt> flds, const Quantity& inttime, uInt fieldrep=1, uInt srcid=0, const Quantity& slewtime=Quantity(0.0, "s"), const Quantity& gaptime=Quantity(0.0, "s"), uInt subary=0, uInt procid=0)
SimScan(const SimObservations& obs, const Quantity& inttime, uInt srcid=0, uInt fieldrep=1, Bool sanityCheck=True, const Quantity& gaptime=Quantity(0.0, "s"), const Quantity& slewtime=Quantity(0.0, "s"), uInt procid=0)
SimScan(const SimScan& scan)
SimScan& operator=(const SimScan& scan)
virtual ~SimScan()
const Vector<uInt>& dataDescriptions() const
Vector<uInt>& dataDescriptions()
Bool checkDataDesc(const SimObservations& obs) const
static Bool checkDataDesc(const Vector<uInt>& descs, const SimObservations& obs)
uInt sourceId() const
void setSourceId(uInt srcid)
Bool checkSourceId(const SimObservations& obs) const
static Bool checkSourceId(Int srcid, const SimObservations& obs)
const Vector<uInt>& fields() const
Vector<uInt>& fields()
Bool checkFields(const SimObservations& obs) const
static Bool checkFields(Int srcid, const Vector<uInt>& flds, const SimObservations& obs)
const Vector<uInt>& antennas() const
Vector<uInt>& antennas()
Bool checkAntennas(const SimObservations& obs) const
static Bool checkAntennas(const Vector<uInt>& ants, const SimObservations& obs)
uInt arrayId() const
void setArrayId(uInt arrayid)
const Quantity& intTime() const
Double intTimeSec() const
void setIntTime(const Quantity& inttime)
const Quantity& gapTime() const
Double gapTimeSec() const
void setGapTime(const Quantity& gaptime)
const Quantity& slewTime() const
Double slewTimeSec() const
void setSlewTime(const Quantity& slewtime)
uInt fieldRepetition() const
void setFieldRepetition(uInt n)
uInt processorId() const
void setProcessorID(uInt id)
Bool check(const SimObservations& obs) const

Description

Prerequisite

Etymology

This class holds the parameters for a particular scan in a set of simulated observations. A scan is defined here as a set of consecutive integrations on the same source with unchanging observational parameters.

Synopsis

This class is a container for parameters to be used in a single scan of observations. (See etymology above for a definition of a scan.) A simulator (e.g. SimpleSimulator) would combine these parameters along with those access via a SimObservations object to drive the simulated observations. When observations are more complicated than just observing a single source, the simulator would typically manage one SimObservation but switch between a set of SimScans--say, one for each source.

Thus, a SimScan holds the part of the observational configuration that is expected to change the most through the run--primarily, the source, the set of fields, the set of data descriptions to fill (which selects the desired polarizations and spectral windows), the set of antennas to use (assigning a sub-array ID), the integration time, the scan start time and duration. One can also control gap times between integrations and a slew time between fields. This class also provides check functions that can check the validity of any of the IDs referenced against what is currently defined in a SimObservation object.

In general, the data held in a SimScan represents information that eventually winds up or otherwise affects the data that gets written to an MeasurementSet's main table. All subtable information is encapsulated in the SimObservations class.

Motivation

To make typical observing patterns (e.g. in which one switches between target and calibrator sources) easier to manage in a simulator, it is helpful to separate out the parameters that change between scans from the more static parameters held in the SimObservations class.

To Do

Member Description

SimScan()

construct an undefined SimScan

SimScan(const SimObservations& obs, const Quantity& inttime, uInt srcid=0, uInt fieldrep=1, Bool sanityCheck=True, const Quantity& gaptime=Quantity(0.0, "s"), const Quantity& slewtime=Quantity(0.0, "s"), uInt procid=0)

construct a defined SimScan

construct a scan that will observe all fields for the first source with all antennas and data descriptions currently defined for the given SimObservations.

SimScan(const SimScan& scan)

construct a defined SimScan

construct a copy of another scan

virtual ~SimScan()

construct a defined SimScan

delete this scan

const Vector<uInt>& dataDescriptions() const
Vector<uInt>& dataDescriptions()

construct a defined SimScan

return the list of data description ids that will be observed simultaneously in this scan.

Bool checkDataDesc(const SimObservations& obs) const
static Bool checkDataDesc(const Vector<uInt>& descs, const SimObservations& obs)

construct a defined SimScan

return true if data description ids can all be applied to the given SimObservations object. False is returned if any of the ids are out of range. The static version allows one to check a potential list of IDs before setting them.

void setSourceId(uInt srcid)

construct a defined SimScan

set the source ID of the source to be observed in this scan. A negative value means that the requested fields refer to multiple sources.

Bool checkSourceId(const SimObservations& obs) const
static Bool checkSourceId(Int srcid, const SimObservations& obs)

construct a defined SimScan

return true if the source id is defined in the given SimObservations. The static version allows one to check a source ID before it.

const Vector<uInt>& fields() const
Vector<uInt>& fields()

construct a defined SimScan

return the IDs of the fields that will be observed in succession with current subarray. ids will be resized if necessary.

Bool checkFields(const SimObservations& obs) const
static Bool checkFields(Int srcid, const Vector<uInt>& flds, const SimObservations& obs)

construct a defined SimScan

return true if the field Ids can all be applied to the given SimObservations. False is returned if any of the field Ids are out of range or don't match the current srcid. The static version allows one to check a potential list of IDs before setting them.

const Vector<uInt>& antennas() const
Vector<uInt>& antennas()

construct a defined SimScan

load into ids the IDs of the antennas observing the source in this scan.

Bool checkAntennas(const SimObservations& obs) const
static Bool checkAntennas(const Vector<uInt>& ants, const SimObservations& obs)

construct a defined SimScan

return true if the antenna Ids can all be applied to the given SimObservations. False is returned if any of the antenna Ids are out of range. The static version allows one to check a potential list of IDs before setting them.

void setArrayId(uInt arrayid)

construct a defined SimScan

set the subarray ID to assign to the current set of antennas

const Quantity& intTime() const
Double intTimeSec() const

construct a defined SimScan

return the integration time

const Quantity& gapTime() const
Double gapTimeSec() const

construct a defined SimScan

return the time interval between integrations

const Quantity& slewTime() const
Double slewTimeSec() const

construct a defined SimScan

return the time interval between observations of different fields

uInt fieldRepetition() const
void setFieldRepetition(uInt n)

construct a defined SimScan

get and set the number of integrations to perform on each field before slewing to the next one. This may be interpreted as a default value that may be overridden by the specific Field description.

void setProcessorID(uInt id)

construct a defined SimScan

set the processor ID

Bool check(const SimObservations& obs) const

construct a defined SimScan

return true if this Scan is applicable to the given SimObservations object. This calls the check*() routines in succession.

SimScan& operator=(const SimScan& scan)
uInt sourceId() const
uInt arrayId() const
void setIntTime(const Quantity& inttime)
void setGapTime(const Quantity& gaptime)
void setSlewTime(const Quantity& slewtime)
uInt processorId() const