octave: A = [2,1;3,2;-2,2] A = 2 1 3 2 -2 2 octave: A A = 2 1 3 2 -2 2
octave: c = 3 c = 3 octave: c*A ans = 6 3 9 6 -6 6
octave: B = [1,1;4,2;-2,1] B = 1 1 4 2 -2 1 octave: C = A + B C = 3 2 7 4 -4 3 octave: D = A - B D = 1 0 -1 0 0 1
octave: D = [2,1,3;-2,2,1] D = 2 1 3 -2 2 1 octave: C = D*A C = 1 10 0 4 octave: C = A*D C = 2 4 7 2 7 11 -8 2 -4 octave: D = [2,1,3] D = 2 1 3 octave: C = D*A C = 1 10 octave: C = A*D error: operator *: nonconformant arguments (op1 is 3x2, op2 is 1x3) error: evaluating binary operator `*' near line 44, column 6 error: evaluating assignment expression near line 44, column 3
octave: AT = A' AT = 2 3 -2 1 2 2 octave: ATT = AT' ATT = 2 1 3 2 -2 2
octave: U = ones(3,1) U = 1 1 1
octave: U = ones(3,2) U = 1 1 1 1 1 1
octave: S = [2,1,4;3,2,2;-2,2,3] S = 2 1 4 3 2 2 -2 2 3 octave: D = diag(S) D = 2 2 3 octave: D = diag(diag(S),0) D = 2 0 0 0 2 0 0 0 3
octave: I = eye(3) I = 1 0 0 0 1 0 0 0 1
octave: C = [2,1,5;1,3,4;5,4,-2] C = 2 1 5 1 3 4 5 4 -2 octave: CT = C' CT = 2 1 5 1 3 4 5 4 -2
octave: A = [4,2,2;4,6,8;-2,2,4] A = 4 2 2 4 6 8 -2 2 4 octave: AI = inv(A) AI = 1.00000 -0.50000 0.50000 -4.00000 2.50000 -3.00000 2.50000 -1.50000 2.00000 octave: A*AI ans = 1 0 0 0 1 0 0 0 1 octave: AI*A ans = 1 0 0 0 1 0 0 0 1
octave: C = [2,1,6;1,3,4;6,4,-2] C = 2 1 6 1 3 4 6 4 -2 octave: CI = inv(C) CI = 0.215686 -0.254902 0.137255 -0.254902 0.392157 0.019608 0.137255 0.019608 -0.049020 octave: d = det(C) d = -102c
octave: X = [3,2;2,-2;4,6;3,1] X = 3 2 2 -2 4 6 3 1 octave: r = rows(A) r = 3 octave: c = columns(X) c = 2
octave: A = [2,1;3,2;-2,2] A = 2 1 3 2 -2 2 octave: c = sum(A) c = 3 5 octave: r = sum(A') r = 3 5 0 octave: a = sum(sum(A)) a = 8
octave: cm = sum(A)/rows(A) cm = 1.0000 1.6667 octave: rm = sum(A')/columns(A) rm = 1.50000 2.50000 0.00000
octave: A A = 2 1 3 2 -2 2 octave: B = [1,1;3,4;2,2] B = 1 1 3 4 2 2 octave: C = [A,B] C = 2 1 1 1 3 2 3 4 -2 2 2 2
octave: C = [A;B] C = 2 1 3 2 -2 2 1 1 3 4 2 2
Multivariate Course Page
Phil Ender, 23oct03