基于GPU-CUDA并行的虚拟网格有限差分法求解器  

Solver of Ghost Cell Finite Difference Method with GPU-CUDA Acceleration

在线阅读下载全文

作  者:辛建建 石伏龙 Xin Jianjian;Shi Fulong(Institute of Naval Architecture and Ocean Engineering,Ningbo University,Ningbo 315211,China;School of Shipping and Naval Architecture,Chongqing Jiaotong University,Chongqing 400074,China)

机构地区:[1]宁波大学海运学院,宁波315211 [2]重庆交通大学航运与船舶工程学院,重庆400074

出  处:《水动力学研究与进展(A辑)》2023年第4期523-527,共5页Chinese Journal of Hydrodynamics

摘  要:基于CPU/GPU异构体系架构的流体力学并行计算已经成为当前CFD研究领域的重点之一。该文自主开发了一高效虚拟网格法并行求解器以模拟绕动边界的不可压缩流动问题,基于GPU的计算统一设备架构(Computing Unified Device Architecture,CUDA)并行编程模型对该求解器进行加速。该文模型采用有限差分法在交错直角网格上求解不可压缩Navier-Stokes方程,采用虚拟网格通过在浸入边界内布置有限数量的虚拟网格(固体内部但邻近流体的网格)以计及浸入边界对流场的影响。通过合理分配线程块内线程数量,减少主机与设备之间的数据通信,充分利用共享内存和高效求解泊松方程,提高并行效率。为验证该并行求解器的精度和效率,对静止流体中二维振荡圆柱和三维振荡球体算例进行模拟,研究发现:GPU并行求解器相比于CPU串行求解器在不同网格上均获得至少一个量级的加速比,且网格数量越多,加速效果越好,在二维细网格上获得100倍以上的加速比,在三维较细网格上获得超过4 000倍的加速比。Parallel computation of fluid dynamics based on CPU/GPU heterogeneous architecture has become a popular research area of CFD(computational fluid dynamics).An in-house developed highly efficient solver of the ghost cell method is presented for incompressible flows around moving boundaries.The present solver is accelerated by a GPU based CUDA(Computing Unified Device Architecture)parallel programming model.A finite difference method is used to solve the Navier-Stokes equation on a staggered Cartesian grid.A ghost cell method is adopted to enforce the no-slip boundary conditions by placing finite ghost cell inside the solid but adjacent the immersed boundary.The present solver is comprehensively optimized by reasonably allocating the number of threads and memory space,reducing data communication between the host and the device,fully utilizing the share memory and solving the Poisson equation.To examine the accuracy and efficiency of the present solver,cases of an oscillating two-dimensional(2D)cylinder and three-dimensional(3D)sphere in a still fluid are simulated.The results show that the present GPU parallel solver obtains speed-up ratios of over one-order of magnitude under different grid numbers compared with the CPU serial solver.Moreover,the more the grid number is,the better the acceleration performance.The speed-up ratio is over 100 for 2D fine grid and over 4000 for a 3D relatively fine grid.

关 键 词:虚拟网格法 不可压缩流动 并行计算 GPU-CUDA 

分 类 号:O352[理学—流体力学]

 

参考文献:

正在载入数据...

 

二级参考文献:

正在载入数据...

 

耦合文献:

正在载入数据...

 

引证文献:

正在载入数据...

 

二级引证文献:

正在载入数据...

 

同被引文献:

正在载入数据...

 

相关期刊文献:

正在载入数据...

相关的主题
相关的作者对象
相关的机构对象