GWOLLUM
4.2.0
Tools for gravitational-wave analyses
|
Manage streams. More...
#include <Streams.h>
Public Member Functions | |
void | GetDetectorAMResponse (double &aFplus, double &aFcross, const double aRa, const double aDec, const double aPsi, const double aGmst) |
Computes antenna factors \(F_+\) and \(F_\times\). More... | |
unsigned int | GetDetectorIndex (void) |
Returns the detector index for this stream. More... | |
string | GetDetectorPrefix (void) |
Returns the detector prefix for this stream. More... | |
string | GetDirectory (const string aOutDir=".") |
Returns the stream directory. More... | |
double | GetLocalTime (const double aRa, const double aDec, const double aGeocentricTime) |
Converts the geocentric time to the detector local time [s]. More... | |
string | GetName (void) |
Returns the stream full name. More... | |
string | GetNameConv (void) |
Returns the stream name using the LIGO-Virgo file name convention. More... | |
string | GetNamePrefix (void) |
Returns the stream name prefix. More... | |
string | GetNameSuffix (void) |
Returns the stream name suffix. More... | |
string | GetNameSuffixUnderScore (void) |
Returns the stream name suffix with only underscores. More... | |
string | GetTriggerFileName (const unsigned int aGpsStart, const unsigned int aDuration, const string aFileFormat="root", const string aProcessName="PROC", const string aOutDir=".") |
Returns the stream trigger file name. More... | |
void | SetName (const string aName) |
Sets a new name to the stream. More... | |
Constructors and destructors | |
Streams (const string aName, const unsigned int aVerbose=0) | |
Constructor of the Streams class. More... | |
virtual | ~Streams (void) |
Destructor of the Streams class. More... | |
Public Member Functions inherited from Sample | |
double | GetHighPassFrequency (void) |
Returns the current highpass frequency. More... | |
unsigned int | GetNativeFrequency (void) |
Returns the current native sampling frequency [Hz]. More... | |
unsigned int | GetWindowSize (void) |
Returns the window size (=0 if no windowing). More... | |
unsigned int | GetWorkingFrequency (void) |
Returns the current working sampling frequency [Hz]. More... | |
void | SetDCRemoval (const bool aDCremove=true) |
Activates/Deactivates the DC removal. More... | |
bool | SetFrequencies (const unsigned int aNativeFrequency, const unsigned int aWorkingFrequency, const double aHighPassFrequency=0.0) |
Defines frequencies for the transformation. More... | |
bool | SetHighPassFrequency (const double aHighPassFrequency) |
Defines a highpass frequency. More... | |
bool | SetNativeFrequency (const int aNativeFrequency) |
Sets a new native sampling frequency. More... | |
void | SetWindow (const unsigned int aWindowSize, double *aWindow) |
Defines the window. More... | |
bool | SetWorkingFrequency (const unsigned int aWorkingFrequency) |
Sets a new working sampling frequency. More... | |
bool | Transform (const unsigned int aInSize, double *aInData, const unsigned int aOutSize, double *aOutData) |
Transforms data. More... | |
Sample (const unsigned int aVerbosity=0) | |
Constructor of the Sample class. More... | |
virtual | ~Sample (void) |
Destructor of the Sample class. More... | |
Protected Attributes | |
string | Name |
Stream name. More... | |
Protected Attributes inherited from Sample | |
double | fHighPassFrequency |
Cutoff frequency. More... | |
unsigned int | fNativeFrequency |
Native sampling frequency. More... | |
bool | fRemoveDC |
DC removal flag. More... | |
unsigned int | fVerbosity |
Verbosity level. More... | |
double * | fWindow |
Window. More... | |
unsigned int | fWindowSize |
Window size. More... | |
unsigned int | fWorkingFrequency |
Working sampling frequency. More... | |
Private Member Functions | |
void | ComputeDetectorResponse (void) |
Computes the detector spatial response matrix. More... | |
void | MakeDetector (void) |
Associates detector's properties to the stream (based on prefix). More... | |
Private Attributes | |
unsigned int | DetIndex |
Detector index. More... | |
double | DetLoc [3] |
Detector location (vertex) on Earth. More... | |
string | NamePrefix |
Stream prefix. More... | |
string | NameSuffix |
Stream suffix. More... | |
string | NameSuffixUnderScore |
Stream suffix with only underscores. More... | |
double | Response [3][3] |
Detector response. More... | |
unsigned int | verbose |
Verbosity level. More... | |
Manage streams.
This class is designed to identify data streams. In particular, the Stream object can be converted into one detector of the LIGO-virgo-KAGRA global network if the stream name is recognized as such. In that case many specific functions are provided to access the detector properties.
Streams::Streams | ( | const string | aName, |
const unsigned int | aVerbose = 0 |
||
) |
|
virtual |
Destructor of the Streams class.
|
private |
Computes the detector spatial response matrix.
void Streams::GetDetectorAMResponse | ( | double & | aFplus, |
double & | aFcross, | ||
const double | aRa, | ||
const double | aDec, | ||
const double | aPsi, | ||
const double | aGmst | ||
) |
Computes antenna factors \(F_+\) and \(F_\times\).
Antenna factors are calculated for a source at a specified sky position, polarization angle, and sidereal time. The implementation follows the formulae given in Anderson et al., PRD 63 042003 (2001)
[out] | aFplus | Returned \(F_+\) value. |
[out] | aFcross | Returned \(F_\times\) value. |
[in] | aRa | Right ascension [rad]. |
[in] | aDec | Declination [rad]. |
[in] | aPsi | Polarisation angle [rad]. |
[in] | aGmst | Sideral time [s]. |
|
inline |
Returns the detector index for this stream.
|
inline |
Returns the detector prefix for this stream.
|
inline |
Returns the stream directory.
Convention: ./[name]
Optionally, a root directory can be added: [aOutDir]/[name]
[in] | aOutDir | Root directory. |
|
inline |
Converts the geocentric time to the detector local time [s].
The wave propagation direction must be given by the right ascension and declination.
[in] | aRa | Right ascension [rad]. |
[in] | aDec | Declination [rad]. |
[in] | aGeocentricTime | Geocentric time [s]. |
|
inline |
Returns the stream full name.
|
inline |
Returns the stream name using the LIGO-Virgo file name convention.
|
inline |
Returns the stream name prefix.
|
inline |
Returns the stream name suffix.
|
inline |
Returns the stream name suffix with only underscores.
Dash characters are turned into underscore characters.
|
inline |
Returns the stream trigger file name.
[in] | aGpsStart | GPS start [s]. |
[in] | aDuration | Duration [s]. |
[in] | aFileFormat | File format (extension). |
[in] | aProcessName | Process name. |
[in] | aOutDir | Output directory. |
|
private |
Associates detector's properties to the stream (based on prefix).
void Streams::SetName | ( | const string | aName | ) |
Sets a new name to the stream.
A stream is identified by its name which shall follow the stream name convention: [prefix]:[suffix], where [prefix] is 2-characters string exactly.
[in] | aName | Stream name. |
|
private |
Detector index.
|
private |
Detector location (vertex) on Earth.
|
protected |
Stream name.
|
private |
Stream prefix.
|
private |
Stream suffix.
|
private |
Stream suffix with only underscores.
|
private |
Detector response.
|
private |
Verbosity level.