6 #define ADV_LIGO_PSD "$HOME_WAT/tools/cwb/plugins/strains/advLIGO_NSNS_Opt_8khz_one_side.txt"
7 #define DELTA_FREQ 0.125 // Hz
13 #define AMP_FACTOR 1e-21
43 cout <<
"Et = " << Et << endl;
51 for(
int i=0;
i<x.
size();
i++) Ef+=x[
i]*x[
i]*df;
52 cout <<
"Ef = " << 2*Ef << endl;
58 cout <<
"PSD : " <<
" rate : " << psd.
rate() <<
" size : " << psd.
size() <<
" df " << df << endl;
67 if(freq<fLow || freq>fHigh)
continue;
68 snr+=(x[2*
i]*x[2*
i]+x[2*
i+1]*x[2*
i+1])/pow(psd[
i],2)*
df;
72 cout <<
"SNR " << snr << endl;
80 for(
int i=0;
i<a.
size();
i++) a[
i]=sqrt(x[2*
i]*x[2*
i]+x[2*
i+1]*x[2*
i+1]);
83 TObjString* sname = (TObjString*)token->At(token->GetEntries()-1);
84 TString Title = sname->GetString();
93 grMDC.SetMarkerColor(kBlue);
94 grMDC.SetLineColor(kBlue);
96 grPSD.SetTitle(Title);
97 grPSD.SetMarkerColor(kRed);
98 grPSD.SetLineColor(kRed);
99 grPSD.GetHistogram()->GetXaxis()->SetRangeUser(8,8192);
100 grPSD.GetHistogram()->GetYaxis()->SetRangeUser(1
e-24,1
e-21);
101 grPSD.GetHistogram()->GetXaxis()->SetTitle(
"Hz");
102 grPSD.GetHistogram()->GetYaxis()->SetTitle(
"PSD");
103 grPSD.GetHistogram()->GetYaxis()->SetTitleOffset(1.2);
virtual size_t size() const
virtual void rate(double r)
wavearray< double > a(hp.size())
wavearray< double > GetSGQ(double frequency, double Q)
wavearray< double > psd(33)
cout<< "SNR "<< snr<< endl;wavearray< double > f
wavearray< double > GetWNB(double frequency, double bandwidth, double duration, int seed=0, bool mode=0)
wavearray< double > GetRD(double frequency, double tau, double iota, bool polarization=0)