scieee AI-readable full text Open interactive document viewer

Improving performance of simplified computational fluid dynamics models via symmetric successive overrelaxation

Turek, Vojtěch

Abstract

The ability to model fluid flow and heat transfer in process equipment (e.g., shell-and-tube heat exchangers) is often critical. What is more, many different geometric variants may need to be evaluated during the design process. Although this can be done using detailed computational fluid dynamics (CFD) models, the time needed to evaluate a single variant can easily reach tens of hours on powerful computing hardware. Simplified CFD models providing solutions in much shorter time frames may, therefore, be employed instead. Still, even these models can prove to be too slow or not robust enough when used in optimization algorithms. Effort is thus devoted to further improving their performance by applying the symmetric successive overrelaxation (SSOR) preconditioning technique in which, in contrast to, e.g., incomplete lower–upper factorization (ILU), the respective preconditioning matrix can always be constructed. Because the efficacy of SSOR is influenced by the selection of forward and backward relaxation factors, whose direct calculation is prohibitively expensive, their combinations are experimentally investigated using several representative meshes. Performance is then compared in terms of the single-core computational time needed to reach a converged steady-state solution, and recommendations are made regarding relaxation factor combinations generally suitable for the discussed purpose. It is shown that SSOR can be used as a suitable fallback preconditioner for the fast-performing, but numerically sensitive, incomplete lower–upper factorization.

Full text

energies Article Improving Performance of Simplified Computational Fluid Dynamics Models via Symmetric Successive Overrelaxation Vojtˇech Turek Sustainable Process Integration Laboratory–SPIL, NETME Centre, Faculty of Mechanical Engineering, Brno University of Technology–VUT Brno, Technická2, 616 00 Brno, Czech Republic; [email protected].cz Received: 23 May 2019; Accepted: 21 June 2019; Published: 25 June 2019   Abstract: The ability to model fluid flow and heat transfer in process equipment (e.g., shell-and-tube heat exchangers) is often critical. What is more, many different geometric variants may need to be evaluated during the design process. Although this can be done using detailed computational fluid dynamics (CFD) models, the time needed to evaluate a single variant can easily reach tens of hours on powerful computing hardware. Simplified CFD models providing solutions in much shorter time frames may, therefore, be employed instead. Still, even these models can prove to be too slow or not robust enough when used in optimization algorithms. Effort is thus devoted to further improving their performance by applying the symmetric successive overrelaxation (SSOR) preconditioning technique in which, in contrast to, e.g., incomplete lower–upper factorization (ILU), the respective preconditioning matrix can always be constructed. Because the efficacy of SSOR is influenced by the selection of forward and backward relaxation factors, whose direct calculation is prohibitively expensive, their combinations are experimentally investigated using several representative meshes. Performance is then compared in terms of the single-core computational time needed to reach a converged steady-state solution, and recommendations are made regarding relaxation factor combinations generally suitable for the discussed purpose. It is shown that SSOR can be used as a suitable fallback preconditioner for the fast-performing, but numerically sensitive, incomplete lower–upper factorization. Keywords: computational fluid dynamics; symmetric successive overrelaxation; preconditioning; performance 1. Introduction In engineering practice, it is often the case that process equipment is designed according to various rules of thumb. No optimization is generally done and, at best, a single computational fluid dynamics (CFD) simulation is carried out to verify that the design meets the key requirements of the future operator of the apparatus. This means that suboptimal designs or solutions, potentially leading to operating problems, are not uncommon. One of the ways to remedy the situation is to use simplified CFD models. In spite of them not being as accurate as the standard CFD models, it has been shown [ 1 ] that they can provide useful quantitative information. What is more, these models feature significantly shorter computational times and their application in optimization algorithms is therefore much less cumbersome. To obtain solutions even faster, however, the numerical methods used to solve the underlying linear systems of equations can also be preconditioned. This means that instead of solving the original linear system Ax =b, (1) Energies 2019,12, 2438; doi:10.3390/en12122438 www.mdpi.com/journal/energies Energies 2019,12, 2438 2 of 16 where A is the coefficient matrix, x the solution vector, and b the right-hand side vector, one considers the system M−1Ax =M−1b. (2) here, M denotes the preconditioning matrix such that M−1A has a smaller condition number than A and, therefore, linear system (2) features better convergence. It should also be noted that M−1A often is not formed explicitly but, instead, Mu = v is solved for various auxiliary vectors u and v within the numerical solution method itself. There are many different preconditioning techniques (i.e., ways to choose M ) available, and the selection of the best one for a particular purpose depends mainly on the type of equation that is being solved and the employed ordering of the variables. However, the most commonly used techniques are likely various flavors of incomplete lower–upper factorization (ILU) [ 2 ] (these were numerically investigated by Chapman et al. [ 3 ]) and symmetric successive overrelaxation (SSOR) [ 4 ]. Although SSOR was originally intended for symmetric matrices, it was shown [ 5 ] to also work when the matrices are not symmetric. Assuming the splitting A = D + L + U , where D is the diagonal of A and L and U its strictly lower and upper triangular parts, respectively, the SSOR preconditioning technique is applied within the numerical solution method as two SOR sweeps using different values of ω . The iteration process for auxiliary vectors u,v(depend on the actual solution method used) can then be written as u(k+1/2) =(D+ωFL)−1[(1 −ωF)D−ωFU]u(k)+ωF(D+ωFL)−1v(forward sweep) u(k+1) =(D+ωRU)−1[(1 −ωR)D−ωRL]u(k+1/2) +ωR(D+ωRU)−1v, (backward sweep) (3) where ωF and ωR denote the corresponding forward and backward relaxation factors. In other words, direct application of the inverse of the preconditioning matrix, M−1 , is replaced by preconditioned fixed point iteration. The advantages of SSOR are evidenced by the existence of a multitude of papers discussing improved versions of this technique or its extensions to various specific applications. Bai [ 6 ] studied SSOR-like preconditioners for non-Hermitian positive definite linear systems, for which the respective matrix was either Hermitian-dominant or skew–Hermitian-dominant. The paper also discussed the results of numerical implementations, showing that Krylov subspace iteration methods, when accelerated using SSOR-like preconditioners, are efficient solvers for classes of non-Hermitian positive definite linear systems. A “shifted” version of SSOR for non-Hermitian positive definite linear systems with a dominant Hermitian part was proposed by Tan [ 7 ]. Zhang [ 8 ], on the other hand, introduced an SSOR-like preconditioner for saddle point problems with a dominant skew-Hermitian part. A class of hybrid preconditioning methods for accelerated solution of saddle point problems was discussed by Wang [ 9 ], while Chen et al. [ 10 ] proposed a version of SSOR suitable for preconditioning of large dense complex linear systems arising from three-dimensional electromagnetic scattering. Wu and Li [ 11 ] introduced a modified SSOR technique for the solution of Helmholtz equations. Preconditioning can also be done block-wise. This was discussed, e.g., by Zhang and Cheng [ 12 ] in terms of large sparse saddle point problems, and by Huang and Lu [ 13 ], who focused on SSOR block preconditioners applied in image restoration. Because, in fact, preconditioning means obtaining an easily invertible approximation of the original matrix, one can also use SSOR for just this purpose as shown, for example, by Meng et al. [ 14 ] in the context of fast recovery of density 3D data from gravity data. Similarly, a massively-parallel GPU implementation of the conjugate gradient method, which uses the approximate inverse matrix derived from SSOR as the preconditioning matrix, was proposed by Helfenstein and Koko [15]. Performance comparisons of SSOR and other, simpler preconditioning techniques were presented, e.g., by Meyer [ 16 ], who focused on genomic evaluation and by Sanjuan et al. [ 17 ], who used SSOR to accelerate parallel wind field calculations. In the latter paper, the authors also evaluated a new, reordered sparse matrix storage format and showed that this format can markedly shorten computational time. This confirms the earlier findings of Duffand Meurant [ 18 ], who investigated the effect of ordering Energies 2019,12, 2438 3 of 16 on the convergence of the conjugate gradient method preconditioned, among others, using SSOR, or DeLong and Ortega [ 19 ], who focused on parallel implementations of SOR in terms of natural and multicolor orderings. Chen et al. [ 20 ], on the other hand, proposed a novel reordering technique for SSOR approximate inverse preconditioner, used together with a GPU-accelerated conjugate gradient solver, which should maximize the coalescing of global memory accesses. Many SSOR-like, a priori preconditioned numerical solution methods using different splittings of the coefficient matrix have also been proposed for various types of problems. A three-parameter extension of the SSOR method intended for singular saddle point problems, which commonly arise, e.g., in fluid dynamics, was proposed by Li and Zhang [ 21 ]. A differently accelerated generalized three-parameter method for both singular and non-singular problems was introduced by Pan [ 22 ]. Similarly, a three-parameter unsymmetric SOR method for such saddle point problems was proposed, for example, by Liang and Zhang [ 23 ], who also discussed the choice of optimal values of the parameters. Many different SSOR-like methods are available for augmented systems, as well. Wang and Huang [ 24 ] introduced a four-parameter method, Louka and Missirlis [ 25 ] introduced a five-parameter extrapolated form of SSOR, and Najafi and Edalatpanah [ 26 ] introduced an improved version of the modified SSOR method for large sparse augmented systems, proposed earlier by Darvishi and Hessari [ 27 ]. Another improved SSOR method intended for the solution of augmented systems was proposed by Salkuyeh et al. [28]. In the case of complex systems, one can use, for instance, the accelerated method by Huang et al. [ 29 ], that is, an accelerated version of the method by Edalatpour et al. [ 30 ], in which the solution vector is split into two subvectors and different relaxation factors are used when solving for each of them. Likewise, one can employ the preconditioned variant of the generalized SSOR method by Hezari et al. [ 31 ] or the method by Salkuyeh et al. [ 32 ], which solves a real system obtained from the original, complex one. Block linear systems can be solved, e.g., using the block-preconditioned SSOR method by Pu and Wang [33]. The majority of the papers mentioned above discuss convergence (or at least semi-convergence) of the proposed methods, and many also include some information on the optimal selection of the relaxation factors. Kushida [ 34 ] focused on the estimation of convergence of the original SSOR preconditioner via a condition number, while general discussion related to SSOR-like methods for non-Hermitian positive definite linear systems was published in [ 35 ]. Augmented systems were addressed, for example, by Wang and Huang [ 36 ]. Similarly, there are papers focusing on convergence and optimal selection of the relaxation factors in the case of methods for block 2 × 2 linear systems [ 37 ], saddle point problems [ 38 ], parallel SSOR implementations [ 39 ], the Poisson equation [ 40 ], etc. In all these cases, however, convergence was investigated via spectral analysis, which is often prohibitively expensive [ 41 ]. The present paper, focusing on fast estimation of suitable SSOR relaxation factors in engineering practice, therefore, investigates the convergence experimentally using several different simplified 3D CFD flow models. The suitability of specific combinations of relaxation factors is assessed on the basis of mean computational times needed to reach converged steady-state solutions. The best-performing combinations of relaxation factors are then given together with the obtained relaxation factor trends. 2. Materials and Methods Three different flow systems, with both the “U” and the “Z” flow arrangements (“U”: outlet on the same side of the flow system as the inlet, “Z”: outlet on the opposite side), were used to generate test cases. Moreover, in two of these three flow systems, the mesh fineness was also varied (coarser and finer mesh). This yielded ten flow system configurations in total, with simplified, cuboid cell-only meshes of different sizes ranging from ~6000 cells to ~41,000 cells (see Table 1). The meshes were generated automatically by the employed benchmarking software (see further) using the key parameters listed in Table 1. Due to the cuboid nature of the meshes, cell sizes were, in all computational domains, governed primarily by how many cell faces comprised a tube cross section (coarser mesh: 1 face only, finer mesh: 2 ×2 faces) and by the utilized cell growth factor. Sample meshes are shown in Figure 1. Energies 2019,12, 2438 4 of 16 Table 1. Flow system parameters: W,L, and Hdenote width, length, and height, respectively, p r row pitch, and pttube pitch. Parameter Flow System 1 Flow System 2 Flow System 3 Headers (W×L×H) 40 ×320 ×40 mm 60 ×340 ×60 mm 100 ×340 ×100 mm Inlet/outlet region (L) 60 mm 60 mm 60 mm Tube bundle 2 inline rows, 20 tubes/row, pr=pt= 15.6 mm 3 staggered rows (45◦), 10 tubes/row, pr=15.6 mm, pt=2pr 5 staggered rows (45◦), 10 tubes/row, pr=15.6 mm, pt=2pr Tubes 10 mm ×500 mm 10 mm ×500 mm 10 mm ×500 mm Flow arrangement “U” or “Z” “U” or “Z” “U” or “Z” Mesh coarser: ~6000 cells, finer: ~25,000 cells coarser: ~8000 cells, finer: ~41,000 cells coarser: ~16,000 cells Energies 2018, 11, x FOR PEER REVIEW 4 of 16 Table 1. Flow system parameters: W, L, and H denote width, length, and height, respectively, pr row 139 pitch, and pt tube pitch. 140 Parameter Flow system 1 Flow system 2 Flow system 3 Headers (W × L × H) 40 × 320 × 40 mm 60 × 340 × 60 mm 100 × 340 × 100 mm Inlet/outlet region (L) 60 mm 60 mm 60 mm Tube bundle 2 inline rows, 20 tubes/row, pr = pt = 15.6 mm 3 staggered rows (45°), 10 tubes/row, pr = 15.6 mm, pt = 2pr 5 staggered rows (45°), 10 tubes/row, pr = 15.6 mm, pt = 2pr Tubes ⌀10 mm × 500 mm ⌀10 mm × 500 mm ⌀10 mm × 500 mm Flow arrangement “U” or “Z” “U” or “Z” “U” or “Z” Mesh coarser: ~6000 cells, finer: ~25,000 cells coarser: ~8000 cells, finer: ~41,000 cells coarser: ~16,000 cells 141 Figure 1. Sample simplified (cuboid cell-only) meshes generated automatically by the benchmarking 142 software using the growth factor of 1.15; clockwise from top left: (a) layout of the “Z”-arranged flow 143 system 1 from Table 1; (b) the corresponding finer mesh (~25,000 cells, groups of red cells in the top 144 view denote locations of tube cross-sections); (c) top view of the finer mesh of the distribution header 145 from flow system 2 (inlet region being on the left); other parts of this mesh, as well as the remaining 146 meshes, were generated analogously. 147 As for boundary conditions, 0.5 kg/s of water at 300 K was fed into the inlet while pressure at 148 the outlet was set to 101,325 Pa. All walls were adiabatic except for tube walls, where a specific heat 149 flux of 15 kW/m2 was set when the energy equation was enabled. Steady state simulations were 150 carried out using the same CFD setup as in [42], that is, the SIMPLEC pressure-velocity coupling [43] 151 was employed together with the Power Law discretization scheme [44]. Standard scaled residual 152 Figure 1. Sample simplified (cuboid cell-only) meshes generated automatically by the benchmarking software using the growth factor of 1.15; clockwise from top left: ( a ) layout of the “Z”-arranged flow system 1 from Table 1; ( b ) the corresponding finer mesh (~25,000 cells, groups of red cells in the top view denote locations of tube cross-sections); (c) top view of the finer mesh of the distribution header from flow system 2 (inlet region being on the left); other parts of this mesh, as well as the remaining meshes, were generated analogously. As for boundary conditions, 0.5 kg/s of water at 300 K was fed into the inlet while pressure at the outlet was set to 101,325 Pa. All walls were adiabatic except for tube walls, where a specific heat flux of 15 kW/m 2 was set when the energy equation was enabled. Steady state simulations were carried out using the same CFD setup as in [ 42 ], that is, the SIMPLEC pressure-velocity coupling [ 43 ] was employed together with the Power Law discretization scheme [ 44 ]. Standard scaled residual limits, i.e., 10 −3 for continuity and momentum and 10 −6 for energy, were used. Only the natural ordering of the variables was considered in this study. Energies 2019,12, 2438 5 of 16 The SSOR preconditioning technique was paired with two widely used numerical solution methods, which were shown by an earlier study [ 42 ] to perform very well in simplified 3D CFD models. The conjugate gradient (CG) numerical solution method [ 45 ] was employed in the pressure correction equation. The momentum and energy equations, on the other hand, were solved using the bi-conjugate gradient stabilized numerical method with the minimization of residuals over L-dimensional subspaces (BiCGstab(L)) [ 46 ], with L=1, 2, or 3. Performance of the ILU preconditioner (which is efficient, but the construction of the respective preconditioning matrix may not always be possible) was taken as the baseline. The SSOR-preconditioned numerical solution methods were tested with various tuples of ωF , ωR=0.1, 0.2, . . . , 1.8, 1.9 in successive steps, depending on the obtained results. Promising combinations of ωF and ωR were then taken as pivots, and their square neighborhoods were tested further—that is, all combinations of ωF , ωR with the respective values being ω – 0.04, ω – 0.02, ω , ω +0.02, and ω +0.04 were evaluated except for the original pivot point ( ωF , ωR ). In order to be able to compare SSOR to the baseline (ILU), all the ten meshes were also evaluated using the ILU-preconditioned combinations of solution methods. In total, 50,620 CFD model setups were tested. The same benchmarking simplified 3D CFD Java software application was used as in [ 42 ], and, therefore, the reader is kindly referred to this paper for details (please note that the software is not publicly available). The benchmarking procedure itself was almost the same, as well, with the only difference being that the numbers of warm-up and test runs were smaller for the larger meshes (see Table 2). Such a measure was necessary to keep the times required to complete the respective benchmarks within reasonable bounds. This did not introduce any problems, because with larger cell counts all Java initializations and compilations had been finished within much less warm-up runs, and, therefore, it was not needed to carry out many of them before the timing phase. Mean test-run computational time was then taken as the final performance metric. Unlike in [ 42 ], however, only one machine (Intel Xeon E5 2698 v4 CPU, 128 GB RAM) was used instead of two largely disparate ones. The reason for this simplification was that, as shown in the respective paper, single-core computational times proved to be virtually identical, irrespective of whether the machine was a high-performance server or a regular laptop with an ultra-low voltage CPU. Please see the paragraph titled Supplementary Materials on how to obtain the data set containing all the mean computational times together with other relevant information. Table 2. Numbers of warm-up and test runs and test case limits. Mesh Size (Cells) Warm-Up Runs Test Runs Iteration Limit Computational Time Limit ~6000 30 50 1000 1800 s ~8000 30 50 1000 1800 s ~16,000 20 40 1500 2700 s ~25,000 10 30 2000 3600 s ~41,000 10 30 2000 3600 s Because this study targeted fast computation, two kinds of limits were set in the solution process as detailed in Table 2. The first one concerned the number of CFD solver iterations, while the second one applied to the actual computational time. Any combination of numerical solution methods and preconditioning techniques which exceeded at least one of these two limits was marked as failing to reach a solution. Additionally, since robustness is one of the factors that must be considered when evaluating the suitability of numerical solution methods, no user interventions (e.g., changes to the internal residual limits of the numerical methods, CFD relaxation factors, etc.) were allowed during a solution process. Energies 2019,12, 2438 6 of 16 3. Results This section is split into four parts. The first part presents the results pertaining to flow-only simulations. The second part discusses flow and energy transport simulations, in which only the energy equation was solved using SSOR-preconditioned numerical methods. The third part, on the other hand, summarizes data obtained via benchmarks, where SSOR was used for both the momentum and the energy equations. The last part then compares the SSOR-related data with results corresponding to the cases where solely the ILU preconditioning technique was used. 3.1. Flow-Only Simulations with SSOR-Preconditioned Momentum Equations As mentioned above, the pressure correction equation was always solved using CG. This solution method was first coupled with SSOR, while the momentum equations were solved using BiCGstab(3):ILU. Within the several initial benchmarks, however, it became clear that CG:SSOR is wholly unsuitable. No matter the actual relaxation factors ωF and ωR , the majority of test cases either failed (mostly due to divergence) or resulted in very long computational times. Those setups which did not fail featured ωF≈ωR and, what is more, their amount decreased with an increasing mesh size, as shown in Figure 2. This was most probably a consequence of the fact that SSOR is sensitive to the ordering of variables. Only the ILU preconditioning technique was, therefore, used for the pressure correction equation, from then on. Energies 2018, 11, x FOR PEER REVIEW 6 of 16 3. Results 196 This section is split into four parts. The first part presents the results pertaining to flow-only 197 simulations. The second part discusses flow and energy transport simulations, in which only the 198 energy equation was solved using SSOR-preconditioned numerical methods. The third part, on the 199 other hand, summarizes data obtained via benchmarks, where SSOR was used for both the 200 momentum and the energy equations. The last part then compares the SSOR-related data with results 201 corresponding to the cases where solely the ILU preconditioning technique was used. 202 3.1. Flow-Only Simulations with SSOR-Preconditioned Momentum Equations 203 As mentioned above, the pressure correction equation was always solved using CG. This 204 solution method was first coupled with SSOR, while the momentum equations were solved using 205 BiCGstab(3):ILU. Within the several initial benchmarks, however, it became clear that CG:SSOR is 206 wholly unsuitable. No matter the actual relaxation factors ωF and ωR, the majority of test cases either 207 failed (mostly due to divergence) or resulted in very long computational times. Those setups which 208 did not fail featured ωF ≈ ωR and, what is more, their amount decreased with an increasing mesh size, 209 as shown in Figure 2. This was most probably a consequence of the fact that SSOR is sensitive to the 210 ordering of variables. Only the ILU preconditioning technique was, therefore, used for the pressure 211 correction equation, from then on. 212 213 Figure 2. Mean computational times for three different meshes and various combinations of ωF and 214 ωR, the pressure correction equation was solved using CG:SSOR and the momentum equations using 215 BiCGstab(3):ILU; diagonal crosses indicate failing combinations of ωF and ωR. Please note that the 216 colorbars have been adjusted so that the best (i.e., the most relevant) combinations of ωF, ωR are easily 217 identifiable. Further, due to the necessary colorbar ranges, the respective lower limits have been set 218 to zero even though the data start at higher values. 219 The shortest mean computational times obtained with BiCGstab(2) and BiCGstab(1) instead of 220 BiCGstab(3) were, on average, ~80 % and ~260 % longer, respectively. Conversely, stability of the 221 solution process was greater with these two methods, and fewer combinations of ωF and ωR resulted 222 in failures (again, mostly because of divergence; see Figure 3). It is also evident from the figure that 223 the best-performing combinations were around ωF = ωR = 1.0, while with ωF below 0.5 or above 1.5 224 the computational times were much longer, or solution failures occurred. As for the CFD setup 225 involving BiCGstab(3) in particular, mean computational times started at 2.56 s for the smallest mesh 226 and 117.33 s when the largest mesh was used. 227 228 Figure 2. Mean computational times for three different meshes and various combinations of ωF and ωR , the pressure correction equation was solved using CG:SSOR and the momentum equations using BiCGstab(3):ILU; diagonal crosses indicate failing combinations of ωF and ωR . Please note that the colorbars have been adjusted so that the best (i.e., the most relevant) combinations of ωF , ωR are easily identifiable. Further, due to the necessary colorbar ranges, the respective lower limits have been set to zero even though the data start at higher values. The shortest mean computational times obtained with BiCGstab(2) and BiCGstab(1) instead of BiCGstab(3) were, on average, ~80% and ~260% longer, respectively. Conversely, stability of the solution process was greater with these two methods, and fewer combinations of ωF and ωR resulted in failures (again, mostly because of divergence; see Figure 3). It is also evident from the figure that the best-performing combinations were around ωF = ωR =1.0, while with ωF below 0.5 or above 1.5 the computational times were much longer, or solution failures occurred. As for the CFD setup involving BiCGstab(3) in particular, mean computational times started at 2.56 s for the smallest mesh and 117.33 s when the largest mesh was used. Thesolutionbehaviormentionedabove was alsoobservedfor thelarger meshes. OnlyBiCGstab(3):SSOR was, therefore, used to solve the momentum equations in the following flow-only benchmarks because of its superior performance. To generate these, the combinations of ωF and ωR obtained for the ten flow systems were sorted by mean computational time and the respective ordered sets were then used to find the most common combinations yielding the most favorable computational times. In other words, the best tuples ( ωF , ωR ) were taken as pivot points whose square neighborhoods were evaluated further. Energies 2019,12, 2438 7 of 16 Energies 2018, 11, x FOR PEER REVIEW 6 of 16 3. Results 196 This section is split into four parts. The first part presents the results pertaining to flow-only 197 simulations. The second part discusses flow and energy transport simulations, in which only the 198 energy equation was solved using SSOR-preconditioned numerical methods. The third part, on the 199 other hand, summarizes data obtained via benchmarks, where SSOR was used for both the 200 momentum and the energy equations. The last part then compares the SSOR-related data with results 201 corresponding to the cases where solely the ILU preconditioning technique was used. 202 3.1. Flow-Only Simulations with SSOR-Preconditioned Momentum Equations 203 As mentioned above, the pressure correction equation was always solved using CG. This 204 solution method was first coupled with SSOR, while the momentum equations were solved using 205 BiCGstab(3):ILU. Within the several initial benchmarks, however, it became clear that CG:SSOR is 206 wholly unsuitable. No matter the actual relaxation factors ωF and ωR, the majority of test cases either 207 failed (mostly due to divergence) or resulted in very long computational times. Those setups which 208 did not fail featured ωF ≈ ωR and, what is more, their amount decreased with an increasing mesh size, 209 as shown in Figure 2. This was most probably a consequence of the fact that SSOR is sensitive to the 210 ordering of variables. Only the ILU preconditioning technique was, therefore, used for the pressure 211 correction equation, from then on. 212 213 Figure 2. Mean computational times for three different meshes and various combinations of ωF and 214 ωR, the pressure correction equation was solved using CG:SSOR and the momentum equations using 215 BiCGstab(3):ILU; diagonal crosses indicate failing combinations of ωF and ωR. Please note that the 216 colorbars have been adjusted so that the best (i.e., the most relevant) combinations of ωF, ωR are easily 217 identifiable. Further, due to the necessary colorbar ranges, the respective lower limits have been set 218 to zero even though the data start at higher values. 219 The shortest mean computational times obtained with BiCGstab(2) and BiCGstab(1) instead of 220 BiCGstab(3) were, on average, ~80 % and ~260 % longer, respectively. Conversely, stability of the 221 solution process was greater with these two methods, and fewer combinations of ωF and ωR resulted 222 in failures (again, mostly because of divergence; see Figure 3). It is also evident from the figure that 223 the best-performing combinations were around ωF = ωR = 1.0, while with ωF below 0.5 or above 1.5 224 the computational times were much longer, or solution failures occurred. As for the CFD setup 225 involving BiCGstab(3) in particular, mean computational times started at 2.56 s for the smallest mesh 226 and 117.33 s when the largest mesh was used. 227 228 Figure 3. Mean computational times for the smallest mesh and the cases when the pressure correction equation was solved using CG:ILU and the momentum equations using BiCGstab(3):SSOR, BiCGstab(2):SSOR, and BiCGstab(1):SSOR; diagonal crosses indicate failing combinations of ωF and ωR . Please note that the colorbars have been adjusted so that the best (i.e., the most relevant) combinations of ωF,ωRare easily identifiable. Example plots resulting from such evaluations are shown in Figure 4. Both pertain to the same mesh—the smallest one in this particular case. The plot on the left (Figure 4a) shows mean computational times for all the pivots and their respective neighborhoods. The plot on the right (Figure 4b) displays a cropped area corresponding to ωF , ωR∈ [0.5, 1.5], where the best-performing combinations of relaxation factors are located. The dotted lines in both these plots represent the trend obtained using the standard weighted least squares method. Because the goal was to minimize computational time, the weights for individual combinations ( ωF , ωR ) were calculated as w i =(t min /t i ) 4 , where t min denotes the minimum computational time observed with a specific mesh and t i denotes the mean computational time corresponding to the respective (i-th) combination of relaxation factors evaluated using this mesh. The fourth power of the computational time ratio instead of just the ratio itself was used to adequately limit the influence of combinations that yielded solutions in longer time frames. Weights for combinations leading to solution failures were set to zero. Energies 2018, 11, x FOR PEER REVIEW 7 of 16 Figure 3. Mean computational times for the smallest mesh and the cases when the pressure correction 229 equation was solved using CG:ILU and the momentum equations using BiCGstab(3):SSOR, 230 BiCGstab(2):SSOR, and BiCGstab(1):SSOR; diagonal crosses indicate failing combinations of ωF and 231 ωR. Please note that the colorbars have been adjusted so that the best (i.e., the most relevant) 232 combinations of ωF, ωR are easily identifiable. 233 The solution behavior mentioned above was also observed for the larger meshes. Only 234 BiCGstab(3):SSOR was, therefore, used to solve the momentum equations in the following flow-only 235 benchmarks because of its superior performance. To generate these, the combinations of ωF and ωR 236 obtained for the ten flow systems were sorted by mean computational time and the respective 237 ordered sets were then used to find the most common combinations yielding the most favorable 238 computational times. In other words, the best tuples (ωF, ωR) were taken as pivot points whose square 239 neighborhoods were evaluated further. 240 Example plots resulting from such evaluations are shown in Figure 4. Both pertain to the same 241 mesh—the smallest one in this particular case. The plot on the left (Figure 4a) shows mean 242 computational times for all the pivots and their respective neighborhoods. The plot on the right 243 (Figure 4b) displays a cropped area corresponding to ωF, ωR ∈ [0.5, 1.5], where the best-performing 244 combinations of relaxation factors are located. The dotted lines in both these plots represent the trend 245 obtained using the standard weighted least squares method. Because the goal was to minimize 246 computational time, the weights for individual combinations (ωF, ωR) were calculated as wi = (tmin / ti)4, 247 where tmin denotes the minimum computational time observed with a specific mesh and ti denotes 248 the mean computational time corresponding to the respective (i-th) combination of relaxation factors 249 evaluated using this mesh. The fourth power of the computational time ratio instead of just the ratio 250 itself was used to adequately limit the influence of combinations that yielded solutions in longer time 251 frames. Weights for combinations leading to solution failures were set to zero. 252 253 Figure 4. Mean computational times for the neighborhoods of pivot points corresponding to the 254 smallest mesh; the pressure correction equation was solved using CG:ILU and the momentum 255 equations using BiCGstab(3):SSOR; please note that, for the sake of clarity, the time ranges have been 256 severely limited in both plots. Again, the colorbars have been adjusted so that the best (i.e., the most 257 relevant) combinations of ωF, ωR are easily identifiable. 258 Trends for all the mesh sizes as well as the overall relaxation factor trends are listed in Table 3 259 and shown in Figure 5. Although the R2 values are relatively low, this is caused by the fact that the 260 data featured many less-relevant points scattered over the (0, 2) × (0, 2) relaxation factor domain, 261 which were assigned small, but still non-zero weights. In any case, the standard errors for the trend 262 coefficients are quite reasonable, and it is obvious that all the trends are very similar. Considering the 263 actual values of the coefficients a and b and the fact that the best combinations of relaxation factors 264 featured ωF ≈ 0.9, it follows that, when solving the momentum equations in flow-only scenarios, both 265 SSOR sweeps should be slightly underrelaxed to gain the shortest computational time. 266 Figure 4. Mean computational times for the neighborhoods of pivot points corresponding to the smallest mesh; the pressure correction equation was solved using CG:ILU and the momentum equations using BiCGstab(3):SSOR; please note that, for the sake of clarity, the time ranges have been severely limited in both plots. Again, the colorbars have been adjusted so that the best (i.e., the most relevant) combinations of ωF,ωRare easily identifiable. Trends for all the mesh sizes as well as the overall relaxation factor trends are listed in Table 3 and shown in Figure 5. Although the R 2 values are relatively low, this is caused by the fact that the data featured many less-relevant points scattered over the (0, 2) × (0, 2) relaxation factor domain, which were assigned small, but still non-zero weights. In any case, the standard errors for the trend coefficients are quite reasonable, and it is obvious that all the trends are very similar. Considering the actual values of the coefficients aand band the fact that the best combinations of relaxation factors Energies 2019,12, 2438 8 of 16 featured ωF≈ 0.9, it follows that, when solving the momentum equations in flow-only scenarios, both SSOR sweeps should be slightly underrelaxed to gain the shortest computational time. Table 3. Relaxation factor trends, ωR =a ωF +b, for individual mesh sizes and the overall relaxation factor trend for the solution of momentum equations using BiCGstab(3):SSOR; R 2 denotes the coefficient of determination and SE(a) and SE(b) the standard error values for the coefficients a,b. Mesh Size (Cells) a b R2SE(a)SE(b) ~6000 0.823 0.071 0.479 0.014 0.009 ~8000 0.843 0.094 0.457 0.015 0.007 ~16,000 0.888 0.011 0.795 0.013 0.003 ~25,000 0.798 0.051 0.593 0.019 0.007 ~41,000 0.898 0.028 0.754 0.015 0.007 Overall trend 0.861 0.056 0.584 0.007 0.003 Energies 2018, 11, x FOR PEER REVIEW 8 of 16 267 Figure 5. Relaxation factor trends for the solution of momentum equations using BiCGstab(3):SSOR; 268 the overall trend was obtained using the merged data set and identical weights. 269 Table 3. Relaxation factor trends, ωR = aωF + b, for individual mesh sizes and the overall relaxation 270 factor trend for the solution of momentum equations using BiCGstab(3):SSOR; R2 denotes the 271 coefficient of determination and SE(a) and SE(b) the standard error values for the coefficients a, b. 272 Mesh size (cells) a b R2 SE(a) SE(b) ~6000 0.823 0.071 0.479 0.014 0.009 ~8000 0.843 0.094 0.457 0.015 0.007 ~16,000 0.888 0.011 0.795 0.013 0.003 ~25,000 0.798 0.051 0.593 0.019 0.007 ~41,000 0.898 0.028 0.754 0.015 0.007 Overall trend 0.861 0.056 0.584 0.007 0.003 3.2. Flow & Energy Transport Simulations with SSOR-Preconditioned Energy Equation 273 Based on the solution behavior observed in the flow-only scenarios, only CG:ILU was used to 274 solve the pressure correction equation in the flow and energy transport simulations. Momentum 275 equations were also preconditioned only with ILU, while SSOR was used just for the energy equation. 276 Various combinations of BiCGstab(L) for the momentum and energy equations were tested first, and 277 the two most suitable combinations were then evaluated in detail using square neighborhoods of 278 promising relaxation factor tuples (i.e., the pivot points). 279 The best results overall were obtained using BiCGstab(3) and BiCGstab(1) for the momentum 280 equations and the energy equation, respectively (see Figure 6). This setup was relatively robust, most 281 probably because of the better stability and smoothness of convergence resulting from the use of 282 BiCGstab(1). Figure 7 shows the second-best combination, featuring only BiCGstab(2). On average, 283 this setup was ~38 % slower, and more combinations of ωF and ωR resulted in solution failures. It can 284 also be seen that all the suitable relaxation factor tuples were in a relatively small neighborhood of 285 (1, 1). Furthermore, with the SSOR-preconditioned energy equation, a significantly larger percentage 286 of failures than before was due to slow convergence (that is, the respective iteration limits were 287 exceeded). 288 The data sets mentioned above were then combined with data sets obtained by evaluating 289 square neighborhoods of the promising tuples of ωF and ωR to get the corresponding relaxation factor 290 trends. Again, the standard weighted least squares method was used with the weights being 291 calculated in the same manner as before. Because the best setup and the second-best one (featured in 292 Figures 6 and 7) were, at least in some cases, on par, the trends were calculated for both of them (see 293 Table 4 and Figure 8). It is of note here that all benchmarks involving the largest mesh and 294 BiCGstab(1) had failed. This suggests that the respective solution method simply is too slow when 295 combined with SSOR. In any case, the best results were obtained with ωF around 1.2 or 1.1 when 296 BiCGstab(1) or BiCGstab(2) were used, respectively. This means that, given the calculated relaxation 297 factor trends, ωR should also be a little above 1.0 (i.e., it is best to slightly overrelax both SSOR sweeps 298 when solving the energy equation). 299 Figure 5. Relaxation factor trends for the solution of momentum equations using BiCGstab(3):SSOR; the overall trend was obtained using the merged data set and identical weights. 3.2. Flow & Energy Transport Simulations with SSOR-Preconditioned Energy Equation Based on the solution behavior observed in the flow-only scenarios, only CG:ILU was used to solve the pressure correction equation in the flow and energy transport simulations. Momentum equations were also preconditioned only with ILU, while SSOR was used just for the energy equation. Various combinations of BiCGstab(L) for the momentum and energy equations were tested first, and the two most suitable combinations were then evaluated in detail using square neighborhoods of promising relaxation factor tuples (i.e., the pivot points). The best results overall were obtained using BiCGstab(3) and BiCGstab(1) for the momentum equations and the energy equation, respectively (see Figure 6). This setup was relatively robust, most probably because of the better stability and smoothness of convergence resulting from the use of BiCGstab(1). Figure 7shows the second-best combination, featuring only BiCGstab(2). On average, this setup was ~38% slower, and more combinations of ωF and ωR resulted in solution failures. It can also be seen that all the suitable relaxation factor tuples were in a relatively small neighborhood of (1, 1). Furthermore, with the SSOR-preconditioned energy equation, a significantly larger percentage of failures than before was due to slow convergence (that is, the respective iteration limits were exceeded). The data sets mentioned above were then combined with data sets obtained by evaluating square neighborhoods of the promising tuples of ωF and ωR to get the corresponding relaxation factor trends. Again, the standard weighted least squares method was used with the weights being calculated in the same manner as before. Because the best setup and the second-best one (featured in Figures 6 and 7) were, at least in some cases, on par, the trends were calculated for both of them (see Table 4 and Figure 8). It is of note here that all benchmarks involving the largest mesh and BiCGstab(1) had failed. This suggests that the respective solution method simply is too slow when combined with SSOR. In any case, the best results were obtained with ωF around 1.2 or 1.1 when BiCGstab(1) or BiCGstab(2) were used, respectively. This means that, given the calculated relaxation factor trends, ωR should also Energies 2019,12, 2438 9 of 16 be a little above 1.0 (i.e., it is best to slightly overrelax both SSOR sweeps when solving the energy equation). Energies 2018, 11, x FOR PEER REVIEW 9 of 16 Table 4. Relaxation factor trends, ωR = aωF + b, for individual mesh sizes and the overall relaxation 300 factor trends for the two discussed setups using either BiCGstab(1):SSOR or BiCGstab(2):SSOR to 301 solve the energy equation; R2 denotes the coefficient of determination, SE(a) and SE(b) denote the 302 standard error values for the coefficients a, b, and “n/a” denotes the fact that all the respective 303 benchmarks had failed, and thus the trend could not be obtained. 304 Mesh size (cells) BiCGstab(1) BiCGstab(2) a b R2 SE(a) SE(b) a b R2 SE(a) SE(b) ~6000 0.867 0.047 0.555 0.027 0.009 0.960 0.007 0.929 0.008 0.004 ~8000 0.762 0.120 0.564 0.023 0.013 0.971 0.005 0.936 0.007 0.003 ~16,000 0.717 0.069 0.512 0.037 0.011 0.995 0.003 0.944 0.006 0.002 ~25,000 0.905 0.012 0.888 0.009 0.002 0.964 0.012 0.922 0.013 0.006 ~41,000 n/a n/a n/a n/a n/a 0.994 0.001 0.940 0.013 0.001 Overall trend 0.866 0.042 0.676 0.009 0.003 0.972 0.005 0.939 0.004 0.001 305 Figure 6. Mean computational times for three different meshes and various combinations of ωF and 306 ωR, CG:ILU was used to solve the pressure correction equation, BiCGstab(3):ILU was used for the 307 momentum equations, and BiCGstab(1):SSOR was used for the energy equation; diagonal crosses 308 indicate failing combinations of ωF and ωR. Please note that the colorbars have been adjusted so that 309 the best (i.e., the most relevant) combinations of ωF, ωR are easily identifiable. 310 311 Figure 7. Mean computational times corresponding to the meshes from Figure 6 and the cases when 312 the momentum equations were solved using BiCGstab(2):ILU, and the energy equation was solved 313 using BiCGstab(2):SSOR; diagonal crosses indicate failing combinations of ωF and ωR. Please note that 314 the colorbars have been adjusted so that the best (i.e., the most relevant) combinations of ωF, ωR are 315 easily identifiable. 316 Figure 6. Mean computational times for three different meshes and various combinations of ωF and ωR , CG:ILU was used to solve the pressure correction equation, BiCGstab(3):ILU was used for the momentum equations, and BiCGstab(1):SSOR was used for the energy equation; diagonal crosses indicate failing combinations of ωF and ωR . Please note that the colorbars have been adjusted so that the best (i.e., the most relevant) combinations of ωF,ωRare easily identifiable. Energies 2018, 11, x FOR PEER REVIEW 9 of 16 Table 4. Relaxation factor trends, ωR = aωF + b, for individual mesh sizes and the overall relaxation 300 factor trends for the two discussed setups using either BiCGstab(1):SSOR or BiCGstab(2):SSOR to 301 solve the energy equation; R2 denotes the coefficient of determination, SE(a) and SE(b) denote the 302 standard error values for the coefficients a, b, and “n/a” denotes the fact that all the respective 303 benchmarks had failed, and thus the trend could not be obtained. 304 Mesh size (cells) BiCGstab(1) BiCGstab(2) a b R2 SE(a) SE(b) a b R2 SE(a) SE(b) ~6000 0.867 0.047 0.555 0.027 0.009 0.960 0.007 0.929 0.008 0.004 ~8000 0.762 0.120 0.564 0.023 0.013 0.971 0.005 0.936 0.007 0.003 ~16,000 0.717 0.069 0.512 0.037 0.011 0.995 0.003 0.944 0.006 0.002 ~25,000 0.905 0.012 0.888 0.009 0.002 0.964 0.012 0.922 0.013 0.006 ~41,000 n/a n/a n/a n/a n/a 0.994 0.001 0.940 0.013 0.001 Overall trend 0.866 0.042 0.676 0.009 0.003 0.972 0.005 0.939 0.004 0.001 305 Figure 6. Mean computational times for three different meshes and various combinations of ωF and 306 ωR, CG:ILU was used to solve the pressure correction equation, BiCGstab(3):ILU was used for the 307 momentum equations, and BiCGstab(1):SSOR was used for the energy equation; diagonal crosses 308 indicate failing combinations of ωF and ωR. Please note that the colorbars have been adjusted so that 309 the best (i.e., the most relevant) combinations of ωF, ωR are easily identifiable. 310 311 Figure 7. Mean computational times corresponding to the meshes from Figure 6 and the cases when 312 the momentum equations were solved using BiCGstab(2):ILU, and the energy equation was solved 313 using BiCGstab(2):SSOR; diagonal crosses indicate failing combinations of ωF and ωR. Please note that 314 the colorbars have been adjusted so that the best (i.e., the most relevant) combinations of ωF, ωR are 315 easily identifiable. 316 Figure 7. Mean computational times corresponding to the meshes from Figure 6and the cases when the momentum equations were solved using BiCGstab(2):ILU, and the energy equation was solved using BiCGstab(2):SSOR; diagonal crosses indicate failing combinations of ωF and ωR . Please note that the colorbars have been adjusted so that the best (i.e., the most relevant) combinations of ωF , ωR are easily identifiable. Table 4. Relaxation factor trends, ωR =a ωF +b, for individual mesh sizes and the overall relaxation factor trends for the two discussed setups using either BiCGstab(1):SSOR or BiCGstab(2):SSOR to solve the energy equation; R 2 denotes the coefficient of determination, SE(a) and SE(b) denote the standard error values for the coefficients a,b, and “n/a” denotes the fact that all the respective benchmarks had failed, and thus the trend could not be obtained. Mesh Size (Cells) BiCGstab(1) BiCGstab(2) a b R2SE(a)SE(b)a b R2SE(a)SE(b) ~6000 0.867 0.047 0.555 0.027 0.009 0.960 0.007 0.929 0.008 0.004 ~8000 0.762 0.120 0.564 0.023 0.013 0.971 0.005 0.936 0.007 0.003 ~16,000 0.717 0.069 0.512 0.037 0.011 0.995 0.003 0.944 0.006 0.002 ~25,000 0.905 0.012 0.888 0.009 0.002 0.964 0.012 0.922 0.013 0.006 ~41,000 n/a n/a n/a n/a n/a 0.994 0.001 0.940 0.013 0.001 Overall trend 0.866 0.042 0.676 0.009 0.003 0.972 0.005 0.939 0.004 0.001 Energies 2019,12, 2438 16 of 16 35. Zhang, C.; Miao, G.; Zhu, Y. Convergence on successive over-relaxed iterative methods for non-Hermitian positive definite linear systems. J. Inequal. Appl. 2016,2016, 156. [CrossRef] 36. Wang, H.-D.; Huang, Z.-D. On convergence and semi-convergence of SSOR-like methods for augmented linear systems. Appl. Math. Comput. 2018,326, 87–104. [CrossRef] 37. Liang, Z.-Z.; Zhang, G.-F. On SSOR iteration method for a class of block two-by-two linear systems. Numer. Algorithms 2016,71, 655–671. [CrossRef] 38. Zhou, L.; Zhang, N. Semi-convergence analysis of GMSSOR methods for singular saddle point problems. Comput. Math. Appl. 2014,68, 596–605. [CrossRef] 39. Cao, G.; Huang, Y.; Song, Y. Convergence of parallel block SSOR multisplitting method for block H-matrix. Calcolo 2013,50, 239–253. [CrossRef] 40. Yang, S.; Gobbert, M.K. The optimal relaxation parameter for the SOR method applied to the Poisson equation in any space dimensions. Appl. Math. Lett. 2009,22, 325–331. [CrossRef] 41. Barrett, R.; Berry, M.W.; Chan, T.F.; Demmel, J.; Donato, J.; Dongarra, J.; Eijkhout, V.; Pozo, R.; Romine, C.; Van der Vorst, H. Templates for the Solution of Linear Systems: Building Blocks for Iterative Methods, 2nd ed.; Society for Industrial and Applied Mathematics (SIAM): Philadelphia, PA, USA, 1994; pp. 35–49. 42. Turek, V. On improving computational efficiency of simplified fluid flow models. Chem. Eng. Trans. 2018 ,70, 1447–1452. [CrossRef] 43. Van Doormaal, J.P.; Raithby, G.D. Enhancement of the SIMPLE method for predicting incompressible fluid flows. Numer. Heat Transf. 1984,7, 147–163. [CrossRef] 44. Patankar, S.V. A calculation procedure for two-dimensional elliptic situations. Numer. Heat Transf. 1981 ,4, 409–425. [CrossRef] 45. Hestenes, M.R.; Stiefel, E. Methods of conjugate gradients for solving linear systems. J. Res. Natl. Bur. Stand. 1952,49, 409–436. [CrossRef] 46. Sleijpen, G.L.; Fokkema, D.R. BiCGstab(l) for linear equations involving unsymmetric matrices with complex spectrum. Electron. Trans. Numer. Anal. 1993,1, 11–32. © 2019 by the author. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).