WP Shape Optimization For Aero Efficiency Adjoint Methods
WP Shape Optimization For Aero Efficiency Adjoint Methods
Adjoint solvers take a Computational Fluid Dynamics (CFD) flow solution and calculate the
sensitivity of performance indicators (for example, drag or heat transfer) for all of the design
variables. Obtaining an adjoint solution gives designers key information on how to alter the
shape of the design to improve the quantity of interest. Mesh morphing is an easy and power-
ful tool that allows designers to alter the geometry at the mesh level and within the parallel
solver to evaluate effects of the design alterations. Designers can then iterate on this process
to achieve an optimum design without the need to return to the original CAD geometry. For
complex geometries, the aerodynamic interactions become complex and the insight gained
by adjoint solvers can take the design in unexpected directions that are difficult to represent
using parametric geometry.
INTRODUCTION
Transportation is a major consumer of the world’s energy. Nearly a quarter of
the total United States’ energy use is in transportation, and a significant por-
tion is spent by aerodynamic drag. The aerodynamic drag of a vehicle plays a
major role in determining the overall efficiency that the vehicle can achieve.
For example, nearly 22% of a typical truck’s fuel is spent on overcoming
aerodynamic drag. Consequently, any improvements in aerodynamics can have
a significant improvement in the world’s total energy consumption, and yield
savings to vehicle operators.
This paper presents an overview of adjoint technology and explains the ben-
efits, including recent advances allowing multi-objective design assessments
and methods for solving large models.
1
Shape Optimization for Aerodynamic
Efficiency using Adjoint Methods
It also presents a case study that uses these recent advances to optimize the
aerodynamic efficiency of a passenger vehicle over the New European Driv-
ing Cycle (NEDC). While this case focuses on an automotive application, the
techniques discussed here work equally as well for aerospace simulations.
Making a change to any of the inputs that define the problem can cause the
results of the calculation to change. The degree of that change depends on
how sensitive the system is to the particular parameter that is being ad-
justed. Indeed, the derivative of the solution data with respect to that
parameter quantifies this sensitivity to first order. Determining these deriva-
tives is the domain of sensitivity analysis.
There is a large collection of derivative data that can be computed for a fluid
system, given the extensive set of input data that is required, and the ex-
tensive flow data that is produced. The matrix of derivatives for output data
with respect to input data can be vast and — depending upon the goal of the
analysis — only a portion of this derivative data may be of interest.
2
Shape Optimization for Aerodynamic
Efficiency using Adjoint Methods
Once you compute an adjoint solution, the derivative of the observable with
respect to the position of each and every point on the surface of the geome-
try is available, and you can find the sensitivity of the observation to specific
boundary condition settings.
Figure 1 – Adjoint Optimization workflow You can then use the computed adjoint sensitivities to guide intelligent
design modifications to the system because the adjoint sensitivity data
provides a map across the entire surface of the geometry. Design modifica-
tions can be most effective if made in regions of high sensitivity since small
changes will have a large effect upon the engineering quantity of interest.
Iteratively applying this principle of making changes to a system in propor-
tion to the local sensitivity is the foundation for the simple gradient algo-
rithm for design optimization as illustrated in Figure 1. This workflow has
the advantage over the traditional optimization workflow; it is conducted
entirely with the parallel solver, and therefore does not have the overhead of
modifying geometry, remeshing and reading/writing files between the differ-
ent stages.
Figure 2 - Contours of Velocity Figure 3 - Contours of Adjoint
Magnitude Sensitivity to Body Force X-
Component
2-D Cylinder example
Consider a 2-D analysis of a circular cylinder subjected to a cross flow and
bounded top and bottom by symmetry planes. The flow is laminar and incom-
pressible with a Reynolds number of 40 based on the cylinder diameter. The
problem is posed at a Reynolds number where the flow is steady, as can be
seen in the velocity plot shown in Figure 2.
If we consider the corresponding adjoint solution for the drag in the X direc-
tion on the cylinder, we can see in Figure 3 how sensitive the drag on the
cylinder is to the application of a body force in the X-direction in the flow.
Here, the figure shows that the effect of applying a body force downstream
of the cylinder is minimal. If a body force is applied directly upstream of the
cylinder, however, the disturbed flow is incident on the cylinder and modifies
the force that it experiences.
Figure 4 shows how sensitive the drag on the cylinder is to changes in the
surface shape. The drag is affected more significantly if the cylinder is
deformed on the upstream rather than the downstream side. As could be ex-
pected in this simple example, the maximum effect is achieved by narrowing
the cylinder in the cross-stream direction.
3
Shape Optimization for Aerodynamic
Efficiency using Adjoint Methods
If the sensitivity for the lift force in the y direction is considered as a second
objective in addition to the drag and the design change required to reduce
the drag and increase the lift can be calculated, the surface of the cylinder
can be morphed as shown in Figure 5 to improve these objectives.
Recent Advances
In the past, the adjoint solver has been primarily used by the Motorsport
arena [3-5]. Slower adoption of this technology in the automotive commu-
nity has been due primarily to the difficulty in obtaining convergence in the
Figure 4 - Vectors of Adjoint Figure 5 - 2D cylinder mesh
Sensitivity to shape for a 2D
adjoint solution for more unsteady problems with highly separated wake
after deformation
cylinder regions. However, there have been a number of recent advances in adjoint
solver technology that have improved the landscape for this class of flow.
Stabilization
The most recent development is the dissipation scheme, which provides sta-
bilization for the solution advancement of the adjoint solution by introducing
nonlinear damping strategically into the calculation domain. The strategy
provides minimal intervention to damp the growth of instabilities that lead
to adjoint solution divergence. A marker is tracked and, based on the state of
the adjoint solution, a damping is applied directly to the adjoint solution in
regions where the marker becomes large.
The dissipation scheme handles both weak and strong instabilities with low
memory and computational requirements and no user intervention. However,
unlike the modal and spatial schemes, the dissipation scheme can slightly af-
fect the adjoint solution, although the spatial order of the damping is chosen
to be one order larger than of the adjoint calculation. This means that the
formal order of accuracy of the adjoint solver is unaffected by the addition of
the dissipation scheme. When applied to problems with large cell counts and
complex geometry the adjoint solver sometimes experiences stability issues.
These instabilities can be associated with small scale modes of unsteadiness
in the flow field and/or strong shear, and tend to be restricted to small and
isolated regions of the flow domain. Despite the spatial localization of these
instabilities, the linearity of the adjoint problem provides no intrinsic limit
on their growth during solution advancement. Therefore their presence can
disrupt the entire adjoint calculation even though the problem may occur in
just a few cells.
4
Shape Optimization for Aerodynamic
Efficiency using Adjoint Methods
While this can work well for some local, weak or unstable behavior, it can
have a high memory overhead.
The next scheme is the modal scheme. This involves a process of identify-
ing the particular details of the unstable growth patterns or modes. These
patterns are localized in space and are used to split the solution into parts
that have stable and unstable characteristics when advanced. The stable part
is advanced as usual, while the algorithm is designed to compensate for the
unstable part so that the overall calculation is stabilized.
The advantages of the modal scheme are that it handles strong instabilities,
formally solves the adjoint equations and has a low memory requirement.
However it may have a large number of modes to identify and manage during
the solution and any changes to solution parameters (under-relaxation, etc.)
can change the modes, therefore there is computational overhead associated
with this method.
The dissipation scheme is considered the most effective scheme so far for
solving adjoint problems, and opens the doors in ANSYS CFD to optimize a
wider variety of complex CFD simulations.
Sub-Modeling
The adjoint solution assumes that the turbulence is frozen, standard wall
functions are used and the solution is valid in the local region of the design
point flow solution. Combining this with the smoothing effect of the relative-
ly low resolution of the control points used to morph the design allows the
assumption that sub-modeling can be used.
Reducing the cell count of a model has the benefit of not only improving the
stability of the adjoint solution but also reducing the computational effort of
the solution. Therefore, it is additionally a useful tool to speed up the design
process when applied to external aerodynamic problems, as is described in
more detail in the case study below.
5
Shape Optimization for Aerodynamic
Efficiency using Adjoint Methods
Vehicle geometry
The vehicle selected as the basis for the case study was the DrivAer Fast-
back Detailed underbody with Mirrors with Wheels (F_D_wM_wW) provided
courtesy of TU Munich, Institute of Aerodynamics [5]. This was selected as it
has previously been the subject of a validation study comparing the analysis
results of ANSYS Fluent and ANSYS CFX to experimental data [6].
Figure 6 – DrivAer F_D_wM_wW Half Car Model
To reduce the computational overhead, the designers conducting the study
created a half-car symmetric model, shown in Figure 6. This method prevents
the final design from becoming asymmetric.
Drive Cycle
The aim of the study was to optimize the shape of the vehicle to reduce the
Coefficient of Drag (Cd) and therefore the CO2 emissions of the vehicle over
the drive cycle. Although Cd is usually quoted as a single value it will vary at
different speeds as the flow rate over the vehicle changes.
The first stage of defining the boundary conditions was to assess the influ-
ence of each of the vehicle speeds over the NEDC. As can be seen from the
graphical representation in Figure 7, the drive cycle contains various speeds
and durations. To assess their influence, the designers assumed a representa-
tive Cd and calculated the force acting on the vehicle for each speed and then
weighted the Cd based upon the duration.
Figure 7 – New European Driving Cycle
This assessment showed that 90% of the force on the vehicle occurred at
speeds 50, 70, 100 and 120 km/h. Therefore, they assumed that the influence
of the lower speeds would be negligible for the purpose of the optimization.
The model used in that study consisted of a tetrahedral mesh with 20 pris-
matic boundary layers on the surfaces of the car and road with an initial
height of 0.02mm. The model also had refinement regions surrounding and
downstream of the car to capture the flow structures away from the boundary
layer.
Figure 8 – Detail Model - Low Y-plus Hexcore Mesh
These mesh sizings were used as the basis for the detailed model used here.
However, in this study the designers created a hexcore mesh using ANSYS
Fluent Meshing which uses a similar prismatic boundary layer joined to a
Cartesian hexahedral outer domain with a layer of tetrahedrons. The hexcore
mesh was used in preference to tetrahedrons as it reduced the overall cell
6 count and improves the capture of vertical flow structures.
Shape Optimization for Aerodynamic
Efficiency using Adjoint Methods
The designers then solved the model with inlet flow velocities of the four ve-
hicle speeds of interest and corresponding moving wall boundary velocities
for the road and wheels. They calculated the solution using the k-omega tur-
bulence model and the pressure-based coupled solver within ANSYS Fluent.
The designers then adopted a solution strategy of varying the Courant
number to accelerate convergence was adopted. By varying the Courant
Figure 9 – Cd Convergence plot and final 100 Iteration Averages
for the Baseline Detailed Model number between initially 50 and then increasing 400 before finally reducing
to 50 convergence is achieved in 300 iterations. They assessed the Cd over
a further 100 iterations to account for any oscillations in the solution. The
monitor plots and average values of Cd over the final 100 iterations for the
four speeds can be seen in Figure 9.
To create this model the designers used the same Fluent Meshing surface
mesh and refinement regions as they used for the detailed model, but
meshed the model using polyhedral elements and boundary layer settings
they changed to give four layers and first layer thickness for high Y-plus. This
resulted in the mesh profile shown in Figure 10 which contains 7.1 Million
Figure 10 – Coarse Model - High Y-plus Polyhedral Mesh
polyhedral elements, giving a sixfold reduction in the mesh size.
In addition to reducing the size of the mesh, they further simplified the
turbulence model by changing it to the k-epsilon model with enhanced wall
functions. This change was facilitated by the high Y-plus boundary layer
matching the standard wall functions of the adjoint solver and had the added
benefit that the k-epsilon model can reduce the unsteadiness in the flow
solution, thus improving the convergence of the adjoint solution.
They set all boundary conditions as per the detailed model and solved the
model using the same solver parameters as the detailed model. From the
results shown in Figure 11, you can see that there is a reduction in the oscil-
lation of the solution, but also a reasonable difference in the Cd calculated.
On further investigation, this was found to be due to a difference in the reso-
lution of the flow separation point along the fastback area with the coarse
model.
The designers then subjected each of the flow solutions to an adjoint solver
calculation with the observable for the sensitivities set to be the drag
force acting on the non-rotating surfaces of the vehicle. The adjoint solu-
Figure 11 – Cd Convergence plot and final 100 Iteration Averages tion settings were left as the default for automatic Solution-Based Controls
for the Baseline Coarse Model Initialization and Auto-Adjust Controls. They set the modes to solve for 500
iteration to ensure convergence and that the resulting sensitivity fields were
7
Shape Optimization for Aerodynamic
Efficiency using Adjoint Methods
exported.
Once the sensitivity field for each of the speeds had been calculated, they
were combined and a design change calculated with a weighting based upon
their contribution to the drive cycle. The plot of in Figure 12 shows contours
of normal optimal displacement, showing in red where the geometry should
be “pulled” outwards and blue where the geometry should be “pushed”
inwards in order to improve the objective. From this, it can be seen that there
are a number of regions on the geometry that exhibit sensitivity to the drag
Figure 12 – Contours of normal Optimal Displacement
force. As areas such as the wheel arches and the underbody often have other
consideration and functions than aerodynamic efficiency, the area selected
for modification here is the rear portion of the bodywork behind the rear
wheel arch.
As these regions are away from the area in which the flow separates from the
fastback, it can be considered that the adjoint sensitivities will be similar
between the two models and thus the sub-modeling approach used.
The next phase is to follow the iterative workflow shown in Figure 1 to solve
the flow solutions, then adjoint solutions and morphing the geometry accord-
ingly. For this case study the optimization loop was repeated for 7 itera-
tions and in each case retaining the sensitivity field obtained for use in the
detailed model optimization. Figure 13 shows the output of the drag force
observable for the rear of the car during the optimization. This highlights
Figure 13 – Plot showing the Drag force observable change during that although the rear of the car exhibits high sensitivity to drag force, the
the Optimization magnitude of the force is only approximately 15% of the total drag force on
the vehicle.
The table below shows the Cd values over the final 100 iterations for the
baseline geometry and the final iteration of the modified geometry. You can
see a comparison of the initial geometry and the final modified geometry in
Figure 14.
We can then run the modified detailed model using the k-omega settings as
before and the results can be seen in Figure 15 which shows a comparison
between the detailed baseline and modified models. From these plots we can
see that the modified model gives a reduction in Cd of between 3.9% and
6.6%. The plot in Figure 16 showing the iso-surface of total pressure high-
8 lights the reduction of the wake structure that resulted in the improvements
in Cd.
Shape Optimization for Aerodynamic
Efficiency using Adjoint Methods
Conclusions
The adjoint solver in ANSYS CFD provides a powerful tool that can optimize
even complex flow systems in non-intuitive directions with little user input.
Using sub-modeling reduces the complexity and computational overhead of
using the adjoint solver on external aerodynamics flow problems. Combining
an adjoint solver and the latest mesh morphing technology can help you op-
timize your product designs for energy efficiency, satisfying federal regula-
tions and international and customer demand for better, greener products.
REFERENCES
Figure 15 – Cd Convergence plot and final 100 Iteration Averages 1. ANSYS FLUENT 16 - Adjoint Solver Module Manual, ANSYS, Inc.,
for the Baseline and Modified Detailed Model Canonsburg, PA, 2015.
2. D. C. Hill, The Automatic Generation of Adjoint Solutions for a General
Purpose Flow Solver, 46th AIAA Aerospace Sciences Meeting and Exhibit,
January 2008, Reno, Nevada
3. Petrone, G., Hill, C., Single-objective and Multi-objective Robust
Optimization of Airfoils Using Adjoint Solutions, 44th AIAA Fluid
Dynamics Conference, June 16-20. Atlanta, 2014. AIAA-2014-3173
4. Petrone, G., Hill, C., Biancolini, M., Track by Track Robust Optimization
of a F1 Front Wing Using Adjoint Solutions and Radial Basis Functions,
44th AIAA Fluid Dynamics Conference, June 16-20. Atlanta, 2014.
AIAA-2014-3174
5. http://www.aer.mw.tum.de/abteilungen/automobilaerodynamik/drivaer/
Figure 16 – Plot showing an Iso-surface of Total Pressure = 0 Pa
6. T. Frank, B. Gerlicher, J. Abanto, DrivAer - Aerodynamic Investigations for a
coloured by Vorticity Magnitude for the 120 km/h vehicle speed New Realistic Generic Car Model using ANSYS CFD, Automotive Simulation
World Congress 2013
ANSYS, Inc. If you’ve ever seen a rocket launch, flown on an airplane, driven a car, used a
Southpointe computer, touched a mobile device, crossed a bridge or put on wearable technol-
2600 ANSYS Drive ogy, chances are you’ve used a product where ANSYS software played a critical
Canonsburg, PA 15317 role in its creation. ANSYS is the global leader in engineering simulation. We help
U.S.A.
the world’s most innovative companies deliver radically better products to their
724.746.3304
[email protected] customers. By offering the best and broadest portfolio of engineering simulation
software, we help them solve the most complex design challenges and engineer
products limited only by imagination. Visit www.ansys.com for more information.