Plot the constant value contours for 𝑒(π‘₯1, π‘₯2), and explain the magnitude of the error at various locations in the context of the problem.

Problem 1: Graphing a bivariate function and its second order approximation
Use R to graph a 3–d plot of the function 𝑓(π‘₯1, π‘₯2) = cos⁑(π‘₯1π‘₯2) and its second order Taylor approximation
β„Ž(π‘₯1, π‘₯2) = 1 βˆ’ πœ‹2
8 π‘₯1

2. Following are the requirements:

i. [1 pt] Write an R function that produces the function 𝑓.

ii. [1 pt] Write an R function that produces the function β„Ž.

iii. [3 pts] Use the functions in (i) and (ii) to plot a 3d graph that contains the surfaces for both 𝑓 and β„Ž on the same frame (axes). Color surface of 𝑓 red and surface of β„Ž blue. The values of π‘₯1 for your graph should range in the interval [βˆ’ πœ‹
4 , β‘πœ‹
4 ] and the values of π‘₯2 must range in the interval [πœ‹
4 , ⁑3πœ‹

4 ]. You may consider dividing each of the intervals by 30 equal points and evaluate the function on the 30 by 30 grid generated, and then make your plot.

iv. [1 pt] Label the first axis π‘₯1and the second axis π‘₯2. Your graph should have the title β€œTaylor approximation of
cos⁑(π‘₯1π‘₯2).” Make sure to show the plot from an angle with a good view of the function.

v. [3 pts] In a separate 3d plot, graph the absolute value error function 𝑒(π‘₯1, π‘₯2) = |𝑓(π‘₯1, π‘₯2) βˆ’ β„Ž(π‘₯1, π‘₯2)|. Use the same range and grid for π‘₯1 and π‘₯2 as described in (iii).

vi. [1 pt] Label the first axis π‘₯1and the second axis π‘₯2. Title your plot β€œThe error in second order Taylor expansion of cos⁑(π‘₯1π‘₯2).”

vii. [3 pts] Plot the constant value contours for 𝑒(π‘₯1, π‘₯2), and explain the magnitude of the error at various locations in the context of the problem.
Problem 2: Given a 𝑝 Γ— 1vector 𝝁 and a 𝑝 Γ— 𝑝 positive definite matrix Ξ£, the pdf for a 𝑝–variate normal density at a point 𝒙 = (π‘₯1, π‘₯2, … , π‘₯𝑝)𝑇can be written as
𝑓(𝒙) = (2πœ‹)βˆ’π‘
2 |Ξ£|βˆ’1/2 exp [βˆ’ 1
2 (𝒙 βˆ’ 𝝁)𝑇 Ξ£βˆ’1(𝒙 βˆ’ 𝝁)] .

Now consider the bivariate normal random variable, where
𝒙 = (π‘₯1
π‘₯2) ,⁑⁑⁑⁑𝝁 = (πœ‡1
πœ‡2) ,⁑⁑⁑⁑⁑⁑Σ = (𝜎11 𝜎12
𝜎21 𝜎22).

(a) [3 pts] Write the second order Taylor expansion for 𝑓(𝒙), for the bivariate normal density, around the point
π’™πŸŽ = (πœ‡1
πœ‡2).

(b) [3 pts] Graph a 3–d plot of the function 𝑓(π‘₯1, π‘₯2) and its second order Taylor expansion for the following parameters (for each set of parameters, f and its approximation should be on the same frame):
(i)⁑⁑⁑𝝁 = (0
0) ,⁑⁑⁑⁑⁑⁑Σ = ( 1 βˆ’0.3
βˆ’0.3 1 ) ⁑;⁑⁑⁑⁑⁑⁑⁑⁑⁑⁑⁑⁑⁑⁑⁑⁑⁑(ii)⁑⁑⁑⁑⁑⁑⁑⁑⁑⁑𝝁 = (0
0) ,⁑⁑⁑⁑⁑⁑Σ = ( 1 0.8
0.8 1 )

Note that the means and variances for each of the variables in the cases (i) and (ii) are 0 and 1 respectively. This should guide you an idea for a reasonable range for π‘₯1 and π‘₯2 to consider for your graphs.

(c) [3 pts] Graph the constant value contours for 𝑓(𝒙) for the cases (i) and (ii) in part

(b). What is the shape of the constant value contours? What is the center of the constant value contours?

(d) [3 pts] Compute the eigenvalues and eigenvectors for each of the covariance matrices 𝛴 given in part (b).
Superimpose the eigenvectors on each of their corresponding constant value contours that you drew in part (c) and explain how the eigenvectors and eigenvalues are related to the constant value contours.

Plot the constant value contours for 𝑒(π‘₯1, π‘₯2), and explain the magnitude of the error at various locations in the context of the problem.

Place your order
(550 words)

Approximate price: $22

Calculate the price of your order

550 words
We'll send you the first draft for approval by September 11, 2018 at 10:52 AM
Total price:
$26
The price is based on these factors:
Academic level
Number of pages
Urgency
Basic features
  • Free title page and bibliography
  • Unlimited revisions
  • Plagiarism-free guarantee
  • Money-back guarantee
  • 24/7 support
On-demand options
  • Writer’s samples
  • Part-by-part delivery
  • Overnight delivery
  • Copies of used sources
  • Expert Proofreading
Paper format
  • 275 words per page
  • 12 pt Arial/Times New Roman
  • Double line spacing
  • Any citation style (APA, MLA, Chicago/Turabian, Harvard)

Our guarantees

Delivering a high-quality product at a reasonable price is not enough anymore.
That’s why we have developed 5 beneficial guarantees that will make your experience with our service enjoyable, easy, and safe.

Money-back guarantee

You have to be 100% sure of the quality of your product to give a money-back guarantee. This describes us perfectly. Make sure that this guarantee is totally transparent.

Read more

Zero-plagiarism guarantee

Each paper is composed from scratch, according to your instructions. It is then checked by our plagiarism-detection software. There is no gap where plagiarism could squeeze in.

Read more

Free-revision policy

Thanks to our free revisions, there is no way for you to be unsatisfied. We will work on your paper until you are completely happy with the result.

Read more

Privacy policy

Your email is safe, as we store it according to international data protection rules. Your bank details are secure, as we use only reliable payment systems.

Read more

Fair-cooperation guarantee

By sending us your money, you buy the service we provide. Check out our terms and conditions if you prefer business talks to be laid out in official language.

Read more