Given a set of many variables $S=\{x_1,x_2, ...., x_i\}$, and any subset $S'$ of $S$, I need a function $f$ which maps $S'$ to a value $x$ and a function $f'$ which maps $x$ back to set $S'$.
I know my question can be solved with Gödel_numbering, but it will consume a lot of space and the computation cost is quite high when the size of $S'$ is big.
Is there any relationship the values in $S$ can satisfy such that we can make function $f$ and $f'$ very easy?
I tried making all values in S to be even, odd or prime and function f as sum. But it clearly does not work.