# Convergence and Stability of Explicit and Implicit Schemes in the Simulation of the Heat Equation
## 3 Finite Difference Approximations  
The finite difference method is one of the many techniques to obtain numerical solutions of Equation (1). In all numerical solutions, the differential equation is replaced by a discrete approximation. In this context, the word \"discrete\" means that the numerical solution is known only at a finite number of points in the physical domain, see Figure 1.  
Figure 1: For the sake of generality, the discretization scheme is shown with the spacings in time and space.  
In general, increasing the number of points not only increases the resolution but also the accuracy of the numerical solution [36; 37].  
In many cases, it is not possible to find an analytical solution, especially with those real physical problems that have regions with non-regular geometry. However, convergence and stability tests ensure that the finite difference approximations used in the discretization are correct. There are ways to calculate the convergence of a code when the analytical solutions are known. Here, the parameters are taken into account to have a sufficiently fine mesh and thus obtain a convergent system in as few iterations as possible. To this end, we resort to the condition \(\Delta x\leq\mathbb{k}\)\(\Delta t\), to ensure that the meshing is the one that best fits the solution space to be discretized. Knowing the value of \(\Delta x\), the minimum number of nodes to give a numerical solution to this system can be determined. In this way, the central idea of the finite difference method is to replace continuous derivatives with so-called difference formulas involving only the discrete values associated with positions on the grid.  
Applying the finite difference method to a differential equation involves replacing the derivatives with the corresponding finite difference expression, according to the appropriate scheme and accuracy. In the heat equation, there are derivatives concerning time and derivatives concerning space. Using different grids should confirm the stability of the solutions. In the limit when the mesh spacing (\(\Delta x\) and \(\Delta t\)) tends to zero, the numerical solution with either scheme will approach the true solution to the original differential equation, or the numerical solution approaches with less error to the true solution. However, how close the numerical solution approaches the true solution varies with the difference scheme used. Additionally, some practically useful schemes may fail to give a solution for bad combinations of \(\Delta x\) and \(\Delta t\). This is what we want to verify in this work [38].  
The discrete approximation results in a set of algebraic equations that are evaluated (or solved) for the values of the discrete variables. Figure 2 is a schematic representation of the numerical solution. The mesh is the set of points where the discrete solution is calculated (Figure 1). These points are called nodes; the lines between are adjacent to the domain nodes, and the resulting image would resemble a grid or mesh. The key parameters of the mesh are \(\Delta x\), the local distance between adjacent points in space, and \(\Delta t\), the local distance between adjacent time steps. For simplicity, the examples considered in this article \(\Delta x\) and \(\Delta t\) are uniform throughout the mesh.  
The numerical solution of the heat equation is discussed in many textbooks. References [1; 2; 3; 4; 5; 6; 7; 8] provide a more mathematical description of the development of finite difference methods. See [PERSON] [4] for a modern introduction to the theory of partial differential equations along with brief coverage of numerical methods [9; 13; 16] that takes a more applied approach and introduces implementation problems. [PERSON] [4] provides development in Fortran for several methods.