32 return std::get<1>(
a) < std::get<1>(b);
40 std::advance(
it_m, posIterator);
54 "iterator is at end of list of configurations");
65 "iterator is at begin of list of configurations");
75 while (std::get<1>(*it) < front &&
80 double zstop = std::get<1>(*it);
81 if (zstop < front)
return;
83 std::get<1>(*it) = front;
87 std::swap(zstop, std::get<1>(*it));
93 while (std::get<1>(*it) > back &&
98 double zstop = std::get<1>(*it);
99 if (zstop > back)
return;
101 std::get<1>(*it) = back;
105 std::swap(zstop, std::get<1>(*it));
112 "iterator is at end of list of configurations");
115 return std::get<0>(*
it_m);
121 "iterator is at end of list of configurations");
124 return std::get<1>(*
it_m);
130 "iterator is at end of list of configurations");
133 return std::get<2>(*
it_m);
137 unsigned long long maxSteps = 0;
139 maxSteps += std::get<2>(config);
147 unsigned long long totalNumSteps = 0;
150 const double &dt = std::get<0>(config);
151 const unsigned long &numSteps = std::get<2>(config);
153 if (minTimeStep > dt) {
154 totalNumSteps =
std::ceil(totalNumSteps * minTimeStep / dt);
158 totalNumSteps +=
std::ceil(numSteps * dt / minTimeStep);
161 return totalNumSteps;
167 if (minTimeStep > std::get<0>(config)) {
168 minTimeStep = std::get<0>(config);
180 out << std::scientific <<
" "
181 << std::setw(20) <<
"dt [ns] "
182 << std::setw(20) <<
"zStop [m] "
183 << std::setw(20) <<
"num Steps [1]"
195 out << std::setw(20) << std::get<0>(*it)
196 << std::setw(20) << std::get<1>(*it)
197 << std::setw(20) << std::get<2>(*it)
PETE_TUTree< FnCeil, typename T::PETE_Expr_t > ceil(const PETE_Expr< T > &l)
Inform & endl(Inform &inf)
double getMinTimeStep() const
StepSizeConfig & advanceToPos(double spos)
bool reachedStart() const
StepSizeConfig & operator++()
unsigned long long getNumStepsFinestResolution() const
void print(Inform &out) const
container_t::iterator it_m
void shiftZStopRight(double front)
void shiftZStopLeft(double back)
unsigned long getNumSteps() const
unsigned long long getMaxSteps() const
container_t configurations_m
StepSizeConfig & operator--()
std::tuple< double, double, unsigned long > entry_t
void sortAscendingZStop()
ValueRange< double > getPathLengthRange() const
double getFinalZStop() const
void enlargeIfOutside(T value)
The base class for all OPAL exceptions.