Before you turn this problem in, make sure everything runs as expected. First, restart the kernel (in the menubar, select Kernel\(\rightarrow\)Restart) and then run all cells (in the menubar, select Cell\(\rightarrow\)Run All).
Make sure you fill in any place that says YOUR CODE HERE or “YOUR ANSWER HERE”, as well as your name and collaborators below:
NAME = ""
COLLABORATORS = ""
Optimal diet#
Foods A and B have 600 and 500 calories, contain 15g and 30g of protein, and cost $1.80 and $2.10 per unit each. Find the minimum cost diet containing at least 3900 calories and at least 150g of protein.
Show a nearby point that does not meet the constraint#
Show one example around your solution that illustrate that the constraints are not met.
suboptimal point#
Show another example where the constraints are met, but the objective is not less less than the solution you found.
When you are done, download a PDF and turn it in on Canvas. Make sure to save your notebook, then run this cell and click on the download link.
%run ~/f23-06623/f23.py
%pdf