Given two finite sets of natural numbers $A$ and $B$, denote the set $\lbrace a+b \mid a \in A \text{ and } b \in B \rbrace$ as $A+B$. What is the best known algorithm of finding a set of natural numbers $R$, such that $R+R=X$ for some finite set of natural numbers $X$?
A brief discussion of this problem is here.
Finding it is a very different question than "the best known algorithm", or the computational complexity of the best algorithm. I don't know much about this, so I'll just state one solution here, which is just the first greedy that comes to mind, in hopes that would help the discussion.
I've tested it with the samples you shared and with some of mine, and it seems to work. This is not efficient at all, but it's a bit unclear if you want the best solution or just one that works.
The pseudo-code is just:
We explore all the possibilities, and if none of them work, then it can't work and we return the empty set. Here it's the solution on Python: