Unformatted text preview: i = N X i =1 (1) i +1 i ( x1) i write a code that prints out the value of P N ( x ) for N ∈ { 2 , 4 , 6 , 8 , 10 , 12 , 14 , 16 , 18 , 20 } . Use a pair of nested ‘ DO ’ loops for this purpose. In your code also print out the error in the approximation. Note to do this you can use the Fortran function ‘ ALOG(num) ’ which returns the natural log of the value ‘ num ’. For example if you stored the result of the approximation P N ( num ) in the ‘ REAL ’ variable ‘ tot ’ then PRINT*,ALOG(num)tot would give you a measure of the error. 1...
View
Full Document
 Fall '10
 BROOKS
 Addition, Taylor Series, Integers, Type theory

Click to edit the document details