Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

By using Matlab 1. The Taylor's series expansion of cos(x) is 4 cos(x)-1-2, +?--+-..DX 2n (2n)! where x is in radians. Write a user-defined function

By using Matlab
image text in transcribed
1. The Taylor's series expansion of cos(x) is 4 cos(x)-1-2, +?--+-..DX 2n (2n)! where x is in radians. Write a user-defined function that determines cos(x) using Taylor's series expansion. For function name and arguments use yecosTaylor(x), where the input argument x is the angle in degrees and the output argument y is the value for cos(x). In the program use a loop for adding the terms of the Taylor's series. If an is the nth term in the series, then the sum Sn of the n terms is Sn Sn1tan. In each pass, calculate the estimated error E given by the equation: SnSn-1 n-1 Stop adding terms when E s 0.000001. Use cosTaylor for calculating a) cos(60) b) cos(110)

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

Knowledge Discovery In Databases

Authors: Gregory Piatetsky-Shapiro, William Frawley

1st Edition

0262660709, 978-0262660709

More Books

Students also viewed these Databases questions

Question

6. Have you used solid reasoning in your argument?

Answered: 1 week ago