Bartender LYSO
Digitizer simulation for the LYSO calorimeter prototype
Loading...
Searching...
No Matches
bartender.cc File Reference

Definition of the main function of Bartender_LYSO. More...

#include <iostream>
#include <vector>
#include <chrono>
#include <TFile.h>
#include <TTree.h>
#include "globals.hh"
#include "configure.hh"
#include "bar.hh"
#include "SiPM.hh"
#include "summary.hh"
Include dependency graph for bartender.cc:

Go to the source code of this file.

Functions

int main (int argc, char **argv)
 Main of the application.
 

Detailed Description

Definition of the main function of Bartender_LYSO.

Definition in file bartender.cc.

Function Documentation

◆ main()

int main ( int argc,
char ** argv )

Main of the application.

It manages the simulation flow. To begin with, it creates instances of the BarLYSO and SiPM classes and invokes Bartender_Configure() and BarLYSO::SetParsDistro() method. Next, it accesses the "lyso" TTree from the Monte Carlo simulation. After initializing all the waveform containers through BarLYSO::InitializeBaselines(), it initiates the core of the simulation. By looping through all events and hit collections in the TTree, it constructs the waveforms by calling BarLYSO::SetFrontWaveforms() and BarLYSO::SetBackWaveform(). Finally, it saves all the data using BarLYSO::SaveBar() and invokes Bartender_Summary().

Definition at line 42 of file bartender.cc.