Parallel computing on GPU for the numerical simulation of the gas-dynamic interaction of a particle with a supersonic shock layer


Аuthors

Sposobin A. V.

Moscow Aviation Institute (National Research University), 4, Volokolamskoe shosse, Moscow, А-80, GSP-3, 125993, Russia

e-mail: spise@inbox.ru

Abstract

This article is devoted to numerical simulation of supersonic flows with admixture of large solid particles on graphics processing units (GPU). The mathematical modeling of two-phase flows is widely covered in modern scientific literature. This is due to the high practical significance of research on this topic, the high complexity and high cost to perform real experiments, as well as the intensive development of mathematical tools and computer technology.

As shown by real experiments and their numerical simulation in a supersonic flow around a blunt body even a single large particle moving against the incoming flow crosses the shock front and significantly changes the entire structure of the gas flow in the shock layer. In this case, local areas of especially intense heating appear on the surface of the body. The mathematical model for a detailed study of ongoing processes is based on the sliding adaptive Cartesian grids method using separate local computational grids for each particle moving along the main grid. This makes it possible, adjusted for the two-dimensional nature of the model, to study the movement of particles along complex trajectories, as well as the collective gas-dynamic interaction of a group of particles with a shock layer. The viscous gas flow is described by a system of two-dimensional unsteady Navier-Stokes equations. The finite volume method based on the second-order scheme is used for its numerical solution. The calculation of inviscid flows is carried out according to the AUSM+ scheme (Advection Upstream Splitting Method Plus). The implementation of boundary conditions on a solid surface is carried out by the ghost cell-based immersed boundary method. The explicit three-stage Runge-Kutta method is used in this study. Cartesian grids have the advantage of being easy to implement in software and provide a detailed flow structure, but requires large computational time and memory. This problem is especially acute when calculating viscous flows, since it is required to resolve the flow in a thin boundary layer near the body surface with high accuracy. To do this, one has to choose square cells of small size, the number of which is rapidly increasing. In the computational experiments performed, the total number of computational grid cells could reach several million. The implementation of an explicit method for solving a system of gas dynamics equations has a high potential for parallelizing calculations. The use of graphics processing units, despite some labor costs for optimizing the distribution of memory data and adapting algorithms and data structures to the features of the GPU, as a result, can reduce the time of computational experiments by dozens of times. The software implementation is based on the use of OpenCL, an open standard for heterogeneous computing. It is still less popular than nVidia’s proprietary CUDA technology, on the other hand, the code developed on OpenCL can be executed on central and graphic processors of various manufacturers. The article provides a brief overview of OpenCL technology. The structure of a typical application is described, which includes a control host program and kernel code in the OpenCL C language, designed to work on devices. The classification of used memory types is given. The difficulties arising in practice of using the OpenCL technology and the methods found by the author to overcome them are described. The main code for the implementation of the described algorithms was developed in the C++ programming language using the OpenCL C++ API, which greatly simplifies development compared to the OpenCL API for the C language. The calculation of the reference problem of the numerical modeling the supersonic viscous flow around a blunt body on various Intel, AMD and nVidia hardware using double-precision calculations is carried out. More than 20x acceleration of calculation on the graphics processor units in comparison with the central one was obtained. The problem of two-dimensional modeling of the motion of three large particles in the shock layer near the surface of a circular cylinder is solved. Schlieren flow images are presented, as well as curves of fluctuations of the gas pressure and heat flux on the streamlined surface.

Keywords:

numerical simulation, parallel computation on GPU, OpenCL technology, adaptive sliding Cartesian grids, supersonic dusty flows around blunt bodies

References

  1. Molleson G.V., Stasenko A.L. Gasdynamic Acceleration of Microparticles and Their Interaction with a Solid Body, High Temperature (Engl. Transl.), 2017, vol. 55, no. 6, pp. 906–913. DOI: 10.7868/S0040364417060096
  2. Mikhatulin D.S., Polezhaev Y.V., Reviznikov D.L. Investigation of Failure of Carbon Heat-Shielding Material under Conditions of Flight in Dusty Atmosphere. High Temperature (Engl. Transl.), 2003, vol. 41, pp. 88–94. DOI: 10.1023/ A:1022384806647
  3. Verevkin A.A., Tsirkunov Yu.M. Dvukhfaznoe techenie gaza s chastitsami v sverkhzvukovoi udarnoi aerodinamicheskoi trube. Teplovye protsessy v tekhnike, 200, vol. 1, no. 10, pp. 420−423.
  4. Zharova I.K., Kuznetsov G.V., Maslov E.A. Techenie i teplomassoobmen pri vzaimodeistvii vysokotemperaturnogo dvukhfaznogo potoka s plastinoi. Teplovye protsessy v tekhnike, 2011, vol. 3, no. 10, pp. 461−470.
  5. Reviznikov D.L., Sukharev T.Yu. Giperzvukovoe obtekanie zatuplennykh tel v usloviyakh atmosfery Zemli i Marsa. Sravnitel’nyi analiz matematicheskikh modelei. Teplovye protsessy v tekhnike, 2018, vol. 10, no. 1–2, pp. 5−15.
  6. Egorov I.V., Kunsik Kong, Novikov A.V. Modelirovanie obtekaniya nosovoi chasti spuskaemogo kosmicheskogo apparata v atmosfere Marsa. Uchenye zapiski TsAGI, 2021, vol. 52, no. 4, pp. 20−33.
  7. Nikitin P.V. Nekotorye aspekty teplofizicheskoi modeli formirovaniya zashchitnykh pokrytii sverkhzvukovym geterogennym potokom. Teplovye protsessy v tekhnike, 2010, vol. 2, no. 7, pp. 308−319.
  8. Ershova T.V., Mikhatulin D.S., Reviznikov D.L., Sposobin A.V., Vinnikov V.V. Numerical simulation of heat and mass transfer between heterogeneous flow and an obstacle. Computational Thermal Sciences, 2011, vol. 3, no. 1, pp. 15−30.
  9. Vinnikov V.V., Dombrovskii L.A., Reviznikov D.L., Sposobin A.V. Modelirovanie perenosa tepla izlucheniem pri obtekanii pregrady sverkhzvukovym potokom gaza so vzveshennymi chastitsami. Teplovye protsessy v tekhnike, 2012, vol. 4, no. 7, pp. 312–318.
  10. Mironov A.A., Isaev S.A., Popov I.A., Aksyanov R.A., Skrypnik A.N. Povyshenie effektivnosti aviatsionnykh teploobmennykh apparatov. Izvestiya vysshikh uchebnykh zavedenii. Aviatsionnaya tekhnika, 2020, vol. 63, no. 1, pp. 147−154. DOI: 10.3103/S1068799820010213
  11. Fleener W.A., Watson R.H. Convective Heating in Dust-Laden Hypersonic Flows. AIAA Paper, 1973, no. 73, p. 761. DOI: 10.2514/6.1973-761
  12. Holden M.S., Gustafson G.Q., Duryea G.R, Hudack L.T. An Experimental Study of Particle-Induced Convective Heating Augmentation. AIAA Pape, 1976, no. 76, p. 320. DOI: 10.2514/6.1976-320
  13. Varaksin A.Yu. Gas-Solid Flows Past Bodies. High Temperature (Engl. transl.), 2018, vol. 56, no. 2, pp. 275–295. DOI: 10.7868/S0040364418020175
  14. Reviznikov D.L., Sposobin A.V., Ivanov I.E. A change in the structure of a flow under the action of highly inertial particle when a hypersonic heterogeneous flow passes over a body. High Temperature (Engl. transl.). 2018, vol. 56, no. 6, pp. 884−889. DOI: 10.31857/S0040364 40003569-9
  15. Sposobin A.V., Reviznikov D.L., Ivanov I.E., Kryukov I.A. Kolebaniya davleniya i teplovogo potoka, indutsirovannye gazodinamicheskim vzaimodeistviem vysokoinertsionnoi chastitsy s udarnym sloem. Izvestiya vysshikh uchebnykh zavedenii. Aviatsionnaya tekhnika, 2020, vol. 6, no. 4, pp. 677−685. DOI: 10.3103/S1068799820040157
  16. Sposobin A., Reviznikov D. Impact of High Inertia Particles on the Shock Layer and Heat Transfer in a Heterogeneous Supersonic Flow around a Blunt Body. Fluids, 2021, vol. 6, no. 11, p. 406. DOI: 10.3390/fluids6110406
  17. Nekrasov K.A., Potashnikov S.I., Boyarchenkov A.S., Kupryazhkin A.Ya. Parallel’nye vychisleniya obshchego naznacheniya na graficheskikh protsessorakh (General-purpose parallel computing on graphics processors). Yekaterinburg: Izd-vo Ural’skogo universiteta, 2016, 106 p.
  18. Semenov S.A., Reviznikov D.L. Effektivnoe ispol’zovanie programmiruemykh graficheskikh protsessorov v zadachakh molekulyarno-dinamicheskogo modelirovaniya. Sistemy i sredstva informatiki, 2017, vol. 27, no. 4, pp. 109−121. DOI: 10.14357/08696527170408
  19. Morozov A.Yu., Reviznikov D.L. Modelling of dynamic systems with interval parameters on graphic processors. Programmnaya inzheneriya, 2019, vol. 10, no. 2, pp. 69–76. DOI: 10.17587/prin.10.69-76
  20. Reviznikov D.L., Semenov S.A. Osobennosti molekulyarno-dinamicheskogo modelirovaniya nanosistem na graficheskikh protsessorakh. Programmnaya inzheneriya, 2013, no. 2, pp. 31–35.
  21. Boreskov A.V., Kharlamov A.A. Osnovy raboty s technologiei CUDA (Basics of working with CUDA technology). Moscow: DMK Press, 2010, 232 p.
  22. Sanders Dzh., Kendrot E. Tekhnologiya CUDA v primerakh. Vvedenie v programmirovanie graficheskikh protsessov (CUDA by Example. An Introduction to General-Purpose GPU Programmong) / translated by Slinkin A.A. Moscow: DMK Press, 2011, 232 p.
  23. Antonyuk V.A. OpenCL. Otkrytyi yazyk dlya parallel’nykh programm (OpenCL. Open language for parallel programs) / fizicheskii fakul’tet MGU im. M.V. Lomonosova. Moscow, 2017, 88 p.
  24. Molchanov A.M. Matematicheskoe modelirovanie zadach gazodinamiki i teplomassoobmena (Mathematical Modeling of Problems of Gas Dynamics and Heat and Mass Transfer). Moscow: Izd-vo MAI, 2013, 206 p.
  25. Kitamura K., Eiji S. Towards shock-stable and accurate hypersonic heating computations: A new pressure flux for AUSM-family schemes. Journal of Computation Physics, 2013, vol. 245, pp. 62−83. DOI: 10.1016/j.jcp.2013.02.046
  26. Vinnikov V.V., Reviznikov D.L. Metod pogruzhennoi granitsy dlya rascheta sverkhzvukovogo obtekaniya zatuplennykh tel na pryamougol’nykh setkakh. Trudy MAI, 2007, no. 27, p. 13. URL: http://trudymai.ru/eng/published. php?ID=34018
  27. Gaster B., Howes L. The OpenCL C++ Wrapper API. Version: 1.2, KhronosOpenCL Working Group, 2012, 83 p. URL: https://www.khronos.org/registry/OpenCL/specs/opencl-cplusplus-1.2.pdf (accessed: 22.06.2022)
  28. Gaster B., Howes L., Kaeli D., Mistry P., Schaa D. Heterogeneous Computing with OpenCL. Revised OpenCL 1.2 Edition. Morgan: Kaufmann, 2012, 308 p.
  29. Sposobin A.V. Bessetochnyi algoritm rascheta sverkhzvukovykh techenii vyazkogo teploprovodnogo gaza. Trudy MAI, 2021, no. 121. URL: http://trudymai.ru/ eng/publicshed.php?ID=162656

mai.ru — informational site of MAI

Copyright © 2009-2024 by MAI