#include <ConstantStepOdeSolver.h>
Public Member Functions | |
ConstantStepOdeSolver () | |
ConstantStepOdeSolver (const AbsODERHS &rhs) | |
ConstantStepOdeSolver (const ConstantStepOdeSolver &r) | |
double | getCoordinate (const unsigned which, const unsigned idx) const |
double | getIntegrated (unsigned which, unsigned idx) const |
double | getPeakTime (unsigned which) const |
const AbsODERHS * | getRHS () const |
AbsODERHS * | getRHS () |
double | getTime (const unsigned idx) const |
double | interpolateCoordinate (unsigned which, double t, bool cubic=false) const |
double | interpolateIntegrated (unsigned which, double t, bool cubic=false) const |
double | lastDeltaT () const |
unsigned | lastDim () const |
double | lastMaxT () const |
unsigned | lastRunLength () const |
virtual const char * | methodName () const =0 |
ConstantStepOdeSolver & | operator= (const ConstantStepOdeSolver &r) |
void | run (const double *initialConditions, unsigned lenConditions, double dt, unsigned nSteps) |
void | setHistory (double dt, const double *data, unsigned dim, unsigned runLen) |
void | setRHS (const AbsODERHS &rhs) |
void | truncateCoordinate (unsigned which, double minValue, double maxValue) |
void | writeHistory (std::ostream &os, double dt, bool cubic=false) const |
void | writeIntegrated (std::ostream &os, unsigned which, double dt, bool cubic=false) const |
virtual | ~ConstantStepOdeSolver () |
Protected Attributes | |
AbsODERHS * | rhs_ |
Private Member Functions | |
void | integrateCoordinate (const unsigned which) |
virtual void | step (double t, double dt, const double *x, unsigned lenX, double *coordIncrement) const =0 |
Private Attributes | |
std::vector< double > | chargeBuffer_ |
unsigned | dim_ |
double | dt_ |
std::vector< double > | historyBuffer_ |
unsigned | lastIntegrated_ |
unsigned | runLen_ |
Definition at line 14 of file ConstantStepOdeSolver.h.
|
inline |
Definition at line 17 of file ConstantStepOdeSolver.h.
Referenced by ConstantStepOdeSolver().
|
inline |
Definition at line 20 of file ConstantStepOdeSolver.h.
References AbsODERHS::clone(), ConstantStepOdeSolver(), operator=(), alignCSCRings::r, and rhs_.
ConstantStepOdeSolver::ConstantStepOdeSolver | ( | const ConstantStepOdeSolver & | r | ) |
Definition at line 145 of file ConstantStepOdeSolver.cc.
References AbsODERHS::clone(), and rhs_.
|
inlinevirtual |
|
inline |
Definition at line 54 of file ConstantStepOdeSolver.h.
References data, dim_, dt, Exception, getIntegrated(), getPeakTime(), historyBuffer_, training_settings::idx, interpolateCoordinate(), interpolateIntegrated(), RecoTauDiscriminantConfiguration::maxValue, methodName(), RecoTauDiscriminantConfiguration::minValue, run(), runLen_, setHistory(), protons_cff::t, truncateCoordinate(), eostools::which(), writeHistory(), and writeIntegrated().
Referenced by writeHistory().
double ConstantStepOdeSolver::getIntegrated | ( | unsigned | which, |
unsigned | idx | ||
) | const |
Definition at line 39 of file ConstantStepOdeSolver.cc.
References chargeBuffer_, dim_, Exception, training_settings::idx, lastIntegrated_, and runLen_.
Referenced by getCoordinate(), and writeIntegrated().
double ConstantStepOdeSolver::getPeakTime | ( | unsigned | which | ) | const |
Definition at line 11 of file ConstantStepOdeSolver.cc.
References dim_, dt_, Exception, historyBuffer_, mps_fire::i, checklumidiff::l, alignCSCRings::r, runLen_, mitigatedMETSequence_cff::U, and eostools::which().
Referenced by getCoordinate(), and QIE8Simulator::preampPeakTime().
|
inline |
Definition at line 38 of file ConstantStepOdeSolver.h.
References rhs_.
Referenced by QIE8Simulator::getRHS(), and QIE8Simulator::modifiableRHS().
|
inline |
|
inline |
Definition at line 47 of file ConstantStepOdeSolver.h.
References dt_, Exception, and runLen_.
Referenced by writeHistory(), and writeIntegrated().
|
private |
Definition at line 49 of file ConstantStepOdeSolver.cc.
References chargeBuffer_, dim_, dt_, Exception, historyBuffer_, mps_fire::i, lastIntegrated_, runLen_, mitigatedMETSequence_cff::U, and eostools::which().
double ConstantStepOdeSolver::interpolateCoordinate | ( | unsigned | which, |
double | t, | ||
bool | cubic = false |
||
) | const |
Definition at line 195 of file ConstantStepOdeSolver.cc.
References runEdmFileComparison::base, dim_, dt_, Exception, historyBuffer_, interpolateLinear(), runLen_, mitigatedMETSequence_cff::U, eostools::which(), and x.
Referenced by QIE8Simulator::controlOutput(), QIE8Simulator::getCharge(), getCoordinate(), QIE8Simulator::preampOutput(), and writeHistory().
double ConstantStepOdeSolver::interpolateIntegrated | ( | unsigned | which, |
double | t, | ||
bool | cubic = false |
||
) | const |
Definition at line 241 of file ConstantStepOdeSolver.cc.
References runEdmFileComparison::base, chargeBuffer_, dim_, dt_, Exception, interpolateLinear(), lastIntegrated_, runLen_, mitigatedMETSequence_cff::U, and x.
Referenced by QIE8Simulator::getCharge(), getCoordinate(), and writeIntegrated().
|
inline |
|
inline |
|
inline |
Definition at line 45 of file ConstantStepOdeSolver.h.
References dt_, runLen_, and mitigatedMETSequence_cff::U.
Referenced by QIE8Simulator::lastStopTime(), QIE8Simulator::run(), writeHistory(), and writeIntegrated().
|
inline |
|
pure virtual |
Implemented in RK4, RK2, and EulerOdeSolver.
Referenced by getCoordinate(), writeHistory(), and writeIntegrated().
ConstantStepOdeSolver & ConstantStepOdeSolver::operator= | ( | const ConstantStepOdeSolver & | r | ) |
Definition at line 158 of file ConstantStepOdeSolver.cc.
References chargeBuffer_, AbsODERHS::clone(), dim_, dt_, historyBuffer_, lastIntegrated_, rhs_, and runLen_.
Referenced by ConstantStepOdeSolver().
void ConstantStepOdeSolver::run | ( | const double * | initialConditions, |
unsigned | lenConditions, | ||
double | dt, | ||
unsigned | nSteps | ||
) |
Definition at line 312 of file ConstantStepOdeSolver.cc.
References dim_, dt, dt_, Exception, historyBuffer_, mps_fire::i, lastIntegrated_, GetRecoTauVFromDQM_MC_cff::next, rhs_, runLen_, step(), protons_cff::t, and mitigatedMETSequence_cff::U.
Referenced by DTWorkflow.DTWorkflow::all(), Types.EventID::cppID(), Types.LuminosityBlockID::cppID(), o2olib.O2OTool::execute(), getCoordinate(), and QIE8Simulator::run().
void ConstantStepOdeSolver::setHistory | ( | double | dt, |
const double * | data, | ||
unsigned | dim, | ||
unsigned | runLen | ||
) |
Definition at line 289 of file ConstantStepOdeSolver.cc.
References dim_, dt, dt_, Exception, historyBuffer_, mps_fire::i, lastIntegrated_, runLen_, and mitigatedMETSequence_cff::U.
Referenced by getCoordinate(), and QIE8Simulator::run().
|
inline |
Definition at line 33 of file ConstantStepOdeSolver.h.
References AbsODERHS::clone(), and rhs_.
Referenced by QIE8Simulator::setRHS().
|
privatepure virtual |
Implemented in RK4, RK2, and EulerOdeSolver.
Referenced by EulerOdeSolver::methodName(), RK2::methodName(), RK4::methodName(), and run().
void ConstantStepOdeSolver::truncateCoordinate | ( | unsigned | which, |
double | minValue, | ||
double | maxValue | ||
) |
Definition at line 176 of file ConstantStepOdeSolver.cc.
References dim_, Exception, historyBuffer_, mps_fire::i, RecoTauDiscriminantConfiguration::maxValue, RecoTauDiscriminantConfiguration::minValue, runLen_, and eostools::which().
Referenced by getCoordinate(), and QIE8Simulator::run().
void ConstantStepOdeSolver::writeHistory | ( | std::ostream & | os, |
double | dt, | ||
bool | cubic = false |
||
) | const |
Definition at line 84 of file ConstantStepOdeSolver.cc.
References dim_, dt, dt_, getCoordinate(), getTime(), mps_fire::i, interpolateCoordinate(), lastMaxT(), methodName(), runLen_, protons_cff::t, tmax, and eostools::which().
Referenced by getCoordinate(), and operator<<().
void ConstantStepOdeSolver::writeIntegrated | ( | std::ostream & | os, |
unsigned | which, | ||
double | dt, | ||
bool | cubic = false |
||
) | const |
Definition at line 118 of file ConstantStepOdeSolver.cc.
References dim_, dt, dt_, getIntegrated(), getTime(), mps_fire::i, interpolateIntegrated(), lastMaxT(), methodName(), runLen_, protons_cff::t, and tmax.
Referenced by getCoordinate().
|
private |
Definition at line 118 of file ConstantStepOdeSolver.h.
Referenced by getIntegrated(), integrateCoordinate(), interpolateIntegrated(), and operator=().
|
private |
Definition at line 113 of file ConstantStepOdeSolver.h.
Referenced by getCoordinate(), getIntegrated(), getPeakTime(), integrateCoordinate(), interpolateCoordinate(), interpolateIntegrated(), lastDim(), operator=(), run(), setHistory(), truncateCoordinate(), writeHistory(), and writeIntegrated().
|
private |
Definition at line 112 of file ConstantStepOdeSolver.h.
Referenced by getPeakTime(), getTime(), integrateCoordinate(), interpolateCoordinate(), interpolateIntegrated(), lastDeltaT(), lastMaxT(), operator=(), run(), setHistory(), writeHistory(), and writeIntegrated().
|
private |
Definition at line 117 of file ConstantStepOdeSolver.h.
Referenced by getCoordinate(), getPeakTime(), integrateCoordinate(), interpolateCoordinate(), operator=(), run(), setHistory(), and truncateCoordinate().
|
private |
Definition at line 115 of file ConstantStepOdeSolver.h.
Referenced by getIntegrated(), integrateCoordinate(), interpolateIntegrated(), operator=(), run(), and setHistory().
|
protected |
Definition at line 100 of file ConstantStepOdeSolver.h.
Referenced by ConstantStepOdeSolver(), getRHS(), operator=(), run(), setRHS(), EulerOdeSolver::step(), RK2::step(), RK4::step(), and ~ConstantStepOdeSolver().
|
private |
Definition at line 114 of file ConstantStepOdeSolver.h.
Referenced by getCoordinate(), getIntegrated(), getPeakTime(), getTime(), integrateCoordinate(), interpolateCoordinate(), interpolateIntegrated(), lastMaxT(), lastRunLength(), operator=(), run(), setHistory(), truncateCoordinate(), writeHistory(), and writeIntegrated().