# Introduction to finite elements/Linear heat equation

Finite element methods are used to solve boundary value problems (BVP) or initial boundary value problems (IBVP) in engineering. BVPs are mathematical models of real-life situations. Such situations can be physical, biological, economic, and so on.

We will explore the problem of heat conduction and see how we build a finite element model and solve this problem. The first step will be to build a model. The model is the IBVP in the form of a partial differential equation or a variational problem. We will discuss whether the problem is well-posed. Then we will try to construct an approximate solution to the problem. Finally, we will discuss how good the solution is.^{[1]}

## Construction of a Model[edit | edit source]

Figure 1 shows a region through which heat is flowing. Points in the medium are represented by with components with respect to the basis and the origin. The heat flux into (or out of) the medium is where is the time. The heat flux takes place across part of the boundary of the medium (). The temperature on the remainder of the boundary () has a known value . Heat sources inside the medium (for example, chemical reactions and plastic deformation) are given as a function .

The goal is to find the temperature distribution in the medium () as time evolves.

A realistic model for this problems needs two components:

- A balance (or conservation) equation for energy.
- A constitutive equation for the medium.

### Balance of energy[edit | edit source]

Let us assume that there are no sources of energy other than thermal energy. Then, the balance of energy states that:

*Rate of change of thermal energy = heat generated by internal sources + heat flow into the body.*

We have to convert this statement into mathematical form. To do this, consider an arbitrary part of the body () with boundary . Let be the outward unit normal to the boundary.

The total thermal energy in at a particular time is given by the heat capacity of the body. The heat capacity is the amount of energy needed to raise the temperature (of a unit mass of the body) by one unit.

Let the mass density be . Then, the total thermal energy in at time is

The total heat generated by internal sources is

And the total heat flux into is

Apply the divergence theorem to (4) to get

Put (2), (3), and (5) together, and apply the balance of energy to get

The limits of integration are fixed. So we can write (6) as

Since is arbitrary, if the functions that appear in (7) are smooth enough, the equation is equivalent to

We can write equation (8) in index notation as

where we have assumed that the components are with respect to the Cartesian basis (). In the following, whenever we use index notation, the components are assumed to be with respect to that Cartesian basis.

### Constitutive equation[edit | edit source]

There are two unknowns in equation (8). These are and and only one equation. Therefore, we need another equation that characterizes the material.

One possibility is the Fourier law which states that:

*the heat flux is linearly related to the temperature gradient.*

In mathematical form,

The quantity is a second-order tensor called the ** thermal conductivity** tensor. The minus sign shows that heat flows
from hot to cold. Recall that a second-order tensor takes a vector to another vector (in this case a temperature gradient to a heat flux).

In index notation, we can write equation (9) as

If the region is ** homogeneous** then is constant.
If the region is ** isotropic**, the thermal conductivity tensor takes the form

where is a scalar.

### Heat equation[edit | edit source]

To get the heat equation, combine (9) with (8) to get

Rearrange to get

where .

In index notation, equation (11) is

In expanded form, equation (11) reads

Equation (12) is the *transient, inhomogeneous, heat equation*.

### Boundary conditions[edit | edit source]

Boundary conditions (BCs) are needed to make sure that we get a unique solution to equation (12).

The temperature is prescribed on . Prescribed boundary conditions are also called * Dirichlet* BCs or * essential* BCs. In this case

The heat flux is given on the remainder of the boundary (). Such flux boundary conditions are also known as * Neumann* BCs or * natural* BCs. The flux boundary condition is

In index notation, the essential boundary condition is

Plug equation (9) into (14). We get

If the region is isotropic with thermal conductivity , we can define and (also called the normal derivative). Then the flux BC simplifies to

If the boundary is insulated, then = 0 = .

### Initial conditions[edit | edit source]

If the problem depends on time, we also need an initial condition for the temperature in the body,

### The complete model[edit | edit source]

The model initial boundary value problem (IBVP) for heat conduction is

```
```

## References[edit | edit source]

- ↑ This writeup is based on the introductory chapter in
*Introductory Functional Analysis with Applications to Boundary Value Problems and Finite Elements*by B. Daya Reddy, Springer, 1998, and the chapter on parabolic and hyperbolic problems in*The Finite Element Method: Linear Static and Dynamic Finite Element Analysis*by T.J.R Hughes.