Chapter 4 – Matrix CSNB 143 Discrete Mathematical Structures.

Slides:



Advertisements
Similar presentations
2.3 Modeling Real World Data with Matrices
Advertisements

CSNB143 – Discrete Structure
Chapter Matrices Matrix Arithmetic
1 Section 7.3 Representing relations (part 1: matrices)
Matrix Definition: An array of numbers in m rows and n colums is called an mxn matrix A square matrix of order n, is an (nxn) matrix.
Mathematics. Matrices and Determinants-1 Session.
Matrix Multiplication To Multiply matrix A by matrix B: Multiply corresponding entries and then add the resulting products (1)(-1)+ (2)(3) Multiply each.
MF-852 Financial Econometrics
Maths for Computer Graphics
CALCULUS – II Matrix Multiplication by Dr. Eman Saad & Dr. Shorouk Ossama.
Matrices MSU CSE 260.
MATRICES. Matrices A matrix is a rectangular array of objects (usually numbers) arranged in m horizontal rows and n vertical columns. A matrix with m.
3.8 Matrices.
Chapter 1: Matrices Definition 1: A matrix is a rectangular array of numbers arranged in horizontal rows and vertical columns. EXAMPLE:
Division in the Integers Theorem 1. If n and m are integers and n>0, then m=qn+r for unique integers q and r with 0
8.4 Matrix Operations Day 1 Thurs May 7 Do Now Solve X – 2y = -6 3x + 4y = 7.
February 25, 2002Applied Discrete Mathematics Week 5: Mathematical Reasoning 1 Addition of Integers How do we (humans) add two integers? Example: 7583.
ECON 1150 Matrix Operations Special Matrices
Mathematics for Computer Graphics. Lecture Summary Matrices  Some fundamental operations Vectors  Some fundamental operations Geometric Primitives:
CS 250, Discrete Structures, Fall 2011 Nitesh Saxena
1 C ollege A lgebra Systems and Matrices (Chapter5) 1.
Lecture 7 Matrices CSCI – 1900 Mathematics for Computer Science Fall 2014 Bill Pine.
If A and B are both m × n matrices then the sum of A and B, denoted A + B, is a matrix obtained by adding corresponding elements of A and B. add these.
Slide Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley.
Matrices Matrices A matrix (say MAY-trix) is a rectan- gular array of objects (usually numbers). An m  n (“m by n”) matrix has exactly m horizontal.
2009/9 1 Matrices(§3.8)  A matrix is a rectangular array of objects (usually numbers).  An m  n (“m by n”) matrix has exactly m horizontal rows, and.
Module #9: Matrices Rosen 5 th ed., §2.7 Now we are moving on to matrices, section 7.
Prepared by Deluar Jahan Moloy Lecturer Northern University Bangladesh
Chapter 6 Systems of Linear Equations and Matrices Sections 6.3 – 6.5.
Relations, Functions, and Matrices Mathematical Structures for Computer Science Chapter 4 Copyright © 2006 W.H. Freeman & Co.MSCS Slides Relations, Functions.
Chapter 6 Matrices and Determinants Copyright © 2014, 2010, 2007 Pearson Education, Inc Matrix Operations and Their Applications.
Meeting 18 Matrix Operations. Matrix If A is an m x n matrix - that is, a matrix with m rows and n columns – then the scalar entry in the i th row and.
CSCI 171 Presentation 9 Matrix Theory. Matrix – Rectangular array –i th row, j th column, i,j element –Square matrix, diagonal –Diagonal matrix –Equality.
For real numbers a and b,we always have ab = ba, which is called the commutative law for multiplication. For matrices, however, AB and BA need not be equal.
Matrices Section 2.6. Section Summary Definition of a Matrix Matrix Arithmetic Transposes and Powers of Arithmetic Zero-One matrices.
Matrices: Basic Operations and Their Properties
Chapter 2 … part1 Matrices Linear Algebra S 1. Ch2_2 2.1 Addition, Scalar Multiplication, and Multiplication of Matrices Definition A matrix is a rectangular.
CSNB143 – Discrete Structure Topic 3 – Matrices. Learning Outcomes Students should understand all matrices operations. Students should be able to differentiate.
Greatest Common Divisors & Least Common Multiples  Definition 4 Let a and b be integers, not both zero. The largest integer d such that d|a and d|b is.
1.3 Matrices and Matrix Operations. A matrix is a rectangular array of numbers. The numbers in the arry are called the Entries in the matrix. The size.
Copyright © Cengage Learning. All rights reserved. 2 SYSTEMS OF LINEAR EQUATIONS AND MATRICES.
Matrices and Determinants
MATRICES Operations with Matrices Properties of Matrix Operations
Matrices and Matrix Operations. Matrices An m×n matrix A is a rectangular array of mn real numbers arranged in m horizontal rows and n vertical columns.
MATRIX A set of numbers arranged in rows and columns enclosed in round or square brackets is called a matrix. The order of a matrix gives the number of.
Section 2.4. Section Summary  Sequences. o Examples: Geometric Progression, Arithmetic Progression  Recurrence Relations o Example: Fibonacci Sequence.
Matrix Algebra Definitions Operations Matrix algebra is a means of making calculations upon arrays of numbers (or data). Most data sets are matrix-type.
CS 285- Discrete Mathematics Lecture 11. Section 3.8 Matrices Introduction Matrix Arithmetic Transposes and Power of Matrices Zero – One Matrices Boolean.
A very brief introduction to Matrix (Section 2.7) Definitions Some properties Basic matrix operations Zero-One (Boolean) matrices.
2.1 Matrix Operations 2. Matrix Algebra. j -th column i -th row Diagonal entries Diagonal matrix : a square matrix whose nondiagonal entries are zero.
Matrices. Matrix A matrix is an ordered rectangular array of numbers. The entry in the i th row and j th column is denoted by a ij. Ex. 4 Columns 3 Rows.
Linear Algebra by Dr. Shorouk Ossama.
MTH108 Business Math I Lecture 20.
CSE 504 Discrete Mathematics & Foundations of Computer Science
CSNB 143 Discrete Mathematical Structures
4.5 Matrices.
Matrices and Matrix Operations
Properties and Applications of Matrices
MATRICES.
Discrete Structures – CNS2300
1.5 Matricies.
MATHEMATICS Matrix Multiplication
L6 matrix operations.
Matrix Multiplication
Sequences and Summations
Section 2.4 Matrices.
CS100: Discrete structures
Multiplication of Matrices
3.8 Matrices L Al-zaid Math1101.
Applied Discrete Mathematics Week 4: Functions
Presentation transcript:

Chapter 4 – Matrix CSNB 143 Discrete Mathematical Structures

Matrix Students should be able to read matrix and its entries without difficulties. Students should understand all matrices operations. Students should be able to differentiate different matrices and operations by different matrix. Students should be able to identify Boolean matrices and how to operate them.

Matrix An array of numbers arranged in m horizontal rows and n vertical columns: A = a 11 a 12 a 13 ……. a 1n a 21 a 22 a 23 …….. a 2n … … … ………… a m1 a m2 a m3 …… a mn The ith row of A is [a i1, a i2, a i3, …a in ]; 1  i  m The jth column of A is a 1j a 2j ; 1  j  n a 3j a mj

We say that A is a matrix m x n. If m = n, then A is a square matrix of order n, and a 11, a 22, a 33,..a nn form the main diagonal of A. a ij which is in the ith row and jth column, is said to be the i, jth element of A or the (i, j) entry of A, often written as A = [a ij ].

Ex 2: A = A square matrix A = [a ij ], for which every entry off the main diagonal is zero, that is a ij = 0 for i  j, is called a diagonal matrix.

Two m x n matrices A and B, A = [a ij ] and B = [b ij ], are said to be equal if a ij = b ij for 1  i  m, 1  j  n; that is, if corresponding elements are the same. Ex 3: A = a 5 3B = 1 5 x y b So, if A = B, then a = 1, x = 3, y = 2, b = 4.

Matrix summation If A = [a ij ] and B = [b ij ] are m x n matrices, then the sum of A and B is matrix C = [c ij ], defined by c ij = a ij + b ij ; 1  i  m, 1  j  n. C is obtained by adding the corresponding elements of A and B.

A = B = C = The sum of the matrices A and B is defined only when A and B have the same number of rows and the same number of columns (same dimension).

Exercise 1: a) Identify which matrices that the summation process can be done. b) Compute C + G, A + D, E + H, A + F. A = 2 1 B = C =

D = 3 3 E = F = G = 4 3 H =

A matrix in when all of its entries are zero is called zero matrix, denoted by 0. Theorems involved in summation : A + B = B + A. (A + B) + C = A + (B + C). A + 0 = 0 + A = A.

Matrices Product If A = [a ij ] is an m x p matrix and B = [b ij ] is a p x n matrix, then the product of A and B, denoted AB, will produce the m x n matrix C = [c ij ], defined by c ij = a i1 b 1j + a i2 b 2j + … + a ip b pj ; 1  i  n, 1  j  m That is, elements a i1, a i2,.. a ip from ith row of A and elements b 1j, b 2j,.. b pj from jth column of B, are multiplied for each corresponding entries and add all the products.

Ex 5: A = B = x x 2 AB = 2(3) + 3(-2) + -4(5)2(1) + 3(2) + -4(-3) 1(3) + 2(-2) + 3(5)1(1) + 2(2) + 3(-3)

=6 – 6 – – – 9 = x 2

Exercise 2: Identify which matrices that the product process can be done. List all pairs. Compute CA, AD, EG, BE, HE.

If A is an m x p matrix and B is a p x n matrix, in which AB will produce m x n, BA might be produce or not depends on: n  m, then BA cannot be produced. n = m, p  n, then we can get BA but the size will be different from AB. n = m= p, A  B, then we can get BA, the size of BA and AB is the same, but AB  BA. n = m = p, A = B, then we can get BA, the size of BA and AB is the same, and AB = BA.

A B AB B ABA (m x p) (p x n) (m x n) (p x n) (m x p) ? 2 x 3 3 x 4 2 x 4 3 x 4 2 x 3 X 2 x 3 3 x 2 2 x 2 3 X 2 2 X 33 X 3 2 X 2 2 X 2 2 X 2 2 X 2 2 X 22 X

MATRIX Identity matrix Let say A is a diagonal matrix n x n. If all entries on its diagonal are 1, it is called identity matrix, ordered n, written as I. Ex 7: Theorems involved are: A(BC) = (AB)C. A(B + C) = AB + AC. (A + B)C = AC + BC. IA = AI = A.

Transposition Matrix If A = [a ij ] is an m x n matrix, then A T = [a ij ] T is a n x m matrix, where a ij T = a ji ; 1  i  m, 1  j  n It is called transposition matrix for A. Ex 8: A = A T = Theorems involved are: (A T ) T = A (A + B) T = A T + B T (AB) T = B T A T

Matrix A = [a ij ] is said to be symmetric if A T = A, that is a ij = a ji, A is said to be symmetric if all entries are symmetrical to its main diagonal. Ex 9: A = B = Symmetric Not Symmetric, why?

Boolean Matrix and Its Operations Boolean matrix is an m x n matrix where all of its entries are either 1 or 0 only. There are three operations on Boolean: a) Join by Given A = [a ij ] and B = [b ij ] are Boolean matrices with the same dimension, join by A and B, written as A  B, will produce a matrix C = [c ij ], where c ij = 1if a ij = 1 OR b ij = 1 0if a ij = 0 AND b ij = 0 b) Meet Meet for A and B, both with the same dimension, written as A  B, will produce matrix D = [d ij ] where d ij = 1if a ij = 1 AND b ij = 1 0 if a ij = 0 OR b ij = 0

MATRIX Ex 10: A = 1 0 1B = A  B = 1 1 1A  B =

MATRIX c) Boolean product If A = [a ij ] is an m x p Boolean matrix, and B = [b ij ] is a p x n Boolean matrix, we can get a Boolean product for A and B written as A ⊙ B, producing C, where: c ij = 1 if a ik = 1 AND b kj = 1; 1  k  p. 0other than that It is using the same way as normal matrix product.

MATRIX Ex 11: A = B = x x 3 A ⊙ B = A ⊙ B = x 3

MATRIX Exercise 3: A = B = C = Find: a) A  B b) A  B c) A ⊙ B d) A  C e) A  C f) A ⊙ C g) B  C h) B  C i) B ⊙ C