JP2005267418A - Numerical calculation method, numerical calculation device and numerical calculation program - Google Patents

Numerical calculation method, numerical calculation device and numerical calculation program Download PDF

Info

Publication number
JP2005267418A
JP2005267418A JP2004081163A JP2004081163A JP2005267418A JP 2005267418 A JP2005267418 A JP 2005267418A JP 2004081163 A JP2004081163 A JP 2004081163A JP 2004081163 A JP2004081163 A JP 2004081163A JP 2005267418 A JP2005267418 A JP 2005267418A
Authority
JP
Japan
Prior art keywords
residual
initial value
value
cycle
level
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP2004081163A
Other languages
Japanese (ja)
Inventor
Akihiro Ida
明弘 伊田
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
VINAS Co Ltd
Original Assignee
VINAS Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by VINAS Co Ltd filed Critical VINAS Co Ltd
Priority to JP2004081163A priority Critical patent/JP2005267418A/en
Publication of JP2005267418A publication Critical patent/JP2005267418A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Complex Calculations (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To enhance convergent property in a numerical calculation using a residual removal method adapting AMG (algebraic multi grid) method for an internal solver. <P>SOLUTION: A variable separation type AMG method is used. As an AMG cycle, v-cycle is used. In the v-cycle, in case of descending the grid level, the repetition frequency n of moderation is set relatively small when the level is shallow, and set relatively large when the level is deep. On the other hand, in case of ascending the grid level, the repetition frequency n of moderation is set to a predetermined value n<SB>u</SB>. According to this, a result close to the V-cycle can be obtained with a minimized calculation quantity. <P>COPYRIGHT: (C)2005,JPO&NCIPI

Description

本発明は、コンピュータを用いた数値計算技術に関するものである。   The present invention relates to a numerical calculation technique using a computer.

従来から、圧力、温度などの物理量を対象とした制御や数値計算において、逐次近似解法アルゴリズムの利用がなされている。逐次近似解法アルゴリズムとは、様々な最適制御理論に基づいて、逐次近似を繰り返し行いつつ、数値計算により最適解を求めるものである。   Conventionally, successive approximation algorithms have been used in control and numerical calculations for physical quantities such as pressure and temperature. The successive approximation algorithm is an algorithm for obtaining an optimal solution by numerical calculation while repeatedly performing successive approximation based on various optimal control theories.

そして、対象となる各パラメータの解を、高速かつ高精度に求めることができる収束性の高い逐次近似解法アルゴリズムとして、残差切除法が知られている。そして、特許文献1では、残差切除法において収束性の更なる向上を実現する技術が提案されている。   A residual ablation method is known as a highly convergent successive approximation algorithm that can obtain a solution for each target parameter at high speed and with high accuracy. And in patent document 1, the technique which implement | achieves the further improvement of convergence in the residual cutting method is proposed.

また、緩和法(ガウスザイデル法、SOR法など)の加速手法の1つとして、マルチグリッド(Multi Grid:MG)法がある。一般に、緩和法は、残差の高周波成分を速く除去することができるが、低周波成分を減衰させるためには、非常に多くの反復回数を必要とする。MG法では、格子間隔(粗さ)の異なる複数の格子を用意し、各格子上で緩和法を用いることによって、各格子における残差の高周波成分を除去し、解を高速で求める。ある格子における残差の低周波成分は、より粗い格子においては高周波成分となる。   As one of acceleration methods of relaxation methods (Gauss Seidel method, SOR method, etc.), there is a multi grid (MG) method. In general, the relaxation method can quickly remove the high-frequency component of the residual, but requires a very large number of iterations to attenuate the low-frequency component. In the MG method, a plurality of lattices having different lattice intervals (roughness) are prepared, and by using a relaxation method on each lattice, a high-frequency component of a residual in each lattice is removed, and a solution is obtained at high speed. The low frequency component of the residual in a certain grid becomes a high frequency component in a coarser grid.

そして、MG法の派生手法として、代数的マルチグリッド(Algebraic Multi Grid:AMG)法がある。上述のMG法(AMG法と区別するために幾何的マルチグリッド法と呼ばれることもある)を用いるためには、格子系を予め人手で準備しておく必要がある。これに対して、AMG法を用いる場合は、格子系を与える必要はなく、連立一次方程式を与えるだけでよい。AMG法では、与えられた連立一次方程式の係数行列から仮想の格子を作成し、疎グリッドの作成もまた係数行列の情報のみから行う。
特開2001−134304号公報 Andrew J. Cleary, et al. "ROBUSTNESS AND SCALABILITY OF ALGEBRAIC MULTIGRID", SIAM J. SCI. COMPUT.,2000,Vol.21,No.5, pp.1886-1908
As a derivation method of the MG method, there is an algebraic multigrid (AMG) method. In order to use the above-described MG method (sometimes called a geometric multigrid method in order to distinguish it from the AMG method), it is necessary to prepare a lattice system manually in advance. On the other hand, when the AMG method is used, it is not necessary to provide a lattice system, and it is only necessary to provide simultaneous linear equations. In the AMG method, a virtual lattice is created from a given coefficient matrix of simultaneous linear equations, and a sparse grid is also created only from the information of the coefficient matrix.
JP 2001-134304 A Andrew J. Cleary, et al. "ROBUSTNESS AND SCALABILITY OF ALGEBRAIC MULTIGRID", SIAM J. SCI. COMPUT., 2000, Vol.21, No.5, pp.1886-1908

本願発明者らは、上述のAMG法を、残差切除法の内部ソルバに利用することを検討している。   The inventors of the present application are considering using the above-described AMG method as an internal solver of the residual cutting method.

一方、構造解析や流体解析から得られる連立一次方程式では、未知変数に複数の物理量を含む場合がある。このような場合には、格子間の関係に物理量間の関係が加わるため、解くべき連立一次方程式の係数行列には、単一物理量の場合に比べて非零要素が多く含まれる。このため、問題が解きにくい(スティッフである)ことが多い。   On the other hand, in simultaneous linear equations obtained from structural analysis and fluid analysis, unknown variables may include a plurality of physical quantities. In such a case, since the relationship between physical quantities is added to the relationship between lattices, the coefficient matrix of the simultaneous linear equations to be solved contains more non-zero elements than in the case of a single physical quantity. For this reason, problems are often difficult to solve (stiff).

このようなスティッフな問題に対して、上述したような、内部ソルバにAMG法を採用した残差切除法を単に適用すると、収束解が得られなかったり、収束解を得るまでに多大な計算時間を要したりする場合がある。   For such a stiff problem, simply applying the residual cutting method adopting the AMG method to the internal solver as described above, a convergent solution cannot be obtained, or a long calculation time is required until a converged solution is obtained. May be required.

前記の問題に鑑み、本発明は、コンピュータによる逐次近似解法アルゴリズムを用いた数値計算、特に、AMG法を内部ソルバに採用した残差切除法を用いた数値計算において、収束性を高めることを課題とする。   In view of the above problems, the present invention has an object to improve convergence in numerical calculation using a successive approximation algorithm by a computer, in particular, numerical calculation using a residual cutting method employing the AMG method as an internal solver. And

前記の課題を解決するために、第1の発明が講じた解決手段は、物理量Uが満たすべき偏微分方程式を離散化したときの係数行列(N行N列、Nは正の整数)をA、非斉次項(ソース項)をfとしたとき、コンピュータを用いて、A・U=fを解き、物理量Uの数値計算を行うための方法、装置、およびプログラムとして、物理量Uの初期値U0を設定し、繰り返し回数mに初期値として0を、摂動量φの初期値として0を与え、残差rの初期値r0として(f−A・U0)を設定し、繰り返し回数mをインクリメントしながら、A・φ=rmの予測近似値Ψmを、内部ソルバを有する第1演算部によって反復計算によって求める第1のステップと、残差rm+1のL2ノルムを最小とする修正近似値φmを、第2演算部によって最適化ルーチンによって予測近似値Ψmから求め、近似解Um+1として(Um+φm)を与え、残差rm+1として(rm−A・φm)を与える第2のステップとを、近似解Umが収束するまで繰り返し実行するものであり、前記第1のステップは、前記内部ソルバにAMG法を用いるものであり、かつ、AMGサイクルとして、緩和の反復回数nが、グリッドレベルを降りる場合は、レベルが相対的に浅いときは相対的に小さく、レベルが相対的に深いときは相対的に大きく設定される一方、グリッドレベルを上がる場合は、所定の値に設定されたν−サイクルを用いるものである。 In order to solve the above-mentioned problem, the solution means taken by the first invention is that a coefficient matrix (N rows and N columns, N is a positive integer) obtained by discretizing a partial differential equation to be satisfied by the physical quantity U is A Assuming that the inhomogeneous term (source term) is f, a method, apparatus, and program for solving a numerical value of the physical quantity U by solving A · U = f using a computer, an initial value U of the physical quantity U 0 is set, 0 is given as the initial value to the number of iterations m, 0 is given as the initial value of the perturbation amount φ, (f−A · U 0 ) is set as the initial value r 0 of the residual r, and the number of iterations m while incrementing the predicted approximate value [psi m of a · φ = r m, and the minimum a first step of obtaining by iteration by the first calculation unit having an internal solver, the L2 norm of the residual r m + 1 The corrected approximate value φ m to be Calculated from the predicted approximate value [psi m Te, given as an approximate solution U m + 1 (U m + φ m), a second step of providing a residual r m + 1 a (r m -A · φ m) , The approximate solution U m is repeatedly executed until it converges, and the first step uses the AMG method for the internal solver, and as the AMG cycle, the number of relaxation iterations n determines the grid level. When descending, the level is relatively small when the level is relatively shallow, and relatively large when the level is relatively deep. On the other hand, when increasing the grid level, ν− is set to a predetermined value. A cycle is used.

そして、前記第1の発明におけるν−サイクルは、緩和法の反復回数nが、1)レベルkからレベルk+1に「制限」する前に行う緩和については、n=max(k−nb ,0)、2)レベルk+1からレベルkに「補間」する前に行う緩和については、n=nu と設定されている(nb ,nu は自然数)のが好ましい。 In the ν-cycle according to the first aspect of the present invention, n = max (k−n b , 0) is applied to the relaxation performed before the number of iterations n of the relaxation method is “limited” from 1) level k to level k + 1. 2) For relaxation performed before “interpolating” from level k + 1 to level k, n = nu is preferably set (n b and n u are natural numbers).

また、第2の発明が講じた解決手段は、物理量Uが満たすべき偏微分方程式を離散化したときの係数行列(N行N列、Nは正の整数)をA、非斉次項(ソース項)をfとしたとき、コンピュータを用いて、A・U=fを解き、物理量Uの数値計算を行うための方法、装置、およびプログラムであって、物理量Uの初期値U0を設定し、繰り返し回数mに初期値として0を、摂動量φの初期値として0を与え、残差rの初期値r0として(f−A・U0)を設定し、繰り返し回数mをインクリメントしながら、A・φ=rmの予測近似値Ψmを、内部ソルバを有する第1演算部によって反復計算によって求める第1のステップと、残差rm+1のL2ノルムを最小とする修正近似値φmを、第2演算部によって最適化ルーチンによって予測近似値Ψmから求め、近似解Um+1として(Um+φm)を与え、残差rm+1として(rm−A・φm)を与える第2のステップとを、近似解Umが収束するまで繰り返し実行するものであり、残差切除率が所定値よりも小さくなったとき、前記修正近似解φm を破棄し、前記第1のステップにおいて用いる内部ソルバのアルゴリズムの変更を伴うリセット処理を行うものである。 The solution provided by the second invention is that the coefficient matrix (N rows and N columns, N is a positive integer) when discretizing the partial differential equation to be satisfied by the physical quantity U is A, an inhomogeneous term (source term) ) Is a method, apparatus, and program for solving a numerical value of the physical quantity U by solving A · U = f using a computer, and setting an initial value U 0 of the physical quantity U, 0 is given as an initial value to the number of iterations m, 0 is given as the initial value of the perturbation amount φ, (f−A · U 0 ) is set as the initial value r 0 of the residual r, and the iteration number m is incremented, the predicted approximate value [psi m of a · φ = r m, a first step of obtaining by iteration by the first calculation unit having an internal solver, modified approximation which minimizes the L2 norm of the residual r m + 1 phi the m, from the predicted approximate value [psi m by the optimization routine by the second arithmetic unit Because, given as an approximate solution U m + 1 (U m + φ m), a second step of providing a residual r m + 1 a (r m -A · φ m) , the approximate solution U m is converged When the residual cutting rate becomes smaller than a predetermined value, the modified approximate solution φ m is discarded, and a reset process that involves changing the algorithm of the internal solver used in the first step is performed. Is what you do.

そして、前記第2の発明において、前記第1のステップは、前記内部ソルバとしてAMG法を用いるものであり、前記リセット処理において、前記内部ソルバのアルゴリズムの変更として、AMGサイクルにおける緩和の反復回数nの設定の変更を行うのが好ましい。   In the second invention, the first step uses an AMG method as the internal solver. In the reset process, as the algorithm of the internal solver is changed, the number of iterations n of relaxation in the AMG cycle is n. It is preferable to change the setting.

第1の発明によると、残差切除法の内部ソルバにおけるAMGサイクルとして、ν−サイクルを用いる。ν−サイクルでは、グリッドレベルを降りる際には、「制限」前に行う緩和の影響が小さいと考えられる浅いレベルでは、緩和の反復回数が少なく設定され、深いレベルでは多く設定されている。一方、グリッドレベルを昇る際には、「補間」後の緩和の反復回数は、V−サイクルと同様に、所定値に設定されている。したがって、より少ない計算量によって、V−サイクルとほぼ同等の性能を得ることができる。   According to the first invention, the ν-cycle is used as the AMG cycle in the internal solver of the residual cutting method. In the ν-cycle, when descending the grid level, the number of iterations of relaxation is set to a low level at a shallow level where the influence of the relaxation performed before “restriction” is considered to be small, and a large number is set to a deep level. On the other hand, when increasing the grid level, the number of iterations of relaxation after “interpolation” is set to a predetermined value as in the V-cycle. Therefore, it is possible to obtain almost the same performance as the V-cycle with a smaller amount of calculation.

第2の発明によると、残差切除率が所定値よりも小さくなったとき、リセット処理が行われ、内部ソルバのアルゴリズムが変更される。これにより、解の修正方向を見出す能力がなくなった状態から抜けだし、それまでとは異なる解修正方向を見出す可能性を高めることができる。したがって、収束性をより向上させることができる。   According to the second invention, when the residual cutting rate becomes smaller than a predetermined value, the reset process is performed and the algorithm of the internal solver is changed. As a result, it is possible to increase the possibility of finding a solution correction direction that is different from the previous one, since the ability to find the solution correction direction is lost. Therefore, the convergence can be further improved.

以下、本発明の実施形態を図面に基づいて詳細に説明する。   Hereinafter, embodiments of the present invention will be described in detail with reference to the drawings.

本実施形態に係る数値計算方法は、内部ソルバにAMG法を利用した残差切除法によるものである。   The numerical calculation method according to the present embodiment is based on the residual cutting method using the AMG method for the internal solver.

<AMG法>
まず初めに、AMG法の概要について、説明する。
<AMG method>
First, an outline of the AMG method will be described.

AMG法の処理は、AMGセットアップと、AMGサイクルとの2つに大別される。AMGセットアップでは、疎グリッドの生成、疎密グリッド間の「制限」「補間」関数の生成、および疎グリッドにおける係数行列の生成が、行われる。これらの詳細については、上述した非特許文献1に詳述されているので、ここではその説明を省略する。   The processing of the AMG method is roughly divided into two types: AMG setup and AMG cycle. In the AMG setup, generation of sparse grids, generation of “restrictions” and “interpolation” functions between sparse grids, and generation of coefficient matrices in sparse grids are performed. Since these details are described in detail in Non-Patent Document 1 described above, the description thereof is omitted here.

(AMGサイクル)
AMGサイクルは、AMGセットアップにおいて生成した疎グリッド、「制限」「補間」関数、および係数行列を用いて、連立一次方程式を解くフェーズである。最も簡単なサイクルは、グリッドが2段のみの場合であり、次の手順A〜Eで1サイクルとなる。
(AMG cycle)
The AMG cycle is a phase in which simultaneous linear equations are solved using a sparse grid generated in an AMG setup, a “restriction” “interpolation” function, and a coefficient matrix. The simplest cycle is a case where there are only two grids, and the following procedures A to E result in one cycle.

A.A0 0 =f0 に対して、n回緩和法(ガウスザイデル法など)を適用する(制限前緩和)
B.制限関数I0 1を用いて、f1 =I0 1(f0 −A0 0 )を計算する。
A. Apply n-time relaxation method (Gauss-Seidel method, etc.) to A 0 U 0 = f 0 (relaxation before restriction)
B. Using the limiting function I 0 1 , f 1 = I 0 1 (f 0 −A 0 U 0 ) is calculated.

C.A1 1 =f1 を解いて、U1 を求める。 C. Solve A 1 U 1 = f 1, obtaining the U 1.

D.補間関数I1 0を用いて、近似解の補正U0 ←U0 +I1 01 を行う。 D. Using an interpolation function I 1 0, corrects U 0 ← U 0 + I 1 0 U 1 of the approximate solution.

E.A0 0 =f0 に対してn回緩和法を適用する(補間後緩和)。 E. Apply the relaxation method n times to A 0 U 0 = f 0 (relaxation after interpolation).

ここでの上付添字は、グリッドレベルを示している。添字が0の式、すなわちグリッドレベル0における式が、上述の添字なしの式 A・U=f に対応している。なお、紛らわしいが、AMGサイクル以外での上付添字は、反復回数を表している。   The superscript here indicates the grid level. An expression with a subscript of 0, that is, an expression at grid level 0 corresponds to the above-described expression A · U = f without a subscript. Note that, although confusing, the superscripts other than the AMG cycle indicate the number of iterations.

上の手順A〜Eのサイクルは、図1のように表現される。図1において、縦方向はグリッドレベル、横方向は処理順序である。手順A,Eは同じグリッドレベル0における処理であり、手順Cはグリッドレベル1における処理である。また、手順Bは「制限」の関数によってグリッドレベルをレベル0からレベル1に遷移する処理、手順Dは「補間」の関数によってグリッドレベルをレベル1からレベル0に遷移する処理である。図1に示すように、このような処理は、点と線とで表される形状が文字「V」に似ていることから、「V−サイクル」と呼ばれる。   The cycle of the above procedures A to E is expressed as shown in FIG. In FIG. 1, the vertical direction is the grid level, and the horizontal direction is the processing order. Procedures A and E are processing at the same grid level 0, and procedure C is processing at grid level 1. The procedure B is a process of transitioning the grid level from the level 0 to the level 1 by the “restriction” function, and the procedure D is a process of transitioning the grid level from the level 1 to the level 0 by the “interpolation” function. As shown in FIG. 1, such processing is called “V-cycle” because the shape represented by dots and lines is similar to the letter “V”.

また、グリッドが3段以上の場合のV−サイクルも、2段の場合と同様である。すなわち、手順A,Bを繰り返すことによってグリッドレベルを下がって行き、最深グリッドで解を求め(手順C)、手順D,Eを繰り返すことによってグリッドレベルを昇って行き、1サイクルを終える。   The V-cycle when the grid has three or more stages is the same as the case of two stages. That is, the grid level is lowered by repeating the procedures A and B, the solution is obtained at the deepest grid (procedure C), the grid level is raised by repeating the procedures D and E, and one cycle is completed.

また、V−サイクル以外にも、W−サイクルや鋸歯−サイクルなどが提案されている。図2はグリッドが3段の場合のW−サイクル(a)と鋸歯−サイクル(b)を示す概念図である。   In addition to V-cycles, W-cycles and sawtooth-cycles have been proposed. FIG. 2 is a conceptual diagram showing a W-cycle (a) and a sawtooth-cycle (b) when the grid has three stages.

(変数分離型AMG法)
上述したように、AMG法では、疎グリッドの生成(格子の間引き)を、係数行列という情報に基づいて行う。解くべき連立一次方程式の元になる微分方程式に未知量が1種類しかない場合、すなわち、1つのグリッド上に1つの未知量しか存在しない場合には、係数行列からグリッド情報を類推できる場合が多い。しかし、多変量の問題を扱う場合には、係数行列のみからグリッド情報を読みとることは一般には困難である。この困難を回避するために考案された手法が、変数分離型AMG法である。
(Variable separation type AMG method)
As described above, in the AMG method, sparse grid generation (lattice thinning) is performed based on information called a coefficient matrix. When there is only one kind of unknown in the differential equation that is the basis of the simultaneous linear equations to be solved, that is, when there is only one unknown on one grid, it is often possible to infer grid information from a coefficient matrix. . However, when dealing with multivariate problems, it is generally difficult to read grid information from only the coefficient matrix. A technique devised to avoid this difficulty is the variable separation AMG method.

変数分離型AMG法では、疎グリッドの生成を行うために、係数行列以外に、未知量の種類に関する情報を用いる。具体的な手順は次のとおりである。   In the variable separation type AMG method, in order to generate a sparse grid, in addition to the coefficient matrix, information on the type of unknown amount is used. The specific procedure is as follows.

A.密グリッドにおいて、未知量を種類毎に分離し、係数行列において種類の異なる未知量間の相互作用を表す項を無視することによって、各種類の未知量毎に連立一次方程式を構築する。   A. In the dense grid, the unknown quantities are separated for each type, and the simultaneous linear equations are constructed for each type of unknown quantities by ignoring the terms representing the interactions between the different kinds of unknown quantities in the coefficient matrix.

B.一般的なAMGセットアップのアルゴリズムを用いて、各種類の未知量毎に、疎グリッド、および疎密グリッド間の「制限」「補間」関数を生成する。   B. Using a general AMG setup algorithm, a sparse grid and a “restriction” and “interpolation” function between sparse and dense grids are generated for each type of unknown quantity.

C.手順Bにおいて生成した疎グリッド、および「制限」「補間」関数、並びに未知量間の相互作用を表す項を無視しない元の係数行列を用いて、疎グリッド上における連立一次方程式の係数行列を構築する。   C. Constructing a coefficient matrix of simultaneous linear equations on a sparse grid using the sparse grid generated in step B, the "constraint" "interpolation" function, and the original coefficient matrix that does not ignore the terms representing the interaction between unknowns To do.

図3は本実施形態に係る数値計算方法を示すフローチャートである。また図4は本実施形態に係る数値計算装置1の構成を示すブロック図である。本実施形態では、解修正ベクトルΨを求める残差切除法の内部ソルバに、上述の変数分離型AMG法を利用する。この数値計算方法は、例えばCD−ROM2のような記録媒体に記録されている、当該方法を実現するためのプログラムを、コンピュータに実行させることによって、実施することができる。また、当該方法を実現するためのプログラムを実行するコンピュータを備えた装置によって、容易に実現することができる。   FIG. 3 is a flowchart showing a numerical calculation method according to this embodiment. FIG. 4 is a block diagram showing the configuration of the numerical calculation apparatus 1 according to this embodiment. In the present embodiment, the above-described variable separation type AMG method is used as an internal solver of the residual cutting method for obtaining the solution correction vector Ψ. This numerical calculation method can be implemented by causing a computer to execute a program for realizing the method, which is recorded on a recording medium such as the CD-ROM 2. In addition, it can be easily realized by an apparatus including a computer that executes a program for realizing the method.

本実施形態に係る数値計算方法には、従来にはない特徴が、いくつか含まれている。その1つが、「ν−AMGサイクル」であり、もう1つが、「リセット発生時のAMGサイクルの変更」である。   The numerical calculation method according to the present embodiment includes some features that are not present in the past. One of them is the “ν-AMG cycle”, and the other is “change of the AMG cycle when a reset occurs”.

<ν−AMGサイクル>
本実施形態では、内部ソルバにおける1回の処理において、次のようなサイクル1サイクルのみを用いるものとする。
<Ν-AMG cycle>
In this embodiment, it is assumed that only one cycle as described below is used in one process in the internal solver.

当初未知変数が属しているグリッドのレベルをレベル0とし、グリッドが粗くなるにつれてレベル1,レベル2,…とグリッド番号が増加するものとする。nb ,nu を自然数とし、緩和法の反復回数をnとしたとき、
1)レベルkからレベルk+1に「制限」する前に行う緩和については、
n=max(k−nb ,0)
2)レベルk+1からレベルkに「補間」する前に行う緩和については、
n=nu
とする。
Assume that the level of the grid to which the unknown variable belongs initially is level 0, and the grid number increases as level 1, level 2,. When n b and n u are natural numbers and the number of iterations of the relaxation method is n,
1) For mitigation before “restricting” from level k to level k + 1:
n = max (k−n b , 0)
2) For mitigation before “interpolating” from level k + 1 to level k:
n = n u
And

図5は本実施形態において用いるAMGサイクルの一例である。図5では、6段のグリッドを用い、nb =1としている。レベル0からレベル1への制限、およびレベル1からレベル2への制限においては、緩和法の反復回数n=0となっている。本願発明者は、このようなAMGサイクルを、「ν−サイクル」と名付けた。 FIG. 5 shows an example of the AMG cycle used in this embodiment. In FIG. 5, a 6-stage grid is used, and n b = 1. In the restriction from level 0 to level 1 and the restriction from level 1 to level 2, the number of relaxation iterations n = 0. The present inventor has named such an AMG cycle as a “ν-cycle”.

本願発明者が考案したν−サイクルの利点について説明する。   The advantages of the ν-cycle devised by the present inventor will be described.

残差切除法における内部ソルバの役割は、反復過去の解修正ベクトル列とは独立な方向を見つけることであり、内部ソルバによって残差方程式が正確に解かれる必要はない。極端な表現をすれば、残差切除法の内部ソルバは、単体では連立一次方程式を解く能力がなくてもよい。   The role of the internal solver in the residual cutting method is to find a direction independent of the solution correction vector sequence of the past iterations, and the residual equation does not need to be accurately solved by the internal solver. In extreme terms, the residual solver internal solver may not have the ability to solve simultaneous linear equations alone.

内部ソルバにAMG法を用いた場合、数値実験の結果から次のようなことが分かった。V−サイクルよりも手順の多いサイクル(W−サイクルなど)を用いたときは、いずれのサイクルを用いても残差切除法の反復1回あたりの収束率に大きな変化はない。一方、鋸歯−サイクルを用いたときは、収束率が顕著に低下する。V−サイクルでは、反復過去の解修正ベクトル列とは独立な方向を見つけることができるが、鋸歯−サイクルでは見つけることが困難である場合が多いと考えられる。ν−サイクルは、V−サイクルよりも鋸歯−サイクルに近いが、鋸歯−サイクルよりも計算量は少なくて済む。これは、鋸歯−サイクルでは最密グリッドから一段粗いグリッドに「制限」する前に行われる緩和が、ν−サイクルでは行われないからである。   When the AMG method was used for the internal solver, the following was found from the results of numerical experiments. When a cycle with more procedures than the V-cycle (such as a W-cycle) is used, there is no significant change in the convergence rate per iteration of the residual cutting method regardless of which cycle is used. On the other hand, when the sawtooth cycle is used, the convergence rate is significantly reduced. In the V-cycle, it is possible to find a direction independent of the solution correction vector sequence in the past, but it is often difficult to find in the sawtooth cycle. The ν-cycle is closer to the sawtooth-cycle than the V-cycle, but requires less computation than the sawtooth-cycle. This is because in the sawtooth cycle, the relaxation that occurs before “limiting” from the closest grid to the coarser grid is not performed in the v-cycle.

そして、次のような理由によって、鋸歯−サイクルよりも計算量が少ないν−サイクルを用いた場合に、良好な結果が得られると考えられる。すなわち、残差切除法の内部ソルバによって計算される問題は初期値に零ベクトルを用いることが多いため、グリッドレベルが浅いときは、「制限」前に行う緩和の影響は小さいと考えられる。ν−サイクルでは、緩和の影響が小さいと考えられる浅いグリッドレベルでは、「制限」前に緩和を行わないか、または、緩和の反復回数を少なくしている。一方、深いグリッドレベルでは、「制限」前に行う緩和の反復回数を多くしている。また、グリッドレベルを昇る際の「補間」後の緩和は、V−サイクルと同様に、反復回数を一定回数にしている。したがって、ν−サイクルは、V−サイクルに近い結果を生むと考えられる。   And, for the following reason, it is considered that a good result can be obtained when the ν-cycle having a smaller calculation amount than the sawtooth-cycle is used. That is, since the problem calculated by the internal solver of the residual cutting method often uses a zero vector as the initial value, it is considered that the effect of relaxation performed before “restriction” is small when the grid level is shallow. In the v-cycle, at shallow grid levels where the effect of relaxation is considered to be small, relaxation is not performed before “restriction” or the number of relaxation iterations is reduced. On the other hand, at the deep grid level, the number of relaxation iterations performed before the “limit” is increased. In addition, the relaxation after “interpolation” when raising the grid level is performed by setting the number of iterations to a fixed number, as in the V-cycle. Therefore, the ν-cycle is considered to produce results close to the V-cycle.

<リセット時のAMGサイクル変更>
m反復目における相対残差εm (=‖rm ‖/‖b‖)に対して、残差切除率δm =(εm −εm+1)/εm が所定の値Δよりも小さくなったとき、次の処理を行う。
<AMG cycle change at reset>
For the relative residual ε m (= ‖r m ‖ / ‖b‖) in the m-th iteration, the residual cutting rate δ m = (ε m −ε m + 1 ) / ε m is larger than a predetermined value Δ. When it becomes smaller, the following processing is performed.

処理A m反復目までの反復過去の解修正ベクトルの列φl (l=m−Lmax+1,…,m)を破棄する。 Process A The sequence φ l (l = m−L max +1,..., M) of solution correction vectors in the past iterations up to the mth iteration is discarded.

処理B 内部ソルバのアルゴリズムを変更する。   Process B Change the internal solver algorithm.

処理Aは、一般に反復法のリセットとして知られる手法である。反復法が局所解に陥った場合に対する対処法として知られており、所定の反復回数目にリセットを行う手法や、所定の反復回数毎にリセットを行う手法が報告されている。   Process A is a technique commonly known as iterative reset. It is known as a coping method when the iteration method falls into a local solution, and a method of resetting at a predetermined number of iterations and a method of resetting at every predetermined number of iterations have been reported.

残差切除法では、内部ソルバによって、解を修正すべき方向(ベクトル)を検知し、近似解が解修正ベクトルと反復過去の解修正ベクトルとの線形結合で表されるとの仮定の基に、次の反復における相対残差が最小になるように、線形結合の係数を決定している。ここで、上述の残差切除率が極めて小さくなるということは、利用している内部ソルバに、それ以上解を修正すべき方向を見い出す能力がない、と考えられる。このため、内部ソルバのアルゴリズムを変更することによって、それまでとは異なる解修正方向を見いだす可能性を高める。   In the residual cutting method, an internal solver detects the direction (vector) in which the solution should be corrected, and based on the assumption that the approximate solution is represented by a linear combination of the solution correction vector and the solution correction vector of the past iteration. The coefficients of the linear combination are determined so that the relative residual in the next iteration is minimized. Here, the fact that the above-described residual cutting rate is extremely small is considered that the internal solver used does not have the ability to find a direction in which the solution should be corrected any more. For this reason, changing the algorithm of the internal solver increases the possibility of finding a different solution correction direction.

そして、本実施形態では、アルゴリズムの変更の一例として、AMGサイクルにおける緩和の反復回数nの設定を変更するものとする。   In this embodiment, as an example of changing the algorithm, the setting of the number of relaxation iterations n in the AMG cycle is changed.

具体的には、例えば次のように変更を行う。すなわち、計算開始から第1回目のリセットが発生するまでは、図5のようなν−サイクルを用いたAMGアルゴリズムを用いる。第1回目のリセットの後は、「制限」前および「補間」後に行われる緩和の反復回数を、全てn=nu 回とする。第2回目以降のリセットの後は、それまでの反復回数nに自然数ns を加え、これを新たな反復回数nとする。nが所定値Nに達したときは、未収束として、全ての処理を終了する。 Specifically, for example, changes are made as follows. That is, the AMG algorithm using the ν-cycle as shown in FIG. 5 is used from the start of calculation until the first reset occurs. After the first reset, the number of iterations of relaxation performed before “limit” and after “interpolation” is all n = nu . After the second and subsequent resets, a natural number ns is added to the number of iterations n so far, and this is set as a new iteration number n. When n reaches a predetermined value N, all the processing is terminated as non-convergence.

本願発明者が考案した、リセット時にAMGサイクルを変更する手法の利点は、次のように考えられる。上述の特許文献1でも論じられているように、残差切除法において内部ソルバにおける緩和回数を決定することは、困難かつ重要な問題である。緩和回数を小さくすると、反復1回当たりの計算量は小さくなるが、収束率が悪化するため、収束解に辿り着けない可能性が高くなる。逆に、緩和回数を大きくすると、反復1回当たりの計算量は大きくなるが、収束率が高くなり、収束解を安定的に得ることができる。   The advantage of the method of changing the AMG cycle at the time of reset devised by the present inventor is considered as follows. As discussed in the above-mentioned Patent Document 1, it is difficult and important to determine the number of relaxations in the internal solver in the residual cutting method. If the number of relaxations is reduced, the amount of calculation per iteration is reduced, but the convergence rate is deteriorated, so that there is a high possibility that the convergence solution cannot be reached. Conversely, when the number of relaxations is increased, the amount of calculation per iteration increases, but the convergence rate increases and a converged solution can be obtained stably.

上述したAMGサイクルの変更では、当初は計算量が少ないν−サイクルを用いて計算し、収束率(残差切除率)が小さくなったとき、計算量は多いが解修正方向を見出す能力が高いと考えられるV−サイクルに変更し、さらに収束率が小さくなったときは、V−サイクルの各段の緩和回数を増やしていく。これによって、できるだけ少ない計算量で、かつ、安定的に収束解を得ることができる。   In the change of the AMG cycle described above, the calculation is initially performed using the ν-cycle with a small amount of calculation, and when the convergence rate (residual cutting rate) becomes small, the amount of calculation is large but the ability to find the solution correction direction is high. When the V-cycle is considered to be changed and the convergence rate is further reduced, the number of relaxations at each stage of the V-cycle is increased. As a result, a convergent solution can be obtained stably with as little calculation as possible.

図3に示すフローチャートに従って、本実施形態に係る数値計算方法について説明する。   The numerical calculation method according to the present embodiment will be described with reference to the flowchart shown in FIG.

いま求めたい物理量をUとし、その物理量Uが満たすべき偏微分方程式を離散化したときの係数行列をA(N行N列)、非斉次項(ソース項)をfとすると、解くべき式は、
A・U=f …(1)
で表される。この式は、一般的には、SOR法、ADI法等の逐次近似法によって解くことができる。
If the physical quantity to be obtained is U, the coefficient matrix when the partial differential equation to be satisfied by the physical quantity U is discretized is A (N rows and N columns), and the inhomogeneous term (source term) is f, the equation to be solved is ,
A ・ U = f (1)
It is represented by In general, this equation can be solved by a successive approximation method such as the SOR method or the ADI method.

式(1)の解U∞を、近似解Uと摂動量(真の解との差)φとによって、次のように表す。
U∞=U+φ …(2)
そして、摂動量φを求めて近似解Uを修正していくことによって、式(1)の真の解U∞を求める。
The solution U∞ of Equation (1) is expressed as follows by the approximate solution U and the perturbation amount (difference from the true solution) φ.
U∞ = U + φ (2)
Then, the true solution U∞ of Equation (1) is obtained by obtaining the perturbation amount φ and correcting the approximate solution U.

ここで、近似解Uに対する残差rを次のように定義する。
r=f−A・U …(3)
式(1)〜(3)から、
A・(U+φ)=f
∴ A・φ=f−A・U
=r
したがって、摂動量φを求めるためには、次の式を解けばよい。
A・φ=r …(4)
Here, the residual r for the approximate solution U is defined as follows.
r = f−A · U (3)
From formulas (1) to (3),
A · (U + φ) = f
A A ・ φ = f−A ・ U
= R
Therefore, in order to obtain the perturbation amount φ, the following equation should be solved.
A · φ = r (4)

本実施形態では、式(4)の収束解を求めるのではなく、最も収束勾配の急な最小単位の反復で予測近似値Ψを求め、求めた予測近似値Ψを、最適化制御ルーチンに供給する。そして、最適化制御ルーチンの実行結果が所定の条件を満たすまで、予測近似値Ψの算出を繰り返し実行する。なお、処理の詳細については、特許文献1に記載されている。   In the present embodiment, instead of obtaining the convergence solution of Equation (4), the predicted approximate value Ψ is obtained by the iteration of the smallest unit with the steepest convergence gradient, and the obtained predicted approximate value Ψ is supplied to the optimization control routine. To do. The calculation of the predicted approximate value Ψ is repeatedly executed until the execution result of the optimization control routine satisfies a predetermined condition. Details of the processing are described in Patent Document 1.

まず、ステップS1において、対象物理量Uの初期値U0を設定する。そして、ステップS2において、AMGセットアップを行う。すなわち、疎グリッドの生成、疎密グリッド間の「制限」「補間」関数の生成、および疎グリッドにおける係数行列の生成が、行われる。 First, in step S1, an initial value U 0 of the target physical quantity U is set. In step S2, AMG setup is performed. That is, generation of sparse grids, generation of “restrictions” and “interpolation” functions between sparse and dense grids, and generation of coefficient matrices in sparse grids are performed.

次に、ステップS3において、繰り返し回数mに初期値として0を、摂動量φの初期値として0を与え、残差rの初期値r0として(f−A・U0)を設定する。また、相対残差εの初期値ε0として、‖r‖/‖f‖を与える。さらに、AMGサイクルにおける緩和の反復回数に関して、n=0とし、またnu,nsを所定値に設定する。また、リセットを判断するための所定値Δを設定する。 Next, in step S3, 0 is given as the initial value to the number of iterations m, 0 is given as the initial value of the perturbation amount φ, and (f−A · U 0 ) is set as the initial value r 0 of the residual r. Also, ‖r‖ / ‖f‖ is given as the initial value ε 0 of the relative residual ε. Further, regarding the number of relaxation iterations in the AMG cycle, n = 0 and n u and n s are set to predetermined values. In addition, a predetermined value Δ for determining reset is set.

以下、近似解Umが収束するまで、繰り返し回数mをインクリメントしながら、ステップS4〜S8を繰り返し実行する(S9,S11)。また、残差切除率δmが所定値Δよりも小さくなったとき、修正近似解φm を破棄し、内部ソルバのアルゴリズムを変更する。ここでは、AMGサイクルにおける緩和の反復回数nの設定の変更を行うものとする。 Thereafter, steps S4 to S8 are repeatedly executed while incrementing the number of repetitions m until the approximate solution U m converges (S9, S11). When the residual cutting rate δ m becomes smaller than the predetermined value Δ, the modified approximate solution φ m is discarded and the algorithm of the internal solver is changed. Here, it is assumed that the setting of the number n of iterations of relaxation in the AMG cycle is changed.

ステップS4〜S7(第1のステップ)では、AMG法を採用した内部ソルバ11を有する第1演算部10によって、
A・φ=rm
の予測近似値Ψm を求める。計算当初から第1回目のリセットがかかるまでは、n=0に設定されているので(ステップS4でNo)、ステップS5において、上述したν−サイクルをAMGサイクルとして実行する。すなわち、緩和法の反復回数nが、
1)レベルkからレベルk+1に「制限」する前に行う緩和については、
n=max(k−nb ,0)
2)レベルk+1からレベルkに「補間」する前に行う緩和については、
n=nu
と設定されている(nbは自然数)。
In steps S4 to S7 (first step), the first arithmetic unit 10 having the internal solver 11 employing the AMG method,
A ・ φ = r m
A predicted approximate value Ψ m of is obtained. Since n = 0 is set from the beginning of the calculation until the first reset is performed (No in step S4), the above-described ν-cycle is executed as an AMG cycle in step S5. That is, the number of iterations n of the relaxation method is
1) For mitigation before “restricting” from level k to level k + 1:
n = max (k−n b , 0)
2) For mitigation before “interpolating” from level k + 1 to level k:
n = n u
( Nb is a natural number).

ステップS4〜S7において予測近似値Ψm が求められると、ステップS8において、この予測近似値Ψm を用いて、第2演算部20における最適化ルーチンによって、次回の残差rm+1のL2ノルムが最小となるように、最適化された修正近似値φmを求める。残差最小化係数αl(l=1,…,L)の計算など最適化ルーチンにおける処理については、特許文献1で詳述されており、ここでは省略する。 When the predicted approximate value Ψ m is obtained in steps S4 to S7, in step S8, using the predicted approximate value Ψ m , L2 of the next residual r m + 1 is obtained by the optimization routine in the second arithmetic unit 20. An optimized modified approximate value φ m is obtained so that the norm is minimized. The processing in the optimization routine such as calculation of the residual minimization coefficient α l (l = 1,..., L) is described in detail in Patent Document 1, and is omitted here.

そして、この最適化された修正近似値φmによって、第(m+1)回目の繰り返しにおける近似値Um+1および残差rm+1は、次式で求められる。 Then, the approximate value U m + 1 and the residual r m + 1 in the (m + 1) th iteration are obtained from the optimized modified approximate value φ m by the following equation.

m+1=Um+φm
m+1=rm−A・φm
また、相対残差εm+1と、残差切除率δmもそれぞれ求められる。
U m + 1 = U m + φ m
r m + 1 = r m −A · φ m
Further, a relative residual ε m + 1 and a residual cutting rate δ m are also obtained.

そして、近似解Umがまだ収束しないとき(ステップS9でNo)、残差切除率δmを所定値Δと比較する(ステップS10)。そして、残差切除率δmが所定値Δを上回っているときは(S10でYes)、繰り返し回数mをインクリメントし(S11)、ステップS4に戻る。 When the approximate solution U m has not yet converged (No in step S9), the residual cutting rate δ m is compared with a predetermined value Δ (step S10). If the residual excision rate δ m exceeds the predetermined value Δ (Yes in S10), the repeat count m is incremented (S11), and the process returns to step S4.

一方、残差切除率δmが所定値Δを下回ったときは(S10でNo)、リセット処理を行い、内部ソルバのアルゴリズムを変更する。 On the other hand, when the residual cutting rate δ m falls below the predetermined value Δ (No in S10), reset processing is performed to change the algorithm of the internal solver.

第1回目のリセットのときは、n=0であるので(ステップS12でNo)、n=nuとする。また、反復過去の解修正ベクトルφl(l=m−Lmax+1,…,m)を零とする(ステップS13)。これにより、以降の繰り返しでは、ステップS4の分岐においてステップS6にすすみ、内部ソルバにおいて、V−サイクルがAMGサイクルとして実行される。V−サイクルの各段における緩和の反復回数は、n=nuである。 At the time of the first reset, since n = 0 (No in step S12), n = nu is set. In addition, the iterative past solution correction vector φ l (l = m−L max +1,..., M) is set to zero (step S13). Thereby, in subsequent iterations, the process proceeds to step S6 in the branch of step S4, and the V-cycle is executed as an AMG cycle in the internal solver. The number of relaxation iterations at each stage of the V-cycle is n = nu .

第2回目以降のリセットのときは、n>0であるので(ステップS12でYes)、nuにnsが加えられる(ステップS14)。そして、n=nuとする。また、反復過去の解修正ベクトルφl(l=m−Lmax+1,…,m)を零とする(ステップS13)。これにより、以降の繰り返しでは、内部ソルバにおいて、緩和の反復回数がnsだけ増えた,V−サイクルによるAMG法が実行される。 In the second and subsequent resets, since n> 0 (Yes in step S12), n s is added to n u (step S14). Then, n = nu . In addition, the iterative past solution correction vector φ l (l = m−L max +1,..., M) is set to zero (step S13). Thereby, in subsequent iterations, the AMG method by the V-cycle in which the number of iterations of relaxation is increased by n s in the internal solver is executed.

なお、ここでは、リセット時の内部ソルバアルゴリズムの変更を、AMGサイクルにおける緩和の反復回数の設定変更によって行うものとしたが、本発明はこれに限られるものではなく、例えば、あるアルゴリズムから全く別のアルゴリズムに変更することも考えられる。また、緩和の反復回数の変更の仕方も、ここで示したものに限られるものではなく、例えば、当初からV−サイクルを採用してリセット毎に緩和回数を増やすようにしてもよい。   Here, the internal solver algorithm at the time of resetting is changed by changing the setting of the number of iterations of relaxation in the AMG cycle. However, the present invention is not limited to this, and is completely different from a certain algorithm, for example. It is possible to change to this algorithm. Further, the method of changing the number of iterations of relaxation is not limited to the one shown here. For example, a V-cycle may be adopted from the beginning to increase the number of relaxations for each reset.

また、リセット処理を行わない場合であっても、ν−サイクルを採用することによって、少ない計算量によって、V−サイクルとほぼ同等の性能を得ることができる。   Further, even when the reset process is not performed, by adopting the ν-cycle, it is possible to obtain almost the same performance as the V-cycle with a small amount of calculation.

<数値実験>
本実施形態で示した数値計算方法を用いて、コンピュータによって、流体解析によって得られた連立一次方程式を実際に解いた。未知変数は、速度3成分と圧力の計4種類であり、その個数は合計143,386元である。
<Numerical experiment>
Using the numerical calculation method shown in this embodiment, a simultaneous linear equation obtained by fluid analysis was actually solved by a computer. There are four types of unknown variables: three speed components and pressure, and the total number is 143,386 yuan.

図6は数値実験の結果得られた収束曲線を示すグラフである。収束判定条件は、相対残差が1.0e−5以下となることとした。緩和法にはSOR法(緩和係数ω=0.2)を用い、nb=2,nu=2,ns=2とした。また比較例として、AMGサイクル内における緩和法の反復回数を4回に固定した場合を、破線で示している。 FIG. 6 is a graph showing a convergence curve obtained as a result of a numerical experiment. The convergence determination condition is that the relative residual is 1.0e-5 or less. As the relaxation method, the SOR method (relaxation coefficient ω = 0.2) was used, and n b = 2, n u = 2 and n s = 2. As a comparative example, the case where the number of iterations of the relaxation method in the AMG cycle is fixed to 4 is indicated by a broken line.

図6から分かるように、本実施形態によると、比較例よりも速い段階から収束を始め、収束が一旦止まった後も、3回目のリセットの後に、再び収束を始めている。これに対して比較例では、本実施形態よりも収束速度は遅く、また、一旦は本実施形態よりも精度が上回ったものの、やがて収束が止まってしまっている。したがって、本実施形態の方が、短時間での収束性が高く、また最終的に得られる精度も比較例を大きく上回っている。   As can be seen from FIG. 6, according to the present embodiment, convergence is started from a stage earlier than the comparative example, and after convergence has once stopped, convergence is started again after the third reset. On the other hand, in the comparative example, the convergence speed is slower than that of the present embodiment, and once the accuracy is higher than that of the present embodiment, the convergence is eventually stopped. Therefore, the present embodiment has higher convergence in a short time, and the accuracy finally obtained greatly exceeds the comparative example.

本発明では、AMG法を内部ソルバに採用した残差切除法を用いた数値計算において、収束性を高めることができるので、例えば、構造解析や流体解析などの数値計算の精度向上や速度向上に、有効である。   In the present invention, the convergence can be improved in the numerical calculation using the residual cutting method adopting the AMG method as an internal solver. For example, for improving the accuracy and speed of numerical calculation such as structural analysis and fluid analysis. ,It is valid.

AMGサイクルの一例としてのV−サイクルを概念的に示す図である。It is a figure which shows notionally the V-cycle as an example of an AMG cycle. AMGサイクルの一例を概念的に示す図であり、(a)はW−サイクル、(b)は鋸歯−サイクルである。It is a figure which shows an example of an AMG cycle conceptually, (a) is a W-cycle, (b) is a sawtooth-cycle. 本発明の一実施形態に係る数値計算方法を示すフローチャートである。It is a flowchart which shows the numerical calculation method which concerns on one Embodiment of this invention. 本発明の一実施形態に係る数値計算装置の構成を概念的に示すブロック図である。It is a block diagram which shows notionally the structure of the numerical calculation apparatus which concerns on one Embodiment of this invention. 本実施形態において用いるAMGサイクルの一例であるν−サイクルを概念的に示す図である。It is a figure which shows notionally the (nu) -cycle which is an example of the AMG cycle used in this embodiment. 数値実験の結果得られた収束曲線を示すグラフである。It is a graph which shows the convergence curve obtained as a result of the numerical experiment.

符号の説明Explanation of symbols

1 数値計算装置
10 第1演算部
11 内部ソルバ
20 第2演算部
DESCRIPTION OF SYMBOLS 1 Numerical calculation apparatus 10 1st calculating part 11 Internal solver 20 2nd calculating part

Claims (8)

物理量Uが満たすべき偏微分方程式を離散化したときの係数行列(N行N列、Nは正の整数)をA、非斉次項(ソース項)をfとしたとき、コンピュータを用いて、
A・U=f
を解き、物理量Uの数値計算を行う方法であって、
物理量Uの初期値U0を設定し、
繰り返し回数mに初期値として0を、摂動量φの初期値として0を与え、残差rの初期値r0として(f−A・U0)を設定し、
繰り返し回数mをインクリメントしながら、
A・φ=rmの予測近似値Ψmを、内部ソルバを有する第1演算部によって、反復計算によって求める第1のステップと、
残差rm+1のL2ノルムを最小とする修正近似値φmを、第2演算部によって、最適化ルーチンによって、予測近似値Ψmから求め、近似解Um+1として(Um+φm)を与え、残差rm+1として(rm−A・φm)を与える第2のステップとを、近似解Umが収束するまで、繰り返し実行するものであり、
前記第1のステップは、
前記内部ソルバにAMG法を用いるものであり、かつ、
AMGサイクルとして、緩和の反復回数nが、グリッドレベルを降りる場合は、レベルが相対的に浅いときは相対的に小さく、レベルが相対的に深いときは相対的に大きく設定される一方、グリッドレベルを上がる場合は、所定の値に設定されたν−サイクルを用いる
ことを特徴とする数値計算方法。
When the coefficient matrix (N rows and N columns, N is a positive integer) when discretizing the partial differential equation to be satisfied by the physical quantity U is A and the inhomogeneous term (source term) is f, using a computer,
A ・ U = f
And performing a numerical calculation of the physical quantity U,
Set the initial value U 0 of the physical quantity U,
0 is set as the initial value for the number of repetitions m, 0 is set as the initial value of the perturbation amount φ, and (f−A · U 0 ) is set as the initial value r 0 of the residual r.
While incrementing the repeat count m,
The predicted approximate value [psi m of A · φ = r m, the first operation unit having an internal solver, a first step of obtaining by iteration,
A modified approximate value φ m that minimizes the L2 norm of the residual r m + 1 is obtained from the predicted approximate value Ψ m by the optimization routine by the second arithmetic unit, and is used as an approximate solution U m + 1 (U m + φ m ) and the second step of giving (r m −A · φ m ) as the residual r m + 1 is repeatedly executed until the approximate solution U m converges,
The first step includes
AMG method is used for the internal solver, and
In the AMG cycle, when the number of relaxation iterations n falls below the grid level, it is set to be relatively small when the level is relatively shallow and relatively large when the level is relatively deep. A numerical calculation method characterized by using a ν-cycle set to a predetermined value when going up.
請求項1において、
前記ν−サイクルは、緩和法の反復回数nが、
1)レベルkからレベルk+1に「制限」する前に行う緩和については、
n=max(k−nb ,0)
2)レベルk+1からレベルkに「補間」する前に行う緩和については、
n=nu
と設定されているものである(nb ,nu は自然数)
ことを特徴とする数値計算方法。
In claim 1,
The ν-cycle has a relaxation method iteration number n
1) For mitigation before “restricting” from level k to level k + 1:
n = max (k−n b , 0)
2) For mitigation before “interpolating” from level k + 1 to level k:
n = n u
(N b and n u are natural numbers)
A numerical calculation method characterized by that.
物理量Uが満たすべき偏微分方程式を離散化したときの係数行列(N行N列、Nは正の整数)をA、非斉次項(ソース項)をfとしたとき、コンピュータを用いて、
A・U=f
を解き、物理量Uの数値計算を行う方法であって、
物理量Uの初期値U0を設定し、
繰り返し回数mに初期値として0を、摂動量φの初期値として0を与え、残差rの初期値r0として(f−A・U0)を設定し、
繰り返し回数mをインクリメントしながら、
A・φ=rmの予測近似値Ψmを、内部ソルバを有する第1演算部によって、反復計算によって求める第1のステップと、
残差rm+1のL2ノルムを最小とする修正近似値φmを、第2演算部によって、最適化ルーチンによって、予測近似値Ψmから求め、近似解Um+1として(Um+φm)を与え、残差rm+1として(rm−A・φm)を与える第2のステップとを、近似解Umが収束するまで、繰り返し実行するものであり、
残差切除率が所定値よりも小さくなったとき、前記修正近似解φm を破棄し、前記第1のステップにおいて用いる内部ソルバのアルゴリズムの変更を伴うリセット処理を行う
ことを特徴とする数値計算方法。
When the coefficient matrix (N rows and N columns, N is a positive integer) when discretizing the partial differential equation to be satisfied by the physical quantity U is A and the inhomogeneous term (source term) is f, using a computer,
A ・ U = f
And performing a numerical calculation of the physical quantity U,
Set the initial value U 0 of the physical quantity U,
0 is set as the initial value for the number of repetitions m, 0 is set as the initial value of the perturbation amount φ, and (f−A · U 0 ) is set as the initial value r 0 of the residual r.
While incrementing the repeat count m,
The predicted approximate value [psi m of A · φ = r m, the first operation unit having an internal solver, a first step of obtaining by iteration,
A modified approximate value φ m that minimizes the L2 norm of the residual r m + 1 is obtained from the predicted approximate value Ψ m by the optimization routine by the second arithmetic unit, and is used as an approximate solution U m + 1 (U m + φ m ) and the second step of giving (r m −A · φ m ) as the residual r m + 1 is repeatedly executed until the approximate solution U m converges,
When the residual cutting rate becomes smaller than a predetermined value, the modified approximate solution φ m is discarded, and a reset process involving a change in the algorithm of the internal solver used in the first step is performed. Method.
請求項3において、
前記第1のステップは、前記内部ソルバとして、AMG法を用いるものであり、
前記リセット処理において、前記内部ソルバのアルゴリズムの変更として、AMGサイクルにおける緩和の反復回数nの設定の変更を、行うものとする
ことを特徴とする数値計算方法。
In claim 3,
The first step uses an AMG method as the internal solver,
In the reset process, as a change of the algorithm of the internal solver, the setting of the number of iterations n of relaxation in the AMG cycle is changed.
物理量Uが満たすべき偏微分方程式を離散化したときの係数行列(N行N列、Nは正の整数)をA、非斉次項(ソース項)をfとしたとき、コンピュータを用いて、
A・U=f
を解き、物理量Uの数値計算を行う装置であって、
物理量Uの初期値U0を設定し、
繰り返し回数mに初期値として0を、摂動量φの初期値として0を与え、残差rの初期値r0として(f−A・U0)を設定し、
繰り返し回数mをインクリメントしながら、
A・φ=rmの予測近似値Ψmを、内部ソルバを有する第1演算部によって、反復計算によって求める第1のステップと、
残差rm+1のL2ノルムを最小とする修正近似値φmを、第2演算部によって、最適化ルーチンによって、予測近似値Ψmから求め、近似解Um+1として(Um+φm)を与え、残差rm+1として(rm−A・φm)を与える第2のステップとを、近似解Umが収束するまで、繰り返し実行するものであり、
前記第1のステップは、
前記内部ソルバにAMG法を用いるものであり、かつ、
AMGサイクルとして、緩和の反復回数nが、グリッドレベルを降りる場合は、レベルが相対的に浅いときは相対的に小さく、レベルが相対的に深いときは相対的に大きく設定される一方、グリッドレベルを上がる場合は、所定の値に設定されたν−サイクルを用いる
ことを特徴とする数値計算装置。
When the coefficient matrix (N rows and N columns, N is a positive integer) when discretizing the partial differential equation to be satisfied by the physical quantity U is A and the inhomogeneous term (source term) is f, using a computer,
A ・ U = f
Is a device that performs numerical calculation of the physical quantity U,
Set the initial value U 0 of the physical quantity U,
0 is set as the initial value for the number of repetitions m, 0 is set as the initial value of the perturbation amount φ, and (f−A · U 0 ) is set as the initial value r 0 of the residual r.
While incrementing the repeat count m,
The predicted approximate value [psi m of A · φ = r m, the first operation unit having an internal solver, a first step of obtaining by iteration,
A modified approximate value φ m that minimizes the L2 norm of the residual r m + 1 is obtained from the predicted approximate value Ψ m by the optimization routine by the second arithmetic unit, and is used as an approximate solution U m + 1 (U m + φ m ), and the second step of giving (r m −A · φ m ) as the residual r m + 1 is repeatedly executed until the approximate solution U m converges,
The first step includes
AMG method is used for the internal solver, and
As the AMG cycle, when the number of relaxation iterations n falls below the grid level, it is set to be relatively small when the level is relatively shallow, and relatively large when the level is relatively deep, whereas the grid level A numerical computation device using a ν-cycle set to a predetermined value when going up.
物理量Uが満たすべき偏微分方程式を離散化したときの係数行列(N行N列、Nは正の整数)をA、非斉次項(ソース項)をfとしたとき、コンピュータを用いて、
A・U=f
を解き、物理量Uの数値計算を行う装置であって、
物理量Uの初期値U0を設定し、
繰り返し回数mに初期値として0を、摂動量φの初期値として0を与え、残差rの初期値r0として(f−A・U0)を設定し、
繰り返し回数mをインクリメントしながら、
A・φ=rmの予測近似値Ψmを、内部ソルバを有する第1演算部によって、反復計算によって求める第1のステップと、
残差rm+1のL2ノルムを最小とする修正近似値φmを、第2演算部によって、最適化ルーチンによって、予測近似値Ψmから求め、近似解Um+1として(Um+φm)を与え、残差rm+1として(rm−A・φm)を与える第2のステップとを、近似解Umが収束するまで、繰り返し実行するものであり、
残差切除率が所定値よりも小さくなったとき、前記修正近似解φm を破棄し、前記第1のステップにおいて用いる内部ソルバのアルゴリズムの変更を伴うリセット処理を行う
ことを特徴とする数値計算装置。
When the coefficient matrix (N rows and N columns, N is a positive integer) when discretizing the partial differential equation to be satisfied by the physical quantity U is A and the inhomogeneous term (source term) is f, using a computer,
A ・ U = f
Is a device that performs numerical calculation of the physical quantity U,
Set the initial value U 0 of the physical quantity U,
0 is set as the initial value for the number of repetitions m, 0 is set as the initial value of the perturbation amount φ, and (f−A · U 0 ) is set as the initial value r 0 of the residual r.
While incrementing the repeat count m,
The predicted approximate value [psi m of A · φ = r m, the first operation unit having an internal solver, a first step of obtaining by iteration,
The corrected approximate value φ m that minimizes the L2 norm of the residual r m + 1 is obtained from the predicted approximate value Ψ m by the optimization routine by the second arithmetic unit, and is used as an approximate solution U m + 1 (U m + φ m ) and the second step of giving (r m −A · φ m ) as the residual r m + 1 is repeatedly executed until the approximate solution U m converges,
When the residual cutting rate becomes smaller than a predetermined value, the modified approximate solution φ m is discarded, and a reset process involving a change in the algorithm of the internal solver used in the first step is performed. apparatus.
コンピュータに、物理量Uが満たすべき偏微分方程式を離散化したときの係数行列(N行N列、Nは正の整数)をA、非斉次項(ソース項)をfとしたとき、
A・U=f
を解かせ、物理量Uの数値計算を行う数値計算用プログラムであって、
物理量Uの初期値U0を設定し、
繰り返し回数mに初期値として0を、摂動量φの初期値として0を与え、残差rの初期値r0として(f−A・U0)を設定し、
繰り返し回数mをインクリメントしながら、
A・φ=rmの予測近似値Ψmを、内部ソルバを有する第1演算部によって、反復計算によって求める第1のステップと、
残差rm+1のL2ノルムを最小とする修正近似値φmを、第2演算部によって、最適化ルーチンによって、予測近似値Ψmから求め、近似解Um+1として(Um+φm)を与え、残差rm+1として(rm−A・φm)を与える第2のステップとを、近似解Umが収束するまで、繰り返し実行するものであり、
前記第1のステップは、
前記内部ソルバにAMG法を用いるものであり、かつ、
AMGサイクルとして、緩和の反復回数nが、グリッドレベルを降りる場合は、レベルが相対的に浅いときは相対的に小さく、レベルが相対的に深いときは相対的に大きく設定される一方、グリッドレベルを上がる場合は、所定の値に設定されたν−サイクルを用いる
処理をコンピュータに実行させる数値計算用プログラム。
When the coefficient matrix (N rows and N columns, N is a positive integer) when discretizing the partial differential equation to be satisfied by the physical quantity U is set to A and the inhomogeneous term (source term) is f,
A ・ U = f
And a numerical calculation program for calculating a physical quantity U,
Set the initial value U 0 of the physical quantity U,
0 is set as the initial value for the number of repetitions m, 0 is set as the initial value of the perturbation amount φ, and (f−A · U 0 ) is set as the initial value r 0 of the residual r.
While incrementing the repeat count m,
The predicted approximate value [psi m of A · φ = r m, the first operation unit having an internal solver, a first step of obtaining by iteration,
A modified approximate value φ m that minimizes the L2 norm of the residual r m + 1 is obtained from the predicted approximate value Ψ m by the optimization routine by the second arithmetic unit, and is used as an approximate solution U m + 1 (U m + φ m ) and the second step of giving (r m −A · φ m ) as the residual r m + 1 is repeatedly executed until the approximate solution U m converges,
The first step includes
AMG method is used for the internal solver, and
In the AMG cycle, when the number of relaxation iterations n falls below the grid level, it is set to be relatively small when the level is relatively shallow and relatively large when the level is relatively deep. A program for numerical calculation that causes a computer to execute processing using a ν-cycle set to a predetermined value.
コンピュータに、物理量Uが満たすべき偏微分方程式を離散化したときの係数行列(N行N列、Nは正の整数)をA、非斉次項(ソース項)をfとしたとき、
A・U=f
を解かせ、物理量Uの数値計算を行う数値計算用プログラムであって、
物理量Uの初期値U0を設定し、
繰り返し回数mに初期値として0を、摂動量φの初期値として0を与え、残差rの初期値r0として(f−A・U0)を設定し、
繰り返し回数mをインクリメントしながら、
A・φ=rmの予測近似値Ψmを、内部ソルバを有する第1演算部によって、反復計算によって求める第1のステップと、
残差rm+1のL2ノルムを最小とする修正近似値φmを、第2演算部によって、最適化ルーチンによって、予測近似値Ψmから求め、近似解Um+1として(Um+φm)を与え、残差rm+1として(rm−A・φm)を与える第2のステップとを、近似解Umが収束するまで、繰り返し実行するものであり、
残差切除率が所定値よりも小さくなったとき、前記修正近似解φm を破棄し、前記第1のステップにおいて用いる内部ソルバのアルゴリズムの変更を伴うリセット処理を行う
処理をコンピュータに実行させる数値計算用プログラム。
When the coefficient matrix (N rows and N columns, N is a positive integer) when discretizing the partial differential equation to be satisfied by the physical quantity U is set to A and the inhomogeneous term (source term) is f,
A ・ U = f
And a numerical calculation program for calculating a physical quantity U,
Set the initial value U 0 of the physical quantity U,
0 is set as the initial value for the number of repetitions m, 0 is set as the initial value of the perturbation amount φ, and (f−A · U 0 ) is set as the initial value r 0 of the residual r.
While incrementing the repeat count m,
The predicted approximate value [psi m of A · φ = r m, the first operation unit having an internal solver, a first step of obtaining by iteration,
A modified approximate value φ m that minimizes the L2 norm of the residual r m + 1 is obtained from the predicted approximate value Ψ m by the optimization routine by the second arithmetic unit, and is used as an approximate solution U m + 1 (U m + φ m ) and the second step of giving (r m −A · φ m ) as the residual r m + 1 is repeatedly executed until the approximate solution U m converges,
When the residual cutting rate becomes smaller than a predetermined value, the modified approximate solution φ m is discarded, and a numerical value that causes the computer to execute a reset process that involves changing the algorithm of the internal solver used in the first step Calculation program.
JP2004081163A 2004-03-19 2004-03-19 Numerical calculation method, numerical calculation device and numerical calculation program Pending JP2005267418A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2004081163A JP2005267418A (en) 2004-03-19 2004-03-19 Numerical calculation method, numerical calculation device and numerical calculation program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2004081163A JP2005267418A (en) 2004-03-19 2004-03-19 Numerical calculation method, numerical calculation device and numerical calculation program

Publications (1)

Publication Number Publication Date
JP2005267418A true JP2005267418A (en) 2005-09-29

Family

ID=35091885

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2004081163A Pending JP2005267418A (en) 2004-03-19 2004-03-19 Numerical calculation method, numerical calculation device and numerical calculation program

Country Status (1)

Country Link
JP (1) JP2005267418A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2008078505A1 (en) * 2006-12-25 2008-07-03 Osaka University Finite element analysis device, finite element analysis method, and computer program
CN107993218A (en) * 2018-01-30 2018-05-04 重庆邮电大学 Image interfusion method based on algebraic multigrid and watershed segmentation

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2008078505A1 (en) * 2006-12-25 2008-07-03 Osaka University Finite element analysis device, finite element analysis method, and computer program
CN107993218A (en) * 2018-01-30 2018-05-04 重庆邮电大学 Image interfusion method based on algebraic multigrid and watershed segmentation
CN107993218B (en) * 2018-01-30 2021-09-07 重庆邮电大学 Image fusion method based on algebraic multiple meshes and watershed segmentation

Similar Documents

Publication Publication Date Title
Transtrum et al. Improvements to the Levenberg-Marquardt algorithm for nonlinear least-squares minimization
Nastase et al. High-order discontinuous Galerkin methods using an hp-multigrid approach
Xie et al. On numerical instabilities of Godunov-type schemes for strong shocks
JP5036450B2 (en) Simulation method and simulation program
US20200104708A1 (en) Training apparatus, inference apparatus and computer readable storage medium
US9189458B1 (en) Parameter estimation
Reyes et al. A variable high-order shock-capturing finite difference method with GP-WENO
Shepherd et al. Using full configuration interaction quantum Monte Carlo in a seniority zero space to investigate the correlation energy equivalence of pair coupled cluster doubles and doubly occupied configuration interaction
Carson The adaptive s-step conjugate gradient method
US20220058311A1 (en) Simulation of microstructure evolution of material as solved based on exponential time-difference format
JP4543192B1 (en) Transient stability limit value calculation method, transient stability limit value calculation device, and program
Wallraff et al. Numerical flux functions for Reynolds‐averaged Navier–Stokes and kω turbulence model computations with a line‐preconditioned p‐multigrid discontinuous Galerkin solver
JP2005267418A (en) Numerical calculation method, numerical calculation device and numerical calculation program
JP5918630B2 (en) Shape simulation apparatus, shape simulation method, and shape simulation program
Güttel et al. Automated parameter selection for rational Arnoldi approximation of Markov functions
Liu et al. A nonlinear elimination preconditioned inexact Newton algorithm
Svärd et al. Shock capturing artificial dissipation for high-order finite difference schemes
JP3978534B2 (en) Method for setting moving boundary moving on fixed grid and computer program for realizing the same
Lam et al. Fast kinetic Monte Carlo simulation of strained heteroepitaxy in three dimensions
Amaladas et al. Implicit and multigrid procedures for steady-state computations with upwind algorithms
Kotov et al. On spurious numerics in solving reactive equations
JP2004118394A (en) Liquid-vapor free interface simulation device
Baboulin et al. Using random butterfly transformations in parallel Schur complement-based preconditioning
Koellermeier Error estimators for adaptive simulation of rarefied gases using hyperbolic moment models
Howard et al. Solution of differential equations with genetic programming and the stochastic bernstein interpolation

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20070312

A977 Report on retrieval

Effective date: 20080911

Free format text: JAPANESE INTERMEDIATE CODE: A971007

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20080924

A02 Decision of refusal

Effective date: 20090203

Free format text: JAPANESE INTERMEDIATE CODE: A02