Module 1: Systems of Linear Equations, Matrix Operations, and Quadratic Forms
Introduction to Matrices and Matrix Types
Overview & Applications:
Information in science, business, and mathematics is organized into rows and columns forming rectangular arrays called matrices.
Matrix representations of systems of equations are central to computational algorithms because computers are designed to manipulate structured arrays of numbers.
Matrices are formal mathematical objects governed by linear algebra, possessing structural properties and application domains across engineering, data science, and physical modeling.
Matrix Definition:
A matrix is a rectangular array of numbers enclosed in brackets.
A matrix containing rows and columns has order (read " by ").
General matrix structure:
Examples of Matrices:
Example 1:
Example 2:
Classification of Matrix Types:
Row Matrix: A matrix possessing only one row ().
Example:
Column Matrix: A matrix possessing only one column ().
Example:
Null Matrix (Zero Matrix): A matrix in which every entry is equal to zero.
Example:
Square Matrix: A matrix with an equal number of rows and columns ().
Example:
Diagonal Matrix: A square matrix in which all non-leading diagonal entries are zero ( for all ).
Example:
Scalar Matrix: A diagonal matrix whose leading diagonal entries are all identical.
Example:
Identity Matrix (Unit Matrix): A scalar matrix whose leading diagonal entries are all equal to .
Example:
Matrix Operations
Equality of Matrices:
Two matrices and are equal () if and only if both matrices have the same order and their corresponding elements are identical ( for all ).
Addition and Subtraction:
For matrices and of identical order , the sum/difference is an matrix obtained by adding or subtracting corresponding entries.
Scalar Multiplication:
For a scalar and matrix , the product is an matrix produced by multiplying every individual entry of by .
Matrix Multiplication:
The product matrix of matrix (order ) and matrix (order ) is defined if and only if the number of columns in equals the number of rows in ().
The resulting product matrix has dimensions .
Row Echelon Form and Reduced Row Echelon Form
Row Echelon Form:
A matrix is in echelon form if it meets two fundamental conditions:
All zero rows (rows consisting entirely of zeros), if any, are situated at the bottom of the matrix.
Each leading nonzero entry (the first nonzero element in a row) is located strictly to the right of the leading nonzero entry of the preceding row.
Example:
Reduced Row Echelon Form (Row Canonical Form):
A matrix is in row canonical form if it satisfies the echelon conditions (1) and (2) along with two additional requirements:
Each pivot entry (leading nonzero entry) is equal to .
Each pivot entry is the unique nonzero entry in its containing column.
Example 1:
Example 2:
Elementary Row Operations and Equivalent Matrices
Elementary Row Operations:
Given a matrix with rows , the permissible elementary row operations are:
Row Interchange: Exchanging row with row , written as R_i \longleftrightarrow R_j$.\n 2. **Row Scaling:** Replacing row R_ik R_iR_i \longrightarrow k R_i$.
Row Addition: Replacing row with the linear sum of and a scalar multiple of row , written as .
Note: The symbol "" denotes "changes to".
Equivalent Matrices:
Two matrices and are row equivalent if one can be transformed into the other through a finite sequence of elementary row operations.
Row Equivalence Examples:
Example 1: Show that the following matrices are row equivalent:
Example 2: Show that the following matrices are row equivalent:
Rank of a Matrix
Formal Definitions:
Sub-matrix Definition: A matrix has rank if:
It contains at least one square sub-matrix of order that is non-singular (determinant is non-zero).
Every square sub-matrix of order greater than is singular (determinant equals zero).
Echelon Definition: The rank of matrix equals the exact number of non-zero rows in its canonical form or row echelon form.
Notation: or .
Worked Problems and Applications:
Problem 1: Find the rank of the matrix:
Problem 2 (Social Media Influence Analysis): A digital marketing agency analyzes interaction among four social media influencers represented by the matrix:
* Positive entries indicate positive influence, negative entries indicate opposing influence, and zero indicates no direct influence.
* Task: Determine the matrix rank and state whether the interaction data provides four independent influence patterns or if some information is redundant.
Problem 3: Find the rank of the matrix:
Problem 4 (Machine Learning Feature Selection): A machine learning engineer analyzes relationship metrics among four input features for customer behavior prediction using the matrix:
* Task: Determine the matrix rank and conclude whether all four features contribute independent information to the predictive model or whether redundant features exist.
Problem 5: Find the rank of the matrix:
Systems of Linear Equations
General Form:
A linear system of equations in unknowns is expressed as:
are the system coefficients, and are the constant terms.
Solution and Consistency Definitions:
Solution: An ordered set of numbers satisfying all equations simultaneously.
Consistent System: A system possessing at least one solution.
Inconsistent System: A system possessing no valid solution.
Matrix Form Representation:
System equation: , where:
Augmented Matrix Representation:
Denoted and defined as:
Linear Homogeneous Systems
System Definition:
When (), the system is called a system of linear homogeneous equations.
Homogeneous systems always admit the zero or trivial solution ().
Because the trivial solution always exists, a system of linear homogeneous equations is inherently consistent.
Solution Procedure:
Represent the system as an augmented matrix .
Transform into its corresponding row reduced echelon form to identify .
Evaluate system criteria against the number of unknowns :
Case 1 (): System possesses only the trivial solution ().
Case 2 (): System possesses infinitely many non-trivial solutions. Assign arbitrary parameters to free variables and solve for the remaining variables using echelon back-substitution.
Problems and Applied Scenarios:
Problem 1: Find the solution to the system:
Problem 2 (Distributed Database System): A distributed database consists of three servers whose synchronization errors satisfy:
* Task: Determine the complete solution set and interpret the network synchronization error state.
Problem 3: Solve the system:
Problem 4 (Communication Network Flow Balancing): A computer network consists of three interconnected channels with data flow rate adjustments satisfying:
* Task: Determine the complete solution and evaluate whether data flow adjustments are independent or dependent.
Problem 5: Solve the system:
Linear Non-Homogeneous Systems and Gaussian Elimination
System Definition:
A linear system where at least one () is called a non-homogeneous system.
Gaussian Elimination Procedure:
Construct the augmented matrix .
Perform elementary row operations to reduce to row reduced echelon form.
Determine and .
Apply Consistency Rules:
Rule 1 (): The system is consistent and yields a unique solution.
Rule 2 (): The system is consistent and yields infinitely many solutions (parameterize free variables).
Rule 3 (): The system is inconsistent and possesses no solution.
Problems and Applied Scenarios:
Problem 1: Verify consistency and solve if solutions exist:
Problem 2 (Cloud Computing Resource Allocation): A cloud system allocates CPU capacity (), memory capacity (), and storage capacity () under requirements:
* Task: Solve the system and interpret the resource allocation state.
Problem 3: Verify consistency and solve if solutions exist:
Problem 4: Verify consistency and solve if solutions exist:
Problem 5 (Parallel Computing Load Balancing): Processor workloads across three computing units satisfy:
* Task: Solve the system and interpret the computational load allocation.
LU Decomposition Method
Definition and Existence Condition:
The factorization of a square matrix into , where is a unit lower triangular matrix and is an upper triangular matrix, is called LU decomposition.
Decomposition requires all principal minors of to be non-singular ():
Mathematical Formulation for Systems:
Given system , set :
Step 1: Write . Set where .
Step 2: Solve for using forward substitution:
Step 3: Solve for using back substitution:
Matrix Entry Determination Formulas:
Equating entries in yields:
Problems and Applied Scenarios:
Problem 1: Solve using LU decomposition:
Problem 2 (Traffic Signal Optimization): Intersection green light durations (in minutes) satisfy:
* Task: Solve using LU decomposition and determine individual green signal durations.
Problem 3: Solve using LU decomposition:
Problem 4 (Cybersecurity Risk Assessment): Risk factor weights for vulnerability severity (), threat frequency (), and data exposure impact () satisfy:
* Task: Solve using LU decomposition and interpret the resulting factor weights.
Eigenvalues and Eigenvectors
Definitions:
For an matrix , a non-zero vector is an eigenvector of if:
The scalar is an eigenvalue of , and is the eigenvector corresponding to
Characteristic Equation:
A scalar is an eigenvalue of if and only if it satisfies:
For a matrix:
where , , and .
For a matrix:
where and .
Problems and Applied Scenarios:
Problem 1: Find all eigenvalues and corresponding eigenvectors of:
Problem 2 (Network Adjacency Analysis): Three network nodes have adjacency matrix:
* Task: Determine eigenvalues and eigenvectors, and interpret their significance regarding network connectivity.
Problem 3: Find all eigenvalues and corresponding eigenvectors of:
Problem 4 (Data Cluster Similarity): Similarity relationships among three clusters in data mining are given by:
* Task: Determine eigenvalues and eigenvectors, interpreting their context in clustering.
Problem 5: Find all eigenvalues and corresponding eigenvectors of:
Problem 6: Find all eigenvalues and corresponding eigenvectors of:
Problem 7: Find all eigenvalues and corresponding eigenvectors of:
Properties of Eigenvalues
Fundamental Mathematical Properties:
Property a: A square matrix and its transpose share identical eigenvalues.
Property b: The sum of the eigenvalues of equals the trace of ().
Property c: The product of the eigenvalues of equals ().
Property d: Given eigenvalues of matrix :
(i) Matrix () has eigenvalues k\lambda_1, k\lambda_2, \dots, k\lambda_n$.\n * (ii) Matrix power A^pp > 0\lambda_1^p, \lambda_2^p, \dots, \lambda_n^p$.
(iii) Inverse matrix has eigenvalues provided \lambda_r \neq 0$.\n * **Property e:** Matrix A \pm kI\lambda_1 \pm k, \lambda_2 \pm k, \dots, \lambda_n \pm k$.
Property f: Eigenvalues of a real symmetric matrix are strictly real numbers.
Property g: If zero () is an eigenvalue of matrix , then is singular ().
Property h: For a triangular matrix or diagonal matrix, the eigenvalues are the leading diagonal entries.
Property i: Eigenvectors corresponding to distinct eigenvalues of a real symmetric matrix are mutually orthogonal.
Analytical Problems on Properties:
Problem 1: Find the sum and product of eigenvalues of:
Problem 2: Two eigenvalues of are equal and double the magnitude of the third. Find the eigenvalues of A^2$.\n * **Problem 3:** If one eigenvalue of A = \begin{pmatrix} 1 & -3 & 3 \ 3 & -5 & 3 \ 6 & -6 & 4 \end{pmatrix}44A$.
Problem 4: Given a matrix with one eigenvalue equal to , sum of all eigenvalues equal to , and product of all eigenvalues equal to , determine all three eigenvalues.
Problem 5: Given eigenvalues for matrix , find the eigenvalues of A^2 - 2I$.\n * **Problem 6:** Find the eigenvalues of A^2A^{-1} for matrix:\n\nA = \begin{pmatrix} 3 & 0 & 0 \ 5 & 4 & 0 \ 3 & 6 & 1 \end{pmatrix}\n\n# Diagonalization of Matrices\n\n* **Similarity of Matrices:**\n * Matrix BAPB = P^{-1}AP$.
If is similar to , then is similar to via , where .
Diagonalization Definition:
A square matrix is diagonalizable if there exists an invertible matrix such that is a diagonal matrix. The matrix diagonalizes .
Diagonalization Procedure:
Find all eigenvalues and corresponding linear independent eigenvectors of matrix A$.\n 2. Construct modal matrix P = \begin{pmatrix} X_1 & X_2 & \dots & X_n \end{pmatrix}_{n \times n}.\n 3. Compute inverse matrix P^{-1}.\n 4. Apply transformation P^{-1}AP = DD is the resulting diagonal matrix containing eigenvalues along its main diagonal.\n\n* **Problems and Applied Scenarios:**\n * **Problem 1:** Transform matrix to diagonal form:\n\n\begin{pmatrix} 1 & 1 & 3 \ 1 & 5 & 1 \ 3 & 1 & 1 \end{pmatrix}\n\n * **Problem 2 (Communication Network Modes):** Diagonalize adjacency matrix A = \begin{pmatrix} 0 & 1 & 1 \ 1 & 0 & 1 \ 1 & 1 & 0 \end{pmatrix} to determine independent communication modes.\n * **Problem 3:** Express matrix in diagonal form:\n\n\begin{pmatrix} 1 & 2 \ 2 & 4 \end{pmatrix}\n\n * **Problem 4:** Express matrix in diagonal form:\n\n\begin{pmatrix} 1 & 4 \ 2 & 3 \end{pmatrix}\n\n * **Problem 5 (Traffic Flow Modes):** Diagonalize road junction interaction matrix:\n\n\begin{pmatrix} 8 & -6 & 2 \ -6 & 7 & -4 \ 2 & -4 & 3 \end{pmatrix}\n\n * Task: Use diagonal form to identify independent traffic-flow modes.\n\n * **Problem 6:** Express matrix in diagonal form:\n\n\begin{pmatrix} 2 & 1 \ 1 & 2 \end{pmatrix}\n\n * **Problem 7:** Express matrix in diagonal form:\n\n\begin{pmatrix} 7 & 2 \ -4 & 1 \end{pmatrix}\n\n * **Problem 8:** Express matrix in diagonal form:\n\n\begin{pmatrix} 2 & 3 \ 4 & 1 \end{pmatrix}\n\n# Quadratic Forms\n\n* **Mathematical Definition:**\n * A homogeneous expression of the second degree in any number of variables is called a quadratic form.\n * Examples: 2x^2 + 5xy - 7y^23x_1^2 - 4x_1x_2 + 7x_2^2$.
General Algebraic Form:
For variable vector :
Matrix Representation:
System expression: , where is a real symmetric matrix () of order , called the matrix of the quadratic form.
Example: .
Problems:
Problem 1: Find matrix of quadratic form 2x_1^2 - 2x_2^2 + 4x_3^2 + 2x_1x_2 - 6x_1x_3 + 6x_2x_3$.\n * **Problem 2:** Find matrix of quadratic form 10x_1^2 + 2x_2^2 + 5x_3^2 - 4x_1x_2 + 6x_2x_3 - 10x_1x_3$.
Problem 3: Find quadratic form corresponding to matrix:
Problem 4: Find quadratic form corresponding to matrix:
Orthogonality and Vector Normalization
Orthogonal Matrix Definition:
A square matrix is orthogonal if , which implies A A^T = A^T A = I$.\n\n* **Pairwise Orthogonality:**\n * Vectors X_1, X_2, X_3 are pairwise orthogonal if:\n\nX_1 \cdot X_2^T = X_2 \cdot X_3^T = X_3 \cdot X_1^T = 0\n\n * Note: A matrix whose columns are pairwise orthogonal and normalized is an orthogonal matrix.\n\n* **Vector Normalization:**\n * The normalized vector of X = \begin{pmatrix} x_1 \ x_2 \ x_3 \end{pmatrix} is given by:\n\nX^N = \begin{pmatrix} \frac{x_1}{d} \ \frac{x_2}{d} \ \frac{x_3}{d} \end{pmatrix} \quad \text{where } d = \sqrt{x_1^2 + x_2^2 + x_3^2}\n\n# Canonical Form of Quadratic Forms and Nature Classification\n\n* **Canonical Form Transformation:**\n * For quadratic form Q = X^T A XX = PYPAQ to:\n\nQ = X^T A X = (PY)^T A (PY) = Y^T (P^T A P) Y = Y^T D Y\n\nQ = \lambda_1 y_1^2 + \lambda_2 y_2^2 + \dots + \lambda_n y_n^2\n\n * where D = \begin{pmatrix} \lambda_1 & 0 & \dots & 0 \ 0 & \lambda_2 & \dots & 0 \ \vdots & \vdots & \ddots & \vdots \ 0 & 0 & \dots & \lambda_n \end{pmatrix}.\n\n\n\n* **Nature Classification of Quadratic Form:**\n * A real quadratic form Q = X^T A Xn variables is classified as:\n * **Positive Definite:** All eigenvalues of A\lambda_i > 0).\n * **Negative Definite:** All eigenvalues of A\lambda_i < 0).\n * **Positive Semidefinite:** All eigenvalues of A\lambda_i \ge 0) with at least one eigenvalue equal to zero.\n * **Negative Semidefinite:** All eigenvalues of A\lambda_i \le 0) with at least one eigenvalue equal to zero.\n * **Indefinite:** Eigenvalues of A consist of both positive and negative values.\n\n* **Reduction Procedure Step-by-Step:**\n 1. Obtain symmetric matrix AQ = X^T A X.\n 2. Compute all eigenvalues \lambda_1, \lambda_2, \dots, \lambda_nX_1, X_2, \dots, X_n.\n 3. Verify pairwise orthogonality of eigenvectors (orthogonalize if degenerate) and compute normalized eigenvectors X_1^N, X_2^N, \dots, X_n^N.\n 4. Form normalized modal matrix P = \begin{pmatrix} X_1^N & X_2^N & \dots & X_n^N \end{pmatrix}.\n 5. Apply substitution X = PYQ = \lambda_1 y_1^2 + \lambda_2 y_2^2 + \dots + \lambda_n y_n^2$.
Determine nature classification based on eigenvalue signs.
Problems and Applied Scenarios:
Problem 1 (Traffic Congestion Model): Congestion across three junctions is modeled by .
Task: Find canonical form and determine nature of traffic network.
Problem 2: Find canonical form and determine nature of quadratic form 2x_1x_2 + 2x_1x_3 + 2x_2x_3$.\n * **Problem 3:** Find canonical form and determine nature of quadratic form 2x^2 + 2y^2 + 2z^2 + 2xy + 2yz + 2xz$.
Problem 4 (Network Router Performance): Performance across three routers is measured by 8x_1^2 + 7x_2^2 + 3x_3^2 - 12x_1x_2 + 4x_1x_3 - 8x_2x_3$.\n * Task: Determine canonical form and classify nature of network performance model.\n * **Problem 5:** Find canonical form and determine nature of quadratic form -2x^2 + 4xy - 2y^2$.
Problem 6: Find canonical form and determine nature of quadratic form $$x^2 - 4xy + y^2$.