Sie sind auf Seite 1von 4

GAUSS ELIMINATION METHOD

PROGRAM: RESULT:

disp('the augmented matrix is') The augmented matrix is

a=[1 0 -3 8;2 2 9 7;0 1 5 -2]; 1. 0. - 3. 8.

disp(a) 2. 2. 9. 7.

0. 1. 5. - 2.
disp('R2=R2-2*R1')
R2=R2-2*R1
a(2,:)=a(2,:)-2*a(1,:);
1. 0. - 3. 8.
disp(a)
0. 2. 15. - 9.
disp('interchange R2 and R3')
0. 1. 5. - 2.
a([2,3],:)=a([3,2],:);
interchange R2 and R3
disp(a)
1. 0. - 3. 8.
disp('R3=R3-2*R2') 0. 1. 5. - 2.
a(3,:)=a(3,:)-2*a(2,:); 0. 2. 15. - 9.
disp(a) R3=R3-2*R2

disp('R3=(1/5)*R3') 1. 0. - 3. 8.

a(3,:)=(1/5)*a(3,:); 0. 1. 5. - 2.

disp(a) 0. 0. 5. - 5.

R3=(1/5)*R3
disp('R2=R2-5*R3 and R1=R1+3*R3')
1. 0. - 3. 8.
a(2,:)=a(2,:)-5*a(3,:);
0. 1. 5. - 2.
a(1,:)=a(1,:)+3*a(3,:);
0. 0. 1. - 1.
disp(a)
R2=R2-5*R3 and R1=R1+3*R3
s=[a(1,4);a(2,4);a(3,4)];
1. 0. 0. 5.
disp('solution is')
0. 1. 0. 3.
disp(s) 0. 0. 1. - 1.

solution is

5.

3.

- 1.
PROGRAM: RESULT:

clc;funcprot(0); (a)The static spring deflection,delta_st=0.1562


ft (or)1.875 in
// Given data
(b)The natural frequency of the
W=25;// The weight of the body in lb system,omega_n=14.36 rad/sec
k=160;// lb/ft The natural frequency of the
system,f_n=2.285 sec
v=2;// The downward velocity in ft/sec
(c)The system period,tau=0.438 sec
g=32.2;// The acceleration due to gravity in
ft/sec^2

// Calculation

// (a)

delta_st=W/k;// The static spring deflection in


ft

delta_st=delta_st*12;// in

// (b)

omega_n=sqrt(k/(W/g));// The natural


frequency of the system in rad/sec

f_n=omega_n*(1/(2*%pi));// The natural


frequency of the system in cycles/sec

// (c)

tau=1/f_n;// The system period in sec

printf("\n(a)The static spring


deflection,delta_st=%0.4f ft (or)%1.3f in
\n(b)The natural frequency of the
system,omega_n=%2.2f rad/sec \n The
natural frequency of the system,f_n=%0.3f sec
\n(c)The system period,tau=%0.3f
sec",delta_st/12,delta_st,omega_n,f_n,tau);
A. K. TAYAL // the term F with suffixes 1 & 2 indicates BM
just to left and right

Engineering M_A=0 // kNm

Mechanics M_B=(-P*L_CD) // kNm

M_C=(-P*(L_AB+L_BC))+(C(1)*L_BC)-
DOWNLOAD BOOK
(UDL*L_BC*(L_BC/2)) // kNm
- Chapter 25 : Shear Force and
Bending Moment M_D=0 // kNm
Example 25.7 // LOCATION OF MAXIMUM BM
// Initilization of variables // Max BM occurs at E at a distance of 2.5 m
from B i.e x=L_AE=4.5 m from free end A.
L_AD=8 // m // length of the beam
Thus max BM is given by taking moment at B
L_AB=2 // m
L_AE=4.5 // m // given
L_BC=4 // m
M_E=(-2*L_AE)+(4.5*(L_AE-2))-((1/2)*(L_AE-
L_CD=2 // m 2)^2) // kNm

UDL=1 // kN/m // PLOTTING SFD & BMD

P=2 // kN // point load at A x=[0;1.99;2;4.5;5.99;6;8]

// Caalculations y=[-2;-2;2.5;0;-1.5;2;0]

// REACTIONS a=[0;2;4.5;6;8]

// solving eqn's 1&2 using matrix to get R_B & b=[0;-4;-0.875;-2;0]


R_C as,
subplot(221)
A=[1 1;1 3]
xlabel("Span (m)")
B=[8;30]
ylabel("Shear Force (kN)")
C=inv(A)*B
plot(x,y)
// SHEAR FORCE
subplot(222)
// the term F with suffixes 1 & 2 indicates SF
plot(a,b)
just to left and right
xlabel("Span (m)")
F_A=-P // kN
ylabel("Bending Moment (kNm)")
F_B1=-P // kN
// Results
F_B2=-P+C(1) // kN
clc
F_C1=-P+C(1)-(UDL*L_BC) // kN
printf('The graphs are the solutions')
F_C2=-P+C(1)-(UDL*L_BC)+C(2) // kN

F_D=0

// BENDING MOMENT
Fdb=((Fad*sind(theta))-(W1))/sind(theta) //N
// (T) // Using eq'n 6
Chapter 9 : Analysis of Plane
Trusses and Frames Fde=(Fdb*cosd(theta))+(Fad*cosd(theta)) //N
// (C) // Using eq'n 5
Example 9.1
// (4) JOINT E

Feb=((Fce*cosd(theta))-(Fde))/cosd(theta) //N
// Initilization of variables // (C) // Using eq'n 7
W1=2000 //N // load at joint D of the truss // Results
W2=4000 //N // load at joint E of the truss clc
Lac=6 //m // length of the tie printf('The Axial Force in member AD (Fad) is
%f N \n',Fad)
Lab=3 //m
printf('The Axial Force in member AB (Fab) is
Lbc=3 //m %f N \n',Fab)
theta=60 //degree // interior angles of the printf('The Axial Force in member CE (Fce) is
truss %f N \n',Fce)
// Calculations printf('The Axial Force in member CB (Fcb) is
// Here A is simply supported & B is roller %f N \n',Fcb)
support. Now the SUPPORT REACTIONS are printf('The Axial Force in member DB (Fdb) is
given as, %f N \n',Fdb)
Rc=((W1*(Lab/2))+(W2*(Lab+(Lbc/2))))/Lac printf('The Axial Force in member DE (Fde)is
//N // Taking moment at A %f N \n',Fde)
Ra=W1+W2-Rc //N // Take sum Fy=0 printf('The Axial Force in member EB (Feb) is
// ANALYSIS OF TRUSS BY METHOD OF JOINT %f N \n',Feb)

// ASSUMPTION- we consider the,(1) Forces


moving towards each other as +ve i.e TENSILE
(T) & (2) Forces moving away from each other
as -ve i.e COMPRESSIVE (C)

// (1) JOINT A

Fad=Ra/(sind(theta)) //N //(C) // Using eq'n 2

Fab=Fad*cosd(theta) //N // (T) // Using eq'n 1

// (2) JOINT C

Fce=Rc/(sind(theta)) //N // (C) // Using eq'n 4

Fcb=Fce*cosd(theta) //N // (T) // Using eq'n 3

// (3) JOINT D

Das könnte Ihnen auch gefallen