VMC Examples Version 6.6
Loading...
Searching...
No Matches
Hit.cxx
Go to the documentation of this file.
1//------------------------------------------------
2// The Virtual Monte Carlo examples
3// Copyright (C) 2007 - 2016 Ivana Hrivnacova
4// All rights reserved.
5//
6// For the licensing terms see geant4_vmc/LICENSE.
7// Contact: root-vmc@cern.ch
8//-------------------------------------------------
9
10/// \file ExGarfield/src/Hit.cxx
11/// \brief Implementation of the ExGarfield::Hit class
12///
13/// Garfield garfieldpp example adapted to Virtual Monte Carlo.
14///
15/// \date 28/10/2015
16/// \author I. Hrivnacova; IPN, Orsay
17
18#include <Riostream.h>
19
20#include "Hit.h"
21
22using namespace std;
23
24/// \cond CLASSIMP
26 /// \endcond
27
28 namespace VMC
29{
30 namespace ExGarfield
31 {
32
33 //_____________________________________________________________________________
35 : TObject(),
36 fEdepAbs(0),
37 fEdepGas(0),
38 fTrackLengthAbs(0),
39 fAvalancheSize(0),
40 fGain(0)
41 {
42 /// Default constructor
43 }
44
45 //_____________________________________________________________________________
47 {
48 /// Destructor
49 }
50
51 //_____________________________________________________________________________
52 void Hit::Print(Option_t* /*option*/) const
53 {
54 /// Print hit info
55
56 cout << " Absorber: total energy: " << std::setw(7) << fEdepAbs * 1.0e03
57 << " MeV"
58 << " total track length: " << std::setw(7) << fTrackLengthAbs
59 << " cm" << endl
60 << " Gas: total energy: " << std::setw(7) << fEdepGas * 1.0e06
61 << " keV"
62 << " avalanche size: " << std::setw(7) << fAvalancheSize
63 << " gain: " << std::setw(7) << fGain << endl;
64 }
65
66 //_____________________________________________________________________________
68 {
69 /// Reset accounted values.
70
71 fEdepAbs = 0.;
72 fEdepGas = 0.;
73 fTrackLengthAbs = 0.;
74 fAvalancheSize = 0.;
75 fGain = 0.;
76 }
77
78 } // namespace ExGarfield
79}
The calorimeter hit.
Definition Hit.h:37
Double_t fGain
Gain.
Definition Hit.h:83
Double_t fTrackLengthAbs
Track length in the absorber.
Definition Hit.h:81
Double_t fEdepAbs
Energy deposit in the absorber.
Definition Hit.h:79
virtual void Print(Option_t *option="") const
Definition Hit.cxx:52
Double_t fEdepGas
Energy deposit in the gas.
Definition Hit.h:80
virtual ~Hit()
Definition Hit.cxx:46
Double_t fAvalancheSize
Avalanche size in the gas.
Definition Hit.h:82