VieSched++
VieVS VLBI Scheduling Software
VieVS::Subcon Class Reference

representation of a VLBI subcon More...

#include <Subcon.h>

Inheritance diagram for VieVS::Subcon:
Collaboration diagram for VieVS::Subcon:

Public Member Functions

 Subcon ()
 empty default constructor More...
 
void addScan (Scan &&scan) noexcept
 add a single source scan to subcon More...
 
void removeScan (unsigned long idx) noexcept
 removes a scan from the subcon More...
 
unsigned long getNumberSingleScans () const noexcept
 getter for number of possible single source scans More...
 
unsigned long getNumberSubnettingScans () const noexcept
 getter for number of possible subnetting scans More...
 
Scan takeSingleSourceScan (unsigned long idx) noexcept
 getter for a single source scan More...
 
std::pair< Scan, ScantakeSubnettingScans (unsigned long idx) noexcept
 getter for subnettin scan More...
 
void calcStartTimes (const Network &network, const SourceList &sourceList, const boost::optional< StationEndposition > &endposition=boost::none) noexcept
 calculates the earliest possible start time for all single source scans in this subcon More...
 
void constructAllBaselines (const Network &network, const SourceList &sourceList) noexcept
 constructs all baselines for all single source scans in this subcon More...
 
void updateAzEl (const Network &network, const SourceList &sourceList) noexcept
 updates all azimuths and elevations of all pointing vectors for each single source scan in this subcon More...
 
void calcAllBaselineDurations (const Network &network, const SourceList &sourceList, const std::shared_ptr< const Mode > &mode) noexcept
 calculates all baseline scan duration for all single source scans in this subcon More...
 
void calcAllScanDurations (const Network &network, const SourceList &sourceList, const boost::optional< StationEndposition > &endposition=boost::none) noexcept
 calculates all scan duration of all single source scans in this subcon More...
 
void createSubnettingScans (const std::shared_ptr< Subnetting > &subnetting, const Network &network, const SourceList &sourceList) noexcept
 create all subnetting scans from possible single source scans More...
 
void generateScore (const Network &network, const SourceList &sourceList) noexcept
 generate scores for all single source and subnetting scans More...
 
void generateScore (const std::vector< double > &lowElevatrionScore, const std::vector< double > &highElevationScore, const Network &network, const SourceList &sourceList)
 generate score for all scans during astrometric calibrator block More...
 
void generateScore (const Network &network, const SourceList &sourceList, const std::vector< std::map< unsigned long, double >> &hiscores, unsigned int interval)
 generate score for high impact scans More...
 
void generateCalibratorScore (const Network &network, const SourceList &sourceList, const std::shared_ptr< const Mode > &mode)
 generate score for calibrator blocks More...
 
void checkTotalObservingTime (const Network &network, const SourceList &sourceList)
 check if there is enough time to reach required endposition for all scans More...
 
void checkIfEnoughTimeToReachEndposition (const Network &network, const SourceList &sourceList, const boost::optional< StationEndposition > &endposition=boost::none)
 check if there is enough time to reach required endposition for all scans More...
 
void minMaxTime () noexcept
 get minimum and maximum time required for a possible scan More...
 
std::vector< ScanselectBest (Network &network, const SourceList &sourceList, const std::shared_ptr< const Mode > &mode, const boost::optional< StationEndposition > &endposition=boost::none) noexcept
 rigorousely updates the best scans until the best one is found More...
 
std::vector< ScanselectBest (Network &network, const SourceList &sourceList, const std::shared_ptr< const Mode > &mode, const std::vector< double > &prevLowElevationScores, const std::vector< double > &prevHighElevationScores, const boost::optional< StationEndposition > &endposition=boost::none) noexcept
 rigorousely updates the best scans until the best one is found during astrometric calibrator block More...
 
void clearSubnettingScans ()
 clear all subnetting scans More...
 
void calcCalibratorScanDuration (const std::vector< Station > &stations, const SourceList &sourceList)
 calc calibration scan duration (deprecated) More...
 
void changeType (Scan::ScanType type)
 change scan type of all scans More...
 
void visibleScan (unsigned int currentTime, Scan::ScanType type, const Network &network, std::shared_ptr< const AbstractSource > thisSource, std::set< unsigned long > observedSources=std::set< unsigned long >(), bool doNotObserveSourcesWithinMinRepeat=true)
 create possible visible scan to a source More...
 
const std::vector< Scan > & getSingleSourceScans () const
 Matthias Schartner. More...
 
- Public Member Functions inherited from VieVS::VieVS_Object
 VieVS_Object (unsigned long id)
 constructor More...
 
const unsigned long getId () const
 get object id More...
 
bool hasValidId () const
 check if id is valid More...
 
bool hasId (unsigned long id) const
 check if object has specific id More...
 
void setId (unsigned long id)
 set object id More...
 
std::string printId () const
 object id string More...
 

Private Member Functions

void precalcScore (const Network &network, const SourceList &sourceList) noexcept
 precalculate all necessary parameters to generate scores More...
 
void prepareAverageScore (const std::vector< Station > &stations) noexcept
 pre calculate station average number of observation score More...
 
void prepareAverageScore (const std::vector< Baseline > &baselines) noexcept
 pre calculate baseline average number of observation score More...
 
void prepareAverageScore (const SourceList &sourceList) noexcept
 pre calculate source average number of observation score More...
 
void prepareIdleTimeScore (const std::vector< Station > &stations) noexcept
 pre calculate extra score after long idle times More...
 
std::vector< double > prepareAverageScore_base (const std::vector< unsigned long > &nobs) noexcept
 pre calculate baseline average number of observation score More...
 

Private Attributes

unsigned long nSingleScans_ = 0
 number of single source scans More...
 
std::vector< ScansingleScans_
 all single source scans More...
 
unsigned long nSubnettingScans_ = 0
 number of subnetting scans More...
 
std::vector< std::pair< Scan, Scan > > subnettingScans_
 all subnetting scans More...
 
unsigned int minRequiredTime_ = std::numeric_limits<unsigned int>::max()
 minimum time required for a scan More...
 
unsigned int maxRequiredTime_ = std::numeric_limits<unsigned int>::min()
 maximum time required for a scan More...
 
std::vector< double > astas_
 average station score for each station More...
 
std::vector< double > asrcs_
 average source score for each source More...
 
std::vector< double > abls_
 average baseline score for each baseline More...
 
std::vector< double > idle_
 extra score for long idle time More...
 

Static Private Attributes

static unsigned long nextId = 0
 next id for this object type More...
 

Detailed Description

representation of a VLBI subcon

Author
Matthias Schartner
Date
29.06.2017

Constructor & Destructor Documentation

Subcon::Subcon ( )

empty default constructor

Author
Matthias Schartner

Member Function Documentation

void Subcon::addScan ( Scan &&  scan)
noexcept

add a single source scan to subcon

Author
Matthias Schartner
Parameters
scanscan which should be added

Here is the call graph for this function:

Here is the caller graph for this function:

void Subcon::calcAllBaselineDurations ( const Network network,
const SourceList sourceList,
const std::shared_ptr< const Mode > &  mode 
)
noexcept

calculates all baseline scan duration for all single source scans in this subcon

Author
Matthias Schartner
Parameters
networkstation network
sourceListlist of all sources
modeobserving mode

Here is the call graph for this function:

Here is the caller graph for this function:

void Subcon::calcAllScanDurations ( const Network network,
const SourceList sourceList,
const boost::optional< StationEndposition > &  endposition = boost::none 
)
noexcept

calculates all scan duration of all single source scans in this subcon

Author
Matthias Schartner
Parameters
networkstation network
sourceListlist of all sources
endpositionrequired endposition

Here is the call graph for this function:

Here is the caller graph for this function:

void Subcon::calcCalibratorScanDuration ( const std::vector< Station > &  stations,
const SourceList sourceList 
)

calc calibration scan duration (deprecated)

Author
Matthias Schartner
Parameters
stationslist of stations
sourceListlist of sources

Here is the caller graph for this function:

void Subcon::calcStartTimes ( const Network network,
const SourceList sourceList,
const boost::optional< StationEndposition > &  endposition = boost::none 
)
noexcept

calculates the earliest possible start time for all single source scans in this subcon

Author
Matthias Schartner
Parameters
networkstation network
sourceListlist of all sources
endpositionrequired endposition

Here is the call graph for this function:

Here is the caller graph for this function:

void Subcon::changeType ( Scan::ScanType  type)

change scan type of all scans

Author
Matthias Schartner
Parameters
typenew scan type

Here is the caller graph for this function:

void Subcon::checkIfEnoughTimeToReachEndposition ( const Network network,
const SourceList sourceList,
const boost::optional< StationEndposition > &  endposition = boost::none 
)

check if there is enough time to reach required endposition for all scans

Author
Matthias Schartner
Parameters
networkstation network
sourceListlist of all sources
endpositionrequired endposition

Here is the call graph for this function:

Here is the caller graph for this function:

void Subcon::checkTotalObservingTime ( const Network network,
const SourceList sourceList 
)

check if there is enough time to reach required endposition for all scans

Author
Matthias Schartner
Parameters
networkstation network
sourceListlist of all sources

Here is the call graph for this function:

Here is the caller graph for this function:

void Subcon::clearSubnettingScans ( )

clear all subnetting scans

Author
Matthias Schartner

Here is the caller graph for this function:

void Subcon::constructAllBaselines ( const Network network,
const SourceList sourceList 
)
noexcept

constructs all baselines for all single source scans in this subcon

Author
Matthias Schartner
Parameters
networkstation network
sourceListlist of all sources

Here is the call graph for this function:

Here is the caller graph for this function:

void Subcon::createSubnettingScans ( const std::shared_ptr< Subnetting > &  subnetting,
const Network network,
const SourceList sourceList 
)
noexcept

create all subnetting scans from possible single source scans

Author
Matthias Schartner
Parameters
subnettingsubnetting parameters
networkstation network
sourceListlist of all sources

Here is the call graph for this function:

Here is the caller graph for this function:

void Subcon::generateCalibratorScore ( const Network network,
const SourceList sourceList,
const std::shared_ptr< const Mode > &  mode 
)

generate score for calibrator blocks

Author
Matthias Schartner
Parameters
networkstation network
sourceListlist of all sources
modecurrent observing mode

Here is the call graph for this function:

Here is the caller graph for this function:

void Subcon::generateScore ( const Network network,
const SourceList sourceList 
)
noexcept

generate scores for all single source and subnetting scans

Author
Matthias Schartner
Parameters
networkstation network
sourceListlist of all sources

Here is the call graph for this function:

Here is the caller graph for this function:

void Subcon::generateScore ( const std::vector< double > &  lowElevatrionScore,
const std::vector< double > &  highElevationScore,
const Network network,
const SourceList sourceList 
)

generate score for all scans during astrometric calibrator block

Author
Matthias Schartner
Parameters
lowElevatrionScorelow elevation scores
highElevationScorehigh elevation score
networkstation network
sourceListlist of all sources

Here is the call graph for this function:

void Subcon::generateScore ( const Network network,
const SourceList sourceList,
const std::vector< std::map< unsigned long, double >> &  hiscores,
unsigned int  interval 
)

generate score for high impact scans

Author
Matthias Schartner
Parameters
networkstation network
sourceListlist of all sources
hiscoreshigh impact scores
intervalhigh impact search interval index

Here is the call graph for this function:

unsigned long VieVS::Subcon::getNumberSingleScans ( ) const
inlinenoexcept

getter for number of possible single source scans

Author
Matthias Schartner
Returns
number of possible single source scans

Here is the caller graph for this function:

unsigned long VieVS::Subcon::getNumberSubnettingScans ( ) const
inlinenoexcept

getter for number of possible subnetting scans

Author
Matthias Schartner
Returns
number of possible subnetting scans

Here is the caller graph for this function:

const std::vector<Scan>& VieVS::Subcon::getSingleSourceScans ( ) const
inline

Matthias Schartner.

Author
Matthias Schartner
Returns
single source scans

Here is the caller graph for this function:

void Subcon::minMaxTime ( )
noexcept

get minimum and maximum time required for a possible scan

Author
Matthias Schartner

Here is the call graph for this function:

Here is the caller graph for this function:

void Subcon::precalcScore ( const Network network,
const SourceList sourceList 
)
privatenoexcept

precalculate all necessary parameters to generate scores

Author
Matthias Schartner
Parameters
networkstation network
sourceListlist of all sources

Here is the call graph for this function:

Here is the caller graph for this function:

void VieVS::Subcon::prepareAverageScore ( const std::vector< Station > &  stations)
privatenoexcept

pre calculate station average number of observation score

Author
Matthias Schartner
Parameters
stationslist of all stations

Here is the caller graph for this function:

void VieVS::Subcon::prepareAverageScore ( const std::vector< Baseline > &  baselines)
privatenoexcept

pre calculate baseline average number of observation score

Author
Matthias Schartner
Parameters
baselineslist of all baselines
void Subcon::prepareAverageScore ( const SourceList sourceList)
privatenoexcept

pre calculate source average number of observation score

Author
Matthias Schartner
Parameters
sourceListlist of all sources

Here is the call graph for this function:

std::vector< double > Subcon::prepareAverageScore_base ( const std::vector< unsigned long > &  nobs)
privatenoexcept

pre calculate baseline average number of observation score

Author
Matthias Schartner
Parameters
nobsnuber of observation per object
Returns
average number of observation score

Here is the caller graph for this function:

void Subcon::prepareIdleTimeScore ( const std::vector< Station > &  stations)
privatenoexcept

pre calculate extra score after long idle times

Author
Matthias Scharnter
Parameters
stationslist of all stations

Here is the caller graph for this function:

void Subcon::removeScan ( unsigned long  idx)
noexcept

removes a scan from the subcon

Author
Matthias Schartner

The index counts first through all single source scans and continues with all subnetting scans. If the index is larger then the number of single scans subnetting scans will be removed.

Parameters
idxindex of scan which should be removed

Here is the call graph for this function:

Here is the caller graph for this function:

vector< Scan > Subcon::selectBest ( Network network,
const SourceList sourceList,
const std::shared_ptr< const Mode > &  mode,
const boost::optional< StationEndposition > &  endposition = boost::none 
)
noexcept

rigorousely updates the best scans until the best one is found

Author
Matthias Schartner

in case a subnetting scan combination has highest score these two scans are returned, otherwise only a single scan is returned

Parameters
networkstation network
sourceListlist of all sources
modeobserving mode
endpositionrequired endposition
Returns
scan(s) with highest score

Here is the caller graph for this function:

vector< Scan > Subcon::selectBest ( Network network,
const SourceList sourceList,
const std::shared_ptr< const Mode > &  mode,
const std::vector< double > &  prevLowElevationScores,
const std::vector< double > &  prevHighElevationScores,
const boost::optional< StationEndposition > &  endposition = boost::none 
)
noexcept

rigorousely updates the best scans until the best one is found during astrometric calibrator block

Author
Matthias Schartner

in case a subnetting scan combination has highest score these two scans are returned, otherwise only a single scan is returned

Parameters
networkstation network
sourceListlist of all sources
modeobserving mode
prevLowElevationScoreslow elevation scores
prevHighElevationScoreshigh elevation scores
endpositionrequired endposition
Returns
scan(s) with highest score

Here is the call graph for this function:

Scan VieVS::Subcon::takeSingleSourceScan ( unsigned long  idx)
inlinenoexcept

getter for a single source scan

Author
Matthias Schartner
Parameters
idxindex
Returns
single source scan at this index

Here is the caller graph for this function:

std::pair<Scan, Scan> VieVS::Subcon::takeSubnettingScans ( unsigned long  idx)
inlinenoexcept

getter for subnettin scan

Author
Matthias Schartner
Parameters
idxindex
Returns
subnetting scan at this index

Here is the call graph for this function:

Here is the caller graph for this function:

void Subcon::updateAzEl ( const Network network,
const SourceList sourceList 
)
noexcept

updates all azimuths and elevations of all pointing vectors for each single source scan in this subcon

Author
Matthias Schartner
Parameters
networkstation network
sourceListlist of all sources

Here is the call graph for this function:

Here is the caller graph for this function:

void Subcon::visibleScan ( unsigned int  currentTime,
Scan::ScanType  type,
const Network network,
std::shared_ptr< const AbstractSource thisSource,
std::set< unsigned long >  observedSources = std::set<unsigned long>(),
bool  doNotObserveSourcesWithinMinRepeat = true 
)

create possible visible scan to a source

Author
Matthias Schartner
Parameters
currentTimecurrent start time
typescan type
networkstation network
thisSourcetarget source
observedSourceslist of priviously observed sources
doNotObserveSourcesWithinMinRepeatconsider scans (with reduced weight) if they are within min repeat time

Here is the call graph for this function:

Here is the caller graph for this function:

Member Data Documentation

std::vector<double> VieVS::Subcon::abls_
private

average baseline score for each baseline

std::vector<double> VieVS::Subcon::asrcs_
private

average source score for each source

std::vector<double> VieVS::Subcon::astas_
private

average station score for each station

std::vector<double> VieVS::Subcon::idle_
private

extra score for long idle time

unsigned int VieVS::Subcon::maxRequiredTime_ = std::numeric_limits<unsigned int>::min()
private

maximum time required for a scan

unsigned int VieVS::Subcon::minRequiredTime_ = std::numeric_limits<unsigned int>::max()
private

minimum time required for a scan

unsigned long Subcon::nextId = 0
staticprivate

next id for this object type

unsigned long VieVS::Subcon::nSingleScans_ = 0
private

number of single source scans

unsigned long VieVS::Subcon::nSubnettingScans_ = 0
private

number of subnetting scans

std::vector<Scan> VieVS::Subcon::singleScans_
private

all single source scans

std::vector<std::pair<Scan, Scan> > VieVS::Subcon::subnettingScans_
private

all subnetting scans


The documentation for this class was generated from the following files: