\(\DeclarePairedDelimiterX{\Set}[2]{\{}{\}}{#1 \nonscript\;\delimsize\vert\nonscript\; #2}\) \( \DeclarePairedDelimiter{\set}{\{}{\}}\) \( \DeclarePairedDelimiter{\parens}{\left(}{\right)}\) \(\DeclarePairedDelimiterX{\innerproduct}[1]{\langle}{\rangle}{#1}\) \(\newcommand{\ip}[1]{\innerproduct{#1}}\) \(\newcommand{\bmat}[1]{\left[\hspace{2.0pt}\begin{matrix}#1\end{matrix}\hspace{2.0pt}\right]}\) \(\newcommand{\barray}[1]{\left[\hspace{2.0pt}\begin{matrix}#1\end{matrix}\hspace{2.0pt}\right]}\) \(\newcommand{\mat}[1]{\begin{matrix}#1\end{matrix}}\) \(\newcommand{\pmat}[1]{\begin{pmatrix}#1\end{pmatrix}}\) \(\newcommand{\mathword}[1]{\mathop{\textup{#1}}}\)
Needs:
Bounded Knapsack Problems
Needed by:
None.
Links:
Sheet PDF
Graph PDF
Wikipedia

Change-Making Problems

Why

Suppose a cashier needs to provide $c \in \Z _+$ cents in change, and wants to do so using the using the fewest (or most) number of coins, each worth a different number of cents. We can model this as a problem similar to the bounded knapsack problem, in which we have an equality constraint instead of an inequality one.

Definition

Given $w: \set{1, \dots , n} \to \R _+$, $b \in \Z _+^n$, find $x \in \Z _+^n$ to

\[ \begin{aligned} \text{minimize} & \quad \sum_i x_i \\ \text{subject to} & \quad \sum_{j = 1}^n w_j x_j = c \\ & \quad 0 \leq x \leq b, x \in \Z _{n}^{+} \end{aligned} \]

This problem is often called a change-making problem. Without the budget constraints, it is called an unbounded change-making problem.

Copyright © 2023 The Bourbaki Authors — All rights reserved — Version 13a6779cc About Show the old page view