Newton-Raphson Method | Numerical Computing in Python

  Рет қаралды 59,641

mechtutor com

mechtutor com

4 жыл бұрын

Here's my NumPy mini-course for an 80% discount. Use coupon code: NUMPY80 at rb.gy/pk99l ... I hope you'll find it useful.
Theory and coding of Newton-Raphson method to solve a nonlinear equation.
** For the full course, visit: www.udemy.com/course/programm...
Visit my new Python course webpage: mechtutor.thinkific.com/cours...

Пікірлер: 29
@mechtutorcom
@mechtutorcom 11 ай бұрын
If you are interested, here's a free NumPy mini-course link: rb.gy/pk99l ... I hope you'll find it useful.
@MathPhysicsFunwithGus
@MathPhysicsFunwithGus 3 жыл бұрын
Amazing video thank you helped me so much in my computational class!
@souadmassi7683
@souadmassi7683 4 жыл бұрын
It is a long time, welcome again on KZfaq. Please, make more videos on Matlab
@AJ-et3vf
@AJ-et3vf 2 жыл бұрын
Awesome video sir! Thank you!
@SS-zq5sc
@SS-zq5sc Жыл бұрын
thank you very much that was so helpful and well explained.
@ascorbic_b
@ascorbic_b Жыл бұрын
You are the best man in the world. I spent one week for doing this shit. I love so much. Thank you
@amirahsalsabila7782
@amirahsalsabila7782 3 жыл бұрын
Terimakasih bapak
@googlegoogle1610
@googlegoogle1610 2 жыл бұрын
the best explanation ever :)
@amalabdallah568
@amalabdallah568 3 жыл бұрын
That was really useful 🧡👍🏼
@dellpi3911
@dellpi3911 3 жыл бұрын
kzfaq.info/get/bejne/od6Wp7h50J2ydJ8.html
@fairouzbadis7975
@fairouzbadis7975 4 жыл бұрын
YOU SAVED ME
@juliomurillo1850
@juliomurillo1850 4 жыл бұрын
Dear mechtutor, I would like to apply the same code, but for a list of elements, It means my initial values are X0 = {1,2,3,4,5,6} and my functions give me a result for each of these initial values it means f = f(x0), same my derivative f'=f'(x0). So as you see at the end I will get a list of values. Do you think is possible?
@AJ-et3vf
@AJ-et3vf 2 жыл бұрын
Yes, it is possible. You will have to modify your code such that if a list of values were given, the code would loop through the values given. You would also need to allocate for another list/array where you would store the roots that were found. Your use case is interesting, but most root-solver codes don't have a "vectorized" implementation as the one you're asking. They only take one input guess at a time. So if you want to find the root for a given initial values, just put the Newton solver function inside a loop that loops through your given initial values.
@bidhayakgoswami2564
@bidhayakgoswami2564 3 жыл бұрын
Once I wrote this function to find the zero of any continuous and differentiable function def newton(fun,y): #A function_name and an initial guess is provided as arguments of the function 'newton' n=len(y);epsilon=10**(-12); e=np.eye(n)*epsilon; fval=fun(y);i=1 while (np.linalg.norm(fval))>1e-10 and i
@ccuuttww
@ccuuttww 3 жыл бұрын
how do u add the bee sound every time u run the program
@alvarocarrillo4410
@alvarocarrillo4410 4 жыл бұрын
How can I do it but for the unreal roots?
@mechtutorcom
@mechtutorcom 4 жыл бұрын
Because this method works only in the real domain, you cannot use it for complex roots. The alternative way is to use the function Scipy.optimize.fsolve() Thanks for your comment.
@fahadtufailsahib
@fahadtufailsahib Жыл бұрын
How to solve an equation with logx
@biswarajpalit
@biswarajpalit 4 жыл бұрын
Zoom ur code...really appearing small
@mechtutorcom
@mechtutorcom Жыл бұрын
Hi friends. I have launched a new course. To learn about it, click here please: mechtutor.thinkific.com/courses/python-for-science-and-engineering
@Dusadof
@Dusadof 2 жыл бұрын
What if I have 7 nonlinear equations
@kaasbaas5906
@kaasbaas5906 3 жыл бұрын
any laptopassignment 2 calculusers?
@TPLCompany
@TPLCompany 3 жыл бұрын
did you just like your own comment?
@kaasbaas5906
@kaasbaas5906 3 жыл бұрын
@@TPLCompany i did not, imagine having so little to do in life, till the point where you mock others for doing so
@TPLCompany
@TPLCompany 3 жыл бұрын
@@kaasbaas5906 damn
@ulisesalejandrogutierrezsa8334
@ulisesalejandrogutierrezsa8334 3 жыл бұрын
♥♥♥♥♥♥♥♥♥♥♥♥♥♥
@thshm2938
@thshm2938 Жыл бұрын
import numpy as np from scipy.misc import derivative def f(x): return 2*x**3-9.5*x+7.5 x1 = 2 x = np.linspace(0.2, 2, 500) m = derivative(f, x1, dx=0.1) for n in range(20): xn = x1 -( f(x1) / m) print(xn) x1 = xn
@shardulpingale2431
@shardulpingale2431 Жыл бұрын
def newton_approximation(f,appr): x = sym.Symbol('x') fprime = sym.diff(f,x) f = sym.lambdify(x,f) fprime = sym.lambdify(x,fprime) steps = 0 x = appr for i in range(0,100): new_x = x - (f(x) / fprime(x)) steps+=1 if round(x,8) == round(new_x, 8): break else: x = new_x return new_x, steps x = sym.Symbol('x') f = x**2 - 104 print("Total steps taken in order to approximate the root {0} are {1}".format(*newton_approximation(f,3)))
@shardulpingale2431
@shardulpingale2431 Жыл бұрын
Do not forget to "import sympy as sym"
Как бесплатно замутить iphone 15 pro max
00:59
ЖЕЛЕЗНЫЙ КОРОЛЬ
Рет қаралды 8 МЛН
The Newton-Raphson Method(NEW!!)| ExamSolutions
14:59
ExamSolutions
Рет қаралды 36 М.
Monte Carlo Integration In Python For Noobs
15:32
Andrew Dotson
Рет қаралды 150 М.
Newton-Raphson Formula And Derivation | Part 1 of 2
5:41
Alpha Theta Epsilon
Рет қаралды 68 М.
Finding Zeros of Functions In Python (Bisection Method and Scipy)
15:26
Newton's method for solving nonlinear systems of Algebraic equations
18:37
Fast Inverse Square Root - A Quake III Algorithm
20:08
Nemean
Рет қаралды 5 МЛН
Newton's Method
10:41
The Organic Chemistry Tutor
Рет қаралды 1,1 МЛН