ATLAS Offline Software
Loading...
Searching...
No Matches
TilePulseShape.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef TILEPULSESIMULATOR_TILEPULSESHAPE_H
6#define TILEPULSESIMULATOR_TILEPULSESHAPE_H
7
9#include "TString.h"
10#include <vector>
11
12class TF1;
13class TGraph;
14class TSpline;
15class IMessageSvc;
16
18 public:
19 TilePulseShape(IMessageSvc* msgSvc, const std::string& name);
20 TilePulseShape(IMessageSvc* msgSvc, const std::string& name, const TString& fileName);
21 TilePulseShape(IMessageSvc* msgSvc, const std::string& name, const std::vector<double>& shapevec);
22 virtual ~TilePulseShape();
23 void loadPulseShape(const TString& fileName);
24 void setPulseShape(const std::vector<double>& shapevec);
25 void setUndershootParameters(double amplitude, double decayTime);
26 double undershootAmplitude() const { return m_undershootAmplitude; }
27 double undershootDecayTime() const { return m_undershootDecayTime; }
28 double effectiveStartTime() const;
29 double effectiveEndTime() const;
30
31 //=== access to the underlying graph
32 TGraph* getGraph(double t0=0., double ped=0., double amp=1.);
33 double eval(double x, bool useSpline=true, bool useUndershoot=false);
34
35 //=== modify the pulseshape
36 void resetDeformation();
37 int scalePulse(double leftSF=1., double rightSF=1.);
38
39 private:
40 TGraph* m_pulseShape{nullptr};
41 TGraph* m_deformedShape{nullptr};
42 TSpline* m_deformedSpline{nullptr};
46};
47
48#endif // TILEPULSESIMULATOR_TILEPULSESHAPE_H
static Double_t t0
#define x
AthMessaging(IMessageSvc *msgSvc, const std::string &name)
Constructor.
double eval(double x, bool useSpline=true, bool useUndershoot=false)
void setPulseShape(const std::vector< double > &shapevec)
TGraph * getGraph(double t0=0., double ped=0., double amp=1.)
double undershootDecayTime() const
virtual ~TilePulseShape()
double m_undershootAmplitude
double effectiveStartTime() const
double m_undershootDecayTime
TGraph * m_pulseShape
TSpline * m_deformedSpline
double effectiveEndTime() const
double undershootAmplitude() const
int scalePulse(double leftSF=1., double rightSF=1.)
void setUndershootParameters(double amplitude, double decayTime)
void loadPulseShape(const TString &fileName)
TGraph * m_deformedShape
TilePulseShape(IMessageSvc *msgSvc, const std::string &name)
bool m_useConfiguredUndershoot