Question

5. Write and save a function Sphere Area that accepts Radius as input argument, and returns SurfaceArea (4 tt r) as output ar
9. Test the program. Paste output for radius values of 4 and 0 (what happens here? Why?). 10. Modify your functions so that t
12. Verify your results using >> type sphere.dat and checking a few rows of values (paste the first few rows here). 13. Creat
15. Create a new function Cylvol that accepts both the radius and height of a cylinder as input arguments, and then returns i
17. Open your script file from question #11 above and save it under a new name. In addition to the user prompts for min and m


5. Write and save a function Sphere Area that accepts Radius as input argument, and returns SurfaceArea (4 ar?) as output arg
10. Modify your functions so that they will accept vector input for the radius. Validate your functions from the command line
12. Verify your results using >> type sphere.dat and checking a few rows of values (paste the first few rows here). 13. Creat
Paste code here Paste output for (a) Paste output for (b) 16. Create a function CylArea to calculate the surface area of a cy
Finally, get rid of the earlier statements associated with the data file, and instead simply create a plot of surface-to-volu

Nay programming languge is fine (MatLab, Octave, etc.)

This is the whole document this last picture i sent is the first page
For the following lab exercise, work in groups of 2 to 3 and submit one copy of the completed assignment for each group (list
0 0
Add a comment Improve this question Transcribed image text
Answer #1

Please do understand my concern, as per HOMEWORKLIB RULES we are supposed to answer the first question if there is more than one question in a post, your downvote effects my career a lot, if I get a downvote for a wrong answer or incomplete answer I will accept it. Please give a positive rating

def SphereArea(r ):
return (4*22*r*r)/7
print(SphereArea(5))

Add a comment
Know the answer?
Add Answer to:
Nay programming languge is fine (MatLab, Octave, etc.) This is the whole document this last picture...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • (MATLAB QUESTION) How to modify this function? function [ varargout ] = ellipsoidInfo( varargin ) %...

    (MATLAB QUESTION) How to modify this function? function [ varargout ] = ellipsoidInfo( varargin ) % enter code/comments here end 4.4 Advanced Functions Modify ellipsoidinfo.m, so that the function returns some information about an ellipsoid (or sphere) depending on the user's supplied input and expected output If the user supplies one input, the function will calculate information for a sphere If the user supplies three inputs, the function will calculate information for an ellipsoid. The user would supply the values...

  • Please help! CS Problem Set 5 #Write a function called sphere_data. volume_and_area will #take in a...

    Please help! CS Problem Set 5 #Write a function called sphere_data. volume_and_area will #take in a dictionary. This dictionary is guaranteed to #have exactly one key: "radius", whose value is an integer #representing the radius of a sphere. # #Modify this dictionary to add two keys: "volume" and "area". #The values associated with these keys should be the volume #and surface area of the sphere. # #The formula for volume is: # (4/3) * pi * radius ^ 3 #...

  • Matlab A forus is shaped like a doughnut. If its inner radius isa and its outer...

    Matlab A forus is shaped like a doughnut. If its inner radius isa and its outer radius is b, its volume and surface area are given by V '(a + b(b - a)? A = (b2 - ) a. Create a user-defined function that computes V and A from the arguments a and b. LastName_FirstName_P4_fn_calc. b. Test for values where acb, ab and aub. Use values between 1 and 10 for a and b. Your output should show a, b,...

  • Need help with this Matlab program %% Exercise 1 % NOTE: Please suppress output--i.e., use a...

    Need help with this Matlab program %% Exercise 1 % NOTE: Please suppress output--i.e., use a semicolon ';' at the end of any % commands for which the output is not necessary to answer the question. % Delete these notes before turning in. % Define input variable theta as discretized row vector (i.e., array). theta = ??; % Define radius. r = ??; % Define x and y in terms of theta and r. x = ??; y = ??;...

  • MATLAB Questions. I have a basic understanding of the tools for MATLAB, but do not know...

    MATLAB Questions. I have a basic understanding of the tools for MATLAB, but do not know how to create the code for these questions. Please show the entire code. 2. A paper cup shaped as a frustum of cone with R-14R1 is designed to have a volume of 25 cm Determine R1, R2 and the surface area, S, of the paper for cups with a height, h, of 1O cm. The volume of the cup, V, and the surface area...

  • can anyone help me with the matlab? U Ulube canvas C by Physics for Sci. US...

    can anyone help me with the matlab? U Ulube canvas C by Physics for Sci. US ABC Radio Mall-dantul @ Science News, Art Courses LMS Integration Documentation 202010 EGR 1302.3 > HW05 - MATLAB Functions > Sphere O solutions submitted (max: 3) Write a function named sphereVSA to compute the volume and surface area of a sphere given the radius. The input to your function is a single number thera should output two numbers, first volume, then surface area. These...

  • C++ Chapter 10 defined the class circleType to implement the basic properties of a circle. (Add t...

    C++ Chapter 10 defined the class circleType to implement the basic properties of a circle. (Add the function print to this class to output the radius, area, and circumference of a circle.) Now every cylinder has a base and height, where the base is a circle. Design a class cylinderType that can capture the properties of a cylinder and perform the usual operations on the cylinder. Derive this class from the class circleType designed in chapter 10.   Some of the...

  • All commands must be in the command line. The expense data file is separate. Programming Project...

    All commands must be in the command line. The expense data file is separate. Programming Project #2: Manage Spending Using Commands Objectives: • Understand how to create and manipulate list of objects using array or vector class • Handle input errors and invalid values • Design and create a well-structure program using C++ basic programming constructs and classes. Description: Each “expense” contains 2 values: the spending amount (double) and its description (string) Here is an example of the “expense” data...

  • A group of physics students collected data from a test of the projectile motion problem that...

    A group of physics students collected data from a test of the projectile motion problem that was analyzed in a previous lab exercise (L5). In their test, the students varied the angle and initial velocity Vo at which the projectile was launched, and then measured the resulting time of flight (tright). Note that tright was the dependent variable, while and Vo were independent variables. The results are listed below. (degrees) Time of Flight (s) Initial Velocity V. (m/s) 15 20...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT