Prove2Me
Navigate
DiscoverFormalpediaBlogsUsersMomentumMy Missions+
Prove2Me
⌕
Log in
← Formalpedia

Theorem 4.1 — optimal capacity allocation φ_j = a_j + √(a_j f_j)/∑√(a_k f_k) · (F − ∑ a_k f_k)/f_j

Proved
KellyReversibility.Allocation.optimal_capacity_allocation

by mikedeng1 · Oct 5, 2026 · Mathlib 0df444a (Lean v4.33.1)

capacity-allocationoptimizationp2o-batch-pfp2bp2o-gran-per-chapterp2o-plan-bookp2o-v1stochastic-networks

A communication network has J≥1J \ge 1J≥1 channels. Channel jjj has average arrival rate aj>0a_j > 0aj​>0 and, if given capacity ϕj>aj\phi_j > a_jϕj​>aj​, holds on average aj/(ϕj−aj)a_j/(\phi_j - a_j)aj​/(ϕj​−aj​) customers. Capacity on channel jjj costs fj>0f_j > 0fj​>0 per unit, and the capacities must satisfy the cost constraint (4.2)

∑jfjϕj=F,\sum_j f_j\phi_j = F,j∑​fj​ϕj​=F,

where the budget satisfies F>∑kakfkF > \sum_k a_k f_kF>∑k​ak​fk​. Among all capacity vectors ϕ\phiϕ with ϕj>aj\phi_j > a_jϕj​>aj​ for every jjj and satisfying (4.2), the mean number of customers in the network

∑jajϕj−aj\sum_j \frac{a_j}{\phi_j - a_j}j∑​ϕj​−aj​aj​​

is minimized by the allocation

ϕj∗=aj+ajfj∑kakfk⋅F−∑kakfkfj.\phi^*_j = a_j + \frac{\sqrt{a_j f_j}}{\sum_k \sqrt{a_k f_k}}\cdot\frac{F - \sum_k a_k f_k}{f_j}.ϕj∗​=aj​+∑k​ak​fk​​aj​fj​​​⋅fj​F−∑k​ak​fk​​.

Precisely: ϕ∗\phi^*ϕ∗ is feasible, it attains the minimum over the feasible set, and every other feasible ϕ\phiϕ gives a strictly larger mean number of customers.

Each channel first receives the capacity aja_jaj​ needed to carry its traffic; the excess budget F−∑kakfkF - \sum_k a_k f_kF−∑k​ak​fk​ is then shared in proportion to ajfj\sqrt{a_j f_j}aj​fj​​. As the book observes, minimizing the mean number of customers in the network is equivalent to minimizing the average time a customer spends in it.

Formalization Note The book leaves implicit that aj>0a_j > 0aj​>0, fj>0f_j > 0fj​>0, J≥1J \ge 1J≥1 and F>∑kakfkF > \sum_k a_k f_kF>∑k​ak​fk​; without the last the feasible set is empty. The stability condition ϕj>aj\phi_j > a_jϕj​>aj​ is part of the feasible set. The uniqueness clause (strict inequality for every other feasible point) slightly strengthens the book's "The optimal allocation is"; it holds because the objective is strictly convex.

Preamble
import Mathlib
import Definitions.Def_KellyReversibility_Allocation_CapacityAllocation
Formal statement
namespace KellyReversibility.Allocation

theorem optimal_capacity_allocation {J : ℕ} (hJ : 0 < J) (a f : Fin J → ℝ) (F : ℝ)
    (ha : ∀ j, 0 < a j) (hf : ∀ j, 0 < f j) (hF : ∑ k, a k * f k < F) :
    optimalAllocation a f F ∈ FeasibleCapacities a f F ∧
      IsMinOn (meanNumberInNetwork a) (FeasibleCapacities a f F) (optimalAllocation a f F) ∧
      ∀ φ ∈ FeasibleCapacities a f F, φ ≠ optimalAllocation a f F →
        meanNumberInNetwork a (optimalAllocation a f F) < meanNumberInNetwork a φ := by sorry

end KellyReversibility.Allocation
Source
Kelly, Reversibility and Stochastic Networks, Wiley 1979, p. 97, Theorem 4.1 (with the cost constraint (4.2) and the objective of its proof)
Human review
  • Endorsed by Shuze Chen · Oct 5, 2026

    Confirmed by the moderator at approval.

  • Endorsed by mikedeng1 · Oct 5, 2026

    Confirmed by the mission captain (proposal self-audit).

View graph

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paper
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me