Having a complete bipartite graph with parts $A$ and $B$, which is edge-weighted, is there a way to compute a maximum flow such that: 1. Only a constant number $n$ of vertices from $A$ are used. 2. An edge points to each of the vertices in $B$. In essence, which nodes from $A$ and which remaining edges to remove from the complete bipartite graph to get a graph with the desired properties with a maximum possible sum of its weights. [![example][1]][1] In the example above, $n=2$ and $w_1 + w_2 + w_3$ is the maximum sum of weights which satisfies the two constraints. [1]: https://i.sstatic.net/J99l2.png