- Generalized assignment problem
In

applied mathematics , the maximum**general assignment problem**is a problem incombinatorial optimization . This problem is ageneralization of theassignment problem in which bothtasks andagents have a size. Moreover, the size of each task might vary from one agent to the other.This problem in its most general form is as follows:

There are a number of agents and a number of tasks. Any agent can be assigned to perform any task, incurring some cost and profit that may vary depending on the agent-task assignment. Moreover, each agent has a budget and the sum of the costs of task assigned to it cannot exceed this budget. It is required to find an assignment in which all agents do not exceed their budget and total profit of the assignment is maximized.

**pecial cases**In the special case in which all the agents' budgets and all tasks' costs are equal to 1, this problem reduces to the

maximum assignment problem . When the costs and profits of all agents-task assignment are equal, this problem reduces to themultiple knapsack problem . If there is a single agent, then, this problem reduces to theKnapsack problem .**Definition**In the following, we have "n" kinds of items, $x\_1$ through $x\_n$ and "m" kinds of bins $b\_1$ through $b\_m$. Each bin $b\_i$ is associated with a budget $w\_i$. For a bin $b\_i$, each item $x\_j$ has a profit $p\_\{ij\}$ and a weight $w\_\{ij\}$. A solution is subset of items "U" and an assignment from "U" to the bins. A feasible solution is a solution in which for each bin $b\_i$ the weights sum of assigned items is at most $w\_i$. The solution's profit is the sum of profits for each item-bin assignment. The goal is to find a maximum profit feasible solution.

Mathematically the generalized assignment problem can be formulated as::maximize $sum\_\{i=1\}^msum\_\{j=1\}^n\; p\_\{ij\}\; x\_\{ij\}.$:subject to $sum\_\{j=1\}^n\; w\_\{ij\}\; x\_\{ij\}\; le\; w\_i\; qquad\; i=1,\; ldots,\; m$;::$sum\_\{i=1\}^m\; x\_\{ij\}\; leq\; 1\; qquad\; j=1,\; ldots,\; n$;::$x\_\{ij\}\; in\; \{0,1\}\; qquad\; i=1,\; ldots,\; m,\; quad\; j=1,\; ldots,\; n$;

The generalized assignment problem is NP-hard, and it is even APX-hard to approximation. Recently it was shown that it is ($e/(e-1)\; -\; epsilon$) hard to approximate for every $epsilon$.

**Greedy approximation algorithm**Using any algorithm ALG $alpha$-approximation algorithm for the knapsack problem, it is possible to construct a ($alpha+1$)-approximation for the generalized assignment problem in a greedy manner using a residual profit concept.The algorithm constructs a schedule in iterations, where during iteration $j$ a tentative selection of items to bin $b\_j$ is selected.The selection for bin $b\_j$ might change as items might be reselected in a later iteration for other bins.The residual profit of an item $x\_i$ for bin $b\_j$ is $p\_\{ij\}$ if $x\_i$ is not selected for any other bin or $p\_\{ij\}$ – $p\_\{ik\}$ if $x\_i$ is selected for bin $b\_k$.

Formally: We use a vector $T$ to indicate the tentative schedule during the algorithm. Specifically, $T\; [i]\; =j$ means the item $x\_i$ is scheduled on bin $b\_j$ and $T\; [i]\; =-1$ means that item $x\_i$ is not scheduled. The residual profit in iteration $j$ is denoted by $P\_j$, where $P\_j\; [i]\; =p\_\{ij\}$ if item $x\_i$ is not scheduled (i.e. $T\; [i]\; =-1$) and $P\_j\; [i]\; =p\_\{ij\}-p\_\{ik\}$ if item $x\_i$ is scheduled on bin $b\_k$ (i.e. $T\; [i]\; =k$).

Formally:: Set $T\; [i]\; =-1$ for all $i\; =\; 1ldots\; n$: For $j=1...m$ do::: Call ALG to find a solution to bin $b\_j$ using the residual profit function $P\_j$. Denote the selected items by $S\_j$.:: Update $T$ using $S\_j$, i.e., $T\; [i]\; =j$ for all $i\; in\; S\_j$.

**ee also***

Assignment problem **References****Further reading*** Katzir Cohen and Raz (2006). [

*http://www.cs.technion.ac.il/~lirank/pubs/2006-IPL-Generalized-Assignment-Problem.pdf "An Efficient Approximation for the Generalized Assignment Problem"*] ,

* Fleischer, Goemans, Mirrokni, and Sviridenko (2006). [*http://www-math.mit.edu/~goemans/ga-soda06.pdf "Tight Approximation Algorithms for Maximum General Assignment Problems"*] ,

* Hans Kellerer and U. Pferschy D. Pisinger (2005). "Knapsack Problems ". Springer Verlag ISBN 3-540-40286-1

*Wikimedia Foundation.
2010.*