Write your own short MATLAB function Pex5 (x,n) returning the value at x of the Taylor...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
Write your own short MATLAB function Pex5 (x,n) returning the value at x of the Taylor polynomial Pn(x) of degree n about a = 0 of the function ln((1 + x)/(1 − x)) (see formula (3.12) on p. 25 of the class notes). Print your code and give 15 significant digits of the value P13 (0.2) =Pex5 (0.2,13) that your code obtains. Print also the absolute error |In(1.5) - P13 (0.2)| expressed in MATLAB by Hints: • To minimize the number of multiplications when n ≥ 3 you should use the value t := x². Create a file called Pex5.m and start the file as follows function y-Pex5 (x,n) if (n<=0) y=0; elseif (n<=2) y=2*x; else t=x*x; the rest of your code here abs(log(1.5) - Pex5(0.2, 13)). end Write your own short MATLAB function Pex5 (x,n) returning the value at x of the Taylor polynomial Pn(x) of degree n about a = 0 of the function ln((1 + x)/(1 − x)) (see formula (3.12) on p. 25 of the class notes). Print your code and give 15 significant digits of the value P13 (0.2) =Pex5 (0.2,13) that your code obtains. Print also the absolute error |In(1.5) - P13 (0.2)| expressed in MATLAB by Hints: • To minimize the number of multiplications when n ≥ 3 you should use the value t := x². Create a file called Pex5.m and start the file as follows function y-Pex5 (x,n) if (n<=0) y=0; elseif (n<=2) y=2*x; else t=x*x; the rest of your code here abs(log(1.5) - Pex5(0.2, 13)). end
Expert Answer:
Related Book For
Posted Date:
Students also viewed these accounting questions
-
What is the value at expiration of a call option with a strike price of $65 if the stock price is $1? $50? $65? $100? $1,000?
-
The Taylor polynomial of degree n for Use the Taylor polynomial of degree nine and three-digit chopping arithmetic to find an approximation to e5 by each of the following methods. c. An approximate...
-
a Determine if y is a polynomial function of x of degree less than 5 b If so find an equation for it x 1234567 y 4 7 14 25 40 59 82 x 2 4 6 8 10 12 14 y 6 13 26 45 70 101 138
-
Describe what happens if you put the double quotes in the print statement of HelloWorld.java on different lines, as in this code fragment: System.out.println("Hello, World");
-
The US-Haul Truck Rental firm has accumulated extra trucks at three of its truck leasing outlets, as shown: Leasing Outlet Extra Trucks 1. ...........Atlanta 70 2. ............St. Louis 115 3....
-
An asset was purchased for $ 1 1 0 , 0 0 0 on January 1 , Year 1 , and originally estimated to have a useful life of 9 years with a residual value of $ 8 , 0 0 0 . At the beginning of the third year,...
-
A swaption is an option to enter a swap arrangement in the future. Suppose that company B has a debt of \(\$ 10\) million financed over 6 years at a fixed rate of interest of \(8.64 \%\). Company A...
-
Solvo produces three types of trucks on one assembly line: the long-haul (L), the short-haul (S) and the vocational truck (V). Next month the company has orders for 500 long-haul trucks, 750...
-
Critical values for quick reference during this activity. Confidence level Critical value 0.90 z* = 1.645 0.95 z* = 1.960 0.99 z* = 2.576 469062.3288744.qx3zqy7 Jump to level 1 A poll for a statewide...
-
Ayayai Hotels Ltd. (AHL) is a small boutique hotel that provides 44 suites that can be rented by the day, week, or month. Food service is available through room service as well. In addition, there...
-
A group of chemists is monitoring 20 different locations of a river for its biochemical oxygen demand (BOD). BOD (ppm) 26 88 45 15 16 7 77 19 33 30 50 60 19 80 23 66 55 31 107 17 a. If we consider...
-
Define and distinguish between legal and physical custody.
-
Describe the accounting treatment for a forward exchange contract where there is no hedging relationship.
-
Describe the nature of a parenting plan and indicate how it differs from a more traditional custody provision in a separation agreement.
-
Define and give two examples of requests for production of documents and things.
-
Discuss the disclosures required by AASB 121/IAS 21 with regards to exchange differences, functional currency and the currency used by an entity to present its financial information.
-
Choose a current article from a legitimate news source (Wall Street Journal, New York Times, Washington Post) that speaks about a supply chain issue(s). 1. Discussion length 250 words Minimum 2....
-
Time Travel Publishing was recently organized. The company issued common stock to an attorney who provided legal services worth $25,000 to help organize the corporation. Time Travel also issued...
-
The function is used in population models to give the size of the next generation ((x)) in terms of the current generation (x). (a) What is a reasonable domain for this function, considering what x...
-
Solve the glucose level example (Example 4) using separation of variables. Example 4 Suppose glucose is infused into a patients bloodstream at a constant rate of a grams per minute. At the same time,...
-
In the year 2019, the proportion of U.S. major league baseball players who were foreign born was 251 out of 882. Suppose we begin to randomly select major league players until we find one who is...
-
Plaintiffs purchased stock warrants (rights to purchase) for blocks of Osborne Computer Corp., the manufacturer of the first mass-market portable personal computer. Because of inability to produce a...
-
Lynn Goldsmith is a photographer known for her photographs of famous musicians. In 1981, Goldsmith had a photography session with the singer Prince. Three years later, Vanity Fair obtained a license...
-
Stone Brewing Co. is a San Diego brewer that has sold its beers for over two decades. Stone has maintained its trademark and brand from the beginning, registering the STONE mark in 1998. Stone has...
Study smarter with the SolutionInn App