To read this content please select one of the options below:

Convergence and error analysis of an automatically differentiated finite volume based heat conduction code

Christopher DeGroot (Department of Mechanical and Materials Engineering, Western University, London, Canada)

International Journal of Numerical Methods for Heat & Fluid Flow

ISSN: 0961-5539

Article publication date: 31 July 2019

Issue publication date: 30 August 2019




This paper aims to investigate the convergence and error properties of a finite volume-based heat conduction code that uses automatic differentiation to evaluate derivatives of solutions outputs with respect to arbitrary solution input(s). A problem involving conduction in a plane wall with convection at its surfaces is used as a test problem, as it has an analytical solution, and the error can be evaluated directly.


The finite volume method is used to discretize the transient heat diffusion equation with constant thermophysical properties. The discretized problem is then linearized, which results in two linear systems; one for the primary solution field and one for the secondary field, representing the derivative of the primary field with respect to the selected input(s). Derivatives required in the formation of the secondary linear system are obtained by automatic differentiation using an operator overloading and templating approach in C++.


The temporal and spatial discretization error for the derivative solution follows the same order of accuracy as the primary solution. Second-order accuracy of the spatial and temporal discretization schemes is confirmed for both primary and secondary problems using both orthogonal and non-orthogonal grids. However, it has been found that for non-orthogonal cases, there is a limit to the error reduction, which is concluded to be a result of errors in the Gauss-based gradient reconstruction method.


The convergence and error properties of derivative solutions obtained by forward mode automatic differentiation of finite volume-based codes have not been previously investigated.



Funding: This work was supported by the Natural Sciences and Engineering Research Council of Canada (NSERC) [RGPIN-2017-04078].


DeGroot, C. (2019), "Convergence and error analysis of an automatically differentiated finite volume based heat conduction code", International Journal of Numerical Methods for Heat & Fluid Flow, Vol. 29 No. 7, pp. 2389-2406.



Emerald Publishing Limited

Copyright © 2019, Emerald Publishing Limited

Related articles