40. Images

40. Images

Definition:

The image of a linear map f from R^n to R^m is the set of vectors b in R^m such that b = f of v for some v in R^n. It is written as im.

If you think of applying a map as "following light rays" (like in some earlier examples), you can think of the image as the shadow your map casts.

If the map f is the vertical projection f of x, y, z = x, y, 0 then the image of f is the x y-plane. That is im f = the set of vectors of the form x, y, 0

Consider the 3-by-2 matrix A = 1, 1; 2, 0; 0, 1. The image of the corresponding linear map is the set of all vectors of the form A times x, y = x + y; 2 x; y We studied this example earlier and even drew a picture of its image: it is the grey plane in the figure below. (There's a slight "videographic typo" (i.e. "mistake") in the video, see if you can spot it).

The plane of vectors of the form (x+y,2x,y) in 3D

Remarks

  • 0 is in im f because 0 = f of 0.

  • If f is invertible then im f = R^m. This is because if b in R^m then b = f of f inverse of b, so b is in im f.

Image is a subspace

Lemma:

The image of f is a subspace.

If b_1 and b_2 are in im f then so is b_1 + b_2. To see this, observe that if b_1 and b_2 are in im f then b_1 = f of v_1 and b_2 = f of v_2 for some v_1, v_2 in R^n. This means that b_1 + b_2 = f of v_1 + f of v_2, which equals f of v_1 + v_2 (since f is linear), so b_1 + b_2 is in im f.

Similarly, lambda b_1 = lambda f of v_1 = f of lambda v_1 (since f is linear), so lambda b_1 is in im f.

Relation with simultaneous equations

Lemma:

A v = b has a solution if and only if b is in i f where f of v = A v.

This is a tautology from the definition of image! A v = b has a solution if and only if there is a v such that f of v = A v = b.

So putting this together with the last lecture, we see that A v = b has a solution if and only if b is in im f and, if it has a solution, then the space of solutions is a translate of ker f.

Rank

Definition:

The rank of a linear map/matrix is the dimension of its image.

Theorem:

(Rank-nullity theorem) If A is an m-by-n matrix (or f from R^n to R^m is a linear map) then rank of A + nullity of A = n Here n is the number of columns or A (or the dimension of the target of f).

The 3-by-3 matrix A = 0, 0, 0; 0, 0, 0; 0, 0, 0 sends everything to zero, so its image is a single point, which has dimension zero, so rank A = 0. The kernel is the set of things which map to zero, and since everything maps to zero the kernel is R^3. Therefore the nullity (dimension of the kernel) is three. Note that 0 + 3 = 3 and n = 3 (A is a 3-by-3 matrix) so the rank-nullity theorem holds.

The 3-by-3 matrix B = 1, 0, 0; 0, 0, 0; 0, 0, 0 sends x, y, z to x, 0, 0, so its image is the x-axis. Therefore the rank (dimension of the image) is 1. The nullity is the number of free variables (B is in reduced echelon form already) which is 2 (there is one leading entry). Again, 1 + 2 = 3, which is good. We can see that as the rank increases, the nullity goes down (as required by the rank-nullity theorem).

The matrix C = 1, 0, 0; 0, 1, 0; 0, 0, 0 is the vertical projection to the x y-plane, so its rank is 2 (image is the x y-plane). Its nullity is 1 (one free variable). Again, 2 + 1 = 3.

The 3-by-3 identity matrix I = 1, 0, 0; 0, 1, 0; 0, 0, 0 has rank 3 (for any v we have v = I v so every vector is in the image) and the nullity is 0 (only the origin maps to the origin). Again, 3 + 0 = 3.

The rank-nullity theorem is basically saying that the map f is taking R^n, crushing down some of the dimensions (those in the kernel), and mapping the rest faithfully onto the image (so the n dimensions of R^n either contribute to the kernel or to the image).

Proof of rank-nullity theorem

The nullity of A is the number of free variables of A when you put it into reduced echelon form. If we can show that the rank is the number of dependent variables then we're done: there are n variables which are either free (contributing to kernel) or dependent (contributing to rank). Recall that the dependent variables correspond to the columns with leading entries in reduced echelon form.

So we need to show that the rank is the number of leading entries of A in reduced echelon form.

First step: we prove that the rank doesn't change when we do a row operation. Suppose we start with a matrix A, do a row operation to get a matrix A prime. We know there is an elementary matrix E such that A prime = E A. This tells us immediately that im A and im A prime have the same dimension: b maps to E b gives us an "isomorphism" (invertible linear map) from the image of A to the image of A prime.

As the rank doesn't change under row operations, we may assume without loss of generality that A is in reduced echelon form.

Second step: if A is in reduced echelon form then it has k nonzero rows (for some k) followed by m minus k zero rows. Now:

  • The number k is the number of leading entries (because each nonzero row has a leading entry and each zero row doesn't).

  • Recall that A v = b has a solution if and only if b_{k + 1} = b_{k + 2} = dot dot dot = b_m = 0: these are the necessary and sufficient conditions for solving the simultaneous equations. If A has a zero row then b has to have a zero in that row, and if all these higher bs are zero then the other rows of A just give us equations which determine the dependent variables.

Since the image of A is the set of b for which A v = b has a solution, this means that im A is the set of b for which b_{k + 1} = dot dot dot = b_m = 0, i.e. those b of the form b_1, b_2, down to b_k, then 0, 0, until the mth row. This is a k-dimensional space, so we see that the rank equals k, the number of leading entries.

This completes the proof of the rank-nullity theorem.