Construction and application of seventh-order WENO format

Through non-polynomial reconstruction and free parameter optimization, the numerical dissipation and resolution of the seventh-order WENO format are improved, the problem of large dissipation in smooth areas in the existing technology is solved, and the numerical simulation effect of multi-scale structures is improved.

CN117932782BActive Publication Date: 2024-09-20SICHUAN UNIV +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410095523.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-01-24
Publication Date
2024-09-20
Estimated Expiration
2044-01-24

AI Technical Summary

Technical Problem

The existing seventh-order WENO scheme has excessive numerical dissipation in the smooth flow region, which affects the numerical simulation effect of multi-scale structures.

Method used

Non-polynomial reconstruction technology is used to construct smooth metric factors through error analysis and free parameter optimization, improve the numerical dissipation and resolution of the format, and improve the reconstruction accuracy on the sub-template.

Benefits of technology

The numerical dissipation in the smooth region is reduced, the high resolution and non-oscillatory characteristics near the discontinuity are maintained, and the numerical simulation accuracy of the seventh-order WENO scheme is improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117932782B
    Figure CN117932782B
Patent Text Reader

Abstract

The present invention relates to the field of fluid mechanics, and provides a construction method and application method of a seventh-order WENO format, wherein the construction method comprises: performing non-polynomial reconstruction on four pre-defined sub-templates; performing error analysis, determining the non-polynomial reconstruction error, determining the high-order function of the flux function through the unit flux, determining the expression of the free parameter, and the free parameter is used to eliminate the non-polynomial reconstruction error; constructing a smoothness metric factor based on the flux derivative of the sub-template, and constructing the seventh-order WENO format based on the smoothness metric factor. This method is used to solve the problem that most existing seventh-order WENO formats use upwind polynomial reconstruction, and this polynomial reconstruction has too large numerical dissipation in the smooth flow area, which seriously affects the numerical simulation effect of the multi-scale structure. The method can optimize the reconstruction process and improve the numerical dissipation and resolution of the format.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of fluid mechanics, and in particular to a construction method and an application method of a seventh-order WENO format. Background Art

[0002] There are a large number of high-speed compressible complex turbulence problems in the field of aerospace engineering, and their numerical simulation is also a hot topic and difficulty in the field of aerodynamics and computational fluid dynamics. There are a large number of multi-scale turbulent structures in compressible complex turbulence, as well as discontinuous structures such as shock waves. For example, the upper surface of the wing of a large passenger aircraft in the cruise state may have laminar flow, turbulence and shock wave structures at the same time, and the tip of a helicopter rotor has both tip vortices and transonic flow structures in high-speed forward flight.

[0003] The numerical simulation of multi-scale turbulent eddy structures places high demands on the accuracy and spectral characteristics of the numerical format, while the numerical simulation of discontinuous structures such as shock waves requires that the numerical format must have moderate numerical dissipation and be able to capture discontinuities stably. The high-order WENO format achieves the purpose of simulating smooth turbulent structures and discontinuities simultaneously without numerical oscillation through sub-template weighting. Currently, the most widely used WENO format in engineering is the fifth-order WENO format. With the improvement of the format accuracy, the computational cost will also rise sharply. At present, the seventh-order WENO format is already the acceptable limit in engineering applications. Nowadays, there have been a lot of improvement studies on the fifth-order WENO format, but there are fewer improvement studies on the seventh-order WENO format. In addition, most of the existing seventh-order WENO formats use upwind polynomial reconstruction. This polynomial reconstruction has too large numerical dissipation in the smooth flow area, which seriously affects the numerical simulation effect of multi-scale structures. Summary of the invention

[0004] The present invention provides a construction method and an application method of a seventh-order WENO format, which are used to solve the problem that most existing seventh-order WENO formats use upwind polynomial reconstruction, and the numerical dissipation of this polynomial reconstruction is too large in the smooth flow area, which seriously affects the numerical simulation effect of the multi-scale structure. The reconstruction process can be optimized and the numerical dissipation and resolution of the format can be improved.

[0005] The present invention provides a method for constructing a seventh-order WENO format, comprising:

[0006] Perform non-polynomial reconstruction on four pre-defined sub-templates;

[0007] Perform error analysis to determine the non-polynomial reconstruction error, determine the higher-order function of the flux function through the unit flux, and determine the expression of the free parameters, which are used to eliminate the non-polynomial reconstruction error;

[0008] Based on the flux derivative of the sub-template, a smoothness factor is constructed, and based on the smoothness factor, a seventh-order WENO format is constructed.

[0009] According to the construction method of the seventh-order WENO format provided by the present invention, error analysis is performed to determine the non-polynomial reconstruction error, the higher-order function of the flux function is determined by the unit flux, and the expression of the free parameter is determined, including:

[0010] Perform error analysis on the results of non-polynomial reconstruction to determine the fourth-order error term;

[0011] Based on the fourth-order error term, a free parameter expression that can eliminate the fourth-order error term is derived. The free parameter expression includes the fourth-order derivative and the second-order derivative of the flux function.

[0012] A five-element template is established, and the fourth-order derivative and the second-order derivative are expressed based on the five-element template to obtain the expression of the free parameter.

[0013] According to the construction method of the seventh-order WENO format provided by the present invention, a five-unit template is established, and the fourth-order derivative and the second-order derivative are expressed based on the five-unit template to obtain the expression of the free parameter, and then the following is included:

[0014] Split the five-unit template into three three-unit templates;

[0015] Determine the smoothness of each three-unit template;

[0016] Based on the smoothness of the three three-unit templates, the expressions of the free parameters are optimized.

[0017] According to the construction method of the seventh-order WENO format provided by the present invention, the seventh-order WENO format is constructed based on the smoothness metric factor, including:

[0018] Substitute the smoothness measurement factor into the four predefined sub-templates to determine whether the sub-template is smooth;

[0019] Constructing weighted coefficients of sub-templates, wherein a smooth sub-template constructs a linear weighted coefficient, and a non-smooth sub-template constructs a non-linear weighted coefficient;

[0020] Based on the weighting coefficients of the sub-templates, the sub-templates are weighted to obtain a seventh-order WENO format.

[0021] According to the construction method of the seventh-order WENO format provided by the present invention, non-polynomial reconstruction is performed on four predefined sub-templates, including:

[0022] Based on the radial basis function interpolation method of Gaussian basis function, non-polynomial reconstruction is performed on the four pre-defined sub-templates.

[0023] According to the construction method of the seventh-order WENO format provided by the present invention, the smoothness of each ternary model is judged, including:

[0024] For each three-unit template, construct a quadratic function and determine the extreme points of the quadratic function;

[0025] If the extreme point of the quadratic function is within the three-unit template, the three-unit template is determined to be smooth.

[0026] According to the construction method of the seventh-order WENO format provided by the present invention, the expression of the free parameter is optimized based on the smoothness of the three three-unit templates, including:

[0027] The smoothness of the five-element template is determined based on the following formula (1):

[0028] C=C1*C2*C3 (1)

[0029] Where C represents the smoothness of the five-unit template, and C1, C2, and C3 represent the smoothness of the three three-unit templates, respectively.

[0030] According to the construction method of the seventh-order WENO format provided by the present invention, the sub-templates are weighted based on the weighting coefficients of the sub-templates to obtain the seventh-order WENO format, including:

[0031] The numerical fluxes of the four sub-templates are weighted to obtain the global numerical flux of the seventh-order WENO format;

[0032] Based on the global numerical flux, the seventh-order WENO format is determined.

[0033] The present invention also provides a method for numerically discretizing a hyperbolic conservation law equation, comprising:

[0034] Determine the computational domain of the hyperbolic conservation law equations, discretize the computational domain through meshing, and generate a computational network that satisfies the geometric boundaries;

[0035] Assign initial values ​​to the computational domain;

[0036] The computational domain is time discretized using the Runge-Kutta method;

[0037] The seventh-order WENO format is used for iterative advancement until the termination time is reached. The seventh-order WENO format is constructed using any of the above-mentioned seventh-order WENO format construction methods. The termination time is set according to the calculation requirements.

[0038] The present invention also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, any of the above-mentioned construction methods of the seventh-order WENO format is implemented.

[0039] The present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the method for constructing any of the above-mentioned seventh-order WENO formats is implemented.

[0040] The present invention also provides a computer program product, comprising a computer program, which implements any of the above-mentioned construction methods of the seventh-order WENO format when executed by a processor.

[0041] The scheme of the present application provides a method for constructing a seventh-order WENO format, in which new degrees of freedom are introduced in the process of non-polynomial reconstruction of sub-templates, thereby optimizing the reconstruction process, improving the numerical dissipation and resolution of the format, and simultaneously developing a free parameter adaptive optimization technology, and realizing the adaptive optimization of the free parameters by constructing high-order derivatives through local variables, thereby improving the reconstruction accuracy on the sub-template. Compared with the traditional seventh-order WENO-Z7 format, the scheme of the present application improves the reconstruction accuracy on the sub-template and reduces the numerical dissipation in the smooth area, while maintaining the high resolution and non-oscillation characteristics near the discontinuity. BRIEF DESCRIPTION OF THE DRAWINGS

[0042] In order to more clearly illustrate the technical solutions in the present invention or the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0043] Figure 1 This is one of the flow charts of the construction method of the seventh-order WENO format provided in an embodiment of the present invention;

[0044] Figure 2 This is the second flow chart of the construction method of the seventh-order WENO format provided in the embodiment of the present invention;

[0045] Figure 3 is a schematic diagram of a sub-template provided in an embodiment of the present invention;

[0046] Figure 4 It is a flow chart of a method for numerically discretizing a hyperbolic conservation law equation provided by an embodiment of the present invention;

[0047] Figure 5 Schematic diagram of the real part of the numerically corrected wave number provided in an embodiment of the present invention;

[0048] Figure 6 Schematic diagram of the imaginary part of the numerical correction wave number provided by an embodiment of the present invention;

[0049] Figure 7Schematic diagram of calculated density distribution of a Sod shock tube provided by an embodiment of the present invention;

[0050] Figure 8 is a schematic diagram of the calculated density distribution of a Lax shock tube provided in an embodiment of the present invention;

[0051] Fig. 9 It is a schematic diagram of the calculation density distribution of the Shur-Osher problem 1 provided in an embodiment of the present invention;

[0052] Fig.10 It is a schematic diagram of the calculation density distribution of the Shur-Osher problem 2 provided by an embodiment of the present invention;

[0053] Fig.11 It is a schematic diagram of the calculated density distribution of the explosion wave problem provided by an embodiment of the present invention;

[0054] Fig.12 This is one of the density gradient cloud diagrams of the double Mach reflection problem provided by an embodiment of the present invention;

[0055] Fig.13 This is the second schematic diagram of the density gradient cloud diagram of the double Mach reflection problem provided by the embodiment of the present invention;

[0056] Fig.14 This is one of the density cloud diagrams of the two-dimensional Riemann problem provided by an embodiment of the present invention;

[0057] Fig.15 This is one of the density cloud diagrams of the two-dimensional Riemann problem provided by an embodiment of the present invention;

[0058] Fig.16 It is a schematic diagram of the structure of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0059] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be clearly and completely described below in conjunction with the drawings of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0060] The seventh-order WENO format is the full name of the seventh-order weighted essential non-oscillatory (WENO) format, which is a calculation format widely used in fluid mechanics.

[0061] The WENO format can achieve high-order accuracy in smooth flow areas and can robustly capture shock waves in discontinuous areas, thus gaining wide attention in the numerical solution of partial differential equations and computational fluid dynamics application research. The characteristics of template weighting make the WENO format only close to the ideal weight in smooth areas, which will introduce relatively obvious numerical dissipation. In the prior art, there are a lot of improvements to the fifth-order WENO format, the main purpose of which is to reduce the numerical dissipation of the format and improve the numerical resolution of the format. There are fewer studies on the improvement of the seventh-order WENO format, such as WENO-BS7, WENO-Z7, WENO-S7, etc. These seventh-order WENO formats all use upwind polynomial reconstruction. This polynomial reconstruction has too large numerical dissipation in the smooth flow area, which seriously affects the numerical simulation effect of multi-scale structures.

[0062] In response to the problem of excessive numerical dissipation in the current seventh-order WENO format polynomial reconstruction process, the solution of the present application provides a new construction method of the seventh-order WENO format, which uses non-polynomial reconstruction technology to introduce new degrees of freedom into the reconstruction process, thereby optimizing the reconstruction process and improving the numerical dissipation and resolution of the format.

[0063] Figure 1 This is one of the flow charts of the construction method of the seventh-order WENO format provided in an embodiment of the present invention.

[0064] Figure 2 This is the second flow chart of the construction method of the seventh-order WENO format provided in the embodiment of the present invention.

[0065] like Figure 1 and Figure 2 As shown, this embodiment provides a construction method of a seventh-order WENO format, including:

[0066] Step 101, performing non-polynomial reconstruction on four predefined sub-templates;

[0067] Step 102, performing error analysis to determine a non-polynomial reconstruction error, determining a higher-order function of the flux function through unit flux, and determining an expression of a free parameter, wherein the free parameter is used to eliminate the non-polynomial reconstruction error;

[0068] Step 103, constructing a smoothness metric factor based on the flux derivative of the sub-template, and constructing a seventh-order WENO format based on the smoothness metric factor.

[0069] Figure 3 It is a schematic diagram of a sub-template provided in an embodiment of the present invention.

[0070] In practical applications, such as Figure 3 As shown, the four predefined sub-templates can be respectively S1={Ii-3 ,I i-2 ,I i-1 ,I i},S2={I i-2 ,I i-1 ,I i ,I i+1},S3={I i-1 ,I i ,I i+1 ,I i+2},S4={I i ,I i+1 ,I i+2 ,I i+3}.

[0071] In practice, the purpose of step 102 is to optimize free parameters, which is a unique step of the present invention. The traditional WENO-BS7, WENO-Z7, and WENO-S7 formats do not have additional degrees of freedom for optimization during the reconstruction process.

[0072] In step 103, corresponding smoothness measurement factors are constructed for the four sub-templates. The smaller the value of the factor, the smoother the sub-template is, and the larger the value, the more likely the sub-template is to have discontinuities.

[0073] In the present embodiment, a construction method of a seventh-order WENO format is provided, in which a new degree of freedom is introduced in the process of non-polynomial reconstruction of a sub-template, thereby optimizing the reconstruction process, improving the numerical dissipation and resolution of the format, and developing a free parameter adaptive optimization technology at the same time, and constructing high-order derivatives through local variables to achieve adaptive optimization of the free parameters, thereby improving the reconstruction accuracy on the sub-template. Compared with the traditional seventh-order WENO-Z7 format, the scheme of the present application improves the reconstruction accuracy on the sub-template and reduces the numerical dissipation in the smooth area, while maintaining high resolution and non-oscillation characteristics near the discontinuity.

[0074] In an exemplary embodiment, non-polynomial reconstruction is performed on four predefined sub-templates, including:

[0075] Based on the radial basis function interpolation method of Gaussian basis function, non-polynomial reconstruction is performed on the four pre-defined sub-templates.

[0076] In practical applications, the radial basis function interpolation method based on Gaussian basis function is used to perform non-polynomial reconstruction on the four pre-defined sub-templates. After simplifying the results, the reconstruction expression shown in the following formula (2) can be obtained:

[0077]

[0078] Among them, fi represents the flux on the ith grid cell, Represent the numerical flux on the four sub-templates, θ represents the free parameter introduced by the non-polynomial reconstruction, and Δx is the grid scale. The reconstruction coefficient consists of a constant and a second-order small quantity containing free parameters. When θ = 0, the above reconstruction degenerates into the traditional WENO-Z7 polynomial reconstruction. The reconstruction accuracy and spectral characteristics can be changed by perturbing θ.

[0079] In an exemplary embodiment, an error analysis is performed to determine a non-polynomial reconstruction error, a higher-order function of a flux function is determined by a unit flux, and an expression for a free parameter is determined, including:

[0080] Perform error analysis on the results of non-polynomial reconstruction to determine the fourth-order error term;

[0081] Based on the fourth-order error term, a free parameter expression that can eliminate the fourth-order error term is derived. The free parameter expression includes the fourth-order derivative and the second-order derivative of the flux function.

[0082] A five-element template is established, and the fourth-order derivative and the second-order derivative are expressed based on the five-element template, thereby obtaining the expression of the free parameter.

[0083] In practice, after performing error analysis on the result of the non-polynomial reconstruction obtained in step 101, it can be found that the non-polynomial reconstruction errors on the four sub-templates are as shown in the following formula (3):

[0084]

[0085] Where v represents the flux function, v (n) Represents higher-order derivatives of the flux function.

[0086] It is not difficult to see from the above formula (3) that when θ = 0, the non-polynomial reconstruction errors on the four sub-templates are all Ο(Δx 4 ), that is to say, the existence of θ makes it possible to eliminate the fourth-order error term. The free parameter that can eliminate the fourth-order error term is the optimized free parameter. If θ satisfies the following formula (4), the fourth-order error term of all sub-template reconstructions will disappear, thus achieving the fifth-order reconstruction on the sub-template:

[0087]

[0088] In practical applications, the higher-order derivatives of the flux function can be approximated by the unit flux, and the expression of the free parameters can be obtained. In addition, since the expression of θ contains the fourth-order derivative of the flux function, its approximate expression needs to be based on at least a five-unit template, which can be expressed as {I i-2 ,I i-1 ,I i,I i+1 ,I i+2}, so v″ and v (4) It can be approximately expressed as the following formula (5):

[0089]

[0090] Based on this, the expression for optimizing the free parameter θ can be expressed as the following formula (6):

[0091]

[0092] Through the above derivation process, the expression of the optimized free parameter θ is calculated. If θ is substituted back into the non-polynomial reconstruction in step 101 and the error analysis is performed again, it can be found that the non-polynomial reconstruction errors on the four sub-templates have reached the fifth order, that is, the fourth-order error term is eliminated. The non-polynomial error after substitution is shown in the following formula (7):

[0093]

[0094] In an exemplary embodiment, a five-unit template is established, and the fourth-order derivative and the second-order derivative are expressed based on the five-unit template to obtain an expression of the free parameter, and then the following is further included:

[0095] Split the five-unit template into three three-unit templates;

[0096] Determine the smoothness of each three-unit template;

[0097] Based on the smoothness of the three three-unit templates, the expressions of the free parameters are optimized.

[0098] In practice, the above steps in this embodiment are intended to perform smooth measurement on the expression of the free parameters. This step is also a unique step of the solution of the present application, which can ensure that the free parameter optimization process does not affect normal discontinuous capture.

[0099] In practical applications, the optimization of free parameters must be performed on a smooth five-element template. If there are discontinuities, the optimized values ​​of the free parameters are invalid. If they are not handled, the calculation will be unstable. i-2 ,I i-1 ,I i ,I i+1 ,I i+2} as an example, the solution of this embodiment also proposes a method for detecting the smoothness of a five-unit template. First, the five-unit template is divided into three overlapping three-unit templates, for example, {I i-2 ,I i-1 ,I i},{I i-1 ,Ii ,I i+1},{I i ,I i+1 ,I i+2}, then the smoothness of the template can be determined by the monotonicity of the flux function on each three-unit template. If all three three-unit templates are smooth, then the five-unit template is also smooth.

[0100] In an exemplary embodiment, the smoothness of each three-unit template is judged, including:

[0101] For each three-unit template, construct a quadratic function and determine the extreme points of the quadratic function;

[0102] If the extreme point of the quadratic function is within the three-unit template, the three-unit template is determined to be smooth.

[0103] In practical applications, when determining the smoothness of the three-unit template, we can first construct a quadratic function on the three-unit template to determine the position of the extreme point, as shown in the following formula (8):

[0104]

[0105] If 0<x c <3Δx, it can be determined that the extreme point is within the three-unit template, and then the three-unit template can be considered to be smooth. The same method is used to judge the smoothness of the three three-unit templates.

[0106] In an exemplary embodiment, based on the smoothness of the three three-unit templates, the expression of the free parameter is optimized, including:

[0107] The smoothness of the five-element template is determined based on the following formula (1):

[0108] C=C1*C2*C3 (1)

[0109] Where C represents the smoothness of the five-unit template, C1, C2 and C3 represent the smoothness of the three three-unit templates respectively, and when the three-unit template is smooth, the values ​​of C1, C2 and / or C3 are 1, and when the three-unit template is not smooth, the values ​​of C1, C2 and / or C3 are 0.

[0110] In practice, based on the above formula (1), it is not difficult to determine that when the three three-unit templates are smooth, the five-unit template is also smooth. If only one of the three three-unit templates is not smooth, then the five-unit template is not smooth.

[0111] Based on this, the expression for optimizing the free parameter θ can be further expressed by the following formula (9):

[0112]

[0113] Where C is the five-unit template {I i-2 ,I i-1 ,I i ,I i+1 ,I i+2}, δ=10 -10 Avoid denominators of zero.

[0114] In an exemplary embodiment, a seventh-order WENO format is constructed based on a smoothness metric factor, including:

[0115] Substitute the smoothness measurement factor into the four predefined sub-templates to determine whether the sub-template is smooth;

[0116] Constructing weighted coefficients of sub-templates, wherein a smooth sub-template constructs a linear weighted coefficient, and a non-smooth sub-template constructs a non-linear weighted coefficient;

[0117] Based on the weighting coefficients of the sub-templates, the sub-templates are weighted to obtain a seventh-order WENO format.

[0118] In practical applications, the smoothness factor constructed by the four sub-templates is shown in the following formula (10):

[0119]

[0120] After determining the smoothness of the sub-template based on the smoothness measurement factor, in order to obtain the global format of the seventh-order WENO format, the reconstruction on the sub-template needs to be weighted. Therefore, it is necessary to construct the weighting coefficient of each sub-template. For smooth sub-templates, linear weighting can be directly used, for example, d0=1 / 35, d1=12 / 35, d2=18 / 35, d3=4 / 35.

[0121] For sub-templates containing discontinuous solutions, nonlinear weighting needs to be constructed, as shown in the following formula (11):

[0122]

[0123] Among them τ7=|β0-β3|, q=2, ε=1×10 -20 .

[0124] In an exemplary embodiment, the sub-templates are weighted based on the weighting coefficients of the sub-templates to obtain a seventh-order WENO format, including:

[0125] The numerical fluxes of the four sub-templates are weighted to obtain the global numerical flux of the seventh-order WENO format;

[0126] Based on the global numerical flux, the seventh-order WENO format is determined.

[0127] Specifically, the global numerical flux of the seventh-order WENO format can be determined by the following formula (12):

[0128]

[0129] The present application also provides a construction system of a seventh-order WENO format. The construction system of the seventh-order WENO format provided by the present invention is described below. The construction system of the seventh-order WENO format described below and the construction method of the seventh-order WENO format described above can refer to each other.

[0130] The construction method of the seventh-order WENO format provided by the present invention includes:

[0131] A reconstruction module, used for performing non-polynomial reconstruction on four pre-defined sub-templates;

[0132] An error analysis module is used to perform error analysis, determine non-polynomial reconstruction errors, determine higher-order functions of flux functions through unit fluxes, and determine expressions of free parameters;

[0133] A construction module is used to construct a smoothness factor based on the flux derivative of the sub-template, and to construct a seventh-order WENO format based on the smoothness factor.

[0134] In an exemplary embodiment, the error analysis module is specifically used to:

[0135] Perform error analysis on the results of non-polynomial reconstruction to determine the fourth-order error term;

[0136] Based on the fourth-order error term, a free parameter expression is derived to eliminate the fourth-order error term. The expression includes the fourth-order derivative and the second-order derivative of the flux function.

[0137] A five-element template is established, and the fourth-order derivative and the second-order derivative are expressed based on the five-element template to obtain the expression of the free parameter.

[0138] In an exemplary embodiment, the error analysis module is further configured to:

[0139] Split the five-unit template into three three-unit templates;

[0140] Determine the smoothness of each three-unit template;

[0141] Based on the smoothness of the three three-unit templates, the expressions of the free parameters are optimized.

[0142] In an exemplary embodiment, the construction module is specifically used to:

[0143] Substitute the smoothness measurement factor into the four predefined sub-templates to determine whether the sub-template is smooth;

[0144] Constructing weighted coefficients of sub-templates, wherein a smooth sub-template constructs a linear weighted coefficient, and a non-smooth sub-template constructs a non-linear weighted coefficient;

[0145] Based on the weighting coefficients of the sub-templates, the sub-templates are weighted to obtain a seventh-order WENO format.

[0146] In the exemplary embodiment, the reconstruction module is specifically used for:

[0147] Based on the radial basis function interpolation method of Gaussian basis function, non-polynomial reconstruction is performed on the four pre-defined sub-templates.

[0148] In an exemplary embodiment, the error determination module is further used for:

[0149] For each three-unit template, construct a quadratic function and determine the extreme points of the quadratic function;

[0150] If the extreme point of the quadratic function is within the three-unit template, the three-unit template is determined to be smooth.

[0151] In an exemplary embodiment, the error determination module is further used for:

[0152] The smoothness of the five-element template is determined based on the following formula:

[0153] C=C1*C2*C3

[0154] Where C represents the smoothness of the five-unit template, and C1, C2, and C3 represent the smoothness of the three three-unit templates, respectively.

[0155] In an exemplary embodiment, the construction module is also used to:

[0156] The numerical fluxes of the four sub-templates are weighted to obtain the global numerical flux of the seventh-order WENO format;

[0157] Based on the global numerical flux, the seventh-order WENO format is determined.

[0158] The specific implementation method of the construction system of the seventh-order WENO format provided in this embodiment can be implemented with reference to the above embodiment, and will not be repeated here.

[0159] Figure 4 It is a flow chart of a method for numerically discretizing a hyperbolic conservation law equation provided by an embodiment of the present invention.

[0160] like Figure 4 As shown, an embodiment of the present invention further provides a method for numerically discretizing a hyperbolic conservation law equation, comprising:

[0161] Step 401, determining the computational domain of the hyperbolic conservation law equation, and discretizing the computational domain by meshing to generate a computational network that satisfies the geometric boundary;

[0162] Step 402, assigning initial values ​​to the computational domain;

[0163] Step 403, using the Runge-Kutta method to time discretize the computational domain;

[0164] Step 404, iteratively advancing using the seventh-order WENO format until reaching a termination time, the seventh-order WENO format being constructed using the construction method of the seventh-order WENO format of any of the above embodiments, and the termination time being set according to calculation requirements.

[0165] In practical applications, in step 402, for the one-dimensional hyperbolic conservation law equation, the initial value is a single variable, and for the Euler equations, the initial values ​​are density, velocity and pressure.

[0166] In step 403, the third-order to fourth-order Runge-Kutta method is used for time discretization, and a time step that satisfies the CFL condition is set.

[0167] In step 404, the iteration is performed in the time direction until the end time is reached. The numerical flux and flux derivatives at all grid points are calculated at each time step.

[0168] The present invention also provides two methods for testing the obtained seventh-order WENO format, including performing a precision numerical test and performing a spectral characteristic test, which specifically include the following steps:

[0169] In the process of numerical accuracy testing, the equation u t +f(u) x =0 Consider the following initial condition u(x,0)=sin n (πx), x∈[-1,1], n=1,2,3, and use periodic boundary conditions to solve the problem until t=2.

[0170] At the same time, the scheme of the present application and the traditional WENO format are tested. The L2 errors under different initial conditions are given in Tables 1 to 3 below, where the WENO-AO7 format is the scheme of the present application and the WENO-Z7 is the scheme of the prior art. It can be seen that the WENO-AO7 format achieves the designed fifth-order accuracy on the sub-template, which is one order higher than the accuracy of the traditional WENO-Z7 format on the sub-template. On the global template, the WENO-AO7 format and the traditional WENO-Z7 format maintain the same seventh-order accuracy, but the calculation error of the WENO-AO7 format is also significantly smaller than that of the traditional WENO-Z7 format.

[0171] Table 1 L2 error and convergence order calculated in different formats (u0(x)=sin(πx))

[0172]

[0173]

[0174] Table 2 L2 error and convergence order calculated in different formats (u0(x)=sin2(πx))

[0175]

[0176] Table 3 L2 error and convergence order calculated in different formats (u0(x)=sin3(πx))

[0177]

[0178]

[0179] When testing the spectral characteristics, the dispersion and dissipation of the WENO-K7 format can be analyzed by solving the linear wave equation and the periodic solution of the discrete Fourier transform. Figure 5 and Figure 6 The modified wavenumbers of WENO-AO7 format and WENO-Z7 format are compared. The black solid line represents the modified wavenumber without dissipation and dispersion. Figure 5 and Figure 6 It can be determined that in the medium and high wave number regions, the dissipation of the WENO-AO7 format is significantly lower than that of the WENO-Z7 scheme. In addition, the dispersion characteristics of the WENO-AO7 format are superior to those of the WENO-Z7 format.

[0180] Applying the solution of this application, the constructed seventh-order WENO format can solve many specific problems, such as:

[0181] (1) First, there are two one-dimensional shock tube problems: Sod shock tube and Lax shock tube. The initial conditions are:

[0182]

[0183]

[0184] The calculation time was advanced to t=0.14 and t=1.4 respectively, zero gradient boundary conditions were adopted at both ends of the calculation domain, and the number of grid cells was 200. Figure 7 and Figure 8 The density distributions of two shock tube problems calculated by WENO-Z7 format and WENO-AO7 format are given respectively. It can be seen that WENO-AO7 format can significantly improve the shock wave resolution while maintaining no oscillation.

[0185] (2) Shu-Osher Problem 1 shows the interaction between a shock wave with a Mach number of 3 and a fluctuating density sinusoidal wave, and requires a high resolution in the numerical format. Its initial conditions are:

[0186]

[0187] The solution is advanced to t = 1.8, using zero gradient boundary conditions.

[0188] Shu-Osher problem 2 will evolve into a large number of high-frequency oscillations with short waves. Its initial conditions are

[0189]

[0190] The solution is advanced to t=4, using zero gradient boundary conditions.

[0191] Fig. 9 It is a schematic diagram of the calculation density distribution of the Shur-Osher problem 1 provided in an embodiment of the present invention.

[0192] Fig.10 It is a schematic diagram of the calculation density distribution of the Shur-Osher problem 2 provided in an embodiment of the present invention.

[0193] like Fig. 9 and Fig.10 As shown, Fig. 9 The density distribution of the Shu-Osher problem 1 solved by both formats at 150 and 200 grid cells is shown. The WENO-AO7 format captures all high frequency oscillations at 150 grid cells, while the WENO-Z7 performs poorly in this regard. At 200 grid cells, the WENO-AO7 format resolves the oscillations better, with the peak values ​​more accurately aligning with the reference values. Fig.10 The density distribution of Shu-Osher problem 2 solved by two formats on 1000 grid cells is shown. The oscillation peak value solved by WENO-AO7 format is closer to the reference value. Therefore, compared with WENO-Z7 format, WENO-AO7 format performs better in the resolution of high-frequency and short-wave interference.

[0194] (3) Explosion wave problem

[0195] This is a problem of interaction of blast waves. This problem involves a transonic expansion zone, and the flow evolution process is very complicated. The initial conditions are as follows

[0196]

[0197] The calculation time is advanced to \(t = 0.038\), and reflective boundary conditions are adopted at both ends of the computational domain. The computational domain is divided into 1000 grid cells. At the peaks and troughs of the solution, as Fig. 9 shown, the results of the WENO-AO7 format are closer to the reference solution and are significantly better than those of the WENO-Z7 format.

[0198] (4) Double Mach reflection problem

[0199] The double Mach reflection problem describes a right-running normal shock wave with \(Ma = 10\) propagating at an incident angle of \(60^{\circ}\) within the computational domain \([0,4]\times[0,1]\). The initial conditions are as follows:

[0200]

[0201] The solution is advanced to \(t = 0.2\). The lower boundary of the computational domain \(0\lt x\lt\frac{1}{6}\) is set to the post-shock parameters, \(\frac{1}{6}\lt x\lt4\) is set to a non-viscous solid wall, the left boundary is set to the post-shock parameters, the right boundary is the outlet condition, the left side of the shock on the upper boundary is set to the post-shock parameters, and the right side of the shock is the pre-shock condition. The calculation is carried out using a grid scale of \(\frac{1}{500}\).

[0202] Fig.12 is one of the schematic diagrams of the density gradient cloud map of the double Mach reflection problem provided by the embodiment of the present invention.

[0203] Fig.13 is the second schematic diagram of the density gradient cloud map of the double Mach reflection problem provided by the embodiment of the present invention.

[0204] As Fig.12 and Fig.13 shown, Fig.12 is the density gradient cloud map obtained by applying the WENO-Z7 format, Fig.13 is the density gradient cloud map obtained by applying the WENO-OA7 format. As Fig.12 and Fig.13 shown, the shock thickness calculated by the WENO-OA7 format is smaller, and at the same time, the capture of the vortex structure rolled up at the intersection of multiple shock waves is also more refined, demonstrating the high-resolution and low-dissipation characteristics of the WENO-OA7 format.

[0205] (5) Two-dimensional Riemann problem

[0206] This problem involves regions with different densities, pressures, and velocities, resulting in diverse evolutions of shock waves, expansion fans, and contact discontinuities. The presence of Kelvin-Helmholtz instability leads to the development of complex vortex structures at the interfaces between different regions, which is another important feature of this problem. These vortex structures are very sensitive to the dissipation of numerical methods. On the computational domain \([0,2]\times[0,2]\), the initial conditions are as follows:

[0207]

[0208] The solution is advanced to t = 1.6, and the computational domain is divided into 200 elements in both the x and y directions.

[0209] Fig.14 It is one of the density cloud diagrams of the two-dimensional Riemann problem provided by an embodiment of the present invention.

[0210] Fig.15 It is one of the density cloud diagrams of the two-dimensional Riemann problem provided by an embodiment of the present invention.

[0211] like Fig.14 and Fig.15 As shown, Fig.14 This is the density cloud map obtained using the WENO-Z7 format. Fig.15 This is the density cloud map obtained by using the WENO-OA7 format, such as Fig.14 and Fig.15 It can be seen that the WENO-OA7 format can solve the vortex structure caused by KH instability more obviously and finely on the contact surface, which further proves that the WENO-OA7 format has lower numerical dissipation and higher numerical resolution than the WENO-Z7 format.

[0212] Fig.16 An example of a physical structure diagram of an electronic device is shown in FIG. Fig.16 As shown, the electronic device may include: a processor 1610, a communication interface 1620, a memory 1630 and a communication bus 1640, wherein the processor 1610, the communication interface 1620 and the memory 1630 communicate with each other through the communication bus 1640. The processor 1610 may call the logic instructions in the memory 1630 to execute the construction method of the seventh-order WENO format, and the method includes:

[0213] Perform non-polynomial reconstruction on four pre-defined sub-templates;

[0214] Perform error analysis to determine the non-polynomial reconstruction error, determine the higher-order function of the flux function through the unit flux, and determine the expression of the free parameters, which are used to eliminate the non-polynomial reconstruction error;

[0215] Based on the flux derivative of the sub-template, a smoothness factor is constructed, and based on the smoothness factor, a seventh-order WENO format is constructed.

[0216] In addition, the logic instructions in the above-mentioned memory 1630 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when it is sold or used as an independent product. Based on such an understanding, the technical solution of the present invention can be essentially or partly embodied in the form of a software product that contributes to the prior art. The computer software product is stored in a storage medium, including several instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods of various embodiments of the present invention. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.

[0217] On the other hand, the present invention further provides a computer program product, the computer program product includes a computer program, the computer program can be stored in a non-transitory computer-readable storage medium, when the computer program is executed by a processor, the computer can execute the construction method of the seventh-order WENO format provided by the above methods, the method includes:

[0218] Perform non-polynomial reconstruction on four pre-defined sub-templates;

[0219] Perform error analysis to determine the non-polynomial reconstruction error, determine the higher-order function of the flux function through the unit flux, and determine the expression of the free parameters, which are used to eliminate the non-polynomial reconstruction error;

[0220] Based on the flux derivative of the sub-template, a smoothness factor is constructed, and based on the smoothness factor, a seventh-order WENO format is constructed.

[0221] In another aspect, the present invention further provides a non-transitory computer-readable storage medium having a computer program stored thereon, which is implemented when the computer program is executed by a processor to execute the construction method of the seventh-order WENO format provided by the above methods, the method comprising:

[0222] Perform non-polynomial reconstruction on four pre-defined sub-templates;

[0223] Perform error analysis to determine the non-polynomial reconstruction error, determine the higher-order function of the flux function through the unit flux, and determine the expression of the free parameters, which are used to eliminate the non-polynomial reconstruction error;

[0224] Based on the flux derivative of the sub-template, a smoothness factor is constructed, and based on the smoothness factor, a seventh-order WENO format is constructed.

[0225] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, i.e., they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Those of ordinary skill in the art may understand and implement it without creative effort.

[0226] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A method for numerically discretizing a fluid containing a discontinuous structure in fluid mechanics, characterized in that: include: Determine a computational domain of the hyperbolic conservation law equation, and discretize the computational domain by meshing to generate a computational network that satisfies the geometric boundary, wherein the computational domain contains a discontinuous structure, and the discontinuous structure includes shock waves and regions with different densities, pressures, and velocities; Assigning an initial value to the computational domain; The third-order to fourth-order Runge-Kutta method is used for time discretization, and the time step that satisfies the CFL condition is set; The seventh-order WENO format is used to iterate in the time direction until the end time is reached. The numerical flux and flux derivatives at all grid points are calculated at each time step. The construction method of the seventh-order WENO format includes: Perform non-polynomial reconstruction on four pre-defined sub-templates; Performing error analysis to determine a non-polynomial reconstruction error, determining a higher-order function of a flux function through unit flux, and determining an expression of a free parameter, wherein the free parameter is used to eliminate the non-polynomial reconstruction error; Based on the flux derivative of the sub-template, a smoothness metric factor is constructed, and based on the smoothness metric factor, a seventh-order WENO format is constructed; The error analysis is performed to determine the non-polynomial reconstruction error, the higher-order function of the flux function is determined by the unit flux, and the expression of the free parameter is determined, including: Perform error analysis on the results of non-polynomial reconstruction to determine the fourth-order error term; Based on the fourth-order error term, deriving a free parameter expression that can eliminate the fourth-order error term, the free parameter expression including a fourth-order derivative and a second-order derivative of the flux function; Establishing a five-unit template, representing the fourth-order derivative and the second-order derivative based on the five-unit template, and obtaining an expression of the free parameter; After error analysis of the non-polynomial reconstruction results, the non-polynomial reconstruction errors on the four sub-templates are determined as shown in the following formula (1): (1) Where S0, S1, S2 and S3 represent four sub-templates, E0, E1, E2 and E3 represent the non-polynomial reconstruction errors on the four sub-templates, represents the flux function, represents the higher-order derivatives of the flux function, represents the free parameters introduced by the non-polynomial reconstruction, is the grid scale; The five-unit template is , and The formula is as follows (2): (2) Optimizing free parameters The expression can be expressed as the following formula (3): (3) in, represents the flux on the i-th grid cell; The step of establishing a five-unit template, expressing the fourth-order derivative and the second-order derivative based on the five-unit template, and obtaining an expression of the free parameter further includes: Splitting the five-unit template into three three-unit templates; Determining the smoothness of each of the three-unit templates; Based on the smoothness of the three three-unit templates, optimizing the expression of the free parameter; Methods for detecting smoothness include: First, divide the five-unit template into three overlapping three-unit templates. , , , then the monotonicity of the flux function on each three-unit template can be used to determine whether the template is smooth. If all three three-unit templates are smooth, then the five-unit template is smooth.

2. The method for numerically discretizing a fluid containing a discontinuous structure in fluid mechanics according to claim 1, characterized in that: The constructing of a seventh-order WENO format based on the smoothness metric factor comprises: Substituting the smoothness measurement factor into the four predefined sub-templates to determine whether the sub-templates are smooth; Constructing weighted coefficients of the sub-templates, wherein a smooth sub-template constructs a linear weighted coefficient, and a non-smooth sub-template constructs a non-linear weighted coefficient; The sub-templates are weighted based on the weighting coefficients of the sub-templates to obtain the seventh-order WENO format.

3. The method for numerically discretizing a fluid containing a discontinuous structure in fluid mechanics according to claim 1, characterized in that: The non-polynomial reconstruction of the four predefined sub-templates includes: The four predefined sub-templates are reconstructed in a non-polynomial manner based on a radial basis function interpolation method of a Gaussian basis function.

4. The method for numerically discretizing a fluid containing a discontinuous structure in fluid mechanics according to claim 1, characterized in that: The step of judging the smoothness of each of the three-unit templates includes: For each of the three-unit templates, construct a quadratic function and determine the extreme value points of the quadratic function; If the extreme point of the quadratic function is within the three-unit template, it is determined that the three-unit template is smooth.

5. The method for numerically discretizing a fluid containing a discontinuous structure in fluid mechanics according to claim 1, characterized in that: The expression of the free parameter is optimized based on the smoothness of the three three-unit templates, including: The smoothness of the five-unit template is determined based on the following formula (1): (1) Where C represents the smoothness of the five-unit template, , and Respectively represent the smoothness of the three three-unit templates.

6. The method for numerically discretizing a fluid containing a discontinuous structure in fluid mechanics according to claim 2, characterized in that: The weighting coefficient based on the sub-template is used to weight the sub-template to obtain the seventh-order WENO format, including: Weighting the numerical fluxes of the four sub-templates to obtain the global numerical flux of the seventh-order WENO format; Based on the global numerical flux, the seventh-order WENO format is determined.

7. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the program, the method for numerically discretizing a fluid containing a discontinuous structure in fluid mechanics as claimed in any one of claims 1 to 6 is implemented.