So, I'm trying to use gmp to some calculations I'm doing, and at some point I need to generate a pseudo random number (prn) from a normal distribution.
Since gmp has a uniform random variable, that already helps a lot. However, I'm finding difficult to choose which method I should use generate the normal distribution from a uniform one. In practice, my problem is that gmp only has simple operations, and so for instance I cannot use cos or erf evaluations, since I would have to implement all by miself.
My question is to what extent can I generate prn from a normal distribution on gmp, and, if it is very difficult, if there is any arbitrary precision lib which already has normal distribution implemented.
As two examples of methods that do not work (retrieved from this question):
Ziggurat algorithm uses evaluation of f, which in this case is an non-integer exponential and thus not supported by gmp.
Box–Muller Transform uses cos and sin, which are not supported by gmp.