11.1 Error Analysis and Estimation
339
made and must be sorted out. The estimated discretization error should be
compared with the required accuracy.
This procedure must be repeated for a number of test cases similar to the
applications in order t o try t o root out as many error sources as possible.
Only when a systematic analysis of the results produced by the code has
been made and grid and time-step independent solutions (in the sense that
the discretization errors have been reliably estimated and are small enough)
have been obtained, should one compare the solutions with analytical or other
reference solutions. This is the final check for programming or algorithmic
errors. Comparing solutions obtained on one grid with reference solutions is
not meaningful, since often some quantities may accidentally agree well or
some errors may cancel out.
Code validation says nothing about the accuracy with which the numerically accurate solutions represent real flows. No matter which turbulence (or
other) model we use, we have to be sure that we are solving the equations
that incorporate the models correctly. Comparisons of solutions obtained by
different groups using the same grid and the same turbulence model but different codes often show larger differences than when one group uses the same
code but different turbulence models (this is the conclusion reached a t many
workshops). The models appear to be differently implemented, the boundary
conditions differently treated etc. This is a difficult problem for which no satisfactory solution has been found. The differences may be due to differences
in implementation but, if the models used are really identical and the implementation is correct and errors have been evaluated and eliminated, every
code should produce the same result and the differences should disappear.
This is why we have stressed the need for validation and error evaluation.
Validation of CFD Results. Validation of CFD results includes the analysis of discretization and modeling errors; one can assume that a validated
code is used with appropriate convergence criteria, so that iteration errors
can be excluded.
One of the most important factors which affects the accuracy of CFD
results is the quality of the numerical grid. Note that even a poor grid, if
refined enough, should produce the correct solution; it will just cost more.
Furthermore, even the best code may produce poor results on a bad and
insufficiently refined grid, and a code based on simpler and less accurate
approximations may produce excellent results if the grid is tuned for the
problem being solved. (However, this is often a matter of getting the various
errors to cancel each other.) Discretization errors may be reduced by a proper
distribution of grid points; see Fig. 7.11.
Many commercial codes have been made sufficiently robust that they run
on any grid the user might provide. However, robustness is usually achieved
a t the expense of accuracy (for example, by using upwind approximations). A
careless user may not pay much attention to grid quality and thereby obtain
inaccurate solutions with little effort. The effort invested in grid generation,
339
made and must be sorted out. The estimated discretization error should be
compared with the required accuracy.
This procedure must be repeated for a number of test cases similar to the
applications in order t o try t o root out as many error sources as possible.
Only when a systematic analysis of the results produced by the code has
been made and grid and time-step independent solutions (in the sense that
the discretization errors have been reliably estimated and are small enough)
have been obtained, should one compare the solutions with analytical or other
reference solutions. This is the final check for programming or algorithmic
errors. Comparing solutions obtained on one grid with reference solutions is
not meaningful, since often some quantities may accidentally agree well or
some errors may cancel out.
Code validation says nothing about the accuracy with which the numerically accurate solutions represent real flows. No matter which turbulence (or
other) model we use, we have to be sure that we are solving the equations
that incorporate the models correctly. Comparisons of solutions obtained by
different groups using the same grid and the same turbulence model but different codes often show larger differences than when one group uses the same
code but different turbulence models (this is the conclusion reached a t many
workshops). The models appear to be differently implemented, the boundary
conditions differently treated etc. This is a difficult problem for which no satisfactory solution has been found. The differences may be due to differences
in implementation but, if the models used are really identical and the implementation is correct and errors have been evaluated and eliminated, every
code should produce the same result and the differences should disappear.
This is why we have stressed the need for validation and error evaluation.
Validation of CFD Results. Validation of CFD results includes the analysis of discretization and modeling errors; one can assume that a validated
code is used with appropriate convergence criteria, so that iteration errors
can be excluded.
One of the most important factors which affects the accuracy of CFD
results is the quality of the numerical grid. Note that even a poor grid, if
refined enough, should produce the correct solution; it will just cost more.
Furthermore, even the best code may produce poor results on a bad and
insufficiently refined grid, and a code based on simpler and less accurate
approximations may produce excellent results if the grid is tuned for the
problem being solved. (However, this is often a matter of getting the various
errors to cancel each other.) Discretization errors may be reduced by a proper
distribution of grid points; see Fig. 7.11.
Many commercial codes have been made sufficiently robust that they run
on any grid the user might provide. However, robustness is usually achieved
a t the expense of accuracy (for example, by using upwind approximations). A
careless user may not pay much attention to grid quality and thereby obtain
inaccurate solutions with little effort. The effort invested in grid generation,
