Explore BrainMass
Share

# Matrices with Matlab

This content was STOLEN from BrainMass.com - View the original, and get the already-completed solution here!

Given A = [ 2 0 4 B = [ 3 5 2
1 4 -1 0 8 4
3 1 2] 1 0 9]

C = [ 1 D = [ 1 4
2 -2 3]
3]

Respond to the following:
Q21. What is the transpose of A?
Q22. Solve for the determinant of A.
Q23. Calculate the inverse of D.
Q24. What is the product of A x C?
Q25. What is the rank of B?
Q26. Compute the sum of A + B.
Q27. What is the product of 3 x D?
Q28. Calculate the product of C x D.
Q29. Write a set of equations that describe the matrix equation Ax X = C.
Q30. Show that A+B = B+A
Q31. Show that A x B is not equal to B x A.

https://brainmass.com/math/matrices/matrices-with-matlab-515462

#### Solution Preview

The following is the output from a MATLAB file used to respond.

initialize matrix
A = [2 0 4; 1 4 -1; 3 1 2];
B = [3 5 2; 0 8 4; 1 0 9];
C = [1; 2; 3];
D = [1 4; -2 3];
transpose of A
Q21 = A'

Q21 =

2 1 3
0 4 1
4 -1 2

Determinant of A
Q22 = det(A)

Q22 =

-26

Inverse of D
Q23 = inv(D)

Q23 =

0.2727 -0.3636
0.1818 0.0909

Product of A x C
Q24 = A*C

Q24 =

14
6
11

Rank of B
Q25 = rank(B)

Q25 =

3

Sum of A+B
Q26 = A+B

Q26 =

5 5 6
1 ...

#### Solution Summary

Performing matrix algebra such as adding and multiplication of matrices.

\$2.19