|
|
||||||||||||||||||||||||||||||||||||||||
|
1. Linear Interpolation and
Extrapolation |
||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||
|
You have a set of data provided
below: |
||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||
|
a)
Find the f(x) for x = 3.5 using the data above. Find the error. |
||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||
|
b)
Find the f(x) for x = 6.2 using the data above. Find the error. |
||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||
|
c) Find the f(x) for x = 3.5 using the
new data now given. Find the error. |
||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||
|
%Program
to Solve Problem 1 for Linear Curve Fitting Homework %version
2007-10-10 D.W. Donovan clear all; f3p5E =
-15.2006; f6p2E = -14.5306; f3p0 = 3.5875; f4p0 = 5.9518; f5p0 =
-5.1424; f6p0 =
-7.5320; f3p4 =
-14.4274; f3p6 =
-13.6225; f3p51 =
f4p0-((f4p0-f3p0)/(4-3))*(4-3.5) e3p51 =
f3p5E-f3p51 f6p2 =
f6p0+((f6p0-f5p0)/(6-5))*(6.2-6) e6p2 =
f6p2E-f6p2 f3p52 = f3p6-((f3p6-f3p4)/(3.6-3.4))*(3.6-3.5) e3p52 =
f3p5E-f3p52 %{ f3p51
= 4.7697 e3p51 =
-19.9703 f6p2
= -8.0099 e6p2
= -6.5207 f3p52 =
-14.0250 e3p52 =
-1.1756 %} |
||||||||||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||||||||||
|
|