Orthogonality as a Finite System of Equations
In a polynomial space, a vector is a polynomial; in a matrix space, a vector is a matrix. The same method applies in both settings: describe the subspace using finitely many generators, take the inner product of an unknown vector with each generator, and set every result equal to zero. The resulting equations can be solved for the coefficients of the unknown polynomial or matrix.
Throughout, the scalar field is \(\mathbb{R}\). For \(k\geq 0\), let \(P_k\) denote the vector space of real polynomials of degree at most \(k\), including the zero polynomial. On \(P_k\), we use the integral inner product on \([-1,1]\). On \(\mathbb{R}^{m\times n}\), we use the Frobenius inner product.
These formulas give real inner products. For a polynomial \(p\), \(\langle p,p\rangle=\int_{-1}^{1}p(x)^2\,dx\) is positive when \(p\ne0\): a nonzero polynomial is nonzero at some point of the interval, and continuity makes its square positive on an interval of positive length. For a matrix \(\mathbf{X}\), \(\langle\mathbf{X},\mathbf{X}\rangle=\sum_{i,j}x_{ij}^{2}\), which is positive unless every entry is zero. Both formulas are also symmetric and linear in each argument over \(\mathbb{R}\).
The orthogonality condition is imposed on every vector in \(W\), but it is usually enough to check a finite list of generators. The reason is that an inner product is linear: orthogonality to each generator implies orthogonality to every linear combination of them.
Proof. Write \(W=\operatorname{span}\{\mathbf{w}_1,\dots,\mathbf{w}_m\}\). If \(\mathbf{x}\in W^{\perp}\), then each generator \(\mathbf{w}_i\) belongs to \(W\), so the definition gives \(\langle\mathbf{x},\mathbf{w}_i\rangle=0\) for every \(i\). Conversely, suppose all these \(m\) inner products are zero. Each \(\mathbf{w}\in W\) has the form \(\mathbf{w}=c_1\mathbf{w}_1+\cdots+c_m\mathbf{w}_m\) for real scalars \(c_i\). By linearity, \(\langle\mathbf{x},\mathbf{w}\rangle=\sum_{i=1}^{m}c_i\langle\mathbf{x},\mathbf{w}_i\rangle=0\). Thus \(\mathbf{x}\) is orthogonal to every vector in \(W\), so \(\mathbf{x}\in W^\perp\). \(\square\)
Polynomial Spaces: Integrate Against Each Generator
In \(P_k\), write an unknown polynomial in a basis such as \(1,x,\dots,x^k\). Each generator then produces one equation. The elementary integrals \(\int_{-1}^{1}x^r\,dx=0\) for odd \(r\), and \(\int_{-1}^{1}x^r\,dx=2/(r+1)\) for even \(r\), make many calculations short. The first formula follows because \(x^r\) is odd; the second follows by evaluating \(x^{r+1}/(r+1)\) at \(1\) and \(-1\).
Worked Example: A Complement in \(P_2\)
Find the orthogonal complement in \(P_2\) of \(W=\operatorname{span}\{1,x\}\), using the integral inner product on \([-1,1]\).
Let \(q(x)=a+bx+cx^2\) be an arbitrary polynomial in \(P_2\). By the finite generator test, \(q\in W^\perp\) exactly when \(\langle q,1\rangle=0\) and \(\langle q,x\rangle=0\). Computing each integral gives
Setting these expressions equal to zero gives \(2a+\frac{2}{3}c=0\) and \(\frac{2}{3}b=0\). Hence \(a=-c/3\), \(b=0\), and \(c\) is free. Therefore
Check: \(\langle x^2-\tfrac13,1\rangle=\frac23-\frac13(2)=0\), and \(\langle x^2-\tfrac13,x\rangle=\int_{-1}^{1}(x^3-\tfrac13x)\,dx=0\), since both terms are odd. The generator is orthogonal to both generators of \(W\), and therefore to every vector in \(W\).
Worked Example: Two Conditions in \(P_3\)
Find the orthogonal complement in \(P_3\) of \(U=\operatorname{span}\{1,x^2\}\), again using the integral inner product on \([-1,1]\).
Let \(q(x)=a+bx+cx^2+dx^3\). Orthogonality to the two generators requires \(\langle q,1\rangle=0\) and \(\langle q,x^2\rangle=0\). Integrating term by term gives
The coefficients \(b\) and \(d\) do not appear because their contributions are odd functions on \([-1,1]\). The equations involving \(a,c\) are equivalent to \(3a+c=0\) and \(5a+3c=0\). Substituting \(a=-c/3\) into the second gives \(-5c/3+3c=4c/3=0\), so \(c=0\) and then \(a=0\). The coefficients \(b,d\) are unrestricted, so
Check: For \(q=bx+dx^3\), both \(q\) and \(x^2q=bx^3+dx^5\) are odd. Their integrals over \([-1,1]\) are zero, so every polynomial in the stated complement is orthogonal to \(1\) and \(x^2\).
Writing the Equations in Coordinates
The same procedure works in any finite-dimensional real inner product space once a basis is chosen. If the unknown vector has coordinates \(c_1,\dots,c_n\), each inner product with a generator is a linear expression in those coordinates. Collecting the coefficients gives a homogeneous linear system. This is the coordinate form of the finite generator test.
Proof. For each \(i\), linearity gives \(\langle\mathbf{x},\mathbf{w}_i\rangle=\left\langle\sum_{j=1}^{n}c_j\mathbf{b}_j,\mathbf{w}_i\right\rangle=\sum_{j=1}^{n}c_j\langle\mathbf{b}_j,\mathbf{w}_i\rangle=\sum_{j=1}^{n}h_{ij}c_j\). The last expression is the \(i\)-th entry of \(\mathbf{H}\mathbf{c}\). Therefore \(\mathbf{H}\mathbf{c}=\mathbf{0}\) holds exactly when \(\mathbf{x}\) is orthogonal to every listed generator. By the finite generator test, that is equivalent to \(\mathbf{x}\in W^\perp\). \(\square\)
Matrix Spaces: Use the Frobenius Inner Product
For matrices of the same size, the Frobenius inner product multiplies entries in matching positions and adds the products. Consequently, each matrix generator contributes one scalar equation in the entries of the unknown matrix. The equations are ordinary linear equations, even though the unknown is written as a matrix.
Worked Example: A Complement in \(\mathbb{R}^{2\times2}\)
Find the orthogonal complement of \(S=\operatorname{span}\{\mathbf{A},\mathbf{B}\}\) in \(\mathbb{R}^{2\times2}\) under the Frobenius inner product, where
Write an arbitrary matrix as \(\mathbf{X}=\begin{bmatrix}r&s\\t&u\end{bmatrix}\). The two required inner products are
Thus \(\mathbf{X}\in S^\perp\) exactly when \(u=-r\) and \(t=-s\). Both \(r\) and \(s\) are free, so
Check: The inner product of \(\begin{bmatrix}1&0\\0&-1\end{bmatrix}\) with \(\mathbf{A}\) is \(1-1=0\), and with \(\mathbf{B}\) is \(0\). The inner product of \(\begin{bmatrix}0&1\\-1&0\end{bmatrix}\) with \(\mathbf{A}\) is \(0\), and with \(\mathbf{B}\) is \(1-1=0\). By linearity, every matrix in the displayed span is orthogonal to both generators.
Common Pitfall: Integral Factors and Matching Entries
A frequent error in polynomial calculations is to use \(\int_{-1}^{1}x^2\,dx=1/3\). The antiderivative is \(x^3/3\), so evaluating at both endpoints gives \(1/3-(-1/3)=2/3\). For example, using the incorrect value in the first worked example would produce the false candidate \(x^2-\frac16\). Substitution exposes the error: \(\langle x^2-\frac16,1\rangle=\frac23-\frac16(2)=\frac13\ne0\). The correct coefficient is \(-1/3\), since \(\langle x^2-\frac13,1\rangle=\frac23-\frac23=0\).
In a matrix space, another mistake is to ignore off-diagonal entries when the generator has nonzero off-diagonal entries. For instance, with \(\mathbf{B}=\begin{bmatrix}0&1\\1&0\end{bmatrix}\) and \(\mathbf{X}=\begin{bmatrix}1&2\\3&4\end{bmatrix}\), the Frobenius inner product is \(1\cdot0+2\cdot1+3\cdot1+4\cdot0=5\), not zero. Matching positions matter: the second and third entries contribute \(2\) and \(3\).
A Reliable Calculation Process
Write a general polynomial or matrix with unknown real coefficients in the space under consideration.
Use one orthogonality equation for each generator of the subspace. If the list is redundant, the equations may also be redundant; they still impose exactly the required conditions.
Evaluate the integrals or entrywise sums exactly, set them equal to zero, and solve the resulting homogeneous system.
Substitute a proposed spanning list into every original inner-product condition. Checking only one generator does not establish orthogonality to the whole subspace.
The finite equation method is useful because it turns an abstract condition—orthogonality to every vector in a subspace—into a manageable calculation. In polynomial spaces, parity and exact integrals often simplify the equations. In matrix spaces, careful entry-by-entry products do the same. In either setting, the proof of correctness is the same: the equations enforce orthogonality to the generators, and linearity extends that orthogonality to their entire span.
Check Your Understanding
For each problem, write every orthogonality equation before solving, and verify the proposed vectors using the stated inner product.
- In \(P_2\) with the integral inner product on \([-1,1]\), find \(\operatorname{span}\{1\}^{\perp}\).
- In \(P_3\), find the complement of \(\operatorname{span}\{x\}\) for the same integral inner product.
- In \(\mathbb{R}^{2\times2}\) with the Frobenius inner product, find the complement of the span of \(\begin{bmatrix}1&1\\0&0\end{bmatrix}\).
- Explain why orthogonality to each of three generators implies orthogonality to their span.
- For \(q(x)=x^2-\frac16\), compute \(\langle q,1\rangle\) and identify the integral value responsible for the result.