% Regression test function (black blox) for FreeMat v3.6
% This function is autogenerated by helpgen.
function bbtest_success = bbtest_randbeta
  bbtest_success = 1;
NumErrors = 0;
try
  a = 3; b = 7;

catch
  NumErrors = NumErrors + 1;
end
try
  x = (0:100)/100; t = x.^(a-1).*(1-x).^(b-1); 

catch
  NumErrors = NumErrors + 1;
end
try
  t = t/(sum(t)*.01);

catch
  NumErrors = NumErrors + 1;
end
try
  plot(x,t);

catch
  NumErrors = NumErrors + 1;
end
try
  mprint betapdf

catch
  NumErrors = NumErrors + 1;
end
if (NumErrors ~= 0) bbtest_success = 0; return; end
NumErrors = 0;
try
  randbeta(3*ones(1,5),7*ones(1,5))

catch
  NumErrors = NumErrors + 1;
end
if (NumErrors ~= 0) bbtest_success = 0; return; end
