title: Generating Probability Distributions in Java
body: <p>I want to find out how to generate a probability distribution. I am working on the Stochastic Shortest Path Problem where edges have associated probability distributions with associated costs for each probability. I was able to generate a (normal) distribution like this:</p>
  
  <pre><code>0     1     2     3     4
  0.15  0.2   0.18  0.22  0.25
  </code></pre>
  
  <p>such that the sum of all probabilities is 1 by following answers provided in this <a href="https://stackoverflow.com/questions/2171074/generating-a-probability-distribution">question</a>. Now, I need to generate other distributions like bi-normal, log-normal and gamma. I would really appreciate any clarifications on these distributions and (pseudo) code, preferably in Java, on generating them.</p>