Problem

Figure P3.1 shows a cylindrical tank with a conical base. If the liquid level is quite low...

Figure P3.1 shows a cylindrical tank with a conical base. If the liquid level is quite low, in the conical part, the volume is simply the conical volume of liquid. If the liquid level is midrange in the cylindrical part, the total volume of liquid includes the filled conical part and the partially filled cylindrical part.

Use decisional structures to write an M-file to compute the tank's volume as a function of given values of R and d. Design the function so that it returns the volume for all cases

FIGURE P3.1

where the depth is less than 3R. Return an error message (“Overtop”) if you overtop the tank—that is, d > 3R. Test it with the following data:

R

0.9

1.5

1.3

1.3

d

1

1.25

3.8

4.0

Note that the tank's radius is R.

Step-by-Step Solution

Request Professional Solution

Request Solution!

We need at least 10 more requests to produce the solution.

0 / 10 have requested this problem solution

The more requests, the faster the answer.

Request! (Login Required)


All students who have requested the solution will be notified once they are available.
Add your Solution
Textbook Solutions and Answers Search
Solutions For Problems in Chapter 3