#include <ZDCWaveformFermiExp.h>
|
| | ZDCWaveformFermiExp ()=delete |
| | ZDCWaveformFermiExp (const std::string &tag, double initialTauRise, double initialTauFall) |
| | ZDCWaveformFermiExp (const ZDCWaveformFermiExp &instance) |
| ZDCWaveformBase * | Duplicate () |
| double | evaluate (double time) const |
| double | evaluateRoot (double *x, double *p) |
| double | evaluateRootNoTF1Par (double *x, double *p) |
| double | operator() (double *x, double *p) |
| const std::string & | getTag () const |
| std::string | getNameTag () const |
| const std::string | getName () const |
| double | getTauRise () const |
| double | getTauFall () const |
| unsigned int | getNumAddtlShapeValues () const |
| double | getAddtlShapeValue (const std::string &name) const |
| double | getAddtlShapeValue (unsigned int index) const |
| void | setAddtlShapeValue (std::string name, double value) |
| void | setAddtlShapeValue (unsigned int index, double value) |
| void | setTaus (double tauRise, double tauFall) |
| void | restoreInitial () |
| TF1 * | makeWaveformTF1 (ZDCWaveformBase *ptr, double xmin, double xmax, bool useTF1Params=true) |
| TF1 * | makeWaveformTF1 (ZDCWaveformBase &instance, double xmin, double xmax, bool useTF1Params=true) |
Definition at line 14 of file ZDCWaveformFermiExp.h.
◆ ZDCWaveformFermiExp() [1/3]
| ZDCWaveformFermiExp::ZDCWaveformFermiExp |
( |
| ) |
|
|
delete |
◆ ZDCWaveformFermiExp() [2/3]
| ZDCWaveformFermiExp::ZDCWaveformFermiExp |
( |
const std::string & | tag, |
|
|
double | initialTauRise, |
|
|
double | initialTauFall ) |
|
inline |
◆ ZDCWaveformFermiExp() [3/3]
◆ doEvaluate()
| double ZDCWaveformFermiExp::doEvaluate |
( |
double | time | ) |
const |
|
overrideprotectedvirtual |
Implements ZDCWaveformBase.
Reimplemented in ZDCWaveformFermiExpTail.
Definition at line 7 of file ZDCWaveformFermiExp.cxx.
8{
11 double shift = -tau1 * std::log(tau2 / tau1 - 1.0);
12 double timeShift =
time - shift;
13
14 double expTerm = std::exp(-timeShift / tau2);
15 double fermiTerm = 1. / (1. + std::exp(-timeShift / tau1));
16
17 return expTerm * fermiTerm;
18}
time(flags, cells_name, *args, **kw)
◆ Duplicate()
◆ evaluate()
| double ZDCWaveformBase::evaluate |
( |
double | time | ) |
const |
|
inlineinherited |
◆ evaluateRoot()
| double ZDCWaveformBase::evaluateRoot |
( |
double * | x, |
|
|
double * | p ) |
|
inlineinherited |
◆ evaluateRootNoTF1Par()
| double ZDCWaveformBase::evaluateRootNoTF1Par |
( |
double * | x, |
|
|
double * | p ) |
|
inlineinherited |
◆ getAddtlShapeValue() [1/2]
| double ZDCWaveformBase::getAddtlShapeValue |
( |
const std::string & | name | ) |
const |
|
inlineinherited |
◆ getAddtlShapeValue() [2/2]
| double ZDCWaveformBase::getAddtlShapeValue |
( |
unsigned int | index | ) |
const |
|
inlineinherited |
◆ getName()
| const std::string ZDCWaveformBase::getName |
( |
| ) |
const |
|
inlineinherited |
◆ getNameTag()
| std::string ZDCWaveformBase::getNameTag |
( |
| ) |
const |
|
inlineinherited |
◆ getNumAddtlShapeValues()
| unsigned int ZDCWaveformBase::getNumAddtlShapeValues |
( |
| ) |
const |
|
inlineinherited |
◆ getTag()
| const std::string & ZDCWaveformBase::getTag |
( |
| ) |
const |
|
inlineinherited |
◆ getTauFall()
| double ZDCWaveformBase::getTauFall |
( |
| ) |
const |
|
inlineinherited |
◆ getTauRise()
| double ZDCWaveformBase::getTauRise |
( |
| ) |
const |
|
inlineinherited |
◆ makeWaveformTF1() [1/2]
| TF1 * ZDCWaveformBase::makeWaveformTF1 |
( |
ZDCWaveformBase & | instance, |
|
|
double | xmin, |
|
|
double | xmax, |
|
|
bool | useTF1Params = true ) |
|
inlineinherited |
◆ makeWaveformTF1() [2/2]
| TF1 * ZDCWaveformBase::makeWaveformTF1 |
( |
ZDCWaveformBase * | ptr, |
|
|
double | xmin, |
|
|
double | xmax, |
|
|
bool | useTF1Params = true ) |
|
inlineinherited |
Definition at line 133 of file ZDCWaveform.h.
134{
135 std::string
name =
ptr->getNameTag() +
"_TF1";
136
137 TF1* newTF1 = 0;
138
139 if (useTF1Params) {
140 unsigned int numPar = 2 +
ptr->getNumAddtlShapeValues();
141
143 "ZDCWaveformBase", "evaluateRoot");
144
145 newTF1->SetParameter(0,
ptr->getTauRise());
146 newTF1->SetParameter(1,
ptr->getTauFall());
147
148 if (numPar > 2) {
149 for (unsigned int idxpar = 2; idxpar < numPar; idxpar++) {
150 newTF1->SetParameter(idxpar,
ptr->getAddtlShapeValue(idxpar - 2));
151 }
152 }
153 }
154 else {
156 "ZDCWaveformBase", "evaluateRoot");
157 }
158
159 newTF1->SetNpx(1000);
160 return newTF1;
161}
◆ name()
| virtual std::string ZDCWaveformFermiExp::name |
( |
| ) |
const |
|
inlineoverrideprotectedvirtual |
◆ operator()()
| double ZDCWaveformBase::operator() |
( |
double * | x, |
|
|
double * | p ) |
|
inlineinherited |
◆ restoreInitial()
| void ZDCWaveformBase::restoreInitial |
( |
| ) |
|
|
inherited |
◆ setAddtlShapeParameters()
| void ZDCWaveformBase::setAddtlShapeParameters |
( |
const std::vector< std::string > & | addtlShapeNames, |
|
|
const std::vector< double > & | addtlShapeValues ) |
|
protectedinherited |
Definition at line 32 of file ZDCWaveform.cxx.
34{
35
36
38 if (
m_numAddtlShapePars != addtlShapeValues.size())
throw std::runtime_error(
"ZDCWaveformBase::setAddtlShapeParameters; Shape name and value size mismatch");
39
41
42
43
44 for (unsigned int param = 0; param < addtlShapeNames.size(); param++) {
46 }
47
48
49
52}
◆ setAddtlShapeValue() [1/2]
| void ZDCWaveformBase::setAddtlShapeValue |
( |
std::string | name, |
|
|
double | value ) |
|
inherited |
◆ setAddtlShapeValue() [2/2]
| void ZDCWaveformBase::setAddtlShapeValue |
( |
unsigned int | index, |
|
|
double | value ) |
|
inlineinherited |
◆ setAddtlShapeValues() [1/2]
| void ZDCWaveformBase::setAddtlShapeValues |
( |
const double * | values | ) |
|
|
protectedinherited |
◆ setAddtlShapeValues() [2/2]
| void ZDCWaveformBase::setAddtlShapeValues |
( |
const std::vector< double > & | values | ) |
|
|
inlineprotectedinherited |
◆ setTaus()
| void ZDCWaveformBase::setTaus |
( |
double | tauRise, |
|
|
double | tauFall ) |
|
inlineinherited |
◆ m_addtlShapeInitialValues
| std::vector<double> ZDCWaveformBase::m_addtlShapeInitialValues |
|
privateinherited |
◆ m_addtlShapeNames
| std::map<std::string, unsigned int> ZDCWaveformBase::m_addtlShapeNames |
|
privateinherited |
◆ m_addtlShapeValues
| std::vector<double> ZDCWaveformBase::m_addtlShapeValues |
|
protectedinherited |
◆ m_initialTauFall
| double ZDCWaveformBase::m_initialTauFall |
|
privateinherited |
◆ m_initialTauRise
| double ZDCWaveformBase::m_initialTauRise |
|
privateinherited |
◆ m_numAddtlShapePars
| unsigned int ZDCWaveformBase::m_numAddtlShapePars |
|
privateinherited |
◆ m_tag
| std::string ZDCWaveformBase::m_tag |
|
privateinherited |
◆ m_tauFall
| double ZDCWaveformBase::m_tauFall |
|
protectedinherited |
◆ m_tauRise
| double ZDCWaveformBase::m_tauRise |
|
protectedinherited |
The documentation for this class was generated from the following files: