Plane Stress and Rotation

ES 302 Assignment 3

Using Matlab, set up a computer program as described in Problem 6.C1, on page 407 in Beer and Johnston Mechanics of Materials, second edition. However, only work Problem 6.4 which you did for homework. Use mnemonic symbols such as sigx, sigy, tauxy, and theta. Use an input statement to get the above four values:

    sigx = input(' SigmaX: ');

Don't forget to convert your input angle from degrees to radians. Since cos(2*theta) and sin(2*theta) are used more than once, equate these expressions new symbols such as cos2 and sin2.

Print out the rotation angle on one line and then make a table to show the three original stresses and the rotated stresses for Problem 6.4.

As usual, put your name, date, and subject in the program with lines such as:

    % print the results
     fprintf('\n   Plane Stress')
     fprintf('\n   Your name, ES 302, ')
     disp(date)
When the program is running properly, surround it with a while loop so you can easily use it for another problem:
      contin = 'y';
      while (contin(1) == 'y')
at the top, and
        contin=input(' Another problem? ','s');
      end
at the bottom. Notice the this input statement is different than the previous ones. It has an s argument because now you are reading a string variable. Furthermore, contin(1) only selects the first letter so you can enter either y or yes. The output should look like this:
   Plane Stress Rotation
   Your name, ES 302, 29-Oct-1998

     Rotation angle 150.0 degrees

             Sigma X   Sigma Y  Tau XY
               Ksi       Ksi     Ksi
 Original     -6.00     12.00    9.00
 Rotated      ...       ...       ...
Copy the output from Matlab and paste it into the bottom of your Matlab program. Attach the regular solution to Problem 6.4 that you previously turned in.

Home, index -- ES Problems -- Matlab Help -- Axial Problem -- Torsion Problem -- Mohr's Circle -- Search

Last revised: March 17, 2000