You have been assigned to a new project at work. The previous engineer had created the following file, which your new boss claims does not work. Debug the program to correct all errors.
These files must be corrected to eliminate any syntax, runtime, formula coding, and formula derivation errors. You may assume that the header comments at the top of the program and all comments throughout the program are correct.
% Problem Slaloming: A ball.is thrown vertically :into
% the air with an initial kinetic energy of 2,500 joules.
% As the ball rises, it gradually loses kinetic energy
% as its potential energy increases. At the top of
% its flight, when its vertical speed goes to zero, all of
% the kinetic energy has been converted into potential energy.
% Assume that no energy is lost to frictional drag, etc.
% How high does the ball rise in units of meters if it has
% a mass of 5 kilograms?
% Input Variables
% KE - Kinetic Energy [J]
% m - Mass of ball [kg]
% Output Variables
% H - Max height of ball [m]
% Other Variables
% g - Acceleration due to gravity {m/s^2]
% Assumptions
% No energy losses due to friction
% g = 9.8 m/s^2
clearscreen
clearworkspace
% Set initial variables
2500 = KE;
m = 5 kg;
gravity = 9.8;
% Calculate height, assuming
% Kinetic Energy = height * mass * -gravity
KE(2500) = H * m * g
Want to see the full answer?
Check out a sample textbook solutionChapter 16 Solutions
Thinking Like an Engineer: An Active Approach, Student Value Edition Plus MyLab Engineering with Pearson eText - Access Card Package (4th Edition)
Additional Engineering Textbook Solutions
Manufacturing Engineering & Technology
Mechanics of Materials, 7th Edition
Thermodynamics: An Engineering Approach
EBK FUNDAMENTALS OF THERMODYNAMICS, ENH
Statics and Mechanics of Materials
Mechanics of Materials (10th Edition)
- Suppose your CFD code can handle nonelementary blocks. Combine as many blocks of Fig. as you can. The only restriction is that in any one block, the number of i-intervals and the number of j-intervals must be constants. Show that you can create a structured grid with only three nonelementary blocks. Renumber all the blocks and indicate how many i- and j-intervals are contained in each block. Add up all the cells and verify that the total number of cells does not change.arrow_forwardLearning Goal: To use equilibrium to calculate the plane state of stress in a rotated coordinate system. In general, the three-dimensional state of stress at a point requires six stress components to be fully described: three normal stresses and three shear stresses (Figure 1). When the external loadings are coplanar, however, the resulting internal stresses can be treated as plane stress and described using a simpler, two-dimensional analysis with just two normal stresses and one shear stress (Figure 2). The third normal stress and two other shear stresses are assumed to be zero. The normal and shear stresses for a state of stress depend on the orientation of the axes. If the stresses are given in one coordinate system (Figure 3), the equivalent stresses in a rotated coordinate system (Figure 4) can be calculated using the equations of static equilibrium. Both sets of stresses describe the same state of stress. The stresses σx′and τx′y′ can be found by considering the free-body…arrow_forwardThe following tools / resources may be useful for you to complete the assignment:a. Chatgpt (You may use it to learn Matlab coding or any other computer language. An example is given here: https://shareg.pt/mXHGne9 ). Please take note that code generated by chatgpt can be directly copied and pasted.b. Matlabi) Useful cheat sheet (https://n.ethz.ch/~marcokre/download/ML-CheatSheet.pdf)ii) Getting started with Matlab (https://matlabacademy.mathworks.com/en/details/gettingstarted )iii) Getting 30-day Matlab trial license (https://www.mathworks.com/campaigns/products/trials.html ) iv) Polyfit (https://www.mathworks.com/help/matlab/ref/polyfit.html )v) Exponential Fit (https://www.mathworks.com/matlabcentral/answers/91159-how-do-i-fit-an-exponential-curve-to-my-data)c. PlotDigitizer (https://plotdigitizer.sourceforge.net/ ) or a free online app that does not requires installation (https://plotdigitizer.com/app )You may use your own engineering judgement to make any assumptions on any…arrow_forward
- JUST DRAW THE SCHEMATIC DIAGRAM. NO NEED TO SOLVE. THANK YOU In Rizal province, one of its power plants has been thoroughly monitored for possible conversion into a wind power plant. A propeller wind turbine is to be used. Survey showed that Rizal Province at a height of 10 meters above the ground has a minimum wind speed of 7.1 miles per hour duringthe month of June and a maximum wind speed of 12.9 miles per hour during the month of January. The minimum temperature is at 75 degree Fahrenheit during the month of January and maximum temperature is at 89 degree Fahrenheit during the month of May. The existing power plant has an output of 54MW. For the proposed wind power, the power coefficient of turbine is 35% and the generator efficiency is 95%. Theimpeller diameter is assumed not to exceed 90m. Determine the following:a. Theoretical Wind Power Outputb. Electrical Power Outputc. Number of turbines to be installedarrow_forward7 Create your own 3 unique problems on the First Law of Thermodynamics/Forms of Energy and Equations of State with detailed Solutions. Include diagrams as much as possiblearrow_forwardRecall the discussion on spacecraft from the chapter opener. The following problems consider a rocket launch from Earth’s surface. The force of gravity on the rocket is given by F(d)=−mk/d2, where m is the mass of the rocket, d is the distance of the rocket from the center of Earth, and k is a constant. 172. As the rocket travels away from Earth’s surface, there is a distance D where the rocket sheds some of its mass, since it no longer needs the excess fuel storage. We can write this function as F(d)=⎨(−m↓1 k / d^2) if d < D (−m↓2 k / d^2) if d ≥ D Is there a D value such that this function is continuous, assuming m1≠m2?arrow_forward
- please write a matlab codearrow_forwardUse MATLAB, please make sure you use the numbers on the picture to make the graph that is also on the pictures. Make an exact copy of that graph and make sure that it runs on MATLAB, please send the code and a screenshot of the graph to show that it works. I need help with this.arrow_forwardMatlab code please or just some stepping stones to help.arrow_forward
- I need a MATLAB code that uses image segmentation to take this photo and single out the weeds in the yard. It also needs to calculate the number of pixels/percentage of the pixels that are in the weeds. Please provide notes in the lines as well so it is easy to follow and understand. Thank you for your help!arrow_forwardNeed help with these Q2. Identify any zero force members. ( there can be more than one ) Member AB Member AJ Member BCBC Member BH Member BJ Member CD Member CG Member CH Member DE Member DF Member DG Member EF Member FG Member GH Member GJ q3. You are asked to find the forces in members GHGH and CGCG using the Method of Sections. Which members should you make a cut through? Member AB Member AJ Member BC Member BH Member BJ Member CD Member CG Member CH Member DE Member DF Member DG Member EF Member FG Member GH Member GJ Q4. Having made a cut through the members in the previous part, you next want to solve for Member GH. Which of the following equilibrium equations is the most efficient? (i.e. which one will allow you to solve for the required member in one equation?) a. ΣFx=0. b. ΣMC=0. c. ΣMH=0. d. ΣFy=0 e ΣMD=0arrow_forwardNewton’s 2nd Law Lab (Modeling friendly lab) Go to the PhET simulation Forces & Motion. https://phet.colorado.edu/sims/html/forcesandmotionbasics/latest/forcesandmotionbasics_en.html Select “Acceleration” Click to show Forces, Sum of Forces, Values, Mass, and Acceleration. There are two experiments for this activity – make sure you include both. Experiment #1: Acceleration vs. Force In this lab you will determine the relationship between acceleration and net force. Choose a mass at the beginning, and keep it constant for this entire experiment. Set the friction to zero. This will make your Applied Force equal to the net force. Record data for five different values of Applied Force. Graph Acceleration vs. Net Force. Graph this in Google sheets(you want a line graph - it should only have one line). Make sure that Applied Force information is used as the x value Make sure that Acceleration information is used as the y value Add a trendline – see what fits best –…arrow_forward
- Elements Of ElectromagneticsMechanical EngineeringISBN:9780190698614Author:Sadiku, Matthew N. O.Publisher:Oxford University PressMechanics of Materials (10th Edition)Mechanical EngineeringISBN:9780134319650Author:Russell C. HibbelerPublisher:PEARSONThermodynamics: An Engineering ApproachMechanical EngineeringISBN:9781259822674Author:Yunus A. Cengel Dr., Michael A. BolesPublisher:McGraw-Hill Education
- Control Systems EngineeringMechanical EngineeringISBN:9781118170519Author:Norman S. NisePublisher:WILEYMechanics of Materials (MindTap Course List)Mechanical EngineeringISBN:9781337093347Author:Barry J. Goodno, James M. GerePublisher:Cengage LearningEngineering Mechanics: StaticsMechanical EngineeringISBN:9781118807330Author:James L. Meriam, L. G. Kraige, J. N. BoltonPublisher:WILEY