CFD: a complex mix of Physics, Engineering and Art! Results need validation and sanity checks including finding a right mesh through mesh convergence studies!
The word "Computational" in the phrase "Computational Fluid Dynamics" is simply an adjective to "Fluid Dynamics". Hence, while dealing with aspects of CFD tool or process, it is vitally important to keep the physical understanding of fluid dynamics uppermost in user's mind as CFD has to do with physical problems. -- Adapted from John D. Anderson, Jr (Computational Fluid Dynamics - The Basics with Applications).
Everybody believe an experiment, except the one who did it.
Nobody believes the simulation, except the one who did it.
We have all come across the phrase "garbage in, garbage out" which has originated from software development (attributed to be coined by George Fuechsel, an IBM programmer and instructor). However, this is equally valid for any 'computer' program where the validity of input decides the correctness of the output. In case of CFD simulations, the term 'validity' refers to the "appropriateness and accuracy" of the input data for numerical simulations. Validation of CFD models is a necessity. These numerical tools are used for different applications and no internal checks are implemented inside the program for the correctness of CFD results. Hence, anybody and everybody who are using CFD simulation tools must make "validation of CFD results" an integral part of their simulation process and activities.
Any numerical simulation process is not just "Meshing, setting Boundary Conditions, Running Solver and Making Colourful Contour / Vector Plots". The results ultimately needs to be converted into a set of inputs for a robust design of the components or sub-systems of a system. The sound knowledge of "underlying fluid mechanics principles and operating conditions of the problem set-up" are more important than just knowing how to use the software. Some of the topics which will help "CFD practitioners" make correct and robust design decisions based on CFD results are:
Though the industrial flow configurations are far from being closer to these simple geometries, the fundamental ideas contained in them are indispensable to a good understanding of modern computational methods. The methods and results arrived at are important not only for these simple flows but also for the extension of our fundamental knowledge of turbulent flows in general. Methods for dealing with turbulent flows for any industrial applications could be devised only on the basis of the detailed experimental results obtained for them.
For example, according to measurements performed by H. Kirsten, the entrance length of a turbulent flow in a pipe is about 50 to 100 diameters. This knowledge is very important in deciding the inlet boundary condition for any industrial internal flow configuration.
CFD is a great tool when used with appropriate procedure and guidelines because of its inherent nature of multi-disciplinary science leading to technically unlimited potential and applications. Yet, "CFD is not a panacea of all the Flow and Heat Transfer problems without experience-base insight". Any result must be looked at by an experienced engineer in that field and must go through an "order-of-magnitude-check" before accepting the results.
All methods for the calculation of turbulent boundary layers are approximate ones and are based on the integral forms of the momentum and energy equations. Since, however, no general expressions for shear and dissipation in turbulent flow can be deduced by purely theoretical considerations, it is necessary to make additional suitable assumptions. These can only be obtained from the results of systematic measurements and, consequently, the calculation of turbulent boundary layers is semi-empirical.
While the usage of CFD simulations in industry is on rise at rapid pace, the credibility of results of any such calculation is still an area of concern. Most organizations using such codes, over time have evolved their own best practice guidelines to minimize the chances of "critical errors". There are many such guidelines issued by ERCOFTAC and AIAA. Following diagram summarizes classifications used to designate the types of error which needs to be addressed when CFD simulations are used to make decisions on performance of a product.
Error: A recognisable deficiency that is not due to lack of knowledge. For example, common known errors are the round-off errors in a computers and the convergence error in an iterative numerical scheme. CFD analyst should be capable of estimating the likely magnitude of the error. It may also arise due to mistakes in input (such as material property variation with temperature).
Uncertainty: A potential deficiency that is due to lack of knowledge. Uncertainties arise because of incomplete knowledge of a physical characteristic, such as the turbulence structure at inlet to a flow domain or because there is uncertainty in the validity of a particular flow model being used. Uncertainty cannot be removed as it is rooted in lack of knowledge (wither physics of the flow or the behaviour of numerical codes). Statistically, the uncertainty of the observable X is a measure of the spread of results around the mean X , also designated as standard deviation.
Verification: It is the procedure intended to ensure that the program solves the equations correctly. As per AIAA, G-077-1998: the process of determining if a simulation accurately represents the conceptual model. A verified simulation does not make any claim relating to the representation of the real world by the simulation. In other words, as per Roache: "it solves the equations right".
Validation: This procedure is intended to test the extent to which the model accurately represents reality. As per AIAA, G-077-1998: it is the process of determining how accurately a simulation represents the real world. In other words, as per Roache: "it solves the right equations".
Accuracy: This is the measure of the similarity of a simulation to the physical flow it is expected to represent. It represents how a predicted value is closer to the measured and/or theoretically exact value.
Consistency: This refers to the 'repeatability' of a process, be it testing or simulation. In measurement or manufacturing process, there are mathods for "Gauge R&anp;R" which stands for repeatability (same output by same operator under idential operating conditions) and reproduceability (same output by different operator) of a method.
Calibration: This procedure to assess the ability of a CFD code to predict global quantities of interest for specific geometries of engineering design interest.
Due to discretization of curved or circular edges (tessellated boundaries), the area is reduced as compared to the curved boundaries. If a velocity boundary condition is being used, it needs to be scaled up in the ratio of reduction in area. Remedy: Grid Convergence Study.
Similarly, not modelig the rotation of the tires and simplification of tire surfaces by removing the grooves can be significant source of error with respect to the actual driving conditions. However, in wind-tunnel tests, the car body is stationary and tyre may not be rotating (though it can be made rotating) - the CFD simulation result will be closer to the test result.
Cases like this when there is rotational contact between two surfaces, the contact area is not correctly known or sometimes it cannot be capture correctly due to accute angle between the circular disk and flat plate.
In actual driving conditions, car is moving through stationary air and the boundary layer may not form at the road surface. When air is blown over a stationary car in wind tunnel testing and CFD simulations, boundary layer forms on the surface representing the ground/road. The remedy is to apply moving wall to the floor having velocity same as car speed.
External aerodynamics simulations are sensitive to the quality of the surface geometry representation. Care must be taken when using the surface wrapper such that junctions/intersections result in smooth and well-defined edges. The geometry simplifications such as removal of small protrusions, deletion of thin wires, smoothen of surface undulation... should be carried out judiciously. Normally such clean-up is a compromise in ability to generate good quality mesh and loss in accuracy due to simplifications. In other words, keeping some of the geometrical features may result in distorted and skewed cells which anyways reduce the accuracy of simulation results.
Recommended monitor points to check for convergence for external aerodynamic simulation over a car body:
MESH CONVERGENCE STUDY: The formal method of establishing mesh convergence requires a curve of a critical result parameter (typically some kind of coefficient such as skin friction coefficient) in a specific location, to be plotted against some measure of mesh density. At least 3 simulation runs are required to plot a curve which can then be used to indicate how convergence is achieved or how far away the most refined mesh is from full convergence. However, if two runs of different mesh density give the same result, (mesh) convergence must already have been achieved and no mesh convergence curve is necessary. Yet, one must be aware that 2 sets of results will only indicate sensitivity and not the mesh convergence.
Another key parameter of a mesh convegence study is the refinement ratio (> 1.0). It is defined as the ratio between two consecutive refinement levels. The use of uniform parameter refinement ratio is recommended for a given parameter. Different refinement ratio for different parameters can also be used based on past experience of the importance of change in value on simulation results. For most of industrial applications with moderate level of accuracy requirements, a refinement ratio of 2.0 often is too high - e.g. it may either lead to a very fine or a very coarse mesh for one of the minimum 3 cases required for convergence study. A refinement ratio of sqrt(2) or 1.5 is a good compromise to distinguish convergence study with iterative errors.
Define target variables (usually scalars like Force, Drag Coefficient, Heat Flux, HTC, MAX Temperature, etc). Check the variation in target variable (e.g. mass flow rate at any plane) for various refinements of mesh, keep ITERATION ERROR limit constant say 1.0E-4
Let's take an example of pump where target variable is head developed by the pump. 3 different meshes are generated with refinement ratio r_{c1}, H_{2} and H_{3} are heads calculated in increasing or decreasing order of refinement. The order of convergence is expressed as: Once the order of convergence is obtained, the average head at zero grid spacing, H(δx = 0) can be determined using a Richardson extrapolation of the two finest mesh. The Grid Convergence Index (GCI) proposed by by Roache (1994) using a safety factor F_{s} of 1.25 should be calculated for mesh pairs [2, 1], [3, 1] and [3, 2].
How close the solution is within the asymptotic range can be calculated using following expression. The value closer to 1 indicates closeness to the asymptotic range.In addition to the turbulence parameter, the inlet velocity profile itself is very important to study the accuracy of CFD result for a particular application. One should check the effect of velocity profile as per power-law such as u = U_{MEAN}*(y/d)^{1/n}, where n = 6, 7, 8, … depending upon Re value. These sensitivity studies are particularly important in cases where separation and reattachment are likely to occur. For Example, in case of a flow over Backward Facing Step, there is decreases in location of reattachment length as the turbulence intensity increases and is sensitive to TI value specified at inlet.
Sources of errors and uncertainties in results from simulations can be divided into two distinct sources: modeling and numerical. Modeling errors and uncertainties are due to assumptions and approximations in the mathematical representation of the physical problem (such as geometry, mathematical equation, coordinate transformation, boundary conditions, turbulence models, etc.) and incorporation of previous data (such as fluid properties) into the model. Numerical errors and uncertainties are due to numerical solution of the mathematical equations (such as discretization, artificial dissipation, incomplete iterative and grid convergence, lack of conservation of mass, momentum, and energy, internal and external boundary non-continuity, computer round-off...).
Buoyancy-driven Flows
Such flows are difficult to converge and special attention is need to set-up the solver. Buoyancy driven flow can be of two types: (a) Open boundaries and (b) Closed domain. While modeling natural convection inside a closed domain, the solution depends on the mass inside the domain. Since the mass in the domain will be known only if the density is known, one must model the flow in one of the following ways:Sample Checklist
In ANSYS FLUENT and as a matter of fact all CFD programs, heat transfer coefficient (h) is a derived quantity using wall temperature, adjacent fluid temperature and heat flux. Note the term "adjacent fluid temperature". This approach makes the HTC value reported by post-processing programs only indicative. In reality: one should estimate heat flux value (q") and area-weighted average tempearature (T_{W_MEAN}) from post-processing utility. Then use the equation: q" = h·(T_{W_MEAN} - T_{REF}) to estimate h. Here selection of T_{REF} should be made inline with empirical correlations reported in text-books.
Heat flux and surface heat transfer coefficient is one of the critical output from a thermal simulation. Understanding of the temperature field near the wall and how its gradient is used to calculate the heat transfer rate is important to identify source of errors. Heat transfer at walls is a combination of "heat diffusion due to conduction" and "heat diffusion due to mixing or convection". This is expressed as described below. Here, T is 'local' time-averaged value. α is thermal diffusivity defined as k/ρCp, ε_{h} is eddy diffusivity of heat - analogous to eddy diffusivity of momentum.
Pr_{t} = ε_{m}/ε_{h} is the turbulent Prandtl number defined as ratio of eddy diffusivity of momentum and eddy diffusivity of heat. Note that ε here is eddy diffusivity and not the turbulent eddy dissipation rate. Analogous to wall function for momentum, the wall function (available in textbooks) for temperature is described below and the equation used to calculate heat flux is also explained.The wall function definition used in ANSYS CFX is:
In ANSYS FLUENT, the laws-of-the-wall for mean velocity and temperature are based on the wall unit y^{*} rather than y^{+}. The definition of y^{*} uses u^{*} instead of u^{+} where y^{*} = ρC_{μ}^{1/4}k^{1/2}y/μ and u^{*} = ρC_{μ}^{1/4}k^{1/2}/τ_{W}. These two quantities are approximately equal in equilibrium turbulent boundary layers. κ is von Karman constant in the equation given below.
The steps followed in calculation of temperature or heat flux are as follows:
Step-1: Molecular Prandtl number is calculated based on specified fluid properties: Pr = μ / Cp / k where k is thermal conductivity (not turbulent kinetic energy though k used in law of wall for temperature above is TKE)
↓
Step-2: For the calculated molecular Prandtl number, thermal sub-layer thickness is estimated which is nothing but the intersection of the linear and logarithmic profiles
↓
Step-3: Depending upon (momentum) boundary layer height, y* is calculated at the centroid of the near wall cell. As mentioned above, in FLUENT, the laws-of-the-wall for mean velocity and temperature are based on the wall unit y^{*} rather than y^{+}.
↓
Step-4: Once y* is calculated, velocity at the centroid of the near wall cell is calculated as per law-of-wall for velocity. Thus, Pr, y* and u(y_{P}) are calculated and stored now. Temperaure at near wall cell is, T(y_{P}) still not known.
↓
Step-5: T(y_{P}) is known by solution of of energy equations in the interior domain. For specified wall temperature boundary condition, heat flux is calculated from the linear equation arising from the law-of-the-wall.
Select the type of geometry: | |
Select the working fluid: | |
Select mode of specifying velocity scale: | |
Specify velocity scale in [m/s] or [m^{3}/s] or [kg/s]: | |
Specify cross-section area in [m^{2}] - ignored if velocity is specified: | |
Select wall condition: 1=constant temperature, 2=constant heat flux: | |
Specify length scale of flow: hyd. dia. (Ducts and bluff bodies) or length of the (Flat) plate [m]: | |
Specify working temperature of the fluid in [°C]: | |
Specify 'absolute' working pressure (required in case of air only) in [bar]: | |
Heat transfer type: 1=Force convection, 2=Natural convection: | |
The content on CFDyna.com is being constantly refined and improvised with on-the-job experience, testing, and training. Examples might be simplified to improve insight into the physics and basic understanding. Linked pages, articles, references, and examples are constantly reviewed to reduce errors, but we cannot warrant full correctness of all content.
Copyright © 2017 - All Rights Reserved - CFDyna.com
Template by OS Templates