Code covered by the BSD License  

Highlights from
Generation of Random Variates

image thumbnail

Generation of Random Variates

by

 

generates random variates from over 870 univariate distributions

invfact_pdf(n, nn, c)
% invfact_pdf.m - evaluates an Inverse Factorial Probability Density.
%   See "On the Sum of Independent Zero-Truncated Poisson Random Variables",   
%   J. Springael, 8 June 2006. 
%
%  Created by Jim Huntley,  08/29/11
%

function [pdf] = invfact_pdf(n, nn, c)

pdf = nn * c * exp(gammaln(n+nn) - gammaln(n+1) - gammaln(c+n+nn+1) + gammaln(c+n));

return

Contact us