Reactor transport calculation methods, electronic equipment, and computer storage media
By combining parallel multi-process computation and the JFNK algorithm with the MPI/OpenMP hybrid parallel architecture, the contradiction between accuracy and speed in neutron transport computation is resolved, and efficient neutron transport computation is achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- SHANGHAI NUCLEAR ENGINEERING RESEARCH & DESIGN INSTITUTE CO LTD
- Filing Date
- 2025-11-18
- Publication Date
- 2026-06-30
AI Technical Summary
In neutron transport calculations, existing techniques struggle to improve solution speed while maintaining computational accuracy, especially when using whole-core rod-by-rod transport calculation methods, where computational accuracy and solution speed are at odds.
A parallel multi-process computing approach is adopted, combining the JFNK algorithm and the MPI/OpenMP hybrid parallel architecture. The reactor core is decomposed into multiple regions, and an accelerated algorithm is used to perform iterative calculations of neutron transport. The calculation process is optimized by using parallel processes and threads to share memory.
It significantly improves the iterative convergence speed and computation speed of neutron transport calculations while maintaining the accuracy of the calculation results, thus achieving an efficient solution process.
Smart Images

Figure CN121506277B_ABST
Abstract
Description
Technical Field
[0001] This application relates to a neutron transport calculation for a nuclear reactor core, specifically a reactor transport calculation method, electronic equipment, and computer storage medium. Background Technology
[0002] In nuclear reactor physics, neutron transport equations are crucial methods for simulating nuclear physics processes in the reactor core. Compared to other methods, the simulation accuracy of neutron transport equations based on deterministic theory depends more heavily on the modeling level and the size of the computational grid; more realistic models and finer grids yield more accurate results. Using whole-core rod-by-rod transport calculations can obtain accurate results at the fuel rod level; however, while this method provides high accuracy, it also reduces the solution speed. Therefore, balancing computational accuracy and solution speed is challenging when using this method for neutron transport calculations. Summary of the Invention
[0003] This application proposes a reactor transport calculation method, electronic equipment, and computer storage medium to solve the problem of decreasing solution speed while maintaining calculation accuracy in neutron transport calculations.
[0004] In a first aspect, this application provides a reactor transport calculation method, comprising the following steps: calling multiple parallel processes to calculate neutron transport response matrices for multiple regions in the reactor core, wherein each region includes several grids allocated to the associated processes, and each grid corresponds to a neutron transport response matrix; setting a set of basis vectors for accelerating the algorithm, wherein the basis vectors include the neutron flux of the grids contained in the multiple regions, a first incident flow at the outer boundary of the reactor core, a second incident flow in a first grid group in the grids, and core characteristic values, wherein the grids in the first grid group are not adjacent; calling the multiple processes to use the acceleration algorithm to perform iterative neutron transport calculations based on the neutron transport response matrices and the basis vectors to obtain target values for the neutron flux and core characteristic values.
[0005] In some embodiments, invoking multiple parallel processes to calculate the neutron transport response matrix of multiple regions in the reactor core includes: starting multiple parallel processes, and using each process to read the input information of the reactor core, the input information including geometric information; dividing the reactor core into multiple grids according to the geometric information; decomposing the reactor core into multiple regions according to the number of processes; and invoking the multiple processes to calculate the neutron transport response matrix of each grid according to their respective assigned grids.
[0006] In some embodiments, invoking multiple parallel processes to calculate the neutron transport response matrix of multiple regions in the reactor core includes: dividing the multiple grids into a first grid group and a second grid group, wherein the grids in the same grid group are not adjacent.
[0007] In some embodiments, the in-process threads share memory.
[0008] In some embodiments, invoking the plurality of processes to use the acceleration algorithm to perform neutron transport iterative calculation based on the neutron transport response matrix and the basis vector includes: invoking the plurality of processes to perform neutron transport calculation, obtaining the neutron flux of the grid, the incident flow of the grid, and the core eigenvalues, and saving them as a second current basis vector; calculating the L2 norm of a first function based on the second current basis vector and a first current basis vector not yet calculated; calculating the JFNK perturbation quantity of the current calculation based on the L2 norm of the first current basis vector; obtaining a Krylov basis based on the first function and the L2 norm of the first function, and performing a minimum residual method loop using the Krylov basis, forming a Krylov basis matrix from the various Krylov bases obtained during the minimum residual method loop, and obtaining the target Krylov basis when the minimum residual method loop exits; generating the next basis vector based on the first current basis vector, the Krylov basis matrix, and the target Krylov basis; and determining whether the L2 norm of the next basis vector converges, thereby deciding whether to end the iterative calculation.
[0009] In some embodiments, invoking the plurality of processes to perform neutron transport calculations to obtain the neutron flux of the grid, the incident flow of the grid, and the core characteristic values includes performing the following steps for each grid: a. Calculating the first outgoing flow of the grids in the target grid group at the boundary of the plurality of regions based on the neutron transport response matrix, wherein the target grid group is selected from one of the first grid group and the second grid group, and the grids in the same grid group are not adjacent; b. Encapsulating the first outgoing flow with inter-process communication data and sending it through non-blocking communication, while simultaneously starting non-blocking reception of communication data from other processes; c. Calculating the grids within the plurality of regions that belong to the target grid group. d. Calculate the incident flow of the grid belonging to the target grid group at the core boundary based on the outer boundary conditions of the core, the first and second outgoing flows; e. Update the neutron flux of the grid belonging to the target grid group in the multiple regions based on the neutron transport response matrix and the basis vector; f. Wait for the non-blocking communication to complete in each process and map the communication data to the incident flow of the grid at the boundary of multiple regions; g. Select the other of the first and second grid groups as the target grid group and iteratively execute step af; update the core eigenvalues based on the updated neutron flux.
[0010] In some embodiments, after obtaining the target values of the neutron flux and the core characteristic values, the method further includes: performing a polynomial projection approximation on the neutron flux to obtain a neutron flux expansion; performing flux distribution resolution enhancement calculation on the neutron flux expansion to obtain a fine neutron flux distribution; and performing power distribution resolution enhancement calculation on the fine neutron flux distribution to obtain a fine power distribution.
[0011] In some embodiments, the acceleration algorithm is the JFNK algorithm.
[0012] In a second aspect, this application provides an electronic device, comprising: a memory for storing instructions executable by a processor; and a processor for executing the instructions to implement the method as described in the first aspect.
[0013] Thirdly, this application provides a computer storage medium storing computer program code that, when executed by a processor, implements the method described in the first aspect.
[0014] Fourthly, this application provides a computer program product including computer program code, wherein when the computer program code is executed by one or more processors, the one or more processors implement the steps of the method described in the first aspect.
[0015] Compared with existing technologies, the method of this application significantly accelerates the convergence speed and computation speed of neutron transport calculation iteration by calling multiple parallel processes and incorporating an acceleration algorithm, while maintaining the accuracy of the calculation results. Attached Figure Description
[0016] The accompanying drawings are included to provide a further understanding of this application; they are incorporated into and constitute a part of this application. The drawings illustrate embodiments of this application and, together with this specification, serve to explain the principles of this application. In the drawings:
[0017] Figure 1 This is a schematic flowchart of a reactor transport calculation method provided in an embodiment of this application;
[0018] Figure 2 This is a flowchart illustrating a method for calculating the neutron transport response matrix of multiple regions in the core of a reactor, as provided in an embodiment of this application.
[0019] Figure 3 This is a schematic diagram of a grid-incident flow provided in an embodiment of this application;
[0020] Figure 4 This is a flowchart of an acceleration algorithm provided in an embodiment of this application;
[0021] Figure 5 This is a flowchart of a parallel process algorithm provided in an embodiment of this application;
[0022] Figure 6 This is a schematic diagram of an algorithm for launching multiple parallel processes using MPI, provided in an embodiment of this application.
[0023] Figure 7 This is a schematic diagram of a resolution enhancement method provided in an embodiment of this application;
[0024] Figure 8 This is a schematic diagram of the integration interval for a resolution enhancement method provided in an embodiment of this application;
[0025] Figure 9 This is a block diagram of an apparatus for a reactor transport calculation method provided in an embodiment of this application. Detailed Implementation
[0026] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are merely some examples or embodiments of this application. For those skilled in the art, these drawings can be applied to other similar scenarios without creative effort. Unless obvious from the context or otherwise specified, the same reference numerals in the drawings represent the same structures or operations.
[0027] As indicated in this application, unless the context clearly indicates otherwise, the words "a," "an," "an," and / or "the" do not specifically refer to the singular and may also include the plural. Generally speaking, the terms "comprising" and "including" only indicate the inclusion of explicitly identified steps and elements, which do not constitute an exclusive list, and the method or apparatus may also include other steps or elements.
[0028] Furthermore, this application uses specific terms to describe embodiments of the application. For example, "an embodiment," "one embodiment," and / or "some embodiments" refer to a particular feature, structure, or characteristic related to at least one embodiment of the application. Therefore, it should be emphasized and noted that "an embodiment," "one embodiment," or "an alternative embodiment" mentioned twice or more in different locations in this specification do not necessarily refer to the same embodiment. In addition, certain features, structures, or characteristics in one or more embodiments of the application can be appropriately combined.
[0029] Unless otherwise specifically stated, the relative arrangement, numerical expressions, and values of the components and steps described in these embodiments do not limit the scope of this application. It should also be understood that, for ease of description, the dimensions of the parts shown in the drawings are not drawn to actual scale. Techniques, methods, and devices known to those skilled in the art may not be discussed in detail, but where appropriate, such techniques, methods, and devices should be considered part of the specification. In all examples shown and discussed herein, any specific values should be interpreted as merely exemplary and not as limitations. Therefore, other examples of exemplary embodiments may have different values. It should be noted that similar reference numerals and letters in the following drawings denote similar items; therefore, once an item is defined in one drawing, it need not be further discussed in subsequent drawings.
[0030] Furthermore, although the terminology used in this application is selected from commonly known and used terms, some terms mentioned in this application's specification may have been chosen by the applicant according to his or her judgment, and their detailed meanings are explained in the relevant sections of the description herein. Moreover, this application is to be understood not only by the actual terms used, but also by the meaning implied by each term.
[0031] This application uses flowcharts to illustrate the operations performed by an apparatus or device according to embodiments of this application. It should be understood that the preceding or following operations are not necessarily performed precisely in sequence. Instead, various steps can be processed in reverse order or simultaneously. Furthermore, other operations may be added to these processes, or one or more steps may be removed from these processes.
[0032] See Figure 1 This application proposes a reactor transport calculation method, including the following steps:
[0033] Step S101: Call multiple parallel processes to calculate the neutron transport response matrix of multiple regions in the reactor core, where each region includes several grids allocated to the associated process, and each grid corresponds to a neutron transport response matrix.
[0034] In this step, the reactor core is divided into multiple regions, each containing several grids. Each process corresponds to one region, thus processing several grids within that region. Each process performs neutron transport response matrix calculations for each grid, obtaining the corresponding neutron transport response matrix.
[0035] As an feasible approach, refer to Figure 2 Step S101 may include the following steps:
[0036] In step S201, multiple parallel processes are started, and each process is used to read the input information of the core, including geometric information.
[0037] In this step, each process reads all the core input information obtained using the bar-by-bar method. In some embodiments, the core input information includes geometric information, material information, cross-sectional information, the number of shared parallel threads, computer control parameters, and iteration accuracy. Because each process reads the complete core parameters, this step ensures that all processes have a completely consistent understanding of the input parameters.
[0038] In step S202, the core is meshed according to the geometric information to obtain multiple meshes.
[0039] In this step, the reactor core is divided into multiple grids, which serve as the basic units for performing neutron transport response matrix calculations.
[0040] In step S203, the reactor core is decomposed into multiple regions based on the number of processes in the multiple processes.
[0041] In this step, the heap core is divided into regions according to the specified number of distributed parallel processes, so that the number of grids allocated to each process is nearly the same. This partitioning method helps to balance the load of each process and makes subsequent inter-process communication smoother.
[0042] In step 204, multiple processes are invoked to calculate the neutron transport response matrix of each grid according to their respective assigned grids.
[0043] In this step, multiple processes are activated, each containing multiple grids, and the neutron transport response matrix corresponding to the grid is calculated within each process.
[0044] As an feasible approach, invoking multiple parallel processes to calculate the neutron transport response matrix of multiple regions in the reactor core involves dividing multiple grids into a first grid group and a second grid group, wherein grids within the same grid group are not adjacent. See [link to relevant documentation]. Figure 3 The first grid group is red, and the second grid group is black. All directly adjacent red grids are black. This method ensures that adjacent grids do not belong to the same group. After grid classification, the location number of each grid is read. The location number can be... The specific calculation formula for classifying the grid is as follows:
[0045] (1)
[0046] If the result of the calculation is 1, then the grid belongs to the red grid group; if the result is -1, then the grid belongs to the black grid group.
[0047] As a feasible approach, the neutron transport response matrix can be obtained through the nodal expansion method, based on the material and cross-sectional properties: , , and The values of the above matrix are related to the material and cross-section.
[0048] Furthermore, the neutron transport response matrix is defined as follows:
[0049] (2)
[0050] (3)
[0051] Among them, the grid within the region is divided into red grid groups and black grid groups. If the incident flow is the red grid, then The outgoing stream is represented by the red grid. After being passed to the black grid of another adjacent region, it becomes the incident flow. Neutron flux For source terms.
[0052] Step S102: Set a set of basis vectors for accelerating the algorithm. The basis vectors include the neutron flux of the grid contained in multiple regions, the first incident flow at the outer boundary of the core, the second incident flow of the first grid group in the grid, and the core eigenvalues. The grids in the first grid group are not adjacent.
[0053] In this step, see Figure 3The internal grid 31 refers to the grid within the dashed area in the figure, i.e., the grid that does not intersect with the region boundary. The boundary grid 32 refers to the grid located on the region boundary, where at least one of its adjacent grids is located within the region managed by another process. The first incident flow refers to the incident flow located at the boundary grid 32, and the second incident flow refers to the incident flow of the internal grid 31.
[0054] As an feasible approach, the JFNK algorithm is used to accelerate the computation. This algorithm facilitates the rapid convergence of neutron transport calculations, thereby speeding up the computation.
[0055] As one feasible approach, each distributed parallel process is allocated a computing grid, and initial values for neutron flux and incident flow are set for each computing grid, along with process core eigenvalues. Initial values: Set the initial values for the JFNK acceleration parameters. (See also...) Figure 3 The initial parameter values are set based on the technical characteristics of parallel computation of the red and black grid groups in neutron transport calculations. The basis vectors of the JFNK algorithm are set as follows:
[0056] ( , , , (4)
[0057] in, For the incident flow of all red grids, The incident flow at the outer boundary of the reactor core. The neutron flux for the entire grid. These are the core eigenvalues. After the basis vectors of the JFNK algorithm are set, a new computation array is created in each distributed parallel process to store the current values of the basis vectors. Specifically, the initial values of the basis vectors are... It should be noted that the basis vectors are a set of iterative variables that accelerate the normal operation of JFNK. The selected basis vectors are the smallest basis vectors, and redundant iterative variables are discarded to reduce computational and memory overhead.
[0058] Step S103: Invoke multiple processes to use the acceleration algorithm to perform neutron transport iterative calculation based on the neutron transport response matrix and basis vectors to obtain the target values of neutron flux and core characteristic values.
[0059] As an feasible approach, refer to Figure 4 As shown, step S103 includes:
[0060] In step S401, multiple processes are invoked to perform neutron transport calculations, obtain the neutron flux of the grid, the incident flow of the grid, and the core characteristic values, and save them as the second current basis vector.
[0061] In this step, the neutron flux of the grid is obtained. Incident flow of the grid , and core eigenvalues , as the second current basis vector The exemplary calculation process will be referenced later. Figure 5 describe.
[0062] In step S402, the L2 norm of the first function is calculated based on the second current basis vector and the first current basis vector that has not been calculated in this instance.
[0063] In this step, the first function is The first current basis vector, not calculated in this instance, is The first function is calculated as follows:
[0064] (5)
[0065] The L2 norm of the first function is and the initial calculation Record .
[0066] In step S403, the JFNK perturbation quantity calculated in this calculation is based on the L2 norm of the first current basis vector.
[0067] In this step, the first basis vector The L2 norm is || Then calculate the JFNK perturbation for the current step:
[0068] (6)
[0069] in, This step ensures the machine precision required to run double-precision real numbers within the hardware. It guarantees that the perturbation is adapted to the magnitude of the numerical environment to maintain the stability and accuracy of the numerical differentiation process.
[0070] In step S404, a Krylov basis is obtained based on the first function and its L2 norm, and a minimum residual method loop (GMRES) is performed using the Krylov basis. The Krylov basis obtained during the minimum residual method loop is used to form a Krylov basis matrix, and the target Krylov basis is obtained when the minimum residual method loop exits.
[0071] In this step, the specific steps for constructing the Minimum Residual Recurrence (GMRES) and forming the Krylov basis matrix are as follows:
[0072] (a) Let the first Krylov basis vector =F( ) / ,in (m=1,2,…) is called the Krylov basis.
[0073] (b) Enter the Minimum Residual Method (GMRES) loop, with loop variable m, where m = 1, 2, ..., and construct the perturbation vector:
[0074] (7)
[0075] Then perform the calculation as in step S401 to obtain .
[0076] (c) Calculate the Jacobian matrix using the following formula. and The product of:
[0077] (8)
[0078] (d) For vectors The normalized new basis vectors are obtained by performing Schmitt orthogonalization on the first m Krylov bases. Then calculate the Hessenberg matrix elements.
[0079] (9)
[0080] (e) Solve using the least squares method:
[0081] (10)
[0082] The goal of step (e) is to find an optimal solution y in the current Krylov subspace. m This minimizes the residual. The result is obtained through calculation. and ,in We obtain the Hessenberg matrix H by adding one row of all zeros. Let m+1 dimensional vector have a first element of 1 and all other elements of 0. When the loop ends, the loop continues. For the target Krylov base, For the matrix spanned by all Krylov bases, .
[0083] In step S405, the next basis vector is generated based on the first current basis vector, the Krylov basis matrix, and the target Krylov basis.
[0084] In this step, the next basis vector is Wherein, the first current basis vector is , The target Krylov base when the GMRES loop exits. At this point, one JFNK acceleration iteration process was completed.
[0085] Step S406: Determine whether the L2 norm of the first function calculated based on the next basis vector has converged, and thus decide whether to end the iterative calculation.
[0086] In this step, the decision is made based on the convergence criterion to repeat steps S401 to S405 until convergence. The convergence criterion is as follows:
[0087] (11)
[0088] in It is based on the next basis vector Calculate the L2 norm of the first function. Take a smaller number, such as Or the number of iterations exceeds a specified value. If convergence is not achieved, increment the iteration count. Then proceed to step S401 to perform the next JFNK accelerated iteration calculation; if convergence is achieved, the calculation ends, and the final neutron flux and eigenvalues are output. .
[0089] As an feasible approach, refer to Figure 5 Steps 501 to 508 illustrate the iterative calculation process of neutron transport in each distributed parallel process. This process aims to obtain the neutron transport response matrix and the current basis vector x. It should be noted that steps 501 to 508 assume that the red grid is calculated first, followed by the black grid, and the iterative process uses the corresponding neutron transport response matrix. The specific steps are as follows:
[0090] In step 501, the first outflow of the target grid group at the boundary of multiple regions is calculated based on the neutron transport response matrix and the grid of the target grid group. The target grid group is selected from one of the first grid group and the second grid group, and the grids in the same grid group are not adjacent.
[0091] In this step, the target grid group is selected as the first grid group, namely the red grid group. The first outflow of the red grid at the boundary of the distributed parallel region is calculated according to formula (1). The incident flow comes from the black grid of the previous iteration step.
[0092] In step 502, the first outgoing stream is encapsulated with inter-process communication data and sent out in a non-blocking communication manner, while simultaneously non-blocking reception of communication data from other processes begins.
[0093] In this step, the first outgoing stream of the red grid obtained in step 501 is encapsulated as inter-process communication data and sent out through non-blocking communication. At the same time, non-blocking communication is enabled to receive communication data from other distributed parallel processes.
[0094] In step 503, the second outflow of the grid belonging to the target grid group within multiple regions is calculated and stored as the inflow of the adjacent grid.
[0095] In this step, the second outflow of the red grid inside the distributed parallel region is calculated according to formula (1), and according to the flow continuity condition, these calculated second outflows are directly stored as the incident flow of the adjacent black grid.
[0096] In step 504, the incident flow of the core edge belonging to the target grid group is calculated based on the outer boundary conditions of the core, the first outflow, and the second outflow.
[0097] In this step, based on the outer boundary conditions of the entire core, such as reflection boundaries and vacuum boundaries, the red grid incident flow at the core boundary is calculated using the outgoing flow updated in steps 501 and 503.
[0098] In step 505, the neutron flux of the grids belonging to the target grid group in multiple regions is updated based on the neutron transport response matrix and basis vectors.
[0099] In this step, neutron flux is applied to all red grids in the distributed parallel region according to formula (2). renew.
[0100] In step 506, each process waits for the non-blocking communication to complete and maps the communication data as an incident flow of the grid at the boundary of multiple regions.
[0101] In this step, each distributed parallel process waits for the non-blocking communication information transmission in step 502 to be completed, ensuring that the communication data between all processes has been synchronized. The received communication data, that is, the red grid outflow sent by the adjacent processes at the boundary, is mapped to the black grid inflow at the boundary of the distributed parallel process region.
[0102] In step 507, select the other of the first and second grid groups as the target grid group, and iteratively execute step af.
[0103] In this step, the second grid group is the black grid group. The second grid group is used as the target grid group. Then, steps 501 to 506 are repeated for another iteration calculation.
[0104] In step 508, the core characteristic values are updated based on the updated neutron flux.
[0105] Furthermore, neutron transport iterative calculations are performed within a distributed parallel process, and the order of red and black grid iterations is arbitrary; that is, in steps 501 to 508, the black grid can be calculated first, followed by the red grid.
[0106] As an feasible approach, enabling multiple processes in the above steps can be achieved using the MPI (Message Passing Interface) method. MPI is the industry standard for message passing interfaces in distributed memory environments, thus allowing parallel computing programs to be launched within an MPI environment. See also... Figure 6 ,like Figure 6 This is a schematic diagram of the algorithm part of the reactor transport calculation method of this application, which uses MPI to start multiple parallel processes. The process reads the same nuclear reactor input parameters for each MPI process. When calculating the neutron transport response matrix, the non-blocking communication method in the MPI method is used for data interaction between processes.
[0107] As an feasible approach, intra-process thread sharing of memory is employed to accelerate the computation of the neutron transport matrix equations. Besides enabling parallel processes, this method utilizes multiple threads sharing memory within a single process. The shared memory parallelism within the distributed parallel region further enhances the processing speed of the parallel process. OpenMP (Open Multi-Processing) is an industry standard for shared-memory system programming, consisting of compiler instructions, runtime libraries, and environment variables that influence runtime behavior. While OpenMP parallelism is relatively small, it avoids communication by exchanging data within memory within nodes. Therefore, this application constructs an MPI / OpenMP hybrid parallel architecture, where multiple OpenMP threads are created within the same MPI process and share all the process's memory. OpenMP computes the neutron transport response matrix for each grid individually within a single process. OpenMP parallelization instructions are added before the loop that iterates through all grids within all grids in a single process, and the compiler automatically splits this loop into multiple threads for parallel execution. The MPI / OpenMP hybrid parallel architecture optimizes memory and load balancing by coupling process parallelism and thread parallelism, which greatly improves the computation speed of rod-by-rod transport calculations based on the block method under the MPI / OpenMP hybrid parallel architecture. The MPI / OpenMP parallel architecture is deeply coupled with the iterative calculation method of dividing the region into red and black grids, which further accelerates the solution speed of neutron transport calculations.
[0108] As an feasible approach, the memory-sharing parallel method within the distributed parallel region can also employ GPU and CUDA-based parallel technology. In this method, the MPI method is still used to start the parallel process. MPI runs on the CPU, initializes the core parameters in the CPU host memory, uses program commands to copy the parameters from the CPU to the GPU, and then traverses the neutron transport response matrix corresponding to the grid. CUDA automatically converts this into thread-level parallelism on the GPU for iterative computation.
[0109] As a feasible approach, to better illustrate the computational acceleration advantages of the MPI / OpenMP hybrid parallel architecture, an acceleration experiment applying the MPI / OpenMP hybrid parallel architecture was designed. The experiment used the same program runtime environment to achieve large-scale parallel acceleration of the same nuclear reactor core rod-by-rod transport computation. The JFNK algorithm was not used for acceleration in this experiment. Test results showed a parallel speedup of approximately 200 in experiments using the MPI / OpenMP hybrid parallel architecture and those not using it, with no change in computational results across different parallel scales.
[0110] As a feasible approach, to better illustrate the speedup effect of the JFNK acceleration algorithm, an acceleration experiment using the JFNK algorithm was designed. The experiment used the same program running environment to achieve large-scale parallel acceleration of the same nuclear reactor core rod-by-rod transport calculation. This acceleration experiment was conducted under the premise of applying the MPI / OpenMP hybrid parallel architecture. In the experiment with the JFNK acceleration algorithm enabled and without enabling the algorithm, the test showed that the parallel speedup ratio was about 10, and the calculation results remained unchanged.
[0111] As one implementation method, to further improve the accuracy of neutron transport calculation results, the resolution of the neutron flux distribution obtained according to the aforementioned steps is improved, referring to... Figure 7 The specific steps of the resolution enhancement technology algorithm are as follows:
[0112] In step S701, the neutron flux is approximated by polynomial projection to obtain the neutron flux expansion.
[0113] In this step, the neutron flux distribution of the uniform nodal level can be obtained according to step S103. For the data, perform a polynomial projection approximation:
[0114] (12)
[0115] in, , For Legendre polynomials, , , , , , , The coefficients are the polynomial expansion coefficients of the projected flux distribution. This step transforms the discrete neutron flux distribution into a continuous functional expression, which can be accurately reconstructed using Legendre polynomials.
[0116] In step S702, the flux distribution resolution is improved by calculating the neutron flux expansion to obtain a refined neutron flux distribution.
[0117] In this step, the resolution of the neutron flux distribution calculation results is improved, referring to... Figure 8 This shows the integration interval along the z-axis for the mesh. The integral interval with any finer resolution within it is Its average flux for:
[0118] (13)
[0119] In this step, the accuracy of neutron flux distribution is improved by using a finer resolution integration interval.
[0120] In step S703, the power distribution resolution is improved by calculating the fine neutron flux distribution to obtain the fine power distribution.
[0121] In this step, the resolution of the power distribution calculation results is improved, referring to... Figure 8 Taking the z-axis as an example, based on the fine neutron flux distribution Further calculations can yield finer integration intervals. Power distribution within:
[0122] (14)
[0123] (15)
[0124] (16)
[0125] (17)
[0126] in, Number the neutron energy group. The total number of energy groups, This is the cross section for fission energy release.
[0127] The neutron transport response matrix obtained in step S101 has the precision of a coarse grid. To solve this problem, it is often necessary to divide the grid into finer grids, which leads to increased computational overhead, more memory usage, and increased computation time. The resolution enhancement technology algorithm achieves high-precision output on the basis of the original coarse grid precision while avoiding the above problems.
[0128] Figure 9 This is a block diagram of an apparatus for a reactor transport calculation method according to an embodiment of this application. (Reference) Figure 9 As shown, system 900 is used to implement Figure 1 The method shown may include an internal communication bus 1001, a processor 902, a read-only memory (ROM) 903, a random access memory (RAM) 904, a communication port 905, and a hard disk 906. The internal communication bus 1001 enables data communication between components of the system 900. The processor 902 can make judgments and issue prompts, and may include a CPU and a GPU. In some embodiments, the processor 902 may consist of one or more processors. The communication port 905 enables data communication between the implementation environment 900 and external systems. In some embodiments, the implementation environment 900 can send and receive information and data from a network via the communication port 1005. The implementation environment 900 may also include different forms of program storage units and data storage units, such as the hard disk 906, the read-only memory (ROM) 903, and the random access memory (RAM) 904, capable of storing various data files used for computer processing and / or communication, as well as possible program instructions executed by the processor 902. The processor executes these instructions to implement the main part of the method. The above-mentioned fault analysis method can be implemented as a computer program, stored in hard disk 906, and loaded into processor 902 for execution.
[0129] The present invention also includes a computer-readable medium storing computer program code that, when executed by a processor, implements the aforementioned fault analysis method.
[0130] The basic concepts have been described above. Obviously, for those skilled in the art, the above disclosure is merely illustrative and does not constitute a limitation of this application. Although not explicitly stated herein, those skilled in the art may make various modifications, improvements, and corrections to this application. Such modifications, improvements, and corrections are suggested in this application, and therefore remain within the spirit and scope of the exemplary embodiments of this application.
[0131] Furthermore, this application uses specific terms to describe embodiments of the application. For example, "an embodiment," "one embodiment," and / or "some embodiments" refer to a particular feature, structure, or characteristic related to at least one embodiment of the application. Therefore, it should be emphasized and noted that "an embodiment," "one embodiment," or "an alternative embodiment" mentioned twice or more in different locations in this specification do not necessarily refer to the same embodiment. In addition, certain features, structures, or characteristics in one or more embodiments of the application can be appropriately combined.
[0132] Some aspects of this application can be executed entirely by hardware, entirely by software (including firmware, resident software, microcode, etc.), or by a combination of hardware and software. The aforementioned hardware or software may be referred to as a "data block," "module," "engine," "unit," "component," or "system." The processor may be one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DAPDs), programmable logic devices (PLDs), field-programmable gate arrays (FPGAs), processors, controllers, microcontrollers, microprocessors, or combinations thereof. Furthermore, aspects of this application may manifest as computer products residing in one or more computer-readable media, including computer-readable program code. For example, computer-readable media may include, but are not limited to, magnetic storage devices (e.g., hard disks, floppy disks, magnetic tapes, etc.), optical discs (e.g., compressed CDs, digital multifunction DVDs, etc.), smart cards, and flash memory devices (e.g., cards, sticks, key drives, etc.).
[0133] A computer-readable medium may contain a propagated data signal containing computer program code, for example, on baseband or as part of a carrier wave. This propagated signal may take various forms, including electromagnetic, optical, and so on, or suitable combinations thereof. A computer-readable medium can be any computer-readable medium other than a computer-readable storage medium, which can be connected to an instruction execution system, apparatus, or device to enable communication, propagation, or transmission of a program for use. The program code located on the computer-readable medium can be propagated through any suitable medium, including radio, cable, fiber optic cable, radio frequency signals, or similar media, or any combination of the above media.
[0134] Similarly, it should be noted that, in order to simplify the description of the present application and thus aid in the understanding of one or more embodiments of the invention, the foregoing description of the embodiments of the present application sometimes combines multiple features into a single embodiment, drawing, or description thereof. However, this disclosure method does not imply that the subject matter of the application requires more features than those mentioned in the claims. In fact, the embodiments contain fewer features than all the features of the single embodiments disclosed above.
[0135] In some embodiments, numbers describing the quantity of components and attributes are used. It should be understood that such numbers used in the description of embodiments are modified in some examples with the terms "approximately," "approximately," or "generally." Unless otherwise stated, "approximately," "approximately," or "generally" indicates that the numbers are allowed to vary by ±20%. Accordingly, in some embodiments, the numerical parameters used in the specification and claims are approximate values, which may be changed depending on the characteristics required by individual embodiments. In some embodiments, numerical parameters should take into account specified significant digits and employ a general method of digit reservation. Although the numerical ranges and parameters used to confirm their breadth of scope in some embodiments of this application are approximate values, in specific embodiments, such values are set as precisely as feasible.
[0136] Although this application has been described with reference to specific embodiments, those skilled in the art should recognize that the above embodiments are only used to illustrate this application, and various equivalent changes or substitutions can be made without departing from the spirit of this application. Therefore, any changes or modifications to the above embodiments within the essential spirit of this application will fall within the scope of the claims of this application.
Claims
1. A reactor transport calculation method, comprising the following steps: Multiple parallel processes are invoked to calculate the neutron transport response matrix of multiple regions in the reactor core, where each region includes several grids allocated to the associated processes, and each grid corresponds to a neutron transport response matrix; A set of basis vectors is set for the acceleration algorithm. The basis vectors include the neutron flux of the grid contained in the plurality of regions, the first incident flow at the outer boundary of the core, the second incident flow of the first grid group in the grid, and the core characteristic value. The grids in the first grid group are not adjacent. The acceleration algorithm is the JFNK algorithm. The multiple processes are invoked to use the acceleration algorithm to perform neutron transport iterative calculations based on the neutron transport response matrix and the basis vectors, thereby obtaining the target values of the neutron flux and core characteristic values.
2. The reactor transport calculation method of claim 1, wherein, The process of calling multiple parallel processes to calculate the neutron transport response matrix of multiple regions in the reactor core includes: Multiple processes are started in parallel, and each process is used to read the input information of the core, including geometric information; The core is meshed based on the geometric information to obtain multiple meshes; The core is divided into multiple regions based on the number of processes in the multiple processes; The multiple processes are invoked to calculate the neutron transport response matrix of each grid according to their respective assigned grids.
3. The method of claim 1, wherein, The process of calling multiple parallel processes to calculate the neutron transport response matrix of multiple regions in the reactor core includes: The plurality of grids are divided into a first grid group and a second grid group, wherein the grids in the same grid group are not adjacent.
4. The reactor transport calculation method as described in claim 1, characterized in that, The threads within the process share memory.
5. The reactor transport calculation method as described in claim 1, characterized in that, Invoking the multiple processes to use the acceleration algorithm to perform neutron transport iterative calculations based on the neutron transport response matrix and the basis vectors includes: The multiple processes are invoked to perform neutron transport calculations, obtain the neutron flux of the grid, the incident flow of the grid, and the core characteristic values, and save them as the second current basis vector; The L2 norm of the first function is calculated based on the second current basis vector and the first current basis vector not calculated in this instance. The JFNK perturbation is calculated based on the L2 norm of the first current basis vector. Krylov bases are obtained based on the first function and the L2 norm of the first function, and the minimum residual method loop is executed using the Krylov bases. Each Krylov base obtained during the minimum residual method loop is formed into a Krylov base matrix, and the target Krylov base is obtained when the minimum residual method loop exits. Generate the next basis vector based on the first current basis vector, the Krylov basis matrix, and the target Krylov basis; Determine whether the L2 norm of the first function calculated based on the next basis vector has converged, and thus decide whether to end the iterative calculation.
6. The reactor transport calculation method as described in claim 5, characterized in that, The process of invoking the multiple processes to perform neutron transport calculations and obtain the neutron flux of the grid, the incident flux of the grid, and the core characteristic values includes performing the following steps for each grid: a. Calculate the first outflow of the target grid group at the boundary of the plurality of regions based on the neutron transport response matrix and the grid of the target grid group, wherein the target grid group is selected from one of the first grid group and the second grid group, and the grids in the same grid group are not adjacent; b. Encapsulate the first outgoing stream with inter-process communication data and send it out in a non-blocking communication manner, while simultaneously starting to receive communication data from other processes in a non-blocking manner; c. Calculate the second outgoing flow of the grids belonging to the target grid group within the multiple regions, and store it as the incoming flow of the adjacent grids; d. Calculate the incident flow of the grid belonging to the target grid group at the core boundary based on the outer boundary conditions of the core, the first outgoing flow, and the second outgoing flow; e. Update the neutron flux of the grids belonging to the target grid group in the plurality of regions according to the neutron transport response matrix and the basis vector; f. Each process waits for the non-blocking communication to complete and maps the communication data as an incident flow of a grid at the boundary of multiple regions; g. Select the other of the first and second grid groups as the target grid group, and iteratively execute step af; The core characteristic values are updated based on the updated neutron flux.
7. The reactor transport calculation method as described in claim 1, characterized in that, After obtaining the target values of the neutron flux and core characteristic values, the process further includes: The neutron flux is approximated by a polynomial projection to obtain the neutron flux expansion. The flux distribution resolution is improved by performing flux distribution enhancement calculations on the neutron flux expansion to obtain a fine neutron flux distribution. The power distribution resolution is improved by performing a power distribution resolution calculation on the fine neutron flux distribution to obtain a fine power distribution.
8. An electronic device, comprising: Memory is used to store instructions that can be executed by the processor; as well as A processor for executing the instructions to implement the method as described in any one of claims 1-7.
9. A computer storage medium storing computer program code, said computer program code implementing the method as claimed in any one of claims 1-7 when executed by a processor.
10. A computer program product comprising computer program code, wherein when the computer program code is executed by one or more processors, the one or more processors implement the steps of the method as described in any one of claims 1-7.