Numerical Accuracy vs Computational Speed in CFD; a comprehensive numerical parameter comparison (technical deep dive)

Join Jun Hao Liew in his CFD journey solving the CFD workflow dilemma: how tight should your solver tolerances really be?

Numerical accuracy in computational fluid dynamics refers to how closely a discretised numerical solution approximates the exact mathematical solution of the governing equations. This accuracy is governed by several critical factors including spatial resolution of the grid, spatial discretisation schemes, and convergence tolerance, along with mesh quality, time step size, and iterative solver parameters.

Among these factors, solution tolerances and relaxation factors represent two key parameters that control iterative solver behaviour and significantly influence both solution quality and computational efficiency.

Solution tolerances define when iterative solvers stop, representing the residual threshold at which solutions are deemed sufficiently accurate. Relaxation factors control how aggressively solutions update between iterations: conservative values promote stability but slow convergence, while aggressive values accelerate solving but risk instability.

Flow around a circular cylinder represents a fundamental engineering problem that has been extensively studied for a long time. This configuration exhibits critical fluid dynamics phenomena including flow separation and vortex shedding, which directly impact drag and lift coefficients. The characteristic von Kármán vortex street formation makes cylinder crossflow an ideal test case for evaluating how numerical solver settings affect both computational performance and physical accuracy.

Simulation Framework

The comparative study in OpenFOAM examined five distinct solver configurations applied to flow over a circular cylinder. The geometry featured a structured mesh containing 320 tangential and 80 radial cells, totalling 25,600 computational cells, with uniform refinement around the cylinder, achieving a refinement ratio of 500 between the first and last cell sizes.

The flow field around the cylinder operates at high Reynolds number within the upper transition regime (Re > 1.5e6), beyond the supercritical range. The Spalart-Allmaras turbulence model with Reynolds-Averaged Navier-Stokes (RANS) equations was employed across all five simulations. Each configuration maintained identical mesh, free-stream boundary conditions, and physical properties while varying only the numerical tolerances and relaxation factors.

Table of configurations
  • Coupling Algorithm: PIMPLE
  • Pressure solver: GAMG
  • Velocity solver: PBiCG + DILU preconditioning
  • Turbulence solver: Smooth Solver + symmetric Gauss Seidel smoothing
  • RANS turbulence model: Spalart-Allmaras
  • Time marching scheme: Backward, with 1e-3 timestep
  • Convection schemes in momentum equation: Gauss limited linear
  • Convection scheme in nuTilda equation: Gauss upwind

Drag and Lift Coefficient Plots

Drag and lift coefficient plots of each configuration

Key Findings and Implications

Configurations 1 and 4 produced nearly identical convergence behaviour despite employing opposite relaxation factor approaches, with extremely minor differences limited to transient initialization phases and negligible variations in oscillation magnitude. This demonstrates that when iterative convergence criteria are sufficiently stringent (1e-8), relaxation factor settings have minimal impact on final solution accuracy.

Similarly, Configurations 3 and 5 demonstrated similar behaviour, with minor deviations limited to initial transient periods. This indicates that when convergence tolerances are less restrictive (1e-4), relaxation factor modifications cannot compensate for inadequate residual reduction requirements.

Comparison of computational time between configurations (Table generated with the help of Claude.ai)

Computational performance aligned with expectations, Configurations 3 and 5 achieved minimum execution times due to their relaxed tolerance thresholds and aggressive relaxation parameters, while Configuration 1 demanded maximum computational resources due to its stringent convergence requirements.

Configuration 2 demonstrated optimal balance, requiring only 30% of the computational time while preserving essential flow physics fidelity. However, Configurations 1, 2, and 4 all exhibited enhanced numerical damping characteristics compared to Configurations 3 and 5, yet all solutions asymptotically converged to equivalent lift coefficient oscillations centred around 0.1.

Drag coefficient predictions demonstrated remarkable consistency across all configurations, exhibiting minimal temporal fluctuations near 0.22, which corresponds precisely with established correlations for trans-critical Reynolds number regimes. This uniformity suggests that time-averaged drag predictions exhibit greater robustness to solver parameter variations than instantaneous lift force characteristics.

In Conclusion

Solver tolerance levels are the dominant factor in determining solution accuracy, while relaxation factors primarily affect convergence speed rather than final solution quality. Figure 2 below shows a summary of the convergence tolerance and relaxation factors and how it affects the solution accuracy and computation speed.

Article content
Tolerance-Relaxation Interaction Matrix (Table generated with the help of Claude.ai)

These findings are based on the specific numerical experiments conducted for cylinder crossflow at trans-critical Reynolds numbers using the Spalart-Allmaras turbulence model. Different flow configurations, geometric scales, turbulence models, and solver applications may require case-specific parameter optimisation. Engineers should conduct similar tolerance and relaxation factor studies for their particular applications to determine optimal solver configurations for their specific computational requirements.

Comparison: nuTilda (modified turbulent viscosity) of cylinder in crossflow, visualised in ParaView

References:

Amalia, E., Moelyadi, M. A., & Ihsan, M. (2018). Effects of Turbulence Model and Numerical Time Steps on Von Karman Flow Behavior and Drag Accuracy of Circular Cylinder. Journal of Physics: Conference Series, 1005, 012012. https://doi.org/10.1088/1742-6596/1005/1/012012.

Sumer, B. M., & Fredsøe, J. (2006). Hydrodynamics Around Cylindrical Structures (Revised, Vol. 26). WORLD SCIENTIFIC. https://doi.org/10.1142/6248

Yao, Q., Zhou, C. Y., & Wang, C. (2016). Numerical Study of the Flow past a Rotating Cylinder at Supercritical Reynolds Number. Proceedings of the 2016 4th International Conference on Mechanical Materials and Manufacturing Engineering. 2016 4th International Conference on Mechanical Materials and Manufacturing Engineering, Wuhan, China. https://doi.org/10.2991/mmme-16.2016.159

Latest news
Sign up to receive our quarterly newsletter and latest news
Read about our privacy policy.
Thank you! Your submission has been received!
Oops! Something went wrong while submitting the form.