The Discrete Formulation
The abstract weak problem — find such that for all — is posed in an infinite-dimensional function space and cannot be solved directly on a computer. The Galerkin method turns it into a finite-dimensional problem by restricting attention to a subspace.
Choose a finite-dimensional subspace of dimension . The subscript conventionally denotes a discretisation parameter, typically the mesh size. The discrete problem reads: find such that
This has exactly the same form as the continuous problem, but lives in a space of dimension instead of an infinite-dimensional one. To turn it into a linear system, let be a basis for . Since is linear in the first argument and , we write
and substitute into the discrete problem, testing against each basis function :
This is a system of equations in unknowns. Defining the stiffness matrix and load vector by
the discrete problem reduces to the linear system
where is the vector of unknown coefficients. When is symmetric (as for the Poisson problem), is symmetric and, under the coercivity condition, positive definite. The restriction of test functions to the subspace — which enforces the Dirichlet boundary conditions — is the subject of a later post on assembly.
The key question is how well approximates the true solution . The relevant measure of error is the -norm, which for is the norm
This norm controls both the function values and their first derivatives, which is exactly the regularity that the weak formulation requires. The answer to the approximation question is given by Céa's lemma: the discrete solution is quasi-optimal in the sense that
where is the continuity constant and is the coercivity constant of . The proof rests on two observations. First, subtracting the discrete problem from the continuous one shows that the error is orthogonal to with respect to :
This is called Galerkin orthogonality. Second, for any ,
where the first step uses coercivity, the second uses Galerkin orthogonality (adding and subtracting ), and the third uses continuity. Dividing by and taking the infimum over gives the bound. When is symmetric the ratio and is the best approximation to from in the energy norm .
Céa's lemma reduces the question of approximation quality entirely to approximation theory: how well can elements of approximate ? This depends on the choice of basis functions and the mesh, which is the topic of the next posts.