1% r = CheckMEPositiveDensity(alpha, A, maxSize, prec)
3% Checks
if the given matrix-exponential distribution has
8% alpha : matrix, shape (1,M)
9% Initial vector of the matrix-exponential distribution
11% A : matrix, shape (M,M)
12% Matrix parameter of the matrix-exponential distribution
14% maxSize : int, optional
15% The procedure tries to transform the ME distribution
16% to phase-type up to order maxSize. The
default value
18% prec : double, optional
19% Numerical precision. The
default value
is 1e-14.
24% True,
if the given matrix-exponential distribution has
29% This procedure calls MonocyclicPHFromME, and can be time
32function r = CheckMEPositiveDensity (alpha, A, maxSize, prec)
34 global BuToolsCheckPrecision;
35 if isempty(BuToolsCheckPrecision)
36 BuToolsCheckPrecision = 1e-12;
39 if ~exist(
'prec',
'var')
40 prec = BuToolsCheckPrecision;
43 if ~exist('maxSize','var')
48 [beta, B] = MonocyclicPHFromME (alpha, A, maxSize, prec);
49 r = CheckMERepresentation (beta, B, prec);