Problem-Solving Methodologies Matlab Help

Designing new engineering devices and systems requires a variety of problem solving skills. (This variety is what keeps engineering from becoming boring! When solving a problem, it is important to plan your actions ahead of time. You can ‘waste many hours by plunging into the problem without a plan of attack. Here we present a plan of attack, or methodology, for solving engineering problems in general. Because solving engineering problems often requires a computer solution and because the examples and exercises in this text require you to develop a computer solution (using MATLAB), we also discuss a methodology for solving computer problems in particular.

Steps in Engineering Problem Solving

Table 1.7-1 summarizes the methodology that has been tried and tested by the engineering profession for many years. These steps describe a general problem solving procedure. Simplifying the problem sufficiently and applying the appropriate fundamental principles is called modeling, and the resulting mathematical description is called a mathematical model, or just a model. When the modeling is finished, we need to solve the mathematical model to obtain the required answer. If the model is highly detailed, we might need to solve it with a computer program. Most of the examples and exercises in this text require you to develop a computer solution (using MATLAB) to problems for which the model has already been developed. Thus we will not always need to use all the steps shown in Table 1.7-1. More discussion of engineering problem solving can be found in [Eide, 1998]:

Example of Problem Solving

Consider the following simple example of the steps involved in problem solving. Suppose you work for a company that produces packaging. You are told that a new packaging material can protect a package when dropped, provided that the

Table 1.7-1 Steps in engineering problem solving

  1. Understand the purpose of the problem.
  2. Collect the known information. Realize that some of it might later be found unnecessary.
  3. Determine what information you must find.
  4. Simplify the problem only enough to obtain the required information.
    State any assumptions you make.
  5. Draw a sketch and label any necessary variables.
  6. Determine which fundamental principles are applicable.
  7. Thnk generally about your proposed solution approach and consider other approaches before proceeding with the details.
  8. Label each step in the solution process.
  9. If you solve the problem with a program, hand check the results using a simple version of the problem. Checking the dimensions and units and printing the results of intermediate steps in the calculation sequence can uncover mistakes.
  10. Perform a “reality check” on your answer. Does it make sense? Estimate the range of the expected result and compare it with your answer. Do not state the answer with greater precision than is justified by any of the following:
    (a) The precision of the given information.
    (b) The simplifying assumptions.
    (c) The requirements of the problem.
    Interpret the mathematics. If the mathematics produces multiple answers do not discard some of them without considering what they mean. The mathematics might be trying to tell you something, and you might miss an opportunity to discover more about the problem.

package hits the ground at less than 25 ft/sec. The package’s total weight is 20 Ib, and it is rectangular with dimensions of 12 by 12 by 8 in. You must determine whether the packaging material provides enough protection when the package is carried by delivery persons.
The steps in the solution are as follows:

  1. Understand the purpose of the problem. The implication here is that the packaging is intended to protect against being dropped while the delivery person is carrying it. It is not intended to protect against the package falling
    off a moving delivery truck. In practice, you should make sure that the person giving you this assignment is making the same assumption. Poor communication i~the cause of many errors!
  2. Collect the known information. The known information is the package’s weight, dimensions, and maximum allowable impact speed.
  3. Determine what information you must find. Although not explicitly stated, you need to determine the maximum height from which the package can bedropped without damage, You need to find a relationship between the speed of impact and the height at which-the package is dropped,
  4. Simplify the problem only enough to obtain the required information. State any assumptions you make. The following assumptions will simplify the problem and are consistent with the problem statement as we understand it:
    a. The package is dropped from rest with no vertical or horizontal velocity.
    b. The package does not tumble (as it might when dropped from a moving truck). The given dimensions indicate that the package is not thin and thus will not “flutter” as it falls.
    c. The effect of air drag is negligible.
    d. The greatest height the delivery person could drop the package from is 6 ft (and thus we ignore the existence of a delivery person 8 ft tall!).
    e. The acceleration g due to gravity is constant (because the distance dropped is only 6 ft).
  5. Draw a sketch and label any necessary variables. Figure 1.7-1 is a sketch of the situation, showing the height h of the package, its mass m, its speed v and the acceleration due to gravity g.
  6. Determine which fundamental principles are applicable. Because this problem involves a mass in motion, we can apply Newton’s laws. From physics we know that the following relations result from Newton’s laws and the basic kinematics of an object falling a short distance under the influence of gravity, with no air drag or initial velocity:
    a. Height versus time to impact t.: h = ¹/² gt²
    b. Impact speed Vi versus time to impact: Vi =gt¹,
    c. Conservation of mechanical energy: mgh = 1/5mv²

    Figure 1.7-1 Sketch of the dropped package problem.

    Figure 1.7-1 Sketch of the dropped package problem.

  7. Think generally about your proposed solution approach and consider other approaches before proceeding with the details. We could solve the second equation for t, and substitute the result into the first equation to obtain the relation between h and Vi. This approach would also allow us to find the time to drop ti. However, this method involves more work than necessary because we need not find the value of ti. The most efficient approach is to solve the third relation for h.
    Capture 
    Notice that the mass m cancels out of the equation. The mathematics just told us something! It told us that the mass does not affect the relation between the impact speed and the height dropped. Thus we do not need the weight of the package to solve the problem.
  8. Label eac step in the solution process. This problem is so simple that there are only a few steps to label:
    a. Basic principle: conservation of mechanical energy
    Capture
    b. Determine the value of the constant g: 8 =32.2 ft/sec.
    c. Use the given information to perform the ‘calculation and round off the result consistent with the precision of the given information:
    Capture
    Because this text is about MATLAB, we might  as well use it to do this simple calculation. The session looks like this:
    » g = 32 . 2 ;
    » vi = 25 ;
    » h = vi  ” 2 / (2*g)
    h =
    9.7050
  9. Check the dimensions and units. This check proceeds as follows, using
    ( 1.7-1 ),
    Capture
    which is correct.
  10. Perform a reality check and precision check on the answer. If the computed height were negative, we would know that we did something wrong. If it were very large, we might be suspicious. However, the computed height of 9.7 ft does not seem unreasonable.

Table 1.7-2 Steps for developing a computer solution

  1. State the problem concisely.
  2. Specify the data to be used by the program. This is the “input.”
  3. Specify the information to be generated by the program. This is the “output.”
  4. Work through the solution steps by hand or with a calculator; use a simpler set of data if necessary.
  5. Write and run the program.
  6. Check the output of the program with your hand solution.
  7. Run the program with your input data and perform a reality check on the output.
  8. If you will use the program as a general tool in the future, test it by running it for a range of reasonable data values; perform a reality check on the results,

If we had used a more accurate value for g, say g = 32.17, then we would be justified in rounding the result to h = 9.71. However, given the need to be conservative here, we probably should round the answer down to the nearest foot. So we probably should report that the package will not be damaged if it is dropped from a height of less than 9 ft. The mathematics told us that the package mass does not affect the answer. The mathematics did not produce multiple answers here. However, many problems involve the solution of polynomials with more than one root; in such cases we must carefully examine the significance of each.

Steps for Obtaining a Computer Solution

If you use a program such as MATLAB to solve a problem, follow the steps shown in Table 1.7-2. More discussion of modeling and computer solutions can be found in [Starfield, 1990] and [Jayaraman, 1991].

MATLAB is useful for doing numerous complicated calculations and then automatically generating a plot of the results. The following example illustrates the procedure for developing and testing such a program.

Posted on July 14, 2015 in An Overview of MATLAB

Share the Story

Back to Top
Share This