I don't really know how to phrase this question, so I'll just mention the idea. This is partially reminiscent (at least in spirit to white box crypto): Can one derive arithmetic operations from a number? Is there a formula to do that?
So, the simplest example would be:
a = 4 ops = get_operations(a) print(ops) /* output: * * b = 2 * c = 2 * return b + c */
The idea is to simply have a way to "derive" a mathematical operation from a value. There are obviously more than "one" operation that could be derived from the above example. The system does not have to be complete.
The flow of such a "derivation" algorithm in my head is as such:
- Get input (k)
- Randomly choose an arithmetic operand (P) where
y = k (P) xand store the operand (P)
- Pick a random number (x) and store its value
- Solve for (y) and store its value
- Now, we have a combination of (P), (x), and (y) that, when solved, would yield the correct input (k).
My question is this: did someone research this and make a way better algorithm that what I could muster up here?