LINE Solver (C++)
Templated C++ port of the LINE queueing solver
Loading...
Searching...
No Matches
qn_reader.h File Reference

Reader for the .qn closed-network model format of mp_pfqn. More...

#include <fstream>
#include <sstream>
#include <string>
#include <vector>
#include "line/num/number.h"
#include "line/util/error.h"
#include "line/util/matrix.h"
Include dependency graph for qn_reader.h:

Go to the source code of this file.

Classes

struct  line::io::QnModel< T >

Namespaces

namespace  line
namespace  line::io

Functions

template<class T>
line::io::parse_rational_token (const std::string &tok)
 Parse a rational token of the form "3" or "3/10".
template<class T>
QnModel< T > line::io::read_qn (const std::string &path)

Detailed Description

Reader for the .qn closed-network model format of mp_pfqn.

Format (mp_pfqn/util/readmodel.c): R number of classes N1 ... NR population per class, -1 marks an open class Z1 ... ZR think times, integers M number of queueing stations mi Li1 ... LiR per station: multiplicity then demands, integers followed by optional keyword sections: LAMBDA arrival rates for the open classes, rationals allowed MU load-dependent rates, M x Nt, rationals allowed

Demands and think times are integers on purpose: that is what keeps the exact rational solvers cheap, and it is why this format is the interchange used to diff against mp_pfqn's binaries. Note the trap documented in _kb/14-cpp-multiprecision: a rational demand like 1/10 in the L section parses as 1 and then desynchronizes the scan, in mp_pfqn as well as here.

Definition in file qn_reader.h.