I'm trying to sell the most batches of animals...
Let's say I have 200 dogs, 100 cats, and 100 ferrets.
Person A will give me $10 for a batch of: (1 dog, 1 cat, and 10 ferret).
Person B will give me $10 for a batch of: (1 dog, 20 cats, and 1 ferret).
Person C will give me $10 for a batch of: (20 dogs, 1 cat, and 1 ferret).
For person A, I can sell 10 batches (10 dogs, 10 cats, and 100 ferrets).
For person B, I can sell 5 batches (5 dogs, 100 cats, 5 ferrets).
For person C, I can sell 10 batches (200 dogs, 10 cats, and 10 ferrets).
Meaning, if I sell only to A, I'll get \$100, person B: \$50, person C: \$100.
BUT! I can actually sell more batches i.e. 9 batches to A and 9 batches to C.
If I sell 9 batches to person A (I'll use 9 dogs, 9 cats, and 90 ferrets), then I can also sell 9 batches to person C (using 18 dogs, 9 cats, and 9 ferrets).
I sell A:9 and C:9, I get the best income and most batches sold.
This is probably extremely simple in terms of optimization and a simple matrix, but it's been a while since algebra.
I obviously don't want to try every possible combination and see which gives me the most money.
Question: Assuming that each batch always has the same income, is there a way to find out which combination of batches A/B/C will give the highest yield?
I still suggest watching the tutorial video I linked in the comments to understand how linear programming works. That being said, you can formulate your problem as trying to maximize
$$Profit=10A+10B+10C$$
subject to the constraints on your number of dogs to sell ($A+B+20C \leq 200$), number of cats to sell ($A+20B+C \leq 100$), number of ferrets to sell ($10A+B+C \leq 100$), and that the number of batches sold must be positive ($A\geq0$, $B\geq0$, and $C\geq0$).
Linear programming tells us that the maximum occurs on a point at the endpoints of the polyhedron formed by all of our constraints. Integer programming tells us that the maximum will be an integer point inside the endpoints (if they're not already integers). Thus, we only have to check a few endpoints.
In your case:
$$\begin{aligned} (A,B,C) = (0,0,0)&\text{ yields Profit}=\$0\\ (A,B,C) = (10,0,0)&\text{ yields Profit}=\$100\\ (A,B,C) = (0,5,0)&\text{ yields Profit}=\$50\\ (A,B,C) = (0,0,10)&\text{ yields Profit}=\$100\\ (A,B,C) = (9.5,4.5,0)&\text{ yields Profit}=\$130\\ (A,B,C) = (9.0,0,9.5)&\text{ yields Profit}=\$180\\ (A,B,C) = (0,4.5,9.7)&\text{ yields Profit}=\$130\\ (A,B,C) = (8.7,4.1,9.4)&\text{ yields Profit}=\$210\\ \end{aligned}$$
Therefore, selling 8 batches to person A, 4 batches to person B, and 9 batches to person C will yield \$210, only requiring 192 dogs, 97 cats, and 93 ferrets.