text:
User:Eas4200c.f08.gator.edwards/Class Notes

Structural Elements
Aircraft are assembled from various elements that are made to withstand different loading conditions (axial, bending torsion).

Basic elements include:
 * axial members:truss/bar element
 * shear panels
 * bending members: beam
 * torsion member: bar/beam torsion

Some of these structural members have been introduced in statics and mechanics of materials.

Stringers

Q: Should bars with rectangular cross-sections be used for stringers?

A: No, bars with open thin-walled cross-sections should be used. This is because they are easier to manufacture (stamping of thin, flat sheets of metal) and they are easier to install on the aircraft (by rivetting. They also are light and strong and we want stringers to resist bending imposed from external pressure as stringers are reinforcement elements. By looking at the figure, we can see they both have the same Iy.

Q: Why don't we use vertical walls on a stringer (designated by the dotted lines in the figure)?

A: There can be many reasons as to why, with one of them being the ability to stockpile stringers when the arms are bent slightly outward. There can

 * also be strucutral reasons for this.

Shear Panel

Shear panels are thin sheets of material that can withstand in-plane shear loads.

$$G$$ = shear modulus

$$\gamma$$ = shear strain - counterpart of $$\epsilon$$, describes change in right angle between two (fictional) lines in the material; due to deformation

$$u=u_{x} ,\quad v=u_{y}$$, \quadby definition

$$\gamma = \frac{\delta u}{\delta y}+\frac{\delta v}{\delta x}=\frac{\delta u_{x}}{\delta y}+\frac{\delta u_{y}}{\delta x}$$

$$u$$ = displacement along x-direction

$$v$$ = displacement along y-direction

$$\varepsilon_{xy}$$ = tensorial shear strain = $$\frac{1}{2}\gamma _{xy}$$

Inspirational Quotes
 About independent thinking :

From The Beatles' "Think for Yourself":

"Think for yourself

'cause I won't be there with you"

 About intelligence :

From Montesquieu:

"Intelligence is the ability to see the difference between similar things and the similarity between different things."


text:
User talk:Eml4500.f08.echo.mott/HW2

How is everyone writing the formulas? I have been trying to code them by hand, but there has to be an editor somewhere.--70.185.115.72 22:31, 25 September 2008 (UTC)

Hey can someone post what the HW questions are (explicitly? can't tell on the web page) and on what days they were due? I missed a couple of classes due to illness.--Charles 03:21, 26 September 2008 (UTC)

license: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/

title: User talk:Eml4500.f08.echo.mott/HW2


text:
User:Eml4500.f08.jamama.adam/homework2topologyofk

homework2topologyofkLink title

9/15/08
Conceptual Step of Assembly: Topology of K

After calculation of the global stifness matrises K1 and K2, they can be combined following the conceptual step of assembly method called: topology of K as follows:

The resulting global stiffnes matrix is:

A sample calculation of the values of K:


text:
User:Eml4500.f08.team.figuerrez/hw2

=Model 2-bar truss system=

 Element 1:
Inclination angle $$\theta^{(1)} = 30 \deg$$

Element Length $$L^{(1)} = 4$$

Cross-sectional area $$A^{(1)} = 1$$

therefore the computed value for l(1) and m(1) are as follows:

$$l^{(1)} = cos \theta^{(1)}$$ $$l^{(1)} = cos {(30)}$$ $$l^{(1)} = 0.866$$

$$m^{(1)} = sin \theta^{(1)}$$ $$m^{(1)} = sin {(30)}$$ $$m^{(1)} = 0.5$$

Once the values for l(1) and m(1) are computed, the stiffness matrix for element 1 can be determined:

$$K^{(1)}_{11} = [K^{(1)}(l^{(1)})^{2}] = [\frac {3}{4})(\frac{\sqrt{3}}{2})^{2}] = (\frac {9}{16}) = 0.5625$$

$$K^{(1)}_{12} = [K^{(1)}(l^{(1)})*m^{(1)}] = [\frac {3\sqrt{3}}{16} = 0.325$$

$$K^{(1)}_{42} = -[K^{(1)}(m^{(1)})^{2}] = \frac {-3}{16} = -0.1875$$

Obs:

 * 1) You only need to compute 3 numbers. The other coefficients have the same absolute value; they just differ by +/-.
 * 2) Matrix K(1) is symmetric, i.e.,

$$K^{(1)}_{ij} = K^{(1)}_{ji}$$ $$K^{(1)}_{13} = K^{(1)}_{31}$$

$$ K^{(e)} = \begin{bmatrix} K^{(e)}_{11} & K^{(e)}_{12} & K^{(e)}_{13} & K^{(e)}_{14} \\

& K^{(e)}_{22} & K^{(e)}_{23} & K^{(e)}_{24} \\

& & K^{(e)}_{33} & K^{(e)}_{34} \\

& & & K^{(e)}_{44} \\ \end{bmatrix} $$

Here, the upper right "triangle" portion of the matrix has to be computed. The remaining values are symmetric and differ by +/-.

Element 2:
$$K^{(2)} = (\frac{E^{(2)}*A^{(2)}}{L^{(2)}}) = (\frac{5*2}{2}) = 5$$

$$\theta^{(2)} = (-\frac{\pi}{4})$$ therefore $$l^{(2)} = cos (\frac{-\pi}{4}) = (\frac{\sqrt{2}}{2}) $$

$$K^{(2)} = [K^{(2)}_{ij}]_{(4x4)}$$

$$K^{(2)}_{11} = K^{(2)}(l^{(2)})^{2} = 5 * (\frac {\sqrt{2}}{2})^{2} = 2.5$$

Obj:

$$K^{(2)}_{ij}, e=2, (i,j) = 1,....,4$$
are all the same: comp. 1 coefficient e
For other coefficients, add + or -
 * Absolute value of all coefficients:

 * K11(2)T = K(2), i.e. (K(2) is symmetric)

$$K^{(e)}d^{(e)} = f$$
e = 1,2
 * Element FD relationship:

$$ d^{(e)} = \begin{bmatrix} d^{(e)}_{1} \\

d^{(e)}_{2} \\

d^{(e)}_{3} \\

d^{(e)}_{4} \\ \end{bmatrix}_{(4x1)} $$

and

$$ f^{(e)} = \begin{bmatrix} f^{(e)}_{1} \\

f^{(e)}_{2} \\

f^{(e)}_{3} \\

f^{(e)}_{4} \\ \end{bmatrix}_{(4x1)} $$

$$K_{(nxn)} * d_{(nx1)} = f_{(nx1)}$$
Here n = 6
 * Global FD relationship:

title: User:Eml4500.f08.team.figuerrez/hw2


text:
User:Eml4500.f08.gravy.JMT

HW1
19. Sparse Matrix Computations

There are two storage modes in Matlab for a matrix: full and sparse. Full mode stores everything, while sparse only stores nonzero numbers. The default is to store elements of a matrix in full mode. In full mode, the zero elements are taken into account during calculations. Sparse mode will remove these zero elements during calculations, thus reducing time spent performing them. It saves time, but still outputs the same numbers.

Matrices can be converted between sparse and full fairly easily. The command “S=sparse(F)” will convert the full matrix, F, to a sparse matrix, S. It can then be converted back from sparse to full using the command "F=full(S)”.  Usually though, if a sparse matrix is desired, it will be created directly rather than by converting from a full matrix.  There are sparse analogs to many full matrices.  The fuctions speye, sparse, spones, and sprandn are sparse analogs to the full functions eye, zeros, ones and randn respectively.

When performing calculations using both full and sparse matrices, the storage mode of the output will vary. If calculations are performed on only sparse functions, the output will be sparse. If calculations are performed only on full functions, the output will be full. However, if calculations are performed using both full and sparse functions, the output will always come out as full unless the user specifically states otherwise.

HW2
What is K-1?

$$\ det(\underline{K}) = K_{33} * K_{34} - K_{34} * K_{43} $$

$$ \underline{K^{-1}} = \frac{1}{det(\underline{K})} * \begin{bmatrix} K_{44} & -K_{34} \\ -K_{43} & K_{33} \end{bmatrix}$$

Result on 2-Bar Truss System:

$$\begin{Bmatrix} d_3 \\ d_4 \end{Bmatrix} = \underline{K^{-1}} \begin{Bmatrix} 0 \\ P \end{Bmatrix}$$

$$\begin{Bmatrix} d_3 \\ d_4 \end{Bmatrix} = \begin{bmatrix} 0.7681 & -0.6217 \\ -0.6217 & 0.8753 \end{bmatrix} * \begin{Bmatrix} 0 \\ P \end{Bmatrix} = \begin{Bmatrix} 4.352 \\ 6.1271 \end{Bmatrix} $$

Complete Reactions

Methods 1: Force Displacement Relations

$$ k^{(e)}d^{(e)} = f^{(e)}, e = 1,2 $$

Element 1 (e=1)

$$k^{(1)} d^{(1)} = f^{(1)}$$

$$d^{(1)} = \begin{Bmatrix} 0 \\ 0 \\ 4.352 \\ 6.1271 \end{Bmatrix} $$

Element 2 (e=2)

$$K^{(2)} d^{(2)} = f^{(2)} $$

$$d^{(2)} = \begin{bmatrix} 4.352 \\ 6.1271 \\ 0 \\ 0 \end{bmatrix} $$

Matlab Code for 2 Bar Truss System
A two bar truss system can be modeled using Matlab. The following is an example, as written on Dr L. Vu-Quoc's website.

HW3
Knowing that the angle to find x_b and y_b is 30 degrees, and to find x_c and y_c is 135 degrees, we can use simple trigonometry to solve for the values:

$$ x_i = L*cos(\theta), yi = L*sin(\theta)$$

$$x_b = AC*cos(30)= 6.8324 * cos(30) = 5.9170, y_b = AC*sin(30) = 6.8324 * sin(30) = 3.4162$$

$$x_c = AB*cos(135) = 1.0249 * cos(135) = -.7247, y_c = AB*sin(135) = 1.0249 * sin(135) = .7247$$

(xb,yb) = (5.9170, 3.4162) (xc,yc) = (-0.7247, 0.7247)

To find x_d and y_d, the following equation is used:

$$\vec{AD} = x_d\vec{i}+ y_d\vec{j}$$

From HW2, we know that:

$$\vec{AD} = d_3\vec{i} + d_4\vec{j}$$

Also from HW2, we know that d3=4.352 and d4=6.1271. This means that:

$$\vec{AD} = 4.352\vec{i} + 6.1271\vec{j}$$

hence, (xd,yd) = (4.352, 6.1271).

HW6
Prove $$u*x_{i+1}=d_{i+1}$$

$$ u*x_{i+1}= N_i*x_{i+1}*d_i + N_{i+1}*x_i*d_{i+1} $$

Given: $$ N_i*x_{i+1} = 0 $$ $$ N_{i+1}*x_{i} = 1 $$

So, $$ u*x_{i+1} = (0)*d_i + (1)*d_{i+1} $$

$$ u*x_{i+1} = d_{i+1} $$

title: User:Eml4500.f08.gravy.JMT


text: File:Stringer.JPG

title: File:Stringer.JPG


text:
User:Eml4500.f08.delta 6.ramirez/staticsolutions

Statics Solution Method

P = 7 L(1) = 4 L(2) = 2 θ(1) = 30° θ(2) = 45°

Observation:

By using trigonometry and the angles given the unknown lengths can be determined. These lengths will be needed when analyzing the summation of the moments of each node.

$$\sin {30^{\circ} } = \frac{L_c}{4} \Rightarrow L_c = 4 \sin {30^{\circ} } = 2$$

$$\cos {30^{\circ} } = \frac{L_x}{4} \Rightarrow L_x = 4 \cos {30^{\circ} } = 3.46$$

$$\sin {45^{\circ} } = \frac{L_b}{2} \Rightarrow L_b = 2 \sin {45^{\circ} } = 1.4$$

$$\cos {45^{\circ} } = \frac{L_y}{2} \Rightarrow L_y = 2 \cos {45^{\circ} } = 1.4$$

Lz = Lx + Ly = 3.46 + 1.4 = 4.86

La = Lc - Lb = 2 - 1.4 = 0.6

Moment equations can now be analyzed since all lengths are known.

(1) M1: -(P)(Lx) + (F4)(Lz) + (F3)(La) = -(7)(3.46) + (F4)(4.86) + (F3)(0.6)

(2) M2: (P)(Ly) + (F1)(La) - (F2)(Lz) = (7)(1.4) + (F1)(0.6) - (F2)(4.86)

(3) M3: (F1)(Lc) - (F2)(Lx) - (F3)(Lb) + (F4)(Ly) = (F1)(2) - (F2)(3.46) - (F3)(1.4) + (F4)(1.4)

Note: There are 4 unknowns with only 3 equations. However, by inspection it is known that the summation of the forces in the x direction are equal to zero, giving us 4 equations with 4 unknowns. (4) $$\sum{F_x} = 0: F_1 - F_3 = 0 $$

All forces can now be determined by using the system of equations. Rearrange the equations solving for a common variable in order to calculate the first unknown force. Next, using the rearrange equations all unknown forces can be calculated.

(1) -24.22 + 4.86 F4 + 0.6 F3 = 0

(2) 9.8 + 0.6 F1 - 4.86 F2 = 0

(3) 2 F1 - 3.46 F2 - 1.4 F3 + 1.4 F4 = 0

(4) F1 = F3

Since F3 is already in terms of F1, F2 and F4 will also solved in terms of F1

(1) $$F_4 = \frac{24.22 - 0.6 F_3}{4.86} = \frac{24.22 - 0.6 F_1}{4.86}$$ (2) $$F_2 = \frac{9.8 + 0.6 F_1}{4.86}$$ (4) F3 = F1

Plugging in these relationships into equation (3), F1 and the rest of the forces can be solved for as follows:

(3) $$2 F_1 - 3.46 (\frac{9.8 + 0.6 F_1}{4.86}) - 1.4 F_1 + 1.4 (\frac{24.22 - 0.6 F_1}{4.86}) = 0 \Rightarrow $$

Combining like terms,

(3) $$2 F_1 - 6.976 - 0.427 F_1 - 1.4 F_1 + 6.976 - 0.173 F_1 = 0 \Rightarrow 0 = 0$$

Thus, F1 = F3 = 0

(2) $$F_2 = \frac{9.8 + 0.6(0)}{4.86} = 2.01$$ (1) $$F_4 = \frac{24.22 + 0.6(0)}{4.86} = 4.98$$

Results

F1 = 0 F2 = 2.01 F3 = 0 F4 = 4.98


title: User:Alberth2


text: File:Ex Element 1 picture.JPG

title: File:Ex Element 1 picture.JPG


text: File:Ex Element 2 picture.JPG

title: File:Ex Element 2 picture.JPG


text:
User:Eml4500.f08.qwiki.bishop/Lecture 10

 Comment: The pictures that were previously used in this homework submission have been changed. The previous images ( and ) were not originally authored by Team Qwiki, however I did not intentionally plagiarize Team Echo's work. While working on Homework 2, both Team Qwiki and Team Echo created two images, with the same name: and . Due to the nature of MediaWiki, if two different teams create an image with the same name, only the latest version is displayed when called upon in an article. Therefore, even though Team Qwiki uploaded two of our own images (Element1.jpg and Element2.jpg) during homework 2, Team Echo's images were displayed because their upload was the most recent. In the future, we will make sure to upload files that have a unique name. The correct images that were authored by Team Qwiki are included in this updated version of Homework 2.

A comparison between the current version of Homework 2 and our prior submission can be found here. Eric GatchEml4500.f08.qwiki.gatch 18:33, 13 November 2008 (UTC)

Elimination of Known Degree's of Freedom
If d1 = d2 = d5 = d6 = 0, then rows 1, 2, 5 and 6 can be eliminated from the global stiffness matrix. This is possible because when the stiffness matrix is multiplied by a displacement matrix containing those zero values, the respective values for the force components will equal zero. So. ..

$$	\mathbf{D} = \begin{Bmatrix} d_1=0\\d_2=0\\d_3\\d_4\\d_5=0\\d_6=0 \end{Bmatrix}$$

Respective Global Stiffness Matrix
Now. ..

$$	\mathbf{K} = \begin{vmatrix} k_{13} & k_{14} \\ k_{23} & k_{24}\\k_{33} & k_{34}\\k_{43} & k_{44}\\k_{53} & k_{54}\\k_{63} & k_{64}\end{vmatrix}$$

Then. . . by the Principle of Virtual Work (PVW), we delete the Global Stiffness Matrix rows corresponding to those rows that equal zero in the Global Stiffness Matrix.

Therefore, the Global Stiffness Matrix, K, reduces to

$$	\mathbf{K} = \begin{vmatrix} k_{33} & k_{34}\\k_{43} & k_{44}\end{vmatrix}$$

Resulting Overall Force Displacement Relationship
$$\begin{bmatrix} k_{33} & k_{34} \\ k_{43} & k_{44} \end{bmatrix} \begin{Bmatrix} d_3\\d_4\end{Bmatrix}=\begin{Bmatrix} F_3\\F_4\end{Bmatrix}=\begin{Bmatrix} 0\\P\end{Bmatrix}$$

What is the inverse of K?
Find the determinant of K:

$$det \mathbf{K}=k_{33}k_{44}-k_{34}k_{43}$$

Then the inverse of K, K-1, equals. ..

$$\mathbf{K}^{-1}=\frac{1}{det\mathbf{K}}\begin{bmatrix} k_{44} & -k_{34} \\ -k_{43} & k_{33} \end{bmatrix}$$

Verification of K-1

$$\mathbf{K}\mathbf{K}^{-1}=\mathbf{K}^{-1}\mathbf{K}=\mathbf{I}=\begin{bmatrix} 1 & 0 \\ 0 & 1 \end{bmatrix}$$

Note. ..

$$\mathbf{K}^T=\begin{bmatrix} k_{33} & k_{43} \\ k_{34} & k_{44} \end{bmatrix}$$

So. ..

$$\mathbf{K}^{-1}\ne \ \frac{1}{det(\mathbf{K})}\mathbf{K}^T$$

Now we go back to the 2 bar truss problem, for which the solution is:

$$\begin{Bmatrix} d_3 \\ d_4 \end{Bmatrix}=\mathbf{K}^{-1}\begin{Bmatrix} 0 \\ P \end{Bmatrix}=\begin{Bmatrix} 4.352 \\ 6.1271 \end{Bmatrix}$$

Computing the Reactions
There are two different methods for finding the reactions:

Method 1

Use the Element Force Displacement Relationship

For this case, the element stiffness matrix is known and the element displacements are known. Some of the element forces are known.

Element 1

$$\mathbf{k}^{(1)}\mathbf{d}^{(1)}=\mathbf{f}^{(1)}$$

$$d^{(1)}=\begin{Bmatrix} 0 \\ 0 \\ 4.352 \\ 6.1271 \end{Bmatrix}$$

Element 2

$$\mathbf{k}^{(2)}\mathbf{d}^{(2)}=\mathbf{f}^{(2)}$$

$$d^{(2)}=\begin{Bmatrix} 4.352 \\ 6.1271 \\ 0 \\ 0 \end{Bmatrix}=\begin{Bmatrix} d_1^{(2)} \\ d_2^{(2)} \\ d_3^{(2)} \\ d_4^{(2)} \end{Bmatrix}$$


text:
User:Eml4500.f08.gravy.jad/NotesRedo

 Comment: This page is a combination of two pages which contains the lecture notes and the Matlab tutorial with the lecture notes changed from images to typed. Here is a link to the two original pages Matlab turorial, Lecture notes And here is a link to a new page's history. Comparison This page is a consolidation between the original pages and the new page created so that the differences between the versions could be shown. Eml4500.f08.gravy.mmm 22:54, 5 November 2008 (UTC)

Accessing MATLAB
After MATLAB is installed to the computer, it may be accessed either by clicking on a icon on the desktop, or if that icon was not created, by selecting the icon in the start menu. An alternate method to access MATLAB is to enter it into the system command which can also be found in the start menu

For convenience, MATLAB, as well as the local editor should both remain open in separate windows for any computer system that allows for multiple processes. Any questions in this area should be directed towards the computer manufacturer.

Entering Matrices
Matrices are the method by which MATLAB represents all variables. Single variables or interpreted as a 1 x 1 matrix, with no indicated direction. This is also known as a scalar quantity. A vector is represented by any matrix consisting of one column, or one row. All matrices are two dimensional and must consist of numerical values.

There are multiple methods by which to introduce a matrix into MATLAB including loading the matrix from a disk or file, inserting the matrix manually, or using a matrix that has been generated by another mathematical equation. The following two statements are examples of the correct syntax to generate a 3 x 3 matrix:

A = [1 2 3; 4 5 6; 7 8 9]

A= [

1 2 3 4 5 6 7 8 9]

The first example separates the values by spaces and the rows by semi-colons while the second separates the rows by lines.

To indicate an exponent, values must be entered in without spaces (i.e. 2.34e-5) for proper syntax. MATLAB also has the ability to interpret imaginary numbers using i and j. These values are also entered without spaces (i.e. 3+4i). If the values of i and j are assigned prior to their use as an imaginary value, a new value can be used by first setting it equal to the square root of negative one.

If a matrix is too long and tedious to enter manually it should be entered via an ASCII file from the local editor to avoid possible error from input. To load files in MATLAB, use the load command followed by the name of the file.

For example: load filename.ext If a user wishes to experiment with matrices of random numbers the rand, magic, and hilb functions provide a solution. The rand function creates a matrix of randomly generated numbers for a matrix with the same number of rows as columns. The magic function creates a magic square matrix. This is a particular type of matrix where the rows, columns, and diagonals have a common sum. The hilb function creates a Hilbert matrix.

Matrix and Array Operations
MATLAB has a variety of operations available including addition (+), subtraction (-), multiplication (*), power (^), conjugate transpose (‘), left division (\), and right division (/) all of which can be applied to both scalars and vectors. Order of operations applies.

Statements Expressions and Variables
Matlab uses operators, functions and variable names (which are case-sensitive) to complete tasks. When an operation has been completed the results are displayed in matrix form, unless the line ends in a semicolon. The semicolon will suppress the output but the operation will still be carried out. To stop matlab mid operation hit CTRL and C, or CTRL and break.

The workspace saves all variables and their values. The command “who” or “whos” will displace the variables in the workspace. To clear a variable the command is “clear” followed by the variable name, if the variable name is omitted then all variables will be cleared.

Saving a Session
To save the variables from the workspace the command is “save”. Save will write the variable in a file called matlab.mat. To load the saved session the command is “load”.

Matrix Building Functions
Some commonly used functions in Matlab consists of:

For example, by saying zeros(m,n) produces an mxn matrix containing zeros. By saying zeros(n) produces an nxn matrix containing zeros. By saying zeros(A) while A is an existing matrix, it produces a matrix size A containing zeros.

For, if, while -and relations
For, if and while are different types of loops used in Matlab.

for:

-The "for" loop produces a vector of size "n" for a given function "x"

-saying, i=n:-1:1, will write the vector backwards

-There can be double nested "for" loops (two or more for loops in the same loop. This will produce an mxn matrix.

-A matrix can be used instead of "n" and it will assume to compute the matrix

while:

-The "while" function is a loop that will continue to loop until the condition statement becomes false

if:

-The"if" function is a single loop that will only enter the loop if the primary condition is met

-it is a single loop

Relations

Some common relational operators used in Matlab consists of:

logical operators are as follows:

In addition, any true/false relations appear as a scalar number 1/0.

Scalar Functions
There are some functions in MATLAB that were designed and created for scalar functions. These functions can still operate element-wise on matrices. Some common examples are sin, cos, tan, asin, acos, atan, exp, log, ln, rem (remainder), abs (absolute value), sqrt (square root)

Vector Functions
Unlike scalar functions, vector functions are, as their name hints, used on vectors (i.e. matrices or size m x n). These functions when used yield answers which are also in vector form. Some common examples of vector functions are max (max value), min (min value), sort (sort values), median, mean, std (standard deviation), sum, prod (product)

Matrix Functions
As mentioned above, matrices are used as a representation of variables in MATLAB. This is what makes the program such a useful tool. Some common examples of matrix functions are eig (eigenvalues), chol (choleski factorization), inv (inverse), hess (hessenberg form), det (determinant)

Command line editing and recall
- editing is easy -> backspace or delete to the right or left of the cursor

- commands: Ctl-a, Ctl-e, Ctl-d, Ctl-k for Unix or PC systems

- the cursor can be moved up or down to recall any previous line, therefore one can move the cursors up, down, left, right and recall and/or edit anything on the page

Submatrices and colon notation
-matlab uses vectors and submatrices, often generated by "colon notation"

- "colon notation" and subscripting is used to manipulate data sets

- ex: A(1:4,3) = matrix A, column 3, elements 1 through 4

A(:,3) = matrix A, column 3, all elements

A(:,[2 4]) = matrix A, column 2 and 4, all elements

M-Files
M-files M-files are are stored files usually ending with the “.m” extension. They allow MATLAB to run an entire preprogrammed series of commands. They effectivly make up the backbone of MATLAB, and most work is usually done to create or edit these files. There are two main types of m-files: script files and function files.

Script Files Script files are a type of m-file that contains a sequence or normal MATLAB commands. They are normally used for the creation and mataince of large variables, such as matrices. The varibable created in a script file are global. To call a script file, simply enter a command into MATLAB that is the name of the script file with the “.m” extension left off. For example, if the file is named “example1.m” than typing in the command “example1” will cause the script file to run.

Function Files Function files are the true brains behind MATLAB. They allow for the creation of any type of function programmable, which greatly extends the cabalities of MATLAB. Function files, unlike script files, default to creating local variables. However they can be declared global if the need arises. A function files starts with the line “function variable=execute(a,b)”. The word “function” tells MATLAb that the following is a function. “variable” is the output argument, and the name can be changed to be more descriptive. “execute(a,b)” is the name of the function (execute) and the variables that need to be passed into the function (a,b). The list of variables (a,b), called the input arguments, can be expanded or deleted to fit the need of the function. Function files, like all m-files, are able to use and call other files within them, allowing for a greater range of programming options.

An example of a function file is shown below. Remember that the “%” symbol allows for comments without affecting any code. MATLAB ignores all statements after the % symbol.

function a=randint(m,n) %RANDINT Randomly generated integral matrix. %       randint(m,n) returns an m-by-n matrix with entries

%      between 0 and 9 a=floor(10*rand(m,n))

Putting the command “z=randint(3,6)” into MATLAB will return a 3-by-6 matrix variable named “z”. The great advantage to function files is the ability to expand and create huge programs. This allows for the creation of many smaller function, similar to the randint(a,b) created before, to be combined into a large file that can be programmed to do thousands of different things. Also, there is the ability to combine self-made functions with some of MATLAB’s built-in functions, much like the built in function “rand(x,y)” was used above.

A useful command to find out a list of all the functions that MATLAB has access to, a combination of built-in and user programmed functions, can be seen by typing the command “type functionname”.

Text strings, error messages, input
To enter a text string in MATLAB, use single quotes: s = 'This is a test' This will assign the text string ‘This is a test’ to the variable s.

To display a text string, use the function disp: disp('this message is hereby displayed');

To display an error message, use the function error: error('Sorry, the matrix must be symmetric'); This also will exit the M-file upon execution.

To prompt the user for input data, use the function input: iter = input('Enter the number of iterations: '); This will display ‘Enter the number of iterations’ and pause execution while the user inputs the data which is then data assigned to the variable iter.

Managing M-files
To keep MATLAB active while editing a file in order to avoid losing all variables, use the !-feature by inserting a ! before any system command: >> !ed rotate.m This will let you edit rotate.m using the local editor without exiting MATLAB.

See help dbtype and references given there for more concerning debbugging tools.

The following commands will duplicate system commands without the use of a !:

M-files must be in an accessible directory. Storing personal M-files in a subdirectory named Matlab in one’s home directory should work. For further information see the discussion of MATLABPATH in the User's Guide.

Comparing efficiency of algorithms: flops, tic, toc
There are two measure of algorithm efficiency: floating point operations (flops) performed and the elapsed time (tic and toc).

The MATLAB function flops keeps a running total of the flops performed.

To reset the flops count to 0, use the command fops(0), not flops=0. Do this at the beginning of the code, and then use the command fops at the end to get the fops count of the algorithm: fops (0); x=A\b; fops

The MATLAB functions tic and toc give the elapsed time between the two commands: tic; x=A\b; toc

However, on timesharing machines, elapsed time is not as reliable as flops at determining algorithm efficiency because the rate of execution is dependent on how busy the computer is at the time.

Output format
To control the format of the displayed output, use the following commands:

Once invoked, the chosen format remains in effect until changed.

To suppress most blank lines, use the command format compact. To reverse the format compact command, use format loose. These are independent of the other format commands.

Hard copy
Saving input from the command window to an alterable and printable file can be done using the command diary. To start recording the command is “diary” then the file name. If you don’t give a file name the default file name is diary. To end recording the command is “diary off”.

Planer plots
The command for plot is “plot (x,y)” with x and y being the variables to be plotted. An interval and mesh size can be set by “variable name= lower limit: mesh size: upper limit”.

“fplot (‘function file’,[lower limit, upper limit])” is the command to graph functions. Function file is a m-file that contains the function to be graphed.

Only one figure is active at a time but you can switch between the figures using “figure(n)” where n is the figure number wanted. “gcf” command gives the active figure’s number.

Multiple plots on one graph can be made using “plot(x, y1,x,y2,…)”Other ways are, declaring a matrix of functions like U=[function1, function2 ] and using plot(x,U). Or using the “hold” command to freeze the current plot and all plots after will be placed on the same plot. To unfreeze the plots, the command is  “hold off”.

3-D line plots
To create 3-d plots the command is “plot3(x,y,z)”.

3-D mesh and surface plots
To create 3-D wire mesh surface plots the command is “mesh(z)” and three dimensional faceted surface plots “surf(z)”where z is a matrix of points in the z direction.

To plot a function over a rectangle use first the command “[x,y]=meshgrid(xx,yy)” where xx and yy are matrices of the sides of the rectangle. x and y result in matrices whose columns equal xx and yy respectably. Next the command mesh is used with z= exp(-x.^2-y.^2)

The color of the shadings can be changed using the command “shading” followed by the setting. The settings are faceted, interp ( for interpolated), and flat. The color profile is changed using the command “colormap” followed by the color. The color codes are hsv, hot, cool, jet, pink, copper, flag, gray, and   bone.

Labeling the figure
The commands Title, xlabel, ylabel and zlabel, can be used to label the figure. An example is Title(‘Title name’).

gtext(‘The Spot’), command places text where on the figure the mouse is clicked, while the text command places the text at coordinates.

Axis scaling
The following commands are used to change the scaling on the axis.

axis([x lower limit, x upper limit, y lower limit, y upper limit ]), to set scaling.

axis(axis), freezes scaling for subsequent graphs.

axis auto, resets the scale to the default.

Variable= axis, the variable will be set to the current scaling.

axis square, makes the same scale for both axes.

axis equal, make the same scale and tic marks for both axes.

axis off, turns off scaling and tic marks axis on turns them on.

Line types
To change the line type, mark type and color use the tables below. The syntax is Plot(x,y,’color line type mark type’) so Plot(x,y,’b:*’) is a blue dotted line with star markers.

'''

Graphics hard copy
The command “print” will send the current graphic to the default printer. The command “print ” then the file name will save and overwrite the graphic to a file, but ”print -append” then the file name will add the graphic to the end  of a file.

To save a graphic that is not the current one, the command is “print –deps –f#” then the filename and # the figure number.

Sparse Matrix Computations
There are two storage modes in Matlab for a matrix: full and sparse. Full mode stores everything, while sparse only stores nonzero numbers. The default is to store elements of a matrix in full mode. In full mode, the zero elements are taken into account during calculations. Sparse mode will remove these zero elements during calculations, thus reducing time spent performing them. It saves time, but still outputs the same numbers.

Matrices can be converted between sparse and full fairly easily. The command “S=sparse(F)” will convert the full matrix, F, to a sparse matrix, S. It can then be converted back from sparse to full using the command "F=full(S)”. Usually though, if a sparse matrix is desired, it will be created directly rather than by converting from a full matrix. There are sparse analogs to many full matrices. The functions speye, sparse, spones, and sprandn are sparse analogs to the full functions eye, zeros, ones and randn respectively.

When performing calculations using both full and sparse matrices, the storage mode of the output will vary. If calculations are performed on only sparse functions, the output will be sparse. If calculations are performed only on full functions, the output will be full. However, if calculations are performed using both full and sparse functions, the output will always come out as full unless the user specifically states otherwise.

 New Lecture Notes
Notes

Online sources for free college resources.

Wikipeida, wikversity, MIT. Open course ware.

Labeling system
1.      Number in a triangle is the global label for an element

2.      Number in a circle is the global label for a node

3.      Number in a square is the local label for a node

Next big step: Force-Displacement relation (FD)

$$\begin{Bmatrix} f_1 \\ f_2 \end{Bmatrix}_{2X1}=\begin{bmatrix} k  &- k  \\-k &k    \end{bmatrix}_{2X2}*    \begin{Bmatrix} d_1 \\ d_2 \end{Bmatrix}_{2X1}$$

Case 1; observer sits on node 1

$$\ f_2=k(d_2-d_1)\,$$

Case 2: observer sits on node 2

$$\ f_1=-f_2=-k(d_2-d_1)=k(d_1-d_2) \,$$

Ch1. : Big Picture
1.1 Discretization

1.1.1         Plane Truss element

1.2      Assembly of element

Ex. 1.4 Fire-bar truss

1.4  Element solution of model validity

1.4.1         Plane Truss element

Steps to solve simple truss systems

1.      Global picture (description) At structures level

·        Global degrees of freedoms (dofs) and displacement degrees of freedoms (disp. dofs)

·        Global forces

Actually the disp dofs are partitioned into:

·        A known part, e.g fixed dofs, constrains

·        An unknown part: Solved using FEM

Similarly for the global forces:

·        A known part: Applied forces

·        An unknown part : Reactions

2.      Element Picture:

·        Element  dofs

·        Element forces

·        Either  of the above in global coordinates systems or in local coordinates systems

3.      Global FD relation

·        Element stiffness matrices in global coordinates

·        Element force matrices in global coordinates

·        Assembly of element stiffness matrix and element force matrix into global FD relation

$$\ K_{nXn} * d_{nX1}=F _{nX1} \,$$

4.      Elimination of known dofs. To reduce the global FD relation (stiffness matrix non-singular) invertible

$$\ \overline{ K_{mXm}} * \overline{ d_{mX1} }= \overline{ F _{mX1}} \,$$

M= number of unknown disp dofs

N= number of both known and unknown disp dofs

k non singular so k-1 exists (k invertible)

$$\ \overline{ d_{mX1} }= \overline{ K^{-1}_{mXm}} * \overline{ F _{mX1}} \,$$

5.      Compute element forces from  now known d= element stresses

6.      Compute reactions. (unknown forces)

title: User:Eml4500.f08.gravy.jad/NotesRedo


title: File:Hw21.GIF


text:
User:Eas4200c.f08.wiki.d/HW1

Introduction
In modern aircraft design a key objective is to produce an aircraft that is light in weight, but strong enough to resist stresses and fatigues that the vehicle is subjected to during flight. Therefore ideal materials for aircraft construction are ones that exhibit high stiffness, strength, and toughness while having a low density and consequently low weight. In order to understand the topic of aerospace structures we must first examine each of these components.

Stiffness is the resistance to deflection and/or deformation generated by a material that is subjected to an applied force. An 18th century British scientist, Thomas Young, was among the first to develop a qualitative method to describe the stiffness of a material. Now, the Young's Modulus of Elasticity, E, is a material property widely used across all fields of engineering and science to describe material stiffness. Young stated that the stress within a material is directly proportional to the strain, with the proportionality constant being E.

$$\sigma\,=E\epsilon\,$$

Strength

Toughness

An example of using different aerospace materials to obtain required structural properties is the F/A-18E (Hornet). In this aircraft various parts are fabricated from different materials in order to maximize the performance of each part based on their individual loading conditions. By doing this, the overall performance of the aircraft is optimized while minimizing the weight, which is the main design criteria in aerospace applications. A few of the numerous materials in the aircraft are listed below along with their locations.
 * Aluminum: Skin
 * Steel: Landing gear
 * Titanium: Engine encasing structure, Stabilator, Wing, Cockpit cover
 * Carbon Epoxy: Fuselage, Aileron, Stabilator, Vertical stabilizer

MediaWiki
MediaWiki is a web-based wiki software application originally written for Wikipedia by Lee Daniel Crocker. Wiki software refers to collaborative software the manages, creates, and edits web pages through common web browser applications as the user interface. The information in wiki software is stored in a file system, while the edits are stored using a relational database management system. The main features of MediaWiki is the rich core feature set and the ability to add extensions, allowing additional functionality. Also, this software is distributed under the terms of the GNU General Public License with some documentation in the public domain; thus, it is a free and open source software, which allows anyone to use and edit the stored content.

The overall idea behind MediaWiki is that by having anyone add information on topics they thoroughly understand, everyone can benefit from the collective knowledge. The let down is that since there is no credibility check before editing a page, people with less than adequate knowledge of a subject or people who's intentions aren't to improve the content can "vandalize" the stored information, whether it be adding incorrect segments or even deleting previous contributions. In order to control this problem, the history of different versions of each web-page is saved, and editors, or custodians, assess each contribution in order to determine the validity. In the case of vandalism, the web-page is simply returned to the last acceptable version.

title: User:Eas4200c.f08.wiki.d/HW1


title: File:Hw22.GIF


text: File:Drawing 09-15.jpg

title: File:Drawing 09-15.jpg


text:
User:Eas4200c.f08.wiki.d/HW2

Within aircrafts, stringers, or longerons, are fastened inside the skin to resist the forces and moments that the fuselage and wings are subjected to during flight. In order to minimize the weight of the stringers while still providing the required structural properties, open-channel cross sections are used rather than solid ones because of there higher resistance to bending stress.

In order to demonstrate the increase in bending resistance by using open channel stringers, the moments of inertia of two stringers with different cross sections are compared below. In Case 1 a closed, solid, circular cross section is used, where as in Case 2 an open-channel cross section with the same area as Case 1 is examined.

Thus, the open-channel cross section stringer is about 11 1/2 times stronger the closed, solid, circular cross section one with the same area. As a result, a smaller,lighter stringer can be used to support the required load if the open-channel cross section is used.

title: User:Eas4200c.f08.wiki.d/HW2


text:
User:Eml4500.f08.gravy.bje/Notes2

Lecture 9 Notes
$$\ \begin{bmatrix} K_{11}^{(1)} & K_{12}^{(1)} & K_{13}^{(1)} & K_{14}^{(1)} & 0 & 0  \\ K_{21}^{(1)}& K_{22}^{(1)} & K_{23}^{(1)} & K_{24}^{(1)} & 0 & 0 \\ K_{31}^{(1)} & K_{32}^{(1)} & (K_{33}^{(1)} + K_{11}^{(2)}) & (K_{34}^{(1)} + K_{12}^{(2)}) & K_{13}^{(2)} & K_{14}^{(2)} \\ K_{41}^{(1)}& K_{42}^{(1)} & (K_{43}^{(1)} + K_{21}^{(2)}) & (K_{44}^{(1)} + K_{22}^{(2)}) & K_{23}^{(2)} & K_{24}^{(2)} \\ 0 & 0 & K_{31}^{(2)} & K_{32}^{(2)} & K_{33}^{(2)} & K_{34}^{(2)} \\ 0 & 0 & K_{41}^{(2)} & K_{42}^{(2)} & K_{43}^{(2)} & K_{44}^{(2)}  \end{bmatrix}\,$$

$$\ \ = \begin{bmatrix} \frac{9}{16}& \frac{3\sqrt{3}}{16} & -\frac{9}{16} & -\frac{3\sqrt{3}}{16} & 0 & 0 \\  \frac{3\sqrt{3}}{16} & \frac{3}{16} & -\frac{3\sqrt{3}}{16} & -\frac{3}{16} & 0 & 0 \\ -\frac{9}{16} & -\frac{3\sqrt{3}}{16} & (\frac{9}{16} + \frac{5}{2}) & (\frac{3\sqrt{3}}{16} + \frac{5}{2}) & -\frac{5}{2} & -\frac{5}{2} \\ -\frac{3\sqrt{3}}{16} & -\frac{3}{16} & (\frac{3\sqrt{3}}{16} + \frac{5}{2}) & (\frac{3}{16} + \frac{5}{2}) & -\frac{5}{2} & -\frac{5}{2} \\  0 & 0 & -\frac{5}{2} & -\frac{5}{2} & \frac{5}{2} & \frac{5}{2} \\ 0 & 0 & -\frac{5}{2} & -\frac{5}{2} & \frac{5}{2} & \frac{5}{2}  \end{bmatrix}_{6X6}\,$$

$$\ \ = \begin{bmatrix} 0.5625 & 0.3248 & -0.5625 & -0.3428 & 0 & 0 \\  0.3248 & 0.1875 & -0.3248 & -0.1875 & 0 & 0 \\ -0.5625 & -0.3248 & (0.5625 + 2.5) & (0.3248 + 2.5) & -2.5 & -2.5 \\ -0.3248 & -0.1875 & (0.3248 + 2.5) & (0.1875 + 2.5) & -2.5 & -2.5 \\  0 & 0 & -2.5 & -2.5 & 2.5 & 2.5 \\ 0 & 0 & -2.5 & -2.5 & 2.5 & 2.5  \end{bmatrix}_{6X6}\,$$

$$\ \begin{bmatrix} -0.5 \\ 0 \\ 1 \\ 0 \end{bmatrix}$$ $$\ \begin{bmatrix} 0.333 \\ -1.333 \\ 0 \\ 1 \end{bmatrix}$$ For λ = 13

$$\ \begin{bmatrix} 0.286 \\ 1 \\ 1 \\ 0 \end{bmatrix}$$ $$\ \begin{bmatrix} 0 \\ -1 \\ 0 \\ 1 \end{bmatrix}$$ For λ = -12

$$\ \begin{bmatrix} 5.6 \\ 5.6 \\ 7.2 \\ 1 \end{bmatrix}$$ For λ = 24

$$\ \begin{bmatrix} -2 \\ 0 \\ 1 \\ 0 \end{bmatrix}$$ $$\ \begin{bmatrix} -1 \\ 0 \\ 0 \\ 1 \end{bmatrix}$$ For λ = -4

$$\ \begin{bmatrix} 1 \\ 1 \\ -2 \\ 1 \end{bmatrix}$$ For λ = 1

x(t) = c1 $$\ \begin{bmatrix} 7 \\ -2 \\ 3 \end{bmatrix}$$ e4t + c2 $$\ \begin{bmatrix} -3 \\ 1 \\ -1 \end{bmatrix}$$ e3t + c3 $$\ \begin{bmatrix} 2 \\ 0 \\ 1 \end{bmatrix}$$ e2t

EX:

$$\ K_{11} = K_{11}^{(1)} \,$$

$$\ K_{33} = K_{33}^{(1)} + K_{11}^{(2)} \,$$

$$\ K_{43} = K_{44} = K_{34}^{(1)} + K_{12}^{(2)} = K_{43}^{(1)} + K_{21}^{(2)} \,$$

$$\ K_{11}^{(1)} = \frac{9}{16} \,$$

$$\ K_{12}^{(1)} = \frac{3\sqrt{3}}{16}$$

$$ K_{33} = \frac{9}{16} + \frac{5}{2} = 3.0625 $$

$$ K_{43} = \frac{3\sqrt{3}}{16} + \frac{-5}{2} = 2.1752 $$

$$ K_{44} = K_{44}^{(1)} + K_{22}^{(2)} = \frac{3}{16} + \frac{5}{2} = 2.6875 $$

4.) Elimination of known dof's

 * Reduce global FD relations (p. 5-3)

 * Elimination of column 1, 2, 5, 6 because d's are zero

Lecture 11 Notes
$$ Elem 1: \underline{k}^{(1)} \underline{d}^{(1)} = \underline{f}^{(1)} $$

$$\ d^{(1)} = \begin{bmatrix} 0 \\ 0 \\ 4.352 \\ 6.1271 \end{bmatrix}_{4X1}\,$$

$$\ = \begin{bmatrix} 0.5625 & 0.32476 & ... & ... \\ & & & \\ & & & \\ & & & \end{bmatrix}_{4X4} \begin{Bmatrix} 0 \\ 0 \\ 4.352 \\ 6.1271 \end{Bmatrix}_{4X1} \,$$

$$\ = \begin{bmatrix} -0.5625 & -0.32476 \\ ... & ... \\ & \\ & \end{bmatrix}_{4X2} \begin{Bmatrix} 4.352 \\ 6.1271 \end{Bmatrix}_{4X1} \,$$

$$\ = \begin{bmatrix} -4.4378 \\ -2.5622 \\ +4.4378 \\ +2.5622 \end{bmatrix}_{4X1}\,$$

$$\ = \begin{bmatrix} f_{1}^{(1)} \\ f_{2}^{(1)} \\ f_{3}^{(1)} \\ f_{4}^{(1)} \end{bmatrix}_{4X1}\,$$

 * f1(1) and f2(1) = Reactions

 * f3(1) and f4(1) = Internal Forces

 * Observation: Element 1 is in equilibrium

 * ΣFx = f1(1) + f3(1)

 * ΣFy = f2(1) and f4(1)

 * ΣMat any point = 0

 * $$P_{1}^{(1)} = [(f_{1}^{(1)})^2 + (f_{2}^{(1)})^2]^ \frac{1}{2}$$

$$ Elem 2: \underline{k}^{(2)} \underline{d}^{(2)} = \underline{f}^{(2)} $$

 * The same method to solve for element one can also be used to solve for element 2

title: User:Eml4500.f08.gravy.bje/Notes2


title: File:Hw23.GIF


title: File:Hw24.GIF


text:
User:Eml4500.f08.gravy.bje/MATLAB

1. Accessing MATLAB
After MATLAB is installed to the computer, it may be accessed either by clicking on a icon on the desktop, or if that icon was not created, by selecting the icon in the start menu. An alternate method to access MATLAB is to enter it into the system command which can also be found in the start menu

For convenience, MATLAB, as well as the local editor should both remain open in separate windows for any computer system that allows for multiple processes. Any questions in this area should be directed towards the computer manufacturer.

2. Entering Matrices
Matrices are the method by which MATLAB represents all variables. Single variables or interpreted as a 1 x 1 matrix, with no indicated direction. This is also known as a scalar quantity. A vector is represented by any matrix consisting of one column, or one row. All matrices are two dimensional and must consist of numerical values.

There are multiple methods by which to introduce a matrix into MATLAB including loading the matrix from a disk or file, inserting the matrix manually, or using a matrix that has been generated by another mathematical equation. The following two statements are examples of the correct syntax to generate a 3 x 3 matrix:

A = [1 2 3; 4 5 6; 7 8 9]

A= [ 1 2 3 4 5 6 7 8 9] The first example separates the values by spaces and the rows by semi-colons while the second separates the rows by lines.

To indicate an exponent, values must be entered in without spaces (i.e. 2.34e-5) for proper syntax. MATLAB also has the ability to interpret imaginary numbers using i and j. These values are also entered without spaces (i.e. 3+4i). If the values of i and j are assigned prior to their use as an imaginary value, a new value can be used by first setting it equal to the square root of negative one.

If a matrix is too long and tedious to enter manually it should be entered via an ASCII file from the local editor to avoid possible error from input. To load files in MATLAB, use the load command followed by the name of the file.

For example: load filename.ext If a user wishes to experiment with matrices of random numbers the rand, magic, and hilb functions provide a solution. The rand function creates a matrix of randomly generated numbers for a matrix with the same number of rows as columns. The magic function creates a magic square matrix. This is a particular type of matrix where the rows, columns, and diagonals have a common sum. The hilb function creates a Hilbert matrix.

3. Matrix and Array Operations
MATLAB has a variety of operations available including addition (+), subtraction (-), multiplication (*), power (^), conjugate transpose (‘), left division (\), and right division (/) all of which can be applied to both scalars and vectors. Order of operations applies.

7. Scalar Functions
There are some functions in MATLAB that were designed and created for scalar functions. These functions can still operate element-wise on matrices. Some common examples are sin, cos, tan, asin, acos, atan, exp, log, ln, rem (remainder), abs (absolute value), sqrt (square root)

8. Vector Functions
Unlike scalar functions, vector functions are, as their name hints, used on vectors (i.e. matrices or size m x n). These functions when used yield answers which are also in vector form. Some common examples of vector functions are max (max value), min (min value), sort (sort values), median, mean, std (standard deviation), sum, prod (product)

9. Matrix Functions
As mentioned above, matrices are used as a representation of variables in MATLAB. This is what makes the program such a useful tool. Some common examples of matrix functions are eig (eigenvalues), chol (choleski factorization), inv (inverse), hess (hessenberg form), det (determinant)

Eigenvalues: eig Cholesky factorization: chol Inverse: inv Hessenberg form: hess Determinant: det

title: User:Eml4500.f08.gravy.bje/MATLAB


text: File:Truss Variables.JPG

title: File:Truss Variables.JPG


title: File:HW2a.jpg


title: File:HW2diag2.jpg


title: File:GlobalFBD1-0908.JPG