中文版 | English
题名

浮点数精度在格子Boltzmann仿真中的影响

其他题名
The impact of floating point precision on lattice Boltzmann simulation
姓名
姓名拼音
DENG Fudong
学号
12132389
学位类型
硕士
学位专业
0801 力学
学科门类/专业学位类别
08 工学
导师
万敏平
导师单位
力学与航空航天工程系;力学与航空航天工程系
论文答辩日期
2024-05-14
论文提交日期
2024-06-24
学位授予单位
南方科技大学
学位授予地点
深圳
摘要

工业软件是工业数字化的基础和核心,是我国“十四五”规划中大力发展的基础软件和核心技术之一。格子Boltzmann方法(LBM)从介观的角度求解问题,由于其易于并行的算法结构以及易于实现等优点逐渐深入地应用于工业领域。基于格子Boltzmann方法的模拟仿真工业软件不断追求更高的模拟精度和更快的模拟速度。在人工智能训练过程中,使用某些架构的GPU通过采用半精度浮点数(FP16)以及混合精度来加速计算,这为LBM工业软件加速计算提供了思路。因此,研究浮点数精度对于格子Boltzmann方法的影响,对于LBM应用于工业界中的程序开发以及性能提升都具有十分重要的意义。

目前,关于提升格子Boltzmann方法结果精度的研究主要集中于单相流中计算密度分布函数(DDF)的扰动项方法(DDF-Shift),该方法对于两相流中的应用研究比较匮乏。本文将DDF-Shift方法扩展到两相流中的颜色梯度模型并对其分别评估不同精度下的结果。

研究过程中开发了基于CUDA语言的模拟多孔介质内复杂流动的格子Boltzmann方法高性能GPU程序。通过悬浮液滴测试、接触角测试、毛细管入侵以及两相泊肃叶流等基准算例,验证了开发的数字岩芯模拟程序对两相流模拟的可靠性。本研究进一步分析了不同精度对以上基准算例模拟结果的影响。结果表明,悬浮液滴测试、接触角测试、毛细管入侵算例中与速度弱相关的统计结果单精度和双精度相比误差在1%以内;而两相泊肃叶流中对于速度的结果双精度与单精度下之间误差在2~5%之间,应用了DDF-Shift方法的模型单精度的模拟结果有较好的提升,与双精度结果误差为0.001%。随后将研究扩展至实际多孔介质渗流直接数值模拟中,选用真实数字岩芯结构,在考虑不同精度下对多孔介质绝对渗透率模拟以及多孔介质中湿润性、毛细管数对驱替模拟结果的影响。最终结果显示DDF-Shift方法在复杂几何下能提升单相流统计流量结果精度以及稳定性,而在两相流驱替模拟实验中,驱替达到稳态时两相分布结果单精度双精度结果相差较小,误差在2%以内。

关键词
语种
中文
培养类别
独立培养
入学年份
2021
学位授予年份
2024-06
参考文献列表

[1] 杨春晖, 刘梦玥, 陈平, 等. 从“十四五”规划看工业软件发展蓝图[J]. 软件导刊, 2022, 21:21-25.
[2] RYOO S, RODRIGUES C I, BAGHSORKHI S S, et al. Optimization principles and application performance evaluation of a multithreaded GPU using CUDA[C]//Proceedings of the 13th ACM SIGPLAN Symposium on Principles and practice of parallel programming. 2008: 73-82.
[3] AKSNES E O, ELSTER A C. Porous Rock Simulations and Lattice Boltzmann on GPUs[C]//International Conference on Parallel Computing. 2009.
[4] OBRECHT C, KUZNIK F, TOURANCHEAU B, et al. The TheLMA project: Multi-GPUimplementation of the lattice Boltzmann method[J]. The International Journal of High Performance Computing Applications, 2011, 25(3): 295-303.
[5] DE OLIVEIRA JR W B, LUGARINI A, FRANCO A T. Performance analysis of the latticeBoltzmann method implementation on GPU[C]//Proceedings of the XL Ibero-Latin-American Congress on Computational Methods in Engineering, ABMEC, Natal, Brazil. 2019: 11-14.
[6] KUZNIK F, OBRECHT C, RUSAOUEN G, et al. LBM based flow simulation using GPUcomputing processor[J]. Computers & Mathematics with Applications, 2010, 59(7): 2380-2392.
[7] GRAY F, BOEK E. Enhancing computational precision for lattice Boltzmann schemes in porous media flows[J]. Computation, 2016, 4(1): 11.
[8] SKORDOS P A. Initial and boundary conditions for the lattice Boltzmann method[J]. Physical review E, 1993, 48(6): 4823.
[9] HARDY J, POMEAU Y, DE PAZZIS O. Time evolution of a two-dimensional model system. I. Invariant states and time correlation functions[J]. Journal of Mathematical Physics, 1973, 14(12): 1746-1759.
[10] FRISCH U, HASSLACHER B, POMEAU Y. Lattice-Gas Automata for the Navier-Stokes Equation[J]. Physical Review Letters, 1986, 56(14): 1505-1508.
[11] 何雅玲, 王勇, 李庆. 格子 Boltzmann 方法的理论及应用[M]. 北京: 科学出版社, 2009.
[12] MCNAMARA G, ZANETTI G. Use of the Boltzmann equation to simulate lattice gas automata. [J]. Physical Review Letters, 1988, 61(20): 2332-2335.
[13] HIGUERA F J, JIMÉNEZ J. Boltzmann approach to lattice gas simulations[J]. Europhysics letters, 1989, 9(7): 663.
[14] HIGUERA F, SUCCI S, BENZI R. Lattice gas dynamics with enhanced collisions[J]. Europhysics letters, 1989, 9(4): 345.
[15] QIAN Y, D’HUMIERES D, LALLEMAND P. Lattice BGK model for Navier-Stokes equation[J]. Europhysics letters, 1992, 17(6): 479-484.
[16] CHEN S, CHEN H, MARTNEZ D, et al. Lattice Boltzmann model for simulation of magnetohydrodynamics[J]. Physical Review Letters, 1991, 67(27): 3776.
[17] DĤUMIERES D. Generalized Lattice-Boltzmann Equations[C]//Rarefied gas dynamics,PROGRESS IN ASTRONAUTICS AND AERONAUTICS: Vol. 159. Washington, DC:AIAA;, 1992: 450-458.
[18] KARLIN I V, GORBAN A N, SUCCI S, et al. Maximum entropy principle for lattice kinetic equations[J]. Physical Review Letters, 1998, 81(1): 6.
[19] SHAN X. Simulation of Rayleigh-Bénard convection using a lattice Boltzmann method[J].Physical review E, 1997, 55(3): 2780.
[20] HE X, CHEN S, DOOLEN G D. A novel thermal model for the lattice Boltzmann method in incompressible limit[J]. Journal of computational physics, 1998, 146(1): 282-300.
[21] SHAN X, CHEN H. Lattice Boltzmann model for simulating flows with multiple phases and components[J]. Physical review E, 1993, 47(3): 1815-1819.
[22] SWIFT M R, OSBORN W, YEOMANS J. Lattice Boltzmann simulation of nonideal fluids[J]. Physical review letters, 1995, 75(5): 830-833.
[23] GUNSTENSEN A K, ROTHMAN D H, ZALESKI S, et al. Lattice Boltzmann model of immiscible fluids[J]. Phys. Rev. A, 1991, 43: 4320-4327.
[24] GEIER M, SCHÖNHERR M, PASQUALI A, et al. The cumulant lattice Boltzmann equation in three dimensions: Theory and validation[J]. Computers & Mathematics with Applications, 2015, 70(4): 507-547.
[25] MALASPINAS O. Increasing stability and accuracy of the lattice Boltzmann scheme: recursivity and regularization[A]. 2015.
[26] JACOB J, MALASPINAS O, SAGAUT P. A new hybrid recursive regularised Bhatnagar–Gross–Krook collision model for lattice Boltzmann method-based large eddy simulation[J].Journal of Turbulence, 2018, 19(11-12): 1051-1076.
[27] RANDELL B. From Analytical Engine to Electronic Digital Computer: The Contributions of Ludgate, Torres, and Bush[J]. Annals of the History of Computing, 1982, 4: 327-341.
[28] BRENT R P. On the Precision Attainable with Various Floating-Point Number Systems[J]. IEEE Transactions on Computers, 1972, C-22: 601-607.
[29] CODY W J. Static and Dynamic Numerical Characteristics of Floating-Point Arithmetic[J]. IEEE Transactions on Computers, 1973, C-22: 598-601.
[30] KUKI H, CODY W J. A statistical study of the accuracy of floating point number systems[J]. Communications of the ACM, 1973, 16: 223 - 230.
[31] IEEE Standard for Binary Floating-Point Arithmetic[J]. ANSI/IEEE Std 754-1985, 1985: 1-20.
[32] BROGI F, BNÀ S, BOGA G, et al. On floating point precision in computational fluid dynamics using OpenFOAM[J]. Future Generation Computer Systems, 2024, 152: 1-16.
[33] OBRECHT C, KUZNIK F, TOURANCHEAU B, et al. Multi-GPU implementation of the lattice Boltzmann method[J]. Computers & Mathematics with Applications, 2013, 65(2): 252-261.
[34] LEHMANN M, KRAUSE M J, AMATI G, et al. Accuracy and performance of the lattice Boltzmann method with 64-bit, 32-bit, and customized 16-bit number formats[J]. Phys. Rev. E, 2022, 106: 015308.
[35] FREYTAG G, LIMA J A V F, RECH P, et al. Impact of Reduced and Mixed-Precision on the Efficiency of a Multi-GPU Platform on CFD Applications[C]//Computational Science and Its Applications–ICCSA 2022 Workshops: Malaga, Spain, July 4–7, 2022, Proceedings, Part IV. Berlin, Heidelberg: Springer-Verlag, 2022: 570–587.
[36] WALDEN A C, NIELSEN E J, DISKIN B, et al. A Mixed Precision Multicolor Point-Implicit Solver for Unstructured Grids on GPUs[J]. 2019 IEEE/ACM 9th Workshop on Irregular Applications: Architectures and Algorithms (IA3), 2019: 23-30.
[37] SUDO M A, FAZENDA Á L, SOUTO R P. Mixed precision applied on common mathematical procedures over GPU[J]. Anais do XXIII Simpósio em Sistemas Computacionais de Alto Desempenho (WSCAD 2022), 2022.
[38] 杜配冰. 基于多部分浮点数表示格式的高精度算法研究[D]. 湖南: 国防科技大学, 2020.
[39] 姜浩. 高精度可靠浮点计算及舍入误差分析研究[D]. 湖南: 国防科学技术大学, 2015.
[40] 易昕. 面向浮点程序的自动修复技术研究[D]. 湖南: 国防科技大学, 2022.
[41] BRYANT R, DAVIDR.O‘HALLARON. 深入理解计算机系统[M]. 北京: 机械工业出版社,2016.
[42] REIS T. Lattice Boltzmann method for complex flows[M]. Cardiff University (United Kingdom), 2007.
[43] COVENEY P V, SUCCI S, D’HUMIèRES D, et al. Multiple–relaxation–time lattice Boltzmann models in three dimensions[J]. Philosophical Transactions of the Royal Society of London. Series A: Mathematical, Physical and Engineering Sciences, 2002, 360(1792): 437-451.
[44] WOLF-GLADROW D A. Lattice-Gas Cellular Automata and Lattice Boltzmann Models[M]. Springer Berlin Heidelberg, 2000: 363-375.
[45] RIVET J P, BOON J. Lattice Gas Hydrodynamics[J]. Lattice Gas Hydrodynamics, 2001: 320.
[46] LADD A J. Numerical simulations of particulate suspensions via a discretized Boltzmann equation. Part 1. Theoretical foundation[J]. Journal of fluid mechanics, 1994, 271: 285-309.
[47] LADD A, VERBERG R. Lattice-Boltzmann simulations of particle-fluid suspensions[J]. Journal of Statistical Physics, 2001, 104(5/6): 1191-1251.
[48] GINZBURG I, VERHAEGHE F, D’HUMIÈRES D. Two-relaxation-time Lattice Boltzmann scheme: About parametrization, velocity, pressure and mixed boundary conditions[J]. Communications in Computational Physics, 2008, 3: 427-478.
[49] IZQUIERDO S, FUEYO N. Characteristic nonreflecting boundary conditions for open boundaries in lattice Boltzmann methods[J]. Phys. Rev. E, 2008, 78: 046707.
[50] YUAN P, SCHAEFER L. Equations of state in a lattice Boltzmann model[J]. Physics of Fluids, 2006, 18(4): 042101.
[51] FALCUCCI G, UBERTINI S, SUCCI S. Lattice Boltzmann simulations of phase-separating flows at large density ratios: the case of doubly-attractive pseudo-potentials[J]. Soft Matter, 2010, 6(18): 4357-4365.
[52] KUPERSHTOKH A, MEDVEDEV D, KARPOV D. On equations of state in a lattice Boltzmann method[J]. Computers & Mathematics with Applications, 2009, 58(5): 965-974.
[53] FRANK X, FUNFSCHILLING D, MIDOUX N, et al. Bubbles in a viscous liquid: latticeBoltzmann simulation and experimental validation[J]. Journal of Fluid Mechanics, 2006, 546:113-122.
[54] HAO L, CHENG P. Lattice Boltzmann simulations of liquid droplet dynamic behavior on a hydrophobic surface of a gas flow channel[J]. Journal of power sources, 2009, 190(2): 435-446.
[55] INAMURO T, OGATA T, TAJIMA S, et al. A lattice Boltzmann method for incompressible two-phase flows with large density differences[J]. Journal of Computational physics, 2004, 198(2): 628-644.
[56] SIMONIS S, NGUYEN J, AVIS S J, et al. Binary fluid flow simulations with free energy lattice Boltzmann methods[J]. Discrete and Continuous Dynamical Systems - S, 2023.
[57] KOTHARI Y, KOMRAKOVA A. Free-energy-based lattice Boltzmann model for emulsions with soluble surfactant[J]. Chemical Engineering Science, 2024, 285: 119609.
[58] ROTHMAN D H, KELLER J M. Immiscible cellular-automaton fluids[J]. Journal of Statistical Physics, 1988, 52: 1119-1127.
[59] CHO J Y, LEE H M, KIM J H, et al. Numerical simulation of gas-liquid transport in porous media using 3D color-gradient lattice Boltzmann method: trapped air and oxygen diffusion coefficient analysis[J]. Engineering Applications of Computational Fluid Mechanics, 2022, 16(1): 177-195.
[60] JU Y, GONG W, CHANG W, et al. Effects of pore characteristics on water-oil two-phase displacement in non-homogeneous pore structures: A pore-scale lattice Boltzmann model considering various fluid density ratios[J]. International Journal of Engineering Science, 2020, 154:103343.
[61] FAKHARI A, LI Y, BOLSTER D, et al. A phase-field lattice Boltzmann model for simulating multiphase flows in porous media: Application and comparison to experiments of CO2 sequestration at pore scale[J]. Advances in water resources, 2018, 114: 119-134.
[62] LATVA-KOKKO M, ROTHMAN D H. Static contact angle in lattice Boltzmann models of immiscible fluids[J]. Phys. Rev. E, 2005, 72: 046701.
[63] AKAI T, BIJELJIC B, BLUNT M J. Wetting boundary condition for the color-gradient lattice Boltzmann method: Validation with analytical and experimental data[J]. Advances in Water Resources, 2018, 116: 56-66.
[64] LECLAIRE S, ABAHRI K, BELARBI R, et al. Modeling of static contact angles with curved boundaries using a multiphase lattice Boltzmann method with variable density and viscosity ratios[J]. International Journal for Numerical Methods in Fluids, 2016, 82(8): 451-470.
[65] ZHAO B, MACMINN C W, PRIMKULOV B K, et al. Comprehensive comparison of pore-scale models for multiphase flow in porous media[J]. Proceedings of the National Academy of Sciences, 2019, 116(28): 13799-13806.
[66] LECLAIRE S, PARMIGIANI A, MALASPINAS O, et al. Generalized three-dimensional lattice Boltzmann color-gradient method for immiscible two-phase pore-scale imbibition and drainage in porous media[J]. Phys. Rev. E, 2017, 95: 033306.
[67] XU Z, LIU H, VALOCCHI A J. Lattice Boltzmann simulation of immiscible two-phase flow with capillary valve effect in porous media[J]. Water Resources Research, 2017, 53(5): 3770-3790.
[68] BRACKBILL J U, KOTHE D B, ZEMACH C. A continuum method for modeling surface tension[J]. Journal of computational physics, 1992, 100(2): 335-354.
[69] GU Q, ZHU L, ZHANG Y, et al. Pore-scale study of counter-current imbibition in strongly water-wet fractured porous media using lattice Boltzmann method[J]. Physics of Fluids, 2019,31(8).
[70] XU M, LIU H. Prediction of immiscible two-phase flow properties in a two-dimensional Berea sandstone using the pore-scale lattice Boltzmann simulation[J]. The European Physical Journal E, 2018, 41: 1-11.
[71] CHEN H, CHEN S, MATTHAEUS W H. Recovery of the Navier-Stokes equations using a lattice-gas Boltzmann method[J]. Physical review A, 1992, 45(8): R5339.
[72] AKAI T, ALHAMMADI A M, BLUNT M J, et al. Modeling oil recovery in mixed-wet rocks: pore-scale comparison between experiment and simulation[J]. Transport in Porous Media, 2019, 127: 393-414.
[73] D’HUMIÈRES D. Multiple–relaxation–time lattice Boltzmann models in three dimensions[J]. Philosophical Transactions of the Royal Society of London. Series A: Mathematical, Physical and Engineering Sciences, 2002, 360(1792): 437-451.
[74] CHEN Y, VALOCCHI A J, KANG Q, et al. Inertial effects during the process of supercritical CO2 displacing brine in a sandstone: Lattice Boltzmann simulations based on the continuum-surface-force and geometrical wetting models[J]. Water Resources Research, 2019, 55(12):11144-11165.
[75] CHEN Y, LI Y, VALOCCHI A J, et al. Lattice Boltzmann simulations of liquid CO2 displacing water in a 2D heterogeneous micromodel at reservoir pressure conditions[J]. Journal of contaminant hydrology, 2018, 212: 14-27.
[76] HUANG H, HUANG J J, LU X Y. Study of immiscible displacements in porous media using a color-gradient-based multiphase lattice Boltzmann method[J]. Computers & Fluids, 2014, 93:164-172.
[77] TÖLKE J, FREUDIGER S, KRAFCZYK M. An adaptive scheme using hierarchical grids for lattice Boltzmann multi-phase flow simulations[J]. Computers & fluids, 2006, 35(8-9): 820-830.
[78] LATVA-KOKKO M, ROTHMAN D H. Diffusion properties of gradient-based lattice Boltzmann models of immiscible fluids[J]. Physical Review E, 2005, 71(5): 056702.
[79] RAMSTAD T, ØREN P E, BAKKE S. Simulation of two-phase flow in reservoir rocks using a lattice Boltzmann method[J]. Spe Journal, 2010, 15(04): 917-927.
[80] RAMSTAD T, IDOWU N, NARDI C, et al. Relative permeability calculations from two-phase flow simulations directly on digital images of porous rocks[J]. Transport in Porous Media, 2012, 94(2): 487-504.
[81] YAMABE H, TSUJI T, LIANG Y, et al. Lattice Boltzmann simulations of supercritical CO2–water drainage displacement in porous media: CO2 saturation and displacement mechanism[J]. Environmental science & technology, 2015, 49(1): 537-543.
[82] LI Y, KAZEMIFAR F, BLOIS G, et al. Micro-PIV measurements of multiphase flow of water and liquid CO 2 in 2-D heterogeneous porous micromodels[J]. Water Resources Research, 2017, 53(7): 6178-6196.
[83] CHEN Y, KANG Q, CAI Q, et al. Lattice Boltzmann simulation of particle motion in binary immiscible fluids[J]. Communications in Computational Physics, 2015, 18(3): 757-786.
[84] LISHCHUK S, CARE C, HALLIDAY I. Lattice Boltzmann algorithm for surface tension with greatly reduced microcurrents[J]. Physical review E, 2003, 67(3): 036701.
[85] GUO Z, SHU C. Lattice Boltzmann method and its application in engineering: Vol. 3[M]. World Scientific, 2013.
[86] GUO Z, ZHENG C, SHI B. Discrete lattice effects on the forcing term in the lattice Boltzmann method[J]. Physical review E, 2002, 65(4): 046308.
[87] YU Y, LIU H, ZHANG Y, et al. Color-gradient lattice Boltzmann modeling of immiscible two-phase flows on partially wetting surfaces[J]. Proceedings of the Institution of Mechanical Engineers, Part C: Journal of Mechanical Engineering Science, 2018, 232(3): 416-430.
[88] HERRING A L, SHEPPARD A, ANDERSSON L, et al. Impact of wettability alteration on 3D nonwetting phase trapping and transport[J]. International Journal of Greenhouse Gas Control,2016, 46: 175-186.
[89] HERRING A L, ANDERSSON L, WILDENSCHILD D. Enhancing residual trapping of super critical CO2 via cyclic injections[J]. Geophysical Research Letters, 2016, 43(18): 9677-9685.

所在学位评定分委会
力学
国内图书分类号
TP399
来源库
人工提交
成果类型学位论文
条目标识符http://sustech.caswiz.com/handle/2SGJ60CL/765962
专题南方科技大学
工学院_力学与航空航天工程系
推荐引用方式
GB/T 7714
邓福东. 浮点数精度在格子Boltzmann仿真中的影响[D]. 深圳. 南方科技大学,2024.
条目包含的文件
文件名称/大小 文献类型 版本类型 开放类型 使用许可 操作
12132389-邓福东-力学与航空航天(29221KB)----限制开放--请求全文
个性服务
原文链接
推荐该条目
保存到收藏夹
查看访问统计
导出为Endnote文件
导出为Excel格式
导出为Csv格式
Altmetrics Score
谷歌学术
谷歌学术中相似的文章
[邓福东]的文章
百度学术
百度学术中相似的文章
[邓福东]的文章
必应学术
必应学术中相似的文章
[邓福东]的文章
相关权益政策
暂无数据
收藏/分享
所有评论 (0)
[发表评论/异议/意见]
暂无评论

除非特别说明,本系统中所有内容都受版权保护,并保留所有权利。