73 assert(conf.
tMax >= 0 && conf.
tMax <=1);
87 const auto maxTarget = std::max(target + conf.
tolerance, 0_m);
88 const auto minTarget = std::max(target - conf.
tolerance, 0_m);
90 const auto minTargetSquared =
Square(minTarget);
96 const auto maxTargetSquared =
Square(maxTarget);
102 auto timeLo =
Real{0};
115 const auto dinfo =
Distance(proxyA, timeLoXfA, proxyB, timeLoXfB, distanceConf);
117 stats.sum_dist_iters += dinfo.iterations;
118 stats.max_dist_iters = std::max(stats.max_dist_iters, dinfo.iterations);
136 if (distSquared < minTargetSquared)
142 if (distSquared <= maxTargetSquared)
152 proxyA, timeLoXfA, proxyB, timeLoXfB);
156 auto timeHi = conf.
tMax;
167 if (timeHiMinSep.distance > maxTarget)
170 assert(timeHi == conf.
tMax);
175 stats.sum_finder_iters += pbIter;
182 if (timeHiMinSep.distance >= minTarget)
184 if (timeHi == timeLo)
196 stats.sum_finder_iters += pbIter;
202 timeLoXfA = timeHiXfA;
203 timeLoXfB = timeHiXfB;
210 const auto timeLoEvalDistance =
Evaluate(fcn, timeLoXfA, timeLoXfB,
211 timeHiMinSep.indices);
216 if (timeLoEvalDistance <= maxTarget)
218 if (timeLoEvalDistance < minTarget)
220 stats.sum_finder_iters += pbIter;
224 stats.sum_finder_iters += pbIter;
233 auto s1 = timeLoEvalDistance;
234 auto s2 = timeHiMinSep.distance;
257 stats.sum_finder_iters += pbIter;
258 stats.sum_root_iters += roots;
259 stats.max_root_iters = std::max(stats.max_root_iters, roots);
275 const auto s =
Evaluate(fcn, txfA, txfB, timeHiMinSep.indices);
300 stats.sum_root_iters += roots;
301 stats.max_root_iters = std::max(stats.max_root_iters, roots);
303 stats.sum_finder_iters += pbIter;