LINE Solver
MATLAB API documentation
Loading...
Searching...
No Matches
matlab
lib
thirdparty
FJ_codes
returnWait.m
1
function [ wait_alpha, wait_Smat, prob_wait, alfa ]=returnWait( En1,pi0,T,phi,sum_Ajump )
2
%
3
% The function calculates the phase-type representation of the stationary
4
% waiting time of a K-node FJ queue
5
%
6
7
%% Section 6
8
alfa = -pi0/T;
9
ds = length(phi);
10
11
rhos = diag(phi*alfa)
'/(alfa*phi);
12
En0 = alfa*sum_Ajump/sum(pi0);
13
14
prob_wait = (En0-1)/(En0-1+En1);
15
wait_alpha = prob_wait*rhos;
16
17
wait_Smat = zeros(ds,ds);
18
for i = 1:ds
19
for j = 1:ds
20
wait_Smat(i,j) = alfa(j)*T(j,i)/alfa(i); % Gij
21
end
22
end
23
Generated by
1.9.8