# Vector Functions

We will use the cross product and dot product of vectors to explore equations of
lines and planes in 3 dimensional space. Vector functions have an input **t**
and an output of a vector function of t.

## Position Vectors

A position vector is a vector whose initial point is fixed at the origin so that
each point corresponds to **P = <x,y>**. Since a position vector cannot
be translated, it is technically not a vector, so it instead should be considered
as a means of using arithmetic of vectors with point in the plane. In this case,
any two given points on a line will have it's own position vector.

## Finding an Equation of a line

We can define **L(t)** to be a vector valued function which maps the input of
**t** to the output vectors **L(t)**. In two dimensions, the equation would
look similar to the equation of a line in slope intercept form.

We use t because it is the parameter, or index of each point on the line. We use
**t** because a point is often labeled by the time at which an object is located
at that point. In this case, **b** is a fixed point (position vector) on the
line and v is the vector between two points on the line, or the constant slope vector
for the line.

The physical interpretation of this equation is that if an object moves along the
line at a constant speed equal to the magnitude of **v**, then t would be the
time at which the object is located at point **L**(t) on the line.

Lets find the equation of the line through the points **P1(2,4)** and **P2(5,1)**.
Vector **v** is given by

Now we have our slope, so we can pick any of the points on the line to be the position vector. Our equation will be

Notice that the x coordinates are given by **x = 3t+2** and the y coordinates
are **y = -3t+4**. We can then solve for t which yields

Plugging in for y, we get the slope intercept form of the line

The reason why the vector equation of a line is used is because it generalizes to more than 2 dimensions, which the slope intercept form cannot. We can do the same thing for 3 dimensional lines.

For example, let's find the equation of the line that passes through the points
**P1(2,4,1)** and **P2(5,1,2)** where P1 is at **t = 0** and P2 is at **t
= 1**.

The vector **u** is given by

The equation will then be

Plugging **t = 0** and **t = 1** we get our original points.

Plugging in other values of t will yield other position vectors on the line

## Finding an Equation of a Plane

Given any plane, there must be a normal vector **n** perpendicular to every vector
**v** parallel to the plane. Generally, the plane through the point **P1(x1,y1,z1)**
with normal vector **n = <a,b,c>** is the set of points **P<x,y,z>** such
that the vectors **v = P1P2 = <x-x1,y-y1,z-z1>** are perpendicular to **n**.
If we recall the dot product, **n*v = 0**, which is equivalent to

The equation of a plane with normal **n = <a,b,c>** through the point **(x1,y1,z1)**
is defined as

Lets find the equation of the plane with normal **<5,4,3>** going through the
point **<0,1,2>** on the plane.

Isolating z, we can put the equation into functional form.

To find the equation of the plane through three non colinear points, we have to
form two vectors connecting one of the points to the other two. Let **u = P1P2**
and **v = P1P3**. These vectors are both parallel to the plane, so the cross
product will yield a normal vector, that is, a vector that is perpendicular to both
**u** and **v**, and therefore perpendicular to the plane.

Find the equation of the plane passing through the points **P1(1,1,2)**, **P2(2,1,3)**,
and **P3(3,1,-1)**

First, we find vectors **u** and **v**.

Then, we use the formula for the cross product to find the normal vector.

The equation for the plane is then given by

Using the points in a different order may yield a different vector, however the functional form will always be the same.

We can also find the equation of a plane given a line and a point not on the line. All we need to do is plug in different values of t to get three different points, and then solve using the previous method.