chapter. Acceleration Techniques 第9章 加速技术[cfd-000A]
为了加速定常问题控制方程(2.19)的求解,人们发展了各种方法。这些加速技术也适用于双时间步进格式的内迭代(6.3节)。本章将讨论以下方法:
- 局部时间步长;
- 焓阻尼;
- 残差光顺;
- 多重网格;
- 低马赫数预条件。
en
Various methodologies were developed in order to accelerate the solution of the governing equations (2.19) for stationary problems. The acceleration techniques are applicable also to the inner iteration of the dual-time stepping scheme (Section 6.3). The following methods will be discussed in this Chapter:
- local time-stepping,
- enthalpy damping,
- residual smoothing,
- multigrid,
- low Mach-number preconditioning.
局部时间步长、焓阻尼和预条件基于对常微分方程组(6.1)的修改,而其余两种技术则是对求解过程的改进。除残差光顺外,所有方法既可以用于显式(6.1节)也可以用于隐式(6.2节)时间推进格式。残差光顺是专门为显式多级格式(6.1.1、6.1.2小节)而发展的。若干种加速技术的概览可参见文献[1]和[2]。en
The local time-stepping, enthalpy damping, and the preconditioning are based on a modification of the system of the ordinary differential equations (6.1), while the two remaining techniques are improvements of the solution process. With the exception of the residual smoothing, all methods can be applied to both the explicit (Section 6.1) and the implicit (Section 6.2) time-stepping schemes. Residual smoothing was developed especially for the explicit multistage schemes (Subsections 6.1.1, 6.1.2). An overview of several acceleration techniques can be found in Refs. [1] and [2].
9.1 Local Time-Stepping 局部时间步长[cfd-9-1]
在这种情形下,离散化的控制方程(6.1)对每个控制体都用尽可能大的时间步长进行积分。局部时间步长\(\Delta t_I\)按式(6.14)、(6.18)、(6.20)或(6.22)之一计算。这样一来,向定常态的收敛会显著加速,但瞬态解不再具有时间上的精度。图9.1以绕机翼的无黏亚声速流动为例,展示了局部时间步长的效率。流动由显式多级格式(6.1.1小节)推进到定常态。显然,采用全局时间步长(即对所有控制体都相同的时间步长)会导致向定常态不必要地缓慢收敛。对于定常黏性流动,通常还能获得更大的CPU时间节省。en
In this case, the discretised governing equations (6.1) are integrated using the largest possible time step for each control volume. The local time step \(\Delta t_I\) is calculated according to one of the formulae (6.14), (6.18), (6.20), or (6.22). As a result, the convergence to the steady state is considerably accelerated, however the transient solution is no longer temporally accurate. The efficiency of the local time-stepping is demonstrated in Fig. 9.1 for an inviscid subsonic flow past a wing. The flow is driven to the steady state by an explicit multistage scheme (Subsection 6.1.1). It is apparent that using a global time step (i.e., a time step identical for all control volumes) results in an unnecessarily slow convergence towards the steady state. Even larger savings in terms of the CPU-time are usually achieved for stationary viscous flows.

图9.1:非结构网格上无黏亚声速流动有/无局部时间步长时升力系数收敛历史的比较。纵轴:升力系数(lift coefficient);横轴:CPU时间(CPU-time [s]);图例:local time-stepping——局部时间步长;global time-stepping——全局时间步长。
9.2 Enthalpy Damping 焓阻尼[cfd-9-2]
在某些情形下,总焓\(H\)(式(2.12))在整个流场中为常数。例如,在无热源和外力的情况下,由欧拉方程支配的外部流动就会出现这种情形。我们可以利用这一事实来减少计算量。en
In certain cases, the total enthalpy \(H\) (Eq. (2.12)) is constant in the whole flow field. This situation occurs, for example, for external flows governed by the Euler equations in absence of heat sources and external forces. We can take advantage of this fact in order to reduce the computational effort.
第一种可能的做法,是在流动域内规定总焓的值。这样一来,便可以从欧拉方程(2.45)中省去能量方程,从而节省内存和CPU时间。en
The first possibility would be to prescribe the value of the total enthalpy in the flow domain. In consequence, the energy equation can be omitted from the Euler equations (2.45). This saves memory and CPU time.
另一种方法——所谓的焓阻尼(enthalpy damping)——由Jameson为求解位势流方程而提出[3]。它利用总焓\(H\)与其自由流值\(H_\infty\)之差来定义一个附加的强迫项。据此,向定常态的收敛可以得到显著加速。把焓阻尼应用于欧拉方程(2.45),得到如下修改形式[4]en
A different methodology - the so-called enthalpy damping - was suggested by Jameson for the solution of the potential flow equation [3]. It employs the difference between the total enthalpy \(H\) and its freestream value \(H_\infty\) to define an additional forcing term. With this, the convergence to the steady state can be considerably accelerated. The application of the enthalpy damping to the Euler equations (2.45) results in the following modification [4]
其中强迫项\(\vec{Q}_{ED}\)由下式给出en
where the forcing term \(\vec{Q}_{ED}\) is given by
阻尼因子\(\vartheta\)是一个小常数,必须凭经验确定。空间离散格式,特别是人工耗散,必须按这样的方式实现:使\(H = H_\infty\)成为离散化方程的一个有效解。这样,加入源项\(\vec{Q}_{ED}\)就不会改变最终的定常态。en
The damping factor \(\vartheta\) is a small constant, which has to determined empirically. The spatial discretisation scheme, and particularly the artificial dissipation has to be implemented in such a way that \(H = H_\infty\) is a valid solution of the discretised equations. Then, the addition of the source term \(\vec{Q}_{ED}\) does not alter the final steady state.
焓阻尼作为附加的步骤,在每次更新流动解之后执行。例如,对于显式\(m\)级时间推进格式(6.1.1或6.1.2小节),阻尼步骤为en
The enthalpy damping is conducted as an additional step after each update of the flow solution. For example, in the case of the explicit \(m\)-stage time-stepping scheme (Subsection 6.1.1 or 6.1.2), the damping step reads
能量方程除外,它变为en
with the exception of the energy equation which becomes
在式(9.3)中,\(\vec{W}_I^{(m)}\)表示\(m\)级显式时间推进格式的最终解。文献[1]中针对绕NACA 0012翼型跨声速流动(\(M_\infty = 0.8\)、\(\alpha = 1.25^{\circ}\))所做的数值实验证实,到达定常态所需的时间步数可以减少约一半。en
In Eq. (9.3), \(\vec{W}_I^{(m)}\) denotes the final solution of the \(m\)-stage explicit time-stepping scheme. Numerical experiments in Ref. [1], which were conducted for a transonic flow past the NACA 0012 airfoil (\(M_\infty = 0.8\), \(\alpha = 1.25^{\circ}\)), confirmed that the number of time steps to reach the steady state can be reduced by about factor of two.
9.3 Residual Smoothing 残差光顺[cfd-9-3]
显式多级时间推进格式(6.1.1和6.1.2小节)的最大CFL数及其收敛特性,可以通过优化各级系数来加以改变[5]–[7]。Jameson和Baker[8]提出了残差光顺(residual smoothing)技术,目的是赋予显式格式以隐式特性,从而提高最大允许CFL数。残差光顺的另一个目的,是对残差高频误差分量更好的阻尼。这对于成功应用多重网格方法尤为重要。en
The maximum CFL number and the convergence properties of the explicit multistage time-stepping scheme (Subsections 6.1.1 and 6.1.2) can be influenced by optimising the stage coefficients [5]--[7]. Jameson and Baker [8] introduced the residual smoothing technique with the aim to lend the explicit scheme an implicit character and hence to increase the maximum allowable CFL number. A further purpose of the residual smoothing is a better damping of the high-frequency error components of the residual. This is of particular importance for a successful application of the multigrid method.
残差光顺可以分别以显式、隐式或混合的方式实现[9]、[10]。残差光顺通常在显式时间推进格式(式(6.5)、(6.7))的每一级中应用。在解\(\vec{W}^{(k)}\)更新之前,先前算得的残差\(\vec{R}^{(k)}\)被光顺后的残差\(\vec{R}^{*}\)所取代。下面,我们将讨论流行的隐式残差光顺(Implicit Residual Smoothing,IRS)在结构网格以及非结构网格上的实现。en
The residual smoothing can be implemented in explicit, implicit or in mixed manner [9], [10], respectively. The residual smoothing is usually applied in each stage of the explicit time-stepping scheme (Eqs. (6.5), (6.7)). The previously computed residuals \(\vec{R}^{(k)}\) are replaced by the smoothed residuals \(\vec{R}^{*}\) before the solution \(\vec{W}^{(k)}\) is updated. In the following, we shall discuss the implementation of the popular Implicit Residual Smoothing (IRS) on structured as well as on unstructured grids.
9.3.1 Central IRS on Structured Grids 结构网格上的中心IRS[cfd-9-3-1]
隐式残差光顺的标准形式在三维情形下为en
The standard formulation of the implicit residual smoothing reads in 3D
其中\(\vec{R}^{*}_{I,J,K}\)、\(\vec{R}^{**}_{I,J,K}\)和\(\vec{R}^{***}_{I,J,K}\)分别表示\(I\)、\(J\)、\(K\)方向上光顺后的残差。参数\(\epsilon^I\)、\(\epsilon^J\)和\(\epsilon^K\)表示三个计算坐标方向上的光顺系数。式(9.5)中的隐式算子类似于二阶中心差分,因此称为中心隐式残差光顺(Central Implicit Residual Smoothing,CIRS)。式(9.5)中的隐式方程组用求三对角矩阵之逆的Thomas算法求解。en
where \(\vec{R}^{*}_{I,J,K}\), \(\vec{R}^{**}_{I,J,K}\), and \(\vec{R}^{***}_{I,J,K}\) denote the smoothed residuals in \(I\)-, \(J\)-, and \(K\)-direction, respectively. The parameters \(\epsilon^I\), \(\epsilon^J\), and \(\epsilon^K\) stand for the smoothing coefficients in the three computational coordinates. The implicit operator in Eq. (9.5) resembles second-order central difference. The term Central Implicit Residual Smoothing (CIRS) is therefore used. The implicit system in Eq. (9.5) is solved by the Thomas algorithm for the inversion of tridiagonal matrices.
光顺系数通常定义为对流通量雅可比矩阵谱半径的函数[11]。其目的是在每个坐标方向上只施加为保持稳定性与良好误差阻尼所必需的光顺量。文献[12]针对二维情形给出了一个合适的公式en
The smoothing coefficients are usually defined as functions of spectral radii of the convective flux Jacobians [11]. The purpose is to apply only as much smoothing in each coordinate direction as it is necessary for stability and good error damping. A suitable formula for 2D was suggested in [12]
这里,\(\sigma^{*}/\sigma\)表示光顺格式与未光顺格式的CFL数之比。变量\(r\)表示对流通量谱半径之比(式(4.53)),即\(r = \hat{\Lambda}_c^{J}/\hat{\Lambda}_c^{I}\)。参数\(\Psi \approx 0.125\)保证光顺操作的线性稳定性。en
Here, \(\sigma^{*}/\sigma\) denotes the ratio of the CFL numbers of the smoothed and unsmoothed scheme. The variable \(r\) stands for the ratio of the convective spectral radii (Eq. (4.53)), i.e., \(r = \hat{\Lambda}_c^{J}/\hat{\Lambda}_c^{I}\). The parameter \(\Psi \approx 0.125\) ensures linear stability of the smoothing operation.
其中en
where
等等。参数\(\Psi\)的典型取值为0.0625。en
etc. The typical value of the parameter \(\Psi\) is 0.0625.
CFL数之比\(\sigma^{*}/\sigma\)的最大值取决于光顺系数的取值以及空间离散格式的类型。对于中心格式(4.3.1小节),该比值由下式给出en
The maximum of the ratio of the CFL numbers \(\sigma^{*}/\sigma\) depends on the value of the smoothing coefficient and on the type of the spatial discretisation scheme. In the case of the central scheme (Subsection 4.3.1), the ratio is given by
实际中,可以达到\(\sigma^{*}/\sigma \approx 2\)(\(\epsilon = 0.8\))。更高的比值会削弱时间推进格式的阻尼能力。对于上风空间离散,不存在像式(9.8)这样简单的条件,因为\(\sigma^{*}/\sigma\)的最大值还与各级系数有关。但通常,无黏流动的CFL数(见表6.1和表6.2)可以提高约两倍,黏性流动(采用表6.2中的混合格式)最多可提高约五倍。图9.2和图9.3展示了中心IRS对结构网格上无黏流动与黏性流动收敛的影响。比较按CPU时间进行,以计入IRS带来的额外计算量。可以看到,求解时间可以显著缩短,对黏性流动尤其明显。不过,当IRS与多重网格(9.4节)联合使用时,还能获得更大的节省。en
In practice, value of \(\sigma^{*}/\sigma \approx 2\) can be reached (\(\epsilon = 0.8\)). Higher ratios reduce the damping of the time-stepping scheme. There is no such simple condition like (9.8) for the upwind spatial discretisation since the maximum of \(\sigma^{*}/\sigma\) depends also on the stage coefficients. But normally, the CFL number (see Tables 6.1 and 6.2) can be raised by about factor two for inviscid and up to factor five for viscous flows (using the hybrid scheme from Table 6.2). Figures 9.2 and 9.3 demonstrate the effect of the central IRS on the convergence for an inviscid and viscous flow on structured grids. The comparison is done in terms of the CPU time, in order to account for the additional numerical effort due to the IRS. As we can see, the solution time can be significantly reduced especially for a viscous flow. Even larger savings can be however realised when the IRS is employed together with multigrid (Section 9.4).

图9.2:结构网格上无黏跨声速流动有/无IRS时收敛历史的比较。纵轴:log(res)(残差的对数);横轴:CPU时间(CPU time [s]);图例:without IRS——无IRS;with central IRS——有中心IRS。

图9.3:结构网格上黏性亚声速流动有/无IRS时收敛历史的比较。纵轴:log(res)(残差的对数);横轴:CPU时间(CPU time [s]);图例:without IRS——无IRS;with central IRS——有中心IRS。
式(6.18)中由黏性谱半径\(\hat{\Lambda}_v\)造成的时间步长限制,可以借助隐式残差光顺来补偿。最大时间步长按式(6.14)计算,但不包含\(\hat{\Lambda}_v\)。在黏性谱半径占主导的流动区域,用较大的系数\(\epsilon^I\)、\(\epsilon^J\)、\(\epsilon^K\)进行光顺。基于黏性谱半径的光顺系数可由文献[12]、[13]中的公式计算en
The limitation of the time step due to the viscous spectral radius \(\hat{\Lambda}_v\) in Eq. (6.18) can be offset with the aid of the implicit residual smoothing. The maximum time step is calculated according to the formula (6.14) without \(\hat{\Lambda}_v\). In flow regions where the viscous spectral radius dominates, smoothing is carried out using higher coefficients \(\epsilon^I\), \(\epsilon^J\), \(\epsilon^K\). Smoothing coefficients based on the viscous spectral radii can be computed from [12], [13]
9.3.2 Central IRS on Unstructured Grids 非结构网格上的中心IRS[cfd-9-3-2]
在非结构网格上,CIRS通过把拉普拉斯算子(见式(5.24))作用于残差来实现。于是,控制体\(I\)内光顺后的残差\(\vec{R}^{*}_{I}\)由如下隐式关系得到[14]en
CIRS is implemented on unstructured grids by applying the Laplacian operator (see Eq. (5.24)) to the residual. Thus, the smoothed residual \(\vec{R}^{*}_{I}\) in a control volume \(I\) is obtained from the implicit relation [14]
求和遍及所有\(N_A\)个相邻控制体。关系式(9.10)用Jacobi迭代对\(\vec{R}^{*}_{I}\)求解。光顺系数的实用取值范围为\(0.5 \le \epsilon \le 0.8\)。采用这些\(\epsilon\)值,可以把CFL数(因而时间步长)提高二至五倍。由于矩阵对角占优,Jacobi迭代大约两步即收敛。en
The sum includes all \(N_A\) adjacent control volumes. The relation (9.10) is solved for \(\vec{R}^{*}_{I}\) using Jacobi iteration. Useful values of the smoothing coefficient are \(0.5 \le \epsilon \le 0.8\). With these values of \(\epsilon\) it is possible to increase the CFL number (and hence the time step) two to five times. Due to the diagonal dominance of the matrix, the Jacobi iteration converges in about two steps.
9.3.3 Upwind IRS on Structured Grids 结构网格上的上风IRS[cfd-9-3-3]
前面讨论的CIRS方法对亚声速和跨声速流动工作良好,在黏性占主导的区域也很有帮助。然而,与上风空间离散格式结合使用时,CIRS的误差阻尼特性较差。此外,经CIRS加速的多级格式在强激波情形下鲁棒性会下降。为此,人们发展了所谓的上风隐式残差光顺(Upwind Implicit Residual Smoothing,UIRS)方法[15]、[16],它特别适合高马赫数流动。en
The previously discussed CIRS method works satisfactorily for subsonic and transonic flows. It is also helpful in viscous dominated regions. However, CIRS exhibits poor error-damping characteristics in conjunction with upwind spatial discretisation schemes. Furthermore, the robustness of a multistage scheme accelerated by CIRS suffers in the case of strong shocks. Therefore, the so-called Upwind Implicit Residual Smoothing (UIRS) method was developed [15], [16], which is particularly suited for high Mach-number flows.
与CIRS不同,UIRS方法考虑了对流特征值\(\bar{\Lambda}_c\)的符号。其思想是只在欧拉方程特征线的方向上光顺残差(即\(dx/dt = \mathrm{const.} = \Lambda_c\))。这种做法可防止对上游残差产生非物理的影响。UIRS方法要求把残差变换到特征变量(参见附录A.11)。这样,残差向量的每个分量都可以按照相应特征值的符号独立地进行光顺。对于残差的第\(l\)个分量,一维情形下的隐式算子定义为[15]、[16]en
By contrast to CIRS, the UIRS methodology takes the sign of the convective eigenvalues \(\bar{\Lambda}_c\) into account. The idea is to smooth the residuals only in the direction of the characteristic of the Euler equations (i.e., \(dx/dt = \mathrm{const.} = \Lambda_c\)). This approach prevents unphysical influences on the upstream residuals. The UIRS method requires transformation of the residuals into the characteristic variables (cf. Appendix A.11). In this way, each component of the residual vector can be smoothed independently according to the sign of the corresponding eigenvalue. For the \(l\)-th component of the residual, the implicit operator is defined in 1D as [15], [16]
其中\(\vec{R}^{c}\)表示变换到特征变量后的残差,即en
where \(\vec{R}^{c}\) denotes the residual transformed into characteristic variables, i.e.,
光顺后的残差\(\vec{R}^{*}\)通过用Thomas算法求解一个三对角(若\(\Lambda_c^l\)不变号则为二对角)方程组而得到。随后,把残差\(\vec{R}^{*}\)变换回守恒变量,之后即可更新解。en
The smoothed residuals \(\vec{R}^{*}\) are obtained by the solution of a tridiagonal (bidiagonal if \(\Lambda_c^l\) does not change its sign) equation system using the Thomas algorithm. Afterwards, the residuals \(\vec{R}^{*}\) are transformed back into the conservative variables and the solution can be updated.
UIRS最理想的特性在于,它使多级格式具有非常好的阻尼特性,与上风空间离散格式结合时尤其如此。在光顺系数很大时,阻尼解误差的能力仍保持不变甚至有所提高。对一维欧拉方程已经证明,像\(\epsilon = 500\)和\(\sigma^{*} = 1000\)这样的取值可以得到稳定且非常快的显式多级格式[15]、[16](另见CD-ROM中的analysis/mstage)。然而,问题在于UIRS在多维情形下的实现。由于对流通量雅可比矩阵无法在所有坐标方向上同时对角化(见附录A.11),变换式(9.12)与光顺式(9.11)必须对每个计算坐标分别执行。坐标分裂的后果是最大光顺系数降为\(2 \le \epsilon \le 6\)。尽管如此,与CIRS相比,向定常态的收敛仍被大大加速[17]、[16]。在收敛速度与鲁棒性方面最大的改进,出现在与多重网格联合使用时[18]、[16]。en
analysis/mstage)。然而,问题在于UIRS在多维情形下的实现。由于对流通量雅可比矩阵无法在所有坐标方向上同时对角化(见附录A.11),变换式(9.12)与光顺式(9.11)必须对每个计算坐标分别执行。坐标分裂的后果是最大光顺系数降为\(2 \le \epsilon \le 6\)。尽管如此,与CIRS相比,向定常态的收敛仍被大大加速[17]、[16]。在收敛速度与鲁棒性方面最大的改进,出现在与多重网格联合使用时[18]、[16]。enThe most desirable feature of UIRS is that it leads to very favourable damping properties of the multistage scheme, particularly in connection with an upwind spatial discretisation. The ability to damp solution errors remains or even improves for high smoothing coefficients. It was demonstrated for 1-D Euler equations that values like \(\epsilon = 500\) and \(\sigma^{*} = 1000\) result in a stable and very fast explicit multistage scheme [15], [16] (see also in analysis/mstage on the CD-ROM). However, the problem is the implementation of UIRS in multiple dimensions. Since the convective flux Jacobians cannot be diagonalised simultaneously in all coordinate directions (see Appendix A.11), the transformation Eq. (9.12) and the smoothing Eq. (9.11) have to be carried out separately for each computational coordinate. The effect of the coordinate splitting is a reduced maximum smoothing coefficient to \(2 \le \epsilon \le 6\). Despite this, the convergence to the steady state is strongly accelerated as compared to CIRS [17], [16]. The largest improvements in terms of convergence speed and robustness occur in combination with multigrid [18], [16].
多维情形下的光顺系数按特征值进行缩放。例如在二维情形下,可以采用如下公式en
The smoothing coefficients in multiple dimensions are scaled by the eigenvalues. For example, in 2D the following formula can be employed
光顺格式的CFL数与系数\(\epsilon\)之间的关系为en
The relation between the CFL number of the smoothed scheme and the coefficient \(\epsilon\) reads
常数\(C\)取决于空间离散格式的类型。中心格式为\(C = 1\);一阶或二阶上风格式则为\(C = 2\)。en
The constant \(C\) depends on the kind of the spatial discretisation. In the case of the central scheme \(C = 1\). For the 1st- or 2nd-order upwind scheme the value is \(C = 2\).
为了避免变换到特征变量所需的计算量,有人提出了UIRS方法的简化版本[17]、[18]、[16]。按\(I\)方向写出即为en
In order to circumvent the numerical effort of the transformation to the characteristic variables, a simplified version of the UIRS method was suggested [17], [18], [16]. Written in the \(I\)-direction it reads
马赫数\(M\)基于投影到相应计算坐标方向(这里为\(I\))上的速度。由于运算量低,简化UIRS特别适合三维流动问题。文献[16]中证明,与CIRS相比,到达定常态所需的CPU时间可以减半(绕钝头圆柱的高超声速流动,\(M_\infty = 8\))。en
The Mach number \(M\) is based on velocity projected into the direction of the particular computational coordinate (here: \(I\)). Due to the low operation count, the simplified UIRS is especially suitable for 3-D flow problems. In Ref. [16] it was demonstrated that the CPU time needed to reach the steady state can be halved as compared to CIRS (hypersonic flow past a blunt cylinder, \(M_\infty = 8\)).
9.4 Multigrid 多重网格[cfd-9-4]
多重网格(multigrid)方法是一种非常强大的加速技术(参见图3.7)。它基于在一系列逐级加粗的网格上求解控制方程,然后把粗网格上的解更新组合起来,加到最细网格的解上。该技术最初由Brandt[19]为椭圆型偏微分方程而发展,随后由Jameson[20]-[22]应用于欧拉方程。此后,多重网格格式又被用于求解Navier-Stokes方程[11]-[13]、[23]-[31]。多重网格方法既可以结合显式时间推进格式实现,也可以结合隐式时间推进格式实现[32]-[36]。当前研究的目标是显著提高多重网格对双曲型流动问题的效率[37]-[40]。en
The multigrid methodology is a very powerful acceleration technique (cf. Fig. 3.7). It is based on the solution of the governing equations on a series of successively coarser grids. The solution updates from the coarse grid are then combined and added to the solution on the finest grid. The technique was originally developed by Brandt [19] for elliptic partial differential equations and later applied to the Euler equations by Jameson [20]-[22]. After that, the multigrid scheme was employed to solve the Navier-Stokes equations [11]-[13], [23]-[31]. The multigrid method can be implemented for both the explicit and the implicit time-stepping schemes [32]-[36]. The goal of the current research is the significant improvement of the efficiency of multigrid for hyperbolic flow problems [37]-[40].
多重网格格式的基本思想是利用粗网格,使最细网格上的解更快地趋于定常态。为此利用了两种效应:
- 1. 在较粗的网格上可以采用较大的时间步长(因为控制体更大),同时数值工作量也更小。由于求新解的工作主要分布在较粗的网格上,因此收敛更快,计算时间也得以减少。
- 2. 大多数显式和隐式时间推进格式与迭代格式主要能有效削减解误差的高频分量(见10.3节)。低频分量通常很难被阻尼。在初始阶段(最大误差被消除的阶段)过后,这会导致向定常态收敛缓慢。多重网格格式正是在这一点上发挥作用——最细网格上的低频分量在较粗网格上变成高频分量,从而被逐级阻尼掉。其结果是,整个误差被非常迅速地削减,收敛显著加速。
en
The basic idea of the multigrid scheme is to employ coarse grids in order to drive the solution on the finest grid faster to steady-state. Two effects are utilised for this purpose:
- 1. larger time steps can be employed on the coarser grids (owing to a larger control volume) in conjunction with a reduced numerical effort. Since the work for determining a new solution is distributed mainly over the coarser grids, a more rapid convergence and a reduction of the computing time results.
- 2. The majority of the explicit and implicit time-stepping and iterative schemes reduces efficiently mainly the high-frequency components of the solution error (see Section 10.3). The low-frequency components are usually only hardly damped. This results in a slow convergence to the steady state, after the initial phase (where the largest errors are eliminated) is over. The multigrid scheme helps at this point - the low-frequency components on the finest grid becomes high-frequency components on the coarser grids and are successively damped. As a result, the entire error is very quickly reduced, and the convergence is significantly accelerated.
因此可以看到,多重网格格式的成败在很大程度上取决于时间推进格式或迭代格式能否良好地阻尼高频误差分量。en
Thus, as we can see, the success of the multigrid scheme depends heavily on good damping of the high-frequency error components by the time-stepping or iterative scheme.
几何多重网格之外的一种替代方法是代数多重网格(Algebraic Multigrid,AMG)方法[41]-[48]。AMG技术为隐式格式而发展,它直接作用于系统矩阵(即左端算子)。AMG的基本思想是应用一个粗化矩阵来降低隐式算子的维数,从而减少方程的数目。随后求解这个代表粗层的约化系统,以获得细层解的修正。粗化矩阵的构造方式是把耦合最强(即系统矩阵中非对角元最大)的方程相加在一起。这样,粗层的生成完全由流动问题的物理特性决定,而与网格无关。因此,AMG的优点是无需构造或存储粗网格拓扑,这在复杂的非结构网格上尤其有利。en
An alternative to the geometrical multigrid is provided by the Algebraic Multigrid (AMG) method [41]-[48]. The AMG technique was developed for implicit schemes, where it operates directly on the system matrix (the left-hand side operator). The basic idea of AMG is to apply a coarsening matrix in order to reduce the dimension of the implicit operator and hence the number of equations. The reduced system, which represents a coarse level, is then solved to obtain the correction of the fine-level solution. The coarsening matrix is constructed such that the equations with the strongest coupling (i.e., the largest off-diagonals in the system matrix) are added together. Thus, the generation of coarse levels is governed solely by the physics of the flow problem and not by the grid. Therefore, the advantage of AMG is that no coarse grid topology has to be constructed or stored, which is particularly beneficial on complex unstructured grids.
9.4.1 Basic Multigrid Cycle 基本多重网格循环[cfd-9-4-1]
在应用几何多重网格格式之前,必须先生成较粗的网格。标准做法是在所有坐标方向上均匀地粗化网格。不过,Mulder[49]提出了一种称为半粗化(semicoarsening)的方法。此时网格只在一个方向上粗化,且该方向从一个粗层到另一个粗层轮换。半粗化方法特别适合控制方程在某一空间方向上呈刚性的流动问题,边界层中垂直于壁面的方向即为一例。将半粗化应用于Navier-Stokes方程的工作见文献[26]、[50]、[51]。en
Before the geometric multigrid scheme can be applied, the coarser grids have to be generated. The standard way is to coarsen the grid evenly in all coordinate directions. However, Mulder [49] proposed an approach called semicoarsening. Here, the grid is coarsened only in one direction, which is changed from one coarse level to another. The semicoarsening methodology is especially suited for flow problems, where the governing equations are stiff in one spatial direction. An example is the direction normal to the wall in boundary layers. Applications of semicoarsening to the Navier-Stokes equations were reported, e.g., in Refs. [26], [50], [51].
按照关系式(6.1),细网格上离散化的控制方程为en
The discretised governing equations on the fine grid read in accordance with the relationship (6.1)
以下用下标\(h\)表示最细网格,该记号源于网格线的间距(在非结构网格上为控制体的特征尺寸)。从已知解\(\vec{W}^{n}_{h}\)出发,用某个合适的迭代格式经过一个时间步后得到新解\(\vec{W}^{n+1}_{h}\),并用这个解计算新的残差\(\vec{R}^{n+1}_{h}\)。为了利用粗网格改进解\(\vec{W}^{n+1}_{h}\),需要进行以下三个步骤:en
In the following, the finest grid will be denoted by subscript \(h\) in reference to the spacing of the grid lines (characteristic dimension of the control volume on unstructured grids). Starting from a known solution \(\vec{W}^{n}_{h}\), a new solution \(\vec{W}^{n+1}_{h}\) is obtained after one time step with some suitable iterative scheme. A new residual \(\vec{R}^{n+1}_{h}\) is evaluated with this solution. In order to improve the solution \(\vec{W}^{n+1}_{h}\) using a coarse grid, the following three steps are carried out:
1. Transfer of the Solution and Residuals to the Coarser Grid 1. 把解与残差转移到较粗网格
解通过插值转移到粗网格上en
The solution is transferred to the coarse grid by means of the interpolation
其中下标\(2h\)表示粗网格¹,\(\hat{I}^{2h}_{h}\)为插值算子(interpolation operator)。残差也必须转移到粗网格上,以便对其低频误差分量进行光顺。为此采用守恒的转移算子,这意味着当控制体尺寸增大时,残差的值必须增大相同的数量。此外还需要细网格的残差,以便在粗网格上保持细网格解的精度。为此,构造一个源项,即所谓的强迫函数(forcing function)[19]、[22],它等于由细网格转移来的残差与用初始解\(\vec{W}^{(0)}_{2h}\)(式(9.17))在粗网格上计算出的残差之差,即en
where the subscript \(2h\) denotes the coarse grid¹ and \(\hat{I}^{2h}_{h}\) is the interpolation operator. The residuals have to be transferred to the coarse grid as well, so that their low-frequency error components can be smoothed. A conservative transfer operator is employed for this purpose. This means that when the control volume size increases, the value of the residual must increase by the same amount. The residuals of the fine grid are also required in order to retain the solution accuracy of the fine grid on the coarse grid. For this purpose, a source term, the so-called forcing function [19], [22], is formed as the difference between the residual transferred from the fine grid and the residual computed using the initial solution \(\vec{W}^{(0)}_{2h}\) (Eq. (9.17)) on the coarse grid, i.e,
¹原书脚注:The notation 2h must not be understood in a strictly geometric sense. On unstructured grids, the ratio of the characteristic dimensions of the control volumes on the fine and the coarse grid will usually differ from two. The same holds also for semicoarsening.(记号2h不应按严格的几何意义理解。在非结构网格上,细网格与粗网格上控制体特征尺寸之比通常并不等于2。半粗化的情形也是如此。)
这里\(I^{2h}_{h}\)表示把残差从细网格转移到粗网格的限制算子(restriction operator)。这类多重网格格式称为完全近似存储(Full Approximation Storage,FAS)方法[19]。FAS方法特别适合非线性方程,因为系统中的非线性通过重新离散化被带到粗层。en
Here, \(I^{2h}_{h}\) represents the restriction operator which transfers residuals from the fine to the coarse grid. This type of multigrid scheme is known as the Full Approximation Storage (FAS) method [19]. The FAS method is particularly suited for non-linear equations because the nonlinearities in the system are carried down to the coarse levels through the re-discretisation.
2. Calculation of a New Solution on the Coarse Grid 2. 在粗网格上计算新解
于是,时间推进格式可以写成en
Hence, the time-stepping scheme can be written in the form
对于显式多级格式(6.1.1小节),这就导致en
In the case of the explicit multistage scheme (Subsection 6.1.1), this results in
这与式(6.5)一致。需要注意的是,在第一次迭代(式(9.21)中的级)时,\((\vec{R}_F)_{2h}\)与从细网格转移来的残差完全相同(即式(9.18)中的\((\vec{R}_F)_{2h} = I^{2h}_{h}\vec{R}^{n+1}_{h}\))。这保证了粗网格上的解依赖于细网格的残差,从而保持细网格的精度。en
in accordance with Eq. (6.5). It has to be noted that during the first iteration (stage in Eq. (9.21)), \((\vec{R}_F)_{2h}\) is identical to the residual transferred from the fine grid (i.e., \((\vec{R}_F)_{2h} = I^{2h}_{h}\vec{R}^{n+1}_{h}\) from Eq. (9.18)). This guarantees that the solution on the coarse grid depends on the residual of the fine grid and thus retains the accuracy of the fine grid.
粗网格上空间离散格式的精度是一个重要问题。由于粗网格不影响细网格解的精度,一阶格式就足够了。与高阶格式相比,粗网格上一阶精度离散的优点是鲁棒性更强、阻尼特性更好、数值工作量更低。en
An important question is the accuracy of the spatial discretisation scheme on coarse grids. Since the coarse grids do not influence the accuracy of the fine-grid solution, first-order schemes are sufficient. The advantages of first-order accurate discretisation on coarse grids are the increased robustness, better damping properties, and lower numerical effort in comparison to higher-order schemes.
3. Solution Interpolation from the Coarse to the Fine Grid 3. 解由粗网格插值回细网格
在粗网格上进行一个或多个时间步(迭代)之后,计算相对于初始——插值——解(式(9.17))的修正量。这个所谓的粗网格修正(coarse grid correction)由下式给出en
After one or several time steps (iterations) were carried out on the coarse grid, the correction with respect to the initial - interpolated - solution (Eq. (9.17)) is computed. This so-called coarse grid correction is given by
粗网格修正被插值回细网格,以改进那里的解。于是,细网格上的新解为en
The coarse-grid correction is interpolated to the fine grid in order to improve the solution there. Hence, the new solution on the fine grid reads
其中\(I^{h}_{2h}\)称为延拓算子(prolongation operator)。en
where \(I^{h}_{2h}\) is denoted as the prolongation operator.
9.4.2 Multigrid Strategies 多重网格策略[cfd-9-4-2]
上面描述的基本多重网格格式只含一个粗网格。如果存在多个粗网格,则重复步骤1和步骤2,直到到达最粗网格。重要的是要认识到,粗网格上的强迫函数是由式(9.19)限制后的修正残差构成的。例如,在粗网格\(4h\)上,强迫函数由下式得到en
The basic multigrid scheme described above consists of one coarse grid only. If multiple coarse grids are present, steps 1 and 2 are repeated until the coarsest grid is reached. It is important to realize that the forcing function on the coarse grids is formed from the restricted corrected residual of Eq. (9.19)). For example, on the coarse grid \(4h\), the forcing function is obtained from
这样,最细网格的残差控制着所有粗网格上解的精度。在最粗网格上进行给定数目的时间步之后,可以逐层重复步骤3,直到再次到达最细网格。这一过程称为锯齿形循环或V循环(见图9.4a)。不过,也可以在粗网格上执行更多的循环。这种策略称为W循环,如图9.4b所示。它在跨声速流动中采用得尤其频繁。而对于超声速和高超声速流动,V循环被证明效率更高。en
In this way, the residual of the finest grid controls the accuracy of the solution on all coarse grids. After a given number of time steps on the coarsest grid, step 3 can be successively repeated until the finest grid is reached again. This procedure is known as a saw-tooth or V-cycle (see Fig. 9.4a). However, it is also possible to conduct more cycles on the coarse grids. This strategy, termed the W-cycle, is displayed in Fig. 9.4b. It is employed particularly frequently for transonic flows. In the case of supersonic and hypersonic flows, the V-cycle proved to be more efficient.
Number of Time Steps 时间步数
限制前和延拓后的最优时间步数取决于时间推进格式的类型。对于显式多级格式(6.1.1或6.1.2小节),通常在残差限制之前只进行一个时间步,延拓之后不进行时间步。不过,把粗网格修正(式(9.22))在加到细网格解\(\vec{W}^{n+1}_{h}\)(式(9.23))上之前先做光顺,可以改进多重网格格式的鲁棒性。这里采用与9.3节相同的中心隐式光顺(系数取为常数)。en
The optimum number of time steps before the restriction and after the prolongation depends on the type of the time-stepping scheme. In the case of the explicit multistage scheme (Subsection 6.1.1 or 6.1.2), it is common to carry out only one time step before the restriction of residuals and no time step after the prolongation. However, the robustness of the multigrid scheme can be improved by smoothing the coarse grid corrections (Eq. (9.22)) before adding them to the fine grid solution \(\vec{W}^{n+1}_{h}\) (Eq. (9.23)). The same central implicit smoothing (with constant coefficients) as described in Section 9.3 is utilised.
另一种常用的时间推进方法——隐式LU-SGS格式(见6.2.4小节)——为了获得最佳多重网格效率,需要在限制之前进行两次迭代[34]。延拓之后的时间步数则取决于空间离散。对于中心格式(4.3.1小节),不需要时间步[34]-[36],但可以对解修正进行光顺。相反,如果采用上风空间离散,则应在延拓之后进行一个时间步。实践证明,这种(2,1)策略在各种流动条件下的鲁棒性和计算时间方面都是最优的[35]、[36]。en
The other popular time-stepping method, the implicit LU-SGS scheme (see Subsection 6.2.4), requires two iterations before the restriction for the best multigrid efficiency [34]. The number of time steps after the prolongation depends on the spatial discretisation. In the case of the central scheme (Subsection 4.3.1), no time step is necessary [34]-[36], but the solution correction can be smoothed. On the contrary, one time step should carried out after the prolongation if an upwind spatial discretisation is used. This (2,1)-strategy proved to be an optimum with respect to robustness and computing time for various flow conditions [35], [36].
Starting Grid 起始网格
需要指出的是,实际中多重网格格式并不是直接从最细网格开始的。相反,先从某个粗网格开始执行若干个多重网格循环,把近似解插值到下一层较细的网格(采用与延拓相同的算子),再执行几个循环,然后把解再次插值到下一层更细的网格,如此继续,直到最细网格。这样,只需适度的数值工作量,就能在最细网格上获得一个良好的起始解。这一非常高效的过程称为完全多重网格(Full Multigrid,FMG)方法[19]。en
It should be pointed out that in practice the multigrid scheme is not started directly from the finest grid. Instead, several multigrid cycles are executed from one of the coarse grids. The approximate solution is interpolated to the next finer grid (using the same operator as for the prolongation), few more cycles are performed, the solution is again interpolated to the next finer grid and so on, until the finest grid is reached. In this way, a good starting solution is obtained on the finest grid with only a moderate numerical effort. This very efficient procedure is termed the Full Multigrid (FMG) method [19].

图9.4:多重网格循环的类型。图内标注:(a)V-cycle——V循环;(b)W-cycle——W循环;h、2h、4h、8h——网格层(由细到粗);●——限制前的时间步;∘——延拓后的时间步。
Accuracy of Transfer Operators 转移算子的精度
其中\(m_R\)和\(m_P\)分别表示限制算子和延拓算子能够精确插值的多项式的“次数加1”。例如,线性插值时\(m_R\)或\(m_P\)等于2。此外,\(m_E\)表示控制方程的阶数。因此,欧拉方程的\(m_E = 1\),Navier-Stokes方程的\(m_E = 2\)。如果违反条件(9.25),限制和/或延拓引入的额外误差将干扰细网格解,这样的多重网格格式将收敛得非常缓慢,甚至发散。en
where \(m_R\) and \(m_P\) denote the degree plus 1 of the polynomial, which is exactly interpolated by the restriction and the prolongation operator, respectively. For example, \(m_R\) or \(m_P\) are equal to two in the case of linear interpolation. Furthermore, \(m_E\) represents the order of the governing equations. Thus, \(m_E = 1\) for the Euler equations, and \(m_E = 2\) in the case of the Navier-Stokes equations. If the condition (9.25) is violated, the additional errors introduced by the restriction and/or prolongation will disturb the fine-grid solution. Hence, such multigrid scheme will converge only slowly or it will even diverge.
9.4.3 Implementation on Structured Grids 结构网格上的实现[cfd-9-4-3]
多重网格在结构网格上的实现很简单,因为粗网格可以很容易地通过在相应坐标方向上每隔一条删除一条网格线来生成,网格线间距因此为\(2h\)、\(4h\)等。这保证了粗网格上的数值工作量相对于最细网格保持在较低水平。若干代表性例子见文献[11]-[13]、[20]-[22]、[26]、[32]-[36]。en
The implementation of multigrid on structured grids is straightforward since the coarse grids can be easily generated by deleting every second grid line in the respective coordinate direction. The spacing of the grid lines is therefore \(2h\), \(4h\), etc. This guarantees that the numerical effort on the coarse grids stays low as compared to the finest grid. Several representative examples are provided in Refs. [11]-[13], [20]-[22], [26], [32]-[36].

图9.5:细网格(h)与两个粗网格(2h、4h)的一维表示。圆圈表示网格点,矩形表示单元中心。
从图9.5可以得出,解插值算子、残差限制算子和修正延拓算子在单元中心(cell-centred)格式与节点中心(cell-vertex,顶点)格式下必须有不同的定义。例如,相邻两层网格每隔一个网格点就有一个公共点;相反,单元中心的位置总是彼此错开的。因此,下面将分别针对单元中心和节点中心(与顶点格式相同)两种有限体积格式讨论转移算子的标准形式。en
As we can conclude from Fig. 9.5, the operators for the solution interpolation, the restriction of residuals and the prolongation of corrections have to be defined differently for cell-centred and node-centred (cell-vertex) schemes. For example, two successive grids have every second grid point in common. On the contrary, the cell centres are always at different locations. Therefore, we shall discuss the standard forms of the transfer operators separately for the cell-centred and node-centred (identical to cell-vertex) finite-volume schemes.
除了下面将要介绍的对称的、纯几何定义的限制与延拓算子之外,文献[16]第4章还提出了偏上风的形式。计及流动方程特征的上风限制与延拓可以提高多重网格格式在高超声速流动中的鲁棒性。为节省篇幅,下面只针对节点中心空间离散讨论上风延拓算子的实现。en
Apart from the symmetrical, purely geometrically defined restriction and prolongation operators, which will be presented next, upwind-biased forms were suggested in [16], Chapter 4. Upwind restriction and prolongation, which account both for the characteristics of the flow equations, improve the robustness of the multigrid scheme for hypersonic flows. In order to save space, we shall discuss the implementation of an upwind prolongation operator for the node-centred spatial discretisation only.
Transfer Operators for the Cell-Centred Scheme 单元中心格式的转移算子
三维情形采用类似的转移算子,此时求和遍及构成一个粗网格单元的八个细网格控制体。en
Similar transfer operator is employed in 3D, where the summation is over the eight fine-grid control volumes, which form one coarse-grid cell.
限制算子定义为包含在一个粗网格控制体内的所有单元的残差之和。因此,二维情形为(参见图9.6a)en
The restriction operator is defined as a sum of the residuals from all cells which are contained in one coarse-grid control volume. Hence, in 2D we have (cf. Fig. 9.6a)

图9.6:二维结构网格单元中心格式的解插值与残差限制(a),粗网格修正的延拓(b、c)。实心圆=网格点;实心矩形=插值目标单元中心;矩形=插值来源单元中心;粗线=粗网格;细线=细网格。
粗网格修正即式(9.23)的延拓可以用两种不同的方式进行。第一种方式:如果把\(\delta\vec{W}_{2h}\)平均分配给周围所有单元中心(如图9.6b所示),就得到零阶延拓算子。例如en
The prolongation of the coarse-grid correction Eq. (9.23) can be conducted in two different ways. First, a zeroth-order prolongation operator results, if \(\delta\vec{W}_{2h}\) is equally distributed to all surrounding cell centres as indicated in Fig. 9.6b. Thus, for instance
第二种方式能使多重网格格式收敛更快,它分两步进行。第一步,把\(\delta\vec{W}_{2h}\)插值到网格节点上,做法与顶点格式相同(见下文)。第二步,对节点值取平均,得到细网格单元中心的值。参照图9.6c,可以推导出如下最终关系式en
The second possibility, which leads to a faster convergence of the multigrid scheme, consists of two steps. In a first step, \(\delta\vec{W}_{2h}\) is interpolated to the grid nodes like for the cell-vertex scheme (see below). In a second step, the nodal values are averaged to obtain the value in the centre of the fine-grid cell. Referring to Fig. 9.6c, the following final relationship can be derived
三维情形的对应表达式可以通过类似的过程得到,为en
The corresponding expression in 3D can be found by a similar procedure. It reads
Transfer Operators for the Cell-Vertex Scheme 顶点格式的转移算子
由于细网格与粗网格拥有公共节点,解可以简单地通过直接注入(injection)来转移,即en
Because of the common nodes between the fine and coarse grid, the solution can be transfered simply by injection, i.e.,
标准的中心限制算子是对构成一个粗网格单元的四个(三维为八个)细网格单元的所有节点作线性插值。按照图9.7,二维情形的限制残差计算为en
The standard central restriction operator represents a linear interpolation from the nodes of all four (eight in 3D) fine-grid cells, which resemble one coarse-grid cell. According to Fig. 9.7, the restricted residual is computed in 2D as

图9.7:二维结构网格顶点格式的限制(a)与延拓(b)的插值系数。实心圆=插值目标点;圆圈=插值来源点;粗线=粗网格;细线=细网格。点(i, j)为两网格共有。
三维情形,细网格残差按下式收集en
In 3D, the fine-grid residuals are collected as follows
其中各因子为en
with the factors

图9.8:二维上风延拓。点A、B、C、D为粗网格(粗线)与细网格共有;点e、f、e′、f′、g仅属于细网格(细线)。
式(9.34)中只标出了与\(i, j, k\)不同的那些下标。需要注意的是,在限制之前必须先把所有物理边界点和虚单元点上的残差\(\vec{R}^{n+1}_{h}\)置为零。en
In the above Eq. (9.34), only those indices are shown which are different from \(i, j, k\). It should be noted that the residuals \(\vec{R}^{n+1}_{h}\) must be set to zero at all physical boundary and dummy points before the restriction.
粗网格修正的延拓可以实现对粗网格点的循环:在循环内,把值\((\delta\vec{W}_{2h})_{i,j,k}\)用与限制相同的权重分配到细网格点上(参见图9.7b),并把各部分贡献累加起来,从而得到细网格每一点上完整的转移修正量。en
The prolongation of the coarse-grid correction can be implemented as a loop over the points of the coarse grid. Within the loop, the values \((\delta\vec{W}_{2h})_{i,j,k}\) are distributed to the fine-grid points using the same weights as for the restriction (cf. Fig. 9.7b). The particular contributions are summed up in order to obtain the complete transfered correction at each point of the fine grid.
Upwind Prolongation (Cell-Vertex Scheme) 上风延拓(顶点格式)
原则上,上风延拓既可以在特征变量中表述,也可以在守恒变量中表述。文献[16]提出了一种特别高效的守恒变量实现。该方法根据马赫数和速度方向对式(9.23)中的修正作偏上风插值。其数值代价非常低,但对于高马赫数流动却能显著改善多重网格格式的鲁棒性[16]。en
In principle, upwind prolongation can be formulated either in characteristic or in conservative variables. A particularly efficient implementation in conservative variables was proposed in [16]. The methodology employs upwind-biased interpolation of the corrections in Eq. (9.23) according to the Mach number and the velocity direction. The numerical effort is very low, nevertheless the robustness of the multigrid scheme can be significantly improved for high Mach-number flows [16].
把解修正\(\delta\vec{W}_{2h}\)插值到较细网格分两步完成。第一步,把两网格共有的点\(A\)、\(B\)、\(C\)、\(D\)(见图9.8)处的修正直接转移到较细网格。第二步,把修正插值到仅存在于较细网格上的点\(e\)、\(f\)、\(e'\)、\(f'\)和\(g\)。插值取决于相应点马赫数的符号和绝对值。这里的马赫数用逆变速度计算en
The interpolation of the solution corrections \(\delta\vec{W}_{2h}\) to the finer grid is accomplished in two steps. In the first step, the corrections at the points \(A\), \(B\), \(C\), and \(D\) (see Fig. 9.8), which are common to both grids, are transferred directly to the finer grid. In the second step, the corrections are interpolated to the points \(e\), \(f\), \(e'\), \(f'\) and \(g\), which are contained only on the finer grid. The interpolation depends on the sign and the absolute value of the Mach number at the corresponding point. The Mach number in this case is calculated using
式(9.35)中的法向向量\(\vec{n}\)既可以由控制体面向量平均得到(沿\(A-B\)方向),也可以由点\(A\)到点\(B\)的向量归一化得到。然后,按如下规则把修正转移到点\(e\)en
is employed. The normal vector \(\vec{n}\) in Eq. (9.35) can be obtained either by averaging the face vectors of the control volume (in the direction \(A-B\)), or by normalising the vector from point \(A\) to point \(B\). Then, the correction is transferred to point \(e\) according to the rule
同样的过程也适用于点\(f\)到\(f'\)。上风处理有助于使网格间的信息交换更好地与真实物理相匹配。往点\(g\)的插值则更困难。文献[16]中只是简单地对周围点\(A\)到\(D\)的值取平均en
The same procedure applies also to the points \(f\) to \(f'\). The upwinding helps to match the information exchange between the grids better to the real physics. The interpolation to the point \(g\) is more difficult. In Ref. [16], the values at the surrounding points \(A\) to \(D\) were simply averaged
不过,某种上风加权插值会更合适。上风延拓也可以在三维中以类似方式实现。尽管作了简化,仍在多个测试算例中得到了令人鼓舞的结果[16]。en
However, some sort of upwind weighted interpolation would be more appropriate. The upwind prolongation can be implemented in similar way also in 3D. Despite the simplification, encouraging results were obtained in a number of test cases [16].
9.4.4 Implementation on Unstructured Grids 非结构网格上的实现[cfd-9-4-4]
与结构网格相比,非结构网格情形下粗网格的构造要复杂得多。问题在于如何从一组没有任何特定排序的单元(网格单元)出发,构造出均匀粗化的网格。此外,粗网格与细网格的单元体积之比也必须保持在一定的范围内(二维约为4,三维约为8)。解决该问题的一种可能途径是采用AMG方法[41]-[48],我们在9.4节开头已简要讨论过。不过,几何多重网格目前仍使用得更广泛,因此这里集中讨论这一方法。en
As compared to the structured grids, the construction of the coarse grids is much more involved in the case of unstructured grids. The problem is how to construct an uniformly coarsened grid from a set of elements (grid cells) which have no particular ordering. Additionally, the ratio of the cell volumes of the coarse to the fine grid has to stay within a certain margins (about 4 in 2D and 8 in 3D). One possibility how to solve this problem is to apply the AMG methodology [41]-[48], which we briefly discussed at the beginning of Section 9.4. However, the geometric multigrid is still more widely used. Therefore, we shall concentrate here on this approach.
粗网格的生成主要有三类方法:
- 非嵌套网格(nonnested-grids)方法;
- 拓扑方法;
- 控制体聚合。
对上述方法的综述见文献[53]和[54]。en
Three main methods for the generation of coarse grids can be identified:
- nonnested-grids approach,
- topological methods, and
- agglomeration of control volumes.
Reviews of the above methods were presented in Refs. [53] and [54].
标准的限制与延拓算子基于纯几何定义的插值。Leclerq和Stoufflet[55]提出了上风转移算子,对含强激波的流动尤其有前景。他们的上风限制/延拓先把残差/修正变换到特征变量,作偏上风插值之后,再把限制/延拓后的值变换回物理变量。文献[16]给出了一种数值代价低得多的上风多重网格方法(另见9.4.3小节式(9.36))。en
The standard restriction and prolongation operators are based on purely geometrically defined interpolation. Leclerq and Stoufflet [55] suggested upwind transfer operators, which are particularly promising for flows with strong shocks. Their upwind restriction/prolongation is based on the transformation of the residuals/corrections into the characteristic variables. After an upwind-biased interpolation, the restricted/prolongated values are transformed back into the physical variables. Numerically much less expensive upwind multigrid method was presented in Ref. [16] (see also Subsection 9.4.3, Eq. (9.36)).
Nonnested Grids 非嵌套网格
最直观的想法是生成一系列完全独立的、逐级加粗的网格[56]-[61]。这些网格不必含有任何公共节点,因此称为非嵌套网格(nonnested grids)。然而,重要的几何特征(前后缘、机身头部等)必须在所有粗网格上保留下来,这在几何外形复杂时并不容易做到。如今基于非嵌套网格的多重网格已很少使用。en
The most obvious idea is to generate a sequence of completely independent, increasingly coarser grids [56]-[61]. It is not necessary that the grids contain any common nodes. Therefore, we speak of nonnested grids. However, it is important that the main geometrical features (leading and trailing edge, fuselage nose, etc.) are retained on all coarse grids. This is not easy to accomplish, particularly in the case of a geometrically complex configuration. Multigrid based on nonnested grids is hardly used today.
Topological Methods 拓扑方法
一种具体的做法是应用基于图的算法从细网格中删除某些节点,然后对剩余节点重新三角化[62]、[63]。与非嵌套网格方法相反,由于相邻网格含有公共节点,网格间的插值变得更容易。但在几何贴合性方面,该方法继承了非嵌套网格的缺点。en
One particular approach applies graph-based algorithms in order to remove certain nodes from the fine grid. The remaining nodes are then re-triangulated [62], [63]. On the contrary to the nonnested-grids approach, the interpolation between the grids becomes easier, since the successive grids contain common nodes. However, the method inherits the drawback of the nonnested grids with respect to geometry conformance.
另一种拓扑方法采用网格加密(grid refinement)[64]、[29]、[65]:从粗网格出发,通过单元剖分生成更细的网格。该方法既可以在整个物理域上应用,也可以只在局部(如边界层处)应用。其缺点是最细网格的质量强烈依赖于初始粗网格和加密过程。这个问题可以部分地通过边交换(edge swapping)[66]、[67]来缓解。en
A further topological method employs grid refinement [64], [29], [65]. The technique starts from a coarse grid and generates finer grids by element division. The methodology can be applied either over the whole physical domain or only locally (e.g., at boundary layers). The disadvantage of this approach is that the quality of the finest grid strongly depends on the initial coarse grid and the refinement procedure. The problem can be partially cured by edge swapping [66], [67].
生成粗网格的另一个想法基于边收缩(edge collapsing)[68]。它最初是为四面体网格上的无黏流动发展的,后来在文献[69]中被推广到混合单元网格上的黏性流动。en
Another idea for the generation of coarse grids is based on edge collapsing [68]. It was initially developed for inviscid flows on tetrahedral grids. The edge-collapsing method was further extended to viscous flows on mixed-element grids in [69].
Agglomeration Multigrid Method 聚合多重网格方法
非结构网格上一种非常高效的方法是所谓的聚合多重网格(agglomeration multigrid)。它最早由Lallemand[70]、Lallemand等[71]以及Koobus等[72]提出。后来,多位作者采用了聚合多重网格[73]-[77]、[31]。该方法通过把细网格的控制体与其邻居融合来生成粗网格,得到的粗网格由逐级增大的、形状不规则的多面体单元组成,如图9.9所示。可以看到,聚合技术完整保留了边界表面的离散,这是它相对于前面讨论的所有非结构多重网格方法的一个显著优点。不过应当指出,迄今为止聚合多重网格的实现大多基于中位对偶顶点格式(median-dual cell-vertex scheme,5.2.2小节)。聚合多重网格在单元中心格式(5.2.1小节)上的应用见文献[73]。en
A very efficient methodology for unstructured grids is the so-called agglomeration multigrid. It was first presented by Lallemand [70], Lallemand et al. [71] and by Koobus et al. [72]. Later on, the agglomeration multigrid was adopted by various authors [73]-[77], [31]. The method generates a coarse grid by fusing the control volumes of the finer grid with their neighbours. The resulting coarse grids consist of successively larger, irregularly shaped polyhedral cells. This is depicted in Fig. 9.9. As we can see, the agglomeration technique retains the full discretisation of the boundary surfaces. This represents a significant advantage over all previously discussed unstructured multigrid methods. However, it should be mentioned that up to now, implementations of the agglomeration multigrid were based mostly on the median-dual cell-vertex scheme (Subsection 5.2.2). The application of the agglomeration multigrid to a cell-centred scheme (Subsection 5.2.1) was described in [73].
Generation of Coarse Grids by Volume Agglomeration 体积聚合生成粗网格
节点中心格式的体积聚合按以下步骤进行:
- 1. 建立所谓的种子点(seed points)列表。种子点是被选中用来聚合周围控制体的网格点。种子点列表既可以包含那些构成近似极大独立集[75]的点,也可以简单地包含当前网格层的全部点。
- 2. 遍历所有种子点。
- 3. 如果该种子点尚未聚合,则聚合其所有尚未聚合的最近邻(由一条边相连)。
- 4. 检查粗化比(即一个粗网格控制体内包含多少个细网格控制体)。如果粗化比小于4(三维为8),则把已聚合最近邻的邻居(若未关联到其他种子点)加入进来,直至达到最优粗化比。文献[27]提出优先聚合那些至少与两个(三维为三个)已聚合最近邻相连的距离为2的邻居。
- 5. 如果列表中仍有种子点,转到步骤2。
- 6. 消除单例(singletons)。单例是指因没有未聚合的邻居而未能被聚合的孤立控制体。把单例与粗化比最小的相邻控制体聚合,即可将其消除。这样得到的粗网格层,其控制体面积的分布更加规则[31]。
en
The volume agglomeration for a node-centred scheme proceeds in the following steps:
- 1. build a list of the so-called seed points. Seed points are grid points selected to agglomerate the surrounding control volumes. The list of seed points can contain either those points which form an approximate maximal independent set [75], or simply all points of the current grid level.
- 2. Loop over all seed points.
- 3. If the seed point is unagglomerated, agglomerate all its nearest neighbours (connected by an edge), which were not already agglomerated.
- 4. Check the coarsening ratio (i.e., how many fine-grid control volumes are contained within a coarse-grid volume). If the ratio is less than four (eight in 3D), the neighbours of the already agglomerated nearest neighbours are added (if not associated with another seed point), until the optimum coarsening ratio is achieved. In Ref. [27], it was proposed to agglomerate those distance-two neighbours first, which are connected to at least two (three in 3D) agglomerated nearest neighbours.
- 5. If there are still seed points in the list, goto step 2.
- 6. Eliminate singletons. These are single control volumes which could not be agglomerated, because there were no unagglomerated neighbours. A singleton can be eliminated by agglomeration with such neighbouring control volume, which has the smallest coarsening ratio. This leads to coarse-grid levels with a more regular distribution of control-volume areas [31].
重复上述过程,直到所有粗网格都生成完毕。en
The above procedure is repeated until all coarse grids are generated.
为了保持网格的各向同性,体积聚合必须从边界开始。在三维情形,可能需要用户根据边界的形状指定聚合方向。为克服这一困难,Okamoto等[77]提出了另一种称为全局粗化(global coarsening)的算法。该方法采用基于边着色(edge colouring)的全局剖分方案;剖分方案用来生成一个独立的边集。第二步,把共享独立边集中一条边的所有控制体聚合起来。重复这一过程,直到达到预定的粗化比。该方法不需要指定初始种子点或聚合方向,还可以处理任何类型的网格单元。en
The volume agglomeration has to start from the boundary in order to preserve grid isotropy. In 3D, user intervention may be required to prescribe the agglomeration direction depending on the shape of the boundary. To overcome this difficulty, Okamoto et al. [77] proposed another algorithm denoted as global coarsening. The method employs a global partitioning scheme, which is based on edge colouring. The partitioning scheme is used to generate an independent set of edges. In a second step, all control volumes, which share an edge of the independent set, are agglomerated. The procedure is repeated until the prescribed coarsening ratio is achieved. The method does not require the specification of an initial seed point or agglomeration direction. It can also treat any type of grid cells.

图9.9:二维聚合多重网格(中位对偶格式)生成粗网格。图序自上而下依次为最细网格与三个粗网格。
Problems of Agglomeration Multigrid 聚合多重网格的问题
对无黏流动,聚合多重网格的实现几乎没有困难。欧拉方程一般按各个控制体面上的通量来离散,因此控制体的形状多么复杂并不重要(实际上采用的是平均面向量)。此外,一阶精度的空间格式只需要相邻控制体内流动量的信息,而这些信息在粗网格上很容易获得。en
The implementation of agglomeration multigrid presents little difficulty for inviscid flows. The Euler equations are in general discretised as fluxes over individual control-volume faces. In this respect, it does not matter how complex is the shape of the control volume (in fact, averaged face vectors are used). Furthermore, a first-order accurate spatial scheme requires the knowledge of flow quantities in the neighbouring control volumes only. This information is readily available on the coarse grids.
对黏性流动,在任意形状的控制体上离散黏性通量不再那么直接,问题在于面中点处梯度的计算(参见文献[31]中的讨论)。另一个甚至更严重的困难与延拓算子所要求的精度有关。式(9.25)的不等式表明\(m_P = 2\),因为常用的限制算子(残差求和)只能给出\(m_R = 1\)。然而,在粗网格上构造线性插值并不容易。en
In the case of viscous flows, the discretisation of the diffusive fluxes on arbitrary shaped control volumes is no longer straightforward. The problem is the evaluation of gradients at face midpoints (see the discussion in [31]). Another, and even more serious, difficulty is related to the required accuracy of the prolongation operator. The inequality in Eq. (9.25) suggests \(m_P = 2\), since the common restriction operator (sum of residuals) leads to \(m_R = 1\) only. However, the construction of a linear interpolation is not easy on the coarse grids.
为了避免构造一阶精度的延拓算子,Mavriplis[53]提出采用常数延拓(即聚合粗网格体积内的所有细网格点都得到相同的解修正),并对黏性通量进行缩放。然而,这一做法无法达到最优的多重网格效率。en
In order to circumvent the construction of a first-order accurate prolongation operator, Mavriplis [53] proposed to use constant prolongation (i.e., all points of the fine grid contained within an agglomerated coarse-grid volume get the same solution correction) and a scaling of the viscous fluxes. However, this approach does not lead to optimal multigrid efficiency.
Haselbacher[31]建议在粗网格上也保留黏性通量的细网格离散,并像在最细网格上那样施加边界条件。此外,他提出了一种分段线性延拓算子。对标量量\(U\),它可以写成en
Haselbacher [31] suggested to retain the fine-grid discretisation of the viscous fluxes also on the coarse grids and to enforce the boundary conditions like on the finest grid. Moreover, he proposed a piecewise linear prolongation operator. For a scalar quantity \(U\), it can be written as
式(9.38)中的梯度\((\nabla\delta U_{2h})_i\)用5.3.4小节式(5.55)所述的线性最小二乘重构计算。限制器函数\(\Psi_i\)的值按5.3.5小节介绍的Barth-Jespersen限制器函数求值。en
The gradient \((\nabla\delta U_{2h})_i\) in Eq. (9.38) is calculated by using the linear least-squares reconstruction described in Subsection 5.3.4, Eq. (5.55). The values of the limiter function \(\Psi_i\) are evaluated according to the Barth-Jespersen limiter function presented in Subsection 5.3.5.
9.5 Preconditioning for Low Mach Numbers 低马赫数预条件[cfd-9-5]
在低亚声速马赫数范围,当流动速度的大小与声速相比变得很小时,控制方程(2.19)的对流项呈现刚性。我们可以用下面的例子来演示这一点。在三维情形,我们有五个特征值en
In the low subsonic Mach number regime, when the magnitude of the flow velocity becomes small in comparison with the acoustic speed, the convective terms of the governing equations (2.19) become stiff. We can demonstrate this with the following example. In the 3-D case, we have the five eigenvalues
其中\(V\)表示逆变速度,\(c\)为声速。控制方程(按时间推进时)的刚性由特征条件数(condition number)决定。该数定义为最大特征值与最小特征值之比en
where \(V\) denotes the contravariant velocity and \(c\) the speed of sound. The stiffness of the governing equations (when marching in time) is determined by the characteristic condition number. This number is defined as the ratio of the largest to the smallest eigenvalue
允许的局部时间步长受最快的波限制,即受\((\Lambda_c)_4\)限制。在一个时间步内,最慢的波只移动了单元宽度的一小部分:\(\Lambda_{min}\Delta t \approx \left(\Lambda_{min}/\Lambda_{max}\right)h = h/C_N\)。因此,大的条件数\(C_N\)(即\(M \rightarrow 0\)时)会降低波传播的效率——它减慢向定常状态的收敛[78]。此外,文献[79]、[80]中证明,可压缩流动的格式所具有的人工耗散量在马赫数趋近于零时无法正确缩放。因此,这类空间离散在低马赫数下的精度会受损[81]。en
The allowable local time step is limited by the fastest wave, i.e, by \((\Lambda_c)_4\). During one time step, the slowest wave moves only over a fraction of the cell width: \(\Lambda_{min}\Delta t \approx \left(\Lambda_{min}/\Lambda_{max}\right)h = h/C_N\). Thus, a large condition number \(C_N\) (i.e., for \(M \rightarrow 0\)) reduces the efficiency of wave propagation - it slows down the convergence to steady state [78]. Furthermore, it was demonstrated in [79], [80] that schemes for compressible flows have an amount of artificial dissipation which does not scale correctly for Mach numbers approaching zero. Thus, the accuracy of such spatial discretisation suffers at low Mach numbers [81].
如果整个流场内的速度都很低(\(M < 0.2\)),那么压缩性效应可以忽略,并可以采用不可压缩方程。不可压缩Navier-Stokes方程可以用著名的压力基(pressure-based)格式求解[82]。另一种可能性是采用人工可压缩性(artificial compressibility,或称伪可压缩性)方法[83]-[89]。然而,存在如下类型的流动情形:
- 高速流动中内嵌大范围低速区域。一个例子是强收敛喷管上游的亚声速流动。
- 由于热源引起的密度变化而具有可压缩性的低速流动。表面传热或体积加热(燃烧模拟)时就会出现这种情况。
- 可压缩与不可压缩流动在不同马赫数下并存的问题——我们称之为全速流动(all-speed flows)。例如,在推进、高升力构型以及V/STOL机动中就会出现这种情形。
en
If the velocity in the entire flow field is low (\(M < 0.2\)), then the compressibility effects can be neglected and the incompressible equations can be utilised. The incompressible Navier-Stokes equations can be solved by the well-known pressure-based schemes [82]. The other possibility is the application of the artificial compressibility (or pseudo-compressibility) method [83]-[89]. However, there are flow cases like:
- high-speed flows with large embedded regions of low velocity. An example is the subsonic flow upstream of a strongly converging nozzle.
- Low-speed flows which are compressible due to density changes induced by heat sources. This occurs for surface heat transfer or volumetric heat addition (combustion simulation).
- Problems, where compressible and incompressible flow at varying Mach numbers occur side by side - we speak of all-speed flows. Such situation arises, for instance, in propulsion, for high-lift configurations and in V/STOL manoeuvring.
这些情形要求应用可压缩控制方程。为了在低马赫数下高效且精确地求解它们,可以采用预条件(preconditioning)。预条件的优点在于,它使得一种适用于所有马赫数的求解方法成为可能。下面,我们将推导预条件控制方程。en
Such cases require the application of the compressible governing equations. In order to solve them efficiently and accurately at low Mach numbers, preconditioning can be employed. The advantage of preconditioning is that it enables a solution method, which is applicable at all Mach numbers. In the following, we shall derive the preconditioned governing equations.
9.5.1 Derivation of Preconditioned Equations 预条件方程的推导[cfd-9-5-1]
我们以一维欧拉方程为例来演示预条件。它们可以写成微分形式en
We demonstrate preconditioning with the aid of 1-D Euler equations. They can be written in differential form as
其中\(\vec{W} = [\rho,\ \rho u,\ \rho E]^T\)为守恒变量向量,\(\vec{F}_c\)表示对流通量。为了考察预条件对谱半径(对时间步长的计算很重要)以及对流通量雅可比矩阵(对上风耗散很重要)的影响,把欧拉方程(9.41)改写为准线性形式en
where \(\vec{W} = [\rho,\ \rho u,\ \rho E]^T\) is the vector of conservative variables and \(\vec{F}_c\) denotes the convective fluxes. In order to see the effect of preconditioning on the spectral radii (important for the computation of the time step) and on the convective flux Jacobian (important for upwind dissipation), the Euler equations (9.41) are rewritten in the quasilinear form
其中\(\bar{A}_c = \partial\vec{F}_c/\partial\vec{W}\)为对流通量雅可比矩阵(参见附录A.2)。en
with \(\bar{A}_c = \partial\vec{F}_c/\partial\vec{W}\) being the convective flux Jacobian (cf. Appendix A.2).
低马赫数预条件背后的想法是变换控制方程(9.41),使新方程在低马赫数(即低于\(M \approx 0.2\))下具有更有利的性质。首先,我们希望均衡对流特征值,以约束条件数(见式(9.40)),从而消除\(M \rightarrow 0\)时的刚性。其次,我们希望改变数值耗散的缩放方式,以提高精度。最后,我们希望像压力基格式中那样把压力和速度耦合起来。这一变换用另一组流动变量取代守恒变量\(\vec{W}\)。可以有多种选择[90],但最常用的是压力、速度分量和温度。把式(9.42)中的准线性形式变换到新变量\(\vec{W}_p\),我们得到en
The idea behind low Mach-number preconditioning is to transform the governing equations (9.41) such that the new equations have more favourable properties at low Mach numbers (i.e. below \(M \approx 0.2\)). First of all, we want to equalise the convective eigenvalues in order to bound the condition number (see Eq. (9.40)) and thus to remove the stiffness at \(M \rightarrow 0\). We further want to change the scaling of the numerical dissipation in order to improve the accuracy. Finally, we want to couple the pressure and the velocity as it is done in the pressure-based schemes. The transformation replaces the conservative variables \(\vec{W}\) by a different set of flow variables. Various choices are possible [90], but the most often used are the pressure, the velocity components and the temperature. Transforming the quasilinear form in Eq. (9.42) into the new variables \(\vec{W}_p\), we obtain
在上面的式(9.43)中,\(\bar{P} = \partial\vec{W}/\partial\vec{W}_p\)表示从新变量\(\vec{W}_p\)到守恒变量\(\vec{W}\)的变换矩阵。引入新的通量雅可比矩阵en
In the above Eq. (9.43), \(\bar{P} = \partial\vec{W}/\partial\vec{W}_p\) represents the transformation matrix from the new variables \(\vec{W}_p\) into the conservative variables \(\vec{W}\). Introducing a new flux Jacobian
或等价地en
or equivalently
或者en
or
现在可以看到,守恒变量下的预条件方程(9.49)、(9.50)具有如下特点:
- 空间导数都乘以\(\bar{P}\bar{\Gamma}^{-1}\)。
- 非定常方程与式(9.42)的原始形式不同,因此解不再具有时间精度。
- 定常解(即\(\partial\vec{W}/\partial t = 0\))保持不变。
- 预条件系统的特征值和特征向量对应于矩阵\(\bar{P}\bar{\Gamma}^{-1}\bar{A}_c = \bar{P}\bar{\Gamma}^{-1}\bar{A}_{c,p}\bar{P}^{-1}\)的特征值和特征向量,因而与式(9.41)中原系统的不同。
en
We can see now that the preconditioned equations in the conservative variables (9.49), (9.50) have the following features:
- Spatial derivatives are multiplied by \(\bar{P}\bar{\Gamma}^{-1}\).
- Unsteady equations are different from the original form in Eq. (9.42) and hence the solution is no longer time accurate.
- Stationary solution (i.e. \(\partial\vec{W}/\partial t = 0\)) remains unchanged.
- Eigenvalues and eigenvectors of the preconditioned system correspond to those of the matrix \(\bar{P}\bar{\Gamma}^{-1}\bar{A}_c = \bar{P}\bar{\Gamma}^{-1}\bar{A}_{c,p}\bar{P}^{-1}\) and hence are different from those of the original system in Eq. (9.41).
现在的主要任务是找到一组合适的变量\(\vec{W}_p\)和矩阵\(\bar{\Gamma}\),使预条件系统(9.50)的对流特征值尽可能接近地被均衡。但同样重要的是,这些矩阵在\(M \rightarrow 0\)时必须仍有定义。此外,最好预条件系统在较高马赫数下能退化为原系统。en
The main task is now to find a suitable set of variables \(\vec{W}_p\) and the matrix \(\bar{\Gamma}\) such that the convective eigenvalues of the preconditioned system (9.50) are equalised as close as possible. But it is also important that the matrices remain defined for \(M \rightarrow 0\). Furthermore, it is desirable that the preconditioned system converts into the original system for higher Mach numbers.
在9.5.3小节给出变换矩阵和预条件矩阵之前,我们先讨论低马赫数预条件在流场解算器中的实现。en
Before we present the transformation and preconditioning matrices in Subsection 9.5.3, we shall discuss the implementation of the low Mach number preconditioning in a flow solver.
9.5.2 Implementation 实现[cfd-9-5-2]
采用显式多级格式(见6.1节所述)求解预条件控制方程(9.51)时,按以下步骤进行:
- 1. 基于矩阵\(\bar{P}\bar{\Gamma}^{-1}\bar{A}_c\)的谱半径计算新的时间步长。
- 2. 利用谱半径(如JST格式)或预条件通量雅可比矩阵的特征值和特征向量(如Roe上风格式)计算人工耗散。耗散项既可以在守恒变量下构造,也可以在原始变量下构造[90]。
- 3. 计算对流通量(或者不作改动,或者基于新变量\(\vec{W}_p\))。
- 4. 把耗散通量和对流通量相加。根据人工耗散的构造方式,或者将整个残差,或者仅将对流项乘以守恒变量预条件矩阵,即乘以\(\bar{P}\bar{\Gamma}^{-1}\)。
- 5. 将残差乘以\(\alpha_k\Delta t/V\)。
- 6. (可选)执行隐式残差光顺。
- 7. 从旧守恒变量\(\vec{W}^{(0)}\)中减去残差,以得到新守恒变量\(\vec{W}^{n+1}\)。
- 8. 更新边界条件(注意:所有基于特征变量的边界条件——如入流、出流、远场——都需要修改)。
en
The solution of the preconditioned governing equations (9.51) using an explicit multistage scheme (described in Section 6.1) proceeds according to the following steps:
- 1. Compute a new time step based on the spectral radii of the matrix \(\bar{P}\bar{\Gamma}^{-1}\bar{A}_c\).
- 2. Evaluate artificial dissipation using the spectral radii (e.g., JST scheme) or the eigenvalues and eigenvectors of the preconditioned flux Jacobian (e.g., Roe upwind scheme). The dissipation can be formulated either in the conservative or in the primitive variables [90].
- 3. Compute the convective fluxes (either without change or based on the new variables \(\vec{W}_p\)).
- 4. Sum up the dissipative and convective fluxes. Depending on the formulation of the artificial dissipation, either the whole residual or just the convective terms are multiplied by the conservative variable preconditioning matrix, i.e. by \(\bar{P}\bar{\Gamma}^{-1}\).
- 5. Multiply the residual by \(\alpha_k\Delta t/V\).
- 6. Carry out the implicit residual smoothing (optionally).
- 7. Subtract the residuals from the old conservative variables \(\vec{W}^{(0)}\) in oder to obtain the new conservative variables \(\vec{W}^{n+1}\).
- 8. Update the boundary conditions (note that all boundary conditions which are based on the characteristic variables - like inflow, outflow, farfield - need to be changed).
隐式格式遵循类似的步骤,只是省略第5步和第6步,并且守恒变量以不同的方式更新(参见6.2节)。还应注意,由于雅可比矩阵为\(\bar{P}\bar{\Gamma}^{-1}\bar{A}_c\),预条件必须包含在隐式算子中。en
Similar procedure is followed for an implicit scheme, only the steps 5. and 6. are omitted and the conservative variables are updated in a different way (cf. Section 6.2). It should also be noted that the preconditioning has to be included in the implicit operator since the Jacobian is \(\bar{P}\bar{\Gamma}^{-1}\bar{A}_c\).
预条件后的标量耗散格式(JST)取如下形式(见式(4.50))en
The preconditioned scalar dissipation scheme (JST) takes the form (see Eq. (4.50))
注意,如果之后要把整个残差乘以\(\bar{P}\bar{\Gamma}^{-1}\),就需要项\(\bar{\Gamma}\bar{P}^{-1}\),因为谱半径\(\hat{\Lambda}^S\)已经包含了预条件矩阵(因此它与式(4.53)不同)。在式(9.52)中,也可以把\(\bar{P}^{-1}\)与\(\vec{W}\)合并为\(W_p\)。这样,我们可以用原始变量表述预条件的标量耗散格式:en
Note that the term \(\bar{\Gamma}\bar{P}^{-1}\) is required if the complete residual is later multiplied by \(\bar{P}\bar{\Gamma}^{-1}\), since the spectral radius \(\hat{\Lambda}^S\) already contains the preconditioning matrix (thus it is different from Eq. (4.53)). It is also possible to combine \(\bar{P}^{-1}\) and \(\vec{W}\) into \(W_p\) in Eq. (9.52). Then, we can formulate the preconditioned scalar dissipation scheme in primitive variables as
必须认识到,此时只有对流通量乘以\(\Gamma^{-1}\),然后整个残差再乘以\(\bar{P}\)。式(9.53)的非守恒形式比关系式(9.52)稍微简单一些,但对于内流或含激波的流动存在精度问题。en
It is important to realize that in this case only the convective fluxes are multiplied by \(\Gamma^{-1}\) and the complete residual then by \(\bar{P}\). The nonconservative form in Eq. (9.53) is somewhat simpler than the relation (9.52), however there are problems with the accuracy for internal flows or for flows containing shocks.
预条件后的Roe上风格式可以写成(参见式(4.91))en
The preconditioned Roe upwind scheme can be written as (cf. Eq. (4.91))
其中\(|\bar{A}_{Roe}| = \bar{T}_{c,p}|\bar{\Lambda}_{c,p}|\bar{T}_{c,p}^{-1}\)。左特征向量(\(\bar{T}_{c,p}^{-1}\))、右特征向量(\(\bar{T}_{c,p}\))以及特征值(\(\bar{\Lambda}_{c,p}\))都是矩阵\(\bar{P}\bar{\Gamma}^{-1}\bar{A}_c = \bar{P}\bar{\Gamma}^{-1}\bar{A}_{c,p}\bar{P}^{-1}\)的。在\((I + 1/2)\)处的流动变量值由式(4.89)给出的Roe平均获得,并且整个残差乘以\(\bar{P}\bar{\Gamma}^{-1}\)。同样,式(9.54)的预条件Roe格式也可以用原始变量\(\vec{W}_p\)表述,这就得到en
where \(|\bar{A}_{Roe}| = \bar{T}_{c,p}|\bar{\Lambda}_{c,p}|\bar{T}_{c,p}^{-1}\). The left (\(\bar{T}_{c,p}^{-1}\)) and right (\(\bar{T}_{c,p}\)) eigenvectors, as well as the eigenvalues (\(\bar{\Lambda}_{c,p}\)) are those of the matrix \(\bar{P}\bar{\Gamma}^{-1}\bar{A}_c = \bar{P}\bar{\Gamma}^{-1}\bar{A}_{c,p}\bar{P}^{-1}\). Values of the flow variables at \((I + 1/2)\) are obtained by Roe's averaging given in Eq. (4.89), and the whole residual is multiplied by \(\bar{P}\bar{\Gamma}^{-1}\). Again, the preconditioned Roe scheme in Eq. (9.54) can be formulated in the primitive variables \(\vec{W}_p\) leading us to
此时,构成\(\bar{A}_{Roe,p}\)的特征值和特征向量由矩阵\(\Gamma^{-1}\bar{A}_{c,p}\)确定(参见式(9.47))。\(\Gamma^{-1}\bar{A}_{c,p}\)的特征值与\(\bar{P}\bar{\Gamma}^{-1}\bar{A}_c\)的特征值相同,即等于\(\bar{\Lambda}_{c,p}\),但特征向量不同。因此,式(9.55)中的Roe矩阵构成为\(|\bar{A}_{Roe,p}| = \bar{T}_p|\bar{\Lambda}_{c,p}|\bar{T}_p^{-1}\)。应当指出,在这种情形下,残差同样必须乘以\(\bar{P}\bar{\Gamma}^{-1}\),以便回到守恒变量。en
The eigenvalues and eigenvectors which compose \(\bar{A}_{Roe,p}\) are now determined by the matrix \(\Gamma^{-1}\bar{A}_{c,p}\) (cf. Eq. (9.47)). The eigenvalues of \(\Gamma^{-1}\bar{A}_{c,p}\) are identical to the eigenvalues of \(\bar{P}\bar{\Gamma}^{-1}\bar{A}_c\), i.e. to \(\bar{\Lambda}_{c,p}\), but the eigenvectors are different. Thus, the Roe matrix in Eq. (9.55) is composed as \(|\bar{A}_{Roe,p}| = \bar{T}_p|\bar{\Lambda}_{c,p}|\bar{T}_p^{-1}\). It should be mentioned that also in this case the residual has to be multiplied by \(\bar{P}\bar{\Gamma}^{-1}\) in order to obtain conservative variables.
9.5.3 Form of the Matrices 矩阵的形式[cfd-9-5-3]
在原始变量\(\vec{W}_p\)的各种选择中,形式en
Among the various choices for the primitive variables \(\vec{W}_p\), the form
出现得最多。因此,后面的讨论将局限于这一特定形式的\(\vec{W}_p\)。下面,我们将针对一般流体和完全气体,给出变换矩阵和预条件矩阵,以及特征值和左、右特征向量。en
appears most often. Therefore, we shall restrict the further discussion to this particular form of \(\vec{W}_p\). In the following, we will present the transformation and the preconditioning matrices together with the eigenvalues and the left and right eigenvectors for a general fluid, as well as a perfect gas.
Transformation matrices 变换矩阵
对于一般流体,从守恒变量到原始变量的变换矩阵\(\bar{P}^{-1} = \partial\vec{W}_p/\partial\vec{W}\)由文献[91]给出en
For a general fluid, the transformation matrix from the conservative into the primitive variables \(\bar{P}^{-1} = \partial\vec{W}_p/\partial\vec{W}\) is given by [91]
其中en
with
从原始变量到守恒变量的变换矩阵\(\bar{P} = \partial\vec{W}/\partial\vec{W}_p\)为[91]en
The transformation matrix from the primitive into the conservative variables \(\bar{P} = \partial\vec{W}/\partial\vec{W}_p\) reads [91]
其中\(\alpha_p\)和\(\alpha_T\)分别为定压和定温压缩性系数。声速可以由下式计算en
where \(\alpha_p\) and \(\alpha_T\) are the compressibility coefficients at constant pressure and temperature, respectively. The speed of sound can be computed from
对于完全气体(见2.4.1小节),式(9.60)中的压缩性系数成为\(\alpha_p = 1/p\)和\(\alpha_T = 1/T\)。此时,式(9.57)中从守恒变量到原始变量的变换矩阵\(\bar{P}^{-1} = \partial\vec{W}_p/\partial\vec{W}\)可以写成en
In the case of a perfect gas (see Subsection 2.4.1), the compressibility coefficients in Eq. (9.60) become \(\alpha_p = 1/p\) and \(\alpha_T = 1/T\). In this case, the transformation matrix from the conservative into the primitive variables \(\bar{P}^{-1} = \partial\vec{W}_p/\partial\vec{W}\) from Eq. (9.57) can be cast into
对完全气体,从原始变量到守恒变量的变换矩阵\(\bar{P} = \partial\vec{W}/\partial\vec{W}_p\)为en
The transformation matrix from the primitive into the conservative variables \(\bar{P} = \partial\vec{W}/\partial\vec{W}_p\) reads for a perfect gas
Preconditioning matrices 预条件矩阵
在欧拉方程的情形下,预条件矩阵的构造相对容易。van Leer等人[92]提出的构造达到了可达的最低条件数。该方法在文献[79]中有详细讨论。然而,Navier-Stokes方程的预条件则更为复杂,原因在于黏性项会导致复数波速,使预条件系统难以分析。黏性流动最著名的预条件器分别由Choi和Merkle[93]、[94],Turkel[90]、[95]-[97],Lee和van Leer[98]、[99]以及Lee[80],Jorgenson和Pletcher[100],以及Weiss和Smith[101]、[45]提出。应用实例见文献[91]、[102]-[109]。en
The construction of a preconditioning matrix is relatively easy in the case of the Euler equations. The formulation proposed by van Leer at al. [92] achieves the lowest attainable condition number. The methodology was discussed in detail in [79]. However, the preconditioning of the Navier-Stokes equations is more involved. The reason is that the viscous terms lead to complex wave speeds, which makes the preconditioned system difficult to analyse. The most recognised preconditioners for viscous flows were proposed by Choi and Merkle [93], [94], Turkel [90], [95]-[97], Lee and van Leer [98], [99] and Lee [80], Jorgenson and Pletcher [100], and by Weiss and Smith [101], [45], respectively. Examples of applications can be found in Refs. [91], [102]-[109].
Weiss and Smith Preconditioner Weiss和Smith预条件器
Weiss和Smith[101]、[45]提出的预条件矩阵\(\bar{\Gamma}\),在一般流体情形下,其形式与式(9.59)中的\(\bar{P}\)相同,只是把\(\rho_p\)替换为适当的预条件参数(preconditioning parameter)\(\theta\)。预条件矩阵的逆也是如此,即\(\bar{\Gamma}^{-1}\)与式(9.57)中的\(\bar{P}^{-1}\)类似。因此,式(9.58)中的参数\(a_1\)变为en
The preconditioning matrix \(\bar{\Gamma}\) due to Weiss and Smith [101], [45] has, in the case of a general fluid, a form identical to \(\bar{P}\) in Eq. (9.59) with \(\rho_p\) replaced by a suitable preconditioning parameter \(\theta\). The same holds also for the inverse of the preconditioning matrix, i.e., \(\bar{\Gamma}^{-1}\) which resembles \(\bar{P}^{-1}\) from Eq. (9.57). Consequently, the parameter \(a_1\) from Eq. (9.58) is changed into
对于完全气体,预条件矩阵\(\bar{\Gamma}\)可以写成en
In the case of a perfect gas, the preconditioning matrix \(\bar{\Gamma}\) can be written as
其中\(\theta\)仍是预条件参数,稍后定义。预条件矩阵的逆由下式给出en
where \(\theta\) is again the preconditioning parameter, which will be defined later. The inverse of the preconditioning matrix is given by
其中采用缩写en
with the abbreviations
相应地,对完全气体,en
or, correspondingly for a perfect gas,
其中\(\Delta h\)是控制体尺寸的度量,\(\Delta p\)表示相邻控制体之间的压差,\(\epsilon\)是一个小数(\(\approx 10^{-3}\))。从式(9.70)的定义可以看到,参考速度受局部输运速度的限制。\(\nu/\Delta h\)和\(\kappa/\Delta h\)两项在以扩散或热传导为主的边界层内变得重要。压力项的目的是防止\(u_r\)在驻点处趋于零。当\(u_r = c\)时,\(\bar{\Gamma}\)变得与\(\bar{P}\)完全相同,\(\bar{\Gamma}^{-1}\)则变为\(\bar{P}^{-1}\)。因此,正如所期望的那样,预条件在超声速流动时自动关闭。en
where \(\Delta h\) is a measure of the control volume size, the quantity \(\Delta p\) stands for the pressure difference between the adjacent control volumes and \(\epsilon\) is a small number (\(\approx 10^{-3}\)). As we can see from the definition in Eq. (9.70), the reference velocity is bounded by the local transport velocity. The terms \(\nu/\Delta h\) and \(\kappa/\Delta h\) become important in boundary layers with dominant diffusion or heat conduction. The pressure term is intended to prevent \(u_r\) from vanishing at stagnation points. In the case that \(u_r = c\), \(\bar{\Gamma}\) becomes identical to \(\bar{P}\) and \(\bar{\Gamma}^{-1}\) is converted into \(\bar{P}^{-1}\). Hence, the preconditioning is turned off for a supersonic flow as intended.
另一种针对完全气体的做法是令[104]en
Another possibility, which was devised for a perfect gas, is to set [104]
其中参考马赫数由下式给出en
with the reference Mach number given by
而\(M\)为当地马赫数(\(M^2 = \|\vec{v}\|_2^2/c^2\))。按照文献[104],参数\(M^2_{min} = K M_\infty^2\)且\(K \approx 3\)(也有人取\(K = 1\)甚至\(K = 0.15\);其确切取值似乎取决于驻点区或边界层内控制体的数目)。容易验证,当\(M \ge 1\)时,参数\(\beta\)等于\(1/\gamma\),矩阵\(\bar{\Gamma}\)与\(\bar{P}\)完全相同。应当指出,式(9.69)与式(9.71)中\(\theta\)的两种定义是等价的。因此,借助式(9.70),参考马赫数也可以取为\(M_r = u_r/c\)。en
and \(M\) being the local Mach number (\(M^2 = \|\vec{v}\|_2^2/c^2\)). According to Ref. [104], parameter \(M^2_{min} = K M_\infty^2\) and \(K \approx 3\) (others choose \(K = 1\) or even \(K = 0.15\); the exact value seems to depend on the number of control volumes in the stagnation region or inside the boundary layer). As it can be easily verified, when \(M \ge 1\) the parameter \(\beta\) equals to \(1/\gamma\) and the matrix \(\bar{\Gamma}\) becomes identical to \(\bar{P}\). It should be mentioned that both definitions of \(\theta\) in Eq. (9.69) and in Eq. (9.71) are equivalent. Hence, the reference Mach number could be determined as \(M_r = u_r/c\) with the help of Eq. (9.70).
Eigenvalues of the Preconditioned System 预条件系统的特征值
其中\(V = \vec{v}\cdot\vec{n}\)表示逆变速度,而en
where \(V = \vec{v}\cdot\vec{n}\) represents the contravariant velocity, and
其中\(a_1\)按式(9.58)定义,\(a_1^{\Gamma}\)按式(9.64)定义。在完全气体以及按式(9.69)定义预条件参数\(\theta\)的情形下,参数成为\(a_4 = \phi\)和\(a_5 = \phi c^2\),\(\phi\)由式(9.67)给出。当采用式(9.71)中\(\theta\)的第二种定义时,式(9.76)中的参数分别简化为\(a_4 = M_r^2\)和\(a_5 = M_r^2 c^2\)。可以看到,当\(|M| \rightarrow 0\)时,\(c' \approx (V/2)\sqrt{5}\),因此各特征值如预期那样被均衡。这样,由条件数即式(9.40)所代表的刚性得以降低(条件数为\(C_N \approx 2.6\)),时间推进或迭代求解过程的收敛性得到极大增强。另一方面,当\(|M| \ge 1\)时,\(a_4 = 1\)、\(c' = c\),从而恢复\(\bar{A}_c\)的特征值。en
where \(a_1\) is defined in Eq. (9.58) and \(a_1^{\Gamma}\) in Eq. (9.64). In the case of a perfect gas and the definition of the preconditioning parameter \(\theta\) according to Eq. (9.69), the parameters become \(a_4 = \phi\) and \(a_5 = \phi c^2\), with \(\phi\) given by Eq. (9.67). When using the second definition of \(\theta\) from Eq. (9.71), the parameters in Eq. (9.76) simplify to \(a_4 = M_r^2\) and \(a_5 = M_r^2 c^2\), respectively. As we can see, \(c' \approx (V/2)\sqrt{5}\) for \(|M| \rightarrow 0\) and hence the eigenvalues become equalised as intended. In this way, the stiffness represented by the condition number Eq. (9.40) is reduced (the condition number is \(C_N \approx 2.6\)) and the convergence of the time-stepping or iterative solution process is dramatically enhanced. On the other hand, \(a_4 = 1\) and \(c' = c\) for \(|M| \ge 1\), and thus the eigenvalues of \(\bar{A}_c\) are recovered.
Eigenvectors of the Preconditioned System 预条件系统的特征向量
对流通量雅可比矩阵的左、右特征向量(参见附录A.11节)会因预条件而改变。这一点对于基于特征变量的空间离散很重要,例如Roe上风格式(4.3.3小节)以及4.3.4小节介绍的上风TVD格式。en
The left and right eigenvectors of the convective flux Jacobian (cf. Section A.11) will be changed by the preconditioning. This is of importance for spatial discretisations based on characteristic variables like Roe's upwind scheme (Subsection 4.3.3), or the upwind TVD scheme presented in the Subsection 4.3.4.
在守恒变量下表述的预条件Roe格式(见式(9.54))需要矩阵\(\bar{P}\bar{\Gamma}^{-1}\bar{A}_c = \bar{P}\bar{\Gamma}^{-1}\bar{A}_{c,p}\bar{P}^{-1}\)的特征向量\(\bar{T}_{c,p}\)和\(\bar{T}_{c,p}^{-1}\),它们可以通过修改上述特征向量式(9.78)和(9.79)得到。可以证明,\(\bar{P}\bar{\Gamma}^{-1}\bar{A}_c\)的右特征向量矩阵的列由\(\bar{P}\vec{x}\)构成,其中\(\vec{x}\)是\(\Gamma^{-1}\bar{A}_{c,p}\)的右特征向量。因此,\(\bar{P}\bar{\Gamma}^{-1}\bar{A}_c\)的右、左特征向量矩阵可以表示为en
The eigenvectors \(\bar{T}_{c,p}\) and \(\bar{T}_{c,p}^{-1}\) of the matrix \(\bar{P}\bar{\Gamma}^{-1}\bar{A}_c = \bar{P}\bar{\Gamma}^{-1}\bar{A}_{c,p}\bar{P}^{-1}\), which are required for the preconditioned Roe scheme formulated in the conservative variables (see Eq. (9.54)), can be obtained by a modification of the above eigenvectors Eqs. (9.78) and (9.79). It can be shown that the columns of the right-eigenvector matrix of \(\bar{P}\bar{\Gamma}^{-1}\bar{A}_c\) are composed of \(\bar{P}\vec{x}\), where \(\vec{x}\) are the right eigenvectors of \(\Gamma^{-1}\bar{A}_{c,p}\). Hence, the matrices of the right and left eigenvectors of \(\bar{P}\bar{\Gamma}^{-1}\bar{A}_c\) can be expressed as
将式(9.51)的预条件有限体积格式(其中\(\bar{\Gamma}\)按式(9.65)取)应用于翼型流动的例子见图9.10-9.12。可以观察到,对于来流马赫数0.01,中心格式和Roe上风格式都无法给出正确的解。无预条件的格式不能预测压力分布,因而也不能正确预测升力系数(\(C_L = 0.323\)和\(0.324\),而正确值为\(0.352\))。如图9.12所示,预条件有助于获得正确的解(\(C_L = 0.353\)),并且还显著加速了收敛。en
An example of the application of the preconditioned finite-volume scheme from Eq. (9.51) with \(\bar{\Gamma}\) according to Eq. (9.65) to airfoil flow is presented in Figs. 9.10-9.12. As we can observe, both the central scheme as well as Roe's upwind scheme fail to deliver the correct solution for an inflow Mach number of 0.01. The schemes without preconditioning cannot predict the pressure distribution and hence the lift coefficient (\(C_L = 0.323\) and \(0.324\) versus the correct \(0.352\)). As demonstrated in Fig. 9.12, preconditioning helps to obtain the correct solution (\(C_L = 0.353\)), and it also significantly accelerates the convergence.

图9.10:绕对称Joukowsky翼型(厚度10%)的二维无黏流动。结构网格,\(M_\infty = 10^{-2}\),\(\alpha = 3^{\circ}\),中心空间离散,显式多级时间推进格式,无预条件。上图为收敛历史,下图为压力系数与精确势流解的比较。图例:上图——convergence(收敛残差,左纵轴为\(\log(\text{res})\))与lift(升力系数,右纵轴),横轴为迭代次数(iteration);下图——Euler solver(欧拉解算器,曲线)与exact solution(精确解,圆点),纵轴为\(-C_p\),横轴为\(x/L\)。

图9.11:绕对称Joukowsky翼型(厚度10%)的二维无黏流动。结构网格,\(M_\infty = 10^{-2}\),\(\alpha = 3^{\circ}\),二阶Roe上风离散,显式多级时间推进格式,无预条件。上图为收敛历史,下图为压力系数与精确势流解的比较。图例:同图9.10。

图9.12:绕对称Joukowsky翼型(厚度10%)的二维无黏流动。结构网格,\(M_\infty = 10^{-2}\),\(\alpha = 3^{\circ}\),中心空间离散,显式多级时间推进格式,Weiss-Smith预条件。上图为收敛历史,下图为压力系数与精确势流解的比较。图例:同图9.10。