Mada za sehemu hiiMatricesMada 5
Addition and subtraction
Matrix addition and subtraction can only be performed on matrices of the same order. These operations are carried out by adding or subtracting corresponding elements of the matrices. The resulting matrix has the same order as the original matrices.
a. Addition of matrices
Let
A=[abcd],B=[egfh]Then,
A+B=[a+eb+gc+fd+h]Properties of matrix addition
- If A and B are matrices of order m×n, then A+B is also a matrix of order m×n.
- Matrix addition is commutative:
A + B = B + A
3.Matrixadditionis∗∗associative∗∗:(A + B) + C = A + (B + C)
4.Addingamatrixtoitsnegativegivesazeromatrix:A + (-A) = 0
5.Addingazeromatrixtoanymatrixleavesthematrixunchanged:A + 0 = A
### b. Subtraction of matrices Using the same matrices:A = \begin{bmatrix} a & c \ b & d \end{bmatrix}, \quad B = \begin{bmatrix} e & f \ g & h \end{bmatrix}
Then,A - B = \begin{bmatrix} a - e & c - f \ b - g & d - h \end{bmatrix}
### Properties of matrix subtraction 1. Subtraction is **not commutative**:A - B \neq B - A
2. The result of subtracting two matrices of order $ m \times n $ is also a matrix of order $ m \times n $. 3. Matrix subtraction is **not associative**:(A - B) - C \neq A - (B - C)
4.Subtractingamatrixfromitselfyieldsthezeromatrix:A - A = 0
5.Subtractingazeromatrixfromamatrixleavesthematrixunchanged:A - 0 = A
6.Subtractingamatrixfromazeromatrixgivesthenegativeofthematrix:0 - A = -A
### Example Given:A = \begin{bmatrix} 3 & 1 & 5 \ 2 & 5 & 7 \end{bmatrix}, \quad B = \begin{bmatrix} 7 & 1 & 2 \ 8 & 9 & 3 \end{bmatrix}, \quad C = \begin{bmatrix} 1 & 1 & 1 \ 4 & 2 & 5 \end{bmatrix}
Find: 1. $ A + B $ 2. $ A - C $ 3. $ A + B - C $ ### Solution: 1. $$ A + B = \begin{bmatrix} 3 + 7 & 1 + 1 & 5 + 2 \\ 2 + 8 & 5 + 9 & 7 + 3 \end{bmatrix} = \begin{bmatrix} 10 & 2 & 7 \\ 10 & 14 & 10 \end{bmatrix}A - C = \begin{bmatrix} 3 - 1 & 1 - 1 & 5 - 1 \ 2 - 4 & 5 - 2 & 7 - 5 \end{bmatrix} = \begin{bmatrix} 2 & 0 & 4 \ -2 & 3 & 2 \end{bmatrix}
3. $$ A + B - C = \begin{bmatrix} 10 & 2 & 7 \\ 10 & 14 & 10 \end{bmatrix} - \begin{bmatrix} 1 & 1 & 1 \\ 4 & 2 & 5 \end{bmatrix} = \begin{bmatrix} 9 & 1 & 6 \\ 6 & 12 & 5 \end{bmatrix}Example
Let:
A=234781253,B=621453982Find:
- A+B
- A−B
Solution:
A + B = \begin{bmatrix} 2 + 6 & 7 + 4 & 2 + 9 \ 3 + 2 & 8 + 5 & 5 + 8 \ 4 + 1 & 1 + 3 & 3 + 2 \end{bmatrix} = \begin{bmatrix} 8 & 11 & 11 \ 5 & 13 & 13 \ 5 & 4 & 5 \end{bmatrix}
2. $$ A - B = \begin{bmatrix} 2 - 6 & 7 - 4 & 2 - 9 \\ 3 - 2 & 8 - 5 & 5 - 8 \\ 4 - 1 & 1 - 3 & 3 - 2 \end{bmatrix} = \begin{bmatrix} -4 & 3 & -7 \\ 1 & 3 & -3 \\ 3 & -2 & 1 \end{bmatrix}If A is any matrix and p is any scalar (real number), then the product pA is the matrix obtained by multiplying each entry of matrix A by the scalar p. The matrix pA is said to be a scalar multiple of A.
Example:
Let
A=[acbd],andp=3Then
3A=3⋅[acbd]=[3a3c3b3d]Properties of scalar multiplication
Let r and s be real numbers (scalars), and let A and B be matrices of the same order. Then the following properties hold:
- r(A±B)=rA±rB
- (r±s)A=rA±sA
- r(sA)=(rs)A
Example 10.6
Let
A=130021113,B=431125011a. Find A+B:
A+B=1+43+30+10+12+21+51+01+13+1=561146124b. Find 4(A+B):
4(A+B)=4⋅561146124=20244416244816Alternatively, using the distributive property:
4A=41200844412,4B=161244820044Then:
4A+4B=4+1612+120+40+48+84+204+04+412+4=20244416244816Conclusion: 4(A+B)=4A+4B, as expected.
Two matrices can be multiplied if and only if the number of columns in the first matrix is equal to the number of rows in the second matrix. If matrix A is of order m×a and matrix B is of order b×n, then the multiplication AB is possible if and only if a=b. The resulting matrix AB will be of order m×n.
Procedure for matrix multiplication
Let:
A=[acbd],B=[rusv]Then, to compute AB=A⋅B, follow these steps:
- Multiply the first row of A by the first column of B:
(a ;; b) \cdot \begin{bmatrix} r \ u \end{bmatrix} = ar + bu \quad \text{(1st element)}
2. Multiply the first row of $ A $ by the second column of $ B $:(a ;; b) \cdot \begin{bmatrix} s \ v \end{bmatrix} = as + bv \quad \text{(2nd element)}
3. Multiply the second row of $ A $ by the first column of $ B $:(c ;; d) \cdot \begin{bmatrix} r \ u \end{bmatrix} = cr + du \quad \text{(3rd element)}
4. Multiply the second row of $ A $ by the second column of $ B $:(c ;; d) \cdot \begin{bmatrix} s \ v \end{bmatrix} = cs + dv \quad \text{(4th element)}
Therefore, the resulting matrix $ AB $ is:AB = \begin{bmatrix} ar + bu & as + bv \ cr + du & cs + dv \end{bmatrix}
### Example Given:A = \begin{bmatrix} 2 & 2 \ 3 & 5 \end{bmatrix}, \quad B = \begin{bmatrix} 3 & 2 \ 1 & 4 \end{bmatrix}
### a. Find $ AB $ To compute $ AB $, we multiply matrix $ A $ (order $ 2 \times 2 $) by matrix $ B $ (order $ 2 \times 2 $):AB = \begin{bmatrix} 2 & 2 \ 3 & 5 \end{bmatrix} \cdot \begin{bmatrix} 3 & 2 \ 1 & 4 \end{bmatrix}
\begin{bmatrix} (2 \cdot 3 + 2 \cdot 1) & (2 \cdot 2 + 2 \cdot 4) \ (3 \cdot 3 + 5 \cdot 1) & (3 \cdot 2 + 5 \cdot 4) \end{bmatrix}
\begin{bmatrix} 6 + 2 & 4 + 8 \ 9 + 5 & 6 + 20 \end{bmatrix}
\begin{bmatrix} 8 & 12 \ 14 & 26 \end{bmatrix}
### b. Is $ AB = BA $? Now compute $ BA $:BA = \begin{bmatrix} 3 & 2 \ 1 & 4 \end{bmatrix} \cdot \begin{bmatrix} 2 & 2 \ 3 & 5 \end{bmatrix}
\begin{bmatrix} (3 \cdot 2 + 2 \cdot 3) & (3 \cdot 2 + 2 \cdot 5) \ (1 \cdot 2 + 4 \cdot 3) & (1 \cdot 2 + 4 \cdot 5) \end{bmatrix}
\begin{bmatrix} 6 + 6 & 6 + 10 \ 2 + 12 & 2 + 20 \end{bmatrix}
\begin{bmatrix} 12 & 16 \ 14 & 22 \end{bmatrix}
Clearly,AB = \begin{bmatrix} 8 & 12 \ 14 & 26 \end{bmatrix} \ne BA = \begin{bmatrix} 12 & 16 \ 14 & 22 \end{bmatrix}
Matrix multiplication is *not commutative*, i.e., in general $ AB \ne BA $. ### Example Let:A = \begin{bmatrix} 2 & 5 & 7 \ 8 & 10 & 9 \end{bmatrix}, \quad B = \begin{bmatrix} 7 \ 3 \ 2 \end{bmatrix}
### Find $ AB $ Matrix $ A $ is of order $ 2 \times 3 $, and matrix $ B $ is of order $ 3 \times 1 $. Since the number of columns in $ A $ equals the number of rows in $ B $, multiplication is possible, and the result will be of order $ 2 \times 1 $.AB = \begin{bmatrix} 2 & 5 & 7 \ 8 & 10 & 9 \end{bmatrix} \cdot \begin{bmatrix} 7 \ 3 \ 2 \end{bmatrix}
\begin{bmatrix} 2 \cdot 7 + 5 \cdot 3 + 7 \cdot 2 \ 8 \cdot 7 + 10 \cdot 3 + 9 \cdot 2 \end{bmatrix}
\begin{bmatrix} 14 + 15 + 14 \ 56 + 30 + 18 \end{bmatrix}
\begin{bmatrix} 43 \ 104 \end{bmatrix}
The product $ AB $ is a matrix of order $ 2 \times 1 $.Let A be an m×n matrix. The transpose of matrix A, denoted by AT, is the n×m matrix obtained by interchanging the rows and columns of A.
Examples:
If
A=adgbehcfithenAT=abcdefghiIf
B=[2435]thenBT=[2345]If
C=359172480thenCT=314578920Example
Given:
A=[3512],B=[−45−3−2]Verify that (AB)T=BTAT
Step 1: Compute AB
AB=[3512]⋅[−45−3−2]=[3(−4)+1(5)5(−4)+2(5)3(−3)+1(−2)5(−3)+2(−2)]=[−12+5−20+10−9−2−15−4]=[−7−10−11−19]Step 2: Compute (AB)T
(AB)T=[−7−10−11−19]T=[−7−11−10−19]Step 3: Compute BT and AT
BT=[−45−3−2]T=[−4−35−2],AT=[3512]T=[3152]Step 4: Compute BTAT
BTAT=[−4−35−2]⋅[3152]=[−4⋅3+5⋅1−3⋅3+(−2)⋅1−4⋅5+5⋅2−3⋅5+(−2)⋅2]=[−12+5−9−2−20+10−15−4]=[−7−11−10−19]Conclusion:
(AB)T=BTAT=[−7−11−10−19]Hence, verified that (AB)T=BTAT.
Mwalimu
Unasoma somo hili? Niulize nikuelezee chochote kilichomo.
Ingia ili kumuuliza Mwalimu wa AI wa Sonza kuhusu mada hii.
Ingia ili kuulizaMajadiliano
Hakuna maswali bado