Background pattern

Volume 1

Engineering Mathematics: Linear Algebra

Study Notes

Concept reference & formula sheet for this chapter

Syllabus: Matrices, determinants, System of linear equations, Eigenvalues and eigenvectors, LU decomposition.

Mark Distribution in Previous GATE

Welcome to the "Engineering Mathematics: Linear Algebra" chapter of your GATE Computer Science preparation. This section serves as a comprehensive, exam-focused reference to help you master the fundamental concepts and problem-solving techniques essential for success.

Subject Overview

Linear Algebra is the branch of mathematics concerning vector spaces and linear mappings between such spaces. It is a cornerstone of modern computing, underpinning areas like machine learning (e.g., PCA, SVMs, neural networks), computer graphics, data science, algorithm design, and optimization. For GATE CS, Linear Algebra typically contributes a significant portion of the Engineering Mathematics section, often carrying 3-5 marks out of the total 8-10 marks allocated to mathematics. Questions can range from direct computational problems (e.g., finding determinants, eigenvalues, ranks) to conceptual understanding (e.g., properties of vector spaces, subspaces, consistency of systems of equations) and application-based scenarios. Proficiency in this subject is not just about scoring marks but also about building a strong mathematical foundation for advanced computer science topics.

Topic-wise Key Concepts

Cartesian Coordinates

Cartesian coordinates provide a way to uniquely specify the position of a point in a space using numerical values. In 2D, a point is defined by its distance from two perpendicular axes (x,yx, y), and in 3D, by its distance from three mutually perpendicular axes (x,y,zx, y, z).

  • Definition: A system that uses an ordered set of numbers (coordinates) to specify the location of a point in a space. For a 2D plane, it's (x,y)(x, y); for 3D space, it's (x,y,z)(x, y, z).

  • Distance Formula (2D): The distance between two points P1(x1,y1)P_1(x_1, y_1) and P2(x2,y2)P_2(x_2, y_2) is given by:

d=(x2−x1)2+(y2−y1)2d = \sqrt{(x_2 - x_1)^2 + (y_2 - y_1)^2}

  • Distance Formula (3D): The distance between two points P1(x1,y1,z1)P_1(x_1, y_1, z_1) and P2(x2,y2,z2)P_2(x_2, y_2, z_2) is given by:

d=(x2−x1)2+(y2−y1)2+(z2−z1)2d = \sqrt{(x_2 - x_1)^2 + (y_2 - y_1)^2 + (z_2 - z_1)^2}

  • Midpoint Formula (2D): The midpoint MM of a line segment connecting P1(x1,y1)P_1(x_1, y_1) and P2(x2,y2)P_2(x_2, y_2) is:

M=(x1+x22,y1+y22)M = \left( \frac{x_1 + x_2}{2}, \frac{y_1 + y_2}{2} \right)

Properties:

  • Allows geometric problems to be translated into algebraic ones.

  • Forms the basis for vector representation and operations.

Common Pitfalls:

  • Confusing x and y coordinates, especially when dealing with transformations.

  • Incorrectly applying distance or midpoint formulas.

Problem-Solving Techniques:

  • Visualize the points and vectors in the coordinate system.

  • Break down complex geometric problems into simpler algebraic calculations.

Determinant

The determinant is a scalar value that can be computed from the elements of a square matrix. It provides crucial information about the matrix, such as its invertibility and the volume scaling factor of the linear transformation it represents.

  • Definition: A scalar value associated with a square matrix AA, denoted as det⁡(A)\det(A) or ∣A∣|A|.

Formulas:

    1. For a 2×22 \times 2 matrix: If A=(abcd)A = \begin{pmatrix} a & b \\ c & d \end{pmatrix}, then ∣A∣=ad−bc|A| = ad - bc.
    1. For a 3×33 \times 3 matrix (Sarrus' Rule): If A=(abcdefghi)A = \begin{pmatrix} a & b & c \\ d & e & f \\ g & h & i \end{pmatrix}, then

∣A∣=a(ei−fh)−b(di−fg)+c(dh−eg)|A| = a(ei - fh) - b(di - fg) + c(dh - eg). This can also be written as a∣efhi∣−b∣dfgi∣+c∣degh∣a \begin{vmatrix} e & f \\ h & i \end{vmatrix} - b \begin{vmatrix} d & f \\ g & i \end{vmatrix} + c \begin{vmatrix} d & e \\ g & h \end{vmatrix}.

    1. General n×nn \times n matrix (Laplace Expansion/Cofactor Expansion): ∣A∣=∑j=1n(−1)i+jaijMij|A| = \sum_{j=1}^n (-1)^{i+j} a_{ij} M_{ij} (along row ii) or ∣A∣=∑i=1n(−1)i+jaijMij|A| = \sum_{i=1}^n (-1)^{i+j} a_{ij} M_{ij} (along column jj) where MijM_{ij} is the minor (determinant of the submatrix obtained by deleting row ii and column jj).

Properties:

  • det⁡(AT)=det⁡(A)\det(A^T) = \det(A)

  • det⁡(AB)=det⁡(A)det⁡(B)\det(AB) = \det(A) \det(B)

  • det⁡(kA)=kndet⁡(A)\det(kA) = k^n \det(A) for an n×nn \times n matrix AA and scalar kk.

  • If a matrix has a row or column of zeros, its determinant is 0.

  • If a matrix has two identical rows or columns, its determinant is 0.

  • If a matrix is triangular (upper or lower), its determinant is the product of its diagonal elements.

  • Swapping two rows/columns changes the sign of the determinant.

  • Adding a multiple of one row/column to another row/column does not change the determinant.

  • A square matrix AA is invertible if and only if det⁡(A)≠0\det(A) \neq 0.

  • det⁡(A−1)=1det⁡(A)\det(A^{-1}) = \frac{1}{\det(A)}

Common Pitfalls:

  • Sign errors in cofactor expansion.

  • Incorrectly applying properties, especially for scalar multiplication det⁡(kA)\det(kA).

  • Assuming det⁡(A+B)=det⁡(A)+det⁡(B)\det(A + B) = \det(A) + \det(B) (which is generally false).

Problem-Solving Techniques:

  • For larger matrices, use row/column operations to create zeros and simplify the calculation before applying cofactor expansion (e.g., make it triangular).

  • Exploit properties (e.g., identical rows/columns, triangular form) to quickly find the determinant.

  • Choose the row or column with the most zeros for cofactor expansion.

Eigen Value

Eigenvalues are special scalar values associated with a square matrix that characterize its fundamental properties. When a linear transformation is applied to an eigenvector, the eigenvector's direction remains unchanged, only its magnitude is scaled by the corresponding eigenvalue.

  • Definition: For a square matrix AA, a scalar λ\lambda is an eigenvalue if there exists a non-zero vector v\mathbf{v} (eigenvector) such that Av=λvA\mathbf{v} = \lambda\mathbf{v}.

Formulas/Theorems:

    1. Characteristic Equation: To find eigenvalues, solve the equation det⁡(A−λI)=0\det(A - \lambda I) = 0, where II is the identity matrix of the same dimension as AA.
    1. Cayley-Hamilton Theorem: Every square matrix satisfies its own characteristic equation. If P(λ)=det⁡(A−λI)P(\lambda) = \det(A - \lambda I) is the characteristic polynomial, then P(A)=0P(A) = 0. This is useful for finding powers of a matrix or its inverse.
    1. Sum of Eigenvalues: The sum of the eigenvalues of a matrix AA is equal to its trace (sum of diagonal elements): ∑λi=trace(A)\sum \lambda_i = \text{trace}(A).
    1. Product of Eigenvalues: The product of the eigenvalues of a matrix AA is equal to its determinant: ∏λi=det⁡(A)\prod \lambda_i = \det(A).

Properties:

  • If λ\lambda is an eigenvalue of AA, then λk\lambda^k is an eigenvalue of AkA^k.

  • If λ\lambda is an eigenvalue of AA, then 1/λ1/\lambda is an eigenvalue of A−1A^{-1} (if AA is invertible).

  • If λ\lambda is an eigenvalue of AA, then kλk\lambda is an eigenvalue of kAkA.

  • The eigenvalues of a symmetric matrix are always real.

  • Eigenvectors corresponding to distinct eigenvalues are linearly independent.

  • For a real symmetric matrix, eigenvectors corresponding to distinct eigenvalues are orthogonal.

  • The eigenvalues of a triangular matrix (upper or lower) are its diagonal entries.

  • A matrix AA is singular (non-invertible) if and only if 0 is an eigenvalue of AA.

Common Pitfalls:

  • Algebraic errors when solving the characteristic equation.

  • Forgetting to check for non-zero eigenvectors.

  • Confusing algebraic and geometric multiplicity.

Problem-Solving Techniques:

  • Always start by setting up the characteristic equation det⁡(A−λI)=0\det(A - \lambda I) = 0.

  • For 2×22 \times 2 matrices, use λ2−trace(A)λ+det⁡(A)=0\lambda^2 - \text{trace}(A)\lambda + \det(A) = 0.

  • Use the sum and product of eigenvalues properties to verify your calculated eigenvalues or to find a missing eigenvalue.

  • For eigenvectors, substitute each eigenvalue back into (A−λI)v=0(A - \lambda I)\mathbf{v} = \mathbf{0} and solve the resulting system of equations.

Gaussian Elimination

Gaussian elimination is an algorithm used to solve systems of linear equations, find the rank of a matrix, compute the inverse of a matrix, and calculate determinants. It transforms a matrix into row echelon form using elementary row operations.

  • Definition: A systematic procedure to transform a matrix into row echelon form (or reduced row echelon form) using elementary row operations.

Elementary Row Operations:

    1. Swapping two rows (Ri↔RjR_i \leftrightarrow R_j).
    1. Multiplying a row by a non-zero scalar (kRi→RikR_i \rightarrow R_i).
    1. Adding a multiple of one row to another row (Ri+kRj→RiR_i + kR_j \rightarrow R_i).

Row Echelon Form (REF): A matrix is in REF if:

  • All non-zero rows are above any rows of all zeros.

  • The leading entry (pivot) of each non-zero row is in a column to the right of the leading entry of the row above it.

  • All entries in a column below a leading entry are zeros.

Reduced Row Echelon Form (RREF): A matrix is in RREF if it is in REF and:

  • The leading entry in each non-zero row is 1 (called a leading 1).

  • Each column containing a leading 1 has zeros everywhere else.

Applications:

  • Solving systems of linear equations.

  • Finding the rank of a matrix.

  • Computing the inverse of a matrix (by augmenting [A∣I][A|I] and reducing to [I∣A−1][I|A^{-1}]).

  • Calculating determinants (by keeping track of row operations).

Common Pitfalls:

  • Arithmetic errors during row operations.

  • Forgetting to apply operations to the augmented part of the matrix when solving systems or finding inverses.

  • Incorrectly identifying pivot elements.

Problem-Solving Techniques:

  • Always aim to create zeros below the pivot elements first.

  • Work column by column from left to right.

  • Use fractions carefully; sometimes it's better to multiply a row to avoid fractions temporarily.

  • For solving systems, use back-substitution after reaching REF.

LU Decomposition

LU decomposition factors a square matrix AA into the product of a lower triangular matrix LL and an upper triangular matrix UU. This factorization is particularly useful for efficiently solving multiple systems of linear equations with the same coefficient matrix, as it simplifies the process into two triangular systems.

  • Definition: A factorization of a square matrix AA into the product of a lower triangular matrix LL (with 1s on the diagonal) and an upper triangular matrix UU, such that A=LUA = LU.

Process:

    1. Use Gaussian elimination to transform AA into an upper triangular matrix UU.
    1. The lower triangular matrix LL is constructed using the multipliers used in the Gaussian elimination process. If Ri−kRj→RiR_i - kR_j \rightarrow R_i was used, then Lij=kL_{ij} = k. The diagonal elements of LL are 1s.
    1. If row swaps are needed, a permutation matrix PP is introduced, such that PA=LUPA = LU.
  • Solving Ax=bA\mathbf{x} = \mathbf{b} using LU Decomposition:

    1. Substitute A=LUA = LU: LUx=bLU\mathbf{x} = \mathbf{b}.
    1. Let Ux=yU\mathbf{x} = \mathbf{y}.
    1. Solve Ly=bL\mathbf{y} = \mathbf{b} for y\mathbf{y} using forward substitution (since LL is lower triangular).
    1. Solve Ux=yU\mathbf{x} = \mathbf{y} for x\mathbf{x} using backward substitution (since UU is upper triangular).

Properties:

  • Not all matrices have an LU decomposition without pivoting (row swaps).

  • If AA is non-singular and all its leading principal minors are non-zero, then AA has a unique LU decomposition.

Common Pitfalls:

  • Incorrectly forming LL from the multipliers.

  • Errors in forward or backward substitution.

  • Forgetting the permutation matrix PP if row swaps are involved.

Problem-Solving Techniques:

  • Carefully track the multipliers used in Gaussian elimination to construct LL.

  • Practice forward and backward substitution for efficiency.

  • Recognize when pivoting is necessary (e.g., if a pivot element becomes zero).

Matrix

A matrix is a rectangular array of numbers, symbols, or expressions arranged in rows and columns. Matrices are fundamental to linear algebra, representing linear transformations, systems of equations, and data structures.

  • Definition: A rectangular array of numbers (or functions) arranged in mm rows and nn columns. Denoted as Am×nA_{m \times n}.

Types of Matrices:

  • Square Matrix: m=nm = n.

  • Row Matrix: m=1m = 1.

  • Column Matrix (Vector): n=1n = 1.

  • Identity Matrix (II): Square matrix with 1s on the main diagonal and 0s elsewhere. AI=IA=AAI = IA = A.

  • Zero Matrix (00): All elements are 0. A+0=AA + 0 = A.

  • Diagonal Matrix: Square matrix where all non-diagonal elements are 0.

  • Scalar Matrix: A diagonal matrix where all diagonal elements are equal.

  • Symmetric Matrix: A=ATA = A^T.

  • Skew-Symmetric Matrix: A=−ATA = -A^T. Diagonal elements are 0.

  • Orthogonal Matrix: AAT=ATA=IAA^T = A^T A = I, which implies A−1=ATA^{-1} = A^T. Determinant is ±1\pm 1.

  • Invertible/Non-singular Matrix: A square matrix AA for which there exists a matrix A−1A^{-1} such that AA−1=A−1A=IAA^{-1} = A^{-1}A = I. det⁡(A)≠0\det(A) \neq 0.

  • Singular Matrix: A square matrix AA for which det⁡(A)=0\det(A) = 0. It does not have an inverse.

Operations:

    1. Addition/Subtraction: Element-wise, only for matrices of the same dimensions. (A+B)ij=Aij+Bij(A + B)_{ij} = A_{ij} + B_{ij}.
    1. Scalar Multiplication: Multiply each element by the scalar. (kA)ij=kAij(kA)_{ij} = kA_{ij}.
    1. Matrix Multiplication: (AB)ij=∑k=1pAikBkj(AB)_{ij} = \sum_{k=1}^p A_{ik}B_{kj}. Requires number of columns of AA to equal number of rows of BB. Resulting matrix has dimensions m×qm \times q if AA is m×pm \times p and BB is p×qp \times q.
    1. Transpose (ATA^T): Rows become columns and columns become rows. (AT)ij=Aji(A^T)_{ij} = A_{ji}.
    1. Inverse (A−1A^{-1}): For a 2×22 \times 2 matrix A=(abcd)A = \begin{pmatrix} a & b \\ c & d \end{pmatrix}, A−1=1ad−bc(d−b−ca)A^{-1} = \frac{1}{ad-bc} \begin{pmatrix} d & -b \\ -c & a \end{pmatrix}. For general n×nn \times n, A−1=1det⁡(A)adj(A)A^{-1} = \frac{1}{\det(A)} \text{adj}(A), where adj(A)\text{adj}(A) is the adjugate matrix (transpose of the cofactor matrix).

Properties:

  • Matrix addition is commutative: A+B=B+AA + B = B + A.

  • Matrix multiplication is associative: (AB)C=A(BC)(AB)C = A(BC).

  • Matrix multiplication is generally NOT commutative: AB≠BAAB \neq BA.

  • (A+B)T=AT+BT(A + B)^T = A^T + B^T.

  • (AB)T=BTAT(AB)^T = B^T A^T.

  • (A−1)−1=A(A^{-1})^{-1} = A.

  • (AB)−1=B−1A−1(AB)^{-1} = B^{-1} A^{-1}.

  • (AT)−1=(A−1)T(A^T)^{-1} = (A^{-1})^T.

Common Pitfalls:

  • Incorrect dimensions for addition or multiplication.

  • Assuming commutativity for matrix multiplication.

  • Errors in calculating inverses, especially for larger matrices.

Problem-Solving Techniques:

  • Always check dimensions before performing operations.

  • For matrix multiplication, visualize the dot products of rows and columns.

  • For inverses, use the adjugate formula for 2×22 \times 2 and Gaussian elimination for larger matrices.

Multiplicity

Multiplicity refers to how many times an eigenvalue appears as a root of the characteristic polynomial (algebraic multiplicity) and the dimension of its corresponding eigenspace (geometric multiplicity). These concepts are crucial for understanding diagonalizability of a matrix.

Definition:

  • Algebraic Multiplicity (AM): The number of times an eigenvalue λ\lambda appears as a root of the characteristic polynomial det⁡(A−λI)=0\det(A - \lambda I) = 0.

  • Geometric Multiplicity (GM): The dimension of the eigenspace corresponding to λ\lambda, which is the number of linearly independent eigenvectors associated with λ\lambda. It is given by n−rank(A−λI)n - \text{rank}(A - \lambda I), where nn is the dimension of the matrix.

Properties/Theorems:

  • For any eigenvalue λ\lambda, 1≤GM(λ)≤AM(λ)1 \leq \text{GM}(\lambda) \leq \text{AM}(\lambda).

  • A matrix AA is diagonalizable if and only if for every eigenvalue λ\lambda, AM(λ)=GM(λ)\text{AM}(\lambda) = \text{GM}(\lambda).

  • If all eigenvalues are distinct, then AM(λ)=GM(λ)=1\text{AM}(\lambda) = \text{GM}(\lambda) = 1 for all λ\lambda, and the matrix is diagonalizable.

Common Pitfalls:

  • Confusing AM and GM.

  • Incorrectly calculating the rank of (A−λI)(A - \lambda I).

  • Assuming diagonalizability based only on AM without checking GM.

Problem-Solving Techniques:

  • First, find all eigenvalues and their algebraic multiplicities by solving det⁡(A−λI)=0\det(A - \lambda I) = 0.

  • For each eigenvalue, calculate the rank of (A−λI)(A - \lambda I) to find its geometric multiplicity.

  • Compare AM and GM for each eigenvalue to determine diagonalizability.

Orthonormality

Orthonormality describes a set of vectors that are mutually orthogonal (perpendicular) and each has a unit length (normalized). Orthonormal bases simplify many calculations in linear algebra, particularly in projections and coordinate transformations.

Definition:

  • Orthogonal Vectors: Two vectors u\mathbf{u} and \\mathbf{v}areorthogonaliftheirdotproductiszero:are orthogonal if their dot product is zero:\mathbf{u} \cdot \mathbf{v} = \mathbf{u}^T \mathbf{v} = 0$.

  • Normalized Vector: A vector u\mathbf{u} is normalized if its length (magnitude) is 1: ∥u∥=u⋅u=1\|\mathbf{u}\| = \sqrt{\mathbf{u} \cdot \mathbf{u}} = 1.

  • Orthonormal Set: A set of vectors {v1,v2,…,vk}\{\mathbf{v}_1, \mathbf{v}_2, \dots, \mathbf{v}_k\} is orthonormal if they are mutually orthogonal and each vector is normalized. That is, vi⋅vj=δij\mathbf{v}_i \cdot \mathbf{v}_j = \delta_{ij} (Kronecker delta), where δij=1\delta_{ij} = 1 if i=ji = j and 0 if i≠ji \neq j.

  • Gram-Schmidt Orthonormalization Process: A procedure to transform a set of linearly independent vectors {x1,…,xk}\{\mathbf{x}_1, \dots, \mathbf{x}_k\} into an orthonormal set {u1,…,uk}\{\mathbf{u}_1, \dots, \mathbf{u}_k\}.

    1. v1=x1\mathbf{v}_1 = \mathbf{x}_1
    1. v2=x2−projv1x2=x2−x2⋅v1∥v1∥2v1\mathbf{v}_2 = \mathbf{x}_2 - \text{proj}_{\mathbf{v}_1} \mathbf{x}_2 = \mathbf{x}_2 - \frac{\mathbf{x}_2 \cdot \mathbf{v}_1}{\|\mathbf{v}_1\|^2} \mathbf{v}_1
    1. v3=x3−projv1x3−projv2x3=x3−x3⋅v1∥v1∥2v1−x3⋅v2∥v2∥2v2\mathbf{v}_3 = \mathbf{x}_3 - \text{proj}_{\mathbf{v}_1} \mathbf{x}_3 - \text{proj}_{\mathbf{v}_2} \mathbf{x}_3 = \mathbf{x}_3 - \frac{\mathbf{x}_3 \cdot \mathbf{v}_1}{\|\mathbf{v}_1\|^2} \mathbf{v}_1 - \frac{\mathbf{x}_3 \cdot \mathbf{v}_2}{\|\mathbf{v}_2\|^2} \mathbf{v}_2
    1. Continue for all vectors.
    1. Normalize each vi\mathbf{v}_i: ui=vi∥vi∥\mathbf{u}_i = \frac{\mathbf{v}_i}{\|\mathbf{v}_i\|}.

Properties:

  • An orthonormal set of vectors is always linearly independent.

  • If QQ is an orthogonal matrix (columns form an orthonormal set), then QTQ=IQ^T Q = I, and Q−1=QTQ^{-1} = Q^T.

  • For an orthogonal matrix QQ, ∥Qx∥=∥x∥\|Q\mathbf{x}\| = \|\mathbf{x}\| (preserves length).

  • For an orthogonal matrix QQ, (Qx)⋅(Qy)=x⋅y(Q\mathbf{x}) \cdot (Q\mathbf{y}) = \mathbf{x} \cdot \mathbf{y} (preserves dot product and angle).

Common Pitfalls:

  • Arithmetic errors in Gram-Schmidt, especially with projections.
  • Forgetting to normalize vectors after making them orthogonal.
  • Confusing orthogonal with orthonormal.

Problem-Solving Techniques:

  • Systematically apply the Gram-Schmidt process, calculating one orthogonal vector at a time.
  • Double-check dot products to ensure orthogonality.
  • Always normalize the final set of orthogonal vectors.

Rank of Matrix

The rank of a matrix is a fundamental property that measures the "linear independence" present in its rows and columns. It indicates the dimension of the vector space spanned by its rows or columns, and is crucial for understanding the solvability of linear systems.

  • Definition: The maximum number of linearly independent row vectors (row rank) or column vectors (column rank) in a matrix. The row rank is always equal to the column rank.

Calculation Methods:

    1. Using Row Echelon Form: The rank of a matrix is the number of non-zero rows in its row echelon form.
    1. Using Determinants (Minors): The rank of a matrix AA is the largest integer rr such that there exists an r×rr \times r submatrix of AA with a non-zero determinant.

Properties/Theorems:

  • For an m×nm \times n matrix AA, rank(A)≤min⁡(m,n)\text{rank}(A) \leq \min(m, n).
  • rank(A)=0\text{rank}(A) = 0 if and only if AA is a zero matrix.
  • rank(A)=rank(AT)\text{rank}(A) = \text{rank}(A^T).
  • rank(AB)≤min⁡(rank(A),rank(B))\text{rank}(AB) \leq \min(\text{rank}(A), \text{rank}(B)).
  • Rank-Nullity Theorem: For an m×nm \times n matrix AA, rank(A)+nullity(A)=n\text{rank}(A) + \text{nullity}(A) = n, where nullity(A)\text{nullity}(A) is the dimension of the null space (kernel) of AA.
  • A square matrix AA of size n×nn \times n is invertible if and only if rank(A)=n\text{rank}(A) = n.
  • For a system Ax=b\mathbf{Ax} = \mathbf{b}:
  • ▪ Consistent if rank(A)=rank([A∣b])\text{rank}(A) = \text{rank}([A|\mathbf{b}]).
  • ▪ Unique solution if rank(A)=rank([A∣b])=n\text{rank}(A) = \text{rank}([A|\mathbf{b}]) = n (number of variables).
  • ▪ Infinitely many solutions if rank(A)=rank([A∣b])<n\text{rank}(A) = \text{rank}([A|\mathbf{b}]) < n.
  • ▪ Inconsistent if rank(A)≠rank([A∣b])\text{rank}(A) \neq \text{rank}([A|\mathbf{b}]).

Common Pitfalls:

  • Errors in Gaussian elimination leading to incorrect row echelon form.
  • Misinterpreting the number of non-zero rows.
  • Not considering the augmented matrix for system consistency.

Problem-Solving Techniques:

  • The most reliable method is to reduce the matrix to row echelon form using Gaussian elimination and count the number of non-zero rows.
  • For smaller matrices, checking determinants of submatrices can be faster.
  • Use the Rank-Nullity Theorem to find nullity if rank is known, or vice versa.

Singular Value Decomposition (SVD)

Singular Value Decomposition is a powerful matrix factorization technique that decomposes any m×nm \times n matrix AA into three matrices: UU, Σ\Sigma, and VTV^T. It generalizes the concept of eigenvalues and eigenvectors to non-square matrices and has broad applications in data compression, noise reduction, and recommender systems.

  • Definition: Any m×nm \times n matrix AA can be factored as A=UΣVTA = U\Sigma V^T, where:

  • UU is an m×mm \times m orthogonal matrix whose columns are the left singular vectors of AA.

  • Σ\Sigma is an m×nm \times n diagonal matrix with non-negative real numbers on the diagonal, called singular values (σi\sigma_i), arranged in decreasing order. The non-zero singular values are σ1≥σ2≥⋯≥σr>0\sigma_1 \geq \sigma_2 \geq \dots \geq \sigma_r > 0, where r=rank(A)r = \text{rank}(A).

  • VV is an n×nn \times n orthogonal matrix whose columns are the right singular vectors of AA. VTV^T is its transpose.

Relationship to Eigenvalues:

  • The singular values σi\sigma_i of AA are the square roots of the eigenvalues of ATAA^T A (or AATAA^T).
  • The columns of VV are the eigenvectors of ATAA^T A.
  • The columns of UU are the eigenvectors of AATAA^T.

Properties/Applications:

  • SVD exists for any matrix (square or rectangular).
  • The number of non-zero singular values is equal to the rank of the matrix.
  • Low-rank approximation: By keeping only the largest singular values and corresponding singular vectors, SVD can approximate a matrix with fewer components, useful for data compression.
  • Pseudo-inverse: The SVD can be used to compute the Moore-Penrose pseudo-inverse of a matrix.
  • Principal Component Analysis (PCA): SVD is closely related to PCA, where singular vectors correspond to principal components.

Common Pitfalls:

  • Confusing singular values with eigenvalues.
  • Incorrectly calculating eigenvectors for ATAA^T A or AATAA^T.
  • Not arranging singular values in decreasing order.

Problem-Solving Techniques:

  • Calculate ATAA^T A (or AATAA^T).
  • Find the eigenvalues of ATAA^T A. The square roots of these eigenvalues are the singular values σi\sigma_i.
  • Find the eigenvectors of ATAA^T A. These form the columns of VV.
  • Find the eigenvectors of AATAA^T. These form the columns of UU.
  • Alternatively, Ui=1σiAViU_i = \frac{1}{\sigma_i} A V_i.

Statistics

While a broad field, within the context of linear algebra for GATE CS, statistics primarily involves concepts like mean, variance, covariance, and their matrix representations. These are crucial for understanding data analysis techniques like PCA, which heavily rely on linear algebra.

  • Definition (Linear Algebra Context): Focuses on the mathematical tools (vectors, matrices) used to analyze and model data, particularly in multivariate statistics.

Key Concepts:

    1. Mean: For a vector x=[x1,…,xn]T\mathbf{x} = [x_1, \dots, x_n]^T, the mean is xˉ=1n∑i=1nxi\bar{x} = \frac{1}{n} \sum_{i=1}^n x_i.
    1. Variance: A measure of how spread out the data is. For a vector x\mathbf{x}, Var(x)=1n−1∑i=1n(xi−xˉ)2\text{Var}(\mathbf{x}) = \frac{1}{n-1} \sum_{i=1}^n (x_i - \bar{x})^2.
    1. Covariance: A measure of how two variables change together. For two vectors x\mathbf{x} and \\mathbf{y},, \text{Cov}(\mathbf{x}, \mathbf{y}) = \frac{1}{n-1} \sum_{i=1}^n (x_i - \bar{x})(y_i - \bar{y})$.
    1. Covariance Matrix: For a dataset with pp variables and nn observations, the covariance matrix Σ\Sigma is a p×pp \times p symmetric matrix where Σij=Cov(xi,xj)\Sigma_{ij} = \text{Cov}(\mathbf{x}_i, \mathbf{x}_j) and \\Sigma_{ii} = \text{Var}(\mathbf{x}_i)$.

Σ=1n−1XTX\Sigma = \frac{1}{n - 1} X^T X

where XX is the data matrix with columns centered (mean subtracted).

    1. Principal Component Analysis (PCA): A dimensionality reduction technique that uses the eigenvectors of the covariance matrix (or SVD of the data matrix) to find orthogonal directions (principal components) of maximum variance in the data.

Properties:

  • Covariance matrix is always symmetric and positive semi-definite.
  • Eigenvalues of the covariance matrix represent the variance along the principal components.
  • Eigenvectors of the covariance matrix are the principal components.

Common Pitfalls:

  • Confusing variance with standard deviation.
  • Incorrectly calculating covariance or covariance matrix.
  • Not centering data before calculating covariance matrix for PCA.

Problem-Solving Techniques:

  • Understand the definitions of mean, variance, and covariance.
  • For PCA, compute the covariance matrix, then find its eigenvalues and eigenvectors.
  • Relate SVD to PCA: SVD of the centered data matrix directly gives principal components and singular values related to variance.

Subspace

A subspace is a subset of a vector space that itself satisfies the properties of a vector space. It must contain the zero vector, be closed under vector addition, and closed under scalar multiplication. Subspaces are fundamental building

blocks for understanding the structure of vector spaces.

  • Definition: A subset WW of a vector space VV is a subspace of VV if WW is itself a vector space under the operations defined on VV.
  • Conditions for a Subspace: A non-empty subset WW of a vector space VV is a subspace if and only if:
    1. The zero vector of VV is in WW (0∈W\mathbf{0} \in W).
    1. WW is closed under vector addition: If u,v∈W\mathbf{u}, \mathbf{v} \in W, then u+v∈W\mathbf{u} + \mathbf{v} \in W.
    1. WW is closed under scalar multiplication: If u∈W\mathbf{u} \in W and cc is any scalar, then cu∈Wc\mathbf{u} \in W.
  • Important Subspaces Associated with a Matrix AA:
  • Column Space (Col(A)\text{Col}(A)): The span of the column vectors of AA. It is a subspace of Rm\mathbb{R}^m (if AA is m×nm \times n). dim⁡(Col(A))=rank(A)\dim(\text{Col}(A)) = \text{rank}(A).
  • Row Space (Row(A)\text{Row}(A)): The span of the row vectors of AA. It is a subspace of Rn\mathbb{R}^n. dim⁡(Row(A))=rank(A)\dim(\text{Row}(A)) = \text{rank}(A).
  • Null Space (Null(A)\text{Null}(A) or Ker(A)\text{Ker}(A)): The set of all vectors x\mathbf{x} such that Ax=0A\mathbf{x} = \mathbf{0}. It is a subspace of Rn\mathbb{R}^n. dim⁡(Null(A))=nullity(A)\dim(\text{Null}(A)) = \text{nullity}(A).
  • Left Null Space (Null(AT)\text{Null}(A^T)): The set of all vectors y\mathbf{y} such that ATy=0A^T\mathbf{y} = \mathbf{0}. It is a subspace of Rm\mathbb{R}^m.
  • Properties:
  • The intersection of two subspaces is always a subspace.
  • The union of two subspaces is generally not a subspace.
  • The sum of two subspaces W1+W2={w1+w2∣w1∈W1,w2∈W2}W_1 + W_2 = \{\mathbf{w}_1 + \mathbf{w}_2 \mid \mathbf{w}_1 \in W_1, \mathbf{w}_2 \in W_2\} is a subspace.
  • Common Pitfalls:
  • Forgetting to check all three conditions for a subspace (especially the zero vector).
  • Confusing the column space with the null space.
  • Assuming the union of subspaces is a subspace.
  • Problem-Solving Techniques:
  • To check if a set is a subspace, verify the three conditions.
  • To find a basis for the column space, identify the pivot columns of the original matrix after reducing to REF.
  • To find a basis for the null space, solve Ax=0A\mathbf{x} = \mathbf{0} and express the solution in terms of free variables.
  • To find a basis for the row space, use the non-zero rows of the REF of the matrix.

System of Equations

A system of linear equations is a collection of one or more linear equations involving the same set of variables. Linear algebra provides powerful tools to determine the existence and nature of solutions (unique, infinite, or no solution) for such systems.

  • Definition: A set of equations of the form a11x1+⋯+a1nxn=b1,…,am1x1+⋯+amnxn=bma_{11}x_1 + \dots + a_{1n}x_n = b_1, \dots, a_{m1}x_1 + \dots + a_{mn}x_n = b_m. This can be written in matrix form as Ax=bA\mathbf{x} = \mathbf{b}, where AA is the coefficient matrix, x\mathbf{x} is the vector of variables, and \\mathbf{b}$ is the constant vector.

  • Types of Systems:

  • Homogeneous System: Ax=0A\mathbf{x} = \mathbf{0}. Always consistent (has at least the trivial solution x=0\mathbf{x} = \mathbf{0}).

  • Non-homogeneous System: Ax=bA\mathbf{x} = \mathbf{b} where b≠0\mathbf{b} \neq \mathbf{0}.

  • Consistency and Number of Solutions (using Rank):

    1. Consistent System: A system has at least one solution if rank(A)=rank([A∣b])\text{rank}(A) = \text{rank}([A|\mathbf{b}]).
  • ▪ Unique Solution: If rank(A)=rank([A∣b])=n\text{rank}(A) = \text{rank}([A|\mathbf{b}]) = n (number of variables).

  • ▪ Infinitely Many Solutions: If rank(A)=rank([A∣b])<n\text{rank}(A) = \text{rank}([A|\mathbf{b}]) < n. The number of free variables is n−rank(A)n - \text{rank}(A).

    1. Inconsistent System: A system has no solution if rank(A)≠rank([A∣b])\text{rank}(A) \neq \text{rank}([A|\mathbf{b}]).
  • Solution Methods:

  • Gaussian Elimination/Row Reduction: Transform the augmented matrix [A∣b][A|\mathbf{b}] into row echelon form to solve by back-substitution.

  • Matrix Inverse Method: If AA is square and invertible, x=A−1b\mathbf{x} = A^{-1}\mathbf{b}. (Only for unique solutions).

  • Cramer's Rule: For a square system with a unique solution, xi=det⁡(Ai)det⁡(A)x_i = \frac{\det(A_i)}{\det(A)}, where AiA_i is the matrix formed by replacing the ii-th column of AA with b\mathbf{b}. (Computationally expensive for larger systems).

  • Properties of Homogeneous Systems:

  • Always has the trivial solution x=0\mathbf{x} = \mathbf{0}.

  • Has non-trivial solutions if and only if det⁡(A)=0\det(A) = 0 (for square AA) or rank(A)<n\text{rank}(A) < n.

  • The set of all solutions forms the null space of AA.

  • Common Pitfalls:

  • Arithmetic errors during row operations.

  • Incorrectly determining consistency or number of solutions.

  • Applying Cramer's rule or inverse method when not applicable (e.g., non-square matrix, singular matrix).

Problem-Solving Techniques:

  • Always form the augmented matrix [A∣b][A|\mathbf{b}].

  • Use Gaussian elimination to reduce the augmented matrix to row echelon form.

  • Analyze the rank of AA and [A∣b][A|\mathbf{b}] to determine consistency and number of solutions.

  • For homogeneous systems, look for non-trivial solutions if det⁡(A)=0\det(A) = 0 or rank(A)<n\text{rank}(A) < n.

Vector Space

A vector space is a fundamental algebraic structure consisting of a set of vectors, along with two operations: vector addition and scalar multiplication, which satisfy a set of ten axioms. It provides a generalized framework for working with vectors beyond simple geometric arrows.

  • Definition: A non-empty set VV of objects, called vectors, on which two operations are defined: vector addition (denoted by ++) and scalar multiplication (denoted by juxtaposition), subject to ten axioms. The scalars are typically real numbers (R\mathbb{R}) or complex numbers (C\mathbb{C}).

  • Axioms of a Vector Space: For all u,v,w∈V\mathbf{u}, \mathbf{v}, \mathbf{w} \in V and all scalars c,dc, d:

    1. u+v∈V\mathbf{u} + \mathbf{v} \in V (Closure under addition)
    1. u+v=v+u\mathbf{u} + \mathbf{v} = \mathbf{v} + \mathbf{u} (Commutativity of addition)
    1. (u+v)+w=u+(v+w)(\mathbf{u} + \mathbf{v}) + \mathbf{w} = \mathbf{u} + (\mathbf{v} + \mathbf{w}) (Associativity of addition)
    1. There exists a zero vector 0∈V\mathbf{0} \in V such that u+0=u\mathbf{u} + \mathbf{0} = \mathbf{u} (Additive identity)
    1. For each u∈V\mathbf{u} \in V, there exists an additive inverse −u∈V-\mathbf{u} \in V such that u+(−u)=0\mathbf{u} + (-\mathbf{u}) = \mathbf{0} (Additive inverse)
    1. cu∈Vc\mathbf{u} \in V (Closure under scalar multiplication)
    1. c(u+v)=cu+cvc(\mathbf{u} + \mathbf{v}) = c\mathbf{u} + c\mathbf{v} (Distributivity of scalar over vector addition)
    1. (c+d)u=cu+du(c + d)\mathbf{u} = c\mathbf{u} + d\mathbf{u} (Distributivity of scalar over scalar addition)
    1. c(du)=(cd)uc(d\mathbf{u}) = (cd)\mathbf{u} (Associativity of scalar multiplication)
    1. 1u=u1\mathbf{u} = \mathbf{u} (Multiplicative identity)

Key Concepts:

  • Span: The set of all possible linear combinations of a set of vectors {v1,…,vk}\{\mathbf{v}_1, \dots, \mathbf{v}_k\}. Denoted as span{v1,…,vk}\text{span}\{\mathbf{v}_1, \dots, \mathbf{v}_k\}. It is always a subspace.

  • Linear Independence: A set of vectors {v1,…,vk}\{\mathbf{v}_1, \dots, \mathbf{v}_k\} is linearly independent if the only solution to c1v1+⋯+ckvk=0c_1\mathbf{v}_1 + \dots + c_k\mathbf{v}_k = \mathbf{0} is c1=⋯=ck=0c_1 = \dots = c_k = 0.

  • Basis: A set of vectors in a vector space VV that is linearly independent and spans VV. The number of vectors in a basis is unique and is called the dimension of the vector space.

  • Dimension: The number of vectors in any basis for a vector space VV, denoted as dim⁡(V)\dim(V).

Examples of Vector Spaces:

  • Rn\mathbb{R}^n (n-dimensional real coordinate space)

  • The set of all m×nm \times n matrices.

  • The set of all polynomials of degree at most nn.

  • The set of all continuous functions on an interval.

Common Pitfalls:

  • Forgetting to check all axioms when verifying if a set is a vector space.

  • Confusing a vector space with a subspace.

  • Incorrectly determining linear independence or a basis.

Problem-Solving Techniques:

  • To check if a set is a vector space, verify all ten axioms.

  • To check linear independence, set up the equation c1v1+⋯+ckvk=0c_1\mathbf{v}_1 + \dots + c_k\mathbf{v}_k = \mathbf{0} and solve the resulting system of linear equations.

  • To find a basis, identify a linearly independent set that spans the space. For Rn\mathbb{R}^n, this often involves finding pivot columns of a matrix formed by the vectors.

Quick Formula Reference

Determinant:

  • 2×22 \times 2: ∣A∣=ad−bc|A| = ad - bc for A=(abcd)A = \begin{pmatrix} a & b \\ c & d \end{pmatrix}

  • Properties: ∣AT∣=∣A∣|A^T| = |A|, ∣AB∣=∣A∣∣B∣|AB| = |A||B|, ∣kA∣=kn∣A∣|kA| = k^n|A|, ∣A−1∣=1/∣A∣|A^{-1}| = 1/|A|

  • Invertible iff ∣A∣≠0|A| \neq 0

Matrix Operations:

  • Matrix Multiplication: (AB)ij=∑kAikBkj(AB)_{ij} = \sum_k A_{ik}B_{kj}

  • Inverse 2×22 \times 2: A−1=1ad−bc(d−b−ca)A^{-1} = \frac{1}{ad-bc} \begin{pmatrix} d & -b \\ -c & a \end{pmatrix}

  • General Inverse: A−1=1det⁡(A)adj⁡(A)A^{-1} = \frac{1}{\det(A)} \operatorname{adj}(A)

  • Transpose Properties: (A+B)T=AT+BT(A + B)^T = A^T + B^T, (AB)T=BTAT(AB)^T = B^T A^T

  • Inverse Properties: (A−1)−1=A(A^{-1})^{-1} = A, (AB)−1=B−1A−1(AB)^{-1} = B^{-1} A^{-1}

Eigenvalues & Eigenvectors:

  • Characteristic Equation: det⁡(A−λI)=0\det(A - \lambda I) = 0

  • Sum of Eigenvalues: ∑λi=trace⁡(A)\sum \lambda_i = \operatorname{trace}(A)

  • Product of Eigenvalues: ∏λi=det⁡(A)\prod \lambda_i = \det(A)

  • Cayley-Hamilton Theorem: P(A)=0P(A) = 0 where P(λ)P(\lambda) is the characteristic polynomial.

  • Algebraic Multiplicity (AM): Number of times λ\lambda is a root.

  • Geometric Multiplicity (GM): dim⁡(Null⁡(A−λI))=n−rank⁡(A−λI)\dim(\operatorname{Null}(A - \lambda I)) = n - \operatorname{rank}(A - \lambda I)

  • Diagonalizable if AM⁡(λ)=GM⁡(λ)\operatorname{AM}(\lambda) = \operatorname{GM}(\lambda) for all λ\lambda.

Rank of Matrix:

  • Number of non-zero rows in REF.

  • rank⁡(A)≤min⁡(m,n)\operatorname{rank}(A) \leq \min(m, n) for m×nm \times n matrix.

  • Rank-Nullity Theorem: rank⁡(A)+nullity⁡(A)=n\operatorname{rank}(A) + \operatorname{nullity}(A) = n (number of columns).

  • System Ax=bA\mathbf{x} = \mathbf{b} consistent if rank⁡(A)=rank⁡([A∣b])\operatorname{rank}(A) = \operatorname{rank}([A|\mathbf{b}]).

  • Unique solution if rank⁡(A)=rank⁡([A∣b])=n\operatorname{rank}(A) = \operatorname{rank}([A|\mathbf{b}]) = n.

  • Infinite solutions if rank⁡(A)=rank⁡([A∣b])<n\operatorname{rank}(A) = \operatorname{rank}([A|\mathbf{b}]) < n.

  • No solution if rank⁡(A)≠rank⁡([A∣b])\operatorname{rank}(A) \neq \operatorname{rank}([A|\mathbf{b}]).

LU Decomposition:

  • A=LUA = LU (or PA=LUPA = LU with permutation matrix PP)

  • Solve Ax=bA\mathbf{x} = \mathbf{b} by Ly=bL\mathbf{y} = \mathbf{b} (forward substitution) then Ux=yU\mathbf{x} = \mathbf{y} (backward substitution).

Orthonormality:

  • Orthogonal: u⋅v=0\mathbf{u} \cdot \mathbf{v} = 0

  • Normalized: ∥u∥=1\|\mathbf{u}\| = 1

  • Orthonormal: ui⋅uj=δij\mathbf{u}_i \cdot \mathbf{u}_j = \delta_{ij}

  • Orthogonal Matrix QQ: QTQ=I  ⟹  Q−1=QTQ^T Q = I \implies Q^{-1} = Q^T.

Singular Value Decomposition (SVD):

  • A=UΣVTA = U\Sigma V^T

  • Singular values σi\sigma_i are λi(ATA)\sqrt{\lambda_i(A^T A)}.

  • Columns of VV are eigenvectors of ATAA^T A.

  • Columns of UU are eigenvectors of AATAA^T.

Subspace Conditions:

  • Contains zero vector.

  • Closed under addition.

  • Closed under scalar multiplication.

Important Tips for GATE

  • Master the Basics: Ensure a strong understanding of fundamental definitions (e.g., matrix types, vector space axioms, linear independence). Many conceptual questions test these directly.

  • Practice Gaussian Elimination: This is a core algorithm. Practice it diligently for solving systems, finding rank, and computing inverses. Accuracy and speed are crucial here.

  • Understand Eigenvalue/Eigenvector Properties: Don't just memorize formulas. Understand why the sum of eigenvalues equals the trace and the product equals the determinant. These properties are often used as shortcuts or for verification.

  • Pay Attention to Matrix Dimensions: Always check if matrix operations (addition, multiplication) are valid based on dimensions. This prevents common errors, especially in matrix multiplication.

  • Rank-Nullity Theorem is Your Friend: This theorem is incredibly useful for quickly finding the nullity if the rank is known, or vice versa, and for analyzing the nature of solutions to linear systems.

  • Beware of Calculation Errors: Linear algebra problems often involve extensive calculations. Use the virtual calculator carefully and double-check intermediate steps. Simple arithmetic mistakes are a common reason for losing marks.

  • Distinguish Between Similar Concepts: Clearly differentiate between algebraic and geometric multiplicity, orthogonal and orthonormal vectors, and the various matrix subspaces (column space, null space, row space).

  • Practice Previous Year Questions: Solve as many GATE previous year questions as possible. This will familiarize

you with the typical question patterns, difficulty levels, and time constraints. Focus on understanding the solution approach rather than just getting the answer.