1%{ @file sn_is_bas_model.m
2 % @brief Checks
if the network
is a closed single-
class Blocking-After-Service model
4 % @author LINE Development Team
8 % @brief Checks
if the network
is a closed single-
class BAS model
11 % Returns
true for a closed, single-
class network with Blocking-After-Service
12 % (BAS) finite-buffer blocking, which solver_sqd handles but exact/AMVA MVA
13 % does not. The Smith queue-decomposition approximation models a single
14 % circulating population, so an open
class or more than one
class disqualifies
19 % bool = sn_is_bas_model(sn)
24 % <tr><th>Name<th>Description
25 % <tr><td>sn<td>Network structure
30 % <tr><th>Name<th>Description
31 % <tr><td>bool<td>True if
the model
is a closed single-class BAS model
34function bool = sn_is_bas_model(sn)
36if sn.nclasses ~= 1 || sn.nclosedjobs <= 0 || isempty(sn.droprule)
39if any(isinf(sn.njobs))
40 return; % open class present
42bool = any(sn.droprule(:) == DropStrategy.BAS);