Omicron  4.2.0
An algorithm to detect and characterize transient events in gravitational-wave detectors
OxCorr Class Reference

Ox cross-correlation engine. More...

#include <OxCorr.h>

Inheritance diagram for OxCorr:
Collaboration diagram for OxCorr:

Public Member Functions

double GetTimeDelay (const unsigned int aTimeDelayBinIndex)
 Returns the time delay of a bin in the cross-correlation map [s]. More...
 
unsigned int GetTimeDelayBinIndex (const double aTimeDelay)
 Returns the time-delay bin index for a given time delay. More...
 
unsigned int GetTimeDelayBinsN (void)
 Returns the number of time-delay bins. More...
 
double GetTimeDelayResolution (void)
 Returns the time-delay resolution [s]. More...
 
double GetXi (const unsigned int aQindex, const unsigned int aFrequencyIndex, const unsigned int aTimeDelayIndex)
 Returns the cross-correlation coefficient \(\xi(Q,f,dt)\). More...
 
bool Process (void)
 Runs the cross-correlation analysis. More...
 
bool Transform (const unsigned int aDetectorIndex)
 Transforms the Omicron spectrogram in the Fourier domain. More...
 
Constructors and destructors
 OxCorr (const string aOptionFile, const unsigned int aGpsRef)
 Constructor of the OxCorr class. More...
 
virtual ~OxCorr (void)
 Destructor of the OxCorr class. More...
 
- Public Member Functions inherited from OxOmicron
bool CreateOutputFile (const unsigned int aTime)
 Creates an ouput file. More...
 
unsigned int GetAnalysisDuration (void)
 Returns the Ox analysis duration [s]. More...
 
Long64_t GetEntries (const unsigned int aDetectorIndex)
 Returns the number of Omicron results. More...
 
int GetEntry (const unsigned int aDetectorIndex, Long64_t aEntry)
 Loads an entry in the Omicron results. More...
 
double GetLightTravelTime (void)
 Returns the light travel time between the two detectors. More...
 
string GetOmicronChannelName (const unsigned int aDetectorIndex)
 Returns the Omicron channel name. More...
 
unsigned int GetOmicronChunkDuration (void)
 Returns the Omicron chunk duration [s]. More...
 
unsigned int GetOmicronEndTime (const unsigned int aDetectorIndex)
 Returns the end time of the current Omicron entry. More...
 
unsigned int GetOmicronOverlapDuration (void)
 Returns the Omicron overlap duration [s]. More...
 
unsigned int GetOmicronQ (const unsigned int aQindex)
 Returns Q value of a given Q plane. More...
 
unsigned int GetOmicronQN (void)
 Returns the number of Omicron Q planes. More...
 
unsigned int GetOmicronStartTime (const unsigned int aDetectorIndex)
 Returns the start time of the current Omicron entry. More...
 
bool Process (const unsigned int aDetectorIndex, const unsigned int aTimeStart, const bool aResetPsd)
 Runs the Omicron analysis. More...
 
 OxOmicron (const string aOptionFile, const unsigned int aGpsRef)
 Constructor of the OxOmicron class. More...
 
virtual ~OxOmicron (void)
 Destructor of the OxOmicron class. More...
 
- Public Member Functions inherited from OxInit
void AttachTree (TTree *aTree)
 Attach a TTree to the output file. More...
 
void CloseOutputFile (void)
 Closes the current ouput file (if any). More...
 
bool CreateOutputFile (const unsigned int aTime)
 Creates an ouput file. More...
 
string GetName (void)
 Returns the object name. More...
 
string GetOutputDirectory (void)
 Returns the path to the output directory. More...
 
bool GetStatus (void)
 Returns the class status. More...
 
 OxInit (const string aOptionFile)
 Constructor of the OxInit class. More...
 
virtual ~OxInit (void)
 Destructor of the OxInit class. More...
 

Private Attributes

fft *** map_fft [2]
 Map FFT plans: detector 1, detector 2 (cross-correlation). More...
 

Additional Inherited Members

- Protected Member Functions inherited from OxInit
void AddOptions (void)
 Adds options from the text file. More...
 
void DefineOption (const string aTag, const string aKey, const double aDefaultValue, const unsigned int aSize)
 Defines an option (double). More...
 
void DefineOption (const string aTag, const string aKey, const int aDefaultValue, const unsigned int aSize)
 Defines an option (integer). More...
 
void DefineOption (const string aTag, const string aKey, const string aDefaultValue, const unsigned int aSize)
 Defines an option (string). More...
 
void DefineOption (const string aTag, const string aKey, const unsigned int aDefaultValue, const unsigned int aSize)
 Defines an option (unsigned integer). More...
 
void OverloadOption (const string aTag, const string aKey)
 Overloads an option using the text file as a reference. More...
 
- Protected Attributes inherited from OxOmicron
Omicronomicron [2]
 Omicron objects (detector 1 and 2) - do not delete. More...
 
TTree * oxo_tree [2]
 TTree: Omicron results. Do not delete as it is owned by the output file. More...
 
TChain * oxo_tree_read [2]
 TChain: Omicron results (read-only). More...
 
- Protected Attributes inherited from OxInit
GwollumOptions * ox_opt
 List of options. More...
 
bool status
 Class status. More...
 

Detailed Description

Ox cross-correlation engine.

This class is designed to compute the cross-correlation of Omicron spectrograms. The one-dimensional cross-correlation is performed in the Fourier domain along the time direction.

The Omicron analysis is managed by the OxOmicron class. Use it to compute the the spectrograms for both detectors. Then, call Transform() to Fourier-transform the spectrograms. Finally, the cross-correlation is computed with Process().

Constructor & Destructor Documentation

◆ OxCorr()

OxCorr::OxCorr ( const string  aOptionFile,
const unsigned int  aGpsRef 
)

Constructor of the OxCorr class.

FFT plans are created. They cover the duration of the Omicron spectrograms excluding half the overlap at both sides.

An option file must be provided to set the cross-correlation parameters:

  • OXC TIMERES Time resolution [s] of the cross-correlation. The time resolution cannot be lower than the resolution of the \(Q=0\) Omicron time-frequency plane. Set this parameter to a negative value to use the maximal time resolution.
  • OXC SPECTROPOWER The amplitude spectrograms from Omicron are applied a power law: \((A^{2}/norm)^{\alpha}\), where \(\alpha\) is the power-law index and \(norm\) is a normalization factor. Provide \(\alpha\) and \(norm\) with this option. See Transform().
Parameters
[in]aOptionFilePath to the option file.
[in]aGpsRefReference GPS time to intiate Omicron objects.

◆ ~OxCorr()

OxCorr::~OxCorr ( void  )
virtual

Destructor of the OxCorr class.

Member Function Documentation

◆ GetTimeDelay()

double OxCorr::GetTimeDelay ( const unsigned int  aTimeDelayBinIndex)
inline

Returns the time delay of a bin in the cross-correlation map [s].

The requested time delay is given by the bin low edge.

When the two spectrograms are mis-aligned in time, an extra time delay is added. It is derived from the Omicron spectrogram times.

Parameters
[in]aTimeDelayBinIndexTime-delay bin index (starts at 0).

◆ GetTimeDelayBinIndex()

unsigned int OxCorr::GetTimeDelayBinIndex ( const double  aTimeDelay)
inline

Returns the time-delay bin index for a given time delay.

When the two spectrograms are mis-aligned in time, the extra time delay is removed. It is derived from the Omicron spectrogram times.

Note
The time-delay bin index starts at 0.
Parameters
[in]aTimeDelayTime delay [s].

◆ GetTimeDelayBinsN()

unsigned int OxCorr::GetTimeDelayBinsN ( void  )
inline

Returns the number of time-delay bins.

◆ GetTimeDelayResolution()

double OxCorr::GetTimeDelayResolution ( void  )
inline

Returns the time-delay resolution [s].

This is the size of one time-delay bin.

◆ GetXi()

double OxCorr::GetXi ( const unsigned int  aQindex,
const unsigned int  aFrequencyIndex,
const unsigned int  aTimeDelayIndex 
)
inline

Returns the cross-correlation coefficient \(\xi(Q,f,dt)\).

Parameters
[in]aQindexQ plane index (must be valid!).
[in]aFrequencyIndexFrequency row index (must be valid!).
[in]aTimeDelayIndexTime-delay index (must be valid!).

◆ Process()

bool OxCorr::Process ( void  )

Runs the cross-correlation analysis.

After the Omicron spectrograms have been transformed in the Fourier domain (Transform()), this function runs the cross-correlation analysis. The cross-correlation is performed in the Fourier domain. After Fourier-transforming back the data, the cross-correlation map is obtained.

Warning
After calling this function, the FFT structure for the second detector is used to store the cross-correlation coefficients \(\xi\). It can no longer be used to compute a new cross-correlation map. This is not the case for the first detector: this function can be called again to process a new spectrogram of detector 2.

◆ Transform()

bool OxCorr::Transform ( const unsigned int  aDetectorIndex)

Transforms the Omicron spectrogram in the Fourier domain.

The Omicron time-frequency maps are resampled at the OxCorr time resolution and the Omicron overlap is removed at both sides of the map. The resulting time-frequency maps are Fourier-transform along the time direction. This is done one frequency row at a time. Each frequency row is normalized:

  • the mean value of the row is subtracted.
  • the Fourier transform normalization ( \(/N_\tau\)) is applied.
  • the RMS normalization is applied.
Note
The amplitude spectrograms are applied a power law: \((A^{2}/norm)^{\alpha}\), where \(\alpha\) is the power-law index and \(norm\) is a normalization factor.
Parameters
[in]aDetectorIndexDetector index: 0 = first detector, 1 = second detector.

Member Data Documentation

◆ map_fft

fft*** OxCorr::map_fft[2]
private

Map FFT plans: detector 1, detector 2 (cross-correlation).


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