The vector a1=(1,1,0) and a2=(1,1,1) span plane in R^3. Find the projection matrix P onto the plane, and find nonzero vector b that is projected to zero.

To find the projection matrix P onto the plane spanned by vectors a1 and a2, we can use the formula:

P = A(A^T A)^-1 A^T

where A is the matrix formed by stacking vectors a1 and a2 as columns.

First, let's find A:

A = [a1, a2] = [1 1; 1 1; 0 1]

Next, let's calculate A^T * A:

A^T * A = [ 1 1 0 ; 1 1 1 ] * [ 1 1 ; 1 1 ; 0 1 ]
= [ 2 2 ; 2 3 ]

Next, let's calculate (A^T * A)^-1:

(A^T * A)^-1 = [ 2 2 ; 2 3 ]^-1
= [ -3/2 1 ; 1 -1/2 ]

Finally, let's calculate P:

P = A (A^T * A)^-1 A^T
= [1 1; 1 1; 0 1] * [ -3/2 1 ; 1 -1/2 ] * [ 1 1 0 ; 1 1 1 ]
= [ 1/2 1/2 0 ; 1/2 1/2 1 ; 1/2 -1/2 1 ]

To find a nonzero vector b that is projected to zero, we need to find a vector in the nullspace of P. The nullspace consists of all vectors that are mapped to zero by P.

To find a vector in the nullspace, we can solve the equation P * b = 0.

Using the matrix P we obtained above and setting it equal to a vector of zeros, we get:

[ 1/2 1/2 0 ; 1/2 1/2 1 ; 1/2 -1/2 1 ] * [b1; b2; b3] = [0; 0; 0]

Simplifying this equation, we have:

1/2 b1 + 1/2 b2 = 0
1/2 b1 + 1/2 b2 + 1/2 b3 = 0
1/2 b1 - 1/2 b2 + 1/2 b3 = 0

We can solve this system of equations to find the values of b1, b2, and b3.

To find the projection matrix P onto the plane spanned by the vectors a1=(1,1,0) and a2=(1,1,1) in R^3, we can follow these steps:

Step 1: Create a matrix A with the given vectors a1 and a2 as its columns.
A = [a1, a2] = [1 1; 1 1; 0 1].

Step 2: Calculate the projection matrix P using the formula P = A(A^T A)^(-1)A^T.
In our case, we have A^T = [1 1 0; 1 1 1], and A^T A = [2 2 1; 2 2 1; 1 1 1].
Inverting the (A^T A) matrix, we get (A^T A)^(-1) = [1/3 -1/3 0; -1/3 2/3 -1/3; 0 -1/3 2/3].
Multiplying this by A^T gives us (A^T A)^(-1)A^T = [1/3 -1/3 0; 1/3 -1/3 -1/3; 0 -1/3 1/3].
Finally, multiplying this by A will give us the projection matrix P:
P = A(A^T A)^(-1)A^T = [1 1; 1 1; 0 1] * [1/3 -1/3 0; 1/3 -1/3 -1/3; 0 -1/3 1/3]
= [2/3 -1/3 -1/3; 2/3 -1/3 -1/3; -1/3 -1/3 2/3].

Step 3: To find a nonzero vector b that is projected to zero, we need to find a vector that lies outside the plane spanned by a1 and a2. As the plane is spanned by a1=(1,1,0) and a2=(1,1,1), and the vectors are linearly independent, we can choose a vector perpendicular to the plane. Let's choose b = (0,0,1).

Step 4: Now, we can calculate the projection of b onto the plane using the projection matrix P:
P * b = [2/3 -1/3 -1/3; 2/3 -1/3 -1/3; -1/3 -1/3 2/3] * [0; 0; 1]
= [(-1/3); (-1/3); (2/3)].

So, the projection matrix P onto the plane spanned by a1=(1,1,0) and a2=(1,1,1) is [2/3 -1/3 -1/3; 2/3 -1/3 -1/3; -1/3 -1/3 2/3]. And the vector b = (0,0,1) is projected to zero by P.