Dear friends, I'm trying to write a program that draws 5,000 numbers from an exponential distribution with mean 4N/k(k-1)
N=10 000 k = 25 I have this: #!jesusafernandez/bin/perl $k = 25; $N = 10000; for ($samp=0; $samp<5000; $samp++) { while ($k!= "$25") { $mean = 4$N/$k($k-1)); $time = (-log (rand)*$ mean); push (@xx,$time); $k=$k-y} print "$time\n"; Any help will be greatly appreciate jaff