Hello, dear friend, you can consult us at any time if you have any questions, add WeChat: daixieit

Homework II

2023-09-29

This homework covers material from module 1 &2 (linear algebra and matrices), modules 3 & 4 (continuity and derivatives). You will explore the following functions in R:

•  matrices

•  functions

• optimize

• plotting

Question 1

The demand for products x1  and x2  follows the following function:

200 = −3x1  + 7x2

The supply for products x1  and x2  follows the following function:

400 = 5x1 − 10x2

1 - a) Enter matrices of demand and supply for products x1  and x2 .  Print the two matrices.

1 - b) How many solutions does this system have? Please use “Solve” to obtain solution to this linear system.

1 - c) Illustrate the solution(s) or no-solution on a plot. You have to include axes titles for x and y and the two equations have to be represented by different colors.

##  [1]  "#1-a"

##  [1]  "#1-b"

##  [1]  "#1-c"

Question 2

The production function for product x1  is the following:

x1  = 1000 x2 4 * x3

The production function for product x2  is the following:

x2  = 1000 x1 2 * x3

The production function for product x3  is the following:

x3  = 500 − 3 * x1

2 - a) Enter the three equations as functions using “functions”. Please print those functions. 2 - b) Enter matrices of the production system. Please print the matrices.

2 - c) How many solutions does this system have?  If it exists more than one solution, what is/are the solutions?

##  [1]  "#2-a"

##  [1]  "#2-b"

##  [1]  "#2-c"

Question 3

Find the derivatives of x1  of the following functions:

3 - a)

y = 2 * x1(4)

3 - b)

y = 100 − 2 * x1 + 3 * x2

##  [1]  "#3  -  a"

##  [1]  "#3  -  b"

Question 4

You have to create a plot for each of the equations below. Plots have to include a plot title, axes titles, one or  more red dot indicating the extremums (maximum or minimum), as well as the coordinates of the extremums.

f (x) = cos(x) − (x − 5)2  + 1000

over [0, 10]

4-b) Find the local minimum

f (x) = x5  − 5 * x4 − x + 10

over [0, 8]

##  [1]  "#4  -  a"

##  [1]  "#4  -  b"