Computer Networks · TEE · practice

Leaky queue and token bucket

Extra mathematical models

TEE · Complete six-unit quick reference · current syllabus 702AI0C023

q_b=\max(0,q-r\Delta t)LaTeX: q_b=\max(0,q-r\Delta t)

Leaky data-queue state before the next arrival; service cannot exceed queued data.

a_{ok}=\min(a,B-q_b),\quad drop=a-a_{ok}LaTeX: a_{ok}=\min(a,B-q_b),\quad drop=a-a_{ok}

B finite data capacity; admit instantaneous arrivals after interval service.

T_{new}=\min(B,T+r\Delta t)LaTeX: T_{new}=\min(B,T+r\Delta t)

Token refill before the next admission, capped by token capacity.

t_{wait}=\max(0,L-T)/rLaTeX: t_{wait}=\max(0,L-T)/r

Single packet of L≤B tokens, no other queued traffic, shaper not policer.

D(t)\le B+rtLaTeX: D(t)\le B+rt

Full token-bucket allowance; physical link rate also bounds actual departure.

t_{burst}=B/(P-r),\quad P>rLaTeX: t_{burst}=B/(P-r),\quad P>r

Fluid peak-rate burst, initially full and continuously backlogged. Net depletion is P−r.

Three sustained-burst examples