BOSS 7.0.8
BESIII Offline Software System
Loading...
Searching...
No Matches
WidgetGenerator.h
Go to the documentation of this file.
1//********************************************************************************
2// This file is part of the Widget, a package for performing dE/dx calibration.
3//
4// Author: Jake Bennett
5// Date: July 8, 2015
6//
7// WidgetGenerator is a class designed to generate or modify a sample for use
8// in the WidgetPrep class. If a pre-existing sample is provided, it is possible
9// to replace the dE/dx information with a fake distribution.
10//
11// For additional details, see the Widget document.
12//
13//********************************************************************************
14#ifndef WIDGETGENERATOR_H
15#define WIDGETGENERATOR_H
16
17#include <string>
18#include <iostream>
19#include <cmath>
20
21#include "TFile.h"
22#include "TTree.h"
23#include "TH1F.h"
24#include "TH2F.h"
25#include "TString.h"
26#include "TRandom.h"
27#include "TMath.h"
28
31
33
35
36 public:
37
39 WidgetGenerator( int nevents, double upperbg, double lowerbg );
40 virtual ~WidgetGenerator() {};
41
42 // generate a sample of fake tracks
43 void generateEvents( TString filename, double genmass );
44
45 // replace the dE/dx measurements for a sample with a fake distribution
46 void simulateDedx( TString infilename, TString filename, double genmass );
47
48 // take the hit level information and replicate the truncation
49 void simulateReconstruction( TString infilename, TString outfilename );
50
51 private:
52
53 int m_nevents; // the number of events stored in the vectors below
54
55 double m_upperbg; // upper bound on beta-gamma
56 double m_lowerbg; // lower bound on beta-gamma
57
58};
59#endif
void simulateDedx(TString infilename, TString filename, double genmass)
void simulateReconstruction(TString infilename, TString outfilename)
void generateEvents(TString filename, double genmass)
virtual ~WidgetGenerator()