
Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
Community
Ask the community for help and clear up your study doubts
Discover the best universities in your country according to Docsity users
Free resources
Download our free guides on studying techniques, anxiety management strategies, and thesis advice from Docsity tutors
finiteelemtn
Typology: Exercises
1 / 1
This page cannot be seen from the preview
Don't miss anything!
E=100e9; %Young Modulus A0=100e-6; %Cross Sectional Area a x=L P=1000; %Apply Load Length=1; %Total length L=Length/10; %Length in each element =0.1m x=1; %for loop purpose n=L; %for loop purpose to calculate length
for i=1:1:10 % FOr Loop to calculate k1 to k c=n/2;%centroid of each element A=A0(1-c/2/Length); %Cross section area of each element k(:,x)=(EA/L); %forming k1 to k10 matrix n=n+L; %go to next centroid ie .15,0.25,0.35,0.45,0.55,0.65,0.75,0.85,0. x=x+1; %for next column of matrix end
k(:,1)+k(:,2) -k(:,2) 0 0 0 0 0 0 0 0; -k(:,2) k(:,2)+k(:,3) -k(:,3) 0 0 0 0 0 0 0; 0 -k(:,3) k(:,3)+k(:,4) -k(:,4) 0 0 0 0 0 0; 0 0 -k(:,4) k(:,4)+k(:,5) -k(:,5) 0 0 0 0 0; 0 0 0 -k(:,5) k(:,5)+k(:,6) -k(:,6) 0 0 0 0; 0 0 0 0 -k(:,6) k(:,6)+k(:,7) -k(:,7) 0 0 0; 0 0 0 0 0 -k(:,7) k(:,7)+k(:,8) -k(:,8) 0 0; 0 0 0 0 0 0 -k(:,8) k(:,8)+k(:,9) -k(:,9) 0; 0 0 0 0 0 0 0 -k(:,9) k(:,9)+k(:,10) -k(:,10); 0 0 0 0 0 0 0 0 -k(:,10) k(:,10);]; % [K] Structural stiffness matrix, with eliminated row1 n column 1 disp('[K]=') disp(K) %show result of [K] F=[0; 0; 0; 0; 0; 0; 0; 0; 0; P]; % Vector of applied Force with P= U=K\F; %solve the matrix to obtain displacement %to plot displacement versus x X=0:0.1:1; %x-axis Y=[0 U(1,:) U(2,:) U(3,:) U(4,:) U(5,:) U(6,:) U(7,:) U(8,:) U(9,:) U (10,:)]; % displacement value with u1= disp('x=') disp(X) disp('displacement=') disp(Y) figure plot(X,Y,'-o') title('displacement versus x-cordinate') xlabel('x-cordinate') ylabel('Displacement/m')