Answered step by step
Verified Expert Solution
Question
1 Approved Answer
double func(x) double x; { double f; f = 1.0-cos(x); return f; } double gunc(x) double x; { double s, g; s = sin(0.5*x); g
double func(x) double x; { double f; f = 1.0-cos(x); return f; } double gunc(x) double x; { double s, g; s = sin(0.5*x); g = 2.0*s*s; return g; }4. For the three numbers a = X + b = TT = 10-9 evaluate analytically the relative error ed on the three numerically calculated numbers d = (a + b) + c, d2 = (c+a) +b, and d3 (b + c) + a as a function of x (2= 1) such that = = = = = = di d1(1 + Edi) d* d2(1 + Ed2) d* d3(1 + Ed3) You should take into account that a* a(1+Ea), b* = 5(1+Eb), c* = c(1+c) with Ea,b,c being the magnitude of the machine error eo. The value e is given by ln e = 1. , 5. Modify the code to investigate and validate the result from question 4 for -1
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started