Code covered by the BSD License  

Highlights from
Generation of Random Variates

image thumbnail

Generation of Random Variates



generates random variates from over 870 univariate distributions

truncbeta_cdf(x, a, b, c)
% truncbeta_cdf.m - evaluates a truncated beta Cumulative Distribution.
%   See "Stichastic Decomposition in M/M/inf Queues with Markow Modulated Service Rates", 
%   M. Baykal-Gursoy and W. Xiao, Rutgers, 3/29/2004.
%  Created by Jim Huntley,  07/17/06

function [cdf] = truncbeta_cdf(x, a, b, c)

%persistent cb2 cb3
    cb2 = c^a * a * beta(a,b-a);
    cb3 = c^(b-1) * (b-1) * beta(a,b-a);

cdf = x.^a ./ cb2 - x.^(b-1) ./ cb3;


Contact us