This question must have been asked before but I couldn't find it anywhere.
Defining a mapping from two sets to the set of their Cartesian product seems seems pretty easy, unless I'm completely wrong:
$f(A,B) = \{(a,b) \mid a∈A, b∈B\}$
My question is - how do I define the inverse function? I want to define a function that takes a set of ordered pairs and returns the original sets. The process is clear to me, but I find it hard writing it mathematically.
Also what is a little unclear to me is the idea of inverting a pairing function: it takes two parameters and return one, so when you invert it you have two solutions from one parameter. How is it not a problem?
Hope I was clear, thanks in advance.