1function ProbAggr = getProbAggr(self, node, state)
2% PROBAGGR = GETPROBAGGR(NODE, STATE)
4% Probability of a SPECIFIC per-
class job distribution at a station.
5% Returns
P(n1 jobs of
class 1, n2 jobs of
class 2, ...) for given state.
7% Compare with getProbMarg: returns total queue-length distribution,
8% i.e.,
P(n total jobs) summed over all class combinations.
12% state - Per-class job counts, e.g., [2,1] = 2 class-1, 1 class-2
15% ProbAggr - Scalar probability in [0,1] (estimated via simulation)
17if GlobalConstants.DummyMode
22% we do not use probSysState as that
is for joint states
23TranSysStateAggr = self.sampleSysAggr;
25isf = sn.nodeToStateful(node.index);
26TSS = cell2mat({TranSysStateAggr.t,TranSysStateAggr.state{isf}});
27TSS(:,1)=[TSS(1,1);diff(TSS(:,1))];
28if nargin<3 %~exist(
'state',
'var')
29 state = sn.state{isf};
31rows = findrows(TSS(:,2:end), state);
33 ProbAggr = sum(TSS(rows,1))/sum(TSS(:,1));
35 line_warning(mfilename,
'The state was not seen during the simulation.\n');