The cost of manufacturing x number of pencils is given by: C = x^2 + 3x + 13
If each pencil is sold for $5, maximize the profit.
I thought profit was equal to the total amount made and subtract the cost of making them, so: profit = (5x) - (x^2 + 3x + 13) and then I differentiated and set it equal to 0 and found that x = 1 is the best to maximize the profit, but it's wrong. I think I set up the profit equation incorrectly. How do I do this?