![]() |
LINE Solver (C++)
Templated C++ port of the LINE queueing solver
|
Mean busy period of order n for a subnetwork of a product-form network. More...
#include <algorithm>#include <cmath>#include <cstddef>#include <functional>#include <limits>#include <vector>#include "line/num/number.h"#include "line/util/error.h"#include "line/util/matrix.h"Go to the source code of this file.
Classes | |
| struct | line::pfqn::BusyPeriodResult |
| What pfqn_busyp returns: the durations and the two constant sequences. More... | |
Namespaces | |
| namespace | line |
| namespace | line::pfqn |
Functions | |
| template<class T, class RateSource> | |
| BusyPeriodResult | line::pfqn::pfqn_busyp (const std::vector< double > &alpha, const RateSource &mu, const Matrix< T > &P, double N, const std::vector< std::size_t > &subnet, const std::vector< std::size_t > &n, const std::vector< double > &gamma={}, double tol=PFQN_BUSYP_DEFAULT_TOL) |
| Mean busy period of order n for the subnetwork. | |
Variables | |
| constexpr double | line::pfqn::PFQN_BUSYP_DEFAULT_TOL = 1e-12 |
| Default relative tolerance of the open-network tail truncation. | |
Mean busy period of order n for a subnetwork of a product-form network.
Templated port of matlab/src/api/pfqn/pfqn_busyp.m, jar/src/main/java/jline/api/pfqn/Pfqn_busyp.java and python/line_solver/api/pfqn/busyp.py. Implements H. Daduna, "Busy Periods for Subnetworks in Stochastic Networks: Mean Value Analysis", J. ACM 35(3), 1988: Theorem 1 for a closed Gordon-Newell network and Theorem 3 for an open Jackson network.
The busy period of order n for a set of nodes I is the interval from the instant a job entering I finds n-1 jobs in it until fewer than n remain. With G(m,I) the normalizing constant of I at population m, H(m,I) that of the complement, and A(I) the total rate at which jobs enter I from outside it,
closed: b(n,I) = sum_{m=n}^{N} G(m,I) H(N-m,I) / [G(n-1,I) H(N-n,I) A(I)] open: b(n,I) = sum_{m>=n} G(m,I) / [G(n-1,I) A(I)]
The paper is single-chain: alpha solves x*P = x for a closed network and x = gamma + x*P for an open one, and every node is a state-dependent single-server FCFS station. By the insensitivity noted in Section 5 the result depends on the service processes only through the rates mu.
ARITHMETIC: the sums are accumulated in the log domain in double, exactly as the three reference implementations do, which is what keeps G(m,I) from overflowing on its own well before the ratio does. The templated inputs are therefore read through num_traits<T>::to_double; there is no exact-rational path, since a logarithm has none.
Definition in file pfqn_busyp.h.