Public Member Functions | Static Public Member Functions | List of all members
AnitaEventFaker Class Reference

Public Member Functions

 AnitaEventFaker (const char *responseDir, const TF1 &mag_response=getDefaultMagResponse(), double delay=30, double signal_dt=5e-2)
 
void setSignalFromMagnitudeResponse (const TF1 &mag_response, double delay=30, double signal_dt=5e-2, int npoints=2000)
 
void setSignalFromMagnitudeResponse (const TGraph &mag_response, double delay=30, double signal_dt=5e-2, int npoints=2000)
 
void setSignal (const AnalysisWaveform &sig)
 
void addSignal (UsefulAnitaEvent *event, double theta_deg, double phi_deg, double A=10, double extra_delay=0, std::complex< double > jones_H=std::complex< double >(1, 0), std::complex< double > jones_V=std::complex< double >(0, 0)) const
 
UsefulAnitaEventmakePureNoiseEvent (double rms=0.1, UsefulAnitaEvent *victim=0) const
 
const AnalysisWaveformgetSignal (int ant, int pol) const
 
const AnalysisWaveformgetPrototype () const
 
const TF2 & getHPolAntennaGainParameterization () const
 
const TF2 & getVPolAntennaGainParameterization () const
 
const TF2 & getOffAxisDelay () const
 
void setHPolAntennaGainParameterization (const TF2 &f)
 
void setVPolAntennaGainParameterization (const TF2 &f)
 
void setOffAxisDelay (const TF2 &f)
 

Static Public Member Functions

static const TF1 & getDefaultMagResponse ()
 
static const TF2 & getDefaultHPolAntennaGain ()
 
static const TF2 & getDefaultVPolAntennaGain ()
 
static const TF2 & getDefaultOffAxisDelay ()
 

Detailed Description

Definition at line 22 of file AnitaEventFaker.h.

Member Function Documentation

void AnitaEventFaker::addSignal ( UsefulAnitaEvent event,
double  theta_deg,
double  phi_deg,
double  A = 10,
double  extra_delay = 0,
std::complex< double >  jones_H = std::complex<double>(1,0),
std::complex< double >  jones_V = std::complex<double>(0,0) 
) const

Add a signal to this event coming from that direction

Parameters
eventthe event to add the signal to
theta_degthe degrees theta (with positive coming from below) for the signal , in payload coordinates
phi_degthe degrees phi of the signal , in payload coordinates
Aa scale factor for the signal
jones_Hcomplex Jones H-pol coefficient
jones_Vcomplex Jones V-pol coefficient

Definition at line 177 of file AnitaEventFaker.cc.

const TF1 & AnitaEventFaker::getDefaultMagResponse ( )
static

Retrieves the default magnitude response used.

Definition at line 32 of file AnitaEventFaker.cc.

const AnalysisWaveform& AnitaEventFaker::getSignal ( int  ant,
int  pol 
) const
inline

Return the current realization of the signal. This is the prottype convolved with each response

Definition at line 78 of file AnitaEventFaker.h.

UsefulAnitaEvent * AnitaEventFaker::makePureNoiseEvent ( double  rms = 0.1,
UsefulAnitaEvent victim = 0 
) const

This is just a helper function to make a pure noise event, where each channel is populated with random noise

Parameters
rmsThe RMS of the noise, in pre-response units
victimIf non-zero, this event will be filled with noise instead of constructing a new event.

Definition at line 114 of file AnitaEventFaker.cc.

void AnitaEventFaker::setSignal ( const AnalysisWaveform sig)

This explicitly sets the signal Note that the power will be rescaled to one.

Definition at line 58 of file AnitaEventFaker.cc.

void AnitaEventFaker::setSignalFromMagnitudeResponse ( const TF1 &  mag_response,
double  delay = 30,
double  signal_dt = 5e-2,
int  npoints = 2000 
)

These generates the signal based on the minimum phase signal corresponding to the specified magnitude response. The signal will be convolved with the impulse response.

Parameters
mag_responsea function giving the magnitude response (in relative units, as the power will be scaled away )
delaythe delay to apply to the signal (should be about the trigger delay)
signal_dtthe level to interpoalte the signal too. it will then be linearly interpolated on top of the event, so this should be significantly smaller than the sampling period of the events

Definition at line 97 of file AnitaEventFaker.cc.


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