Differences between revisions 18 and 19
Revision 18 as of 2025-09-24 18:01:44
Size: 2861
Comment: Simplifying matrix page names
Revision 19 as of 2026-02-16 15:47:43
Size: 2725
Comment: Rewrite
Deletions are marked like this. Additions are marked like this.
Line 3: Line 3:
A '''projection''' is an approximation within a column space. A '''projection matrix''' describes the linear transformation of the approximation.

See also [[Calculus/Projection|vector projection]].
A '''projection''' is an approximation within a column space.
Line 16: Line 14:
Given vectors ''a'' and ''b'', ''b'' can be [[Calculus/Projection|projected]] into the column space of ''a'' (i.e., ''C(a)''). A '''projection matrix''' describes the linear transformation from vector ''a'' to projection vector ''p''. Such a projection matrix '''''P''''' satisfies ''p = '''P'''a''. Given two vectors ''a'' and ''b'', ''b'' can be [[Calculus/Projection|projected]] into ''C(a)'', the column space of ''a''.
Line 18: Line 16:
The column space of the projection matrix (i.e., ''C('''P''')'') is equivalent to ''C(b)''. It follows that '''''P''''' is also of [[LinearAlgebra/Rank|rank]] 1. Furthermore, the projection vector with the least [[LinearAlgebra/Distance|error]] as compared to the true vector ''b'' is characterized by orthogonality. Let ''e'' be the error vector; it is orthogonal to ''a''.

The [[LinearAlgebra/LinearMapping|transformation]] of vector ''b'' into projection vector ''p'' can be described by a '''projection matrix'''. It is notated '''''P''''' as in ''p = '''P'''b''.
Line 23: Line 23:

The projection matrix '''''P''''' satisfying ''p = '''P'''b'' is [[LinearAlgebra/Rank|rank]] 1.

''C('''P''')'', the column space of the projection matrix, is equivalent to ''C(b)''.
Line 32: Line 36:
Given vector ''b'' and matrix '''''A''''', ''b'' can be projected into the column space of '''''A''''' (i.e., ''C('''A''')''). For all the same reasons, a vector ''b'' can be projected into ''C('''A''')'', the column space of '''''A'''''. The [[LinearAlgebra/Distance|error]] vector ''e'' is orthogonal to ''R('''A''')'', the row space of '''''A''''', and is therefore in the [[LinearAlgebra/NullSpace|null space]].
Line 34: Line 38:
Given a linear system as '''''A'''x = b'', if ''b'' is in ''C('''A''')'', there are solutions for ''x''. If ''b'' is ''not'' in ''C('''A''')'' however, there is no possible solution. The best ''approximation'' is expressed as '''''A'''x̂ = p'' where projection ''p'' estimates ''b'' with an error term ''e''. [[Statistics/OrdinaryLeastSquares|This should sound familiar.]] The projection matrix is now notated '''''P''''' as in ''p = '''P'''b''.
Line 36: Line 40:
The error term can be characterized by ''e = b - p'' or ''e = b - '''A'''x̂''. ''e'' is orthogonal to ''R('''A''')'', the row space of '''''A'''''; equivalently it is orthogonal to ''C('''A'''^T^)''. Orthogonality in this context means that ''e'' is in the [[LinearAlgebra/NullSpace|null space]], so '''''A'''^T^(b - '''A'''x̂) = 0''.
Line 38: Line 41:
The system of '''normal equations''' is '''''A'''^T^'''A'''x̂ = '''A'''^T^b''. This simplifies to ''x̂ = ('''A'''^T^'''A''')^-1^'''A'''^T^b''. Altogether, the projection is characterized by ''p = '''A'''('''A'''^T^'''A''')^-1^'''A'''^T^b''.
Line 40: Line 42:
The projection matrix '''''P''''' satisfies ''p = '''P'''b''. It is calculated as '''''P''' = '''A'''('''A'''^T^'''A''')^-1^'''A'''^T^''. === Least Squares ===
Line 42: Line 44:
''b'' can also be projected onto ''e'', which geometrically means projecting into the null space of '''''A'''^T^''. Algebraically, if one projection matrix has been computed as '''''P''''', then the projection matrix for going the other way is ''('''I''' - '''P''')b''. Given a consistent system as '''''A'''x = b'', i.e. ''b'' is in ''C('''A''')'', there are solutions for ''x''.

If the system is inconsistent, then there is no solution. The best approximation is expressed as '''''A'''x̂ = p'' where projection ''p'' estimates ''b'' with an error term ''e''. [[Statistics/OrdinaryLeastSquares|This should sound familiar.]]

The error term can be generally characterized by ''e = b - p''. An expression for ''p'' is known, so ''e = b - '''A'''x̂''.

''e'' is orthogonal to ''R('''A''')'', so '''''A'''^T^e = 0''. Substituting in the above expression gives '''''A'''^T^(b - '''A'''x̂) = 0''

Altogether, '''''A'''^T^'''A'''x̂ = '''A'''^T^b'' which simplifies to ''x̂ = ('''A'''^T^'''A''')^-1^'''A'''^T^b''.

The projection matrix is calculated as '''''P''' = '''A'''('''A'''^T^'''A''')^-1^'''A'''^T^''.

The projection is calculated as ''p = '''A'''('''A'''^T^'''A''')^-1^'''A'''^T^b''.
Line 48: Line 62:
As above, the projection matrix '''''P''''' is symmetric and idempotent. Projection matrices are still symmetric and idempotent.
Line 50: Line 64:
If '''''A''''' is square, the above equations simplify rapidly.

If ''b'' is in ''C('''A''')'', then '''''P''' = '''I'''''. Conversely, if ''b'' is orthogonal to ''C('''A''')'', then '''''P'''b = 0'' and ''b = e''.
If ''b'' is in ''C('''A''')'', then '''''P''' = '''I'''''.. Conversely, if ''b'' is orthogonal to ''C('''A''')'', then '''''P'''b = 0'' and ''b = e''.

Projection

A projection is an approximation within a column space.


Vectors

Given two vectors a and b, b can be projected into C(a), the column space of a.

Furthermore, the projection vector with the least error as compared to the true vector b is characterized by orthogonality. Let e be the error vector; it is orthogonal to a.

The transformation of vector b into projection vector p can be described by a projection matrix. It is notated P as in p = Pb.

Properties

The projection matrix P satisfying p = Pb is rank 1.

C(P), the column space of the projection matrix, is equivalent to C(b).

Projection matrices are symmetric (i.e., PT = P) and idempotent (i.e., P2 = P).


Matrices

For all the same reasons, a vector b can be projected into C(A), the column space of A. The error vector e is orthogonal to R(A), the row space of A, and is therefore in the null space.

The projection matrix is now notated P as in p = Pb.

Least Squares

Given a consistent system as Ax = b, i.e. b is in C(A), there are solutions for x.

If the system is inconsistent, then there is no solution. The best approximation is expressed as Ax̂ = p where projection p estimates b with an error term e. This should sound familiar.

The error term can be generally characterized by e = b - p. An expression for p is known, so e = b - A.

e is orthogonal to R(A), so ATe = 0. Substituting in the above expression gives AT(b - Ax̂) = 0

Altogether, ATAx̂ = ATb which simplifies to x̂ = (ATA)-1ATb.

The projection matrix is calculated as P = A(ATA)-1AT.

The projection is calculated as p = A(ATA)-1ATb.

Properties

Projection matrices are still symmetric and idempotent.

If b is in C(A), then P = I.. Conversely, if b is orthogonal to C(A), then Pb = 0 and b = e.


CategoryRicottone

LinearAlgebra/Projection (last edited 2026-02-16 16:43:48 by DominicRicottone)