*Bounty: 100*

*Bounty: 100*

I am defining triangular and Beta-Pert distributions in MATLAB to produce random samples for Monte Carlo analysis. This is a trivial task if the minimum, maximum and mode are known using:

makedist(‘Triangular’, ‘a’,’b’,’c’); [where a,b,c are min/mode/max values]

makedist(‘Beta’,’a’,’b’); [where a and b can be calculated from min/mode/max using the Beta-Pert relations]

However, my users will provide the mode and percentile values (P5/P95, P10/P90 etc.) and the distribution type. As far as I can tell MATLAB can only accept distributions defined using their minimum, mode and maximum values.

So my question is how do I derive the minimum and maximum values of a triangular or Pert distribution given the mode and low/high percentile values?

http://www.greatsolutions.com.br/images/BetaEng.pdf shows a method for doing it empirically but Palisade @Risk has an analytical solution which I’m looking to replicate.

It can’t be as simple as using the inverse cumulative distribution function equation as I think there would be too many unknowns to solve it.

I would greatly appreciate any help on this because this level of statistical detail is a bit over my head and the link above is the closest thing I can find online to the solution I am after.