FLD (Fluid/Mean-Field Approximation)

Methods · Configuration · Shared options · All solvers

The FLD solver is based on a system of ordinary differential equations (ODEs) that provide mean-field approximations for queueing networks. The approach is grounded in Kurtz's mean-field approximation theory and is particularly effective for transient analysis and models with large job populations.

Methods

The method names and defaults below describe the MATLAB interface. Aliases share a row; model-specific restrictions and backend differences are noted. Use solver.listValidMethods() to inspect the names available for your model.

The table includes fluid.-qualified spellings (fluid.matrix, fluid.dae, fluid.minnormal, and so on); butools has no qualified alias. The two-part names qualify as fluid.ggisgi and fluid.tga. fluid.default is listed by the JAR, python and C++ but not by MATLAB.

FLD methods and aliases
MethodAlgorithm and applicabilityReference
defaultResolve to the route the model needs: dae for a Petri net, a binding buffer or a capacity region, rmf for a cache, else minnormal where it applies, else closing for DPS, else matrix.
matrix, fluid.matrixFirst-order mean-field ODE built from the linear generator, with the hard min() capacity term; the historical default.[1], [2]
pnorm, fluid.pnormThe matrix drift with the hard min replaced by a p-norm smoothing (config.pstar, default 20).[2]
softmin, fluid.softminThe state-dependent drift with min() replaced by a Boltzmann softmin of parameter alpha (config.alpha, default 20).
statedep, fluid.statedepDrift built in closed form from the phase-type parameters, allowing rates that are general functions of the state.[1]
closing, fluid.closingClosing-method fluid iteration: the inner fixed point over per-station throughputs used for open, mixed and DPS models.[3]
minnormal, fluid.minnormalMin-normal moment closure: E[min(X,c)] evaluated for jointly normal populations, so mean and covariance are integrated together.
refined, fluid.refinedThe min-normal closure plus Gast's O(1/N) correction taken about the mean-field fixed point.
dae, fluid.daeThe same min-normal closure stated and solved as one differential-algebraic system; the only route for Petri nets, binding buffers and capacity regions.
tbi, fluid.tbiTrajectory-based iteration: the stations are partitioned into cells and each cell's IVP is solved with the others frozen (waveform relaxation) until the trajectories agree.
diffusion, fluid.diffusionEuler-Maruyama on the flow drift, reflected at zero and projected back onto each class population; stochastic, closed multiclass only.[4]
kp, fluid.kpKo-Pender fluid and diffusion limits of the time-varying infinite-server network. Integrates the mean and covariance ODEs and returns second moments.
rmf, fluid.rmfRefined mean-field decomposition of a cache-queueing model; degenerates to matrix when the model has no Cache node.
mfq, fluid.mfqMarkovian fluid-queue analyzer using BuTools for a Source-Queue-Sink shape, including the fluid priority queue; falls back to matrix off that shape.[5]
butoolsAlias of mfq (the one name of the family with no fluid. twin).
aoi, fluid.aoiAlias of mfq, reaching the age-of-information fluid solver when the topology qualifies.
mtginf, fluid.mtginfExact Poisson law of the time-varying infinite-server queue: the mean E[lambda(t-Se)] and its time lag.
mol, fluid.molModified offered load: the infinite-server offered load fed into the stationary Erlang formula, which carries the time lag.
ggisgi.fluid, ggisgi, fluid.ggisgiDeterministic fluid limit of the overloaded multiserver queue with abandonment, including the queue boundary.
ggingi.tga, tga, fluid.tgaTruncated-Gaussian refinement of that fluid limit, carrying a general service law.
tvms, fluid.tvmsTime-varying many-server fluid queue solved forward on a grid at the staffing the model declares.

Configuration options

The solver-specific fields below belong to options.config. Set them on an options struct, for example opt.config.name = value, and pass that struct to the solver constructor. See shared solver options for all top-level fields, shared configuration, defaults and usage. Options apply only to the methods and model features that consume them.

Relevant top-level options: iter_max, timespan, timestep, init_sol, stiff, odesolvers.

FLD defaults to iter_max=200, timespan=[0,Inf] and stiff=true. The five ODE integrator slots belong to options.odesolvers. The pnorm method supplies pstar=20 when no exponent is given; the general configuration field is otherwise unset.

Solver-specific configuration
OptionDefaultDescription and values
alpha20Smoothing parameter of the softmin drift, scalar or per station; larger is sharper and stiffer.
dae_maxcov25Cap on the transient covariance system the DAE route will build.
dae_maxstate100Cap on the simultaneous state dimension the DAE route will solve.
fluid_earlystoptrueStop the ODE window loop once the drift residual says the state is at a fixed point, instead of running iter_max windows.
immediate_toltoleranceRate above which a coordinate counts as immediate and is eliminated rather than integrated.
init_covunsetInitial covariance matrix of the kp diffusion limit, in that method's state space.
init_qcovunsetInitial queue-length covariance for the same, given per station and class.
init_qlenunsetInitial mean queue lengths of a transient, in the same index space as init_qcov.
kp_init_solunsetInitial state vector of the kp (Ko-Pender) fluid and diffusion system.
lsoda_retryfalseInternal: marks the second attempt after an LSODA failure so the retry does not recurse.
moment_covinternalPer-station covariance handles passed between the moment-closure passes.
moment_maxstatecapLargest state dimension a moment-closure method will attempt.
moment_sigma2zerosPer-station variance seed of the closure; all-zero reduces it to the mean-field limit.
nhpp_schedunsetNon-homogeneous Poisson arrival schedule, a struct array making the drift time-varying.
pstarunsetExponent of the p-norm smoothing, switching it on under any matrix-family method.
rate_trajunsetExplicit rate trajectory over time, the other way to make the drift time-varying.
tbi_cellsderivedTrajectory-based iteration: an explicit cell array of disjoint station index sets.
tbi_cellsize5Stations per cell when the partition is derived rather than given.
tbi_iterationJacobiSweep order over cells: 'gs'/'gauss-seidel' uses the updated inflows within a sweep.
tbi_iter_maxmethod defaultIteration cap of that cell fixed point.
tbi_parallelfalseFan the per-cell integrations over a parfor pool, when the toolbox is licensed.
tbi_tolmethod defaultCross-cell inflow tolerance that stops the iteration.

Example

This example demonstrates the FLD solver on a closed queueing network with a large job population (100 jobs). The fluid approximation is particularly effective for high-population scenarios, where it provides accurate results more efficiently than state-space methods.

% Create a closed queueing network with 100 jobs
model = Network('FLD Example');

delay = Delay(model, 'Delay');
queue = Queue(model, 'Queue', SchedStrategy.FCFS);
jobclass = ClosedClass(model, 'Class1', 100, delay);

delay.setService(jobclass, Exp(1.0));
queue.setService(jobclass, Exp(2.4));

P = model.initRoutingMatrix();
P.set(jobclass, jobclass, delay, queue, 1.0);
P.set(jobclass, jobclass, queue, delay, 1.0);
model.link(P);

solver = FLD(model);
FLD(model).avgTable()

Output:

FLD analysis [method: default/matrix; type: approximate, deterministic; lang: matlab; env: 2025a] completed in 0.076s.
  2×8 table

    Station    JobClass     QLen      Util     RespT     ResidT     ArvR      Tput
     Delay      Class1      2.4       2.4          1         1      2.4       2.4
     Queue      Class1     97.6         1     40.667    40.667      2.4       2.4
// Create a closed queueing network with 100 jobs
Network model = new Network("FLD Example");

Delay delay = new Delay(model, "Delay");
Queue queue = new Queue(model, "Queue", SchedStrategy.FCFS);
ClosedClass jobclass = new ClosedClass(model, "Class1", 100, delay);

delay.setService(jobclass, new Exp(1.0));
queue.setService(jobclass, new Exp(2.4));

RoutingMatrix P = model.initRoutingMatrix();
P.set(jobclass, jobclass, delay, queue, 1.0);
P.set(jobclass, jobclass, queue, delay, 1.0);
model.link(P);

FLD solver = new FLD(model);
solver.avgTable.print();

Output:

FLD analysis [method: default/matrix; type: approximate, deterministic; lang: java; env: 17.0.9] completed.

  Station    JobClass     QLen      Util     RespT     ResidT     ArvR      Tput
    Delay      Class1      2.4       2.4          1         1      2.4       2.4
    Queue      Class1     97.6         1     40.667    40.667      2.4       2.4
# Create a closed queueing network with 100 jobs
from line_solver import *

model = Network("FLD Example")

delay = Delay(model, "Delay")
queue = Queue(model, "Queue", SchedStrategy.FCFS)
jobclass = ClosedClass(model, "Class1", 100, delay)

delay.set_service(jobclass, Exp(1.0))
queue.set_service(jobclass, Exp(2.4))

P = model.init_routing_matrix()
P.set(jobclass, jobclass, delay, queue, 1.0)
P.set(jobclass, jobclass, queue, delay, 1.0)
model.link(P)

solver = FLD(model)
print(solver.avg_table)

Output:

FLD analysis [method: default/matrix; type: approximate, deterministic; lang: python; env: 3.13.7] completed.

  Station    JobClass     QLen      Util     RespT     ResidT     ArvR      Tput
    Delay      Class1      2.4       2.4          1         1      2.4       2.4
    Queue      Class1     97.6         1     40.667    40.667      2.4       2.4

References

  1. Pérez, J. F., & Casale, G. (2017). Decoupling transient and steady-state analysis in closed-form solutions of Markovian queueing networks. IEEE Transactions on Reliability, 66(3), 625-638.
  2. Ruuskanen, J., Berner, T., Årzén, K.-E., & Cervin, A. (2021). Improving the mean-field fluid model of processor sharing queueing networks for dynamic performance models in cloud computing. Performance Evaluation, 151, 102231.
  3. Bolch, G., Greiner, S., de Meer, H., & Trivedi, K. S. (2006). Queueing Networks and Markov Chains (2nd ed.). Wiley-Interscience.
  4. Reiser, M. (1983). Performance evaluation of data communication systems. Proceedings of the IEEE, 70(2), 171-196.
  5. Horváth, G., & Telek, M. (2014). Sojourn times in fluid queues with independent and dependent input and output processes. Performance Evaluation, 79, 160-181. https://doi.org/10.1016/j.peva.2014.07.011