Logo coherent WaveBurst  
Library Reference Guide
Logo
DrawInspiralUserDet.C
Go to the documentation of this file.
1 {
2  //
3  // Draw Inspiral Waveform with the mdc class (for user defined detectors)
4  // Author : Gabriele Vedovato
5 
6  #include <vector>
7 
8  // --------------------------------------------------------
9  // define network
10  // --------------------------------------------------------
11 
12  int nIFO = 4;
13  char ifo[NIFO_MAX][4];
14  strcpy(ifo[0],"L1");
15  strcpy(ifo[1],""); // if empty then select user detectors
16  strcpy(ifo[2],""); // if empty then select user detectors
17  strcpy(ifo[3],"V1");
18 
20  {"L1", 30.5629, -90.7742, 0.0, 0, ( +90-197.716), 0, ( -197.716)},
21 
22  {"Y2", 46.4551, -119.408, 0.0, 0, ( +90-125.999), 0, ( +45-125.999)}, // H2 LCI
23  {"Y3", 46.4551, -119.408, 0.0, 0, ( +45-125.999), 0, ( -125.999)}, // H3 LCI
24 
25  {"V1", 43.6314, 10.5045, 0.0, 0, ( +90-70.5675), 0, ( -70.5675)},
26  };
27 
28 
31  for(int i=0; i<nIFO; i++) {
32  if(strlen(ifo[i])>0) pD[i] = new detector(ifo[i]); // built in detector
33  else pD[i] = new detector(detParms[i]); // user define detector
34  }
35  for(int i=0; i<nIFO; i++) NET.add(pD[i]);
36 
37  bool ifoBuiltin=true;
38  for(int n=0; n<nIFO; n++) {
39  if(pD[n]->isBuiltin()) {
40  cout << pD[n]->Name << " -> Builtin " << endl;
41  } else {
42  cout << pD[n]->Name << " -> User Defined " << endl;
43  }
44  }
45 
46 
47  CWB::mdc MDC(&NET);
48 
49  // ---------------------------------
50  // set inspiral parms
51  // ---------------------------------
52 
54 // inspOptions = "--gps-start-time 968650000 --gps-end-time 968660000 --time-step 60 --time-interval 5 ";
55  inspOptions = "--time-step 40 --time-interval 5 ";
56  inspOptions+= "--l-distr random ";
57 // inspOptions+= "--l-distr fixed --longitude 30 --latitude 76 ";
58  inspOptions+= "--d-distr uniform --m-distr totalMassRatio --i-distr uniform ";
59  inspOptions+= "--f-lower 10.000000 ";
60  inspOptions+= "--min-mass1 25.000000 --min-mass2 25.000000 --max-mass1 25.000000 --max-mass2 25.000000 ";
61  inspOptions+= "--min-mtotal 50.000000 --max-mtotal 50.000000 --min-mratio 1.000000 --max-mratio 1.000000 ";
62  inspOptions+= "--min-distance 5000.000000 --max-distance 5000.000000 ";
63 // inspOptions+= "--output GHLTV-UNIFORM_v1-968650000-10000.xml ";
64  inspOptions+= "--waveform EOBNRv2HMpseudoFourPN --disable-spin ";
65  inspOptions+= "--taper-injection start --seed 123456789";
66 
67  MDC.SetInspiral("TEST",inspOptions);
68 
69  MDC.SetInjLength(10);
70  int id=0;
71  MDC.Draw("Y2",968650200,968650300,id,MDC_TIME);
72  //MDC.Draw("Y2",968650000,968650100,id,MDC_TIME);
73  //MDC.Draw("L1",968650000,968650100,id,MDC_TIME);
74  //MDC.Draw("L1",968650000,968650100,id,MDC_FFT);
75  //MDC.Draw("L1",968650000,968650100,id,MDC_TF);
76 }
Definition: mdc.hh:202
watplot * Draw(TString name, int id=0, TString polarization="hp", MDC_DRAW type=MDC_TIME, TString options="ALP", Color_t color=kBlack)
Definition: mdc.cc:2317
size_t add(detector *)
param: detector structure return number of detectors in the network
Definition: network.cc:2559
int n
Definition: cwb_net.C:28
TString("c")
void SetInjLength(double inj_length=MDC_INJ_LENGTH)
Definition: mdc.hh:304
CWB::mdc * MDC
char ifo[NIFO_MAX][4]
strcpy(ifo[0],"L1")
i drho i
#define nIFO
detector * pD[NIFO_MAX]
network NET
Definition: mdc.hh:248
const int NIFO_MAX
Definition: wat.hh:22
char Name[16]
Definition: detector.hh:327
detectorParams detParms[4]
TString inspOptions