CuPyMag:具有磁致伸缩的GPU加速有限元微磁学
CuPyMag: GPU-Accelerated Finite-Element Micromagnetics with Magnetostriction
AI总结:
CuPyMag通过GPU加速实现高效率的有限元微磁学模拟,结合磁弹性耦合和远场效应,支持大规模磁性结构分析。
摘要:
我们介绍了CuPyMag,一个基于Python的开源框架,用于大规模具有磁致伸缩的微磁学模拟。CuPyMag在GPU驻留的工作流中使用有限元方法求解微磁学,其中关键操作,如右侧装配、空间导数和体积平均,利用CuPy的BLAS加速后端进行张量化。基准测试显示,CuPyMag中的GPU求解器相比CPU代码实现了高达两个数量级的加速。其运行时间随着问题规模线性或亚线性增长,显示出高效率。此外,CuPyMag使用高斯-塞德尔投影法进行时间积分,这不仅允许稳定的步长(最高达11皮秒),而且在没有预处理的情况下,每个控制方程仅需1-3次共轭梯度迭代即可求解。CuPyMag考虑了磁弹性耦合和磁体边界产生的远场效应,这两种因素在存在局部缺陷时对磁化反转起着重要作用。CuPyMag在NVIDIA H200 GPU上不到三小时内,使用高分辨率网格(最高达300万个节点)解决了这些计算密集型多物理场模拟。这种加速使微磁学模拟能够处理非平凡的缺陷几何结构,并解析纳米级磁性结构。它将微磁学模拟的范围扩展到能够指导实验的现实、大规模问题。更广泛地说,CuPyMag是使用广泛采用的Python库开发的,这提供了跨平台兼容性、安装简便性和对多样化应用的适应性。
英文摘要:
We introduce CuPyMag, an open-source, Python-based framework for large-scale micromagnetic simulations with magnetostriction. CuPyMag solves micromagnetics with finite elements in a GPU-resident workflow in which key operations, such as right-hand-side assembly, spatial derivatives, and volume averages, are tensorized using CuPy's BLAS-accelerated backend. Benchmark tests show that the GPU solvers in CuPyMag achieve a speedup of up to two orders of magnitude compared to the CPU codes. Its runtime grows linearly/sublinearly with problem size, demonstrating high efficiency. Additionally, CuPyMag uses the Gauss-Seidel projection method for time integration, which not only allows stable time steps (up to 11 ps) but also solves each governing equation with only 1-3 conjugate-gradient iterations without preconditioning. CuPyMag accounts for magnetoelastic coupling and far-field effects arising from the boundary of the magnetic body, both of which play an important role in magnetization reversal in the presence of local defects. CuPyMag solves these computationally intensive multiphysics simulations with a high-resolution mesh (up to 3M nodes) in under three hours on an NVIDIA H200 GPU. This acceleration enables micromagnetic simulations with non-trivial defect geometries and resolves nanoscale magnetic structures. It expands the scope of micromagnetic simulations towards realistic, large-scale problems that can guide experiments. More broadly, CuPyMag is developed using widely adopted Python libraries, which provide cross-platform compatibility, ease of installation, and accessibility for adaptations to diverse applications.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。