Is there a package for three parameter inverse gaussian or lognormal distributions in C++? I want to generate random numbers from one of the following distribution in C++. I haven't been able to find any libraries though. Do they exist?
In order of preference:


*

*Three parameter inverse Gaussian

*Three parameter Lognormal

*Three parameter Log-Logistic

*Four parameter Pearson Type 6

*Generalized Pareto

 A: I don't think there is a c++ library, but you can easily write your code:
1) on wikipedia there is a method to simulate a two parameters inverse gaussian http://en.wikipedia.org/wiki/Inverse_Gaussian_distribution. You can use this and then shift the distributon to have a three parameters distribution
2) you can simulate a normal variable with the same two parameters of the log normal, take the exponential, shifting by the value of the third parameter
3) maybe you can simulate a logistic distribution and then take the log, but i am not sure
4) i don't know this distribution
5)again wikipedia helps you http://en.wikipedia.org/wiki/Generalized_Pareto_distribution#Generating_generalized_Pareto_random_variables
A: With some more searching I found a library by Richard Saucier which contained the three parameter lognormal among other distributions. The documentation for the library is here.
Thank you niandra82 for your reply. When I looked at the library code you were quite right in that it would have been easy enough to write myself. The wikipedia definitions of the distributions make things seem far more complicated than needed and I was put off though!
