Construct a time-frequency-Q tiling. More...
#include <Otile.h>

Public Member Functions | |
| TH2D * | GetMap (const int qindex, double *aDataRe, double *aDataIm, const double time_offset=0.0, const bool printamplitude=false) |
| Returns a SNR map of data projected onto a given Q plane. | |
| int | GetNQPlanes (void) |
| Returns the number of Q planes. | |
| double | GetQ (const int qindex) |
| Returns the Q value of plane with index 'qindex'. | |
| bool | GetStatus (void) |
| Returns class status. | |
| bool | GetTriggers (Triggers *aTriggers, double *aDataRe, double *aDataIm, const int aTimeStart) |
| Saves triggers above SNR threshold. | |
| void | PrintInfo (void) |
| Prints detailed parameters of tiling structure. | |
| bool | SetPowerSpectrum (Spectrum *aSpec) |
| Sets the data power spectrum. | |
Constructors and destructors | |
| Otile (const int aTimeRange, const int aTimePad, const double aQMin, const double aQMax, const double aFrequencyMin, const double aFrequencyMax, const int aSampleFrequency, const double aMaximumMismatch, const double aSNRThreshold=0, const int aVerbosity=0) | |
| Constructor of the Otile class. | |
| virtual | ~Otile (void) |
| Destructor of the Otile class. | |
Construct a time-frequency-Q tiling.
This class was designed to tile the 3-dimensional space in time, frequency and Q. The tiling consists of logarithmically spaced Q-planes. Each of these planes is divided in logarithmically spaced frequency bands. Each of these bands are then linearly divided in time bins.
| Otile::Otile | ( | const int | aTimeRange, | |
| const int | aTimePad, | |||
| const double | aQMin, | |||
| const double | aQMax, | |||
| const double | aFrequencyMin, | |||
| const double | aFrequencyMax, | |||
| const int | aSampleFrequency, | |||
| const double | aMaximumMismatch, | |||
| const double | aSNRThreshold = 0, |
|||
| const int | aVerbosity = 0 | |||
| ) |
Constructor of the Otile class.
The tiling is constructed given the user parameters. The parameter space is defined by a time range, a frequency range and a Q range. A time pad value is given to exclude triggers produced at both ends of the time range (to remove filtering artifacts, for example). The user must specify a maximum mismatch value corresponding to a maximal fractional energy loss from one tile to the next. When GetTriggers() is called, only triggers with a SNR value larger than the threshold are saved.
Some conditions are to be met:
| aTimeRange | time range [s] | |
| aTimePad | time pad [s] | |
| aQMin | minimal Q value | |
| aQMax | maximal Q value | |
| aFrequencyMin | minimal frequency [Hz] | |
| aFrequencyMax | maximal frequency [Hz] | |
| aSampleFrequency | sampling frequency [Hz] | |
| aMaximumMismatch | maximum mismatch between tiles | |
| aSNRThreshold | SNR threshold to save triggers | |
| aVerbosity | verbosity level |
| Otile::~Otile | ( | void | ) | [virtual] |
Destructor of the Otile class.
| TH2D * Otile::GetMap | ( | const int | qindex, | |
| double * | aDataRe, | |||
| double * | aDataIm, | |||
| const double | time_offset = 0.0, |
|||
| const bool | printamplitude = false | |||
| ) |
Returns a SNR map of data projected onto a given Q plane.
A complex data vector is projected onto the Q-plane with index qindex. The tiles are populated with the SNR values and the resulting map is returned as a TH2 histogram.
The input complex vector must be given in the frequency domain and have the right size, i.e. half of the sampling frequency times the time range.
If given, the time offset is added to the time of the tiles.
If printamplitude=true, the amplitude is used instead of the SNR.
Do not delete the returned histogram. It will be deleted by the class.
| qindex | Q-plane index | |
| aDataRe | real part of the data vector (frequency domain) | |
| aDataIm | imaginary part of the data vector (frequency domain) | |
| time_offset | time offset [s] | |
| printamplitude | switch to amplitude |
| int Otile::GetNQPlanes | ( | void | ) | [inline] |
Returns the number of Q planes.
| double Otile::GetQ | ( | const int | qindex | ) |
Returns the Q value of plane with index 'qindex'.
-1.0 is returned if this function fails.
| qindex | Q-plane index |
| bool Otile::GetStatus | ( | void | ) | [inline] |
Returns class status.
| bool Otile::GetTriggers | ( | Triggers * | aTriggers, | |
| double * | aDataRe, | |||
| double * | aDataIm, | |||
| const int | aTimeStart | |||
| ) |
Saves triggers above SNR threshold.
A complex data vector is projected onto all Q-planes. The tiles are populated with the SNR values. A trigger is defined as a tile with a SNR value above the threshold defined in Otile(). This trigger is added to the Triggers object with the GWOLLUM convention with the following parameters:
A time offset must be given corresponding to the starting time of the time range.
| aTriggers | Triggers object | |
| aDataRe | real part of the data vector (frequency domain) | |
| aDataIm | imaginary part of the data vector (frequency domain) | |
| aTimeStart | time offset |
| void Otile::PrintInfo | ( | void | ) |
Prints detailed parameters of tiling structure.
| bool Otile::SetPowerSpectrum | ( | Spectrum * | aSpec | ) |
Sets the data power spectrum.
This function must be called before the GetTriggers() or GetMap() functions. The power spectrum must be set to compute the trigger amplitude defined as SNR*sqrt(power). power is the weighted average of the PSD over the tile (weighted by the tile Gaussian window). If this function is not called, power is set to 1 and the amplitude is just the SNR.
The PSD must be given as a valid Spectrum structure, i.e, the PSD was previously computed.
| aSpec | Spectrum structure where the PSD has been computed |
1.6.1