Sie sind auf Seite 1von 4

Seminar 19: Computational Linear Algebra

Computational Linear Algebra 1. If the tensor S is dened by

1 2

S= 2 5

3 6 6

(a) Show that the tensor is symmetric (Sij = Sji) (b) Calculate Skk (c) Calculate the tensor norm dened by 2Sij Sij 2. A matrix V is dened by

5 1

V = 3

1 4 3

Write this matrix as the sum of a symmetric matrix A and an anti-symmetric matrix B . (Hint: The symmetric part Aij is given by Aij = 0.5(Vij + Vji))
1

3. A basic Matlab programme to calculate the product of a matrix A and a vector b reads: % % Initialisation matrix A A(1,1)=1; A(1,2)=2; A(1,3)=3; A(2,1)=-3; A(2,2)=-2; A(2,3)=-1; A(3,1)=2; A(3,2)=5; A(3,3)=6; % % Initialisation vector b b(1)=2; b(2)=0; b(3)=3;
2

% % Calculation of multiplication A b = c: % for i=1,3 c(i)=0; for j=1,3 c(i)=c(i)+A(i,j)*b(j); end end % % result is c % end of programme % Adapt this code to write a Matlab programme to perform the multiplication of two matrices A and B : Cij = Aik Bkj
3

using a loop over k for i, j = 1, 2, 3. REMARKS: Note that a matrix can also be initialised in Matlab by simply stating: % Initialisation matrix A A=[1 2 3; -3 -2 -1; 2 5 6]; % The semi-column in the denition of the matrix values denotes the end of a row. Hence a vector should be dened by: % Initialisation vector b b=[2; 0; 3]; % The semi-column at the end of a statement suppresses output.