arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2505.20399astro-ph.IM
收藏

ULULA:用于教学与实验的超轻量二维流体动力学代码

ULULA: An ultra-lightweight 2D hydrodynamics code for teaching and experimentation

Benedikt Diemer

AI总结:

ULULA是一个超轻量Python代码,用于二维流体动力学和引力模拟,旨在教学与实验,代码简洁、组件可替换,并附带多个可快速运行的标准问题。

摘要:

流体动力学在课堂教学中是一门难以教授的学科,因为大多数相关问题必须通过数值方法而非解析方法求解。尽管有许多公开的流体动力学代码,但生产级软件的复杂性掩盖了其背后的物理原理,并可能让初次使用者感到不知所措。在此,我们介绍ULULA,一个用于求解二维流体动力学和引力的超轻量Python代码。其主要目标是使代码易于理解、扩展和实验。该模拟框架包含不到800行纯Python代码,但包含一个稳健的MUSCL-Hancock方案,并具有可替换的组件,如黎曼求解器、重构方案、边界条件和状态方程。代码提供了许多著名的流体动力学问题,可在笔记本电脑上几分钟内运行。该代码开源、注释丰富且文档详尽。

英文摘要:

Hydrodynamics is a difficult subject to teach in the classroom because most relevant problems must be solved numerically rather than analytically. While there are numerous public hydrodynamics codes, the complexity of production-level software obscures the underlying physics and can be overwhelming to first-time users. Here we present ULULA, an ultra-lightweight python code to solve hydrodynamics and gravity in 2D. The main goal is for the code to be easy to understand, extend, and experiment with. The simulation framework consists of fewer than 800 active lines of pure python code, but it includes a robust MUSCL-Hancock scheme with exchangeable components such as Riemann solvers, reconstruction schemes, boundary conditions, and equations of state. Numerous well-known hydrodynamics problems are provided and can be run in a few minutes on a laptop. The code is open-source, generously commented, and extensively documented.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑