A method and system for cycle tolerance determination for flash iteration calculations
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- SHENGTAI ZHIKE (SHANGHAI) SOFTWARE TECHNOLOGY CO LTD
- Filing Date
- 2024-12-20
- Publication Date
- 2026-08-07
AI Technical Summary
[0005]本说明书实施例提供一种用于闪蒸迭代计算的循环容差确定方法及系统,以解决部分或者全部问题:目前,在化工流程模拟中,需要手动规定流程软件的循环迭代容差,这种手动指定循环迭代容差的方法,虽然能够给出缺省的容差值,但是缺省值对两相设备数少的流程会偏大,对两相设备数多的流程会偏小
[0013] The above-mentioned at least one technical solution adopted in the embodiments of this specification can achieve the following beneficial effects: Based on the different component proportions corresponding to the several flash evaporation devices to be processed and the error amplification factor of each flash evaporation, the total error amplification factor is determined. The different component proportions corresponding to the several flash evaporation devices to be processed are the component proportions of different gas phases of the several flash evaporation devices to be processed, or the component proportions of different liquid phases of the several flash evaporation devices to be processed. Based on the total error amplification factor, the vaporization fraction and the effective component number of the tearing stream corresponding to the several flash evaporation devices to be processed, the cycle tolerance of the tearing stream after one cycle is determined using a preset cycle tolerance calculation formula. This can be applied to the tearing stream in the process simulation with circulation, realize the automatic setting of cycle tolerance, and realize the optimal tolerance calculation.
Smart Images

Figure CN119719571B_ABST
Abstract
Description
Technical Field
[0001] The embodiments of this application belong to the field of process simulation flash evaporation iterative calculation technology, and particularly relate to a method and system for determining cycle tolerance for flash evaporation iterative calculation. Background Technology
[0002] Chemical process simulation is an important tool in the field of chemical engineering, used to predict and optimize the behavior of industrial production processes. It can be applied to a wide range of chemical processes, from laboratory scale to large-scale production.
[0003] Currently, in chemical process simulation, it is necessary to manually specify the iteration tolerance of the process software. While this method of manually specifying the iteration tolerance can provide a default tolerance value, the default value tends to be too large for processes with a small number of two-phase devices and too small for processes with a large number of two-phase devices. Therefore, users need to adjust it gradually based on their experience, and ordinary users cannot adjust the default value according to their own process setup.
[0004] Therefore, a method for determining the cyclic tolerance for flash evaporation iterative calculations is needed. Summary of the Invention
[0005] This specification provides a method and system for determining the cyclic tolerance in flash evaporation iterative calculations to solve some or all of the following problems: Currently, in chemical process simulation, it is necessary to manually specify the cyclic iteration tolerance of the process software. While this method of manually specifying the cyclic iteration tolerance can provide a default tolerance value, the default value tends to be too large for processes with a small number of two-phase devices and too small for processes with a large number of two-phase devices. Therefore, users need to adjust it gradually based on their experience, and ordinary users cannot adjust the default value according to their own process setup.
[0006] To solve the above-mentioned technical problems, the embodiments in this specification are implemented as follows:
[0007] This specification provides an embodiment of a method for determining the cycle tolerance in flash evaporation iterative calculations. The method for determining the cycle tolerance includes:
[0008] Based on the different component proportions corresponding to the several flash evaporation devices to be processed and the error amplification factor of each flash evaporation, the total error amplification factor is determined. The different component proportions corresponding to the several flash evaporation devices to be processed are the component proportions of different gas phases of the several flash evaporation devices to be processed, or the component proportions of different liquid phases of the several flash evaporation devices to be processed.
[0009] Based on the total error amplification factor, the gasification fraction of the several flash evaporation devices to be processed, and the effective component number of the tear stream, the cycle tolerance of the tear stream after one cycle is determined using a preset cycle tolerance calculation formula.
[0010] This specification also provides an embodiment of a cyclic tolerance determination system for flash evaporation iterative calculations. The cyclic tolerance determination system includes:
[0011] The error total amplification factor determination module determines the error total amplification factor based on the different component proportions corresponding to the several flash evaporation devices to be processed and the error amplification factor of each flash evaporation. The different component proportions corresponding to the several flash evaporation devices to be processed are the component proportions of different gas phases of the several flash evaporation devices to be processed, or the component proportions of different liquid phases of the several flash evaporation devices to be processed.
[0012] The cycle tolerance calculation module, based on the total error amplification factor, the gasification fraction corresponding to the several flash evaporation devices to be processed, and the effective component number of the tear stream, uses a preset cycle tolerance calculation formula to determine the cycle tolerance of the tear stream after one cycle.
[0013] The above-mentioned at least one technical solution adopted in the embodiments of this specification can achieve the following beneficial effects: Based on the different component proportions corresponding to the several flash evaporation devices to be processed and the error amplification factor of each flash evaporation, the total error amplification factor is determined. The different component proportions corresponding to the several flash evaporation devices to be processed are the component proportions of different gas phases of the several flash evaporation devices to be processed, or the component proportions of different liquid phases of the several flash evaporation devices to be processed. Based on the total error amplification factor, the vaporization fraction and the effective component number of the tearing stream corresponding to the several flash evaporation devices to be processed, the cycle tolerance of the tearing stream after one cycle is determined using a preset cycle tolerance calculation formula. This can be applied to the tearing stream in the process simulation with circulation, realize the automatic setting of cycle tolerance, and realize the optimal tolerance calculation. Attached Figure Description
[0014] The accompanying drawings, which are included to provide a further understanding of this application and form part of this application, illustrate exemplary embodiments and are used to explain this application, but do not constitute an undue limitation of this application. Some specific embodiments of this application will be described in detail below with reference to the accompanying drawings in an exemplary and non-limiting manner. The same reference numerals in the drawings designate the same or similar parts or components. Those skilled in the art should understand that these drawings are not necessarily drawn to scale. In the drawings:
[0015] Figure 1 A flowchart illustrating a method for determining cyclic tolerance in flash evaporation iterative calculations, provided as an embodiment of this specification.
[0016] Figure 2 A schematic diagram of a single flash evaporation device provided in the embodiments of this specification;
[0017] Figure 3 A schematic diagram illustrating the process for determining the component proportions of different gas phases and different liquid phases in the flash evaporation equipment provided in the embodiments of this specification.
[0018] Figure 4 A schematic diagram of the iterative process simulation provided in the embodiments of this specification;
[0019] Figure 5 This is a schematic diagram of a cyclic tolerance determination system for flash evaporation iterative calculations provided in this embodiment. Detailed Implementation
[0020] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are merely some, not all, of the embodiments of the present application. All other embodiments obtained by those skilled in the art based on the embodiments of the present application without creative effort should fall within the scope of protection of the present application.
[0021] Figure 1 This is a flowchart illustrating a method for determining cycle tolerance in flash evaporation iterative calculations, provided as an embodiment of this specification. From a programming perspective, the execution entity of the method for determining cycle tolerance in flash evaporation iterative calculations is a program mounted on an application server or application terminal. It can be understood that this method can be executed by any device, equipment, platform, or cluster of devices with computing and processing capabilities. Figure 1 As shown, the method for determining the cyclic tolerance includes:
[0022] Step S101: Based on the different component proportions corresponding to the several flash evaporation devices to be processed and the error amplification factor of each flash evaporation, determine the total error amplification factor. The different component proportions corresponding to the several flash evaporation devices to be processed are the component proportions of different gas phases of the several flash evaporation devices to be processed, or the component proportions of different liquid phases of the several flash evaporation devices to be processed.
[0023] In the embodiments of this specification, the method for obtaining the different component proportions corresponding to the plurality of flash evaporation devices to be processed includes:
[0024] Based on the temperature, pressure, and composition of the flash streams from several flash evaporators to be processed, the phase equilibrium constant is determined.
[0025] Based on the phase equilibrium constant and the initial gasification fraction, the component proportions of different gas phases in the several flash evaporation devices to be processed are determined;
[0026] Based on the component ratio of different gas phases in the several flash evaporation devices to be processed, a flash evaporation convergence judgment function is determined;
[0027] If the flash evaporation convergence judgment function satisfies the flash evaporation tolerance, then the component proportions of different liquid phases in the several flash evaporation devices to be processed are determined.
[0028] In the embodiments of this specification, the formula for calculating the component proportions of different gas phases in the plurality of flash evaporators to be processed is as follows:
[0029] ;
[0030] in,
[0031] This indicates the proportion of component i in the gas phase;
[0032] This represents the phase equilibrium constant of component i;
[0033] Indicates the initial gasification fraction;
[0034] The formula for calculating the flash evaporation convergence judgment function is as follows:
[0035] ;
[0036] in,
[0037] This represents the convergence judgment function for flash evaporation;
[0038] This indicates the proportion of component i in the gas phase;
[0039] This represents the phase equilibrium constant of component i;
[0040] Indicates the proportion of component i;
[0041] Indicates the initial gasification fraction;
[0042] The formula for calculating the component proportions of different liquid phases in the several flash evaporation devices to be processed is as follows:
[0043] ;
[0044] in,
[0045] This indicates the proportion of component i in the liquid phase;
[0046] This represents the phase equilibrium constant of component i;
[0047] This represents the initial gasification fraction.
[0048] In specific embodiments, the phase equilibrium constant can be obtained by consulting charts or empirical formulas, and will not be elaborated here.
[0049] In the embodiments described in this specification, the method further includes:
[0050] If the flash evaporation convergence judgment function does not satisfy the flash evaporation tolerance, the initial gasification fraction is adjusted to the updated initial gasification fraction, thereby determining the component proportions of different gas phases in the several flash evaporation devices to be processed.
[0051] in,
[0052] The adjustment of the initial gasification fraction to the updated initial gasification fraction specifically includes:
[0053] = ;
[0054] in,
[0055] This indicates the updated initial gasification fraction;
[0056] Indicates the initial gasification fraction;
[0057] This represents the convergence judgment function for flash evaporation;
[0058] This represents the updated flash evaporation convergence criterion function. f ' e = ∑ z i K i -1 [1+ K i -1 e j ] 2 .
[0059] Figure 2 This is a schematic diagram of a single flash evaporation device provided in the embodiments of this specification. In the process of chemical process simulation calculation, the temperature, pressure and feed composition of the products of equipment such as tanks have been determined. It is necessary to calculate the gas-liquid phase composition and vaporization fraction after flash evaporation.
[0060] Figure 3 This is a schematic diagram illustrating the process for determining the component proportions of different gas phases and different liquid phases in the flash evaporation equipment provided in the embodiments of this specification. Figure 3 As shown, the temperature T, pressure P, and composition of the flash streams from several flash evaporators to be processed are... Determine the phase equilibrium constants of different components i at temperature T and pressure P. Determine the initial gasification fraction. ; Calculate the component proportions of different gas phases in several flash evaporators to be processed. ; Calculate the flash evaporation convergence criterion function ;like Then calculate the component proportions of different liquid phases in the several flash evaporators to be processed. ;like Then according to = Adjustments were made to update the initial gasification fraction.
[0061] The process computation consists of multiple devices, each primarily employing flash calculations. The objective value of the computational equation should theoretically be zero. However, due to the iterative nature of the computation, the objective value cannot reach absolute zero. Therefore, a minimum value is typically set for the convergence condition, such as 1e-6, denoted here as... So, the composition calculated from flash evaporation... and It is not an absolutely precise value, but a value with a certain margin of error, expressed as:
[0062]
[0063]
[0064] In the above formula , This represents the true value calculated when the objective equation is 0. , These represent the actual calculated values due to the set tolerances. , This indicates the error carried by the true value.
[0065] In process simulation, calculations are usually performed on multiple devices, and loops often form between devices. There are often unsatisfactory processed products that are fed in for reprocessing. Figure 4 This is a schematic diagram illustrating the iterative process simulation provided in the embodiments of this specification. For example... Figure 4 As shown, when there is a loop, one of the streams within the loop is usually torn, which is called a "torn flow". The loop needs to converge iteratively, and it is generally required that the flow rates of all components be consistent in the two calculations before and after the tear. When using computer iterative calculations, absolute equality is not achievable, and it is also required that the error between the two calculations of the torn flow be less than the tolerance.
[0066]
[0067] Since tear flow is also an intermediate calculated material, its composition contains errors. ,in, Indicates composition The error; through the flash evaporation calculation formula, it was found that this error is amplified with each flash evaporation calculation. When there are fewer devices in the cycle, A relatively small value can be specified. However, when there are many devices in the loop, the tearing flow error at the inlet is amplified. Therefore, when the user specifies a relatively small value... This can cause the loop to fail to converge.
[0068] In the embodiments of this specification, the total error amplification factor specifically includes:
[0069] The component proportions of the different gas phases are as follows: And the ideal component proportions of different gas phases The error in the proportion of components in different gas phases is: The error amplification factor for each flash evaporation is... Then the total error amplification factor is: Where n represents the flash evaporation equipment n;
[0070] Or the component proportions of the different liquid phases are:
[0071] And the ideal component proportions of different liquid phases The error in the component ratio of different liquid phases is: The error amplification factor for each flash evaporation is... Then the total error amplification factor is: , where n represents the flash evaporation equipment n.
[0072] To understand the total error amplification factor The derivation of this formula will be explained below. Assume the composition of the material at the tear point. With error :
[0073]
[0074] Calculated from flash evaporation for
[0075]
[0076] make
[0077]
[0078]
[0079] but Simplified to
[0080]
[0081] make
[0082] .
[0083] It can be seen from the above formula that yes of times, will This is called the error amplification factor for each flash evaporation. With each flash evaporation, the tolerance is amplified. The error amplification factor is: after multiple flash evaporations.
[0084] .
[0085] Similarly, the calculations based on flash evaporation for ,make And the ideal component proportions of different liquid phases Then the error in the component proportions of different liquid phases is: .
[0086] make .
[0087] It can be seen from the above formula that yes of times, will This is called the error amplification factor for each flash evaporation. With each flash evaporation, the tolerance is amplified. The error amplification factor is: after multiple flash evaporations. .
[0088] It is evident that during the flash evaporation process, regardless of whether it is for the liquid phase component or the gas phase component, after multiple flash evaporations, the error amplification factor remains the same: .
[0089] In the embodiments described in this specification, the total error amplification factor is... With phase equilibrium constant Gasification fraction and the number of two-phase devices Related, and ;
[0090] The total error amplification factor is then mentioned. for: ;
[0091] in,
[0092] Indicates the total error amplification factor;
[0093] Indicates the initial gasification fraction;
[0094] Indicates gas phase components;
[0095] n represents the flash evaporation equipment.
[0096] Due to the total error amplification factor With phase equilibrium constant Gasification fraction And related to the number of two-phase devices. Different variables affect the overall error amplification factor. The effects differ, and will be explained separately below. Phase equilibrium constant Impact: When When it is 0, When it is 0, the error is not amplified. As the value increases, the error coefficient gradually approaches the value. .
[0097] Gasification fraction Impact: When When the value is 0, the error amplification factor is ,when When the value is 1, the error amplification factor is 1.
[0098] The effect of the number of two-phase devices n: As the number of two-phase devices increases, the error amplification factor will increase exponentially.
[0099] From the influence of the variables above, it can be concluded that the device n has the greatest impact on the error amplification factor, and the relationship is exponential. Assume... If the value is very large, then .
[0100] Based on this, the total error amplification factor is: .
[0101] Step S103: Based on the total error amplification factor, the gasification fraction of the several flash evaporation devices to be processed, and the effective component number of the tear stream, the cycle tolerance of the tear stream after one cycle is determined using a preset cycle tolerance calculation formula.
[0102] Continuing with the previous derivation process, when the flash evaporation tolerance is... Then the average tolerance of each component is Where m is the number of effective components. Assume the initial tolerance of the torn material is... Therefore, after one iteration, the cycle tolerance should be set to... .
[0103] In the embodiments described in this specification, the preset cycle tolerance calculation formula is as follows: ;
[0104] in,
[0105] This indicates the cyclic tolerance of the tearing flow strand;
[0106] This indicates the flash evaporation tolerance;
[0107] Indicates the number of valid components;
[0108] This represents the total error amplification factor.
[0109] In the embodiments described in this specification, Set to 1e-6.
[0110] To further understand the method for determining the cyclic tolerance for flash evaporation iterative calculation provided in the embodiments of this specification, the following will describe it in conjunction with specific embodiments.
[0111] The tearing flow of a certain device is shown below. The device involves three two-phase flash evaporation units, and the flash evaporation calculation tolerance is 0.000001.
[0112] The composition of the tear flow is shown in the table below:
[0113]
[0114] It can be seen that the tearing flow has 6 effective components, therefore After initial cycle calculations, the gasification fractions of the three flash evaporators were found to be e1=0.90979, e2=0.84956, and e3=0.95463, respectively.
[0115] so
[0116]
[0117] The initial tear flow convergence error calculated using this invention is 0.000000226.
[0118] The method for determining the cyclic tolerance for flash evaporation iterative calculation provided in this specification determines the component proportions of different gas phases and different liquid phases of several flash evaporation devices based on the temperature, pressure, and composition of the flash streams. The component proportions of different gas phases of the several flash evaporation devices satisfy the flash tolerance. Based on the component proportions of different gas phases and the error amplification factor for each flash, the total error amplification factor is determined. Based on the vaporization fraction, the effective component number of the tear stream, and the total error amplification factor corresponding to the several flash evaporation devices, the cyclic tolerance of the tear stream after one cycle is determined using a preset cyclic tolerance calculation formula. This method can be applied to tear streams in process simulations with cyclic flow, realizing automatic setting of the cyclic tolerance and achieving optimal tolerance calculation.
[0119] The foregoing embodiments of this specification provide a method for determining the cyclic tolerance for flash evaporation iterative calculations. Based on the same idea, the embodiments of this specification also provide a system for determining the cyclic tolerance for flash evaporation iterative calculations. Figure 5 This is a schematic diagram of a cyclic tolerance determination system for flash iterative calculations provided in this embodiment. Figure 5 As shown, the cyclic tolerance determination system includes:
[0120] The error total amplification factor determination module 501 determines the error total amplification factor based on the different component proportions corresponding to the several flash evaporation devices to be processed and the error amplification factor of each flash evaporation. The different component proportions corresponding to the several flash evaporation devices to be processed are the component proportions of different gas phases of the several flash evaporation devices to be processed, or the component proportions of different liquid phases of the several flash evaporation devices to be processed.
[0121] The cycle tolerance calculation module 503, based on the total error amplification factor, the gasification fraction corresponding to the several flash evaporation devices to be processed, and the effective component number of the tear stream, uses a preset cycle tolerance calculation formula to determine the cycle tolerance of the tear stream after one cycle.
[0122] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features therein. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of this application.
Claims
1. A method for determining the cyclic tolerance in flash evaporation iterative calculations, characterized in that, The method for determining the cycle tolerance includes: Based on the different component proportions corresponding to the several flash evaporators to be processed and the error amplification factor of each flash evaporation, the total error amplification factor is determined. The different component proportions corresponding to the several flash evaporators to be processed refer to the component proportions of different gas phases of the several flash evaporators to be processed, or the component proportions of different liquid phases of the several flash evaporators to be processed. The total error amplification factor... With phase equilibrium constant Gasification fraction and the number of two-phase devices Related, and The total error amplification factor is then... for: ;in, Indicates the total error amplification factor; Indicates the initial gasification fraction; Indicates the gas phase components; n represents the flash evaporation equipment n; Based on the total error amplification factor, the gasification fraction corresponding to the several flash evaporators to be processed, and the effective component number of the tear stream, the cycle tolerance of the tear stream after one cycle is determined using a preset cycle tolerance calculation formula. The preset cycle tolerance calculation formula is as follows: ;in, This indicates the cyclic tolerance of the tearing flow strand; Indicates flash evaporation tolerance; Indicates the number of valid components; This represents the total error amplification factor, and the initial tolerance of the tearing strand is... The cycle tolerance after one iteration is: .
2. The method for determining cycle tolerance as described in claim 1, characterized in that, The methods for obtaining the different component proportions corresponding to the several flash evaporation devices to be processed include: Based on the temperature, pressure, and composition of the flash streams from several flash evaporators to be processed, the phase equilibrium constant is determined. Based on the phase equilibrium constant and the initial gasification fraction, the component proportions of different gas phases in the several flash evaporation devices to be processed are determined; Based on the component ratio of different gas phases in the several flash evaporation devices to be processed, a flash evaporation convergence judgment function is determined; If the flash evaporation convergence judgment function satisfies the flash evaporation tolerance, then the component proportions of different liquid phases in the several flash evaporation devices to be processed are determined.
3. The method for determining cycle tolerance as described in claim 2, characterized in that, The formula for calculating the component proportions of different gas phases in the several flash evaporation devices to be processed is as follows: ; in, This indicates the proportion of component i in the gas phase; This represents the phase equilibrium constant of component i; Indicates the initial gasification fraction; The formula for calculating the flash evaporation convergence judgment function is as follows: ; in, This represents the convergence judgment function for flash evaporation; This indicates the proportion of component i in the gas phase; This represents the phase equilibrium constant of component i; Indicates the proportion of component i; Indicates the initial gasification fraction; The formula for calculating the component proportions of different liquid phases in the several flash evaporation devices to be processed is as follows: ; in, This indicates the proportion of component i in the liquid phase; This represents the phase equilibrium constant of component i; This represents the initial gasification fraction.
4. The method for determining cycle tolerance as described in claim 3, characterized in that, The method further includes: If the flash evaporation convergence judgment function does not satisfy the flash evaporation tolerance, the initial gasification fraction is adjusted to the updated initial gasification fraction, thereby determining the component proportions of different gas phases in the several flash evaporation devices to be processed. in, The adjustment of the initial gasification fraction to the updated initial gasification fraction specifically includes: = ; in, This indicates the updated initial gasification fraction; Indicates the initial gasification fraction; This represents the convergence judgment function for flash evaporation; This represents the updated flash evaporation convergence criterion function. .
5. The method for determining cycle tolerance as described in claim 2, characterized in that, The total error amplification factor specifically includes: The component proportions of the different gas phases are as follows: And the ideal component proportions of different gas phases The error in the proportion of components in different gas phases is: The error amplification factor for each flash evaporation is... Then the total error amplification factor is: Where n represents the flash evaporation equipment n; Or the component proportions of the different liquid phases are: And the ideal component proportions of different liquid phases The error in the component ratio of different liquid phases is: The error amplification factor for each flash evaporation is... Then the total error amplification factor is: , where n represents the flash evaporation equipment n.
6. A system for determining cyclic tolerance in flash evaporation iterative calculations, characterized in that, The cycle tolerance determination system includes: The overall error amplification factor determination module determines the overall error amplification factor based on the different component proportions corresponding to the several flash evaporators to be processed and the error amplification factor of each flash evaporation. The different component proportions corresponding to the several flash evaporators to be processed refer to the component proportions of different gas phases of the several flash evaporators to be processed, or the component proportions of different liquid phases of the several flash evaporators to be processed. The overall error amplification factor... With phase equilibrium constant Gasification fraction and the number of two-phase devices Related, and The total error amplification factor is then... for: ;in, Indicates the total error amplification factor; Indicates the initial gasification fraction; Indicates the gas phase components; n represents the flash evaporation equipment n; The cycle tolerance calculation module, based on the total error amplification factor, the gasification fraction corresponding to the several flash evaporators to be processed, and the effective component number of the tear stream, determines the cycle tolerance of the tear stream after one cycle using a preset cycle tolerance calculation formula. The preset cycle tolerance calculation formula is as follows: ;in, This indicates the cyclic tolerance of the tearing flow strand; Indicates flash evaporation tolerance; Indicates the number of valid components; This represents the total error amplification factor, and the initial tolerance of the tearing strand is... The cycle tolerance after one iteration is: .
Citation Information
Patent Citations
Genetic algorithm-based tolerance optimization method
CN113779885A
Flash evaporation method and device applied to digital twinning and capable of simultaneously judging phase state and solving
CN115424672A