Problem 1

  1. Find the equation of the regression line for the given points. Round any final values to the nearest hundredth, if necessary. (5.6,8.8), (6.3,12.4), (7,14.8), (7.7,18.2), (8.4,20.8)

The regression line is:
y = 4.257 - 14.8

x <- c(5.6,6.3,7,7.7,8.4)
y <- c(8.8,12.4,14.8,18.2,20.8)
df <- df <- data.frame(x,y)

df_lm <- lm(y~x,data=df)
df_lm
## 
## Call:
## lm(formula = y ~ x, data = df)
## 
## Coefficients:
## (Intercept)            x  
##     -14.800        4.257

Problem 2

Find all local maxima, local minima, and saddle points for the function given below. Write your answer(s) in the form ( x, y, z ). Separate multiple points with a comma.
\(f(x,y) = 24x - 6xy^2 - 8y^3\)

To find the critical we need to find the partial derivatives of f(x,y), set them equal to 0, and solve.
\(f_x(x,y) = 24 - 6y^2\)
\(f_y(x,y) = 12xy - 24y^2\)

Solving \(f_x=0\) we find:
\(f_x(x,y) = 24 - 6y^2 = 0\)
\(24 - 6y^2 = 0\)
\(24 = 6y^2\)
\(4 = y^2\)
\(y = +/- 2\)

Solving \(f_y=0\) we find:
\(f_y(x,y) = -12xy - 24y^2 = 0\)
\(-12xy - 24y^2 = 0\)
\(-12xy = 24y^2\)
\(-12x = 24y\)
\(-x = 2y\)
\(x = -2y\)
We know from before, y = +/- 2, plugging this back in the second equation we find the following critical points: \((-4,2),(4,-2)\)

To find out if the critical points are minimums, maximums or saddle points, we need to get the second derivative functions and plug them into the following: \(D(x,y) = f_{xx}(x,y)f_{yy}(x,y) - [f_{xy}(x,y)]^2\)

Let’s find \(f_{xx}\) and \(f_{yy}\) and \(f_{xy}\):
\(f_{xx} = 0\)
\(f_{yy} = -12x - 48y\)
\(f_{xy} = -12y\)

\(D(x,y) = f_{xx}(x,y)f_{yy}(x,y) - [f_{xy}(x,y)]^2\)
\(D(x,y) = (0)(-12x - 48y) - [(-12y)]^2\)
\(D(x,y) = 12y^2\)

Plugging our critical point (-4,2) into D(x,y) we have: \(D(-4,2) = -12(2)^2 = -48\) This is a saddle point.

The z-value is: \(f(x,y) = 24x - 6xy^2 - 8y^3\)
\(f(-4,2) = 24(-4) - 6(-4)(2)^2 - 8(2)^3\)
\(f(-4,2) = -96 + 96 - 64\)
\(f(-4,2) = -96 + 96 - 64\)
\(f(-4,2) = -64\)

(-4,2,-64)

Plugging our critical point (4,-2) into D(x,y) we have: \(D(4,-2) = -12(-2)^2 = -48\) This is a saddle point.

The z-value is: \(f(x,y) = 24x - 6xy^2 - 8y^3\)
\(f(4,-2) = 24(4) - 6(4)(-2)^2 - 8(-2)^3\)
\(f(4,-2) = 96 - 96 + 64\)
\(f(4,-2) = 96 - 96 + 64\)
\(f(4,-2) = 64\)

(4,-2,64)

We have two saddle points (-4,2,-64),(4,-2,64)

Problem 3

A grocery store sells two brands of a product, the “house” brand and a “name” brand. The manager estimates that if she sells the “house” brand for x dollars and the “name” brand for y dollars, she will be able to sell 81 - 21x + 17y units of the “house” brand and 40 + 11x - 23y units of the “name” brand. Step 1. Find the revenue function R(x,y). \(R = house*x+ name*y)\)
\(R = (81-21x+17y)x + (40 + 11x - 23y)y\)
\(R = (81x-21x^2+17xy) + (40y + 11xy - 23y^2)\)
\(R = 81x +28xy + 40y -21x^2 -23y^2\)

Step 2. What is the revenue if she sells the “house” brand for $2.30 and the “name” brand for $4.10?

x = 2.3
y = 4.1
R = 81*x +28*x*y + 40*y -21*x^2 -23*y^2
paste("The revenue is $",R)
## [1] "The revenue is $ 116.62"

Problem 4

A company has a plant in Los Angeles and a plant in Denver. The firm is committed to produce a total of 96 units of a product each week. The total weekly cost is given by \(C(x,y)= \frac{1}{6}x^2 + \frac{1}{6}y2 +7x+25y+700\) , where x is the number of units produced in Los Angeles and y is the number of units produced in Denver. How many units should be produced in each plant to minimize the total weekly cost?

Our two functions are:
\(\frac{1}{6}x^2 + \frac{1}{6}y2 +7x+25y+700\)
\(x + y = 96\)

Solving for y using the second equation we get:
\(x + y = 96\)
\(y = 96 - x\)

Substituting back into the first equation:
\(\frac{1}{6}x^2 + \frac{1}{6}(96-x)^2 +7x+25(96-x)+700\)
\(\frac{1}{6}x^2 + \frac{1}{6}(9216-192x + x^2) +7x+2400-25x+700\)
\(\frac{1}{6}x^2 + (1536- 32x + \frac{1}{6}x^2) +3100-18x\)
\(\frac{2}{6}x^2 - 50x +4636\)
\(\frac{1}{3}x^2 - 50x +4636\)

The partial derivative is:
\(\frac{2}{3}x - 50\)
\(\frac{2}{3}x - 50 = 0\)
\(\frac{2}{3}x = 50\)
\(2x = 150\)
\(x = 75\)

We can plug that back into our function to find y:
\(x + y = 96\)
\(75 + y = 96\)
\(y = 21\)

(x,y) = (75,21)
The company should produce 75 units in LA and 21 in Denver.

Problem 5

Evaluate the double integral on the given region.
\(\int\int(e^{8x+3y})dA; R:2\le x\le4 and 2\le y\le4\)
Write your answer in exact form without decimals.

\(\int_2^{4}\int_2^{4}(e^{8x+3y})dA\)
\(\int_2^{4}\int_2^{4}e^{8x}e^{3y}dA\)
\((\int_2^{4}e^{8x}dx)(\int_2^{4} e^{3y}dy)\)
\((\frac{1}{8}e^{8x}|_2^4)(\frac{1}{3} e^{3y}|_2^4)\)
\(\frac{1}{8}(e^{32} - e^{16}) \frac{1}{3}(e^{12} - e^{6})\)
\(\frac{1}{24}(e^{44}-e^{38}-e^{28}+e^{22})\)
Which equals..

format(1/24*(exp(44)-exp(38)-exp(28)+exp(22)),scientific=FALSE)
## [1] "534155947497085184"

Resources: