#include "LArUtil-TypeDef.hh"
#include <iostream>
#include <TTree.h>
#include <TFile.h>
#include <TSystem.h>
Go to the source code of this file.
Functions | |
int | main (int argc, char **argv) |
int main | ( | int | argc, | |
char ** | argv | |||
) |
< in ns
< in # of clock ticks
< conversion factor for # of ionization electrons to 1 ADC count
< number of clock ticks per event
< number of clock ticks per readout window
< time offsets to convert spacepoint
< coordinates to hit times on each
< view
< Parameters for x<-->ticks
Definition at line 11 of file gen_tree_DetectorProperties.cc.
00011 { 00012 00013 gSystem->Load("libBase"); 00014 TFile *fout = TFile::Open("tree_DetectorProperties.root","RECREATE"); 00015 00016 TTree* tree = new TTree("DetectorProperties",""); 00017 00018 Double_t fSamplingRate; 00019 Int_t fTriggerOffset; 00020 Double_t fElectronsToADC; 00021 UInt_t fNumberTimeSamples; 00022 UInt_t fReadOutWindowSize; 00023 Double_t fTimeOffsetU; 00024 Double_t fTimeOffsetV; 00025 Double_t fTimeOffsetZ; 00026 00027 tree->Branch("fSamplingRate",&fSamplingRate,"fSamplingRate/D"); 00028 tree->Branch("fTriggerOffset",&fTriggerOffset,"fTriggerOffset/I"); 00029 tree->Branch("fElectronsToADC",&fElectronsToADC,"fElectronsToADC/D"); 00030 tree->Branch("fNumberTimeSamples",&fNumberTimeSamples,"fNumberTimeSamples/i"); 00031 tree->Branch("fReadOutWindowSize",&fReadOutWindowSize,"fReadOutWindowSize/i"); 00032 tree->Branch("fTimeOffsetU",&fTimeOffsetU,"fTimeOffsetU/D"); 00033 tree->Branch("fTimeOffsetV",&fTimeOffsetV,"fTimeOffsetV/D"); 00034 tree->Branch("fTimeOffsetZ",&fTimeOffsetZ,"fTimeOffsetZ/D"); 00035 00036 Double_t fXTicksCoefficient; 00037 std::vector<Double_t> fXTicksOffsets; 00038 00039 tree->Branch("fXTicksCoefficient",&fXTicksCoefficient,"fXTicksCoefficient/D"); 00040 tree->Branch("fXTicksOffsets","std::vector<Double_t>",&fXTicksOffsets); 00041 00042 tree->Fill(); 00043 tree->Write(); 00044 fout->Close(); 00045 00046 return 0; 00047 }