Abstract
This work proposes a new topology optimization formulation to subsonic compressible flows. Compressible flows can be seen in many aerodynamic problems and optimization techniques can be used to improve designs of wings, diffusers, and other applications. In this work, the compressible Navier-Stokes equations are used coupled with a density-based material model. The effects of the material model are shown for both the momentum and energy equations. Two objective functions are considered, the entropy variation in a control volume and the entropy generation. The algorithm is implemented by a finite element model to solve the state equations. The pyadjoint libraries are used to perform the automatic sensitivity derivation and an internal point optimizer is used to update the design variable. The algorithm is evaluated by performing the optimization of 2D domains and a 3D diffuser. The results show optimized designs with reduced entropy generation.
Similar content being viewed by others
References
Alonso DH, de Sá LFN, Saenz JSR, Silva ECN (2018) Topology optimization applied to the design of 2D swirl flow devices. Struct Multidiscip Optim 58(6):2341–2364
Alonso DH, de Sá LFN, Saenz JSR, Silva ECN (2019) Topology optimization based on a two-dimensional swirl flow model of Tesla-type pump devices. Comput Math Appl 77(9):2499–2533
Amestoy PR, Duff IS, L’Excellent J-Y, Koster J (2001) A fully asynchronous multifrontal solver using distributed dynamic scheduling. SIAM J Matrix Anal Appl 23(1):15–41
Anderson J (2003) Modern compressible flow: with historical perspective. Aeronautical and Aerospace Engineering Series. McGraw-Hill Education, New York
Anderson W, Venkatakrishnan V (1999) Aerodynamic design optimization on unstructured grids with a continuous adjoint formulation. Computers & Fluids 28(4-5):443–480
Avellaneda J, Bataille F, Toutant A, Flamant G (2020) Entropy generation minimization in a channel flow: application to different advection-diffusion processes and boundary conditions. Chem Eng Sci 220:115601
Blazek J (2001) Computational fluid dynamics: principles and applications. Elsevier, Amsterdam
Borgnakke C, Sonntag R (2008) Fundamentals of thermodynamics. Wiley
Borrvall T, Petersson J (2003) Topology optimization of fluids in Stokes flow. Int J Numer Methods Fluids 41(1):77–107
Burgreen G, Baysal O (1994) Three-dimensional aerodynamic shape optimization of wings using sensitivity analysis. In: 32nd Aerospace Sciences Meeting and Exhibit, Reston, Virigina. American Institute of Aeronautics and Astronautics
Cao H, Blom G (1996) Navier-Stokes/genetic optimization of multi-element airfoils. In: 14th Applied Aerodynamics Conference, Reston, Virigina. American Institute of Aeronautics and Astronautics
Castro C, Lozano C, Palacios F, Zuazua E (2007) Systematic continuous adjoint approach to viscous aerodynamic design on unstructured grids. AIAA J 45(9):2125–2139
Challis VJ, Guest JK (2009) Level set topology optimization of fluids in Stokes flow. Int J Numer Methods Eng 79(10):1284–1308
Cummings RM, Yang H, Oh Y (1995) Supersonic, turbulent flow computation and drag optimization for axisymmetric afterbodies. Computers & fluids 24(4):487–507
Dasgupta D, Michalewicz Z (1997) Evolutionary algorithms in engineering applications. Springer, Berlin
de Villiers E, Othmer C (2012) Multi-objective adjoint optimization of intake port geometry. Technical report, SAE Technical Paper
Dilgen CB, Dilgen SB, Fuhrman DR, Sigmund O, Lazarov BS (2018) Topology optimization of turbulent flows. Comput Methods Appl Mech Eng 331:363–393
Economon TD, Palacios F, Alonso JJ (2013) A viscous continuous adjoint approach for the design of rotating engineering applications. In: 21st AIAA computational fluid dynamics conference. American Institute of Aeronautics and Astronautics, Reston, pp 1–19
Economon TD, Palacios F, Alonso JJ (2015) Unsteady continuous adjoint approach for aerodynamic design on dynamic meshes. AIAA J 53(9):2437–2453
Elliott J, Peraire J (1996) Aerodynamic design using unstructured meshes. In: Fluid dynamics conference, number June. American Institute of Aeronautics and Astronautics, Reston, pp 1–13
Evgrafov A (2005) The limits of porous materials in the topology optimization of stokes flows. Appl Math Optim 52(3):263–277
Evgrafov A (2006) Topology optimization of slightly compressible fluids. ZAMM 86(1):46–62
Farrell PE, Ham DA, Funke SW, Rognes ME (2013) Automated derivation of the adjoint of high-level transient finite element programs. SIAM J Sci Comput 35(4):C369–C393
Funke SW, Farrell PE (2013) A framework for automated PDE-constrained optimisation. arXiv:1302.3894
Gersborg-Hansen A, Sigmund O, Haber R (2005) Topology optimization of channel flow problems. Struct Multidiscip Optim 30(3):181–192
Jameson A (1988) Aerodynamic design via control theory. J Sci Comput 3(3):233–260
Jameson A, Martinelli L, Pierce N (1998) Optimum aerodynamic design using the Navier-Stokes equations. Theor Comput Fluid Dyn 10(1-4):213–237
John V (2004) Reference values for drag and lift of a two-dimensional time-dependent flow around a cylinder. Int J Numer Methods Fluids 44(7):777–788
John V, Matthies G (2001) Higher-order finite element discretizations in a benchmark problem for incompressible flows. Int J Numer Methods Fluids 37(8):885–903
Lapointe C, Christopher JD, Wimer NT, Hayden TR, Rieker GB, Hamlington PE (2017) Optimization for internal turbulent compressible flows using adjoints. In: 23rd AIAA computational fluid dynamics conference, number June. American Institute of Aeronautics and Astronautics, Reston, pp 1–8
Logg A, Wells GN, Book TF (2012) Automated solution of differential equations by the finite element method, volume 84 of Lecture notes in computational science and engineering. Springer, Berlin
Morgan H, Scott LR (2018) Towards a Unified Finite Element Method for the Stokes Equations. SIAM J Sci Comput 40(1):A130–A141
Moukalled F, Mangani L, Darwish M (2015) The finite volume method in computational fluid dynamics: an advanced introduction with OpenFOAM®; and Matlab. Fluid Mechanics and Its Applications. Springer International Publishing
Nadarajah S, Jameson A (2000) A comparison of the continuous and discrete adjoint approach to automatic aerodynamic optimization. American Institute of Aeronautics and Astronautics, Reston
Nielsen EJ, Anderson WK (1999) Aerodynamic design optimization on unstructured meshes using the Navier-Stokes equations. AIAA J 37(11):1411–1419
Olesen LH, Okkels F, Bruus H (2006) A high-level programming-language implementation of topology optimization applied to steady-state Navier-Stokes flow. Int J Numer Methods Eng 65(7):975–1001
Othmer C (2008) A continuous adjoint formulation for the computation of topological and surface sensitivities of ducted flows. Int J Numer Methods Fluids 58(8):861–877
Oyama A, Obayashi S, Nakahashi K, Nakamura T (1999) Euler/Navier-Stokes Optimization of Supersonic Wing Design Based on Evolutionary Algorithm. AIAA J 37(10):1327–1328
Papadimitriou D, Giannakoglou K (2007) A continuous adjoint method with objective function derivatives based on boundary integrals, for inviscid and viscous flows. Computers & Fluids 36(2):325–341
Papoutsis-Kiachagias EM, Giannakoglou KC (2016) Continuous adjoint methods for turbulent flows, applied to shape and topology optimization: industrial applications. Arch Comput Methods Eng 23(2):255–299
Pingen G, Maute K (2010) Optimal design for non-Newtonian flows using a topology optimization approach. Comput Math Appl 59(7):2340–2350
Pritchard P (2010) Fox and McDonald’s introduction to fluid mechanics, 8th edn. Wiley, Hoboken
Quagliarella D, Dell A (1994) Genetic algorithms applied to the aerodynamic design of transonic airfoils. In: 12th applied aerodynamics conference, vol 32. American Institute of Aeronautics and Astronautics, Reston, pp 686–693
Reddy JN, Gartling DK (2010) The finite element method in heat transfer and fluid dynamics. CRC Press, Boca Raton
Reuther JJ, Jameson A, Alonso JJ, Rimllnger MJ, Saunders D (1999) Constrained multipoint aerodynamic shape optimization using an adjoint formulation and parallel computers, Part 2. J Aircr 36(1):61–74
Romero JS, Silva ECN (2014) A topology optimization approach applied to laminar flow machine rotor design. Comput Methods Appl Mech Engrg 279:268–300
Sá L. F. N., Novotny AA, Romero JS, Silva ECN (2017) Design optimization of laminar flow machine rotors based on the topological derivative concept. Struct Multidiscip Optim 56(5):1013–1026
Sá LFN, Amigo RCR, Novotny AA, Silva ECN (2016) Topological derivatives applied to fluid flow channel design optimization problems. Struct Multidiscipl Optim 54(2):249–264
Sá LFN, Romero JS, Horikawa O, Silva ECN (2018) Topology optimization applied to the development of small scale pump. Struct Multidiscip Optim 57(5):2045–2059
Sá LFN, Yamabe PVM, Souza BC, Silva ECN (2021) Topology optimization of turbulent rotating flows using Spalart–Allmaras model. Comput Methods Appl Mech Eng 373:113551
Wächter A (2009) Short tutorial: getting started with Ipopt in 90 Minutes. In: Toledo UN, Schenk O, Simon HD, Sivan (eds) Combinatorial Scientific Computing, Dagstuhl, Germany. Schloss Dagstuhl - Leibniz-Zentrum fuer Informatik, Germany
Wáchter A, Biegler LT (2006) On the implementation of an interior-point filter line-search algorithm for large-scale nonlinear programming. Math Program 106(1):25–57
Yoon GH (2016) Topology optimization for turbulent flow with Spalart–Allmaras model. Comput Methods Appl Mech Eng 303:288–311
Yoon GH (2020) Topology optimization method with finite elements based on the k- e turbulence model. Comput Methods Appl Mech Eng 361:112784
Funding
The authors gratefully acknowledge support of the RCGI—Research Centre for Gas Innovation, hosted by the University of São Paulo (USP) and sponsored by FAPESP—São Paulo Research Foundation (2014/50279-4) and Shell Brasil, and the strategic importance of the support given by ANP (Brazil’s National Oil, Natural Gas and Biofuels Agency) through the R&D levy regulation. The third author thanks the financial support of CNPq (National Council for Research and Development) under grant 302658/2018-1.
Author information
Authors and Affiliations
Corresponding author
Ethics declarations
Conflict of interest
The authors declare that they have no conflict of interest.
Additional information
Responsible Editor: Felipe A. C. Viana
Publisher’s note
Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
Replication of results
Most of the software environment used in this work can be found in the docker container provided by dolfin-adjoint (available in http://www.dolfin-adjoint.org/en/latest/download/). The tutorials presented there may also help with the implementation.
In order to reproduce the results the following steps are needed:
(1) Define a mesh;
(2) Define the function spaces of the state variables (u,p,h);
(3) Define the function spaces of the design variable (α);
(4) Define the boundary conditions;
(5) Define the state equations (Navier-Stokes coupled with the energy equation);
(6) Solve the state equations, which causes pyadjoint to annotate the steps in the tape;
(7) Define the objective function;
(8) Calculate the initial objective function value;
(9) Start the optimization loop:
● Solve the state equations for current α;
● Calculate the current objective function value;
● Call pyadjoint to mount and solve the adjoint model;
● Pass the sensitivity to the optimizer (IPOpt);
● Update the design variable (α):
- If the convergence criteria is met return;
_ Else: restart the optimization loop;
Appendices
Appendix A: Weak form derivation
In this appendix, the weak form derivation of the momentum and energy equations are presented.
1.1 A.1 Momentum equation
By using the “weak-form Galerkin” method, (1) is multiplied by a test function v:
The integration by parts on the second term gives:
The integration by parts on the third term:
The integration by parts on the fourth term:
The integration by parts on the fifth term:
Finally, by substituting all the integration by parts in the original equation the following weak form is obtained:
1.2 A.2 Energy equation
By using the Galerkin method, (4) is multiplied by a test function vh:
Then, integrating by parts on the second term:
The integration by parts on the third term:
Finally, by substituting all the integration by parts in the original equation, the following weak form is obtained:
Appendix B: Finite element matrix derivation
This section shows the matrix assemble by using the finite element method to solve the state equations. This derivation follows the steps shown in Reddy and Gartling (2010). Suppose that the relation between approximated continuous distributions (ui,p, h) and the nodal values (ui,P, H) is given by:
where Ψ, Θ, and Ξ are vectors of interpolation (or shape) functions, ui, P, and H are vectors of nodal values of velocity components, pressure, and enthalpy, respectively.
Substitution of (34), (35), and (36) into the state equations weak forms results in the following finite element equations:
Continuity
The matrix R representing the density is defined as:
Momentum
Energy
By replacing the approximation for pressure and velocity fields obtained through finite element interpolation functions in the weak formulation, the algebraic equations for the finite element method are obtained. The matrix coefficients per element are given by:
The global algebraic system, considering two-dimensional case, is defined in the matrix form as:
where u is the velocity column vector with all directions (\(\mathbf {u} = \{\mathbf {u}_{1} \mathbf {u}_{2}\}^{T}\)). This resulting system is non-symmetrical and highly non-linear.
Appendix C: Material model assessment
In this section, the behavior of the material model is verified by comparing the flows calculated by a body-fitted mesh case and by an equivalent case with the domain represented by the material model. As explained in Section 3.1, the very low velocities in the solid region reduces the energy equation to a Laplacian equation on enthalpy (see 13). If there are no heat generation and no other source terms in the energy equation, this Laplacian of enthalpy is equal to zero. By using the divergence theorem, this equation can be interpreted as no heat going in or out of the solid region. Thus, the higher the velocity penalization on the momentum equations, the lower are the terms with velocity (u) in the energy equation, and then, the solid region defined by the design variable becomes closer to an adiabatic material.
In Fig. 14, the two domains used for a numerical comparison are presented. The body fitted case with definitions of boundary conditions can be seen in Fig. 14a. These boundary conditions have the same definition as the cases previously presented in the text: specified velocity and enthalpy at the inlet, zero velocity, adiabatic condition at the walls, and specified pressure at the outlet. In Fig. 14b, this same domain is represented by using the material model presented in the paper. The boundary conditions are the same, and the contour is defined by the material model. The boundary conditions at the domain external walls are defined as zero velocity and adiabatic.
The black arrow indicates a cut performed in both cases to verify the state variables profile in that section. The body fitted case is calculated without the material model penalization, and the extended case is calculated with the penalization term, with the value for κmax varying from 103 to 106.
In Fig. 15, comparisons of the state variables profile at the cut section can be seen. The black solid line indicates the profile in the body fitted case and the colorful lines indicate the cases with penalization. As can be seen, the higher the penalization, the closer to the body fitted case. It is important to notice that the profiles will not match perfectly because velocity will never be exactly zero in the solid region and also the penalized cases do not have a perfectly smooth contour. This contour is jagged and depends on the mesh refinement. Even so, it can be seen that this material model exhibits a good representation of adiabatic boundaries.
Appendix D: Regularization term analysis
In this appendix, the effects of the regularization term Jκ are further analyzed by considering the double channel Stokes problem presented by Borrvall and Petersson (2003) with:
-
μ = 1.0[Pa ⋅ s];
-
κmin = 2.5μ10− 4;
-
κmax = 2.5μ104;
-
1[m] × 1[m] mesh with 100 × 100 triangular elements;
-
their energy dissipation objective function without Jκ, i.e. \(J_{ed}={\int \limits }_{{\varOmega }} \mu \nabla \boldsymbol {u} : \nabla \boldsymbol {u} d{\varOmega }\),
and by testing different values of q = [1, 10, 100, 1000]. This is done in order to show that increasing the q value without the regularization is not enough to remove the gray regions.
The results are shown in Fig. 16. It is shown that even though the topologies minimize the viscous energy dissipation functional (Jed), they still present many gray areas. Moreover, even when high values of q are used, the topologies are still blurred by intermediate values of α. These grays areas are removed when the regularization Jκ is used.
Appendix E: : Sensitivity verification via finite differences
This section shows the finite difference verification of the automatic differentiated sensitivities calculated by the pyadjoint library. The central finite difference is used, which is given by:
where the perturbation used is h = 1 ⋅ 10− 6.
This verification considers the domain shown in Fig. 9 and an uniform design variable distribution of α = 0.5. The chosen trial points are presented in Fig. 17. Given that two objective functions are used in this work the results of the sensitivity verification are split into two tables.
Table 7 shows the sensitivity comparison between the value calculated by pyadjoint and the value obtained via finite differences for the entropy variation functional (15). The sensitivities are almost identical, and the highest discrepancy occurs for sensitivity values close to zero, such as for trial point 14 which presents a difference of − 3.23%.
Table 8 shows the sensitivity comparison between the value calculated by pyadjoint and the value obtained by finite differences for the entropy generation functional (16) with the outlet velocity functional (22). The sensitivities are in good agreement and the highest discrepancy occurs for trial point 8 which presents a difference of 0.0085%.
Rights and permissions
About this article
Cite this article
Sá, L.F.N., Okubo, C.M. & Silva, E.C.N. Topology optimization of subsonic compressible flows. Struct Multidisc Optim 64, 1–22 (2021). https://doi.org/10.1007/s00158-021-02903-5
Received:
Revised:
Accepted:
Published:
Issue Date:
DOI: https://doi.org/10.1007/s00158-021-02903-5