Is there some probability distribution that can be implemented/defined/etc. without irrational numbers such that it returns 1 an irrational proportion $P$ of the time and 0 the rest of the time, for any irrational probability $P$? If not, for what irrational $P$ can this be done? I am specifically trying for quadratic irrationals.
When I assume I have some random infinite sequence of bits to use, I want $\Bbb E(X) = \frac 12 \Bbb E(X_0) + \frac 12\Bbb E(X_1)$, where $X_0, X_1$ are results after getting 0 or 1 as the first bit respectively, but this prevents getting irrational from rational it seems, since the two expected values on the right must be irrational, but can't without starting irrationals. This would imply that it needs to be a more complicated process.
I want this to be a distribution that a computer program could in theory run, where irrational numbers cannot occur but I still want an irrational probability.
Edit: In principle I would like to have no approximate arithmetic, since if I could I could just generate a random floating point number between 0 and 1 and check if it's less than the given P (represented inexactly). I am fine with programs that have an indefinitely long running time as long as they are fast in the average case.
Edit: I really want a way to do this for any quadratic irrational, but if it isn't possible I would want to know that it is impossible instead.