Blok uses only the cookies needed to run the site and remember your preferences. See our Privacy Policy.
Everything in this course is built from one operation: the dot product. It measures length, it decides when two vectors are at right angles, and it is the only tool you need to do geometry in dimensions you cannot picture.
In and you can see what "length" and "right angle" mean. In you cannot.
So we do the reverse. We take one algebraic operation, check that it gives the right answers in the two dimensions we can see, and then DEFINE length and angle by it everywhere else.
For ,
Multiply matching entries, add them up. The result is a single number, not a vector.
Two notations, one object. Bretscher writes ; the lectures write .
They mean exactly the same thing for real vectors. This guide uses , because that is the notation the exam is written in — but do not be thrown when the textbook uses a dot.
Compute for and .
Pair off the entries and multiply:
That is:
One number out. A negative one, which will turn out to mean the two vectors point somewhat away from each other.
Let .
Why is the right definition of length?
Because in it IS Pythagoras. With :
That is the hypotenuse of the right triangle with legs and . The definition in is the same formula with more terms.
The square root is a nuisance in almost every proof, so almost nobody works with directly. They work with and take the root at the very end.
See a norm in a proof? Square it immediately. turns geometry into algebra you can expand.
Find the length of .
And , so:
For any and any scalar ,
.
Square the left-hand side:
Pull both scalars out:
Take the square root:
That theorem is what makes NORMALISING possible. If , then
is a unit vector pointing the same way as .
Check:
You will normalise a vector on almost every page of this course — Gram-Schmidt, QR, the spectral theorem and the SVD all end with it.
Normalise = divide by your own length. Direction survives, size becomes 1.
Dividing a vector by its length means dividing EVERY entry by that one number. It does not mean dividing entry by entry .
For we have , so
Keep the out front rather than writing thirds inside — it is less to write and much less to get wrong later.
Orthogonality extends from vectors to whole subspaces.
A vector is orthogonal to a subspace if it is orthogonal to EVERY vector in : for all .
Let be a basis of a subspace of . Then is orthogonal to if and only if is orthogonal to each of .
This is the theorem that makes the definition usable. "Orthogonal to every one of infinitely many vectors" is not something you can check. "Orthogonal to these three" is.
The seminar sheet flags this exercise as one worth remembering. It is used silently in nearly every later computation.
if and only if for every basis vector of .
() Suppose . Each is itself a vector in , so
() Suppose for all . Take any and write it in the basis:
Then every term dies:
Since was an arbitrary vector of , is orthogonal to all of .
For which value of the constant are and perpendicular?
Perpendicular means the inner product is zero, so set it to zero and solve:
Setting this equal to :
.
Check: . ✓
Orthogonal to everything: yes. for every , including itself.
A unit vector: no. .
This is why the normalising formula carries the condition — you cannot divide by a length of zero.
A set of vectors that are all unit length and all at right angles to one another. Two conditions, and they buy you linear independence for free — no row reduction, no determinant.
Take a set and ask two things of it.
1. Every vector has length 1: for . They are all NORMALISED. 2. Every pair is orthogonal: whenever .
The vectors in are ORTHONORMAL if
That one formula packs both conditions in.
Setting gives , which is condition 1. Setting gives condition 2.
Show that the standard basis of is orthonormal.
Show that for any angle , the vectors and are orthonormal.
(a) Orthonormal vectors are linearly independent.
(b) Orthonormal vectors in form a basis of .
Part (a) is the payoff. Linear independence is normally something you WORK OUT — row reduce, look for a pivot in every column.
For an orthonormal set you get it for free, from the definition alone.
Orthonormal vectors are linearly independent.
Suppose a combination vanishes:
The move in step 2 — take the inner product of an equation with one particular — is the single most reused trick in this course. It appears again in the projection formula, in Gram-Schmidt and in the spectral theorem.
Want to isolate the -th coefficient? Dot the whole equation with . Orthonormality deletes every other term.
Part (b) follows from part (a) with no extra work.
orthonormal vectors in are linearly independent by (a), and any linearly independent vectors in form a basis. So they are a basis — an ORTHONORMAL BASIS.
The converse of (a) is false. Linearly independent vectors need not be orthonormal — they need not even be orthogonal.
and are linearly independent, but .
The vectors , and in are orthonormal. Can you find a vector making all four orthonormal? If so, how many are there?
No. They would be five linearly independent vectors in a 4-dimensional space, and no such set exists.
So an orthonormal set in has at most members — and when it has exactly , it is a basis.
Split any vector into the part that lies inside a subspace and the part that sticks out at right angles. The split always exists, and there is only one of them — which is what makes the whole of Chapter 5 possible.
The goal. Given a linear subspace and a vector , find a decomposition
where , and for every .
The lecture labels the picture: is DATA, is the space of MODELS.
That is not decoration. is the best your models can do; is what they miss. Lecture 4 turns exactly this picture into the method of least squares.
Start in a case you can see. is a line in , and is an arrow that does not lie along it.
Drop a perpendicular from the tip of onto . The foot of that perpendicular is ; the dropped segment is . Everything below is that picture, in dimensions, done with algebra instead of a ruler.
The solid arrow along the line is ; the dashed one is . The small square marks the right angle, and it never opens up however far you drag — that is the whole content of the decomposition theorem. Watch the second readout too: the projection is never longer than , with equality only when lies along the line.
The line is fixed; drag around it.
The solid arrow along is , the dashed one is , and the small square is the right angle between them. It never opens up, however far you drag — that is the existence half of the theorem, holding for every at once.
Let be a subspace of and . Then can be written as
Two separate claims are hiding in there, and a proof has to earn both.
EXISTENCE — such a split can be found. UNIQUENESS — there is no second one.
Existence is a construction; uniqueness is a short argument that needs no construction at all.
Existence: with an orthonormal basis of in hand, the split can be written down.
Let be an orthonormal basis of , and suppose the split exists. Since lies in , it is a combination of the basis:
Uniqueness: there is only one such split.
Suppose the vector splits two ways:
The uniqueness argument is three lines and reappears constantly: if a vector lies in and in at once, it is zero.
, because the only vector perpendicular to itself is the zero vector.
Notice what the existence proof needed and what it did not.
It needed an ORTHONORMAL basis of — orthonormality is what collapsed the sum in step 4. Any old basis would have left simultaneous equations to solve.
It did not need to be anything special. Any subspace of any , of any dimension.
is not "the part of outside " in a loose sense — it is orthogonal to ALL of , not merely different from .
Splitting with can be done in infinitely many ways: pick any and set .
If : take and . That is a valid split, and by uniqueness it is THE split. So .
One formula computes the projection, and the same formula hands you coordinates. In a general basis, finding coordinates means solving a linear system. In an orthonormal one, it means taking inner products — and that is the entire reason this course cares about orthonormal bases.
If is a subspace of with ORTHONORMAL basis , then
for every .
Read it as an instruction, not a formula.
For each basis direction : measure how much of points along it — that is the number — then lay off that much in the direction . Add up the results.
Each term is itself the projection of onto the LINE spanned by . So projecting onto a subspace is nothing more than projecting onto each of its basis lines and adding.
In : projecting onto the -plane is the same as projecting onto the -axis, projecting onto the -axis, and adding the two results.
The formula is only valid for an ORTHONORMAL basis. Feed it a merely-orthogonal basis, or an arbitrary one, and it returns the wrong vector.
If your basis is orthogonal but not normalised, either divide each vector by its length first, or use the version that carries the correction factor:
Let in , where has columns and . Find for .
Always verify a projection by checking against the basis vectors. Two inner products that come out zero is near-proof you are right; one that does not is instant proof you are wrong.
Projection done? Subtract it from and dot the leftover with every basis vector. All zeros or start again.
Now push the formula to its limit. Take to be the whole of .
Projecting a vector onto the entire space cannot change it, so . Put that into the formula and you get an identity that holds for every .
Let be an orthonormal basis of . Then
In coordinate language: the coordinate vector of with respect to the orthonormal basis is
This is the practical point of the whole lecture.
Given ANY basis , writing means solving an linear system for the . That is real work, and it grows fast with .
The lecture derives the same fact directly. Write and take the inner product with :
Same trick as the independence proof in Topic 2, used for a different purpose. Dot the expansion with ; orthonormality deletes everything else; the -th coefficient falls out.
Orthonormal basis coordinates are just inner products.
Write in the orthonormal basis , of .
Because and . The projection formula sums over a basis of the SUBSPACE; the expansion formula sums over a basis of the whole space.
Every subspace has a partner: the set of all vectors perpendicular to it. Their dimensions add up to n, they meet only at the origin, and each is the other's partner — which lets you compute a hard projection by doing an easy one instead.
Consider the projection and ask what its kernel is.
means , so . The kernel is exactly the set of vectors perpendicular to . That set deserves a name.
Let be a subspace of . The ORTHOGONAL COMPLEMENT of is
Say it out loud: " perp is the set of in such that is orthogonal to , for every in ."
Picture it in . If is a plane through the origin, is the line through the origin normal to it. If is a line, is the plane through the origin perpendicular to it.
Find for the line in .
Let be a subspace of . Then:
(a) is a subspace of . (b) . (c) . (d) .
Parts (a), (b) and (c).
(a) is the kernel of the linear map , and the kernel of a linear transformation is always a subspace.
(b) Suppose is in and also in . Being in means is orthogonal to every vector of — and is itself one of those vectors.
Part (d): .
First show . Take . Every satisfies , so is orthogonal to everything in — which is what belonging to means.
Part (c) is the workhorse. It turns "find " into a problem where you already know the answer's SIZE before you start — and a dimension that comes out wrong tells you instantly that you have made a mistake.
. Plane in ? Complement is a line. Line in ? Complement is 3-dimensional.
Let . Find and verify the correctness of your solution.
The complement also gives a shortcut for projections.
Since , you can compute EITHER piece and subtract:
Let and . Find the orthogonal projection of onto , and verify your answer.
: every vector is orthogonal to the zero vector, so nothing is excluded.
Pythagoras' theorem, stated in n dimensions and proved in two lines. It immediately gives the fact that a shadow is never longer than the object casting it — and that innocent-looking inequality is what the Cauchy-Schwarz inequality is built on.
In , Pythagoras is about right triangles. In we have no triangles to draw — but we do have the definitions of length and orthogonality, and that turns out to be enough.
Let . Then
holds IF AND ONLY IF and are orthogonal.
exactly when .
The expansion in step 2 is worth memorising on its own:
Consider a line in and a vector . What is the relationship between and ?
Let be a subspace of and . Then
The proof is the example above with replaced by — nothing about the argument used the dimension.
A shadow is never longer than the object casting it, and it is exactly as long only when the object is lying flat on the ground.
Projecting can only shorten. , equality iff was already in .
Give an algebraic proof of the parallelogram identity
, so they are orthogonal and the theorem should apply.
One inequality bounds the inner product by the product of the lengths. It is what lets us define an angle in dimensions we cannot picture, it gives the triangle inequality for free, and it turns up in exam questions that look nothing like linear algebra.
For all ,
with equality if and only if and are parallel.
Absolute value bars on the left, because the inner product can be negative while the right-hand side never is.
The content: the inner product cannot be large unless BOTH vectors are long. Two short vectors can never have a big inner product, however well aligned they are.
The proof is a surprise. It uses nothing but the projection inequality from Topic 6 — no clever algebra, no discriminant trick.
The idea is to project onto the line spanned by , and then read off what "the shadow is shorter than the object" says.
, assuming .
Set , a unit vector, and let — the line through .
Two remarks the lecture flags explicitly.
The proof assumed . If , both sides of the inequality are , so it holds trivially — the theorem is still true, the proof just needs the separate line.
Equality holds when is parallel to , because then and step 2's inequality becomes an equality.
Writing "take " without saying is the standard way to lose a mark on a proof question.
Open with: "If both sides are zero and the inequality holds. So assume ."
For all ,
The seminar sheet singles this exercise out as one to remember. The picture is the reason for the name: going straight from to is never longer than detouring via .
.
Square the left side and expand:
Now the payoff Cauchy-Schwarz was really for.
In you may already know that , where is the angle between the vectors. Rearranged:
For nonzero , the angle between them is
This definition needs Cauchy-Schwarz to be legal at all.
only accepts inputs between and . Dividing Cauchy-Schwarz through by gives exactly
The sign of already tells you the shape of the angle without computing an arccos at all.
: acute. : right angle. : obtuse. Cosine is positive below and negative above.
Find the angle between and in .
Three quantities, then one arccos.
Let with . Use the Cauchy-Schwarz inequality to prove that
Two inequalities were used, so both must be tight.
Step 3 (Cauchy-Schwarz) is tight when and are parallel. Step 2 () is tight when .
Leave it as a surd. Decimals lose exactness and gain nothing in an exam.
The word itself is the two conditions glued together: ORTHO-gonal plus NORMAL-ised.
is the vector with a in slot and zeros everywhere else.
For : every term of the sum is except slot , which is . So .
For with : in every slot, at least one of the two factors is . So every term is , and
Orthonormal. The standard basis is the model every other orthonormal basis is built to imitate: a set of perpendicular directions, each one unit long.
Lengths first:
So both are unit vectors.
Now the inner product:
Orthonormal for every .
Geometrically this is the standard basis rotated by — turning a pair of perpendicular unit arrows does not change either their length or the right angle between them. That observation becomes a theorem in Lecture 3.
with each and the zero vector of .
Fix one index and take the inner product of BOTH sides with :
Expand the left side:
Every with is , and is . The whole sum collapses, and the right side is :
The index was arbitrary, so every coefficient is zero, and the vectors are linearly independent.
Orthonormal is a much stronger condition than independent. Turning an independent set into an orthonormal one is exactly the job of the Gram-Schmidt process in Lecture 2.
Three orthonormal vectors in . By part (a) they span a 3-dimensional subspace , so there is exactly one dimension left over.
So I am looking for a unit vector in the orthogonal complement of , and that complement is a LINE (dimension ). A line through the origin contains exactly two unit vectors, pointing opposite ways.
That already answers "how many" before I compute anything: two.
To find them, I need with for . The factors do not affect whether an inner product is zero, so I can drop them and solve with the raw sign patterns.
Write and set each inner product to zero:
Add the first two: , so . Subtract the second from the first: , so .
Put those into the third equation:
So : the solution space is a line, as predicted.
Normalise. , so
Marks: setting up the three orthogonality equations, solving them to a one-dimensional solution space, normalising, and stating BOTH signs.
The is the half people lose. "How many such vectors are there" is asking for it explicitly.
A dimension count (, and a line holds two unit vectors) earns the counting mark even if the arithmetic goes wrong.
Watch the length readout too: , with equality exactly when lands on the line. That is Topic 6's theorem, three topics early.
with and perpendicular to , and this representation is UNIQUE.
The vector is called the ORTHOGONAL PROJECTION of onto , written . The map from to is linear.
for coefficients we have yet to find.
Then must be orthogonal to , and by the basis test that means
Expand that condition:
Orthonormality kills every term except the -th, where :
So define
The first lies in , and by construction for every , so the second is orthogonal to .
with and .
Rearrange to put the -parts on one side:
The left side lies in and the right side lies in . They are the same vector, call it — so is in BOTH.
Being in means is orthogonal to everything in , and itself is in . So
Hence and : the two splits were the same split.
Exactly one of those splits has . That is the content of the uniqueness half, and it is why the theorem is worth stating at all.
If : take and . So .
These two cases say the projection map fixes and annihilates — a fact used again in Lecture 7 to read off its eigenvalues, which turn out to be just and .
If the basis is not even orthogonal, the formula does not apply at all — run Gram-Schmidt first (Lecture 2), or use the matrix formula from Lecture 4.
First check the two columns are orthogonal:
They are independent, so they are a basis of . Each has length , so normalise:
Now the two coefficients:
Assemble:
.
Check it. , and
The remainder is perpendicular to both basis vectors, so it is perpendicular to . That check costs ten seconds and catches almost every arithmetic slip.
for every .
Given an ORTHONORMAL basis, . One inner product each. No system, no elimination.
Every term dies except the -th, where the inner product is :
Two inner products, and nothing else:
So
Check by reassembling:
.
Compare the effort with solving — doable in , unpleasant in .
Equivalently, is the kernel of the orthogonal projection onto .
is spanned by the single vector , so by the basis test a vector lies in exactly when it is orthogonal to that one vector:
Written out:
That is one linear equation in three unknowns — a plane through the origin. In matrix language,
is the plane .
Note the pattern: the SPAN of a vector and the KERNEL of that same vector written as a row. It is the shape of Theorem 5.4.1 in Lecture 4, , in its smallest case.
So the vector is orthogonal to itself:
(c) Apply the rank-nullity theorem to :
The image of is and the kernel of is :
Now count dimensions. By (c) applied to :
By (c) applied to , . Substituting:
A subspace contained in another of the SAME dimension must equal it. So .
Two steps, in the obvious order: find , then find the complement of what I find.
Before any arithmetic, predict the sizes. has rank (the rows are clearly not multiples of each other), so by rank-nullity . Then part (c) gives as well.
So I am looking for two independent vectors at the end. If I get one or three, something has gone wrong.
For the second step I use the basis test: a vector is in exactly when it is orthogonal to each of the two basis vectors of — two equations, not infinitely many.
The question says "verify", so the verification is worth marks. I will check dimensions add to , and check every basis vector of one space against every basis vector of the other.
STEP 1 — find . Row-reduce: subtracting row 1 from row 2 gives
From the second row, . Substituting into the first row:
So , with and free. Taking and :
STEP 2 — find the complement. A vector is in iff it is orthogonal to both:
The second gives ; the first gives , with free. Taking and :
STEP 3 — verify. Dimensions: . ✓
All four pairings:
Marks: correctly computing , setting up the orthogonality conditions against a BASIS of it rather than against all of it, solving, and verifying.
Any basis of the same plane scores full marks — the span is what is being asked for, not one particular pair of vectors.
Worth noticing for later: this answer is the span of the two ROWS of . Check it — . That is Theorem 5.4.1 of Lecture 4, , and once you have met it this whole question collapses to "write down the row space".
When is big and is small — a plane in , say, whose complement is a single line — projecting onto the complement is far less work.
is the plane in — a 2-dimensional space. Finding an orthonormal basis for it would mean two vectors and a Gram-Schmidt step.
But is only 1-dimensional, and I can write it down instantly: the plane's normal direction is the coefficient vector .
So project onto the LINE instead and subtract. One inner product rather than a Gram-Schmidt.
I will simplify to first — a line does not care about scaling, and the smaller numbers make the arithmetic clean.
is spanned by , with
Project onto that line. Using the un-normalised form of the formula:
Compute the numerator:
So
Subtract:
Verification, both halves of which earn marks:
Marks: identifying as the span of the coefficient vector, projecting onto it correctly, subtracting, and verifying both conditions.
The method mark is for choosing to project onto the complement. Doing it the long way — Gram-Schmidt on a basis of the plane — is not wrong and scores the same, but it takes three times as long under time pressure.
: a vector orthogonal to everything is orthogonal to itself, so it is zero.
Both obey part (c): and . And they are each other's complements, as part (d) requires.
Start from the squared norm:
Expand:
The two middle terms are equal, so this is
That equals exactly when the middle term vanishes:
It is for vectors. It will be the first line of half a dozen later proofs, including the triangle inequality and the parallelogram identity.
Split into its two pieces: , and those two pieces are orthogonal.
So Pythagoras applies:
Since , dropping it can only decrease the right side:
, with equality exactly when lies on .
Equality forces , so and .
with equality if and only if .
and interpret the result geometrically using a sketch.
"Algebraic proof" means: do not draw anything, expand.
There are two squared norms on the left. I know how to expand each — square the norm into an inner product and distribute. The only difference between them is the sign on .
I expect the cross terms to cancel, because that is the only way an identity like this could hold for ALL and : the right side has no in it at all.
For the geometric half, I need to know what the four objects are. Draw the parallelogram with sides and from a common corner. Then is one diagonal and is the other. So the identity is a statement about diagonals versus sides.
Expand the first term:
Expand the second, which differs only in the sign of :
Add them. The cross terms and cancel:
GEOMETRIC READING. Draw the parallelogram whose sides from one corner are and . Its two diagonals are the vectors (the long way across) and (from the tip of to the tip of ).
The parallelogram has four sides: two of length and two of length . So the right-hand side is the sum of the squares of all four sides, and the left-hand side is the sum of the squares of the two diagonals.
In a parallelogram, the sum of the squares of the two diagonals equals the sum of the squares of the four sides.
Marks: expanding both norms via the inner product, observing that the cross terms cancel, and identifying the diagonals as and in a labelled sketch.
The sketch is not decoration here — the question asks for it, and the geometric statement is unmarkable without labelling which vector is which diagonal.
Sanity check with a rectangle: , . Both diagonals have length , so the left side is , and the right side is . ✓
and , summing to .
, so . ✓
Now break orthogonality: take instead. Then , and , while . The gap is exactly — the cross term the proof identified.
Apply the projection inequality:
Pull the scalar out of the norm:
The last step is .
Substitute back:
So . Multiply both sides by :
One sentence, and the proof is complete rather than nearly complete. The lecturer wrote this remark in the margin in a different colour, which is a fair signal about how often it is forgotten.
Bound the middle term above by its absolute value:
Apply Cauchy-Schwarz:
Chain the two bounds:
Take square roots of both sides:
In there is no angle to measure. So we turn the formula round and use it as the DEFINITION.
By the range of , this lies between and .
so the input is always in range. Without the inequality, the definition would be meaningless.
So
, that is .
A clean answer in , where there is nothing to draw. That is the point of the definition.
When does equality occur?
Nothing here mentions vectors, so the first job is to MAKE two vectors whose inner product and norms produce the three quantities in the question.
What do I have? A sum of the , and a sum of the . The second is for — that is the quantity I want to bound below.
The first is , which is with . That fixes both vectors.
Now check the direction. Cauchy-Schwarz bounds from ABOVE by . I want a LOWER bound on — but the inner product here is a fixed number, , so the upper bound on the left is really a lower bound on the right. It works out.
For the equality case: Cauchy-Schwarz is an equality exactly when the two vectors are parallel. parallel to means all the are equal, and the constraint then pins their common value.
Set
Then:
Cauchy-Schwarz gives
Divide by :
Both sides are non-negative, so squaring preserves the direction:
EQUALITY. Cauchy-Schwarz is an equality exactly when and are parallel, i.e. for some scalar — every equal to .
The constraint then forces , so :
Check: . ✓
Marks: choosing , identifying all three of , and , applying the inequality, and handling the equality case.
The choice of is the whole question. Everything after it is substitution.
The equality case needs BOTH halves: parallel to makes the entries equal, and only then does the constraint pin the common value to . Stating "all equal" without using the constraint is half the mark.
Together: and point in the SAME direction, not merely along the same line. Anti-parallel vectors satisfy Cauchy-Schwarz with equality but fail step 2 — which matches the picture, since walking out and back is strictly longer than not moving.