Engineering
Engineering, 25.04.2020 05:06, Savannahh8503

Write a Matlab program that finds numerically all the roots (or the zeros) of the algebraic equation below in the interval 1.0 <=x<=3.0: sqrt(log(x^2+1))=x^2*sin(e^x)+2Part a) Prompt the user to enter a positive integer number n, defined the range 2<=n<=15, and then verify if the number entered lies within the specifications. Your program must allow the user to reenter the number without the need to rerun the program. Part b) Create a user-defined function for the bisection method(see details below). Inside the user-defined function, use the built-in Matlab inline function command (see Lecture Part #3 on Blackboard) to define a function (f(x)) corresponding to the difference between the two sides of the above algebraic equation:f(x)=sqrt(log(x^2+1)) -x^2*sin(e^x)-2Part c) Determine ALL the roots(or zeros) of the above-defined equation using the BISECTION METHOD (see details below)with a precision better than 10-n, where n is the number provided by the user by searching the roots using the bisection function in the interval [1,3] at interval steps of 0.2.Part d) A plot displaying the function corresponding to the difference between the two sides of the above-defined algebraic equation. The x-axis MUST be defined in the range [1,3 ]and the plot MUST have 1000 evenly spaced points. Label the x-axis and y-axis and add a title to the plot. Display inside the function plot all the roots determined from the bisection method. THE BISECTION METHOD: approximates a root of a function (named f(x)) on an interval containing the root. Assume that xL and xR is an interval [xL, xR] where the function has one root. Assume also that function f(x)is continuous in the interval. If the interval is bisected by computing its midpoint, xM, XM=(XL+XR)/2then, three possible situations may occur:1.f(xM)=0, then xM is the root of the function;2.the root is in the left half of the interval [xL, xM];3.the root is in the right half of the interval [xM, xR];f f(xM)≠ 0, then the interval (left half or right half) where the root is located is bisected again. This process is repeated until |f(xM)|<10-n, returning as the root of the function the last calculated xM.

answer
Answers: 1

Other questions on the subject: Engineering

image
Engineering, 04.07.2019 18:10, mm016281
What difference(s) did you notice using a pneumatic circuit over hydraulic circuit. explain why the pneumatic piston stumbles when it hits an obstacle.
Answers: 2
image
Engineering, 04.07.2019 18:20, 1230bering
Select any two (2) areas of applications of chain-drive. (clo4) a)-permanent lubrication necessary b)-hydraulic forklift truck operation c)-rigging and heavy moving materials d)-relatively high maintenance costs e)-costlier than belt drives
Answers: 2
image
Engineering, 04.07.2019 18:20, AnonymousLizard52303
A2-m rigid tank initially contains saturated water vapor at 100 kpa. the tank is connected to a supply line through a valve. steam is flowing in the supply line at 600 kpa and 300 c. the valve is opened, and steam is allowed to enter the tank until the pressure in the tank reaches the line pressure, at which point the valve is closed. a thermometer placed in the tank indicates that the temperature at the final state is 200°c. determine (a) the mass of steam that has entered the tank (b) the amount of heat transfer.
Answers: 3
image
Engineering, 04.07.2019 19:10, nani3906
Starting wih an energy balance on a rectangular volume element, derive the one- dimensional transient heat conduction equation for a plane wall with constant thermal conductivity and no heat generation.
Answers: 1
Do you know the correct answer?
Write a Matlab program that finds numerically all the roots (or the zeros) of the algebraic equation...

Questions in other subjects:

Konu
Mathematics, 23.07.2020 03:01
Konu
History, 23.07.2020 03:01
Konu
Mathematics, 23.07.2020 03:01