University of Florida/Eml4507/Team7 Report2

Problem 1

edit

Find

edit

Verify the equilibrium of node 2; Explain the assembly process; Using CALFEM verify the results of the 2-D truss system with 2 inclined members [1]

Given

edit
 
Figure 1.1: Free body diagram of node 2 of the 2-D truss system with 2 inclined members


 

Solution

edit
Equilibrium of Node 2
edit

 

(1.1)

 

(1.2)

 

 

(1.3)

 

(1.4)

 

Explanation for the Assembly Process
edit

To assemble the global stiffness matrix for the structure; sum the force-displacement matrices in global coordinates:

 

(1.5)

Substituting for the force displacement matrix for each element:

 

(1.6)

Substituting zero for where there is no stiffness for each element and changing to local coordinates:

 

(1.7)

Summing the matrices:

 

(1.8)

CALFEM for 2-D Truss System
edit

MATLAB script file:

 
Edof=[1 1 2 3 4;
      2 3 4 5 6;];
bc=[1 0;2 0;5 0;6 0;]
f=zeros(6,1);
f(4)=7;
K=zeros(6);
x1=-2*sqrt(3); y1=-2;
x2=0; y2=0;
x3=sqrt(2); y3=-sqrt(2);
A1=1; A2=2;
E1=3; E2=5;
ex1=[x1 x2]; ey1=[y1 y2]; ep1=[E1 A1];
ex2=[x2 x3]; ey2=[y2 y3]; ep2=[E2 A2];

Ke1=bar2e(ex1,ey1,ep1)
Ke2=bar2e(ex2,ey2,ep2)

K=assem(Edof(1,:),K,Ke1);
K=assem(Edof(2,:),K,Ke2)

a=solveq(K,f,bc);

ed1=extract(Edof(1,:),a)
ed2=extract(Edof(2,:),a)

f1=Ke1*ed1'
f2=Ke2*ed2'

MATLAB output:

 
>> r2p1

bc =

     1     0
     2     0
     5     0
     6     0


Ke1 =

    0.5625    0.3248   -0.5625   -0.3248
    0.3248    0.1875   -0.3248   -0.1875
   -0.5625   -0.3248    0.5625    0.3248
   -0.3248   -0.1875    0.3248    0.1875


Ke2 =

    2.5000   -2.5000   -2.5000    2.5000
   -2.5000    2.5000    2.5000   -2.5000
   -2.5000    2.5000    2.5000   -2.5000
    2.5000   -2.5000   -2.5000    2.5000


K =

    0.5625    0.3248   -0.5625   -0.3248         0         0
    0.3248    0.1875   -0.3248   -0.1875         0         0
   -0.5625   -0.3248    3.0625   -2.1752   -2.5000    2.5000
   -0.3248   -0.1875   -2.1752    2.6875    2.5000   -2.5000
         0         0   -2.5000    2.5000    2.5000   -2.5000
         0         0    2.5000   -2.5000   -2.5000    2.5000


ed1 =

         0         0    4.3520    6.1271


ed2 =

    4.3520    6.1271         0         0


f1 =

   -4.4378
   -2.5622
    4.4378
    2.5622


f2 =

   -4.4378
    4.4378
    4.4378
   -4.4378

Problem 2

edit

Find

edit

Homogenous L2-ODE-CC, damping ratio zeta, plot of the solution, log decrement delta, quality factor Q and loss factor eta.

Given

edit

Consider the spring-mass damper system on p.53-2.

  

Initial Conditions:

  

Solution

edit

Case: Underdamped

 
 
 
 

 

 

(2.1)

 

(2.2)


Solving equation (2.1) and (2.2)
 
 

Therefore L2-ODE-CC:  

 

 

(2.3)

 

(2.4)


Using the two initial conditions and solving equation (2.3) and (2.4) the coefficients are as follows:  

Therefore,
 

 

The next step in analyzing the model is comparing and evaluating Log Decrements. This can be done numerically and by a formula. The log decrement in this case was done both ways and then compared to verify the value.
Numerical method:  

The log decrement was calculated by finding the average value:  

Verifying the log decrement value by using the formula:  

Comparing the two values:  

Finding the quality factor :  
 

Finding the loss factor:  
 

Problem 3

edit

Find

edit

Determine the member force and axial stress in each member of the truss shown in the figure using one of the FE analysis programs in the Appendix. Assume that Young’s modulus is 104 psi and all cross-sections are circular with a diameter of 2 in. Compare the results with the exact solutions that are obtained from the free-body diagram.[2]

Write a matlab program to assemble the global stiffness matrix, compute the unknown disp dofs, the reaction forces, the member forces; compare the results with exact hand calculation (Statics, Mechanics of Materials).

Run CALFEM to verify the results, but now do this problem in a different way (as in commercial FE codes).

First, establish 2 arrays: (1) the global node coordinate array “coord”, and (2) the elem connectivity array “conn”. next, write a matlab code to loop over the number of element to call the function “bar2e” of CALFEM to compute the element stiffness matrices. with this method, you let your matlab code construct the arrays ex1, ey1, ex2, ey2, etc. for you, using the info from the arrays “coord” and “conn”.

Given

edit
 
Figure 3.1: Nine Member Truss [3]

Solution

edit
By Hand Calculations
edit

 

(3.1)

 

 

(3.2)

 

 

(3.3)

 

 

(3.4)

 

 

(3.5)

 

 

(3.6)

 


By MATLAB
edit



MATLAB script file:

 
%X= [element number; EA/L; l; m];
X = [1:9; 174.44 218.06 174.44 290.74 174.44 290.74 218.06 218.06 218.06; 0.80 -1.00 -0.80 0.00 -0.80 0.00 1.00 1.00 1.00; 
     0.60 0.00 0.60 1.00 0.60 1.00 0.00 0.00 0.00]
i=1;
for i=1:9
str=fprintf('For element %d\n',i);
k=X(2,i).*[X(3,i)^2 X(3,i)*X(4,i) -(X(3,i)^2) -X(3,i)*X(4,i); X(3,i)*X(4,i) X(4,i)^2 -X(3,i)*X(4,i) -(X(4,i)^2); 
  -(X(3,i)^2)-X(3,i)*X(4,i) X(3,i)^2 X(3,i)*X(4,i); -X(3,i)*X(4,i) -(X(4,i)^2) X(3,i)*X(4,i) X(4,i)^2]
i=i+1;
end



MATLAB output:

>> report2

X =

   1.0000    2.0000    3.0000    4.0000    5.0000    6.0000    7.0000    8.0000    9.0000
 174.4400  218.0600  174.4400  290.7400  174.4400  290.7400  218.0600  218.0600  218.0600
   0.8000   -1.0000   -0.8000         0   -0.8000         0    1.0000    1.0000    1.0000
   0.6000         0    0.6000    1.0000    0.6000    1.0000         0         0         0

For element 1

k =

 111.6416   83.7312 -111.6416  -83.7312
  83.7312   62.7984  -83.7312  -62.7984
-111.6416  -83.7312  111.6416   83.7312
 -83.7312  -62.7984   83.7312   62.7984

For element 2

k =

 218.0600         0 -218.0600         0
        0         0         0         0
-218.0600         0  218.0600         0
        0         0         0         0

For element 3

k =

 111.6416  -83.7312 -111.6416   83.7312
 -83.7312   62.7984   83.7312  -62.7984
-111.6416   83.7312  111.6416  -83.7312
  83.7312  -62.7984  -83.7312   62.7984

For element 4

k =

        0         0         0         0
        0  290.7400         0 -290.7400
        0         0         0         0
        0 -290.7400         0  290.7400

For element 5

k =

 111.6416  -83.7312 -111.6416   83.7312
 -83.7312   62.7984   83.7312  -62.7984
-111.6416   83.7312  111.6416  -83.7312
  83.7312  -62.7984  -83.7312   62.7984

For element 6

k =

        0         0         0         0
        0  290.7400         0 -290.7400
        0         0         0         0
        0 -290.7400         0  290.7400

For element 7

k =

 218.0600         0 -218.0600         0
        0         0         0         0
-218.0600         0  218.0600         0
        0         0         0         0

For element 8

k =

 218.0600         0 -218.0600         0
        0         0         0         0
-218.0600         0  218.0600         0
        0         0         0         0

For element 9

k =

 218.0600         0 -218.0600         0
        0         0         0         0
-218.0600         0  218.0600         0
        0         0         0         0

Problem 4

edit

Part 1

edit

Find

edit

For each case, derive the corresponding standard L2-ODE-CC, find the overall homogeneous solution, and plot the solution in a separate figure; then plot all 3 solutions in the same figure for comparison.

Given

edit

Two Roots:  

Initial conditions y(0)=1, y'(0)=0

Solution

edit

Since \lambda_1 and \lambda_2 are unequal and negative, the system is overdamped. Currently we have:

 

Standard form

 

The standard homogeneous L2-ODE-CC, or the equation of motion, is therefore:

 

The general solution is given by:

 

Using the given initial conditions, we solve for the constants:

 

 

Plugging these in to find the overall homogeneous solution:

 

The graph of the solution is:

 

Part 3

edit

Find

edit

Derive the corresponding standard L2-ODE-CC, find the overall homogeneous solution, and plot the solution in a separate figure; then plot all 3 solutions in the same figure for comparison.

Given

edit

Two roots:  

Initial conditions:

 

Solution

edit

From the characteristic equation:

 

 

Multiplying out to the standard form:

 

 

Where:

 

The standard homogeneous L2-ODE-CC, or the equation of motion, is therefore:

 

The general solution is given by:

 

The variables for this equation are found to be:

 

  rad/s

 

 

Therefore:

 


 


On our honor, we did this assignment on our own, without looking at the solutions in previous semesters or other online solutions.

Problem 5

edit

Find

edit

The general procedure in linear finite element calculations.

Generate element matrices, assemble element matrices into the Global System of equations. Solve the global system of equations and evaluate element forces.

Given

edit
 
Figure 5.1: The figure above consists of a system of three linear elastic springs, and the corresponding finite element model. The system of springs is fixed at the ends and loaded by a single load   [4]

Solution

edit

Using Matlab, we first define the topology matrix by Edof containing element numbers and global degrees of freedom

>> Edof=[1 1 2; 2 2 3; 3 2 3]
    1     1     2
    2     2     3
    3     2     3


Now the global stiffness matrix K   of zeros.

>> K=zeros(3,3)
    0     0     0
    0     0     0
    0     0     0


The load vector   with load   and load it in position 2.

>> f=zeros(3,1); f(2)=100
    0
  100
    0


Stiffness matrices are generated by using the function spring1e
The function is given by:

function [Ke]=spring1e(ep);
k = ep;  
Ke = [ k -k;
     -k  k];

Now we can set the element property as ep for the springs with their respective spring constants   and   Where  


Commands in matlab are as follows:

>> k=1500; ep1=k; ep2=2*k;
>> Ke1=spring1e(ep1)
Ke1 =
       1500       -1500
      -1500        1500
>> Ke2=spring1e(ep2)
Ke2 =
       3000       -3000
      -3000        3000


With the assem function we can assemble stiffness matrices into the global stiffness matrix K. Which leads too:

assem function:

function [K,f]=assem(edof,K,Ke,f,fe)
   [nie,n]=size(edof);
   t=edof(:,2:n);
   for i = 1:nie
     K(t(i,:),t(i,:)) = K(t(i,:),t(i,:))+Ke;
     if nargin==5
        f(t(i,:))=f(t(i,:))+fe;
     end
   end

Stiffness matrix K:

>> K=assem(Edof(1,:),K,Ke2)
K =
       3000       -3000           0
      -3000        3000           0
          0           0           0
>> K=assem(Edof(2,:),K,Ke1)
K =
       3000       -3000           0
      -3000        4500       -1500
          0       -1500        1500
>> K=assem(Edof(3,:),K,Ke2)
K =
       3000       -3000           0
      -3000        7500       -4500
          0       -4500        4500


The Global system of equations is solved with boundary condtions given in bc as well as with function solveq.

Function solveq is as follows:

function [d,Q]=solveq(K,f,bc)
 if nargin==2 ; 
    d=K\f ; 
 elseif nargin==3;
    [nd,nd]=size(K);
    fdof=[1:nd]';
    d=zeros(size(fdof));
    Q=zeros(size(fdof));
    pdof=bc(:,1);
    dp=bc(:,2);
    fdof(pdof)=[];
    s=K(fdof,fdof)\(f(fdof)-K(fdof,pdof)*dp);
    d(pdof)=dp;
    d(fdof)=s;
 end  
    Q=K*d-f;

With Matlab commands it results in:

>> bc=[1 0; 3 0];
>> [a,r]=solveq(K,f,bc)
a =
        0
   0.0133
        0
r =
 -40.0000
        0
 -60.0000


Element forces are now computed from the element displacements. These are obtained from global displacements a using the function extract.

Function extract:

function [ed]=extract(edof,a)
   [nie,n]=size(edof);
   t=edof(:,2:n);
   for i = 1:nie
       ed(i,1:(n-1))=a(t(i,:))';
   end

Now the corresponding Matlab commands are as follows:

>> ed1=extract(Edof(1,:),a)
ed1 =
        0    0.0133
>> ed2=extract(Edof(2,:),a)
ed2 =
   0.0133         0
>> ed3=extract(Edof(3,:),a)
ed3 =
   0.0133         0


The last step is to evaluate the spring forces by using the function spring1s.

We have function spring1s as written below:

function [es]=spring1s(ep,ed)
 k = ep;  
 u=ed;
 es = k*(u(2)-u(1));


We can now finally evaluate the spring forces. Using Matlab the forces are as follows:

>> es1=spring1s(ep2,ed1)
es1 =
   40
>> es2=spring1s(ep1,ed2)
es2 =
  -20
>> es3=spring1s(ep2,ed3)
es3 =
  -40

  • Note: Instructions and commands were all followed from CALFEM 3.4 Manual.

Problem 6

edit

Find

edit

Find the displacements of the three bodies and the forces ( tensile/compressive) in the springs. What are the reactions at the walls? Assume only horizontal translation.

Given

edit
 
Problem 2.6[5]

Solution

edit

The nodes and elements are labeled in the problem. Create a connectivity table.

 
Figure 6.1: Connectivity Table[6]


Construct Elemental equilibrium equations for all 6 elements.

Here is a sample equilibrium equation for element 3:

 

(6.1)

The notation for  : The superscript parenthesis signifies the element number, while the subscript signifies the associated node number.

With element forces calculated, a node equilibrium can be established. Start with a free-body diagram of each node, and then create the five nodal equations:

 
Figure 6.2: Node Equilibrium Equation



Make sure all forces are positive and modeled in tension.

Combine your elemental equilibrium equations with your nodal equilibrium equations for the global stiffness correlation:

 

(6.2)

 

(6.3)





Solving via MATLAB
edit
%Spring constants - in N/mm
k1 = 500;
k2 = 400;
k3 = 600;
k4 = 200;
k5 = 400;
k6 = 300;

%Declaration of Global Displacement Variables
u1 = 0; %due to being at reactions
u2 = 1; %placeholder
u3 = 1; %placeholder
u4 = 1; %placeholder
u5 = 0; %due to being at reactions

%Combining the Nodal equilibrium and the Element Equilibrium, we can find
%the displacements

kglobal =[k1+k4   -k1     -k4     0     0;
           -k1  k1+k2+k3  -k3    -k2    0;
           -k4    -k3   k3+k4+k5 -k5    0;
            0     -k2     -k5 k2+k5+k6 -k6;
            0      0       0    -k6     k6;]

%Rows 1 and 5 can be excluded for now, because the displacements at node 1
%and 5 are zero. This makes the corresponding rows and columns irrelevant

kglobalsimplified = [k1+k2+k3  -k3    -k2;
                     -k3     k3+k4+k5 -k5;
                     -k2       -k5  k2+k5+k6;]
                  
%kglobalsimplified*displacements = External Forces

Fsimplified = [0; %no external force
               1000; %given
               0;]; %no external force
           
Displacementsimplified = kglobalsimplified\Fsimplified %u2, u3, u4

u2 = Displacementsimplified(1)
u3 = Displacementsimplified(2)
u4 = Displacementsimplified(3)

klocal = [1 -1;
          -1 1;]; %Local Equilibrium equations are multiplied by this
      
%Element Equilibrium Equations
k1ef = k1*klocal*[u1;u2]; %k1ef means K1 Element Forces
k2ef = k2*klocal*[u2;u4];
k3ef = k3*klocal*[u2;u3];
k4ef = k4*klocal*[u1;u3];
k5ef = k5*klocal*[u3;u4];
k6ef = k6*klocal*[u4;u5];

%The above matrices are 2x1s
%We need to access the specific values within each matrix
%So we'lll reassign the matrices to new variables

f11 = k1ef(1); %k11 = k(node 1)(element 1)
f21 = k1ef(2);

f22 = k2ef(1); 
f42 = k2ef(2);

f23 = k3ef(1); 
f33 = k3ef(2);

f14 = k4ef(1); 
f34 = k4ef(2);

f35 = k5ef(1); 
f45 = k5ef(2);

f46 = k6ef(1); 
f56 = k6ef(2);

%With our element force variables, we can create the nodal equilibirum eqns
F3 = 1000;

R1 = f11 + f14 %Reaction Force
F2 = f21 + f23 + f22; %unknown force
F3 = f33 + f34 + f35; %Given force
F4 = f42 + f45 + f46; %unknown force
R5 = f56 %Reaction Force

Resulting in the answers (in units mm for the displacements and N for the Reaction):

>> run r26.m

u2 =

    0.8542


u3 =

    1.5521


u4 =

    0.8750


R1 =

 -737.5000


R5 =

 -262.5000
Solving via CALFEM
edit
ep1 = 500; %spring constants
ep2 = 400;
ep3 = 600;
ep4 = 200;
ep5 = 400;
ep6 = 300;

%create element spring stiffness matrix
k1 = spring1e(ep1);
k2 = spring1e(ep2);
k3 = spring1e(ep3);
k4 = spring1e(ep4);
k5 = spring1e(ep5);
k6 = spring1e(ep6);

%define degrees of freedom for each element. All elements have 2 dof.
Edof = [1 1 2; % el1 is element 1
        2 2 4;
        3 2 3;
        4 1 3;
        5 3 4;
        6 4 5;];
fe = zeros(5,1); %declare f, and then populate f with extractions
fe(1) = spring1s(ep1,Edof(1,:));
fe(2) = spring1s(ep2,Edof(2,:));
fe(3) = spring1s(ep3,Edof(3,:));
fe(4) = spring1s(ep4,Edof(4,:));
fe(5) = spring1s(ep5,Edof(5,:));

%Assembling structural stiffness matrix
K = zeros(5);
[K,f] = assem(Edof(1,:),K,k1,f,fe);
[K,f] = assem(Edof(2,:),K,k2,f,fe);%adding element 2 to the structural matrix
[K,f] = assem(Edof(3,:),K,k3,f,fe);%adding element 3 to the structural matrix
[K,f] = assem(Edof(4,:),K,k4,f,fe);
[K,f] = assem(Edof(5,:),K,k5,f,fe);
[K,f] = assem(Edof(6,:),K,k6,f,fe);

a = solveq(K,f); %solves K*a = f

Ed = extract(Edof,a) %extracts element displacements from global 
                      %solution vector a
                      
Ed(3)
Ed(4)
Ed(5)

f(1)
f(5)

Resulting in the answers (in units mm for the displacements and N for the Reaction):

>> run calfem26.m

Ed(3) =

    0.8542


Ed(4) =

    1.5521


Ed(5) =

    0.8750


f(1) =

 -737.5000


f(5) =

 -262.5000

References

edit
  1. https://docs.google.com/document/d/1lQLCUXKTYtMs4BqzLExS5jqLVcpAIP1FW4sd2sl1cqA/edit#
  2. KS 2008 p.103 sec.2.7 pb.21
  3. KS 2008 p.103 sec.2.7 pb.21
  4. http://www.solid.lth.se/fileadmin/hallfasthetslara/utbildning/kurser/FHL064_FEM/calfem34.pdf
  5. KS 2008 p.98 sec.2.7 pb.21
  6. http://upload.wikimedia.org/wikiversity/en/0/04/Eml4500.f08.1.djvu

Contributing Team Members

edit
Problem Assignments
Problem # Solved & Typed by Reviewed by
1 Matthew Gidel All
2 Zeyn Kermani All
3 Kristin Howe All
4 Spencer Herran,Brandon Wright All
5 Kevin Li All
6 Joshua Plicque All

On our honor, we did this assignment on our own, without looking at the solutions in previous semesters or other online solutions.