Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

2. Consider interpolating the data (x0,yo), . . . , (x64%) given by Xi | 0.1 | 0.15 | 0.2 | 0.3 | 0.35 |

image text in transcribed

2. Consider interpolating the data (x0,yo), . . . , (x64%) given by Xi | 0.1 | 0.15 | 0.2 | 0.3 | 0.35 | 0.5 | 0.75 yi 4.0 1.0 1.22.12.02.52.5 For all tasks below, please submit your MATLAB code and your plots. You can write all code in a single (a) Using MATLAB, plot the interpolating (6th degree) polynomial given these data on the domain .m-file [0.1,0.75] using the polyfit and polyval commands. To learn how to use these routines type help polyfit and help polyval in MATLAB.) Also show the abscissae on your plot (b) Now we will explore the sensitivity of the interpolant to perturbations in the data. Replace the point (0.3,2.1) with the point (0.3,3.1). Plot the new interpolating polynomial on the same figure Use different line styles and/or colors and label your curves (c) How much did the interpolating polynomial change at x-0.7? (d) 5 Using MaTLAB's pchip command, perform the interpolation using a piecewise cubic Hermite polynomial on the original and modified data sets. Plot both curves in a new figure. Compare the results with the plots from part (b). What do you observe? Are the piecewise cubic Hermite interpolants purely local or are there still global effects? Note: The pchip command does not take in derivatives; it uses a slightly different version of Hermite interpolation, but the general idea is the same (see help pchip) (e) Using MATLAB's spline command, perform the interpolation using a cubic spline on the original and modified data sets. Plot both curves in a new figure. Compare the results with the plots from parts (b) and (d). What do you observe? Are the cubic splines purely local or are there still global effects

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Mastering Big Data Interview 751 Comprehensive Questions And Expert Answers

Authors: Mr Bhanu Pratap Mahato

1st Edition

B0CLNT3NVD, 979-8865047216

More Books

Students also viewed these Databases questions

Question

What do you think the most important job of a sales manager is ?

Answered: 1 week ago