In mathematics, an inner product space is a vector space with the additional structure called an inner product. This additional structure associates each pair of vectors in the space with a scalar quantity known as the inner product of the vectors. Inner products allow the rigorous introduction of intuitive geometrical notions such as the length of a vector or the angle between two vectors. They also provide the means of defining orthogonality between vectors (zero inner product). Inner product spaces generalize Euclidean spaces (in which the inner product is the dot product, also known as the scalar product) to vector spaces of any (possibly infinite) dimension, and are studied in functional analysis.
An inner product space is sometimes also called a preHilbert space, since its completion with respect to the metric, induced by its inner product, is a Hilbert space. That is, if a preHilbert space is complete with respect to the metric arising from its inner product (and norm), then it is called a Hilbert space.
Inner product spaces were referred to as unitary spaces in earlier work, although this terminology is now rarely used.
Contents 
In this article, the field of scalars denoted is either the field of real numbers or the field of complex numbers .
Formally, an inner product space is a vector space V over the field together with an inner product, i.e., with a map
that satisfies the following three axioms for all vectors and all scalars :
Notice that conjugate symmetry implies that is real for all x, since we have
Conjugate symmetry and linearity in the first variable gives
so an inner product is a sesquilinear form. Conjugate symmetry is also called Hermitian symmetry, and a conjugate symmetric sesquilinear form is called a Hermitian form While the above axioms are more mathematically economical, a compact verbal definition of an inner product is a positivedefinite Hermitian form.
In the case of , conjugatesymmetric reduces to symmetric, and sesquilinear reduces to bilinear. So, an inner product on a real vector space is a positivedefinite symmetric bilinear form.
From the linearity property it is derived that x = 0 implies while from the positivedefiniteness axiom we obtain the converse, implies x = 0. Combining these two, we have the property that if and only if x = 0.
The property of an inner product space V that
is known as additivity.
Remark: Some authors, especially in physics and matrix algebra, prefer to define the inner product and the sesquilinear form with linearity in the second argument rather than the first. Then the first argument becomes conjugate linear, rather than the second. In those disciplines we would write the product as (the braket notation of quantum mechanics), respectively y^{T}x (dot product as a case of the convention of forming the matrix product AB as the dot products of rows of A with columns of B). Here the kets and columns are identified with the vectors of V and the bras and rows with the dual vectors or linear functionals of the dual space V^{*}, with conjugacy associated with duality. This reverse order is now occasionally followed in the more abstract literature, e.g., Emch [1972], taking to be conjugate linear in x rather than y. A few instead find a middle ground by recognizing both and as distinct notations differing only in which argument is conjugate linear.
There are various technical reasons why it is necessary to restrict the basefield to and in the definition. Briefly, the basefield has to contain an ordered subfield (in order for nonnegativity to make sense) and therefore has to have characteristic equal to 0. This immediately excludes finite fields. The basefield has to have additional structure, such as a distinguished automorphism. More generally any quadratically closed subfield of or will suffice for this purpose, e.g., the algebraic numbers, but when it is a proper subfield (i.e., neither nor ) even finitedimensional inner product spaces will fail to be metrically complete. In contrast all finitedimensional inner product spaces over or , such as those used in quantum computation, are automatically metrically complete and hence Hilbert spaces.
In some cases we need to consider nonnegative semidefinite sesquilinear forms. This means that is only required to be nonnegative. We show how to treat these below.
Inner product spaces have a naturally defined norm
This is well defined by the nonnegativity axiom of the definition of inner product space. The norm is thought of as the length of the vector x. Directly from the axioms, we can prove the following:
Let V be a finite dimensional inner product space of dimension n. Recall that every basis of V consists of exactly n linearly independent vectors. Using the GramSchmidt Process we may start with an arbitrary basis and transform it into an orthonormal basis. That is, into a basis in which all the elements are orthogonal and have unit norm. In symbols, a basis is orthonormal if if and for each i.
This definition of orthonormal basis generalizes to the case of infinite dimensional inner product spaces in the following way. Let V be a any inner product space. Then an collection is a basis for V if the subspace of V generated by finite linear combinations of elements of E is dense in V (in the norm induced by the inner product). We say that E is an orthonormal basis for V if it is a basis and if and for all .
Using an infinitedimensional analog of the GramSchmidt process one may show:
Theorem. Any separable inner product space V has an orthonormal basis.
Using the Hausdorff Maximal Principle and the fact that in a complete inner product space orthogonal projection onto linear subspaces is welldefined, one may also show that
Theorem. Any complete inner product space V has an orthonormal basis.
The two previous theorems raise the question of whether all inner product spaces have an orthonormal basis. The answer, it turns out is negative. This is a nontrivial result, and is proved below. The following proof is taken from Halmos's A Hilbert Space Problem Book (see the references).
Proof 

Recall that the dimension of an inner product space is the
cardinality of the maximal orthonormal system that it contains. Let
K be a Hilbert Space (a complete inner product space) with
and let E be an orthonormal basis for K. The
cardinality of E is .
Let F be a subset of K such that
is a Hamel basis for K. Then
 F  = c, the
cardinality of the continuum.
Our first task is to construct a Hilbert Space H with a dense subspace G so that the dimension of G is strictly smaller than the dimension of H'.' Let L be a Hilbert Space of dimensions c, and define a linear transformation where B is an orthonormal basis for L. Let G be the graph of T. That is,
Define . Notice that . Therefore, . Thus, since , we get that
Hence, we see that . So . Moreover, because E is a maximal orthonormal set in G. Indeed, if , then , which implies that f=0 and so Tf=0 as well. We have now constructed a Hilbert Space H with a dense subspace G so that
We claim that there does not exist an orthonormal basis for G. Suppose for the sake contradiction that is a total orthonormal system for G. Then the span of intersected with G is a closed subspace of G containing and hence is equal to G. But G is dense in H and hence is an orthonormal basis for H as well. This is a contradiction since this implies . This completes the proof. 
Parseval's identity leads immediately to the following theorem:
Theorem. Let V be a separable inner product space and {e_{k}}_{k} an orthonormal basis of V. Then the map
is an isometric linear map V → ℓ^{ 2} with a dense image.
This theorem can be regarded as an abstract form of Fourier series, in which an arbitrary orthonormal basis plays the role of the sequence of trigonometric polynomials. Note that the underlying index set can be taken to be any countable set (and in fact any set whatsoever, provided ℓ^{ 2} is defined appropriately, as is explained in the article Hilbert space). In particular, we obtain the following result in the theory of Fourier series:
Theorem. Let V be the inner product space C[ − π,π]. Then the sequence (indexed on set of all integers) of continuous functions
is an orthonormal basis of the space C[ − π,π] with the L^{2} inner product. The mapping
is an isometric linear map with dense image.
Orthogonality of the sequence {e_{k}}_{k} follows immediately from the fact that if k ≠ j, then
Normality of the sequence is by design, that is, the coefficients are so chosen so that the norm comes out to 1. Finally the fact that the sequence has a dense algebraic span, in the inner product norm, follows from the fact that the sequence has a dense algebraic span, this time in the space of continuous periodic functions on [ − π,π] with the uniform norm. This is the content of the Weierstrass theorem on the uniform density of trigonometric polynomials.
Several types of linear maps A from an inner product space V to an inner product space W are of relevance:
From the point of view of inner product space theory, there is no need to distinguish between two spaces which are isometrically isomorphic. The spectral theorem provides a canonical form for symmetric, unitary and more generally normal operators on finite dimensional inner product spaces. A generalization of the spectral theorem holds for continuous normal operators in Hilbert spaces.
If V is a vector space and ⟨ , ⟩ a semidefinite sesquilinear form, then the function x = ⟨x, x⟩^{1/2} makes sense and satisfies all the properties of norm except that x = 0 does not imply x = 0 (such a functional is then called a seminorm). We can produce an inner product space by considering the quotient W = V/{ x : x = 0}. The sesquilinear form ⟨ , ⟩ factors through W.
This construction is used in numerous contexts. The Gelfand–Naimark–Segal construction is a particularly important example of the use of this technique. Another example is the representation of semidefinite kernels on arbitrary sets.

