3D Geometry Essentials

3D geometry extends the principles of two-dimensional geometry into a three-dimensional space, enabling us to describe and analyze objects with depth, width, and height. Using coordinates \((x, y, z)\), we can pinpoint locations in space, calculate distances, determine midpoints, and define geometric shapes like planes and spheres. This field is critical in computer graphics for rendering 3D models, in physics for analyzing motion in three dimensions, and in architecture for designing complex structures. This guide explores 3D geometry through detailed examples, formulas, and real-world applications, making it accessible and practical.

Coordinates

In 3D space, a point is represented by the ordered triple \((x, y, z)\), where:

  • \(x\): The horizontal axis (left-right movement).
  • \(y\): The vertical axis (forward-back movement).
  • \(z\): The depth axis (up-down movement).
The coordinate system is typically a right-handed system, where the positive \(x\)-axis points right, the positive \(y\)-axis points forward, and the positive \(z\)-axis points upward, following the rule that \(x \times y = z\). This system allows us to locate points relative to the origin \((0, 0, 0)\), which serves as the reference point. Points can be plotted using a three-dimensional grid, where each axis is perpendicular to the others, creating a cubic framework for spatial analysis.

Examples: Distance, Midpoint, Vector, Angle Between Vectors, Plane Equation, Sphere Center

Let’s explore key 3D geometry concepts with detailed calculations.

Example 1: Distance

Find the distance between points \((1, 2, 3)\) and \((4, 6, 8)\). The distance formula is:

\[ d = \sqrt{(x_2 - x_1)^2 + (y_2 - y_1)^2 + (z_2 - z_1)^2} \] \[ x_1 = 1, \, y_1 = 2, \, z_1 = 3 \] \[ x_2 = 4, \, y_2 = 6, \, z_2 = 8 \] \[ d = \sqrt{(4 - 1)^2 + (6 - 2)^2 + (8 - 3)^2} \] \[ = \sqrt{3^2 + 4^2 + 5^2} \] \[ = \sqrt{9 + 16 + 25} \] \[ = \sqrt{50} \] \[ \approx 7.071 \]

This distance represents the straight-line path between the two points in 3D space, useful for measuring spatial separations.

Example 2: Midpoint

Find the midpoint between \((1, 2, 3)\) and \((4, 6, 8)\). The midpoint formula is:

\[ M = \left( \frac{x_1 + x_2}{2}, \frac{y_1 + y_2}{2}, \frac{z_1 + z_2}{2} \right) \] \[ x_1 = 1, \, y_1 = 2, \, z_1 = 3 \] \[ x_2 = 4, \, y_2 = 6, \, z_2 = 8 \] \[ M_x = \frac{1 + 4}{2} = \frac{5}{2} = 2.5 \] \[ M_y = \frac{2 + 6}{2} = \frac{8}{2} = 4 \] \[ M_z = \frac{3 + 8}{2} = \frac{11}{2} = 5.5 \] \[ M = (2.5, 4, 5.5) \]

The midpoint is the center point between the two given coordinates, often used to locate the middle of a line segment in 3D.

Example 3: Vector Between Points

Find the vector from \((1, 2, 3)\) to \((4, 6, 8)\). The vector \(\vec{v}\) is:

\[ \vec{v} = (x_2 - x_1, y_2 - y_1, z_2 - z_1) \] \[ x_1 = 1, \, y_1 = 2, \, z_1 = 3 \] \[ x_2 = 4, \, y_2 = 6, \, z_2 = 8 \] \[ \vec{v}_x = 4 - 1 = 3 \] \[ \vec{v}_y = 6 - 2 = 4 \] \[ \vec{v}_z = 8 - 3 = 5 \] \[ \vec{v} = (3, 4, 5) \]

The magnitude of the vector is the distance, confirming \(\sqrt{3^2 + 4^2 + 5^2} = \sqrt{50}\), aligning with the distance calculation.

Example 4: Angle Between Vectors

Find the angle between vectors \(\vec{u} = (1, 2, 3)\) and \(\vec{v} = (4, 6, 8)\). Use the dot product formula:

\[ \vec{u} \cdot \vec{v} = u_x v_x + u_y v_y + u_z v_z \] \[ \vec{u} \cdot \vec{v} = (1 \times 4) + (2 \times 6) + (3 \times 8) \] \[ = 4 + 12 + 24 \] \[ = 40 \] \[ |\vec{u}| = \sqrt{1^2 + 2^2 + 3^2} = \sqrt{1 + 4 + 9} = \sqrt{14} \] \[ |\vec{v}| = \sqrt{4^2 + 6^2 + 8^2} = \sqrt{16 + 36 + 64} = \sqrt{116} \] \[ \cos \theta = \frac{\vec{u} \cdot \vec{v}}{|\vec{u}| |\vec{v}|} \] \[ = \frac{40}{\sqrt{14} \times \sqrt{116}} \] \[ \approx \frac{40}{13.892 \times 10.770} \] \[ \approx \frac{40}{149.63} \] \[ \approx 0.267 \] \[ \theta = \cos^{-1}(0.267) \approx 74.5^\circ \]

The angle helps determine the orientation between two directions in 3D space, critical in physics and graphics.

Example 5: Plane Equation

Find the equation of a plane passing through \((1, 2, 3)\), \((4, 6, 8)\), and \((0, 0, 0)\). Use the normal vector from cross product of vectors \(\vec{AB}\) and \(\vec{AC}\):

\[ \vec{AB} = (4 - 1, 6 - 2, 8 - 3) = (3, 4, 5) \] \[ \vec{AC} = (0 - 1, 0 - 2, 0 - 3) = (-1, -2, -3) \] \[ \vec{n} = \vec{AB} \times \vec{AC} \] \[ = \begin{vmatrix} \mathbf{i} & \mathbf{j} & \mathbf{k} \\ 3 & 4 & 5 \\ -1 & -2 & -3 \\ \end{vmatrix} \] \[ = \mathbf{i}(4 \cdot (-3) - 5 \cdot (-2)) - \mathbf{j}(3 \cdot (-3) - 5 \cdot (-1)) + \mathbf{k}(3 \cdot (-2) - 4 \cdot (-1)) \] \[ = \mathbf{i}(-12 + 10) - \mathbf{j}(-9 + 5) + \mathbf{k}(-6 + 4) \] \[ = -2\mathbf{i} + 4\mathbf{j} - 2\mathbf{k} \] \[ \vec{n} = (-2, 4, -2) \] \[ \text{Plane equation: } -2(x - x_0) + 4(y - y_0) - 2(z - z_0) = 0 \] \[ \text{Using } (1, 2, 3): \] \[ -2(x - 1) + 4(y - 2) - 2(z - 3) = 0 \] \[ -2x + 2 + 4y - 8 - 2z + 6 = 0 \] \[ -2x + 4y - 2z = 0 \] \[ x - 2y + z = 0 \]

This equation defines the plane, useful for modeling surfaces in 3D design.

Example 6: Sphere Center

Find the center and radius of a sphere with equation \(x^2 + y^2 + z^2 - 2x + 4y - 6z + 5 = 0\). Complete the square:

\[ x^2 - 2x + y^2 + 4y + z^2 - 6z = -5 \] \[ (x^2 - 2x + 1) + (y^2 + 4y + 4) + (z^2 - 6z + 9) = -5 + 1 + 4 + 9 \] \[ (x - 1)^2 + (y + 2)^2 + (z - 3)^2 = 9 \]

The center is \((1, -2, 3)\) and the radius is \(\sqrt{9} = 3\), representing a sphere in 3D space for applications like planetary modeling.

Applications

3D geometry is integral to various fields. Here are detailed examples:

  • Computer Graphics - Object Rendering: Calculate the distance between a camera at \((0, 0, 0)\) and an object at \((3, 4, 5)\):
    \[ d = \sqrt{(3 - 0)^2 + (4 - 0)^2 + (5 - 0)^2} \] \[ = \sqrt{9 + 16 + 25} \] \[ = \sqrt{50} \] \[ \approx 7.071 \]
    This distance determines scaling and perspective in 3D rendering.
  • Physics - Vector Motion: A particle moves from \((1, 2, 3)\) to \((4, 6, 8)\) with velocity vector \((3, 4, 5)\). Speed is the magnitude:
    \[ |\vec{v}| = \sqrt{3^2 + 4^2 + 5^2} \] \[ = \sqrt{9 + 16 + 25} \] \[ = \sqrt{50} \] \[ \approx 7.071 \, \text{units/second} \]
    This speed is used to analyze motion trajectories.
  • Architecture - Structural Design: Find the midpoint of two support points \((0, 0, 0)\) and \((10, 20, 30)\) for a beam:
    \[ M = \left( \frac{0 + 10}{2}, \frac{0 + 20}{2}, \frac{0 + 30}{2} \right) \] \[ = (5, 10, 15) \]
    This midpoint helps position the beam’s center for load distribution.
  • Robotics - Angle Between Joints: For robot arms with vectors \((1, 1, 1)\) and \((2, 2, 2)\), the angle is:
    \[ \vec{u} \cdot \vec{v} = (1 \times 2) + (1 \times 2) + (1 \times 2) \] \[ = 6 \] \[ |\vec{u}| = \sqrt{1^2 + 1^2 + 1^2} = \sqrt{3} \] \[ |\vec{v}| = \sqrt{2^2 + 2^2 + 2^2} = \sqrt{12} = 2\sqrt{3} \] \[ \cos \theta = \frac{6}{\sqrt{3} \times 2\sqrt{3}} \] \[ = \frac{6}{6} \] \[ = 1 \] \[ \theta = \cos^{-1}(1) = 0^\circ \]
    A 0° angle indicates the arms are aligned, aiding motion planning.
  • Engineering - Plane Intersection: For a plane \(x - y + z = 0\) and a line from \((1, 1, 1)\) to \((2, 0, 2)\), check intersection:
    \[ \text{Line vector: } (2 - 1, 0 - 1, 2 - 1) = (1, -1, 1) \] \[ \text{Plane normal: } (1, -1, 1) \] \[ \text{Dot product: } 1 \cdot 1 + (-1) \cdot (-1) + 1 \cdot 1 = 1 + 1 + 1 = 3 \neq 0 \]
    Since the dot product is non-zero, the line is not parallel and intersects the plane, useful for structural analysis.
  • Astronomy - Sphere Modeling: A planet’s orbit is approximated by a sphere \(x^2 + y^2 + z^2 - 4x + 6y - 2z + 5 = 0\). Find the center:
    \[ x^2 - 4x + y^2 + 6y + z^2 - 2z = -5 \] \[ (x^2 - 4x + 4) + (y^2 + 6y + 9) + (z^2 - 2z + 1) = -5 + 4 + 9 + 1 \] \[ (x - 2)^2 + (y + 3)^2 + (z - 1)^2 = 9 \]
    Center is \((2, -3, 1)\), radius is 3, aiding in orbital path calculations.