1function eta=QBD_CAUDAL(A0,A1,A2,varargin)
2%QBD_CAUDAL Computes the Spectral Radius of R
4% eta=QBD_CAUDAL(A0,A1,A2) computes the dominant eigenvalue of the
5% matrix R, the smallest nonnegative solution to R= A2 + R A1 + R^2 A0,
6% in
case the QBD
is recurrent
10% Dual: When set to 1, the dominant eigenvalue of the Ramaswami
11% dual
is returned. The input QBD must be transient.
14OptionTypes=[
'numeric'];
18for i=1:size(OptionNames,1)
19 options.(deblank(OptionNames(i,:)))=[];
25% Parse Optional Parameters
26options=ParseOptPara(options,OptionNames,OptionTypes,OptionValues,varargin);
29 % the dominant eigenvalue of the Ramaswami dual
is
30 % identical to the dominant eigenvalue of the process
31 % where A2 and A0 are switched.
40while (eta_max - eta_min > 10^(-15))
41 new_eta=max(eig(A2+A1*eta+A0*eta^2));
47 eta=(eta_min+eta_max)/2;