LINE Solver
MATLAB API documentation
Loading...
Searching...
No Matches
pfqn_ldbcmp.m
1%{
2%{
3 % @file pfqn_ldbcmp.m
4 % @brief Anselmi-Cremonesi (2008) lower throughput bound for closed
5 % single-class BCMP networks with load-dependent stations.
6%}
7%}
8
9function [Xlo,Rhi,Qhat] = pfqn_ldbcmp(L,N,Z,c,varargin)
10%{
11%{
12 % @brief Lower bound on system throughput (and upper bound on response time)
13 % for a closed, single-class BCMP network with load-dependent stations,
14 % via the asymptotic closed-open equivalence of Anselmi and Cremonesi,
15 % "Bounding the Performance of BCMP Networks with Load-Dependent
16 % Stations" (2008). The bound (their eq. 15) exploits the monotonicity
17 % of system throughput and the fact that a closed BCMP network is, in
18 % the limit N -> inf, equivalent to the open network obtained by
19 % removing the bottleneck and injecting arrivals at rate 1/D_max. It is
20 % applicable when N >= Qhat and is asymptotically exact; Algorithm 1
21 % refines it to a monotone fixed point.
22 % @fn pfqn_ldbcmp(L, N, Z, c, tol)
23 % @param L Fixed-rate (limiting) service demand vector (M x 1). For a Heffes
24 % LD station, L(i) is the limiting demand D_i = lim_n D_i(n).
25 % @param N Total population (scalar).
26 % @param Z Think time (scalar; modeled as a non-bottleneck delay station).
27 % @param c Per-station Heffes load-dependence coefficient (M x 1, default 0).
28 % c(i)=0 marks a fixed-rate (LI) station with open queue
29 % rho_i/(1-rho_i); c(i)>0 a Heffes LD station with open queue
30 % (c(i)+1)*rho_i/(1-rho_i) (their eq. 22-23). The bottleneck is
31 % assumed fixed-rate (population transform (7) reduces to N'=N).
32 % @param tol Fixed-point tolerance for Algorithm 1 (default 1e-10).
33 % @return Xlo Lower bound on system throughput X(N); NaN if N < Qhat.
34 % @return Rhi Upper bound on system response+think time, N/Xlo (Little).
35 % @return Qhat Sum of non-bottleneck limiting queue lengths (eq. 11).
36%}
37%}
38
39L = L(:);
40M = numel(L);
41if nargin < 3 || isempty(Z)
42 Z = 0;
43end
44Z = sum(Z(:));
45if nargin < 4 || isempty(c)
46 c = zeros(M,1);
47end
48c = c(:);
49tol = 1e-10;
50if numel(varargin) >= 1 && ~isempty(varargin{1})
51 tol = varargin{1};
52end
53
54% Limiting effective demands and bottleneck (eqs. 3-5).
55Dstar = L;
56Dm = max(Dstar);
57isbott = abs(Dstar - Dm) <= 1e-12*Dm;
58bmax = sum(isbott);
59
60% Qhat: sum of non-bottleneck queue lengths in the equivalent open BCMP
61% network at arrival rate lambda = 1/Dm (eqs. 11, 17, 22-23).
62lambda = 1/Dm;
63Qhat = 0;
64for i = 1:M
65 if isbott(i)
66 continue
67 end
68 rho_i = lambda*Dstar(i);
69 if rho_i >= 1
70 Xlo = NaN; Rhi = NaN; return
71 end
72 Qhat = Qhat + (c(i)+1)*rho_i/(1-rho_i);
73end
74% Delay station (infinite server): open queue lambda*Z.
75Qhat = Qhat + lambda*Z;
76
77% Applicability (eqs. 8-10 require N - Qhat >= 0).
78if N - Qhat < 0
79 Xlo = NaN;
80 Rhi = NaN;
81 return
82end
83
84% Algorithm 1: iterate the lower bound eq. (15) to a monotone fixed point.
85a = N - Qhat;
86Xprime = 0;
87Xlo = 0;
88for it = 1:10000
89 Xprev = Xlo;
90 denom = Dm*(bmax + N - Qhat) - bmax*(Dm*Xprime)^N*Dm;
91 Xlo = a/denom;
92 Xprime = Xlo;
93 if Xprev > 0 && abs(Xprev - Xlo)/Xprev <= tol
94 break
95 end
96end
97
98Rhi = N/Xlo; % response+think upper bound (Little, eq. 16)
99end
Definition Station.m:245