Dynamics of Structures: The Development of The Potential and Academic Programmes of Wrocław University of Technology
Dynamics of Structures: The Development of The Potential and Academic Programmes of Wrocław University of Technology
Dynamics of Structures: The Development of The Potential and Academic Programmes of Wrocław University of Technology
EUROPEAN
SOCIAL FUND
THE DEVELOPMENT OF THE POTENTIAL AND ACADEMIC PROGRAMMES OF WROCAW UNIVERSITY OF TECHNOLOGY
Dynamics of Structures
Part 1
Zbigniew Wjcicki
Jacek Grosel
EUROPEAN UNION
EUROPEAN
SOCIAL FUND
THE DEVELOPMENT OF THE POTENTIAL AND ACADEMIC PROGRAMMES OF WROCAW UNIVERSITY OF TECHNOLOGY
Matrices
Definition of matrix
A matrix is set of numbers or algebraic expressions arranged in a rectangular form with m rows and n
columns. A matrix is denoted by an underlined letter A or a bold letter A. The abbreviation dim
denotes the dimension of matrix. Any element of matrix is described by two subscripts aij, where the
first one, i, denotes the number of the row and the second, j - the number of the column. The
element aij is placed on the intersection of i-th row and j-th column.
a12
a11
a22
a21
A=A=
am11 am1 2
a
am 2
m1
a11
ai1
a
m1
a1j
aij
amj
a1n1
a2 n1
am1 n1
am n1
a1n
a2 n
,
am1 n
am n
dim A= mn
a1n
ain
amn
i-th row: ai
j-th column: a j
element: aij
every element of matrix A: [A]ij= aij
i, j
Types of matrices
dim A= mn rectangular matrix
dim B= 1n row matrix
dim C= m1 column matrix, vector c
EUROPEAN UNION
EUROPEAN
SOCIAL FUND
THE DEVELOPMENT OF THE POTENTIAL AND ACADEMIC PROGRAMMES OF WROCAW UNIVERSITY OF TECHNOLOGY
0 f1 0 0
0 0 f2 0
f diagf1, f1,..., fn
fnn 0 0 fn
f11 0
0 f22
0 0
1 0
0
e.g. I2
, I4
0
0 1
0 0 0
1 0 0
0 1 0
0 0 1
Equality of matrices
A=B [A]ij=[B]ij
Scalar multiplication
B = A [B]ij= [A]ij;
- scalar
Matrix addition
Matrix addition is possible only if the dimensions of matrices are equal.
C=A+B [C]ij=[A]ij+[B]ij
EUROPEAN UNION
EUROPEAN
SOCIAL FUND
THE DEVELOPMENT OF THE POTENTIAL AND ACADEMIC PROGRAMMES OF WROCAW UNIVERSITY OF TECHNOLOGY
Matrix multiplication
A B = C multiplication is possible if dim C= mp where dim A= mn, dim B= np. The result of
multiplication is equal to
n
The fact that the multiplication A B is possible does not mean that the multiplication B A is
possible.
Example:
1 2
A= 2 3 ;
4 1
1 2 3 4
B=
;
4 3 2 1
4
3
1 2 c11 c12
2
c13
2 3 c21 c22
4 1 c31 c32
C = A B=?
c11 1 1 2 4 9
c13 ?
1
c14 ,
c12 1 2 2 3 8
c22 2 2 3 3 13
c14 ? c32 ?
c21 ?
c23
c24
c33 4 3 1 2 14
c23 ?
c33
c34
c34 4 4 1 1 17
c24 ?
9 8 7 6
A B = C = 14 13 12 11 ,
8 11 14 17
c31 ?
EUROPEAN UNION
EUROPEAN
SOCIAL FUND
THE DEVELOPMENT OF THE POTENTIAL AND ACADEMIC PROGRAMMES OF WROCAW UNIVERSITY OF TECHNOLOGY
dim{a} =dim{b}
Example:
1 3
A=
, {b} = diag (2, 3),
5 2
A {b}=?
{b} A =?
2 9
A {b}=
. It is a column multiplication, i.e. the i-th column of matrix A is multiplied by the
10 6
EUROPEAN UNION
EUROPEAN
SOCIAL FUND
THE DEVELOPMENT OF THE POTENTIAL AND ACADEMIC PROGRAMMES OF WROCAW UNIVERSITY OF TECHNOLOGY
Matrix transposition
A = BT dim A= mn, dim B= nm and [A]ij= [B]ji
Example:
1
1 2 3 4
1 2 3 4
T
2
B=
;
B
=
3
4 3 2 1
4 3 2 1
4
T
3
A
2
A = BT B = AT
A = (AT)T
(A+B+C) T = A T +B T +C T
(A B C) T = C T B T A T
If A = AT then A is a symmetric matrix, [A]ij= [A]ji
If A = AT then A is a skew-symmetric matrix, [A]ij= -[A]ji , [A]ii= 0
Every diagonal matrix is also a symmetric matrix {a}T = {a}.
Trace of matrix
dim A= nn,
n
tr AT = tr A
tr (A+B+C) = tr A + tr B + tr C
tr ( A) = (tr A)
tr (A B) = tr (B A)
tr (A B C) = tr (B C A) = tr (C A B ) tr (A C B )
EUROPEAN UNION
EUROPEAN
SOCIAL FUND
THE DEVELOPMENT OF THE POTENTIAL AND ACADEMIC PROGRAMMES OF WROCAW UNIVERSITY OF TECHNOLOGY
Example:
1
5
tr
2
3 0 1
2 1 2
1 2 0 4 7
3 0 3
2 3 4
Determinant of matrix
A determinant of matrix A is denoted by det A. The determinant is a scalar and is defined solely for
the square matrix dim A= nn. The easiest way to define the determinant is recursion. For a matrix
with dimensions 11, the determinant is equal in value to the only element of this matrix. For a
matrix with dimensions 22, the determinant is equal to:
a12 a11 a12
a
det 11
a11 a22 a12 a21
For a matrix with dimensions 33, the rule of Sarrus can be used. Two first columns should be
written on the right side of the matrix (or two first rows -- under the matrix). The product of the
elements crossed with a blue line are added, and the ones crossed with a red line are subtracted:
a11 a12
a11a22 a33 a12 a23 a31 a13a21a32 a13 a22 a31 a11a23 a32 a12 a21a33
For matrix A with dimensions dim A= nn det A is defined by determinants of matrices with
dimensions (n-1)(n-1). The minor Mij is a matrix obtained from matrix A by erasing the i-th row and
the j-th column. The cofactor Aij of the element aij is a determinant of the minor Mij multiplied by (1)i+j.
Aij = (-1)i+j det Mij
The determinant may be calculated by application of the Laplace expansion along any i-th row
EUROPEAN UNION
EUROPEAN
SOCIAL FUND
THE DEVELOPMENT OF THE POTENTIAL AND ACADEMIC PROGRAMMES OF WROCAW UNIVERSITY OF TECHNOLOGY
n
det A =
i k
1
k 1
aik Aik
k 1
det A =
k j
1
k 1
akj Akj
k 1
Example
1
5
det
2
3 0 1
2 1 2
?
3 0 3
2 3 4
Using the Laplace expansion along the 3rd column and the rule of Sarrus, the determinant can be
easily calculated:
1
5
det
2
3 0 1
1 3 1
1 3 1
2 1 2
2 3
4 3
1 1 det 2 3 3 3 1 det 5 2 2
3 0 3
1 2 4
2 3 3
2 3 4
1 (1 3 4 3 3 1 1 2 2 1 3 1 1 2 3 3 2 4)
3 (1 2 3 3 2 2 1 5 3 1 2 2 1 2 3 3 5 3) 8 66 74
Adding a column/row multiplied by any number to another column/row does not change the value
of the determinant. This property makes it possible to calculate the determinant easily. In the
example below:
(1) the 2nd row multiplied by -3 is added to the 4th row. After this, there is only one nonzero element
in the 3rd column
(2) the Laplace expansion is applied along the 3rd column
(3) the 1st row multiplied by -2 is added to the 2nd row and the 1st row multiplied by 14 is added
to the 3rd row.
(4) the Laplace expansion is applied along the 1st column and the determinant can be calculated
easily for matrix 22.
EUROPEAN UNION
EUROPEAN
SOCIAL FUND
THE DEVELOPMENT OF THE POTENTIAL AND ACADEMIC PROGRAMMES OF WROCAW UNIVERSITY OF TECHNOLOGY
5
det
2
3 0 1
3 0 1
1
3
1
1
2 1 2
5
2 1 2
23
det
1 1 det 2
3
3
(3 )
2
3 0 3 (1)
3 0 3 (2)
14 4 2
2 3 4
14 4 0 2
1
1 3
3 1
0 38 12
Inversion of matrix
A square matrix B with the same dimensions as matrix A is called inverse to it when:
BA=AB=I
The symbol A-1 is used for a matrix inverse to A.
Using the properties of the determinant:
A2= A A , A3= A A A
det (An) = (det A) n
A-1 A = A A-1 = I
det (A A-1) = det A det A-1 = det I = 1
EUROPEAN UNION
EUROPEAN
SOCIAL FUND
THE DEVELOPMENT OF THE POTENTIAL AND ACADEMIC PROGRAMMES OF WROCAW UNIVERSITY OF TECHNOLOGY
A1n A11
A2 n A12
=
Ann A1n
A11 A12
A
A22
adj A = 21
An1 An2
A21
A22
A2 n
An1
An2
Ann
Example:
1 2 5
A = 2 3 0 , det A = 9+0+2015120 = 2
1 2 3
3
det
2
2
adj A = det
2
2
det
3
0
2
det
3
1
5
1
det
3
1
5
1
det
0
2
0
2
det
3
1
5
1
det
3
1
5
1
det
0
2
2
2
=
2
2
6 1
4 15
9
9
4
2 0 6 2 10
15 10 1
1
0
1
4,5 2 7,5
A = adj A /det A = 3 1 5
0,5 0 0,5
-1
Any matrix A could be transformed into an identity matrix I by performing the following
transformations (multiplication of the row/column by a scalar, adding rows/columns).
By applying the same transformations to the identity matrix one can obtain a matrix inverse to A.
EUROPEAN UNION
EUROPEAN
SOCIAL FUND
THE DEVELOPMENT OF THE POTENTIAL AND ACADEMIC PROGRAMMES OF WROCAW UNIVERSITY OF TECHNOLOGY
1 2 5
A = 2 3 0 , I =
1 2 3
1 0 0
0 1 0
0 0 1
nd
nd
st
2 row row2 1 row 2
3rd row 3 rd row 1st row
5
1 2
A(step1) = 0 1 10 , I(step1) =
0 0 2
1 0 0
2 1 0
1 0 1
1 0 15
A(step 2) = 0 1 10 , I(step 2) =
0 0 2
3 2 0
2 1 0
1 0 1
1 0 0
A(step 3) = 0 1 0 =I , I(step 3) =
0 0 1
Verification of:
nd
nd
2 row 2 row / element22
1st row 1st row 2nd row 2
3 rd row 3 rd row / 2
st
st
rd
1 row 1 row 3 row 15
2nd row 2 nd row 3 rd row 10
4,5 2 7,5
-1
3 1 5 =A
0,5 0 0,5
A-1 A = ?, A A-1 = ?
3 1 5 2 3 0 2 3 0 3 1 5 0 1 0
0,5 0 0,5 1 2 3 1 2 3 0,5 0 0,5 0 0 1
Vectors
Matrices with only one column are often called vectors. Vectors are denoted by overlining
x1
x
x = col (x1, x2, ... xn) = 2 = [x1, x2, ... xn]T
xn
EUROPEAN UNION
EUROPEAN
SOCIAL FUND
THE DEVELOPMENT OF THE POTENTIAL AND ACADEMIC PROGRAMMES OF WROCAW UNIVERSITY OF TECHNOLOGY
1)
x max xi
maximum norm
2)
x xT x -
a 7
anorm col 74 , 47 , 1
2)
anorm col 49 , 49 ,
7
9
- 1 anorm,i 1
anorm 1
A xy
EUROPEAN UNION
EUROPEAN
SOCIAL FUND
THE DEVELOPMENT OF THE POTENTIAL AND ACADEMIC PROGRAMMES OF WROCAW UNIVERSITY OF TECHNOLOGY
y 0. The existence of a solution depends on the type of the system (homogenous or not) and on
the properties of matrix A (if it is a singular matrix or not).
1. nonhomogenous system ( y 0)
1.1. det A 0 solution exists x = A-1 y
1.2. det A = 0 solution does not exist
2. homogenous system ( y = 0)
2.1. det A 0 solution exists and is trivial x = 0
2.2. det A = 0 there is an infinite number of solutions
x = adj A v ,
for v =col (0, 0, ... ,1, ... 0) the solution is any non-zero column of matrix adj A; generally the
solution is a linear combination of columns of matrix adj A.
Eigenproblem
Numbers i are eigenvalues of a square matrix A if a nonzero vector wi exists which fulfils the
equation A wi = i wi . Vectors wi are called eigenvectors.
A w= w
A w w =0
(A I) w = 0 ;
a11
det ai1
a
n1
w 0 det (A I) = 0
a1j
aij
anj
a1n
ain 0
ann
EUROPEAN UNION
EUROPEAN
SOCIAL FUND
THE DEVELOPMENT OF THE POTENTIAL AND ACADEMIC PROGRAMMES OF WROCAW UNIVERSITY OF TECHNOLOGY
characteristic equation:
2
3
det
0 3 6 4 0 ,
6
2
2 9 14 0 solutions 1 2, 2 7
The eigenvector is any non-zero column of the matrix adjoint to matrix (A i I)
1
1 2
4 2 normalization 1
1
1 = 2; B1=(A 1 I) =
, w1
,
, adj B1 =
1
1
1
2 4
2 1
2 2
2
4 2
2 = 7; B2=(A 2 I) =
, adj B2 =
2 1
1 2 normalization 12
2 4
1
1
2
12
, w2
1
1
1
W = w 1 w 2 =
1
2
1
2
,
1
EUROPEAN UNION
EUROPEAN
SOCIAL FUND
THE DEVELOPMENT OF THE POTENTIAL AND ACADEMIC PROGRAMMES OF WROCAW UNIVERSITY OF TECHNOLOGY
In[1]:=
Out[1]=
In[2]:=
Out[2]=
In[3]:=
A 1, 2, 5, 2, 3, 0,
1, 2, 3
1, 2, 5, 2, 3, 0, 1, 2, 3
A
1, 2, 5, 2, 3, 0, 1, 2, 3
A MatrixForm
Out[3]//MatrixForm=
125
230
123
In[4]:=
TraditionalForm A
Out[4]//TraditionalForm=
125
230
123
In[5]:=
Out[5]=
In[6]:=
v 1, 2, 3
1, 2, 3
MatrixForm v
Out[6]//MatrixForm=
1
2
3
In order to transpose the matrix, the command Transpose should be used. The transposition of
a vector with one column yields a matrix with one row only.
In[7]:=
Transpose A
Out[7]=
1, 2, 1, 2, 3, 2, 5, 0, 3
In[8]:=
TraditionalForm TransposeA
Out[8]//TraditionalForm=
121
232
503
In[9]:=
Transposev MatrixForm
Out[9]//MatrixForm=
1 2 3
EUROPEAN UNION
EUROPEAN
SOCIAL FUND
THE DEVELOPMENT OF THE POTENTIAL AND ACADEMIC PROGRAMMES OF WROCAW UNIVERSITY OF TECHNOLOGY
In[10]:=
A.A MatrixForm
Out[10]//MatrixForm=
10 18 20
8 13 10
8 14 14
In[11]:=
A.v MatrixForm
Out[11]//MatrixForm=
20
8
14
In[12]:=
Transposev.A MatrixForm
Out[12]//MatrixForm=
8 14 14
In[13]:=
DetA
Out[13]=
2
In[14]:=
TraditionalForm InverseA
Out[14]//TraditionalForm=
9
2 15
2
2
3 1 5
1
0 12
2
In[15]:=
TrA
Out[15]=
EUROPEAN UNION
EUROPEAN
SOCIAL FUND
THE DEVELOPMENT OF THE POTENTIAL AND ACADEMIC PROGRAMMES OF WROCAW UNIVERSITY OF TECHNOLOGY
In[17]:=
TraditionalForm InverseA .A
Out[17]//TraditionalForm=
100
010
001
In[18]:=
TraditionalForm IdentityMatrix3
Out[18]//TraditionalForm=
100
010
001
In[19]:=
DiagonalMatrix1, 2, 3 MatrixForm
Out[19]//MatrixForm=
100
020
003
The command IdentityMatrix can be used in order to declare an identity matrix, and the
command DiagonalMatrix to declare a diagonal matrix. The command Eigenvalues
yields the eigenvalues of the matrix, arranged from the greatest to the smallest. The command
Eigenvectors yields the eigenvectors of the matrix. These eigenvectors are arranged in rows!
The first row corresponds to the greatest eigenvalue. The command Eigensystem combines two
previous commands.
In[26]:=
AA 3, 2, 2, 6; AA MatrixForm
Out[26]//MatrixForm=
In[27]:=
32
26
EigenvaluesAA
Out[27]=
7, 2
In[28]:=
EigenvectorsAA MatrixForm
Out[28]//MatrixForm=
In[29]:=
1 2
2 1
Eigensystem AA MatrixForm
Out[29]//MatrixForm=
7
2
1, 2 2, 1
EUROPEAN UNION
EUROPEAN
SOCIAL FUND
THE DEVELOPMENT OF THE POTENTIAL AND ACADEMIC PROGRAMMES OF WROCAW UNIVERSITY OF TECHNOLOGY
Problems
The following matrices are given:
2 2
A=
, B=
2 6
2 2
2 6 , C =
3 7 1
F=
,
3 0 1
3
G=
4
2 2
2 6 , D =
2 1 5
2 1 0
, U=
2 7 1
2 2 3
1 2 3
4 5 1 , E =
3 1 2
1
,
2
2
V = 3 , X =
1
2 4
4 1 ,
6 2
2
3 ,
4
1
(g) XT G , (h)
2 x 3y 4 z 0
2 x 1y 0
6. Find the value of for which a nontrivial solution v of these equations exists:
(K B ) v 0 ,
Find vectors v and normalize them
(a)
k k
K =
, B=
k 2k
m 0
(b)
k k 0
K = k 2k k , B =
0 k 2 k
m 0 0
0 m 0 , k=1, m=1,
0 0 m
EUROPEAN UNION
EUROPEAN
SOCIAL FUND
THE DEVELOPMENT OF THE POTENTIAL AND ACADEMIC PROGRAMMES OF WROCAW UNIVERSITY OF TECHNOLOGY
Answers to problems
1.
4 4
T
(a) A + A =
, (bd) A A = A B = B C =
4
12
8 16
,
16 40
6 14 6
(e) E F = 9 28 5 , (f) D V =
12 42 8
11
24 ,
11
(g) XT G = 9 20 35 17
1 4 3
(h) D M = 4 10 1 ,
3 2 2
6
(i) N G =
16
15
4 2 0
,
8 28 4
2 2 3
4 6 2
2. (a) tr G =13, (b) det C= 8 (c) det D = -34 (d) det G =26
2 4
(e) det (L C L) = det
= 32,
4 24
6 2
3. (a) adj B
, (b) adj N = diag (8, 12, 6, 24)
2 2
1 2 4 2
(c) adj (U UT) = adj
=
2 4 2 1
2 0,4142
0,4142
2 2 2 1
1 2 3
2
3
1
5
1 =0
4
3
1
2
EUROPEAN UNION
EUROPEAN
SOCIAL FUND
THE DEVELOPMENT OF THE POTENTIAL AND ACADEMIC PROGRAMMES OF WROCAW UNIVERSITY OF TECHNOLOGY
0,440 0,518
1
8. eigenmatrix W = 0,486
1
1 ;
0,644 0,868 0,462
9. eg.
2
3
6,534
1
1
1
0,462 0,462 0,462
1
3
10. G =
4
2 1 5
2 1 0
,
2 7 1
2 2 3
1,704 1,288 i
1,705 1,288i
0,351
0,425
1
1,033 2,252i
1,033 2,252i 0,008
Eigenmatrix W =
,
0,492 1,524 0,774i 1,524 0,774i
1
1
1
0,346
0,367
x 2y 3 z 0
11. 2 x 3y 4 z 0
2 x 1y 0
1 2 3
System matrix A = 2 3 4
2 1 0
EUROPEAN UNION
EUROPEAN
SOCIAL FUND
THE DEVELOPMENT OF THE POTENTIAL AND ACADEMIC PROGRAMMES OF WROCAW UNIVERSITY OF TECHNOLOGY
4 3 1
0,5
x
0,5
columns'
normalization
adj A = 8 6 2
1 y 1
4 3 1
0,5
z
0,5
- any number
12. (a)
k k
K =
, B=
k 2k
m 0
,
0 m
det (K B ) = 0 k2 3 k m + m2 2= 0
1= (3 k 5 k) / 2m=0,381 k/m 2= (3 k +5 k) / 2m = 2,618 k/m
2 k
W=
1
2
3k
5k
1,618
1
=
1,618
3 k 5k 1
k
1
2
0,618
1
(b)
k k 0
K = k 2k k , B =
0 k 2 k
m 0 0
0 m 0 , k=1, m=1,
0 0 m
2= 1,555 3= 3,247
0,802 0,445
1