Linear Algebra Difficulty: Intermediate

Inner Product Spaces

Inner products generalize the dot product, allowing notions of length, angle, orthogonality, and projection. They are essential for Hilbert spaces and optimization.

Key Points

  • An inner product is linear, symmetric (or conjugate symmetric), and positive definite.
  • Orthogonality and orthonormal bases simplify many computations.
  • The projection onto a subspace minimizes the distance to that subspace.

Formulas

Inner product axioms
$$\langle u, v \rangle = \overline{\langle v, u \rangle}, \quad \langle u, u \rangle \ge 0$$
Cauchy-Schwarz
$$|\langle u, v \rangle| \le \|u\| \|v\|$$
Projection
$$\operatorname{proj}_v u = \frac{\langle u, v \rangle}{\langle v, v \rangle} v$$

Code Example

import numpy as np

u = np.array([1, 2, 3])
v = np.array([1, 0, 1])
proj = (np.dot(u, v) / np.dot(v, v)) * v
print(proj)

Applications

Tags

  • inner-product
  • orthogonality
  • projection

References

  • Linear Algebra Done Right
    Sheldon Axler · Springer · source
  • Introduction to Hilbert Space
    James R. Retherford · Dover · source

Knowledge Graph