Question: Write a matlab scrip for the following THE ALTERNATING HARMONIC SERIES The alternating harmonic series converges to the natural log of 2: y_i_ = 1-2+?4+5-...-In(2)

Write a matlab scrip for the following
 Write a matlab scrip for the following THE ALTERNATING HARMONIC SERIES

THE ALTERNATING HARMONIC SERIES The alternating harmonic series converges to the natural log of 2: y_i_ = 1-2+?4+5-...-In(2) = 0.6931471806 Because of this, we can use the alternating harmonic series to approximate the In(2). But how far out do you have to take the series to get a good approximation of he final answer? We can use a while loop to solve this problem. 1. State the Problem Use a while loop to calculate the members of the alternating harmonic sequence and the value of the series until it converges to values that vary by less than.001. Compare the result to the natural log of 2. 2. Describe the Input and Output Input The description of the alternating harmonic series

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!