I'd like a design a circuit that, given a random bit with probability $p$ to be zero, it outputs a random bit with probability $\sqrt{p}$ to be zero. Actually, I am rather looking for $\sqrt{p(1-p)}$, in case it makes things easier.
Let's assume that we have an unlimited but finite stream of independent random bits and all the common logic gates (AND, OR, NOT, XOR...).
If an exact solution wouldn't be possible in a finite setting. I would also be happy with an approximation, preferably one that can be arbitrarily expanded to reduce the error.
I have already looked into a Taylor expansion around $p=1/2$, and it is a good option. The second degree expansion of $\sqrt{p(1-p)}$ is $\frac{1}{2} - (p - \frac{1}{2})^2 + O((p - \frac{1}{2}))^4$ which goes to $\frac{3}{4} + p(1-p)$ which is nice and easy to implement.
I am here to see if there is a better solution.
This question is highly related to the following question, but the answer is not general enough to satisfy my needs.
Understanding what $\sqrt{p}$ means for an event of probability $p$
Could you elaborate on your comment about using the fact that the terms are non-negative. What do you have in mind? A more complex algorithm may also work if it's not too complex.
– Oersted Dec 28 '17 at 14:38