C++ for Engineers and Scientists
C++ for Engineers and Scientists
4th Edition
ISBN: 9781133187844
Author: Bronson, Gary J.
Publisher: Course Technology Ptr
bartleby

Videos

Textbook Question
Book Icon
Chapter 5.7, Problem 6E

(Numerical analysis) Here’s a challenging problem for those who know a little calculus. The Newton-Raphson method can be used to find the roots of any equation y ( x )   =   0. In this method, the ( i   +   1 ) s t   a p p r o x i m a t i o n ,   x i + 1 ,   t o   a   r o o t   o f   y ( x )   =   0 is given in terms of the ith approximation, xi, by the following formula, where y’ denotes the derivative of y(x) with respect to x:

x i + 1 = x i y ( x i ) / y ' ( x i )

For example, if y ( x )   =   3 x 2   +   2 x     2 ,   t h e n   y ( x )   =   6 x   +   2 , and the roots are found by making a reasonable guess for a first approximation x1 and iterating by using this equation:

x i + 1 = x i ( 3 x i 2 + 2 x i 2 ) / ( 6 x i + 2 )

a. Using the Newton-Raphson method, find the two roots of the equation 3 x 2   +   2 x     2   =   0. (Hint: There’s one positive root and one negative root.)

b. Extend the program written for Exercise 6a so that it finds the roots of any function y ( x )   =   0 , when the function for y(x) and the derivative of y(x) are placed in the code.

Blurred answer
Students have asked these similar questions
Find the error, assume data is a string and all variables have been declared. for ch in data:         if ch.isupper:             num_upper = num_upper + 1         if ch.islower:             num_lower = num_lower + 1         if ch.isdigit:             num_digits = num_digits + 1         if ch.isspace:             num_space = num_space + 1
Find the Error: date_string = input('Enter a date in the format mm/dd/yyyy: ') date_list = date_string.split('-') month_num = int(date_list[0]) day = date_list[1] year = date_list[2] month_name = month_list[month_num - 1] long_date = month_name + ' ' + day + ', ' + year print(long_date)
Find the Error:       full_name = input ('Enter your full name: ')       name = split(full_name)       for string in name:         print(string[0].upper(), sep='', end='')         print('.', sep=' ', end='')

Chapter 5 Solutions

C++ for Engineers and Scientists

Knowledge Booster
Background pattern image
Computer Science
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
SEE MORE QUESTIONS
Recommended textbooks for you
Text book image
C++ for Engineers and Scientists
Computer Science
ISBN:9781133187844
Author:Bronson, Gary J.
Publisher:Course Technology Ptr
Text book image
Operations Research : Applications and Algorithms
Computer Science
ISBN:9780534380588
Author:Wayne L. Winston
Publisher:Brooks Cole
Text book image
C++ Programming: From Problem Analysis to Program...
Computer Science
ISBN:9781337102087
Author:D. S. Malik
Publisher:Cengage Learning
Boolean Algebra - Digital Logic and Logic Families - Industrial Electronics; Author: Ekeeda;https://www.youtube.com/watch?v=u7XnJos-_Hs;License: Standard YouTube License, CC-BY
Boolean Algebra 1 – The Laws of Boolean Algebra; Author: Computer Science;https://www.youtube.com/watch?v=EPJf4owqwdA;License: Standard Youtube License