0% found this document useful (0 votes)
219 views5 pages

3D Truss Analysis: 1 Element Stiffness Matrix in Local Coordinates

This document describes the process for analyzing a 3D truss structure using matrix structural analysis. It discusses developing the element stiffness matrix in local coordinates and then transforming it to global coordinates using coordinate transformation matrices. It also describes modifying existing MATLAB code for 2D truss analysis (truss2d.m, truss_element2d.m, truss_assemble2d.m, truss_forces2d.m) to enable 3D truss analysis by accounting for the additional z-coordinate degree of freedom at each node. Key changes include using 3D node coordinate matrices, modifying how degrees of freedom are numbered, and updating plot commands to handle 3D visualization.

Uploaded by

Saul Auqui Gomez
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
219 views5 pages

3D Truss Analysis: 1 Element Stiffness Matrix in Local Coordinates

This document describes the process for analyzing a 3D truss structure using matrix structural analysis. It discusses developing the element stiffness matrix in local coordinates and then transforming it to global coordinates using coordinate transformation matrices. It also describes modifying existing MATLAB code for 2D truss analysis (truss2d.m, truss_element2d.m, truss_assemble2d.m, truss_forces2d.m) to enable 3D truss analysis by accounting for the additional z-coordinate degree of freedom at each node. Key changes include using 3D node coordinate matrices, modifying how degrees of freedom are numbered, and updating plot commands to handle 3D visualization.

Uploaded by

Saul Auqui Gomez
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

3D Truss Analysis

CEE 421L. Matrix Structural Analysis


Department of Civil and Environmental Engineering
Duke University
Henri P. Gavin
Fall, 2014

1 Element Stiffness Matrix in Local Coordinates


Consider the relation between axial forces, {q1 , q2 }, and axial displacements, {u1 , u2 }, only
(in local coordinates).

EA
k=
L

"

1 1
1
1

q=ku

CEE 421L. Matrix Structural Analysis Duke University Fall 2014 H.P. Gavin

2 Coordinate Transformation

Global and local coordinates

L=

(x2 x1 )2 + (y2 y1 )2 + (z2 z1 )2

x2 x1
= cx
L
y2 y1
= cy
cos y =
L
z2 z1
cos z =
= cz
L

cos x =

Displacements

u1 = v1 cos x +v2 cos y +v3 cos z


u2 = v4 cos x +v5 cos y +v6 cos z

cz

.
"

u1
u2

"

cx cy cz 0 0
0 0 0 cx cy

v1
v2
v3
v4
v5
v6

u=Tv
Forces

f1
f2
f3
f4
f5
f6

cx 0

cy 0
"
#

cz 0
q
1

0 cx
q2

0 cy

0 cz

f = TT q
CC BY-NC-ND H.P. Gavin

3D Truss Analysis

3 Element Stiffness Matrix in Global Coordinates


"

q1
q2

EA
=
L

"

1 1
1
1

#"

u1
u2

f = TT q

u=Tv

q = ku
q = kTv
T

T q = TT k T v
f = TT k T v
f = Kv

K=

EA
L

c2x
cx cy
cx cz
c2x cx cy cx cz

cx cy
c2y
cy cz cx cy c2y cy cz

2
2
cx cz cy cz cz
cx cz
cy cz
cz

c2x cx cy cx cz
c2x
cx cy
cx cz

2
2
cy cz
cy
cx cy cy cy cz cx cy

2
2
cx cz cy cz cz
cx cz
cy cz
cz

4 Numbering Convention for Degrees of Freedom


g = [ 3*n1-2 ; 3*n1-1 ; 3*n1 ;

3*n2-2 ; 3*n2-1 ; 3*n2 ];

5 Truss Bar Tensions, T

T = q2 = (kTv)2 =

EA
(cx (v4 v1 ) + cy (v5 v2 ) + cz (v6 v3 ))
L

CC BY-NC-ND H.P. Gavin

CEE 421L. Matrix Structural Analysis Duke University Fall 2014 H.P. Gavin

6 Modifying truss 2d.m to truss 3d.m


Copy truss 2d.m to truss 3d.m
function [D,R,T,L,Ks] = truss 3d(XYZ,TEN,RCT,EA,P,D)
Modifications to the input arguments:
the node location matrix XYZ has x, y, and z coordinates . . . a 3 x nN matrix;
the reaction matrix RCT has x, y, and z coordinates . . . a 3 x nN matrix;
the node load matrix P has x, y, and z coordinates . . . a 3 x nN matrix;
the prescribed displacement matrix D has x, y, and z coordinates . . . a 3 x nN matrix;
Modification to the computed output:
the computed deflections D will be the x, y, z displacements at each node, returned
as a 3 x nN matrix;
the computed reactions R will be the x, y, z forces at each node with a reaction,
returned as a 3 x nN matrix;
Modifications to the program itself:
Change how DoF is computed;
Change [Ks,L] = truss assemble 2d(XY,TEN,EA); to
[Ks,L] = truss assemble 3d(XYZ,TEN,EA);
Change T = truss forces 2d(XY,TEN,EA,Dv); to
T = truss forces 3d(XYZ,TEN,EA,D);
Modify the section of code relating the node displacement vector Dv to the node
displacement matrix D to account for the fact that there are three degrees of freedom
per node.
Change plot commands to plot3 commands and change XY to XYZ.
For example, change . . .
plot( XY(1,TEN(:,b)), XY(2,TEN(:,b)), -g )
. . . to . . .
plot3( XYZ(1,TEN(:,b)), XYZ(2,TEN(:,b)), -g )
Also change the ax variable to account for the Z dimension.

CC BY-NC-ND H.P. Gavin

3D Truss Analysis

Copy truss element 2d.m to truss element 3d.m


function K = truss element 3d(x1,y1,z1,x2,y2,z2,EA)
L =
cx =
cy =
cz =
K =

Copy truss assemble 2d.m to truss assemble 3d.m


function [Ks,L] = truss assemble 3d(XYZ,TEN,EA)
DoF =
x1 =
y1 =
z1 =
x2 =
y2 =
z2 =
[K, L(b)] = truss element 3d(x1,y1,z1,x2,y2,z2,EA(b) );
g =

Copy truss forces 2d.m to truss forces 3d.m


function T = truss forces 3d(XYZ,TEN,EA,D)
x1 =
y1 =
z1 =
x2 =
y2 =
z2 =
L =
cx =
cy =
cz =
T(b) =

CC BY-NC-ND H.P. Gavin

You might also like