Public Member Functions | Public Attributes | Friends | List of all members
Acclaim::InterferometryCache Class Reference

Class to cache the deltaTs or parts of their calculation for fast map making. More...

#include <InterferometryCache.h>

Public Member Functions

 InterferometryCache ()
 
 InterferometryCache (CrossCorrelator *cc, const AnalysisReco *reco)
 
void init (CrossCorrelator *cc, const AnalysisReco *reco, bool forceCacheRecalculation=false)
 Initialize the cache, only needs to be done once. More...
 
int coarseIndex (int pol, int combo, int phiBin, int thetaBin)
 Get the internal array index for the fDeltaTs vector (for coarsely binned InterferometericMap) More...
 
double coarseDt (int pol, int combo, int phiBin, int thetaBin)
 Look up the delay for the antenna pair / polarization at a given angle. More...
 
int partBAsIndex (int pol, int combo, int fineThetaBin)
 Get the index for part of the deltaT calculation for the finely binned InterferometricMap. More...
 
int zoomedCosPartIndex (int pol, int ant, int finePhiBin)
 Get the index for part of the deltaT calculation for the finely binned InterferometricMap. More...
 
int part21sIndex (int pol, int combo, int finePhiBin)
 
void populateCache (CrossCorrelator *cc, const AnalysisReco *reco)
 
void populateFineCache (CrossCorrelator *cc, const AnalysisReco *reco)
 

Public Attributes

int fUseOffAxisDelay
 Should we use the off-axis delay? Set to 1 or 0 as it's used in a multiplication for speed.
 
bool fInitialized
 Has the cache been initialized?
 
int fNCoarseBinsPhi
 The number of phi bins in the coarsely binned interferometric map.
 
int fNCoarseBinsTheta
 The number of theta bins in the coarsely binned interferometric map.
 
int fNumCombos
 The number of possible antenna pairs to be correlated.
 
std::vector< double > fDeltaTs
 Delays between antenna pairs for the coarsely binned interferometric map.
 
int fNFineBinsPhi
 If a finely binned InterferometricMap extended over all 360 in phi (plus edge effects) it would have this many bins.
 
int fNFineBinsTheta
 If a finely binned InterferometricMap extended over all theta (plus edge effects) it would have this many bins.
 
std::vector< double > fPartBAsZoom
 Partial caching for the finely binned InterferometricMap. More...
 
std::vector< double > fPart21sZoom
 Partial caching for the finely binned InterferometricMap.
 
std::vector< double > fZoomedThetaWaves
 Values of theta (radians) for the finely binned InterferometricMap.
 
std::vector< double > fZoomedTanThetaWaves
 Values of tan(theta) for the finely binned InterferometricMap.
 
std::vector< double > fZoomedCosThetaWaves
 Values of cos(theta) for the finely binned InterferometricMap.
 
std::vector< double > fDtFactors
 Multiplier factor for the finely binned InterferometricMap.
 
std::vector< double > fZoomedPhiWaveLookup
 The value of phi in each bin in radians.
 
std::vector< double > fZoomedCosPartLookup
 Partial caching for the of the deltaT calculation.
 
std::vector< double > fOffAxisDelays
 Off-axis delays for use when making fine binned InterferometricMap.
 
std::vector< double > fOffAxisDelaysDivided
 Same as fOffAxisDelays, but delays scaled to remove an operation from an inner loop in InterfermetricMap.
 

Friends

class InterferometricMap
 

Detailed Description

Class to cache the deltaTs or parts of their calculation for fast map making.

It's a glorified set of std::vectors with some indexing logic

Definition at line 22 of file InterferometryCache.h.

Collaboration diagram for Acclaim::InterferometryCache:
Collaboration graph
[legend]

Constructor & Destructor Documentation

Acclaim::InterferometryCache::InterferometryCache ( )

Default constructor, not very useful

Definition at line 5 of file InterferometryCache.cxx.

Acclaim::InterferometryCache::InterferometryCache ( CrossCorrelator cc,
const AnalysisReco reco 
)

Useful constructor

Parameters
ccis a pointer to a CrossCorrelator
recois a pointer to an AnalysisReco

Definition at line 12 of file InterferometryCache.cxx.

Member Function Documentation

double Acclaim::InterferometryCache::coarseDt ( int  pol,
int  combo,
int  phiBin,
int  thetaBin 
)
inline

Look up the delay for the antenna pair / polarization at a given angle.

Parameters
polis the polarization
combois an index for the antenna pair
phiBinis the azimuthal bin (counting from 0) of the coarsely binned InterferometricMap
thetaBinis the elevation bin (counting from 0) of the coarsely binned InterferometricMap
Returns
the delay between the antenna pair

Definition at line 73 of file InterferometryCache.h.

int Acclaim::InterferometryCache::coarseIndex ( int  pol,
int  combo,
int  phiBin,
int  thetaBin 
)
inline

Get the internal array index for the fDeltaTs vector (for coarsely binned InterferometericMap)

Parameters
polis the polarization
combois an index for the antenna pair
phiBinis the azimuthal bin (counting from 0) of the coarsely binned InterferometricMap
thetaBinis the elevation bin (counting from 0) of the coarsely binned InterferometricMap
Returns
the index for fDeltaTs

Definition at line 59 of file InterferometryCache.h.

void Acclaim::InterferometryCache::init ( CrossCorrelator cc,
const AnalysisReco reco,
bool  forceCacheRecalculation = false 
)

Initialize the cache, only needs to be done once.

Parameters
ccis a pointer to the CrossCorrelator
recois a pointer to the AnalysisReco
forceCacheRecalculationset true to calculate the cached delays even if they've already been calculated.

Definition at line 21 of file InterferometryCache.cxx.

int Acclaim::InterferometryCache::part21sIndex ( int  pol,
int  combo,
int  finePhiBin 
)
inline

Get the index for the phi part of the deltaT calculation for the finely binned InterferometricMap

Parameters
polis the polarization
combois an index for the antenna pair
finePhiBinthe phi bin of the antenna pair (considering the full range of azimuth at the finely binned resolution)
Returns
the index for the fPart21sZoom

Definition at line 116 of file InterferometryCache.h.

int Acclaim::InterferometryCache::partBAsIndex ( int  pol,
int  combo,
int  fineThetaBin 
)
inline

Get the index for part of the deltaT calculation for the finely binned InterferometricMap.

At the current resolution caching the full set of dts for the finely binned InterferometricMap is too large to calculate over all azimuth/elevation

Parameters
polis the polarization
combois an index for the antenna pair
fineThetaBinthe theta bin of the antenna pair (considering the full range of theta at the finely binned resolution)
Returns
the index for the fPartBAsZoom

Definition at line 88 of file InterferometryCache.h.

void Acclaim::InterferometryCache::populateCache ( CrossCorrelator cc,
const AnalysisReco reco 
)

Populate the fDeltaTs cache for the coarsely binned InterferometricMap

Parameters
ccis the CrossCorrelator
recois the AnalysisReco

Definition at line 29 of file InterferometryCache.cxx.

void Acclaim::InterferometryCache::populateFineCache ( CrossCorrelator cc,
const AnalysisReco reco 
)

Populate the various caches for the finely binned InterferometricMap

Parameters
ccis the CrossCorrelator
recois the AnalysisReco

Definition at line 79 of file InterferometryCache.cxx.

int Acclaim::InterferometryCache::zoomedCosPartIndex ( int  pol,
int  ant,
int  finePhiBin 
)
inline

Get the index for part of the deltaT calculation for the finely binned InterferometricMap.

At the current resolution caching the full set of dts for the finely binned InterferometricMap is too large to calculate over all azimuth/elevation

Parameters
polis the polarization
antis the antenna
finePhiBinthe phi bin of the antenna pair (considering the full range of azimuth at the finely binned resolution)
Returns
the index for the fZoomedCosPartLookup

Definition at line 103 of file InterferometryCache.h.

Member Data Documentation

std::vector<double> Acclaim::InterferometryCache::fPartBAsZoom

Partial caching for the finely binned InterferometricMap.

The following variables represent a partial caching of the finely binned InterferometricMap dts. Calculating the full set of deltaTs would use too much memory. These are partially cached such that the minimize the dt calculations in an inner loop in InterferometricMap. I'm don't think the cached quantities are very physically meaningful and as such they have silly names.

Definition at line 155 of file InterferometryCache.h.


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