In three-dimensional space, we add a z-axis
perpendicular (orthogonal) to the usual x- and y-axis
to create a rectangular coordinate system called xyz-space.
The z-axis is oriented relative to the xy-plane
in accordance to the right-hand rule.
Any pair of axes span a coordinate plane,
and these coordinate planes split xyz-space into eight octants.
Each point can be described by a ordered triple (x,y,z).
All computations from two-dimensional space
regarding either points or vectors
generalize to three-dimensional space in the most natural way.
Given two points (x1,y1,z1) and (x2,y2,z2),
the distance between them is (x2−x1)2+(y2−y1)2+(z2−z1)2,
and their midpoint has coordinates (x,y,z)
given by the formulas
x=21(x1+x2)
and y=21(y1+y2)
and z=21(z1+z2).
In three-dimensional space,
two points uniquely determine a line
and three non-colinear points uniquely determine a plane.
A sphere of radius r centered at (h,k,ℓ)
has equation r2=(x2−h)2+(y2−k)2+(z2−ℓ)2.
If a sphere intersects a plane in space,
the resulting shape of their intersection, generically a circle,
is called the trace of the sphere in the plane.
Vectors in xyz-space have three components.
The magnitude of v=⟨v1,v2,v3⟩ is calculated as
∣v∣=v12+v22+v32.
In addition to the unit coordinate vectors
i=⟨1,0,0⟩
and j=⟨0,1,0⟩,
we now have k=⟨0,0,1⟩.
For vectors u=⟨u1,u2,u3⟩
and v=⟨v1,v2,v3⟩
their dot product is calculated as
u⋅v=u1v1+u2v2+u3v3=∣u∣∣v∣cos(θ).
The direction angles of a vector v
are the three angles between v and each of the three coordinate axes.
The cosines of these angles are referred to as the vector’s direction cosines.
If α and β and γ are the direction angles of v
with the x- and y- and z-axis respectively, then
cos(α)=∣v∣v1cos(β)=∣v∣v2cos(γ)=∣v∣v2v=⟨∣v∣cos(α),∣v∣cos(β),∣v∣cos(γ)⟩.