Answered step by step
Verified Expert Solution
Question
1 Approved Answer
You are designing a spherical tank (see figure below) of radius R-3m, to hold water for a small village in a developing country The volume
You are designing a spherical tank (see figure below) of radius R-3m, to hold water for a small village in a developing country The volume of liquid it can hold can be computed as 3R - h 3 Where h is the depth of the water and V is the volume of water Write a function that uses the Newton-Raphson method to calculate the root and number of iterations to obtain the root. Your function should accept the function f, derivative function df, initial guess x, and the precision as inputs. A. function [root, iter]newraph(f,df,xi, precision) write an m-file that uses the function from part A to determine the depth that the tank must be filled to so that it holds 30m3 of water. Prompt the user for the initial guess of xi. Use a precision of 1e-4. Your m-file should plot the function fand derivative function df. Also, mark the roots with a blue upward triangle. B
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started