Possible results of randomized oracle programs #
A result of a program with private coins is possible when some private samples and some replies
to its external queries lead to it: ProbOracleComp.support is the set of results at the leaves
of the program's tree of calls. Every stateful execution returns only possible results
(mem_support_of_mem). When every reply type is nonempty, every possible result is returned by
some stateful execution (mem_support_iff_exists): an oracle that answers its first call with a
chosen reply realizes each path. Invariants of adaptive loops quantify over possible results, so
they remain valid for every shared oracle and every reply length.
Main definitions #
Cslib.ProbOracleComp.support: the results at the leaves of the program's tree of calls.
Main results #
Cslib.ProbOracleComp.mem_support_bind_iff: a possible result of a sequence is a possible result of a continuation at a possible intermediate result.Cslib.ProbOracleComp.support_sample: private samples range over the closed program's support.Cslib.ProbOracleComp.mem_support_iff_exists: with nonempty reply types, the possible results are the results of stateful executions.Cslib.ProbOracleComp.iterate_invariant: an invariant preserved by every possible step holds for every possible result of a bounded loop.
References #
Generalizes the supported loop invariants of Computability/Probabilistic/Adaptive.lean on the
cslib crypto branch at 5ff69ca93402e7c947208dc56396d6d86203ccd8 to programs with external
calls, for the loop rules adapted from Christian Reitwiessner's Combinators/IterateWhile
(crei:crei/tidy-universal @7f7c0696).
The results of program for some private samples and some replies to its external queries:
the results at the leaves of its tree of calls.
Instances For
A possible result of a sequence is a possible result of a continuation at a possible intermediate result.
A possible result of a sequence comes from a possible first result.
A possible mapped result is the image of a possible result.
A result supported by one stateful execution is possible.
When every reply type is nonempty, the possible results of a program are exactly the results of its stateful executions.
An invariant indexed by the number of completed steps holds for every possible result of a bounded loop when every possible step preserves it.