Brian Hempel
08/26/2019, 6:39 PMSo when it crosses over the previous function, we must have a strategy for deciding which paths it travels without relying on history.Probably impossible: unless you want to have a lot of fun doing it “wrong” on purpose! Consider the simple “plus” operator: given the output of a sum, how do “undo” the sum into its two input summands? There’s an infinite number of possibilities. Consequently, for example, in Perera et al.‘s “Functional Programs that Explain Their Work” (ICFP 2012, excerpted in screenshot), they record the original operands so you can undo the computation. Their goal is to rewind the computation in order to rebuild a minimal program required to produce the result, but the challenge is the same. (Their overall strategy is to use computation traces recorded during execution, the _T_‘s in the screenshot.)
Brian Hempel
08/26/2019, 7:13 PM