Question: An approximate formula for 1- (sin(2x)/2r) is sin(2.r) 2x 1- 2 2 15 4 315 Write a program that, for given a, computes 1-sin(2x)/2r
An approximate formula for 1- (sin(2x)/2r) is sin(2.r) 2x 1- 2 2 15 4 315 Write a program that, for given a, computes 1-sin(2x)/2r using the approximate formula provided above, and then computes the exact value using the math function sin(). The program should read from the keyboard and should report the exact value, the approximation, and the percent relative error between the approximation and the exact value. Recall that percent relative error is computed as |(approx- exact)/exact] 100 For example, the following transaction might take place; Enter x: 1.0 Exact = 0.545351 Approx 0.546032 Error H 0.124783%
Step by Step Solution
There are 3 Steps involved in it
The image youve provided appears to contain a problem statement and an example of how a program shou... View full answer
Get step-by-step solutions from verified subject matter experts
