Assignment 7 Mechanics of Composite Structures: %no of Laminas and Thickness of Laminas
This MATLAB code calculates the ABBD matrix for a laminated composite structure. It takes in the number of laminae, thickness, stacking sequence, and material properties as inputs. It then calculates the local stiffness matrix, transforms it to the global stiffness matrix for each lamina, and sums the results to obtain the ABBD matrix representing the overall laminate stiffness. The key steps are 1) defining material properties and stacking sequence, 2) calculating local and global stiffness matrices, and 3) summing the results to obtain the ABBD matrix of the laminate.
Assignment 7 Mechanics of Composite Structures: %no of Laminas and Thickness of Laminas
This MATLAB code calculates the ABBD matrix for a laminated composite structure. It takes in the number of laminae, thickness, stacking sequence, and material properties as inputs. It then calculates the local stiffness matrix, transforms it to the global stiffness matrix for each lamina, and sums the results to obtain the ABBD matrix representing the overall laminate stiffness. The key steps are 1) defining material properties and stacking sequence, 2) calculating local and global stiffness matrices, and 3) summing the results to obtain the ABBD matrix of the laminate.
N = input('Enter the total no of laminas: '); h = input('Enter the thickness of laminas: '); %Stacking sequence starting from the bottom lamina stkseq = zeros(1,N); for i=1:N fprintf('Enter the orientation in degrees of lamina %d:', i); stkseq(1,i) = input(' '); end %Material properties El = input('Enter El(Gpa): '); Et = input('Enter Et(Gpa): '); Ylt = input('Enter Ylt(Gpa): '); Glt = input('Enter Glt(Gpa): '); %Local stiffnes matrix elements Q11 = El/(1-(Et/El)*Ylt^2); Q12 = Ylt*Et/(1-(Et/El)*Ylt^2); Q22 = Et/(1-(Et/El)*Ylt^2); Q66 = Glt; %Assembled local stiffness matrix fprintf('The local stiffness matrix of all the laminas \n'); Q = [Q11,Q12,0;Q12,Q22,0;0,0,Q66]; disp(Q); %Calculating invariants U1 = 1/8*(3*Q11+3*Q22+2*Q12+4*Q66); U2 = 1/2*(Q11-Q22); U3 = 1/8*(Q11+Q22-2*Q12-4*Q66); U4 = 1/8*(Q11+Q22+6*Q12-4*Q66); %Global stiffness matrix of each lamina Qbar = zeros(3,3,N); for i=1:N Qbar11 =U1+U2*cos(2*pi/180*stkseq(1,i))+U3*cos(4*pi/180*stkseq(1,i)); Qbar12 = U4+U3*cos(4*pi/180*stkseq(1,i)); Qbar22 = U1-U2*cos(2*pi/180*stkseq(1,i))+U3*cos(4*pi/180*stkseq(1,i)); Qbar16 =U2/2*sin(pi/180*stkseq(1,i))+U3*sin(4*pi/180*stkseq(1,i)); Qbar26 = U2/2*sin(pi/180*stkseq(1,i))-U3*sin(4*pi/180*stkseq(1,i)); Qbar66 = (U1-U4)/2-U3*cos(4*pi/180*stkseq(1,i)); for j=1:3 for k=1:3 if (j==k) if (j==1) Qbar(j,k,i) = Qbar11; elseif (j==2) Qbar(j,k,i) = Qbar22; else Qbar(j,k,i) = Qbar66; end elseif (j + k == 3) Qbar(j,k,i) = Qbar12; elseif (j + k == 4) Qbar(j,k,i) = Qbar16; else Qbar(j,k,i) = Qbar26; end end end end for i=1:N fprintf('Global stiffness matrix for lamina %d: \n', i); display(Qbar(:,:,i)); end %ABBD matrix for the laminate z = zeros(1,N+1); for i =1:N z(1,i+1) = z(1,i) + h; end A = zeros(3,3); B = zeros(3,3); D = zeros(3,3); for i = 1:3 for j = 1:3 for k = 1:N A(i,j) = A(i,j)+Qbar(i,j,k)*(z(1,k+1)-z(1,k)); B(i,j) = B(i,j)+1/2*Qbar(i,j,k)*(z(1,k+1)^2-z(1,k)^2); D(i,j) = D(i,j)+1/3*Qbar(i,j,k)*(z(1,k+1)^3-z(1,k)^3); end end end ABBD = [A B; B D]; fprintf('The ABBD Matrix is :\n'); display(ABBD); OUTPUT: