---
title: '2D Demand Bin Packing: Models & Algorithms'
url: https://www.emergentmind.com/topics/2d-demand-bin-packing
type: topic
---

# 2D Demand Bin Packing: Models & Algorithms

Searching arXiv for the provided topic and key supporting papers.
arXiv search query: "2D Demand Bin Packing 2508.13347 2509.01218 1103.0260 2403.12420 2308.02787 1703.07244 1909.06835 1209.0880"
2D demand bin packing denotes a family of optimization problems in which two-dimensional demand objects must be allocated to bins under packing or capacity constraints, with the objective usually expressed as minimizing the number of bins used. The literature does not employ a single canonical formalization. One line of work defines a bin as a timeline of length \(T\) and capacity \(C\), with each task \(i\) represented by a rectangle of width \(w_i\) and height \(h_i\), so that the sum of heights active at any time slot does not exceed \(C\) [2508.13347]. A second line corresponds directly to 2-dimensional vector packing, where item \(i\) has demand vector \((s_i,l_i)\) and each bin has capacities \((C_S,C_L)\) [1103.0260]. A third line treats demand through multiplicities of geometric item types, selecting feasible single-bin layouts repeatedly until lower and upper production requirements are met [2509.01218]. Taken together, these works indicate that “2D demand bin packing” is best viewed as an umbrella term rather than a single standardized model.

## 1. Formalizations and scope

In the timeline-capacity formulation, a feasible allocation of tasks into one bin is a function \(\mathcal{A}: I \to \{1,\dots,T\}\) such that task \(i\), if started at time \(\mathcal{A}(i)=t\), occupies time slots \(\{t,\dots,t+w_i-1\}\), and the load profile
\[
\ell(t)=\sum_{i:\, t \in [\mathcal{A}(i),\,\mathcal{A}(i)+w_i-1]} h_i
\]
satisfies \(\ell(t)\le C\) for every slot \(t\) [2508.13347]. This model is demand-oriented in the literal sense: width is duration and height is per-slot demand. A common misconception is to equate this directly with geometric non-overlap packing. In fact, tasks may overlap in time as long as cumulative height remains within capacity; the feasibility condition is load aggregation, not rectangle disjointness [2508.13347].

In 2-dimensional vector packing, the mapping is coordinate-wise. Given tuples \((s_1,l_1),\dots,(s_n,l_n)\), one seeks a minimum number of sets \(B_1,\dots,B_k\) such that every tuple is assigned to some \(B_j\) and
\[
\sum_{(s_i,l_i)\in B_j} s_i \le C_S,\qquad \sum_{(s_i,l_i)\in B_j} l_i \le C_L.
\]
After normalization, the standard assumption is \(C_S=C_L=1\) and \(s_i,l_i\in[0,1]\) [1103.0260]. Here “demand” is a 2-component resource requirement rather than a geometric object.

In geometric demand formulations with multiplicities, a pattern or layout \(l\) is represented by an item-count vector \(\vec a_l=(a_{1,l},\dots,a_{n,l})\), where \(a_{j,l}\) is the number of copies of type \(j\) placed in one bin. If \(x_l\) denotes the number of bins using pattern \(l\), then total production of type \(j\) is
\[
s_j=\sum_{l=1}^p a_{j,l}x_l,
\]
and demand is enforced by
\[
d_j \le s_j \le u_j.
\]
This is the formulation closest to cutting-stock style demand satisfaction in geometric 2D packing [2509.01218].

## 2. Timeline-capacity demand packing

The most explicit recent formalization of 2D Demand Bin Packing models each bin as a timeline of length \(T\) with capacity \(C\), and each task \(i\) as a rectangle with width \(w_i\), height \(h_i\), and area \(a(i)=h_i w_i\) [2508.13347]. The optimization problem is to partition the task set into the minimum number of bins so that each part admits a feasible allocation. A fundamental lower bound is the area bound
\[
OPT(I)\ge \left\lceil \frac{a(I)}{T\cdot C}\right\rceil,
\]
since a single bin can contain total area at most \(TC\) [2508.13347].

A central structural notion is the load profile \((\ell(1),\dots,\ell(T))\). A profile is called sorted if
\[
\ell(1)\ge \ell(2)\ge \cdots \ge \ell(T).
\]
This supports the generalized First-Fit mechanism used in the paper’s approximation framework: relatively large tasks are packed into a structured partial solution, and relatively small tasks are then inserted from left to right while maintaining a monotone suffix profile [2508.13347].

The key abstraction is a \(k\)-structured solution. A partial solution is \(k\)-structured if it uses at most \(k\cdot OPT\) bins and each bin is either \(\frac1k\)-full or has a sorted load profile. The main insertion lemma states that if there exists a \(k\)-structured solution for tasks with \(h_i>\delta_h C\) or \(w_i>\delta_w T\), then all tasks can be allocated into at most \(kOPT\) bins provided
\[
(1-\delta_h)(1-\delta_w)\ge \frac1k.
\]
This is the unifying device behind the approximation algorithms for short tasks, square tasks, and the general case [2508.13347].

## 3. Complexity and approximation landscape

The complexity picture is sharply developed for the timeline-capacity model. Even deciding whether a given set of tasks fits in one bin is NP-hard, which immediately yields that no \((2-\varepsilon)\)-approximation can exist unless \(P=NP\), because an instance with \(OPT=1\) would have to be recognized exactly [2508.13347]. The paper strengthens this for restricted families. For short tasks, defined by
\[
h_i \le \frac19 C \qquad \forall i,
\]
there is a 2-approximation, and no \((2-\varepsilon)\)-approximation exists unless \(P=NP\) [2508.13347]. For square tasks, there is likewise a 2-approximation, again matching a \((2-\varepsilon)\)-hardness barrier in the square-bin case [2508.13347]. For unrestricted instances, the best guarantee in that paper is a 3-approximation, leaving a gap between the factor-2 hardness barrier and the current upper bound [2508.13347].

The vector-packing literature provides a different but related approximation perspective. In the normalized model \(C_S=C_L=1\), items are classified as \(s\)-heavy if \(s_i\ge l_i\) and \(l\)-heavy otherwise, and the algorithm repeatedly balances the currently dominant coordinate by adding an item from the opposite heavy class [1103.0260]. Let
\[
\rho=\max\{s_i,l_i:1\le i\le n\}.
\]
The paper proves that its linear-time in-place algorithm generates a solution with no more than
\[
\frac{C^\ast}{1-\rho}+1
\]
bins, where \(C^\ast\) is the value of an optimal solution [1103.0260]. This result is specific to the 2-dimensional vector model rather than the timeline-capacity model, but it shows that 2D demand packing admits materially different approximation structures depending on whether “2D” refers to time-demand overlap or coordinate-wise capacities.

## 4. Pattern-based demand satisfaction and branch-and-price

A geometric demand model with explicit multiplicities is developed through a branch-and-price formulation in which each column represents one feasible 2D single-bin layout [2509.01218]. There are \(n\) rectangular item types, one rectangular bin type, and lower and upper production requirements \(d_j\) and \(u_j\). If all feasible patterns are enumerated, the master MIP is
\[
\min \sum_{l=1}^p \left(c_1 y_l + c_2 x_l\right),
\]
where \(x_l\in\mathbb N_0\) is the number of bins using pattern \(l\) and \(y_l\in\{0,1\}\) indicates whether pattern \(l\) is used at all [2509.01218]. The linking and demand-range constraints are
\[
\frac{1}{M}x_l \le y_l \qquad \forall l,
\]
\[
s_j = \sum_{l=1}^p a_{j,l}x_l,\qquad d_j \le s_j \le u_j \qquad \forall j.
\]
This is a genuine demand-bin-packing model: demands are not individual items only, but required multiplicities covered by repeated use of feasible patterns [2509.01218].

The decomposition is classical in spirit but specialized to 2D geometry. The master problem handles demand accounting; the pricing problem generates a new feasible pattern \(a\) maximizing
\[
-1 + \sum_{j=1}^n (\pi_{j,1}-\pi_{j,2}) a_j,
\]
where \(\pi_{j,1}\) and \(\pi_{j,2}\) are dual variables associated with lower and upper demand bounds [2509.01218]. The difficult 2D placement constraints are therefore removed from the master and handled inside pricing. In the reported implementation, pricing is heuristic rather than exact: multiplicities are grown greedily, feasibility is checked with a bottom-left heuristic, several orderings are tried, and all positive reduced-cost columns found are added [2509.01218].

A distinctive feature is the adapted Ryan-Foster branching for multiplicity-rich settings. For a fractional solution, the affinity between item types \(i\) and \(j\) is
\[
\rho_{i,j} := \begin{cases}
\displaystyle \sum_{l=1}^{p'} a_{i,l}\cdot \frac{a_{i,l}-1}{2}\cdot x_l, & i=j,\\[1.2ex]
\displaystyle \sum_{l=1}^{p'} a_{i,l}\cdot a_{j,l}\cdot x_l, & i\ne j.
\end{cases}
\]
Branching then either forbids cohabitation of a pair of types in future patterns or forces at least one joint occurrence via a compound item type [2509.01218]. This is a demand-specific strengthening that does not arise in finite-item formulations.

## 5. Operational enrichments and neighboring variants

Several adjacent literatures enrich 2D packing with operational constraints that are demand-like without introducing demand as a first-class mathematical object. In the two-dimensional non-oriented bin packing problem with due dates, every item must be packed, each bin completes at time \(kP\), and the objective is to minimize
\[
L_{\max}=\max_{i\in N}\{C_i-d_i\},
\qquad C_i = kP \text{ if item } i \text{ is assigned to bin } k.
\]
The paper couples assignment and geometry through an exact MIP, CP-based single-bin feasibility checks, and assignment MIPs guided by dual-feasible-function feasibility constraints, then improves solutions with random local search [1703.07244]. Although the objective is lateness rather than bin minimization, the separation between assignment and per-bin feasibility is directly relevant to demand-oriented extensions.

A logistics-oriented line extends bin packing to heterogeneous bins, item-bin eligibility restrictions, and delivery priorities. In the 2D case, items are orthogonally placed rectangles with optional \(90^\circ\) rotation, continuous coordinates, and relative-position binaries for non-overlap; delivery priority is imposed by fixing selected relative-position variables, and admissible-bin sets \(J_\alpha\) encode item-bin association requirements [2308.02787]. This does not introduce explicit demand variables, order quantities, or service-level penalties, but it captures operational constraints often associated with demand-serving environments.

The broader 2D geometric literature contributes structural tools rather than direct demand models. A randomized multi-start and evolutionary use of the LGFi constructive heuristic show how permutation search can exploit order sensitivity in oriented 2D bin packing under free guillotine cutting [1209.0880]. A primal decomposition based on area-only assignment decisions, exact 2D feasibility checks, and no-good cuts demonstrates how geometry can be deferred to subproblems in exact algorithms [1909.06835]. For skewed instances, shelf, container, and compartment decompositions lead to a \(4/3\)-style guillotine bound and an APTAS, illustrating how thin-item structure collapses geometric complexity into bounded pattern spaces [2105.02827]. These results are not demand formulations, but they are structurally important because demand-oriented geometric models often reuse the same shelf, configuration, and decomposition ideas.

## 6. Heuristics, learning-based methods, and current frontiers

Machine-learning approaches have so far treated demand mostly as an expanded finite batch rather than as a separate modeling layer. One deep reinforcement learning formulation takes a fixed offline set of rectangular objects, learns the packing order with a modified Pointer Network, and places items deterministically through a 2D height map. In the 2D experiments, there are 40 objects per instance, identical \(10\times 10\) bins, no described rotation in the 2D formulation, and the reported mean number of used boxes improves slightly over BRKGA, from \(4.212\) to \(4.203\), while latency drops from \(832.715\) ms to \(0.764\) ms per instance [2403.12420]. This is best interpreted as a learned heuristic for a fixed known order list in which each demanded item has multiplicity one.

A different line studies online and semi-online single-bin utilization maximization with repacking. A hierarchical framework combines heuristic tree search for item choice, order, and orientation with an RL policy for placement position, and in \(10\times 10\) bins reaches near-perfect or perfect utilization on the reported 100% sets once repacking is enabled [2506.01628]. This is highly relevant to incremental demand arrival, but it optimizes fill in a currently open bin rather than minimizing the number of bins.

LLM-guided heuristic generation has also been evaluated on standard 2D-BPP, using an evaluator that scores generated scripts by number of bins, utilization, and runtime, with island-based selection over six iterations [2509.22255]. The paper is explicit that it does not model item demand quantities or customer demand fulfillment. A plausible implication is that such frameworks are reusable for demand-aware problems only after the evaluator is rewritten around multiplicity, fulfillment, or service constraints.

Across these strands, three open issues recur. First, the phrase “2D demand bin packing” remains model-dependent: it may mean timeline-capacity demand overlap, 2-dimensional vector packing, or geometric pattern selection with multiplicities. Second, the general timeline-capacity model still has a gap between its factor-2 hardness barrier and its current 3-approximation [2508.13347]. Third, in geometric demand models, the most natural exact framework is pattern-based branch-and-price, but the reported pricing is heuristic and the LP relaxation can lose the layout-count component of the objective [2509.01218]. These points suggest that the field is converging on a shared set of tools—structured solutions, configuration or pattern spaces, feasibility surrogates, and decomposition—without yet converging on a single universal definition of the problem itself.

Source: https://www.emergentmind.com/topics/2d-demand-bin-packing