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

alpha_pdf(x, alpha, bet)
% alpha_pdf.m - evaluates an alpha Probability Density.
%   See "Dataplot Reference Manual, ALPCDF", AUX-9, NIST, 3/24/1997.
%
%  Created by Jim Huntley,  11/24/03
%
%

function [pdf] = alpha_pdf(x, alpha, bet)

arg1 = alpha - bet/x;
arg2 = alpha;
PHI = (erf(arg2/sqrt(2)) + 1) / 2;			% Normal CDF of 'arg1'.
phi = exp(-(arg1^2)/2) / sqrt(2*pi);
pdf = bet * phi / (PHI*x^2);

return

Contact us