当前位置: X-MOL 学术Comput. Phys. Commun. › 论文详情
Our official English website, www.x-mol.net, welcomes your feedback! (Note: you will need to create a separate account there.)
A finite-element toolbox for the simulation of solid–liquid phase-change systems with natural convection
Computer Physics Communications ( IF 7.2 ) Pub Date : 2020-08-01 , DOI: 10.1016/j.cpc.2020.107188
Aina Rakotondrandisa , Georges Sadaka , Ionut Danaila

Abstract We present and distribute a new numerical system using classical finite elements with mesh adaptivity for computing two-dimensional liquid–solid phase-change systems involving natural convection. The programs are written as a toolbox for FreeFem++ (www3.freefem.org), a free finite-element software available for all existing operating systems. The code implements a single domain approach. The same set of equations is solved in both liquid and solid phases: the incompressible Navier–Stokes equations with Boussinesq approximation for thermal effects. This model describes naturally the evolution of the liquid flow which is dominated by convection effects. To make it valid also in the solid phase, a Carman–Kozeny-type penalty term is added to the momentum equations. The penalty term brings progressively (through an artificial mushy region) the velocity to zero into the solid. The energy equation is also modified to be valid in both phases using an enthalpy (temperature-transform) model introducing a regularized latent-heat term. Model equations are discretized using Galerkin triangular finite elements. Piecewise quadratic (P2) finite-elements are used for the velocity and piecewise linear (P1) for the pressure. For the temperature both P2 and P1 discretizations are possible. The coupled system of equations is integrated in time using a second-order Gear scheme. Non-linearities are treated implicitly and the resulting discrete equations are solved using a Newton algorithm. An efficient mesh adaptivity algorithm using metrics control is used to adapt the mesh every time step. This allows us to accurately capture multiple solid–liquid interfaces present in the domain, the boundary-layer structure at the walls and the unsteady convection cells in the liquid. We present several validations of the toolbox, by simulating benchmark cases of increasing difficulty: natural convection of air, natural convection of water, melting of a phase-change material, a melting-solidification cycle, and, finally, a water freezing case. Other similar cases could be easily simulated with this toolbox, since the code structure is extremely versatile and the syntax very close to the mathematical formulation of the model. Programm summary Program Title: PCM-Toolbox-2D Program Files doi: http://dx.doi.org/10.17632/phby62rhgv.1 Licensing provisions: Apache License, 2.0 Programming language: FreeFem + + (free software, www3.freefem.org) Nature of problem: The software computes 2D configurations of liquid–solid phase-change problems with convection in the liquid phase. Natural convection, melting and solidification processes are illustrated in the paper. The software can be easily modified to take into account different related physical models. Solution method: We use a single domain approach, solving the incompressible Navier–Stokes equations with Boussinesq approximation in both liquid and solid phases. A Carman–Kozeny-type penalty term is added to the momentum equations to bring the velocity to zero into the solid phase. An enthalpy model is used in the energy equation to take into account the phase change. Discontinuous variables (latent heat, material properties) are regularized through an intermediate (mushy) region. Space discretization is based on Galerkin triangular finite elements. Piecewise quadratic (P2) finite-elements are used for the velocity and piecewise linear (P1) for the pressure. For the temperature both P2 and P1 discretizations are possible. A second order Gear scheme is used for the time integration of the coupled system of equations. Non-linear terms are treated implicitly and the resulting discrete equations are solved using a Newton algorithm. A mesh adaptivity algorithm is implemented to reduce the computational time and increase the local space accuracy when (multiple) interfaces are present.

中文翻译:

用于模拟具有自然对流的固液相变系统的有限元工具箱

摘要 我们提出并发布了一个新的数值系统,该系统使用具有网格自适应性的经典有限元来计算涉及自然对流的二维液固相变系统。这些程序是作为 FreeFem++ (www3.freefem.org) 的工具箱编写的,FreeFem++ 是一款适用于所有现有操作系统的免费有限元软件。该代码实现了单域方法。在液相和固相中求解同一组方程:不可压缩的 Navier-Stokes 方程与热效应的 Boussinesq 近似。该模型自然地描述了受对流效应支配的液体流动的演变。为了使其在固相中也有效,在动量方程中添加了 Carman-Kozeny 型惩罚项。惩罚项逐渐(通过人工糊状区域)使固体的速度为零。使用引入正则化潜热项的焓(温度转换)模型,能量方程也被修改为在两个阶段都有效。模型方程使用伽辽金三角有限元离散化。分段二次 (P2) 有限元用于速度,分段线性 (P1) 用于压力。对于温度,P2 和 P1 离散化都是可能的。使用二阶齿轮方案对耦合方程组进行时间积分。非线性被隐式处理,产生的离散方程使用牛顿算法求解。使用度量控制的高效网格自适应算法用于在每个时间步调整网格。这使我们能够准确捕获域中存在的多个固液界面、壁上的边界层结构和液体中的不稳定对流单元。我们通过模拟难度越来越大的基准案例来展示工具箱的几个验证:空气的自然对流、水的自然对流、相变材料的熔化、熔化-凝固循环,以及最后的水冻结案例。使用此工具箱可以轻松模拟其他类似情况,因为代码结构极其通用且语法非常接近模型的数学公式。程序概要 程序名称:PCM-Toolbox-2D Program Files doi:http://dx.doi.org/10.17632/phby62rhgv.1 许可条款:Apache License,2.0 编程语言:FreeFem++(免费软件,www3.freefem. org) 问题性质:该软件计算具有液相对流的液固相变问题的二维配置。论文中说明了自然对流、熔化和凝固过程。该软件可以轻松修改,以考虑不同的相关物理模型。求解方法:我们使用单域方法,在液相和固相中使用 Boussinesq 近似求解不可压缩的 Navier-Stokes 方程。Carman-Kozeny 类型的惩罚项被添加到动量方程中,以使速度为零进入固相。在能量方程中使用焓模型来考虑相变。不连续变量(潜热、材料特性)通过中间(糊状)区域进行正则化。空间离散化基于伽辽金三角有限元。分段二次 (P2) 有限元用于速度,分段线性 (P1) 用于压力。对于温度,P2 和 P1 离散化都是可能的。二阶齿轮方案用于耦合方程组的时间积分。非线性项被隐式地处理,产生的离散方程使用牛顿算法求解。当存在(多个)界面时,实施网格自适应算法以减少计算时间并提高局部空间精度。二阶齿轮方案用于耦合方程组的时间积分。非线性项被隐式地处理,产生的离散方程使用牛顿算法求解。当存在(多个)界面时,实施网格自适应算法以减少计算时间并提高局部空间精度。二阶齿轮方案用于耦合方程组的时间积分。非线性项被隐式地处理,产生的离散方程使用牛顿算法求解。当存在(多个)界面时,实施网格自适应算法以减少计算时间并提高局部空间精度。
更新日期:2020-08-01
down
wechat
bug