使用Jacobi多项式的球坐标中的张量演算,第二部分:实现和示例
Tensor calculus in spherical coordinates using Jacobi polynomials, Part-II: Implementation and Examples
摘要:
我们提出了一个模拟代码,可以解决广泛的偏微分方程在一个完整的球。如第一部分所述,该代码将张量变量扩展为角方向上的自旋加权球谐函数谱系列和径向方向上的缩放雅可比多项式基。非线性项的计算是通过将光谱序列中的系数转换为物理网格上每个量的值来进行的,在物理网格上很容易计算乘积并执行其他局部操作。展开使得以张量形式求解方程变得简单(即,不分解成标量)。我们提出并研究了几个单元测试,这些测试表明代码可以准确地解决线性问题,实现边界条件,并在谱空间和物理空间之间进行转换。然后,我们运行Marti等人(2014)提出的一系列基准问题,实现流体动力学和磁流体动力学方程。通过在更高的空间分辨率下运行并使用高阶时间步长方案,我们能够计算出比Marti等人2014年报告的更精确的解。我们发现旋转对流和对流发电机基准问题敏感地依赖于时间步长和数据分析的细节。我们还表明,在低分辨率模拟的发电机问题,数值方案中的小变化可能会导致大的变化的解决方案。为了帮助将来与这些基准进行比较,我们包括用于生成数据的源代码,以及用于生成图表的数据和分析脚本。
英文摘要:
We present a simulation code which can solve broad ranges of partial differential equations in a full sphere. The code expands tensorial variables in a spectral series of spin-weighted spherical harmonics in the angular directions and a scaled Jacobi polynomial basis in the radial direction, as described in Part-I. Nonlinear terms are calculated by transforming from the coefficients in the spectral series to the value of each quantity on the physical grid, where it is easy to calculate products and perform other local operations. The expansion makes it straightforward to solve equations in tensor form (i.e., without decomposition into scalars). We propose and study several unit tests which demonstrate the code can accurately solve linear problems, implement boundary conditions, and transform between spectral and physical space. We then run a series of benchmark problems proposed in Marti et al (2014), implementing the hydrodynamic and magnetohydrodynamic equations. We are able to calculate more accurate solutions than reported in Marti et al 2014 by running at higher spatial resolution and using a higher-order timestepping scheme. We find the rotating convection and convective dynamo benchmark problems depend sensitively on details of timestepping and data analysis. We also demonstrate that in low resolution simulations of the dynamo problem, small changes in a numerical scheme can lead to large changes in the solution. To aid future comparison to these benchmarks, we include the source code used to generate the data, as well as the data and analysis scripts used to generate the figures.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。