Skip to content

Partition problem

The problem of dividing a multiset of positive integers into two exhaustive parts with equal sums, or minimizing their sum difference.

Version
v1 · 2026-09-28 · History
Domain-specific #
11217
Domain group
Applied Sciences & Engineering
Origin domain
Computer Science & Software Engineering
Subdomains
Computational Complexity, NP Complete Problems → Computer Science & Software Engineering
Aliases
Number partitioning

Core Idea

The partition problem assigns every occurrence in a multiset of positive integers to one of two sides and asks whether the sums can be equal. Equality is possible only if one side totals half the overall sum. The optimization version always seeks a split, choosing one whose absolute sum difference is minimal.

The problem is NP-complete in its decision form but weakly so: dynamic programming can run in time polynomial in the numeric total, which is pseudo-polynomial relative to binary input length. This explains why many practical instances are manageable. Partition is a half-total subset-sum case and a two-bin number-partitioning case, but should not be conflated with strongly hard 3-partition.

Scope of Application

  • Complexity theory. The problem illustrates weak NP-completeness.
  • Dynamic programming. Reachable subset sums yield pseudo-polynomial solutions.
  • Scheduling and load balance. Two-machine assignments resemble minimum-difference partitioning.
  • Approximation algorithms. Heuristics trade guarantees and speed for large instances.

Clarity

Specify multiset semantics, positivity, decision versus optimization version, integer encoding, item count, total sum, exact or approximate requirement, and tie handling. A claim of polynomial runtime must say whether it is polynomial in input bits or numeric total. Inclusion test: An instance is partition when all multiset items must be assigned to exactly two sides and equality of their sums is the decision target. Exclusion test: Choosing an arbitrary subset for a separately supplied target is subset sum, not partition unless the target is half the total. Nearest boundary: Two-way number partitioning is the same core problem, whereas 3-partition has variable many triples and different strong-hardness behavior. Exit condition: The identity exits when there are more than two bins, cardinality constraints, arbitrary target, nonadditive cost, or unassigned items. Common misclassifications: It is not arbitrary set partition without numeric weights. It is not subset sum with any externally chosen target. It is not 3-partition. It is not multiway partitioning with unrestricted k. Nearest named distinctions: Set partition: Divides a set without necessarily balancing numeric sums. Subset sum: Uses an arbitrary target and need not emphasize the complementary side. 3-partition: Forms many three-item equal-sum groups and is strongly NP-complete. Knapsack: Optimizes value under capacity rather than equal use of all items.

Manages Complexity

A simple equal-sum condition hides an exponential choice space. Additivity permits compact dynamic programming over totals, while large binary-encoded magnitudes restore worst-case difficulty. Complexity depends on representation as much as on the apparent number of items.

Abstract Reasoning

  1. Compute the total and reject exact equality immediately if it is odd.
  2. Set the target to half the total.
  3. Represent reachable subset sums by dynamic programming or another exact method.
  4. Recover a target subset and place all remaining occurrences on the other side.
  5. For optimization, locate the reachable sum nearest half the total.
  6. Verify exhaustive disjoint assignment and compute imbalance.
  7. Report optimality or approximation guarantee and resource dependence.

Knowledge Transfer

The balancing form transfers to two-way scheduling and load distribution when costs add and every item is assigned once. It stops at multiple bins, vector costs, precedence, or splittable jobs without modifying the model. The cargo is exhaustive two-way additive balance.

Relationships to Other Abstractions

Local relationship map for Partition problemParents appear above the current abstraction, mutual partners to the right, and children below. Node labels state whether each abstraction is prime or domain-specific; colors identify relation types.Partition problemDOMAINDomain-specific abstraction: Matroid-Constrained Number Partitioning — is a kind ofMatroid-Constra…DOMAIN

Current abstraction Partition problem Domain-specific

Foundational — no parent edges in the catalog.

Children (1) — more specific cases that build on this

  • Matroid-Constrained Number Partitioning Domain-specific is a kind of Partition problem

    Matroid-Constrained Number Partitioning is a strict kind of Partition problem: it partitions numbers among subsets while adding matroid-independence constraints.

Neighborhood in Abstraction Space

Partition problem sits in a crowded region of the domain-specific corpus (26th percentile for distinctiveness): several abstractions share nearly its structure, so a description that fits it tends to fit its neighbors too.

Family — Combinatorial Optimization & Game Problems (12 abstractions)

Nearest neighbors

Computed from structural-signature embeddings · 2026-10-08