Expand description
Probing a sequence of trial values until one decides: a step halved until a point stepped off a curve lands where it should, a reach doubled until it brackets a crossing, a point marched on until it passes one, a ray cast in one direction after another until one is clear of every vertex.
What is probed is a free choice — how far to step, how far to reach —
and what the probe finds there is the caller’s to judge. The solver
promises only the sequence: start, then each value next makes of
the one before, at most most of them, each asked once and in order.
It answers None when none decided, never the last value tried.
Enums§
- Probe
- What a probe found at one value of the sequence.
Functions§
- attempts
probeover attempts0, 1, 2, …— at mostmostof them — for a sequenceatmakes itself (thek-th of a set of directions, the next draw of a seeded generator).- halve
probewith a step halved each time:start,start / 2, … — at mostmostof them.- probe
- Asks
atforstartand each valuenextmakes of the one before, at mostmostof them, until one isProbe::FoundorProbe::Stop.nextis asked only for a value that will be probed.atmay keep state of its own (what the probes so far said), since every value is asked once, in order.