Also known as rucksack problem, backpack problem
problem in combinatorial optimization
via Wikidata · CC0
~38 min read
Example of a one-dimensional (constraint) knapsack problem: which books should be chosen to maximize the books' value while still keeping the overall weight under or equal to 15 kg? A multiple constrained problem could consider both the weight and volume of the books. (Solution: if any number of each book is available, then three yellow books and three grey books; if only the shown books are available, then all except for the green book.)
The knapsack problem is the following problem in combinatorial optimization:
via Wikidata sitelinks · CC0
Discovered by embedding cosine similarity (sentence-transformers MiniLM, 384-dim).