Code covered by the BSD License  

Highlights from
Generation of Random Variates

image thumbnail

Generation of Random Variates


James Huntley (view profile)


generates random variates from over 870 univariate distributions

cascade_cdf(n, d, p, r)
% cascade_cdf.m - compute Cascade Cumulative Distribution Function.
%   See "Dynamical and Probabilistic Approoaches to the Study of Blackout
%   Vulnerability of the Power Transmission Grid", B. A. Carreras et al., 
%   Hawaii Internaltional Conference on System Science, Jan., 2004.
%  Created by:  Jim Huntley,  07/24/06.

function [y] = cascade_cdf(n, d, p, r)

sum1 = cascade_pdf(0, d, p, r);
for jn = 1:n
    sum1 = sum1 + cascade_pdf(jn, d, p, r);
y = sum1;

Contact us