SlidesGroepA 2526
Introduction to linear algebra concepts and course structure
This section outlines the logistical framework for the linear algebra course, detailing required materials, assessment methods, and introducing the foundational concepts of linear equations and their solution sets.
1.1 Course structure and learning materials
The course employs several distinct teaching and learning modalities 1.
1.1.1 Contact moments
Contact moments are divided into lectures and practice sessions 2.
- Hoorcollege (Lecture): Used for presenting theory, working through examples, answering student questions, and discussing homework assignments. Students are permitted to ask questions during lectures 1 2.
- Oefenzittingen (Practice Sessions): These sessions are conducted under the supervision of an assistant and cover material deemed more challenging than the standard homework assignments. Students are strongly advised to prepare by reviewing the relevant theory beforehand 2.
1.1.2 Study materials
A variety of resources are provided for study and practice 1:
- Textbook: The "Lay" textbook serves as the primary reference, containing more detailed examples and exercises 1 2.
- MyMathLab: Used for assigned homework exercises 1.
- VTK Resources: Supplementary materials such as additions, exercise bundles, and lecture slides are available through VTK 1.
- Slides: The main purpose of the slides is to minimize the time spent copying notes, as not everything required is present on them; taking notes concurrently is essential. Slides are numbered to align with the Lay textbook and supplements 2.
- TOLEDO: This platform hosts the slides, video examples, preparatory material for MATLAB, lists detailing required knowledge ("What must I know/not know"), and sample examination questions 1.
- SPOC: A specific module concerning complex numbers is provided 1.
- Practice Exercises: The exercise bundle includes 8 exercises intended for pen-and-paper work and 3 sessions utilizing MATLAB on a PC 2.
Tip: Focus on understanding the theory presented in lectures and the textbook, as the slides are designed primarily to prevent excessive note-taking during class time 2.
1.2 Examination and preliminary tests
Assessment involves a final exam and a preliminary test (Tussentijdse toets) 3.
1.2.1 Preliminary test (TTT) rules
- The preliminary test is scheduled during a week without scheduled classes (lesluwe week) 3.
- The score achieved on the preliminary test will only be factored into the final grade if the student passes the TTT, and the score from the TTT is strictly higher than the score obtained on the final exam (score(TTT) > score(ex)) 3.
1.2.2 Exam format and allowed materials
The final examination is closed book 3.
- Allowed Materials: Students may use a faculty-approved calculator and a formula sheet (formularium) specified on TOLEDO 3.
- Question Types: Questions will cover theory, insight-based questions, proofs derived from the lectures or textbook, and exercises. Knowledge of the underlying theory is necessary to save time during problem-solving 3.
1.3 Fundamental algebraic structures
The course immediately introduces the fundamental building blocks of linear algebra: linear equations and systems thereof 3 5.
1.3.1 Linear equation definition
A linear equation is formally defined by the expression 4: a1x1+a2x2+⋯+anxn=b
- The components x1,…,xn are the unknowns or variables, which belong to the set of real numbers (R) or complex numbers (C) 4.
- The components a1,…,an are the coefficients, which also belong to R or C 4.
- The term b is referred to as the independent term or the right-hand side (rechter lid) 4.
Example: A concrete linear equation is 3x1−2x2+x3=1 4.
1.3.2 Solution set of a linear equation
A solution to the equation is a set of n specific numbers (s1,…,sn) substituted for (x1,…,xn) that transforms the equation into a true statement 4.
The solution set, denoted V, is the collection of all such solutions: V={solutions} 4.
Example: For the equation 3x1−2x2+x3=1, specific solutions in R include (1,1,0) and (−1,1,6). The complete solution set V can be parameterized as {(r,s,1−3r+2s) with r,s∈R} 4 5.
1.4 System of linear equations
A system of linear equations involves multiple linear equations combined 5.
A system consisting of m linear equations with n variables is represented generally as: a11x1+⋯+a1nxn⋮am1x1+⋯+amnxn=b1=bm
Example: A system with m=3 equations and n=3 variables: 3x1−2x2+x3−5x1+x2x1−x3=1=2=2 5.
Systems of linear equations and matrix methods
This major topic details the systematic approach to solving systems of linear equations using matrix representations, elementary row operations, and the interpretation of resulting echelon forms to determine solution sets.
2.1 Introduction to systems of linear equations and solutions
A solution to a system of m linear equations in n variables, (s1,…,sn), must satisfy all m equations simultaneously. The set of all solutions is called the solution set 6.
- If the solution set is not empty, the system is consistent. Consistency implies either a unique solution or infinitely many solutions 6.
- If the solution set is empty, the system is inconsistent (or strijdig) 6.
- Two systems are considered equivalent if they share the exact same solution set 6.
2.2 Matrix notation for linear systems
A system of m linear equations in n variables can be written in matrix form as:
a11x1+⋯+a1nxn⋮am1x1+⋯+amnxn=b1⋮=bm6.
This system is represented using matrices 7:
- Coefficient Matrix (A): Contains only the coefficients of the variables 6:
The matrix A has m rows and n columns 7. 2. Augmented Coefficient Matrix ([A∣b]): Includes the coefficient matrix A augmented by the column vector b of the right-hand side constants 6:
[A | \mathbf{b}] = \begin{pmatrix} a_{11} & \cdots & a_{1n} & b_1 \\ \vdots & \ddots & \vdots & \vdots \\ a_{m1} & \cdots & a_{mn} & b_m \end{pmatrix} [6](#page=6).Tip: For a system with m equations and n variables, the coefficient matrix A has dimensions m×n, and the augmented matrix [A∣b] has dimensions m×(n+1) 7.
2.3 Elementary Row Operations (ER) and Row Equivalence
Solving linear systems is achieved by applying Elementary Row Operations (ER) to the augmented matrix to obtain an equivalent, but simpler, system 8.
The three ER are 8:
- Row Replacement: Replacing row i with the sum of row i and a multiple c of row j: (row i) ← (row i) +c⋅(row j) 8.
- Row Swap: Interchanging two rows 8.
- Row Scaling: Multiplying a row by a non-zero scalar c=0: (row i) ←c⋅(row i) 8.
Properties of ER:
- Elementary row operations do not change the solution set of the system 8.
- Elementary row operations are reversible 8.
Two matrices A and B are row equivalent (denoted A∼B) if there exists a sequence of ER that transforms A into B 8.
Example: Solving the system 3x1−2x2+x3=1, −5x1+x2=2, x1−x3=2 involves applying ER to the augmented matrix 3−51−21010−1122 to simplify it, such as swapping Row 1 and Row 3 (R1↔R3) 9.
2.4 Echelon Forms
Row reduction aims to transform the augmented matrix into a standardized form to easily read the solutions 11 8.
2.4.1 Echelon form (EV)
A matrix is in Echelon Form (EV) if it satisfies three conditions 11:
- Any non-zero row has its leading entry (the first non-zero number from the left) in a column to the right of the leading entry of the row above it 11.
- Any rows consisting entirely of zeros are at the bottom of the matrix 11.
- All entries in a column below a leading entry are zero 11.
Note: Echelon form is not unique 11.
2.4.2 Reduced Echelon Form (GEV)
If an echelon form matrix satisfies two additional conditions, it is in Reduced Echelon Form (GEV) 11:
Theorem 1: The Reduced Echelon Form (GEV) of a matrix is unique 11.
2.5 Pivots, Pivot Columns, and Variables
In the context of EV or GEV:
- A Pivot Position is the (row,column) location of a pivot (leading entry) in the (G)EV 12.
- A Pivot Column (PK) in the original matrix A (or its (G)EV) is a column that contains a pivot 12.
- A column that does not contain a pivot is a Non-Pivot Column (NPK) 12.
- Rows containing exactly one pivot are non-zero rows; rows with no pivot are zero rows 12.
Tip: While the pivot positions are fixed by row operations, one cannot speak about the "pivot rows" of the original matrix A because row swaps change row indices 12.
2.5.1 Algorithm for Echelon Form (EV)
- Consider the entire matrix 13.
- Identify the leftmost non-zero column; this is the pivot column 13.
- Select a non-zero element in this column (the pivot) and use row swaps (if necessary) to place it at the top position of this column 13.
- Use row replacement operations to make all elements below the pivot zero 13.
- Cover the top row and return to step 2 for the remaining submatrix 13.
2.5.2 Algorithm for Reduced Echelon Form (GEV)
- First, transform the matrix into Echelon Form (EV) 13.
- Use row scaling to make all pivots equal to 1 13.
- Start with the last non-zero row 13.
- Use row replacement to make all entries above the pivot in that row zero 13.
- Repeat this process for all preceding rows 13.
2.6 Solving systems using GEV and parametric form
To solve a system Ax=b 14:
- Bring the augmented coefficient matrix [A∣b] into its unique Reduced Echelon Form (GEV) 14.
- The variables corresponding to pivot columns are basic variables 14.
- The variables corresponding to non-pivot columns are free variables 14.
- Express the basic variables as functions of the free variables and the constant terms from the right-hand side to find the parametric form of the solutions 14.
Example: If the GEV has non-pivot columns corresponding to variables x4 and x5, these are free variables, and the basic variables (x1,x2,x3, etc.) are written in terms of x4,x5, and the constants. The solution set V is written in vector form, often parametrized by r,s∈R if there are two free variables 14 16.
2.7 Consistency and Uniqueness of Solutions
The existence and nature of solutions are determined directly from the GEV of the augmented matrix [A∣b] 16.
Theorem 2 (Existence of a Solution): A linear system is consistent if and only if the right-hand column of the GEV of the augmented coefficient matrix is not a pivot column 16.
- If the right-hand column contains a leading 1 (a pivot), it corresponds to the equation 0=1, indicating an inconsistent system 16.
- If the system is consistent:
- It has a unique solution if there are no free variables (i.e., every column in A's GEV has a pivot) 16.
- It has infinitely many solutions if there is at least one free variable (i.e., at least one non-pivot column in A's GEV) 16.
Example (Inconsistent System): If the row operations yield a row like (0001) in the augmented matrix, this translates to 0=1, and the system is inconsistent 17.
2.8 Homogeneous Linear Equations
A system of homogeneous linear equations is represented by Ax=0 28.
- This system always has the trivial solution x=0. Thus, homogeneous systems are never inconsistent 28.
- The system possesses non-trivial solutions if and only if there is at least one free variable in A's GEV, which is equivalent to A having at least one non-pivot column 28.
- Non-trivial solutions are found by reducing A to GEV and expressing the basic variables as functions of the free variables (the parametric form) 28.
Example: For a system represented by the GEV:
\begin{pmatrix} 1 & 0 & 0 & -7 & 5 \\ 0 & 0 & 1 & -2 & -3 \\ 0 & 0 & 0 & 0 & 0 \end{pmatrix} [28](#page=28).Pivot variables are x1 and x3. Free variables are x2 and x4. The solution is written:
x1x3=5+7x2−6x4=−3+2x4In vector form, with x2 and x4 as parameters:
\begin{pmatrix} x_1 \\ x_2 \\ x_3 \\ x_4 \end{pmatrix} = \begin{pmatrix} 5 \\ 0 \\ -3 \\ 0 \end{pmatrix} + x_2 \begin{pmatrix} 7 \\ 1 \\ 0 \\ 0 \end{pmatrix} + x_4 \begin{pmatrix} -6 \\ 0 \\ 2 \\ 1 \end{pmatrix} [28](#page=28).
Vectors, span, and linear transformations
This topic establishes fundamental concepts in linear algebra, detailing vector operations, linear combinations, the concept of span, the equivalence between systems of linear equations and vector equations, and the representation of linear transformations via matrices.
3.1 Vectors in Rn
A vector x in Rn is an ordered list of n real numbers, x=x1x2⋮xn∈Rn. A row vector is represented as x=[x1 x2 … xn]. Vectors are equal if and only if all their corresponding elements are equal. This concept applies similarly to complex numbers 18.
3.1.1 Vector operations
Vector operations are performed element-wise 19.
- Vector Addition: For u,v∈Rn, their sum u+v∈Rn is defined such that (u+v)i=ui+vi 19.
- Scalar Multiplication: For u∈Rn and a scalar c∈R, the product cu∈Rn is defined such that (cu)i=cui 19.
3.1.2 Arithmetic rules for vectors
The following rules hold for vector addition and scalar multiplication, which can be proven by writing the equations component-wise 19:
- u+v=v+u (Commutativity) 19.
- (u+v)+w=u+(v+w) (Associativity) 19.
- c(u+v)=cu+cv 19.
- (c+d)u=cu+du 19.
- (cd)u=c(du) 19.
The zero vector, 0, has all elements equal to zero. The negative of a vector is −u=(−1)u. The following identities hold 19:
Tip: The distributive property c(u+v)=cu+cv is visually illustrated by the vector addition triangle property 20.
3.2 Linear combinations and span
A linear combination of vectors v1,v2,…,vp in Rn is any vector y∈Rn that can be written as: y=c1v1+c2v2+⋯+cpvp where c1,c2,…,cp are scalars (weights) 20.
The span of {v1,v2,…,vp} is the set of all possible linear combinations of these vectors, denoted Span{v1,v2,…,vp}, which is a subset of Rn 21.
Example: In R2, the vector y=2v1+3v2 is a linear combination of v1 and v2 20.
3.3 Equivalence of linear systems, vector equations, and span
A system of m linear equations with n variables: a11x1+⋯+a1nxnam1x1+⋯+amnxn=b1⋮=bm can be restated in several equivalent forms. Let a1,a2,…,an,b be vectors in Rm, where aj is the j-th column vector of the coefficient matrix 21 25.
The primary equivalences are summarized in Theorem 3 25:
- Matrix Equation: Ax=b, where A=[a1 a2 … an] 23 25.
- Vector Equation: x1a1+x2a2+⋯+xnan=b. This asks if b can be written as a linear combination of the columns of A 22 25.
- System of Linear Equations: The original system 25.
- Augmented Matrix: The existence of a solution is determined by analyzing the augmented coefficient matrix [a1 a2 … an b] 22 25.
Span Interpretation: The vector equation Ax=b has a solution if and only if b lies in Span{a1,a2,…,an} 22.
Example: The system: x1+2x22x1−x2−x1+x2=1=0=1 is equivalent to the vector equation x112−1+x22−11=101 26.
3.4 Matrix-vector product Ax
If A is an m×n matrix with columns a1,…,an, and x∈Rn, the matrix product Ax is defined as a linear combination of the columns of A 24: Ax=x1a1+x2a2+⋯+xnan(∈Rm) The calculation can be done by rows (row-column rule): Ax=a11x1+a12x2+⋯+a1nxn⋮am1x1+am2x2+⋯+amnxn=a11⋮am1a12⋮am2⋯⋱⋯a1n⋮amnx1⋮xn 24.
Properties of Matrix-Vector Product (Theorem 5): For A∈Rm×n and u,v∈Rn, and scalar c∈R 25:
3.5 Span and linear independence related to pivots
Theorem 4 links pivot positions in the coefficient matrix A (not the augmented matrix [A b]) to spanning Rm. The following statements are equivalent 26: a) Ax=b has a solution for every b∈Rm 26. b) Every b∈Rm is a linear combination of the columns of A 26. c) Span{a1,a2,…,an}=Rm 26. d) A has a pivot position in every row 26.
If A∼U (echelon form), and U has a pivot in every row, then [U d] is consistent regardless of d, proving a)⟺d) 27.
3.6 Linear (in)dependence
Linear Independence (l.i.): A set {a1,a2,…,an}⊂Rm is linearly independent if the equation Ax=0 (where A=[a1 a2 … an]) has only the trivial solution x=0. This means x1a1+x2a2+⋯+xnan=0 implies all weights xi must be zero 33.
Linear Dependence (l.d.): The set is linearly dependent if Ax=0 has at least one non-trivial solution x=0. This means some vector in the set can be written as a linear combination of the others 33 34.
Example: For {a1,a2} in Rm, linear dependence means ∃x1,x2 (not both zero) such that x1a1+x2a2=0, which implies a1=−x1x2a2 (if x1=0) 33.
Theorem 7: {a1,…,an}⊂Rm is linearly dependent (given n≥2 and a1=0) if and only if some vector aj (for j>1) is a linear combination of the preceding vectors: aj=c1a1+⋯+cj−1aj−1 35.
Properties of L.D. Sets (Theorems 8 & 9):
- Theorem 8: If the set contains more vectors than dimensions (n>m), the set {a1,…,an}⊂Rm must be linearly dependent. (Proof relies on the fact that the number of pivots is ≤m, implying n≤m for an injective map, leading to a contradiction if n>m) 35.
- Theorem 9: If a set of vectors contains the zero vector, the set is linearly dependent 35.
3.7 Linear Transformations
A transformation T:Rn→Rm maps a vector x in the domain Rn to a vector T(x) in the codomain Rm (the image/range is a subset of the codomain). The kernel of T is the set {x∈Rn:T(x)=0} 36 37.
3.7.1 Linearity Definition
A transformation T:Rn→Rm is linear if for all scalars c and all u,v in the domain 38:
A consequence is that T(0)=0, and T(c1v1+⋯+cpvp)=c1T(v1)+⋯+cpT(vp). Every matrix transformation T(x)=Ax is a linear transformation 38.
3.8 The standard matrix of a linear transformation
Theorem 10: Every linear transformation T:Rn→Rm is a matrix transformation, T(x)=Ax, where A is the standard matrix of T 39.
The standard matrix A is constructed using the images of the standard basis vectors ei (unit vectors) in Rn 38 39: A=[ T(e1) T(e2) … T(en) ] 39. The standard vectors ei are defined such that the i-th component is 1 and others are 0. Any vector x can be written as x=x1e1+x2e2+⋯+xnen 39.
The equivalence T(x)=y is equivalent to Ax=y. Standard matrices can represent reflections, scaling, rotations, projections, and shears in 2D and 3D space 39 40 41.
3.9 Injectivity and Surjectivity
For a linear transformation T:Rn→Rm with standard matrix A=[a1,…,an]:
3.9.1 Surjectivity (Onto)
T is surjective if every vector b∈Rm is the image of at least one x∈Rn (the range equals the codomain) 42. Theorem 12a: T is surjective if and only if Span{a1,…,an}=Rm, which occurs if and only if A has a pivot position in every row 42.
3.9.2 Injectivity (One-to-One)
T is injective if every vector b∈Rm is the image of at most one x∈Rn 43.
Theorem 11: A linear T is injective if and only if T(x)=0 has only the trivial solution x=0 43.
Theorem 12b: T is injective if and only if Ax=0 has only the trivial solution, which is equivalent to the columns a1,…,an being linearly independent, which occurs if and only if A has a pivot in every column 44.
Caution: Injectivity and surjectivity are not opposites; a transformation can be one but not the other. For T:Rn→Rm, if n<m, T cannot be surjective; if n>m, T cannot be injective 44 45.
3.10 Synthesis of Viewpoints
A system Ax=b, where A∈Rm×n and b∈Rm, can be viewed through three equivalent perspectives 45:
- Per Row: A system of m linear equations 45.
- Per Column: A vector equation expressing b as a linear combination of the columns of A (related to span) 45.
- Linear Transformation: A matrix transformation T:Rn→Rm such that y=T(x)=Ax 45.
Matrix algebra and inverses
This topic summarizes fundamental matrix operations, the non-commutative nature of matrix multiplication, the concept of the inverse matrix, and methods for its calculation using elementary matrices.
4.1 Matrix operations and rules
Matrix addition and scalar multiplication are defined for matrices of compatible sizes 47.
4.1.1 Matrix-vector product
For an m×n matrix A=[a1a2…an] and a vector u∈Rn, the matrix-vector product Au∈Rm is defined as a linear combination of the columns of A using the entries of u as weights 47: Au=u1a1+u2a2+⋯+unan
4.1.2 Matrix addition
If A and B are m×n matrices, their sum is defined element-wise 47: (A+B)ij=(A)ij+(B)ij Matrix addition is commutative: A+B=B+A 47.
4.1.3 Scalar multiplication
For a scalar c∈R and an m×n matrix A, the product cA is defined element-wise 47: (cA)ij=c(A)ij
4.1.4 Rules for addition and scalar multiplication
The set of m×n matrices under addition and scalar multiplication forms a vector space, satisfying the following properties (Stelling 1) 47:
- A+B=B+A (Commutativity)
- (A+B)+C=A+(B+C) (Associativity)
- A+0=A (Zero matrix)
- r(A+B)=rA+rB
- (r+s)A=rA+sA
- r(sA)=(rs)A
4.2 Matrix product AB
The matrix product AB is defined when the number of columns of A equals the number of rows of B. If A∈Rm×n and B∈Rn×p, then AB∈Rm×p 48.
4.2.1 Definition via columns
The j-th column of the product AB is the matrix-vector product of A times the j-th column of B 48: AB=[Ab1 Ab2 … Abp] The j-th column Abj is calculated as: Abj=b1ja1+b2ja2+⋯+bnjan 48.
4.2.2 Row-column rule
The entry (AB)ij is calculated by taking the dot product of the i-th row of A and the j-th column of B 49: (AB)ij=ai1b1j+ai2b2j+⋯+ainbnj=∑k=1naikbkj 49.
Tip: Memorize the structure of the row-column rule: row i of A multiplied by column j of B yields element (i,j) of AB 49.
4.2.3 Properties of matrix multiplication (Stelling 2)
Matrix multiplication is generally not commutative (AB=BA). However, it possesses the following properties for suitably sized matrices A,B,C and scalar r 50 51:
- (AB)C=A(BC) (Associativity)
- A(B+C)=AB+AC
- (B+C)A=BA+CA
- r(AB)=(rA)B=A(rB)
- Ak=A…A (k factors, for A∈Rn×n) 50.
4.2.4 Matrix product as composite linear transformation
If T:Rn→Rm has the standard matrix A (i.e., T(y)=Ay) and S:Rp→Rn has the standard matrix B (i.e., S(x)=Bx), then the composite transformation T∘S has the standard matrix AB 50 51: T(S(x))=T(Bx)=A(Bx)=(AB)x 51.
4.3 Transpose and Diagonal Matrices
4.3.1 Transposed matrix
The transpose of a matrix A, denoted AT, is obtained by interchanging its rows and columns: (AT)ij=(A)ji 51. Properties (Stelling 3) 51:
- (AT)T=A
- (A+B)T=AT+BT
- (rA)T=rAT
- (AB)T=BTAT (Note the order reversal) 51.
4.3.2 Diagonal and Identity Matrices
A square n×n matrix A is diagonal if aij=0 for i=j. The elements aii are the diagonal elements 52. The identity matrix In is an n×n diagonal matrix with all diagonal entries equal to 1 52. Property 52: BIn=B=ImB (where B is m×n)
4.4 The Inverse Matrix
4.4.1 Definition
An n×n matrix A is invertible (or regular) if there exists an n×n matrix A−1 such that 53: A−1A=InandAA−1=In If an inverse exists, it is unique. A non-invertible matrix is called singular 53.
4.4.2 Solving Ax=b
If A is an invertible n×n matrix, the equation Ax=b has a unique solution for any b∈Rn, given by x=A−1b 53. If A is invertible, the corresponding linear transformation T:x↦Ax is both injective and surjective 53.
4.4.3 Rules for inverses (Stelling 6)
If A and B are invertible n×n matrices 54:
- (A−1)−1=A
- (AB)−1=B−1A−1 (Order reversal)
- (AT)−1=(A−1)T If AB=In, then BA=In (only true for square matrices) 54.
Tip: The properties of inverses mirror those of powers and transposes, crucially involving the reversal of order upon inversion or transposition of products 54.
4.5 Calculating the inverse using elementary matrices
The standard procedure to find A−1 involves row reduction of the augmented matrix [A In] 56.
4.5.1 Elementary matrices and row operations
Multiplying a matrix on the left by an elementary matrix E performs an elementary row operation (ER) on that matrix 55:
- Row scaling: Multiplying a row by a non-zero scalar k. The inverse scales by 1/k 55.
- Row swap: Exchanging two rows. The inverse is the same swap matrix (E−1=E) 55.
- Row replacement: Adding a multiple k of one row to another. The inverse subtracts k times that row (E−1 uses −k) 55.
All elementary matrices are invertible 55.
4.5.2 Invertibility condition (Stelling 7)
A matrix A is invertible if and only if it is row equivalent to the identity matrix In (A∼In) 56 57. If A is invertible, the row reduction process applied to the augmented matrix [A In] yields [In A−1] 56 57: [A In∼[In A−1]
If A∼In, there exists a sequence of elementary matrices EpEp−1…E1 such that EpEp−1…E1A=In. This implies A−1=EpEp−1…E1 57.
Example: Inverting the matrix A=11−10−22−131 involves performing the row operations sequentially on [A I3] until the left side becomes I3, resulting in [I3 A−1] 56.
4.6 Matrix Inversion Theorems
Stelling 8 lists numerous equivalent conditions for an n×n matrix A being invertible 58:
- A∼In 58.
- A has n pivot positions 58.
- Ax=0 has only the trivial solution 58.
- Columns of A are linearly independent 58.
- Span{a1,…,an}=Rn 58.
- The linear transformation T:x↦Ax is injective and surjective onto Rn 58.
- ∃C such that CA=In and ∃D such that AD=In 58.
- AT is invertible 58.
4.7 Partitioned Matrices
A matrix can be divided into smaller rectangular submatrices called blocks 59.
4.7.1 Operations on partitioned matrices
- Addition: Blocks of the same size are added element-wise 60.
- Multiplication: The product is calculated as if the blocks were scalar elements, provided dimensions are compatible. For A=(A11A21A12A22) and B=(B1B2) 60: AB=(A11B1+A12B2A21B1+A22B2) 60.
4.7.2 Inversion of block matrices
For a block upper triangular matrix A=(A110A12A22), where A11 is p×p and A22 is q×q, if A is invertible, its inverse is given by 61: A−1=(A11−10−A11−1A12A22−1A22−1) 61.
Factorizations and determinants
This topic covers matrix factorization techniques, specifically LU decomposition, and the comprehensive properties of determinants, including their calculation, behavior under elementary row operations, and their application in solving linear systems via Cramer's rule and determining volumes under linear transformations.
5.1 LU factorization
Factorization, or decomposition, involves expressing a matrix as a product of matrices with specific properties. A key example is the LU decomposition, where a matrix A is factored into A=LU 62.
5.1.1 Definition of LU factors
For an m×n matrix A that can be brought to echelon form without row swaps or scaling 62:
- L is an m×m lower triangular matrix with ones on the main diagonal (a unit lower triangular matrix) 62.
- U is an m×n echelon form of A 62.
Tip: If row exchanges are necessary during reduction, the standard LU decomposition does not apply directly; instead, a factorization PA=LU is used, where P is a permutation matrix 62.
5.1.2 Utility of LU decomposition
The primary use of LU decomposition is efficiently solving systems of linear equations Ax=b for many different vectors b 62. The system Ax=b is transformed into LUx=b. This is solved in two sequential steps 62:
- Solve Ly=b for y. Since L is a unit lower triangular matrix, this is done using forward substitution (solving for y1,y2,…,ym sequentially). L is invertible, so a solution for y always exists 62.
- Solve Ux=y for x. Since U is in echelon form, this is solved using backward substitution. This step might result in infinite solutions (if free variables exist) or no solution (if inconsistent rows appear) 62.
5.1.3 Constructing L from Elementary Matrices
If the reduction of A to U is achieved through a sequence of elementary matrices Ep…E1A=U then A=(Ep…E1)−1U=LU 63. The factor L is then L=(Ep…E1)−1=E1−1…Ep−1 63. When the elementary row operation involves only adding a multiple of one row to a row below it (Row Replacement), the corresponding elementary matrix Ei is unit lower triangular. The inverse Ei−1 is also unit lower triangular, but with the negative of the multiplier below the diagonal. The product of unit lower triangular matrices is unit lower triangular, meaning L is unit lower triangular 63.
The elements Lij (where i>j) represent the ratio of the element below the pivot in row i to the pivot element a in row j that was used in that reduction step. Specifically, Lij=x/a, where x is the element in row i below the pivot and a is the pivot element in row j 64.
5.2 Determinants: Introduction and Calculation
The determinant, denoted detA or ∣A∣, is a scalar value associated with a square matrix A∈Rn×n 65.
5.2.1 Definition by Cofactor Expansion
For n=1, detA=a11 65. For n≥2, the determinant is defined recursively using cofactor expansion along the first row 65: detA=∑j=1n(−1)1+ja1jdetA1j Here, Aij is the submatrix formed by deleting row i and column j from A 65.
For n=2: detA=a11a22−a21a12 65. For n=3, the Sarrus rule expansion is: detA=a11a22a33+a21a32a13+a12a23a31−a31a22a13−a21a12a33−a32a23a11 65.
5.2.2 Expansion along any row or column
The determinant can be calculated by expanding along any row i or any column j 66: detA=∑j=1naijCij=∑i=1naijCij where Cij=(−1)i+jdetAij is the cofactor of the entry aij 66.
The sign pattern for cofactors follows a checkerboard pattern, starting with positive in the top-left corner 66:
\begin{pmatrix} + & - & + & \dots \\ - & + & - & \dots \\ + & - & + & \dots \\ \vdots & \vdots & \vdots & \ddots \end{pmatrix} $$ [66](#page=66). #### 5.2.3 Determinant of Triangular Matrices If $A$ is an upper or lower triangular matrix, its determinant is simply the product of the diagonal entries [66](#page=66): $$\det A = \prod_{j=1}^{n} a_{jj}$$ [66](#page=66). ### 5.3 Properties of Determinants The behavior of the determinant is closely tied to elementary row operations (ER). If $B = EA$ where $E$ is an elementary matrix performing an operation on $A$, then $\det B = \det E \det A$ [67](#page=67). The effect of the three types of ERs on the determinant are [67](#page=67): 1. **Row Scaling:** Scaling row $i$ by a factor $k$: $\det B = k \det A$ [67](#page=67). 2. **Row Swap:** Swapping two rows: $\det B = - \det A$ [67](#page=67). 3. **Row Replacement:** Adding a multiple $k$ of one row to another row: $\det B = \det A$ [67](#page=67). #### 5.3.1 Invertibility and the Determinant **Theorem:** A square matrix $A$ is invertible if and only if $\det A \neq 0$ [68](#page=68). This is proven by considering the echelon form $U$ resulting from $E_p \dots E_1 A = U$. Since $\det E \neq 0$ for all elementary matrices $E$ used in the reduction, $\det A$ and $\det U$ are related by a non-zero constant $c = (\det E_p \dots \det E_1)^{-1}$ [68](#page=68). * If $A$ is invertible, $U$ must be square with $n$ pivot positions (every row has a pivot), meaning $\det U$ is the product of non-zero diagonal elements, so $\det U \neq 0$. Thus, $\det A \neq 0$ [68](#page=68). * If $A$ is not invertible, $U$ has at least one row of zeros (fewer than $n$ pivots), so $\det U = 0$. Thus, $\det A = 0$ [68](#page=68). #### 5.3.2 Other Key Properties * **Transpose:** $\det A = \det A^T$ [68](#page=68). * **Product Rule:** $\det (AB) = \det A \det B$ [68](#page=68). * **Linearity in Columns:** The function $x \to \det([a_1 \dots a_{i-1} \ x \ a_{i+1} \dots a_n])$ is linear in the argument vector $x$ (the $i$-th column) [68](#page=68). * **Caveats:** Generally, $\det(A+B) \neq \det A + \det B$ and $\det(kA) = k^n \det A$ for an $n \times n$ matrix $A$ [68](#page=68). ### 5.4 Cramer's Rule and Inverses #### 5.4.1 Cramer's Rule for $Ax=b$ If $A$ is an invertible $n \times n$ matrix, the unique solution $x = (x_1, x_2, \dots, x_n)^T$ to $Ax=b$ is given by Cramer's Rule [69](#page=69): $$x_i = \frac{\det A_i(b)}{\det A}$$ where $A_i(b)$ is the matrix formed by replacing the $i$-th column of $A$ with the vector $b$ [69](#page=69). > **Example:** If $A = [\mathbf{a}_1 \ \mathbf{a}_2 \ \dots \ \mathbf{a}_n]$, then $A_i(b) = [\mathbf{a}_1 \ \dots \ \mathbf{a}_{i-1} \ \mathbf{b} \ \mathbf{a}_{i+1} \ \dots \ \mathbf{a}_n]$ [69](#page=69). #### 5.4.2 Calculating the Inverse $A^{-1}$ Cramer's rule can be used to find the inverse $A^{-1} = [d_1 \ d_2 \ \dots \ d_n]$ by setting $b$ sequentially to the standard basis vectors $e_j$, since $Ad_j = e_j$ [70](#page=70). The $(i, j)$ entry of $A^{-1}$, denoted $A^{-1}_{ij}$, is found by calculating the solution $d_j$ for $x=d_j$ in $Ay=e_j$ [70](#page=70). $$d_{j, i} = \frac{\det A_i(e_j)}{\det A}$$ [70](#page=70). Since $\det A_i(e_j)$ is $(-1)^{j+i}$ times the determinant of $A$ with row $j$ and column $i$ removed (i.e., $(-1)^{i+j} \det A_{ji}$), we have [70](#page=70): $$A^{-1}_{ij} = \frac{C_{ji}}{\det A}$$ where $C_{ji}$ is the cofactor of $a_{ji}$ [70](#page=70). This leads to the formula using the adjugate matrix, $\text{adj}(A)$, which is the transpose of the cofactor matrix [70](#page=70): $$A^{-1} = \frac{1}{\det A} \text{adj}(A)$$ [70](#page=70). ### 5.5 Determinants, Area, and Volume The determinant measures how a linear transformation scales volume [72](#page=72). #### 5.5.1 Area in $\mathbb{R}^2$ For vectors $s_1, s_2$ in $\mathbb{R}^2$, the area of the parallelogram spanned by them is given by the absolute value of the determinant of the matrix formed by these vectors as columns [70](#page=70) [71](#page=71): $$\text{Area} = |\det [s_1 \ s_2]|$$ [71](#page=71). Elementary row operations that correspond to area-preserving shears do not change the determinant's absolute value, confirming that the determinant captures the scaling factor [71](#page=71). #### 5.5.2 Volume in $\mathbb{R}^n$ For a parallelepiped $S$ spanned by vectors $s_1, s_2, \dots, s_n$ in $\mathbb{R}^n$ [72](#page=72): $$\text{Volume}(S) = |\det [s_1 \ s_2 \ \dots \ s_n]|$$ [72](#page=72). #### 5.5.3 Volume Scaling under Linear Transformation If $T(\mathbf{y}) = A\mathbf{y}$ is a linear transformation represented by matrix $A$, and $S$ is a parallelepiped spanned by $\{s_1, \dots, s_n\}$, then the transformed shape $T(S)$ is also a parallelepiped spanned by $\{Ts_1, \dots, Ts_n\} = \{As_1, \dots, As_n\}$. The volume scales according to the determinant of $A$ [72](#page=72): $$\text{Volume}(T(S)) = |\det [As_1 \ As_2 \ \dots \ As_n]| = |\det(A[s_1 \ s_2 \ \dots \ s_n])|$$ [72](#page=72). Using the product rule: $$\text{Volume}(T(S)) = |\det A| \cdot |\det [s_1 \ s_2 \ \dots \ s_n]| = |\det A| \cdot \text{Volume}(S)$$ [72](#page=72). This principle generalizes to the volume scaling of any measurable region $R$ under the transformation $T$: $\text{Volume}(T(R)) = |\det A| \cdot \text{Volume}(R)$ [72](#page=72). --- # Vector spaces, bases, and dimension This section generalizes concepts from $\mathbb{R}^n$ to abstract vector spaces ($V$), defining subspaces, bases, dimension, and the associated coordinate transformations [73](#page=73) [76](#page=76) [81](#page=81). ### 6.1 Vector spaces and subspaces A **Vector Space** $V$ is a non-empty set ($\emptyset \ne V$) of objects called vectors, equipped with two operations: vector addition and scalar multiplication, satisfying ten axioms. Let $u, v, w \in V$ and $c, d$ be scalars [73](#page=73): 1. $u+v \in V$ 2. $u+v = v+u$ (Commutativity of addition) 3. $(u+v)+w = u+(v+w)$ (Associativity of addition) 4. There exists a zero vector $0 \in V$ such that $u+0=u$ 5. For every $u \in V$, there exists an inverse $-u \in V$ such that $u+(-u)=0$ 6. $cu \in V$ 7. $c(u+v) = cu+cv$ 8. $(c+d)u = cu+du$ 9. $c(du) = (cd)u$ 10. $1u = u$ (Identity element for scalar multiplication) Examples of vector spaces include $\mathbb{R}^n$, the set of $m \times n$ matrices ($\mathbb{R}^{m \times n}$), sequences of numbers $\{u_k\}$, and the space of polynomials of degree $n$ or lower, $\mathbb{P}_n$, where a polynomial is represented as $a_n t^n + a_{n-1} t^{n-1} + \dots + a_1 t + a_0$ [74](#page=74). A **Subspace** $H$ of $V$ is a subset of $V$ that is itself a vector space under the same operations, requiring only three conditions to be checked when $V$ is already known to be a vector space [74](#page=74): 1. $0 \in H$ 2. If $u, v \in H$, then $u+v \in H$ (Closure under addition) 3. If $u \in H$ and $c$ is a scalar, then $cu \in H$ (Closure under scalar multiplication) Examples of subspaces include $\{0\}$, $V$ itself, lines through the origin in $\mathbb{R}^n$, and symmetric matrices in $\mathbb{R}^{n \times n}$. Invertible matrices in $\mathbb{R}^{n \times n}$ do **not** form a subspace because the zero matrix is not invertible [74](#page=74). The concepts of **linear combination (l.c.)** and **span** used in $\mathbb{R}^n$ apply directly to abstract vector spaces $V$ [75](#page=75). **Theorem 1:** If $v_1, \dots, v_p \in V$, then $\text{Span}\{v_1, \dots, v_p\}$ is a subspace of $V$. For instance, the span of specific $3 \times 3$ matrices forms the subspace of $3 \times 3$ diagonal matrices [75](#page=75). ### 6.2 Linear dependence, span, and basis The definitions for linear dependence (l.d.) and linear independence (l.i.) for vectors $v_1, \dots, v_p \in V$ remain the same as in $\mathbb{R}^n$: the equation $c_1 v_1 + \dots + c_p v_p = 0$ has only the trivial solution ($c_i=0$ for all $i$) if the set is l.i. [76](#page=76). **Theorem 4:** A set $\{v_1, \dots, v_p\}$ is linearly dependent if and only if there exists an index $j > 1$ such that $v_j$ is a linear combination of the preceding vectors $\{v_1, \dots, v_{j-1}\}$ [76](#page=76). **Definition (Basis):** A set $\beta = \{b_1, \dots, b_p\}$ belonging to $V$ is a **basis** for a subspace $H$ of $V$ if and only if: 1. $\beta$ is a linearly independent set [76](#page=76). 2. $\text{Span} \beta = H$ [76](#page=76). > **Tip:** To check if a set is a basis for $V$, you must verify both linear independence and that the span equals $V$ [76](#page=76). **Theorem (5a - Spanning Set Reduction):** If $v_1, \dots, v_p \in V$ and $\text{Span}\{v_1, \dots, v_p\} = H$, and if any vector $v_k$ can be written as a linear combination of the other vectors in the set, then $H = \text{Span}\{v_1, \dots, v_{k-1}, v_{k+1}, \dots, v_p\}$. This implies that redundant vectors (those dependent on others in the set) can be removed without changing the span [77](#page=77). **Theorem (5b - Basis Extraction):** If $S = \{v_1, \dots, v_p\}$ spans $H$ (where $H \neq \{0\}$), then there exists a subset $\beta \subseteq S$ that forms a basis for $H$. The process involves iteratively removing linearly dependent vectors from $S$ until the remaining set is linearly independent; this process must terminate with a basis, as the zero vector space $\{0\}$ is spanned by the empty set which is trivially l.i. [77](#page=77). ### 6.3 Coordinates and Isomorphism **Theorem 8 (Coordinates):** If $\beta = \{b_1, \dots, b_p\}$ is a basis for $V$, then for any $x \in V$, there exists a **unique** set of scalars $c_1, \dots, c_p$ such that $x = c_1 b_1 + \dots + c_p b_p$. The uniqueness proof relies on assuming two different representations exist, leading to a non-trivial linear combination summing to zero, contradicting the linear independence of the basis vectors [78](#page=78). **Definition (Coordinates):** The unique scalars $c_1, \dots, c_p$ are called **the coordinates** of $x \in V$ in basis $\beta$. They are denoted by the coordinate vector [79](#page=79): $$ [x]_\beta = \begin{bmatrix} c_1 \\ c_2 \\ \vdots \\ c_p \end{bmatrix} $$ where $x = c_1 b_1 + \dots + c_p b_p$ [79](#page=79). **Definition (Coordinate Transformation):** The mapping $T: V \rightarrow \mathbb{R}^p$ defined by $x \mapsto [x]_\beta$ is the **coordinate transformation** relative to basis $\beta$ [79](#page=79). **Theorem 9:** The coordinate transformation $T: V \rightarrow \mathbb{R}^p$ is linear, injective (one-to-one), and surjective (onto) [79](#page=79). **Isomorphism:** Because $[ \ ]_\beta$ is linear and bijective, it establishes an **isomorphism** between $V$ and $\mathbb{R}^n$ (where $n=p$), meaning the algebraic operations in $V$ are equivalent to those in $\mathbb{R}^n$ [79](#page=79). > **Example:** In $\mathbb{R}^2$, two different bases, $\beta = \{b_1, b_2\}$ and $\gamma = \{c_1, c_2\}$, yield different coordinate representations for the same vector $x$: $x = 3b_1 + 1b_2$ means $[x]_\beta = \begin{bmatrix} 3 \\ 1 \end{bmatrix}$, while $x = 6c_1 + 4c_2$ means $[x]_\gamma = \begin{bmatrix} 6 \\ 4 \end{bmatrix}$. The coordinate transformation $T_1(x) = [x]_\beta$ and $T_2(x) = [x]_\gamma$ are distinct mappings [78](#page=78). ### 6.4 Dimension and relationship to linear independence **Theorem 10 (Maximum number of l.i. vectors):** If $\beta = \{b_1, \dots, b_n\}$ is a basis for $V$, then any set of $p$ vectors $\{u_1, \dots, u_p\} \subset V$ with $p > n$ must be linearly dependent. This is proven by transforming the vectors into their coordinate representations in $\mathbb{R}^n$: since there are more vectors ($p$) than entries ($n$) in $\mathbb{R}^n$, their coordinate vectors are linearly dependent, implying the original vectors in $V$ are linearly dependent [80](#page=80). **Definition (Dimension):** The **Dimension** of $V$ ($\text{dim}(V)$) is the number of vectors in any basis for $V$ [81](#page=81). * A vector space $V$ is **finitely-dimensional** if it has a basis with a finite number of vectors [81](#page=81). * The dimension of the zero space is $\text{dim}(\{0\}) = 0$ [81](#page=81). **Theorem 11 (Uniqueness of Dimension):** If $\beta_1 = \{b_1, \dots, b_n\}$ is a basis for $V$, then any other basis $\beta_2$ must also have exactly $n$ vectors. If $|\beta_2| = p$, since $\beta_1$ is a basis, we must have $p \le n$. Since $\beta_2$ is also a basis, we must have $n \le p$. Therefore, $n=p$ [81](#page=81). **Properties of Finitely-Dimensional Vector Spaces (V with $\text{dim}(V)=p$ for $p \ge 1$):** [81](#page=81). 1. **Theorem 13a:** If $S \subset V$ is a linearly independent set, then $S$ can be extended to form a basis for $V$ (i.e., $\text{Span} S = V$) [81](#page=81). 2. **Theorem 13b:** If $S \subset V$ spans $V$ ($\text{Span} S = V$), then $S$ contains a subset that forms a basis for $V$ [81](#page=81). 3. **Theorem 13 (Combined):** If $S=\{b_1, \dots, b_p\}$ where $p=\text{dim}(V)$: * If $S$ is linearly independent, then $\text{Span} S = V$ [81](#page=81). * If $\text{Span} S = V$, then $S$ is linearly independent [81](#page=81). **Properties related to Subspaces:** **Theorem 12:** If $H$ is a subspace of $V$: a) Any linearly independent set in $H$ can be extended to a basis for $H$ [81](#page=81). b) $\text{dim}(H) \le \text{dim}(V)$ [81](#page=81). --- # Null space, column space, and rank This section establishes the fundamental vector subspaces associated with a matrix ($A$), namely the Null Space (Nul A) and the Column Space (Col A), and relates their dimensions through the Rank-Nullity Theorem. ### 7.1 Null Space (Nul A) The Null Space of an $m \times n$ matrix $A$ is defined as the set of all vectors $x$ in $\mathbb{R}^n$ such that $Ax = 0$ [82](#page=82). **Definition:** $$ \text{Nul } A = \{ x \in \mathbb{R}^n : Ax = 0 \} $$ The Null Space is equivalent to the solution set of the homogeneous system $Ax = 0$ [82](#page=82). **Subspace Property:** The Null Space $\text{Nul } A$ is a subspace of $\mathbb{R}^n$. This is verified by checking three conditions [82](#page=82): 1. The zero vector is in $\text{Nul } A$: $A\mathbf{0} = \mathbf{0}$ [82](#page=82). 2. Closure under vector addition: If $\mathbf{u}, \mathbf{v} \in \text{Nul } A$, then $A(\mathbf{u}+\mathbf{v}) = A\mathbf{u} + A\mathbf{v} = \mathbf{0} + \mathbf{0} = \mathbf{0}$, so $\mathbf{u}+\mathbf{v} \in \text{Nul } A$ [82](#page=82). 3. Closure under scalar multiplication: If $\mathbf{u} \in \text{Nul } A$, then $A(c\mathbf{u}) = c(A\mathbf{u}) = c\mathbf{0} = \mathbf{0}$, so $c\mathbf{u} \in \text{Nul } A$ [82](#page=82). **Finding a Basis for Nul A:** To find a basis for $\text{Nul } A$ [83](#page=83): 1. Solve the homogeneous equation $Ax = \mathbf{0}$ [83](#page=83). 2. Write the solution set parametrically as a span of linearly independent vectors [83](#page=83) [84](#page=84). The structure of the solution set is related to the free variables obtained after reducing the augmented matrix $[A | \mathbf{0}]$ to its Reduced Row Echelon Form (RREF). The basis vectors span the solution set, $\text{Nul } A = \text{Span}\{\mathbf{u}, \mathbf{v}, \mathbf{w}, \ldots \}$ [84](#page=84) [85](#page=85). **Dimension of Nul A:** The dimension of the Null Space, $\text{dim}(\text{Nul } A)$, is equal to the number of free variables in the homogeneous system, which corresponds to the number of non-pivot columns in the RREF of $A$ [85](#page=85). > **Tip:** The number of free variables is the number of non-pivot columns, which directly gives the dimension of the null space [85](#page=85). ### 7.2 Column Space (Col A) The Column Space of an $m \times n$ matrix $A$ is the set spanned by its column vectors, $\mathbf{a}_1, \mathbf{a}_2, \ldots, \mathbf{a}_n$ [85](#page=85). **Definition:** $$ \text{Col } A = \text{Span}\{\mathbf{a}_1, \mathbf{a}_2, \ldots, \mathbf{a}_n \} $$ The column space $\text{Col } A$ is a subspace of $\mathbb{R}^m$. It consists of all vectors $\mathbf{b} \in \mathbb{R}^m$ for which the equation $A\mathbf{x} = \mathbf{b}$ has at least one solution. Geometrically, $\text{Col } A$ is the span of the columns of $A$ [85](#page=85) [86](#page=86). **Basis for Col A:** The column space of $A$ is generally **not** equal to the column space of its RREF, $\text{Col } A \neq \text{Col } B$ [86](#page=86). **Theorem 6 (Basis for Col A):** The pivot columns of the original matrix $A$ form a basis for $\text{Col } A$ [87](#page=87). This is established because elementary row operations (EROs) preserve the solutions to $A\mathbf{x} = \mathbf{0}$ (which relates to $\text{Nul } A$), but not the column relationships in general. However, the pivot columns ($\text{PK}$) of $A$ are linearly independent, and $\text{Col } A = \text{Span}\{\text{PK}(A)\}$ [87](#page=87). > **Example:** If $A \sim B$ (where $B$ is the RREF), and the first and second columns of $B$ are pivot columns, then the first and second columns of $A$ form a basis for $\text{Col } A$ [87](#page=87). ### 7.3 Rank of a Matrix The rank of a matrix $A$ is defined as the dimension of its column space [87](#page=87). **Definition:** $$ \text{rank } A = \text{dim}(\text{Col } A) $$ The rank of $A$ is equal to the number of pivot columns in its row echelon form [87](#page=87). ### 7.4 Row Space (Row A) The Row Space of $A$ is the span of the row vectors of $A$, which is equivalent to the column space of $A$ transpose, $\text{Col } A^T$. It is a subspace of $\mathbb{R}^n$ [88](#page=88). **Theorem 7a:** If $A \sim B$ (row equivalent), then $\text{Row } A = \text{Row } B$. This is because EROs only create linear combinations of the rows, preserving the overall space spanned by the rows [88](#page=88). **Basis for Row A:** **Theorem 7b:** The non-zero rows of the RREF ($U$) of $A$ form a basis for $\text{Row } U$, and thus for $\text{Row } A$. The non-zero rows in the RREF are guaranteed to be linearly independent [89](#page=89). **Rank and Row Space:** The rank of $A$ is also equal to the dimension of the Row Space [90](#page=90). $$ \text{rank } A = \text{dim}(\text{Row } A) = \text{\# of non-zero rows in GEV } U = \text{\# of pivot columns (PK)} $$ Furthermore, $\text{rank } A = \text{dim}(\text{Col } A) = \text{dim}(\text{Row } A)$, and because $\text{Row } A = \text{Col } A^T$, we have $\text{rank } A = \text{rank } A^T$ [90](#page=90). ### 7.5 The Rank-Nullity Theorem For any $m \times n$ matrix $A$, the sum of the dimension of the column space (rank) and the dimension of the null space equals the number of columns, $n$ [88](#page=88) [90](#page=90). **Theorem 14 (Dimension Theorem):** $$ \text{rank } A + \text{dim}(\text{Nul } A) = n $$ where $n$ is the number of columns of $A$ [88](#page=88). This theorem can also be applied to the transpose $A^T$, which is an $n \times m$ matrix [90](#page=90): $$ \text{rank } A^T + \text{dim}(\text{Nul } A^T) = m $$ Since $\text{rank } A^T = \text{rank } A$ and $\text{dim}(\text{Row } A) = \text{dim}(\text{Col } A^T) = \text{rank } A$, this leads to: $$ \text{dim}(\text{Row } A) + \text{dim}(\text{Nul } A^T) = m $$ [90](#page=90). > **Tip:** The Rank-Nullity Theorem provides a crucial link between the dimension of the solution space of the homogeneous system ($\text{dim}(\text{Nul } A)$) and the dimension of the space spanned by the columns ($\text{rank } A$) [88](#page=88). --- # Eigenvalues, eigenvectors, and diagonalization This topic covers the fundamental concepts of eigenvalues and eigenvectors, which characterize how a linear transformation scales specific vectors, leading to the powerful technique of matrix diagonalization [98](#page=98). ### 8.1 Definitions of eigenvalues and eigenvectors For a square matrix $A \in \mathbb{R}^{n \times n}$: * **Eigenvector Definition:** A non-zero vector $\mathbf{x} \neq \mathbf{0}$ is an **eigenvector** of $A$ if there exists a scalar $\lambda$ such that $A\mathbf{x} = \lambda \mathbf{x}$ [98](#page=98). * **Eigenvalue Definition:** A scalar $\lambda$ is an **eigenvalue** of $A$ if there exists a non-trivial solution ($\mathbf{x} \neq \mathbf{0}$) to the equation $A\mathbf{x} = \lambda \mathbf{x}$ [98](#page=98). * The vector $\mathbf{x}$ is the eigenvector belonging to the eigenvalue $\lambda$ [98](#page=98). * For a linear transformation $T: \mathbb{R}^n \to \mathbb{R}^n$ defined by $T(\mathbf{x}) = A\mathbf{x}$, an eigenvector is mapped to a scalar multiple of itself [98](#page=98). ### 8.2 Finding eigenvectors and eigenspaces If the eigenvalue $\lambda$ is known, finding the corresponding eigenvectors involves solving the homogeneous system derived from $A\mathbf{x} = \lambda \mathbf{x}$ [99](#page=99): $$A\mathbf{x} - \lambda \mathbf{x} = \mathbf{0} \iff A\mathbf{x} - \lambda I_n \mathbf{x} = \mathbf{0} \iff (A - \lambda I_n) \mathbf{x} = \mathbf{0}$$ Subtracting $\lambda$ from the diagonal entries of $A$ results in the matrix $A - \lambda I_n$ [99](#page=99). * **Eigenspace Definition:** The **eigenspace** corresponding to $\lambda$ is the null space of $(A - \lambda I_n)$, denoted $Nul(A - \lambda I_n)$ [99](#page=99). * For $\lambda$ to be an eigenvalue, the dimension of the null space must satisfy $1 \leq \dim(Nul(A - \lambda I_n)) \leq n$ [99](#page=99). > **Example:** For a matrix $A = \begin{pmatrix} 3 & -1 \\ -0.5 & 2.5 \end{pmatrix}$ and eigenvalue $\lambda_1 = 2$, the homogeneous system $(A-2I)\mathbf{x}=\mathbf{0}$ leads to the row-equivalent matrix $\begin{pmatrix} 1 & -1 \\ 0 & 0 \end{pmatrix}$, yielding the eigenvector $\mathbf{v}_1 = \begin{pmatrix} 1 \\ 1 \end{pmatrix}$ [100](#page=100). **Linear Independence of Eigenvectors:** * **Theorem:** Eigenvectors corresponding to distinct eigenvalues are linearly independent. If $\mathbf{v}_1, \dots, \mathbf{v}_r$ are eigenvectors belonging to distinct eigenvalues $\lambda_1, \dots, \lambda_r$, then $\{\mathbf{v}_1, \dots, \mathbf{v}_r\}$ is a linearly independent set [100](#page=100). ### 8.3 Characteristic equation and finding eigenvalues Eigenvalues are found by solving the characteristic equation: $$\det(A - \lambda I) = 0$$ This condition ensures that the matrix $(A - \lambda I)$ is non-invertible (singular), guaranteeing non-trivial solutions for $(A - \lambda I)\mathbf{x} = \mathbf{0}$ . * **Characteristic Polynomial (KP):** $\det(A - \lambda I)$ is a polynomial in $\lambda$ of degree $n$ . $$\det \begin{pmatrix} A_{11}-\lambda & \cdots \\ \vdots & \ddots \end{pmatrix} = (-1)^n(\lambda^n + a_{n-1}\lambda^{n-1} + \cdots + a_1\lambda + a_0)$$ * There are always exactly $n$ solutions (eigenvalues), which may be complex or repeated . * The factored form is $\det(A - \lambda I) = (\lambda_1 - \lambda)^{m_1} \cdots (\lambda_k - \lambda)^{m_k}$, where $m_1 + \cdots + m_k = n$ . * $m_i$ is the **algebraic multiplicity** of the eigenvalue $\lambda_i$ . > **Tip:** For triangular matrices (upper or lower), the eigenvalues are simply the entries on the main diagonal . **Eigenvalue Zero and Invertibility:** A matrix $A$ has an eigenvalue $\lambda=0$ if and only if $\det(A) = 0$, meaning $A$ is singular (not invertible). Invertible matrices do not have zero as an eigenvalue . **General Technique for Calculating Eigenvalues/Eigenvectors:** 1. Factor the characteristic equation: $\det(A - \lambda I) = 0$ to find eigenvalues $\lambda_j$ and their algebraic multiplicities $m_j$ . 2. For each $\lambda_j$, solve the homogeneous system $(A - \lambda_j I) \mathbf{x} = \mathbf{0}$ . 3. The resulting linearly independent solutions span the eigenspace corresponding to $\lambda_j$. Let $d_j$ be the number of linearly independent eigenvectors found (the dimension of the eigenspace, or **geometric multiplicity**) . * **Property:** For any eigenvalue, $1 \leq d_j \leq m_j$ . ### 8.4 Matrix similarity (Gelijkvormigheid) * **Definition:** $n \times n$ matrices $A$ and $C$ are **similar** if there exists an invertible $n \times n$ matrix $P$ such that $C = P^{-1} A P$ (or $A = P C P^{-1}$) . * **Theorem:** Similar matrices have the same characteristic polynomial and thus the same eigenvalues . **Meaning of Similarity:** Similarity arises when changing the basis for a linear transformation $T(\mathbf{x}) = A\mathbf{x}$. If $P = [\mathbf{b}_1 \cdots \mathbf{b}_n]$ is the change-of-basis matrix from basis $B = \{\mathbf{b}_1, \dots, \mathbf{b}_n\}$ to the standard basis, then the matrix representation of $T$ in basis $B$ is $[A]_B = P^{-1} A P$ . > **Example:** If $A = \begin{pmatrix} 3 & -1 \\ 1 & 1 \end{pmatrix}$ and the basis $B$ is spanned by $\mathbf{b}_1 = \begin{pmatrix} 1 \\ 1 \end{pmatrix}$ and $\mathbf{b}_2 = \begin{pmatrix} 1 \\ 0 \end{pmatrix}$, then $P = \begin{pmatrix} 1 & 1 \\ 1 & 0 \end{pmatrix}$, and $[A]_B = P^{-1} A P = \begin{pmatrix} 2 & 1 \\ 0 & 2 \end{pmatrix}$ . ### 8.5 Diagonalization The goal of diagonalization is to find a basis in which the linear transformation $T$ is represented by a diagonal matrix $D$ . * **Definition:** Matrix $A$ is **diagonalizable** if $A$ is similar to a diagonal matrix $D$, meaning $A = P D P^{-1}$ for some invertible matrix $P$ . * **Theorem for Diagonalization:** An $n \times n$ matrix $A$ is diagonalizable if and only if $A$ possesses $n$ linearly independent eigenvectors . * If diagonalizable, $A = P D P^{-1}$, where $D$ is the diagonal matrix containing the eigenvalues $\lambda_1, \dots, \lambda_n$, and $P$ is the matrix whose columns are the corresponding $n$ linearly independent eigenvectors $\mathbf{v}_1, \dots, \mathbf{v}_n$: $$D = \begin{pmatrix} \lambda_1 & \cdots & 0 \\ \vdots & \ddots & \vdots \\ 0 & \cdots & \lambda_n \end{pmatrix}, \quad P = [\mathbf{v}_1 \cdots \mathbf{v}_n]$$ * The proof confirms that $A\mathbf{v}_j = \lambda_j \mathbf{v}_j$ implies $A P = P D$, leading to $A = P D P^{-1}$ . > **Interpretation:** If $A$ is diagonalizable, a basis exists (the set of $n$ linearly independent eigenvectors) where the linear transformation $T(\mathbf{x}) = A\mathbf{x}$ simply scales each basis vector by its corresponding eigenvalue . > > **Corollaries:** > 1. If $A$ has $n$ distinct eigenvalues, $A$ is diagonalizable . > 2. $A$ is diagonalizable if and only if the geometric multiplicity ($d_i$) equals the algebraic multiplicity ($m_i$) for all eigenvalues $\lambda_i$. This requires $d_1 + \cdots + d_k = n$ . > **Example (Diagonalizable):** For $A = \begin{pmatrix} 3 & -1 \\ -0.5 & 2.5 \end{pmatrix}$ with eigenvalues $\lambda_1=2$ ($\mathbf{v}_1 = \begin{pmatrix} 1 \\ 1 \end{pmatrix}$) and $\lambda_2=3.5$ ($\mathbf{v}_2 = \begin{pmatrix} 2 \\ -1 \end{pmatrix}$), $P = \begin{pmatrix} 1 & 2 \\ 1 & -1 \end{pmatrix}$ and $D = \begin{pmatrix} 2 & 0 \\ 0 & 3.5 \end{pmatrix}$ . > **Example (Not Diagonalizable):** For $A = \begin{pmatrix} 3 & -1 \\ 1 & 1 \end{pmatrix}$, the characteristic equation is $(\lambda - 2)^2 = 0$, so $\lambda_1=2$ has algebraic multiplicity $m_1=2$. Solving $(A - 2I)\mathbf{x} = \mathbf{0}$ yields an eigenspace spanned by only one vector $\begin{pmatrix} 1 \\ 1 \end{pmatrix}$, so the geometric multiplicity is $d_1=1$. Since $d_1 \neq m_1$, $A$ is **not diagonalizable** . ### 8.6 Useful results related to diagonalization If $A$ is diagonalizable, $A = P D P^{-1}$ : * **Matrix Powers:** $A^k = P D^k P^{-1}$ . * **Determinant:** $\det(A) = \prod_{i=1}^{n} \lambda_i$ . * **Trace:** $\text{trace}(A) = \sum_{i=1}^{n} a_{ii} = \sum_{i=1}^{n} \lambda_i$ . > **Tip:** Using the diagonal form simplifies calculating high powers of a matrix $A$, as powers of the diagonal matrix $D$ are trivial: $D^k$ has entries $\lambda_i^k$ on the diagonal . ### 8.7 Comparison of concepts Diagonalization simplifies the action of a linear transformation $T(\mathbf{x}) = A\mathbf{x}$ to coordinate scaling in the eigenvector basis $B = \{\mathbf{v}_1, \dots, \mathbf{v}_n\}$, where $[T(\mathbf{x})]_B = D[\mathbf{x}]_B$ . > **Caution:** > * Elementary row/column operations change eigenvalues and eigenvectors . > * Diagonalizability and invertibility are distinct concepts . > * $\begin{pmatrix} 1 & 1 \\ 0 & 1 \end{pmatrix}$ is invertible but not diagonalizable ($m=2, d=1$) . > * $\begin{pmatrix} 1 & 1 \\ 1 & 1 \end{pmatrix}$ is diagonalizable ($\lambda_1=2, \lambda_2=0$) but not invertible ($\det=0$) . > * An $n \times n$ matrix $A$ is diagonalizable if and only if it has $n$ linearly independent eigenvectors . > * An $n \times n$ matrix $A$ is invertible if and only if it has $n$ linearly independent columns . --- # Discrete-time linear systems analysis This topic covers the analysis of Discrete-Time Linear Time-Invariant (DTLTI) systems described by the state-space representation and explores system response, equivalent descriptions through state transformation, diagonal form analysis using eigenvectors, and stability criteria based on eigenvalues . ### 9.1 State-space representation A system is mathematically described as a mapping of input signals $u \in \mathbb{S}^m$ to output signals $y \in \mathbb{S}^l$, $y = T(u)$. A DTLTI system is characterized by the following state-space equations for $k \in \mathbb{N}$ :\begin{aligned} \mathbf{x}[k+1 &= \mathbf{A} \mathbf{x}[k + \mathbf{B} \mathbf{u}[k \ \mathbf{y}[k &= \mathbf{C} \mathbf{x}[k + \mathbf{D} \mathbf{u}[k \end{aligned}
Here, $\mathbf{x}[k \in \mathbb{R}^n$ is the state vector, $\mathbf{u}[k \in \mathbb{R}^m$ is the input vector, and $\mathbf{y}[k \in \mathbb{R}^l$ is the output vector. The initial state is defined as $\mathbf{x} $ . The system order, $n$, is the number of state variables (or memory elements). The system matrices have dimensions: $\mathbf{A} \in \mathbb{R}^{n \times n}$, $\mathbf{B} \in \mathbb{R}^{n \times m}$, $\mathbf{C} \in \mathbb{R}^{l \times n}$, and $\mathbf{D} \in \mathbb{R}^{l \times m}$. For a Single-Input-Single-Output (SISO) system ($m=l=1$) :\begin{aligned} \mathbf{x}[k+1 &= \mathbf{A} \mathbf{x}[k + \mathbf{b} u[k \ y[k &= \mathbf{c} \mathbf{x}[k + d u[k \end{aligned}
where $\mathbf{b}$ is a column vector, $\mathbf{c}$ is a row vector, and $d$ is a scalar . ### 9.2 System Response Calculation The analysis seeks to determine $\mathbf{x}[k]$ and $\mathbf{y}[k]$ given $\mathbf{A}, \mathbf{B}, \mathbf{C}, \mathbf{D}$, $\mathbf{u}[k]$, and $\mathbf{x} $. This can be done numerically or by solving the state equation analytically . #### 9.2.1 Analytical Solution Iterative substitution yields the general form for $k > 0$ :\mathbf{x}[k = \mathbf{A}^k \mathbf{x} + \sum_{j=0}^{k-1} \mathbf{A}^{k-1-j} \mathbf{B} \mathbf{u}[j .
Thecorrespondingoutputis:\mathbf{y}[k = \mathbf{C} \mathbf{x}[k + \mathbf{D} \mathbf{u}[k
For $k=0$, $\mathbf{y} = \mathbf{C} \mathbf{x} + \mathbf{D} \mathbf{u} $ . #### 9.2.2 Zero-input and Zero-state Response The system response is the sum of two components : 1. **Zero-input response:** $\mathbf{y}[k]$ when $\mathbf{u}[k = 0$ for all $k$. This is determined by the initial state $\mathbf{x} $: $\mathbf{y}_{\text{zi}}[k = \mathbf{C} \mathbf{A}^k \mathbf{x} $ . 2. **Zero-state response:** $\mathbf{y}[k]$ when $\mathbf{x} = 0$. This depends only on the input $\mathbf{u}[k]$ . > **Tip:** For a SISO system, the zero-input response ($\mathbf{y}_{\text{zi}}[k = \mathbf{c} \mathbf{A}^k \mathbf{x} $) is a weighted sum of terms involving the eigenvalues $\lambda_i$ raised to the power $k$: $\sum_{i=1}^n w_i \lambda_i^k \mathbf{v}_i$ . ### 9.3 Equivalent descriptions and similarity transformations The state-space representation is not unique. A similarity transformation using an invertible matrix $\mathbf{P}$ changes the coordinates from $\mathbf{x}[k]$ to $\mathbf{w}[k = \mathbf{P}^{-1} \mathbf{x}[k]$ .\begin{aligned} \mathbf{w}[k+1 &= \mathbf{\bar{A}} \mathbf{w}[k + \mathbf{\bar{B}} \mathbf{u}[k \ \mathbf{y}[k &= \mathbf{\bar{C}} \mathbf{w}[k + \mathbf{\bar{D}} \mathbf{u}[k \end{aligned}
Thetransformedmatricesarerelatedby:\mathbf{\bar{A}} = \mathbf{P}^{-1} \mathbf{A} \mathbf{P}, \quad \mathbf{\bar{B}} = \mathbf{P}^{-1} \mathbf{B}, \quad \mathbf{\bar{C}} = \mathbf{C} \mathbf{P}, \quad \mathbf{\bar{D}} = \mathbf{D}
$\mathbf{A}$ and $\mathbf{\bar{A}}$ are similar matrices. The transformation requires the initial condition compatibility: $\mathbf{x} = \mathbf{P} \mathbf{w} $ . #### 9.3.1 Diagonal form If matrix $\mathbf{A}$ has $n$ distinct eigenvalues ($\lambda_i$), it is diagonalizable. If $\mathbf{P}$ is chosen such that its columns are the eigenvectors ($\mathbf{P} = [\mathbf{v}_1, \ldots, \mathbf{v}_n]$), then $\mathbf{\bar{A}}$ becomes a diagonal matrix $\mathbf{\Lambda}$ :\mathbf{\Lambda} = \mathbf{P}^{-1} \mathbf{A} \mathbf{P} = \begin{pmatrix} \lambda_1 & \cdots & 0 \ \vdots & \ddots & \vdots \ 0 & \cdots & \lambda_n \end{pmatrix}
The system decouples into $n$ independent first-order systems in the new state $\mathbf{w}[k]$ :w_i[k+1 = \lambda_i w_i[k + \mathbf{\bar{b}}_i u[k \quad (i=1, \ldots, n)
> **Example:** The technique to convert $(\mathbf{A}, \mathbf{b}, \mathbf{c}, d)$ to diagonal form $(\mathbf{\Lambda}, \mathbf{\bar{b}}, \mathbf{\bar{c}}, \bar{d})$ involves finding eigenvalues/eigenvectors to form $\mathbf{P}$, solving $\mathbf{P} \mathbf{\bar{b}} = \mathbf{b}$, and computing $\mathbf{\bar{c}} = \mathbf{c} \mathbf{P}$ . #### 9.3.2 Minimality (Controllability and Observability) In diagonal form, properties related to the usefulness of state variables become clear : * If $\mathbf{\bar{b}}_i = 0$, the state variable $w_i[k]$ cannot be influenced by the input; the system is **not controllable** . * If $\mathbf{\bar{c}}_i = 0$, the state variable $w_i[k]$ cannot influence the output; the system is **not observable** . A system that is not observable and/or not controllable is called **non-minimal**, meaning the same input-output behavior can be achieved with fewer memory elements . ### 9.4 Stability Analysis #### 9.4.1 Internal Stability A system is **internally stable** if the state $\mathbf{x}[k \to 0$ as $k \to \infty$ for zero input ($\mathbf{u}[k]=0$) and for all initial states $\mathbf{x} $ . This requires that the magnitude of all eigenvalues of $\mathbf{A}$ must be strictly less than one :\text{Internal Stability} \iff |\lambda_i| < 1 \quad \text{for } i = 1, \ldots, n
If any $|\lambda_i| \geq 1$, the system is internally unstable . > **Tip:** When using the diagonal form $(\mathbf{\Lambda}, \mathbf{\bar{b}}, \mathbf{\bar{c}}, \bar{d})$, stability is checked by $|\lambda_i| < 1$, controllability by $\mathbf{\bar{b}}_i \neq 0$, and observability by $\mathbf{\bar{c}}_i \neq 0$ . #### 9.4.2 Effect of Eigenvalues on Zero-Input Response The zero-input response is composed of terms $\lambda_i^k$ : * If $|\lambda_i| > 1$, the component grows exponentially . * If $|\lambda_i| < 1$, the component decays exponentially towards zero . * If $|\lambda_i| = 1$, the component is bounded (oscillatory or constant) . If eigenvalues are complex, $\lambda_i = r e^{i \pi \omega}$ and $\lambda_{i+1} = \bar{\lambda}_i$. The contribution to the output $y[k]$ involves an exponential decay/growth factor $r^k$ and an oscillating term $\cos(\phi + k\pi\omega)$ . ### 9.5 Canonical Forms and Difference Equations #### 9.5.1 Controllable Canonical Form A specific coordinate transformation $\mathbf{Q} = [\mathbf{q}_1, \ldots, \mathbf{q}_n]$ can transform $(\mathbf{A}, \mathbf{b})$ into the controllable canonical form $(\mathbf{\tilde{A}}, \mathbf{\bar{b}})$. $\mathbf{\tilde{A}}$ is the companion matrix, derived from the coefficients ($\tilde{a}_i$) of the characteristic polynomial of $\mathbf{A}$ . The relationship $\mathbf{A}\mathbf{Q} = \mathbf{Q}\mathbf{\tilde{A}}$ and $\mathbf{Q}\mathbf{\bar{b}} = \mathbf{b}$ is used for construction, where $\mathbf{\bar{b}}$ is typically $\begin{pmatrix} 0 & \cdots & 0 & 1 \end{pmatrix}^T$ . In this form, the first state variable $w_1[k]$ satisfies a single difference equation derived from the state equations :w_1[k+n + \tilde{a}{n-1} w_1[k+n-1 + \tilde{a}{n-2} w_1[k+n-2 + \cdots + \tilde{a}_0 w_1[k = u[k
The output equation involves the transformed $\mathbf{\bar{c}}$ vector: $y[k = \mathbf{\bar{c}} \mathbf{w}[k + \bar{d} u[k]$ . #### 9.5.2 Difference Equation from Canonical Form By eliminating $w_2[k, \ldots, w_n[k]$ between the state equations and the output equation, a linear difference equation relating $y[k]$ and $u[k]$ is obtained :y[k+n + \tilde{a}_{n-1} y[k+n-1 + \cdots + \tilde{a}0 y[k = f_n u[k+n + f{n-1} u[k+n-1 + \cdots + f_0 u[k
where $\tilde{a}_i$ are coefficients from the characteristic polynomial of $\mathbf{A}$, and $f_j$ depend on $\mathbf{\bar{c}}$ and $\bar{d}$ . > **Example:** For the system $(\mathbf{A}, \mathbf{b}, \mathbf{c}, d)$ from the previous example the characteristic polynomial yields $\tilde{a}_1 = 0$ and $\tilde{a}_0 = -1/4$. The resulting difference equation, after finding $\mathbf{Q}$ and $\mathbf{\bar{c}}$, leads to $y[k+2 - \frac{1}{4} y[k = u[k]$ . ### 9.6 Impulse Response and Convolution The **impulse response** $h[k]$ of a SISO DTLTI system starting from the zero state ($\mathbf{x} =0$) is the output $\mathbf{y}[k]$ when the input is the unit impulse $\mathbf{u}[k = \delta[k]$ . For a system starting from the zero state, the output $\mathbf{y}[k]$ is the **convolution** of the input $\mathbf{u}[k]$ and the impulse response $h[k]$: $y = u * h$ .y[k = \sum_{j=-\infty}^{\infty} u[j h[k-j
For causal signals ($u[j]=0, h[j]=0$ for $j<0$), this simplifies to:y[k = \sum_{j=0}^{k} u[j h[k-j
The impulse response is derived from the state equations : * $h = d$ . * $h[k = \mathbf{c} \mathbf{A}^{k-1} \mathbf{b}$ for $k > 0$ For a diagonalizable $\mathbf{A}$, $h[k]$ is a weighted sum of exponential terms ($\lambda_i^k$) or oscillating exponential terms (for complex $\lambda_i$) . --- # Orthogonality, projections, and decompositions in $\mathbb{R}^n$ This topic section covers the fundamental concepts of inner products, orthogonality, orthogonal complements, projections onto subspaces, techniques for constructing orthogonal bases (Gram-Schmidt), and the related QR factorization, which is crucial for solving least squares problems. ### 10.1 Inner Product and Orthogonality The inner product (dot product) of two vectors $\mathbf{u}, \mathbf{v} \in \mathbb{R}^n$ is defined as: $$\mathbf{u} \cdot \mathbf{v} = \mathbf{u}^T \mathbf{v} = u_1v_1 + \dots + u_nv_n \in \mathbb{R}$$ . **Properties of the Inner Product** : For all $\mathbf{u}, \mathbf{v}, \mathbf{w} \in \mathbb{R}^n$ and scalar $c \in \mathbb{R}$: 1. $\mathbf{u} \cdot \mathbf{v} = \mathbf{v} \cdot \mathbf{u}$ 2. $(\mathbf{u}+\mathbf{v}) \cdot \mathbf{w} = \mathbf{u} \cdot \mathbf{w} + \mathbf{v} \cdot \mathbf{w}$ 3. $(c\mathbf{u}) \cdot \mathbf{v} = c(\mathbf{u} \cdot \mathbf{v}) = \mathbf{u} \cdot (c\mathbf{v})$ 4. $\mathbf{u} \cdot \mathbf{u} \geq 0$; and $\mathbf{u} \cdot \mathbf{u} = 0$ if and only if $\mathbf{u} = \mathbf{0}$ . **Norm and Distance** The norm (or length) of a vector $\mathbf{u}$ is defined as $||\mathbf{u}|| = \sqrt{\mathbf{u} \cdot \mathbf{u}}$ . Vector normalization means dividing the vector by its norm: $\frac{\mathbf{u}}{||\mathbf{u}||}$ . The distance between $\mathbf{u}$ and $\mathbf{v}$ is $d(\mathbf{u},\mathbf{v}) = ||\mathbf{u}-\mathbf{v}|| = ||\mathbf{v}-\mathbf{u}||$ . **Orthogonal Vectors** Two vectors $\mathbf{u}$ and $\mathbf{v}$ are orthogonal ($\mathbf{u} \perp \mathbf{v}$) if their inner product is zero: $$\mathbf{u} \perp \mathbf{v} \iff \mathbf{u} \cdot \mathbf{v} = 0$$ . The Pythagorean theorem equivalent holds: $\mathbf{u} \perp \mathbf{v} \iff ||\mathbf{u}+\mathbf{v}||^2 = ||\mathbf{u}||^2 + ||\mathbf{v}||^2$ . ### 10.2 Orthogonal Complement If $W$ is a subspace of $\mathbb{R}^n$, a vector $\mathbf{z} \in \mathbb{R}^n$ is orthogonal to $W$ if $\mathbf{z} \cdot \mathbf{w} = 0$ for all $\mathbf{w} \in W$ . The **orthogonal complement** of $W$, denoted $W^{\perp}$, is the set of all vectors orthogonal to $W$: $$W^{\perp} = \{\mathbf{z} \in \mathbb{R}^n: \mathbf{z} \cdot \mathbf{w} = 0 \text{ for all } \mathbf{w} \in W\}$$ . $W^{\perp}$ is always a subspace of $\mathbb{R}^n$ . If $W = \text{Span}\{\mathbf{v}_1, \dots, \mathbf{v}_p\}$, then $\mathbf{z} \in W^{\perp}$ if and only if $\mathbf{z} \cdot \mathbf{v}_i = 0$ for $i=1, \dots, p$ . **Relationships between Subspaces and Orthogonal Complements** For an $m \times n$ matrix $A$: 1. $(\text{Row } A)^{\perp} = \text{Nul } A$ . 2. $(\text{Col } A)^{\perp} = \text{Nul } A^T$ . The relationship $\mathbf{x} \in \text{Nul } A$ is equivalent to $\mathbf{x}$ being orthogonal to every row of $A$, meaning $\mathbf{x} \perp \text{Row } A$, hence $\mathbf{x} \in (\text{Row } A)^{\perp}$ . ### 10.3 Orthogonal Bases and Projections **Orthogonal and Orthonormal Sets** A set $S = \{\mathbf{u}_1, \dots, \mathbf{u}_p\}$ is **orthogonal** if $\mathbf{u}_i \cdot \mathbf{u}_j = 0$ for all $i \neq j$ . A set $S$ is **orthonormal** if it is orthogonal and $||\mathbf{u}_i|| = 1$ for all $i$ . **Theorem 4:** If $S = \{\mathbf{u}_1, \dots, \mathbf{u}_p\}$ is an orthogonal set of non-zero vectors, then $S$ is linearly independent and thus forms a basis for $\text{Span}\{\mathbf{u}_1, \dots, \mathbf{u}_p\}$ . An orthogonal basis for a subspace $W$ is a basis that is also an orthogonal set . **Coordinates in an Orthogonal Basis** If $S = \{\mathbf{u}_1, \dots, \mathbf{u}_p\}$ is an orthogonal basis for $W$, then for any $\mathbf{y} \in W$, the coordinates $c_j$ relative to this basis are calculated as: $$c_j = \frac{\mathbf{y} \cdot \mathbf{u}_j}{\mathbf{u}_j \cdot \mathbf{u}_j}$$ . Thus, $\mathbf{y} = c_1 \mathbf{u}_1 + \dots + c_p \mathbf{u}_p$ . **Orthogonal Projection** For any $\mathbf{y} \in \mathbb{R}^n$, there exists a unique decomposition (orthogonal decomposition): $$\mathbf{y} = \hat{\mathbf{y}} + \mathbf{z} \quad \text{with } \hat{\mathbf{y}} \in W \text{ and } \mathbf{z} \in W^{\perp}$$ . Here, $\hat{\mathbf{y}} = \text{Proj}_W(\mathbf{y})$ is the orthogonal projection of $\mathbf{y}$ onto $W$, and $\mathbf{z}$ is the component orthogonal to $W$. This decomposition is unique and $\hat{\mathbf{y}}$ is independent of the basis chosen for $W$ . If $\{\mathbf{u}_1, \dots, \mathbf{u}_p\}$ is an orthogonal basis for $W$, the projection is: $$\text{Proj}_W(\mathbf{y}) = \hat{\mathbf{y}} = \frac{\mathbf{y} \cdot \mathbf{u}_1}{\mathbf{u}_1 \cdot \mathbf{u}_1}\mathbf{u}_1 + \cdots + \frac{\mathbf{y} \cdot \mathbf{u}_p}{\mathbf{u}_p \cdot \mathbf{u}_p}\mathbf{u}_p$$ . **Theorem 9: Best Approximation Property** If $\hat{\mathbf{y}} = \text{Proj}_W(\mathbf{y})$, then for any $\mathbf{v} \neq \hat{\mathbf{y}}$ in $W$: $$||\mathbf{y} - \hat{\mathbf{y}}|| < ||\mathbf{y} - \mathbf{v}||$$ This means $\hat{\mathbf{y}}$ is the vector in $W$ closest to $\mathbf{y}$. This is proven because $\mathbf{y} - \mathbf{v} = (\mathbf{y} - \hat{\mathbf{y}}) + (\hat{\mathbf{y}} - \mathbf{v})$, where the two terms on the right are orthogonal, leading to $||\mathbf{y} - \mathbf{v}||^2 = ||\mathbf{y} - \hat{\mathbf{y}}||^2 + ||\hat{\mathbf{y}} - \mathbf{v}||^2$ . **Projection with Orthonormal Basis** If $\{\mathbf{u}_1, \dots, \mathbf{u}_p\}$ is an **orthonormal** basis for $W$, the projection simplifies significantly: $$\text{Proj}_W(\mathbf{y}) = \hat{\mathbf{y}} = (\mathbf{y} \cdot \mathbf{u}_1)\mathbf{u}_1 + \cdots + (\mathbf{y} \cdot \mathbf{u}_p)\mathbf{u}_p$$ . If $U = [\mathbf{u}_1 \ \dots \ \mathbf{u}_p]$ is the $n \times p$ matrix whose columns form an orthonormal basis for $W$, then: $$\hat{\mathbf{y}} = \text{Proj}_W(\mathbf{y}) = U U^T \mathbf{y}$$ . The matrix $U U^T$ is the $n \times n$ standard matrix for the orthogonal projection onto $W$. Since the columns are orthonormal, $U^T U = I_p$ . **Matrices with Orthonormal Columns** For a matrix $U \in \mathbb{R}^{m \times n}$ with orthonormal columns: 1. $U^T U = I_n$ . 2. $(U\mathbf{x}) \cdot (U\mathbf{y}) = \mathbf{x} \cdot \mathbf{y}$ . 3. $(U\mathbf{x}) \perp (U\mathbf{y}) \iff \mathbf{x} \perp \mathbf{y}$ . An **orthogonal matrix** is a square matrix ($m=n$) with orthonormal columns. For an orthogonal matrix $U$, $U^T U = I_n$ and $U U^T = U^{-1} U = I_n$, meaning its rows are also orthonormal . ### 10.4 The Gram-Schmidt Process The Gram-Schmidt process transforms a basis $\{\mathbf{x}_1, \dots, \mathbf{x}_p\}$ for a subspace $W = \text{Span}\{\mathbf{x}_1, \dots, \mathbf{x}_p\}$ into an orthogonal (and subsequently orthonormal) basis $\{\mathbf{v}_1, \dots, \mathbf{v}_p\}$ for the same space $W$ . **Gram-Schmidt Process (Orthogonal Basis Construction)** : Given a basis $\{\mathbf{x}_1, \dots, \mathbf{x}_p\}$ for $W$ (assuming $\mathbf{x}_i \neq \mathbf{0}$): 1. $\mathbf{v}_1 = \mathbf{x}_1$ . 2. $\mathbf{v}_2 = \mathbf{x}_2 - \text{Proj}_{W_1} \mathbf{x}_2 = \mathbf{x}_2 - \frac{\mathbf{x}_2 \cdot \mathbf{v}_1}{\mathbf{v}_1 \cdot \mathbf{v}_1}\mathbf{v}_1$ . 3. $\mathbf{v}_3 = \mathbf{x}_3 - \text{Proj}_{W_2} \mathbf{x}_3 = \mathbf{x}_3 - \frac{\mathbf{x}_3 \cdot \mathbf{v}_1}{\mathbf{v}_1 \cdot \mathbf{v}_1}\mathbf{v}_1 - \frac{\mathbf{x}_3 \cdot \mathbf{v}_2}{\mathbf{v}_2 \cdot \mathbf{v}_2}\mathbf{v}_2$ . ... $p$. $\mathbf{v}_p = \mathbf{x}_p - \text{Proj}_{W_{p-1}} \mathbf{x}_p$ . The resulting set $\{\mathbf{v}_1, \dots, \mathbf{v}_p\}$ is an orthogonal basis for $W$. Normalizing each $\mathbf{v}_i$ yields an orthonormal basis $\{\mathbf{q}_1, \dots, \mathbf{q}_p\}$ . > **Tip:** The core idea is constructing $\mathbf{v}_{k+1}$ by subtracting the projection of $\mathbf{x}_{k+1}$ onto the subspace spanned by the previously constructed orthogonal vectors $\{\mathbf{v}_1, \dots, \mathbf{v}_k\}$ (which equals $\text{Span}\{\mathbf{x}_1, \dots, \mathbf{x}_k\}$) . ### 10.5 QR Factorization If $A = [\mathbf{x}_1 \ \dots \ \mathbf{x}_n]$ is an $m \times n$ matrix whose columns are linearly independent, the Gram-Schmidt process applied to the columns yields an $m \times n$ matrix $Q = [\mathbf{q}_1 \ \dots \ \mathbf{q}_n]$ with orthonormal columns, and an invertible $n \times n$ upper triangular matrix $R$ such that: $$A = QR$$ . Since $\{\mathbf{q}_1, \dots, \mathbf{q}_n\}$ is an orthonormal basis for $\text{Col } A$, and $\mathbf{x}_k \in \text{Span}\{\mathbf{q}_1, \dots, \mathbf{q}_k\}$, the entries $r_{ik}$ of $R$ are determined by the coefficients when expressing $\mathbf{x}_k$ in the basis $\{\mathbf{q}_1, \dots, \mathbf{q}_k\}$. Specifically, $r_{ik} = \mathbf{x}_k \cdot \mathbf{q}_i$ for $i \leq k$, and $r_{kk} = ||\mathbf{v}_k|| > 0$ . **Properties of R:** $R$ is upper triangular, invertible, and has strictly positive diagonal elements . Since $Q$ has orthonormal columns, $Q^T Q = I_n$ . **Applications of QR Factorization:** 1. $\text{Col } A = \text{Col } Q$ . 2. $A^T A = (R^T Q^T)(QR) = R^T Q^T Q R = R^T R$ . 3. Helps reduce numerical sensitivity and solves least squares problems . ### 10.6 Least Squares Problems For solving $A\mathbf{x} = \mathbf{b}$: if the system is inconsistent ($\mathbf{b} \notin \text{Col } A$), no exact solution exists . A **least squares solution ($\hat{\mathbf{x}}$)** minimizes the error vector magnitude: $$\mathbf{x} \in \mathbb{R}^n \text{ is a least squares solution (kko) if } ||\mathbf{b} - A\hat{\mathbf{x}}|| \leq ||\mathbf{b} - A\mathbf{x}|| \text{ for all } \mathbf{x} \in \mathbb{R}^n$$ . The vector $\hat{\mathbf{b}} = A\hat{\mathbf{x}} \in \text{Col } A$ is the unique vector in $\text{Col } A$ closest to $\mathbf{b}$ (the best approximation). The error vector $\mathbf{b} - A\hat{\mathbf{x}}$ is orthogonal to $\text{Col } A$ . **Normal Equations** The least squares solutions are precisely the solutions to the **normal equations**: $$A^T A \hat{\mathbf{x}} = A^T \mathbf{b}$$ . This system always has at least one solution . **Uniqueness and QR Factorization** $A\mathbf{x} = \mathbf{b}$ has a unique least squares solution for every $\mathbf{b} \in \mathbb{R}^m$ if and only if the columns of $A$ are linearly independent (i.e., $A^T A$ is invertible) . If the solution is unique, it is given by: $$\hat{\mathbf{x}} = (A^T A)^{-1} A^T \mathbf{b}$$ . **Least Squares using QR Factorization (when columns of A are L.I.)** : If $A=QR$ where $R$ is invertible: $$\hat{\mathbf{x}} = (R^T Q^T Q R)^{-1} R^T Q^T \mathbf{b} = (R^T R)^{-1} R^T Q^T \mathbf{b} = R^{-1} (R^T)^{-1} R^T Q^T \mathbf{b} = R^{-1} Q^T \mathbf{b}$$ Thus, solving $A\mathbf{x} = \mathbf{b}$ reduces to solving the upper triangular system: $$R\hat{\mathbf{x}} = Q^T \mathbf{b}$$ . **Rank and $A^T A$** The columns of $A$ are linearly independent if and only if the columns of $A^T A$ are linearly independent. Consequently, $A$ and $A^T A$ have the same rank . --- # Applications of linear algebra: Least Squares and Data Analysis This topic explores finding the best approximate solutions to inconsistent systems using least squares methods, derived from the normal equations or QR factorization, and details the application of Singular Value Decomposition (SVD) in data analysis, particularly dimensionality reduction for information retrieval. ### 10.1 Linear least squares problems (KKO) The concept of least squares arises when dealing with overdetermined systems that have no exact solution, often encountered in modeling data . #### 10.1.1 Model formulation A common scenario involves fitting a model to measured data points $y_i$ taken at times $t_i$, where the underlying relationship is linear in the unknown parameters $x$ . For instance, modeling the height $z$ of a tennis ball over time $t$ using the kinematic equation: $$z = -\frac{g}{2} t^2 + v_0 t + z_0$$ If we have $m$ measurements $y_i$ at times $t_i$, the model error $e_i$ is defined by $y_i = z_i + e_i$ . The unknown model parameters form the vector $x^T = [-g/2 \ v_0 \ z_0]$ . This relationship can be written in matrix form as $y = Ax + e$ . In the general case, where the model is linear in $n$ parameters $x$, the $i$-th measurement is given by: $$y_i = [f_1(t_i) \ \ldots \ f_n(t_i)] x + e_i$$ where $f_j$ are known functions of the measured values $t_i$. The matrix $A$ (the design matrix) has entries $a_{ij} = f_j(t_i)$. Finding the best fit $\hat{x}$ for $y = Ax$ requires solving the corresponding Least Squares Problem (KKO) . > **Tip:** The least squares solution minimizes the Euclidean norm of the error vector $e$, i.e., $\min \|e\|^2 = \min \|y - Ax\|^2$ . ### 10.2 Singular Value Decomposition (SVD) The Singular Value Decomposition (SVD) provides a powerful factorization for any matrix $A \in \mathbb{R}^{m \times n}$ . #### 10.2.1 SVD Theorem **Theorem 10: Singular Value Decomposition (SVD)** . If $A \in \mathbb{R}^{m \times n}$ has rank $r$, there exists a factorization $A = U \Sigma V^T$ such that: 1. $U = [u_1 \ \ldots \ u_m \in \mathbb{R}^{m \times m}$ is an orthogonal matrix ($U^T U = I_m$), whose columns $u_i$ are the **left singular vectors** . 2. $V = [v_1 \ \ldots \ v_n \in \mathbb{R}^{n \times n}$ is an orthogonal matrix ($V^T V = I_n$), whose columns $v_i$ are the **right singular vectors** . 3. $\Sigma \in \mathbb{R}^{m \times n}$ has the form: $$\Sigma = \begin{pmatrix} \Sigma_r & 0 \\ 0 & 0 \end{pmatrix}, \quad \Sigma_r = \begin{pmatrix} \sigma_1 & \cdots & 0 \\ \vdots & \ddots & \vdots \\ 0 & \cdots & \sigma_r \end{pmatrix}$$ where $\sigma_1 \geq \sigma_2 \geq \cdots \geq \sigma_r > 0$ are the **singular values** . **Alternative Forms:** * **Reduced SVD:** $A = U_r \Sigma_r V_r^T$, where $U_r = [u_1 \ \ldots \ u_r]$ and $V_r = [v_1 \ \ldots \ v_r]$ . * **Outer Product Form:** $A = \sigma_1 u_1 v_1^T + \cdots + \sigma_r u_r v_r^T$ . #### 10.2.2 Interpretations of SVD SVD reveals fundamental geometric properties of the linear transformation $T: \mathbb{R}^n \to \mathbb{R}^m$ defined by $x \to Ax$ . 1. **Transformation Property:** A right singular vector $v_i$ is mapped to a multiple of its corresponding left singular vector $u_i$ for $i \leq r$: $$A v_i = \sigma_i u_i \quad (i \leq r)$$ The right singular vector is mapped onto a real multiple of the corresponding left singular vector . 2. **Geometric Decomposition:** Any linear transformation $A$ can be decomposed as a composition of three basic operations: * Rotation/reflection in $\mathbb{R}^n$ by $V^T$ . * Scaling of axes by $\Sigma$ from $\mathbb{R}^n \to \mathbb{R}^m$ . * Rotation/reflection in $\mathbb{R}^m$ by $U$ . #### 10.2.3 Relation to Eigenvalue Decomposition For a symmetric matrix $A$, the SVD relates to the spectral decomposition $A = PD P^T$. If $A$ is symmetric, one can choose $U_r = [p_1 \ p_2 \ \ldots \ p_r]$ and $V_r = [s_1 p_1 \ s_2 p_2 \ \ldots \ s_r p_r]$, where $s_i = \text{sgn}(\lambda_i)$ is the sign of the eigenvalue $\lambda_i$. Then $\Sigma_r = \text{diag}(s_1 \lambda_1, \ldots, s_r \lambda_r)$ . **Construction of SVD:** The singular vectors and values are derived from the eigendecomposition of $A^T A$ . 1. Calculate $A^T A$, which is diagonalizable and positive semi-definite . 2. $A^T A = V D V^T$, where $v_i$ are orthonormal eigenvectors and $\lambda_i$ are eigenvalues such that $\lambda_1 \geq \lambda_2 \geq \cdots \geq \lambda_n \geq 0$ . 3. The singular values are $\sigma_i = \sqrt{\lambda_i}$. If $r$ is the rank, then $\sigma_1 \geq \cdots \geq \sigma_r > 0$ . #### 10.2.4 Fundamental Subspaces via SVD SVD provides orthonormal bases for the four fundamental subspaces associated with $A$. Let $r$ be the rank of $A$ : * **Column Space ($\text{Col } A$):** $\{u_1, \ldots, u_r\}$ forms an orthonormal basis . * **Left Null Space ($\text{Nul } A^T$):** $\{u_{r+1}, \ldots, u_m\}$ forms an orthonormal basis for $(\text{Col } A)^\perp = \text{Nul } A^T$ . * **Row Space ($\text{Row } A$):** $\{v_1, \ldots, v_r\}$ forms an orthonormal basis for $\text{Row } A$ (which is $\text{Col } A^T$) . * **Null Space ($\text{Nul } A$):** $\{v_{r+1}, \ldots, v_n\}$ forms an orthonormal basis for $\text{Nul } A$ . > **Example:** The set $\{A v_1, \ldots, A v_r\}$ is an orthogonal basis for $\text{Col } A$ . #### 10.2.5 SVD and Invertibility If $A$ is a square matrix ($m=n$), $A$ is invertible if and only if all singular values are strictly positive. Other equivalent conditions include $\text{Col } A = \mathbb{R}^n$ and $\text{Row } A = \mathbb{R}^n$ . ### 10.3 Moore-Penrose Pseudo-inverse The pseudo-inverse, denoted $A^\dagger$, exists for every matrix $A \in \mathbb{R}^{m \times n}$ and is constructed using the reduced SVD $A = U_r \Sigma_r V_r^T$ . $$A^\dagger = V_r \Sigma_r^{-1} U_r^T$$ $\Sigma_r^{-1}$ is formed by taking the reciprocal of each non-zero singular value and transposing the resulting diagonal matrix. $A^\dagger$ is an $n \times m$ matrix . #### 10.3.1 Pseudo-inverse and Least Squares The vector $\hat{x} = A^\dagger b$ is proposed as the least squares solution to $Ax=b$ . If $r < n$, the general solution set for the least squares problem is $\hat{x} + v$, where $v \in \text{Nul } A$ . Crucially, $\hat{x} = A^\dagger b$ lies in $\text{Row } A$. Since $\text{Row } A$ is orthogonal to $\text{Nul } A$, the solution $\hat{x}$ is the unique least squares solution with the **smallest length (norm)** . If $A$ is square and invertible ($r=m=n$), then $A^\dagger = A^{-1}$ . ### 10.4 Best Rank-k Approximation SVD is essential for finding low-rank approximations, a core technique in data compression and analysis . Given an $m \times n$ matrix $A$ of rank $r$, the goal is to find a matrix $B$ of rank $k \leq r$ that minimizes the squared Frobenius norm of the difference $\|A - B\|_F^2 = \sum_{i,j} (a_{ij} - b_{ij})^2$ . The best rank-$k$ approximation $B$ is given by: $$B = U \Sigma^{(k)} V^T$$ where $\Sigma^{(k)}$ is formed by replacing all singular values $\sigma_{k+1}, \ldots, \sigma_r$ with zero in $\Sigma$ . $$\Sigma^{(k)} = \begin{pmatrix} \Sigma_k & 0 \\ 0 & 0 \end{pmatrix}, \quad \Sigma_k = \text{diag}(\sigma_1, \ldots, \sigma_k)$$ This result is based on the outer product expansion: $$B = \sigma_1 u_1 v_1^T + \cdots + \sigma_k u_k v_k^T$$ This approximation is optimal in the sense that it yields the smallest possible error norm . ### 10.5 Applications in Data Analysis (Information Retrieval) SVD is crucial in information retrieval, embodying the principle: "You shall know a word by the company it keeps". This is leveraged to find related words or documents automatically . #### 10.5.1 Term-Document Matrix A matrix $A$ of size $W \times D$ (where $W$ is the number of unique words and $D$ is the number of documents) is constructed such that $a_{wd}$ is the frequency of word $w$ in document $d$ . * **Document Vectors:** Columns $d_i \in \mathbb{R}^W$ represent documents. Similarity between documents $i$ and $j$ is high if their word frequencies are correlated, measured by the cosine of the angle between their vectors: $\cos \theta_{ij} = \frac{d_i^T d_j}{\|d_i\| \|d_j\|}$ . * **Word Vectors:** Rows $w_i \in \mathbb{R}^D$ represent words. Similarity between words $i$ and $j$ is high if they appear together frequently in documents: $\cos \phi_{ij} = \frac{w_i^T w_j}{\|w_i\| \|w_j\|}$ . #### 10.5.2 Latent Semantic Analysis (LSA) via SVD To combat the high dimensionality ($W$ and $D$ can be very large, e.g., 95,000 words $\times$ 90,000 documents in one example) SVD is applied to find a low-rank representation . 1. **Preprocessing:** Text may undergo normalization, such as weighting entries by $\log(D/N_i)$, where $N_i$ is the number of documents containing word $i$ . 2. **SVD Application:** Calculate the SVD of the term-document matrix $A \approx U_k \Sigma_k V_k^T$ . * $U_k$ is $W \times k$ with orthonormal columns (word features in $k$-space) . * $V_k$ is $D \times k$ with orthonormal columns (document features in $k$-space) . * $\Sigma_k$ is a $k \times k$ diagonal matrix containing the $k$ largest singular values . The similarity between word vectors $w_i$ and $w_j$ in the original space is approximated by their similarity in the reduced $k$-dimensional space using the $U_k$ factors : $$\cos \phi_{ij} \approx \frac{u_i^T \Sigma_k^2 u_j}{ (\Sigma_k u_i)^T (\Sigma_k u_j) } = \frac{u_i^T \Sigma_k u_j}{ \| \Sigma_k u_i \| \| \Sigma_k u_j \| }$$ where $u_i$ is the $i$-th row of $U_k$. This dramatically reduces the dimensionality for similarity calculations (e.g., from 90,000 dimensions to 100 dimensions) . > **Example:** SVD approximation can group words like 'wapen' (weapon), 'munitie' (ammunition), and 'bestand' (truce) together based on co-occurrence patterns across thousands of documents, reducing complex retrieval queries to simple inner products in a much smaller subspace . --- # Symmetric matrices, quadratic forms, and complex vector spaces This topic summarizes the special properties of real symmetric matrices, including their orthogonal diagonalization and spectral decomposition, their connection to quadratic forms and principal axes, and introduces the concepts of complex inner products, Hermitian matrices, and unitary matrices. ### 12.1 Diagonalization of symmetric matrices A matrix $A \in \mathbb{R}^{n \times n}$ is defined as **symmetric** if $A = A^T$ . #### 12.1.1 Properties of symmetric matrices If $A$ is a symmetric matrix and $v_1$ and $v_2$ are eigenvectors corresponding to distinct eigenvalues $\lambda_1$ and $\lambda_2$ ($\lambda_1 \neq \lambda_2$), then $v_1$ and $v_2$ are orthogonal ($v_1 \perp v_2$) . The proof relies on: $$ \lambda_1 (v_1^T v_2) = (Av_1)^T v_2 = v_1^T A^T v_2 = v_1^T (Av_2) = \lambda_2 (v_1^T v_2) $$ This implies $(\lambda_1 - \lambda_2)(v_1^T v_2) = 0$, forcing $v_1^T v_2 = 0$ since $\lambda_1 \neq \lambda_2$ . Crucially, the **eigen-subspaces** of a symmetric matrix are **orthogonal** . Furthermore, **the eigenvalues of a symmetric matrix are always real** . > **Tip:** For a symmetric matrix, the eigenvectors corresponding to distinct eigenvalues are not just linearly independent, but actually **orthogonal** . #### 12.1.2 Orthogonal diagonalization A matrix $A$ is **orthogonally diagonalizable** if $A = P D P^{-1}$ where $P$ is an orthogonal matrix ($P^T P = P P^T = I$, so $P^{-1} = P^T$), and $D$ is a diagonal matrix . **Theorem 2:** $A$ is orthogonally diagonalizable if and only if $A = A^T$ (i.e., $A$ is symmetric) . For a symmetric matrix, the algebraic multiplicity ($\text{m}_i$) equals the geometric multiplicity (dimension of the eigenspace) for every eigenvalue. If $A$ is symmetric, it can be written as $A = P D P^T$ . #### 12.1.3 Spectral Decomposition The orthogonal diagonalization of a symmetric matrix $A$ leads to its **spectral decomposition**: $$ A = P D P^T = \sum_{i=1}^{n} \lambda_i u_i u_i^T $$ where $\{u_1, \dots, u_n\}$ are the orthonormal eigenvectors (columns of $P$) and $\{\lambda_i\}$ are the corresponding eigenvalues (diagonal entries of $D$). The set $\{\lambda_i\}$ is called the **spectrum** of the matrix . > **Example:** The spectral decomposition of $A = \begin{pmatrix} 2 & 0 & 1 \\ 0 & 2 & 1 \\ 1 & 1 & 1 \end{pmatrix}$ with eigenvalues $\lambda_1=0, \lambda_2=2, \lambda_3=3$ and corresponding normalized eigenvectors $u_1, u_2, u_3$ is $A = \lambda_1 u_1 u_1^T + \lambda_2 u_2 u_2^T + \lambda_3 u_3 u_3^T$. Since $\lambda_1=0$, $A$ is singular, and the decomposition shows $A$ written as a sum of two rank-one matrices corresponding to the non-zero eigenvalues . ### 12.2 Quadratic forms A **quadratic form** on $\mathbb{R}^n$ is a function $Q(\mathbf{x}) = \mathbf{x}^T A \mathbf{x} \in \mathbb{R}$, where $A$ is an $n \times n$ symmetric matrix . For $n=3$, $Q(\mathbf{x}) = ax_1^2 + dx_2^2 + fx_3^2 + 2bx_1x_2 + 2cx_1x_3 + 2ex_2x_3$ when $A = \begin{pmatrix} a & b & c \\ b & d & e \\ c & e & f \end{pmatrix}$ . #### 12.2.1 Simplification and principal axes Quadratic forms can be simplified by changing to an orthonormal basis defined by the eigenvectors of $A$. If $A = P D P^T$, where $P = [\mathbf{u}_1 \dots \mathbf{u}_n]$ is orthogonal, and we set $\mathbf{x} = P\mathbf{y}$ (where $\mathbf{y} = P^{-1}\mathbf{x} = P^T\mathbf{x}$), the quadratic form transforms into: $$ Q(\mathbf{x}) = \mathbf{x}^T A \mathbf{x} = (P\mathbf{y})^T A (P\mathbf{y}) = \mathbf{y}^T (P^T A P) \mathbf{y} = \mathbf{y}^T D \mathbf{y} $$ **Theorem 4:** The simplified form has no cross-terms: $$ Q(\mathbf{y}) = \lambda_1 y_1^2 + \lambda_2 y_2^2 + \dots + \lambda_n y_n^2 $$ The eigenvectors $\mathbf{u}_i$ define the **principal axes** of the quadratic form . > **Example:** For $A = \begin{pmatrix} 5 & 2 \\ 2 & 5 \end{pmatrix}$, the eigenvalues are $\lambda_1=3, \lambda_2=7$. Changing basis $\mathbf{x}=P\mathbf{y}$ yields $Q(\mathbf{y}) = 3y_1^2 + 7y_2^2$. If $Q(\mathbf{x})=c$, this equation represents an **ellipse** in the original $\mathbf{x}$-space. If the eigenvalues have opposite signs (e.g., $3y_1^2 - 7y_2^2 = c$), it represents a **hyperbola** . #### 12.2.2 Classification of quadratic forms (Theorem 5) The classification of a quadratic form $Q(\mathbf{x})$ (or the symmetric matrix $A$) depends entirely on the signs of its eigenvalues $\lambda_i$. Assuming eigenvalues are ordered such that $\lambda_1 \geq \lambda_2 \geq \dots \geq \lambda_n$ : | Classification | Condition on $\lambda_i$ | Condition on $Q(\mathbf{x})$ for $\mathbf{x} \neq 0$ | | :--- | :--- | :--- | | Positive definite | $\lambda_i > 0$ for all $i$ | $Q(\mathbf{x}) > 0$ | | Negative definite | $\lambda_i < 0$ for all $i$ | $Q(\mathbf{x}) < 0$ | | Positive semi-definite | $\lambda_i \geq 0$ for all $i$ | $Q(\mathbf{x}) \geq 0$ | | Negative semi-definite | $\lambda_i \leq 0$ for all $i$ | $Q(\mathbf{x}) \leq 0$ | | Indefinite | Mixed positive and negative $\lambda_i$ | $Q(\mathbf{x})$ can be positive or negative | ### 12.3 Optimization with constraints Optimization seeks the maximum (M) or minimum (m) value of the quadratic form $Q(\mathbf{x}) = \mathbf{x}^T A \mathbf{x}$ subject to the constraint $\|\mathbf{x}\| = 1$ (i.e., $\mathbf{x}^T \mathbf{x} = 1$) . Using the change of basis $\mathbf{x} = P\mathbf{y}$ (where $P$ is the orthogonal matrix of normalized eigenvectors), the constraint $\|\mathbf{x}\|^2 = 1$ becomes $\|\mathbf{y}\|^2 = 1$. Thus, optimizing $Q(\mathbf{x})$ under $\|\mathbf{x}\|=1$ is equivalent to optimizing $Q(\mathbf{y}) = \mathbf{y}^T D \mathbf{y}$ under $\|\mathbf{y}\|=1$ . #### 12.3.1 Extrema on the unit sphere If eigenvalues are ordered $\lambda_1 \geq \lambda_2 \geq \dots \geq \lambda_n$ : * **Maximum value (M):** $$ M = \max_{\|\mathbf{x}\|=1} \mathbf{x}^T A \mathbf{x} = \lambda_1 $$ This maximum is achieved when $\mathbf{y} = \pm \mathbf{e}_1$, which corresponds to $\mathbf{x} = \pm P \mathbf{e}_1 = \pm \mathbf{u}_1$ (the normalized eigenvector corresponding to the largest eigenvalue $\lambda_1$). (Stelling 6a) . * **Minimum value (m):** $$ m = \min_{\|\mathbf{x}\|=1} \mathbf{x}^T A \mathbf{x} = \lambda_n $$ This minimum is achieved when $\mathbf{y} = \pm \mathbf{e}_n$, corresponding to $\mathbf{x} = \pm P \mathbf{e}_n = \pm \mathbf{u}_n$ (the normalized eigenvector corresponding to the smallest eigenvalue $\lambda_n$). (Stelling 6b) . #### 12.3.2 Optimization with additional constraints If further constraints are added, such as orthogonality to a set of eigenvectors, the maximum value will be the next largest available eigenvalue . * **Theorem 7:** If constrained by $\|\mathbf{x}\|=1$ and $\mathbf{x} \perp \mathbf{u}_1$, the maximum value is $\lambda_2$ . * **Theorem 8:** If constrained by $\|\mathbf{x}\|=1$ and $\mathbf{x} \perp \mathbf{u}_i$ for $i=1, \dots, k-1$, the maximum value is $\lambda_k$ . ### 12.4 Complex vector spaces and Hermitian matrices The concepts extend naturally to complex vector spaces $\mathbb{C}^n$ . #### 12.4.1 Complex Inner Product and Hermitian Conjugate For $C \in \mathbb{C}^{m \times n}$, the **Hermitian adjoint** (or conjugate transpose) is $C^* = \overline{C}^T$ (complex conjugate followed by transpose) . The **Hermitian product** (or inner product) for $\mathbf{u}, \mathbf{v} \in \mathbb{C}^n$ is defined as: $$ \mathbf{u} \bullet \mathbf{v} = \mathbf{u}^* \mathbf{v} = \overline{\mathbf{u}}^T \mathbf{v} $$ Properties include $\mathbf{u} \bullet \mathbf{v} = \overline{\mathbf{v} \bullet \mathbf{u}}$ and $\mathbf{u} \bullet \mathbf{u} \geq 0$, with equality iff $\mathbf{u} = \mathbf{0}$ . If $\mathbf{u} \in \mathbb{R}^n$, the Hermitian product reduces to the standard dot product $\mathbf{u}^T \mathbf{v}$ . Orthogonality is defined as $\mathbf{u} \perp \mathbf{v} \iff \mathbf{u} \bullet \mathbf{v} = 0$ . #### 12.4.2 Hermitian Matrices A square matrix $C \in \mathbb{C}^{n \times n}$ is **Hermitian** if $C^* = C$ . * A real symmetric matrix is Hermitian . * A Hermitian matrix has real entries on its main diagonal . #### 12.4.3 Unitary Matrices and Orthogonal Bases in $\mathbb{C}^n$ If $\{\mathbf{u}_1, \dots, \mathbf{u}_p\}$ is an orthogonal basis for a subspace $W \subset \mathbb{C}^n$, the coefficients $c_j$ in $\mathbf{y} = c_1 \mathbf{u}_1 + \dots + c_p \mathbf{u}_p$ are found via: $$ c_j = \frac{\mathbf{u}_j \bullet \mathbf{y}}{\mathbf{u}_j \bullet \mathbf{u}_j} $$ The order of the inner product matters: $\mathbf{u} \bullet (c\mathbf{v}) = c(\mathbf{u} \bullet \mathbf{v})$ and $(c\mathbf{u}) \bullet \mathbf{v} = \overline{c}(\mathbf{u} \bullet \mathbf{v})$ . If $\{\mathbf{u}_1, \dots, \mathbf{u}_p\}$ is an **orthonormal** basis ($\mathbf{u}_j \bullet \mathbf{u}_j = 1$), the orthogonal projection $\text{Proj}_W(\mathbf{y})$ is: $$ \text{Proj}_W(\mathbf{y}) = (\mathbf{u}_1 \bullet \mathbf{y}) \mathbf{u}_1 + \dots + (\mathbf{u}_p \bullet \mathbf{y}) \mathbf{u}_p = \mathbf{U} \mathbf{U}^* \mathbf{y} $$ where $\mathbf{U} = [\mathbf{u}_1 \dots \mathbf{u}_p]$ . A matrix $\mathbf{U} \in \mathbb{C}^{n \times n}$ whose columns are orthonormal is called a **unitary matrix**, satisfying $\mathbf{U}\mathbf{U}^* = \mathbf{U}^* \mathbf{U} = I$, meaning $\mathbf{U}^{-1} = \mathbf{U}^*$ . #### 12.4.4 Eigenvalues and Eigenvectors of Hermitian Matrices Similar to real symmetric matrices: 1. **Eigenvalues of a Hermitian matrix $C$ are real** . 2. **Eigen-subspaces corresponding to distinct eigenvalues are orthogonal** with respect to the Hermitian product . #### 12.4.5 Eigenvalue decomposition of Hermitian Matrices A Hermitian matrix $C$ admits an eigenvalue decomposition: $$ C = U D U^* $$ where $U$ is a unitary matrix (whose columns are the orthonormal eigenvectors) and $D$ is a real diagonal matrix containing the eigenvalues . --- ## Common mistakes to avoid - Review all topics thoroughly before exams - Pay attention to formulas and key definitions - Practice with examples provided in each section - Don't memorize without understanding the underlying concepts© 2026 Maeve. All rights reserved. This content is protected by copyright.