User:Eml4500.f08.wiki1.schaet/hw7

Image for section 35-2

Images from lecture 37:







Two Bar Frame using MATLAB analysis
The following depicts the two bar system to be analyzed using MATLAB. It is very similar to the 2-bar system analyzed in Homework 3 except for this system is a frame system rather than a simple truss system. Here, Element 1 is a frame element with a square cross-sectional area and Element 2 is a truss system.



Since the frame element is assumed to be sqaure, the values for the moment of inertia were calculated by using the equation $$ I=\frac{s_{1}s_{2}^{3}}{12} $$ where the s-values are the sides of the square and thus $$s_{1}=s_{2}$$. These values along with the values given in the problem are stated in the following table. P is known to be 7.

Matlab Code
Below is the matlab code used to obtain the comparison between the undeformed 2 bar truss, the 2 bar truss system (determined in homework 3), and the combined frame/truss system explained above.

 "2 Bar Truss/Frame Comparison Matlab Code"

Below is the matlab code for the m-file PlaneFrameElement.m as given in the companion for the textbook. This file obtains the K matrix and R matrix. The one given in the book is for an element with a distributed load. Plugging in zeros for these values simplifies the distributed load to the one point load we have in this problem. These lines of code could have been removed but were left in to keep it simple. PlaneFrameElement.m Matlab Code

Below is the matlab code used to obtain the results for shear, bending moment, and axial forces. It is important to note that while this file is similar to the books companion site, some changes were made. One of the changes was to increase the number of increments along the frame element from 3 points in the book (i = 0:L/2:) to 16 points in our code (i=0:L/15:L). This gives us more points along the element to analyze so that the curve is more accurate. Other changes were just simple definition changes. Instead of using the word 'inertia', it is defined as I. Similarly, the word 'modulus' was replaced with E.  This serves just to simplify the code.  Modified PlaneFrameResults.m Matlab Code

Below are the results obtained. Note too that we also have the reaction forces as defined by rf. The shear, bending moment, and axial forces are much larger matricies because they are the results at each of the points along element 1 as defined by (i = 0:L/15:L).  Results

Below is the image obtained by the code. The undeformed system is the dotted blue line. The deformed truss system is the green line. These are the same as obtained in HW3. The red line shows the deformations for the frame/truss system given in this homework. As you can see, for the frame system, the angle at node 1 does not change significantly. This is due to the change in the type of connection at that node. Instead, there is a sort of wavy motion going up to node 2. This is due to the added degree of freedom and moments at each node. There is also a close up view to see these differences.