Question: using MATLAB please :::: formula for the volume of the cylinder is V = pi r ^ 2 * h where r is the radius

using MATLAB please ::::
formula for the volume of the cylinder is
V=pi r^2*h
where r is the radius and is the height of the cylinder. You need to write three functions in Lab7.m
A local function srPrompt to prompt the user for r and .
(No input argument, two returning values)
A local function calcV to calculate the Volume of the cylinder.
(Two input arguments, one returning values)
A local function printV to print the Volume of the cylinder formatted with two decimal
places.
(One input arguments, no returning values)
Note: write the function as the local function in the main script (put the function at the end
of the script).
Second, use proper variables in the main script to call and connect the three functions. The input value of r =5 and the input value of =14, your result should be like below: Problem 2
Enter the radius: 5
Enter the height of the cylinder: 14
The volume of the cylinder is: 1099.56 Using MATLAB please. thank you

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!