0% found this document useful (0 votes)
27 views83 pages

Unit I MSCS

Uploaded by

nidaaa.0209
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
27 views83 pages

Unit I MSCS

Uploaded by

nidaaa.0209
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 83

Mathematical structure for

Computer Science
UNIT I

Matrices
– Introduction
– Determination
– Inverse of a matrix
– Rank of a Matrix
– Eigen value Problems
UNIT II

System of Simultaneous Linear algebraic Equation


– Gauss elimination
– Gauss Jordon
– Gauss Seidal methods
UNIT III
Numerical Differentiations
– Newton‘s forward Difference
– Backward Difference
– Starling formula
Numerical Integration
– Trapezoidal Rule
– Simpson‘s rule
UNIT IV

Measures of central tendency


– Mean Median and Mode
– Relationship among mean media and mode.
Measures of dispersion
– Range
– quartile deviation
– Standard deviation
UNIT V

Regression and Correlation


– Types of relationship
– Linear regression
– linear Correlation
– Coefficient of correlation
– Regression equation of variables
TEXT BOOKS

1 . Engineering Mathematics, Volume II, Dr M.K. Venkataraman, National Publishing Company, Chennai.
(Unit I)
2. Numerical Methods in Science & Engineering, M.K. Venkataraman, National Publishing Company,
Chennai, Revised Edition -2005 (Unit II & III)
3. Business Statistics, S.P. Gupta & M.P. Gupta, Sultan Chand and Sons (Unit IV & V)
UNIT I

Matrix

Matrix is an arrangement of elements (numbers) in rows and columns.

The numbers are enclosed by parentheses or brackets or double bars


For example,

1.
2.
3.
are all matrices.
If a salesman has the following sales record during three months for three items A, B and C the same cr De
written in a matrix form as given below:

Month Sales in units


A B C

Jan. 90 100 20

Feb. 130 50 40

Mar 60 100 30
2.Importance

As matrix enables compact presentation and facilitates smooth manipulations, it is used in many fields of study. It is
convenient for computer operations also.
The common operations of
Addition

Multiplication

Transposition

inversion, etc., are possible and simple in matrix algebra.


3. Notation

 Capital letters A,B,C, ………. are used to denote matrices.


 Small letters a,b,c,... with two subscripts denote the elements. The first subscript indicates the row while
the second indicates he column in which the element appears
The general of a matrix is

A=
4. Order of matrix

In linear algebra, the order of a matrix refers to the number of rows and columns in the matrix. A matrix with
m rows and n columns is said to have an order of m x n.
For example, consider the following matrix:
A= 1 2 3
4 5 6
This matrix has 2 rows and 3 columns, so its order is 2 x 3
TYPES OF MATRICES

Square matrix: A square matrix is a matrix where the number of rows is equal to the number of columns.
For example,
A=

is a 3 x 3 square matrix.


Diagonal matrix: A diagonal matrix is a square matrix where all the non-diagonal elements are zero. For
example,
D=

is a diagonal matrix.


TYPES OF MATRICES

Unit or Identity matrix: An identity matrix is a diagonal matrix where all the diagonal elements are 1. For
example,
I=

is a 3 x 3 identity matrix.


TYPES OF MATRICES

 Zero or Null matrix : If all the elements of a matrix are zeros,it is called zero or null matrix

 3*3 matrix
TYPES OF MATRICES

 Row matrix: If there is only one row is called row matrix


 Eg : A= [10 ,32, 44]

 Column matrix : If there is only one column is called column matrix


 Eg: A=
TYPES OF MATRICES

Upper triangular matrix: An upper triangular matrix is a square matrix where all the elements below the
diagonal are zero. For example,
U=

is an upper triangular matrix.


Lower triangular matrix: A lower triangular matrix is a square matrix where all the elements above the
diagonal are zero. For example,
L=

is a lower triangular matrix.


TYPES OF MATRICES

Symmetric matrix: A symmetric matrix is a square matrix where the elements are symmetric across the
diagonal. For example,
S=

is a symmetric matrix.


TYPES OF MATRICES

 Equal matrix: Two matrices A= ((are equal if and only if


1. They have same order
2. The elements at the corresponding places are equal

 Eg 1 : if A = and B = , A= B
 Eg 2: if A = and B= , A=B implies x=10 & y= 14
TYPES OF MATRICES

 Equivalent matrices: Two matrices A and B of the same order are said to be
equivalent if one of them can be obtained from the other by elementary
transformations

 A
TYPES OF MATRICES

 Scalar matrix : A diagonal matrix in which all the elements in the diagonal are equal is called a scalar
matrix
TYPES OF MATRICES

 Non singular matrix: A square matrix A is said to be non-singular if |A|

 Orthogonal matrix: A square matrix A is said to be an orthogonal matrix if A’A=AA’=I

 Submatrix: A matrix obtained by deleting one or more rows or one or more columns (or both)
is a sub matrix of a given matrix
Eg: If A = , [9 10 15], and [41] are a sub matrices of A
TYPES OF MATRICES

 Skew Symmetric matrix: A square matrix such that for all i and j is called a skew symmetric
matrix.

 A’=-A
Matrix Operations

 Addition

 Subtraction

 Scalar Multiplication

 Multiplication

 Transpose
Addition

 Eg: If A = B =

 A+B = B+A =
Subtraction

 Eg : If A = and B =

 A- B =

 B-A =

 A-B B-A
Scalar Multiplication

 Eg: If A = and B = , show that 5(A+B)= 5A+5B

 Eg: If A = , B = and C = find a and b when 2A+5B = C


Multiplication

 Eg: If A = (2 3 5) and B =

 Eg: If A = and B = find AB


Transpose

 Let A be a matrix of order m*n. the transpose of A is denoted by A’ or

 Eg: Verify that When A = and B =


A System of Linear Equations

 and

 A = = coefficient matrix

 X= = unknown vectors

 C = = constant vectors
Determinants

 With each square matrix A we can associate a determinant

 The determinant of a matrix is denoted by det(A) or |A|, where A is the matrix.


Let's calculate the determinant of a 3x3 matrix A
A =

Using the expansion by minors formula, we can choose the first row to expand the determinant:
det(A) = 1 * det([]) - 2 * det([]) + 3 * det([])
where each minor is a 2x2 matrix obtained by deleting the row and column containing the chosen element.
We can calculate the determinants of these minors as follows:
det() = 5*9 - 6*8 = 3
det() = 4*9 - 6*7 = -6
det() = 4*8 - 5*7 = -3
Substituting these values back into the expansion formula, we get:
det(A) = 1 * 3 - 2 * (-6) + 3 * (-3) = 0
Eg 2

𝑎 𝑏
=𝑎𝑑 − 𝑏𝑐
𝑐 𝑑
Minor and Cofactor

 Minor of an element of a determinant is the value of the lower order


determinant obtained by deleting the row and the column which contain the
element.
 Denoted by

 Depending on the position of an element, the minor itself is the cofactor or the
minor with change in sign is the cofactor
Take 2*2 matrix

 Eg :

ELEMENT MINOR COFACTOR

= =

= =

= =

= =
SIMILARLY, TAKE 3*3 MATRIX

𝑎1 𝑏1 𝑐1
𝑎2 𝑏2 𝑐2
𝑎3 𝑏3 𝑐3
Eg : find the minor & cofactor of all
the elements of

 Solution:

ELEMENT MINOR COFACTOR

3 0 0

2 5 -5

5 2 -2

0 3 3
Eg :

 Find the minor & cofactor of all the elements of


ELEMENT MINOR COFACTOR
5 21
6 6
7 2
0 -26
1 59
-3 -32
-2 -25
4 15
9 5
INVERSE OF A MATRIX

The inverse of a matrix is another matrix that, when multiplied by


the original matrix, results in the identity matrix. The inverse of a
matrix is useful for solving systems of linear equations, finding the
adjoint of a matrix, and performing other mathematical operations.
 To find the inverse of a matrix, we use a specific
formula that involves calculating the determinant and the adjoint of
the matrix. If the determinant is non-zero, then the matrix has an
inverse, and we can use the formula to find it.
Consider the matrix A:
A =

To find the inverse of A,


we first need to check if it is invertible
We can do this by calculating the determinant of A:
det(A) = [(2 * 3) - (1 * 4) ]= 6 - 4 = 2
Since the determinant is non-zero, A is invertible.
Next, we can find the inverse of A using the following formula:

A-1 = (Adj A)

Where adj(A) is the classical adjoint of A, which is obtained by taking the transpose of the
matrix of cofactors of A.
cof(A) =

adj(A) =

A-1 = ( )*

 =
Therefore, the inverse of A is:
A-1 =
METHOD I

Example 1
Find the inverse of
Solution

Let A=
Therefore, |A| = ad – bc
= , adj A =
:

= adj A
Example 2

Find the inverse of the matrix


Solution

Let A =
Therefore, =
Elements Minors Cofactors
1 =2 2

3 =6 -6

0 =4 4

0 =-21 21

4 =-7 -7

-6 =8 -8

-1 =-18 -18

5 =-6 6

-7 =4 4
Therefore, adj A =

Based on the first row, [ 1 0 -1]


|A| = (1)
= 1(-28+30) – 0 – 1(-18-0)
= 1(2)-1 (-18)
= 2+18
= 20
So, Inverse Matrix = adj A
= *
METHOD II

 Find from an equation aA+ bI = 0 or given


equation is to be rewritten after multiplying by
and substituting for for A , etc.,
Example 1

 If 10A -50I =0 and A = , find


Solution

Consider 10A -50I =0 --------------------------------------(1)


Post multiply by ,
10A -50I= 0 *
10I – 50 =0

50
I
I
*

=
Rank of a Matrix :

 The rank of a matrix is a measure of its linear independence and can be


calculated using various methods such as row echelon form, reduced row echelon form, and
determinants. The rank of a matrix has numerous applications in fields such as computer
graphics, statistics, and physics.
 The rank of a matrix can be used to determine if a system of linear
equations has a unique solution, no solution, or infinitely many solutions. It can also be used
to find the null space and column space of a matrix, which are important concepts in linear
algebra.
 For example,
Consider the matrix A:
 A=

To find the rank of this matrix, we can perform row operations to reduce it to row echelon form, and count the number
of non-zero rows.

Performing row operations, we can transform the matrix A into row echelon form :
Since there are two non-zero rows in this matrix, the rank of A
is 2.
Therefore, the rank of the matrix A is 2.
METHOD 1

Example 1.1

Find the rank of the matrix


Solution:

Let A=

Order of A is 2 × 2 ∴ ρ(A)≤ 2

Consider the second order minor

 = 15 -8 =7

There is a minor of order 2, which is not zero. ∴ρ (A) = 2


Example 2

Find the rank of


Solution

Let A =

Find |A| = 1 -2 +

= (24-25)-2(12-15)+3(10-12)
= -1+6-6
= -1
Therefore rank is 3

∴ρ (A) = 3
METHOD II

RANK FROM AN EQUIVALENT MATRIX

Eg 1

Find the rank of


 Eg 2

 Find the rank of A,B , A+B and AB A = and B=


SOLUTION OF A SYSTEM OF
SIMULTANEOUS LINEAR EQUATION

 AX =C

 AUGMENTED MATRIX AND IS DENOTED BY


(A:C)
Test for consistency and solve if consistent

4x+ 3y+2z+7=0
2x+y-4z+1=0
x-7y-2 = 0
EIGEN VALUES AND
EIGEN VECTORS
EIGEN VALUES
• EIGEN VALUES ARE THE SPECIAL SET OF
SCALAR VALUES THAT IS ASSOCIATED WITH
THE SET OF LINEAR EQUATIONS MOST
PROBABLY IN THE MATRIX EQUATIONS.
• FORMULA |A-
Eigen vectors
• EIGEN VECTORS ARE ALSO TERMED AS
CHARACTERISTIC ROOTS . IT IS A NON – ZERO
VECTOR THAT CAN BE CHANGED AT MOST BY ITS
SCALAR FACTORS AFTER THE APPLICATIONS OF
THE LINEAR TRANSFORMATION
• FORMULA (A- )X=0
Problem 1

 Find the Eigen value of the given matrix


A=
Solution:
Formula |A-
Given A = , I = and is eigen value
 Finda-
- =0
- = 0
=0
And find |a-
| | =0
- - 2+2 = 0
( ) – (-1)(2)
-3 +2 = 0
-3 +2 = 0
(-1) – 2(-1)=0
- - 2+2 = 0 (-1)(-2)=0
(-1) – 2(-1)=0
(-1)(-2)=0
= 1,2
i.e., eigen values =1,2
Problem 2

 Find the eigen values and eigen vectors of the matrix


a =
 given
 Formula |a-

a= , I = and is eigen value


By 3* 3 matrix
- +- =0 1

= Sum of the main diagonal of the given 3*3 matrix


= 2+2+2
=6
 = Sum of the minors of main diagonal of the given 3*3 matrix

 = + +

= (4-0) +(4-1) + (4-0)


= 4+3 + 4
 = 11
 = Determinant of the given matrix
 =2 +1
 = 2(4)-0+1(-2)
 = 8-2
 =6
 Substitute , , , in eqn 1
 - 6 + 11- 6= 0
 Find
 Put ()=0 , is a factor
 1 1 -6 11 -6
 0 1 -5 6
 1 -5 6 0

 -5 6= 0
 -2 6= 0
 (-2) – 3(-2)=0
 (-2) (-3) =0
 Eigen values are = 1,2,3
Eigen vectors
(a-

 A=
 A- =
 (A- )x = 0
 =0
 For eigen value

 =0
 =0
 + =0
 =0
 + =0
 =-
 Let = 1 so, = -1
 = 1, = 0 , = -1
Eigen value
 =
 For eigen value

 =0

 =0

 =0
 = 0 let = 1
 = 0, = 1 , = 0
Eigen value
 =
 For eigen value
 =0
 =0
 - + = 0 - = 0 - = - = Let = 1 so, = 1
 -=0 =0
 = 1, = 0 , = -1
Eigen value
 =

You might also like