Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Procedure Write a MATLAB code to: 1-plot the graph of the function f(x)=f(x) = x + 4x - 10 = 0. Plot the function

Procedure Write a MATLAB code to: 1-plot the graph of the function f(x)=f(x) = x + 4x - 10 = 0. Plot the function in the interval [0,5]. 2.Find a root of the function using x1=1. Perform the iterations of the Newton-Raphson method. Solution: 1 2 3 4 5- 6 789GAG ROOT FINDING USING NEWTON-RAPHSON METHOD 10 11 - 12- 13- 14 15 16 17 18 19 20 21 clear clc first step: plot the function x=0:0.05:4; f=@ (x) (x.^3) + (4* (x.^2)) -10; plot (x, f(x)); grid % Second step: Compute the value of x root fd=@ (x) (3* (x.^2)) + (8*x); x1=1; tol=0.0001; n = 0; while abs (f (x1)) > tol fl=f(x1); f1d=fd (x1); x2=x1-(f1/fld); f2=f(x2); x1=x2; n = n + 1; fprintf('%9.6f %13.6f %13.6f ', n, x2, f2) end 3- Repeat steps 1 and 2 using the function of derivative in MATLAB (diff).

Step by Step Solution

3.48 Rating (151 Votes )

There are 3 Steps involved in it

Step: 1

MATLAB CODE To plot the graph for the following newton raphson method CODING ... blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Calculus

Authors: Dale Varberg, Edwin J. Purcell, Steven E. Rigdon

9th edition

131429248, 978-0131429246

More Books

Students also viewed these Computer Engineering questions