A method for measuring two-dimensional density distribution of a leaking gas based on background schlieren technology

By combining background schlieren technology with the Glaston-Dale equation, the accuracy problem of optical gas forming technology in quantitatively calculating the density of leaked gas was solved, achieving high-precision measurement of gas density distribution and reducing the risk of combustion and explosion.

CN116448616BActive Publication Date: 2026-06-23HEFEI GENERAL MACHINERY RES INST +1

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
HEFEI GENERAL MACHINERY RES INST
Filing Date
2023-04-03
Publication Date
2026-06-23

AI Technical Summary

Technical Problem

Existing optical gas forming technology is difficult and inaccurate in quantitatively calculating the density of leaked gas, and it cannot adapt to the complex environmental changes during gas leakage, resulting in inaccurate calculation results.

Method used

Using a background schlieren technique, images of the reflected beams before and after gas injection are captured by a CCD camera. Combined with temperature measurements and the Glaston-Dale equation, the refractive index distribution of the gas flow field is iteratively solved using the central difference method, and the gas density distribution is inferred from this.

Benefits of technology

It improves the accuracy of leaked gas density calculation, enables the study of gas leakage behavior under different rupture conditions, provides a quantitative analysis tool for flammable gas leaks, and reduces the risk of combustion and explosion.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116448616B_ABST
    Figure CN116448616B_ABST
Patent Text Reader

Abstract

The application relates to the technical field of leakage gas density detection, in particular to a leakage gas two-dimensional density distribution measurement method based on background schlieren technology, which uses a CCD camera to shoot, and then obtains an experimental image affected by leakage gas and a reference image not affected by leakage gas; the reference image and the experimental image are compared, an inquiry window is selected, and then the total displacement of the inquiry window is obtained; a proper number of thermocouples are arranged at the edges of a gas flow field to measure the temperature, the measured temperature is taken as a boundary condition for gas refractive index calculation, and finally the density distribution of the gas in the gas flow field is obtained; the application can effectively improve the accuracy of leakage gas density calculation.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of leaked gas density detection technology, specifically a method for measuring the two-dimensional density distribution of leaked gas based on background schlieren technology. Background Technology

[0002] In the production and storage of various flammable gases, both transportation pipelines and storage devices pose a risk of gas leakage. Gas leaks can cause environmental pollution and even lead to explosions, resulting in property damage and personal injury. Therefore, leak detection of flammable gases is essential.

[0003] In leak gas detection, optical methods, as a non-contact measurement method, have advantages such as not intruding on the observed gas and being stable and reliable. Common optical gas shaping techniques include schlieren, shading, and background schlieren. The principle of schlieren is that light refracts in the target flow field, creating a bright and dark image on the imaging plane due to uneven light intensity. Shading directly illuminates the flow field with a strong light source, thus leaving a shadow on the imaging plane. Because these optical gas shaping techniques are mature, they have been widely used in the field of gas imaging. However, some problems have also been exposed in practical applications:

[0004] 1. Using the above method to quantitatively calculate the density of leaked gas is difficult, the calculation results are rough, and the accuracy is low.

[0005] 2. The environment during gas leakage and release is complex, and boundary conditions change rapidly and are difficult to determine. The existing optical gas shaping methods treat boundary conditions as constants throughout the process; while this simplifies calculations, it does not reflect the actual changes in the gas, leading to a significant reduction in the accuracy and precision of the calculations.

[0006] Therefore, the aforementioned technical problems urgently need to be solved. Summary of the Invention

[0007] To avoid and overcome the problems existing in the prior art, this invention provides a method for measuring the two-dimensional density distribution of leaked gas based on background schlieren technology. This invention can effectively improve the accuracy of leaked gas density calculation.

[0008] To achieve the above objectives, the present invention provides the following technical solution:

[0009] A method for measuring the two-dimensional density distribution of leaked gas based on background schlieren technology includes the following steps:

[0010] S1. Set up a background board at the designated optical measurement position and install a CCD camera at the designated shooting position; turn on the illumination light source, so that the light beam shines on the background board and is reflected into the CCD camera; install the gas injector that sprays the leaked gas at the predetermined position and align the nozzle with the propagation path of the reflected light beam.

[0011] S2. Simultaneously adjust the positions of the background plate, CCD camera, illumination light source, and gas ejector so that the reflected beam is perpendicularly illuminating the imaging plane of the CCD camera, and at the same time, make the projection of the light-emitting surface of the background plate along the propagation direction of the reflected beam completely coincide with the imaging plane of the CCD camera; at this time, the jet plane generated by the gas ejector intersects perpendicularly with the reflected light, and the perpendicular intersection forms a gas flow field.

[0012] S3. Use a CCD camera to capture an image of the reflected beam when the gas ejector is off as a reference image; use a CCD camera to capture an image of the reflected beam when the gas ejector is in the ejecting state as an experimental image.

[0013] S4. Compare the changes in the position of the corresponding query window on the reference image and the experimental image, obtain the pixel-level displacement and sub-pixel-level displacement of the query window, and add the pixel-level displacement and sub-pixel-level displacement to calculate the total displacement of the corresponding query window.

[0014] S5. Detect the temperature at the edge of the gas flow field and substitute the measured temperature into the ideal gas law to calculate the density of the leaking gas at the edge of the gas flow field; substitute the gas density into the Glaston-Dale equation to calculate the refractive index of the leaking gas.

[0015] S6. Using the refractive index value calculated in S5 as the Dirichlet boundary condition of the refractive index calculation equation, the gas flow field is iteratively solved using the central difference method to obtain the refractive index distribution field in the entire flow field, and then the density distribution of the gas flow field can be deduced.

[0016] As a further aspect of the present invention, step S4 is as follows:

[0017] S41. Establish a Cartesian coordinate system with the side where the two perpendicular lines of the reference image intersect as the coordinate axis and the intersection point of the two sides as the origin; select a specified area on the reference image as the query window and record the coordinates (x0, y0) of the center point of the query window in the reference image.

[0018] S42. Construct query windows of the same size at the corresponding positions of the experimental images, observe the position changes of the query windows, and record the coordinates (x1, y1) of the center point of the query window.

[0019] S43. Use the cross-correlation coefficient to calculate the correlation between the query window in the reference image and the query window in the experimental pattern. The formula for calculating the correlation coefficient is as follows:

[0020]

[0021] Where R(x,y) is the formula for calculating the cross-correlation coefficient, F(x0,y0) represents the gray-level distribution of the query window in the reference image, and G(x1,y1) represents the gray-level distribution of the query window in the experimental image.

[0022] S44. If the calculated cross-correlation coefficient is in the range [0.95, 1], then the query window constructed in the experimental image is correct; otherwise, repeat S42 to S43.

[0023] S45. Subtract the coordinates of the point in the query window before and after the movement to obtain the pixel-level displacement of the query window:

[0024] dx = x0 - x1

[0025] dy = y0 - y1

[0026] Where dx is the pixel-level displacement of the query window on the X-axis, and dy is the pixel-level displacement of the query window on the Y-axis;

[0027] S46. Next, use the sub-pixel displacement calculation formula to calculate the sub-pixel displacement of the query window:

[0028]

[0029]

[0030] Where du is the subpixel displacement of the query window on the X-axis, and dv is the subpixel displacement of the query window on the Y-axis.

[0031] S47. Finally, add the pixel-level displacement and the sub-pixel-level displacement to obtain the total displacement of the corresponding query window:

[0032] D x =dx+du

[0033] D y =dy+dv

[0034] Among them, D x D represents the total displacement of the query window on the X-axis. y This represents the total displacement of the query window on the Y-axis.

[0035] As a further aspect of the present invention, the specific process of step S5 is as follows:

[0036] S51, The length direction of the gas flow field is perpendicular to the propagation direction of the reflected light beam; Temperature sensors are arranged on the four sides of the gas flow field to obtain the temperature T at the edge of the gas flow field;

[0037] S52. Substitute the measured temperature T into the ideal gas law to calculate the density ρ of the gas at the edge of the gas flow field:

[0038]

[0039] Where ρ is the density of the leaking gas, P is the standard atmospheric pressure, M is the molar mass of the leaking gas, T is the temperature at the edge of the gas flow field, and R... g It is the ideal gas constant;

[0040] S53. Substitute the gas density into the Glaston-Dale equation to calculate the refractive index of the leaking gas. The Glaston-Dale equation is as follows:

[0041] n=kρ+1

[0042] Where n is the refractive index of the leaked gas, and k is the Glaston-Dale constant.

[0043] As a further aspect of the present invention, the specific process of step S6 is as follows:

[0044] S61. Find the value of Glastondale constant k from the table, substitute it into the solution of the Glastondale equation, and calculate the refractive index of the leaking gas.

[0045] S62. Using the refractive index of the leaked gas as the Dirichlet boundary condition for the refractive index calculation equation, the refractive index calculation equation is as follows:

[0046]

[0047]

[0048] Among them, Z D Z is the distance from the background plate to the center of the gas flow field. I ΔZ is the distance from the CCD camera lens to the imaging plane. D It is half the length of the gas flow field, and n is the refractive index of the leaking gas;

[0049] S63. The central difference method is used to iteratively solve the gas flow field to obtain the refractive index distribution field in the entire flow field, and then the density distribution of the gas flow field can be deduced.

[0050] Compared with the prior art, the beneficial effects of the present invention are:

[0051] This invention provides a two-dimensional gas density distribution measurement method, which can effectively improve the accuracy of leaked gas density calculation. A system was built to study the release behavior of gas leaks under different rupture conditions. The pressure, temperature, and flow rate changes of flammable gas during the leakage process were measured. Furthermore, the morphology of the leaked gas was characterized using background schlieren technology, and the two-dimensional density distribution of the leaked gas was quantitatively calculated. When the concentration of flammable gas is within its upper and lower explosive limits, it is highly likely to ignite and explode upon contact with an open flame. This system provides a basis for comprehensively evaluating the impact of ruptures of different sizes on the release characteristics of flammable gas leaks. Attached Figure Description

[0052] Figure 1 This is a schematic diagram of the structure of the present invention.

[0053] Figure 2 This is a schematic diagram of the experimental apparatus in this invention.

[0054] Figure 3 This is a schematic diagram of the thermocouple installation structure at the edge of the gas flow field in this invention.

[0055] Figure 4 This is a schematic diagram of a reference pattern in this invention.

[0056] Figure 5 This is a schematic diagram of the experimental pattern in this invention.

[0057] Figure 6 This is a schematic diagram of the query window displacement in this invention.

[0058] In the picture:

[0059] 10. Illumination source; 20. Background plate; 30. Gas flow field; 40. Lens; 50. Imaging plane. Detailed Implementation

[0060] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0061] The steps of the measurement method of the present invention are as follows: Figure 1 As shown.

[0062] First, according to Figure 2 The structure described above completes the assembly of the experimental measuring device, and the positions of each component are adjusted. Specific setup data is as follows:

[0063] The distance Z from the center of the background plate 20 to the center of the gas flow field 30 D = 50cm; the distance 50° from the lens of a CCD camera to the imaging plane, i.e., the focal length Z of the CCD camera. I = 1.25cm; the distance Z from the imaging plane 50 to the background plate 20 B =150cm.

[0064] The density of air is 1.0 g / cm³. 3 The experimental gas is low-temperature nitrogen, and its temperature is determined by temperature sensors, specifically thermocouples. Thermocouples are positioned around the perimeter of the gas flow field 30 for temperature detection, as shown in the diagram. Figure 3 As shown, the temperatures are as follows:

[0065] T 01 =25.22℃,T 02 =25.28℃,T 03 = -1.51℃, T 04 =0.67℃,T 05 =17.5℃

[0066] T 11 =25.38℃,T 12 =24.83℃,T 13 =24.8℃

[0067] T 21 =24.65℃,T 22 =23.93℃,T 23 =24.84℃

[0068] T 31 =25.67℃, T 32 =25.53℃,T 33 =25.58℃,T 34 =25.67℃, T 35 =25.78℃

[0069] Substituting all the aforementioned temperatures into the ideal gas law, the density of the gas at the edge of the gas flow field 30 is calculated. Then, these densities are substituted into the Glaston-Dale equation to calculate the refractive index of the gas at the edge of the gas flow field 30, in preparation for subsequent calculations.

[0070] A background plate 20 is placed at a designated optical measurement position, and a CCD camera is installed at a designated shooting position. The illumination light source 10 is turned on, and the beam illuminates the background pattern on the background plate 20 and reflects into the CCD camera. A gas injector for injecting leaked gas is installed at a predetermined position, with the injection direction of the nozzle perpendicularly aligned with the propagation path of the reflected beam.

[0071] The positions of the background plate 20, CCD camera, illumination light source 10, and gas injector are simultaneously adjusted so that the reflected light beam is perpendicularly illuminating the imaging plane 50 of the CCD camera, and the projection of the luminous surface of the background plate 20 along the propagation direction of the reflected light beam is completely aligned with the imaging plane 50 of the CCD camera. At this time, the jet plane generated by the gas injector intersects perpendicularly with the reflected light beam, and the point of perpendicular intersection forms a gas flow field 30.

[0072] The background pattern on background board 20 was generated using a MATLAB random function. The background image size is 297mm × 420mm, and it contains 50,000 dots, which are the white dots in the image. Each dot has a diameter of 1mm. Since the background pattern is the same size as A3 paper, it will be printed on A3 paper, as shown below. Figure 4 As shown.

[0073] The illumination source 10 uses a high-power LED lamp. The light emitted by the LED lamp shines on the background pattern and is reflected to form a reflected beam. The reflected beam shines on the imaging plane 50 of the CCD camera to form a reference pattern.

[0074] exist Figure 2 In the middle, when there is no gas flow field 30, the reflected light shines along the direction of the dotted line; when there is interference from the gas flow field 30, the reflected light shines along the direction of the solid line when it passes through the gas flow field 30.

[0075] In this invention, the CCD camera is mainly divided into two parts: a lens 40 at the lens and an imaging plane 50 installed behind the lens 40. Its imaging principle is the same as that of a conventional camera.

[0076] Turn on all equipment except the gas injector, and use a CCD camera to capture an image of the reflected beam as a reference image, such as... Figure 4 As shown. The acquired reference image is imported into MATLAB software for analysis and processing to obtain the position matrix im1 composed of each light spot:

[0077]

[0078] Next, the gas ejector was turned on to simulate a gas leak. A CCD camera was used to capture images of the reflected light beam from the ejector as experimental images, such as... Figure 5 As shown. The acquired experimental images were imported into MATLAB software for analysis and processing to obtain the position matrix im2 composed of each light spot:

[0079]

[0080] It is worth noting that when the density difference between the leaked gas and air is not very large, it is generally difficult to distinguish them with the naked eye. Figures 4 to 5 Specific changes.

[0081] exist Figure 4 The query window is selected from the reference image, starting from the top left corner and proceeding clockwise until all windows are selected. The coordinates (x0, y0) of each point in the query window in the reference image are recorded. The selected query window is a square with a side length of 64 mm, and the repetition rate of the query window is 0.5.

[0082]

[0083]

[0084] Construct the query window at the corresponding position in the experimental image, observe the position change of the corresponding query window, and record the coordinates (x1, y1) of the point in the query window;

[0085]

[0086]

[0087] Next, import the corresponding image into the MATLAB program to obtain the total displacement change of the query window, as shown in the matrix below:

[0088]

[0089]

[0090] The displacement diagram of each inquiry window is as follows Figure 6 As shown in the figure, the arrows represent displacement vectors.

[0091] The obtained temperature is substituted into the corresponding calculation formula to calculate the corresponding refractive index and density distribution. The calculation process is the same as the selection method of the query window, following the clockwise direction.

[0092] The calculated refractive index matrix is ​​as follows:

[0093]

[0094] The final density matrix is:

[0095]

[0096] The above description is only a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any equivalent substitutions or modifications made by those skilled in the art within the scope of the technology disclosed in the present invention, based on the technical solution and inventive concept of the present invention, should be covered within the scope of protection of the present invention.

Claims

1. A method for measuring the two-dimensional density distribution of leaked gas based on background schlieren technology, characterized in that, Includes the following steps: S1. Set up a background board at the designated optical measurement position and install a CCD camera at the designated shooting position; turn on the illumination light source, so that the light beam shines on the background board and is reflected into the CCD camera; install the gas injector that sprays the leaked gas at the predetermined position and align the nozzle with the propagation path of the reflected light beam. S2. Simultaneously adjust the positions of the background plate, CCD camera, illumination light source, and gas ejector so that the reflected beam is perpendicularly illuminating the imaging plane of the CCD camera, and at the same time, make the projection of the light-emitting surface of the background plate along the propagation direction of the reflected beam completely coincide with the imaging plane of the CCD camera; at this time, the jet plane generated by the gas ejector intersects perpendicularly with the reflected light, and the perpendicular intersection forms a gas flow field. S3. Use a CCD camera to capture an image of the reflected beam when the gas ejector is off as a reference image; use a CCD camera to capture an image of the reflected beam when the gas ejector is in the ejecting state as an experimental image. S4. Compare the changes in the position of the corresponding query window on the reference image and the experimental image, obtain the pixel-level displacement and sub-pixel-level displacement of the query window, and add the pixel-level displacement and sub-pixel-level displacement to calculate the total displacement of the corresponding query window. S5. Detect the temperature at the edge of the gas flow field and substitute the measured temperature into the ideal gas law to calculate the density of the leaking gas at the edge of the gas flow field; substitute the gas density into the Glaston-Dale equation to calculate the refractive index of the leaking gas. S6. Using the refractive index value calculated in S5 as the Dirichlet boundary condition of the refractive index calculation equation, the gas flow field is iteratively solved using the central difference method to obtain the refractive index distribution field in the entire flow field, and then the density distribution of the gas flow field can be deduced.

2. The method for measuring the two-dimensional density distribution of leaked gas based on background schlieren technology according to claim 1, characterized in that, Step S4 is as follows: S41. Establish a Cartesian coordinate system using the intersection of two perpendicular lines in the reference image as the coordinate axes and the intersection point as the origin; select a specified area on the reference image as the query window and record the coordinates of the center point of the query window in the reference image. x 0 ,y 0 ); S42. Construct query windows of the same size at the corresponding positions in the experimental images, observe the positional changes of the query windows, and record the coordinates of the center point of the query window. x 1 ,y 1 ); S43. Use the cross-correlation coefficient to calculate the correlation between the query window in the reference image and the query window in the experimental pattern. The formula for calculating the correlation coefficient is as follows: in, R ( x,y () is the formula for calculating the cross-correlation coefficient. F ( x 0 , y 0 () represents the grayscale distribution of the query window in the reference image. G ( x 1, y 1) Represents the grayscale distribution of the query window in the experimental image; S44. If the calculated cross-correlation coefficient is in the range [0.95, 1], then the query window constructed in the experimental image is correct; otherwise, repeat S42 to S43. S45. Subtract the coordinates of the point in the query window before and after the movement to obtain the pixel-level displacement of the query window: in, dx This represents the pixel-level displacement of the query window on the X-axis. dy The pixel-level displacement of the query window on the Y-axis; S46. Next, use the sub-pixel displacement calculation formula to calculate the sub-pixel displacement of the query window: in, du For the subpixel displacement of the query window on the X-axis, dv This represents the subpixel displacement of the query window on the Y-axis. S47. Finally, add the pixel-level displacement and the sub-pixel-level displacement to obtain the total displacement of the corresponding query window: in, D x This represents the total displacement of the query window on the X-axis. D y This represents the total displacement of the query window on the Y-axis.

3. The method for measuring the two-dimensional density distribution of leaked gas based on background schlieren technology according to claim 2, characterized in that, The specific process of step S5 is as follows: S51. The length direction of the gas flow field is perpendicular to the propagation direction of the reflected light beam; temperature sensors are arranged on the four sides of the gas flow field to obtain the temperature at the edge of the gas flow field. T ; S52, the measured temperature T Substitute these values ​​into the ideal gas law to calculate the density of the gas at the edge of the gas flow field. ρ : in, ρ The density of the leaked gas, P Standard atmospheric pressure M The molar mass of the leaked gas. T The temperature at the edge of the gas flow field. R g It is the ideal gas constant; S53. Substitute the gas density into the Glaston-Dale equation to calculate the refractive index of the leaking gas. The Glaston-Dale equation is as follows: in, n The refractive index of the leaked gas. k This is the Glaston-Dale constant.

4. The method for measuring the two-dimensional density distribution of leaked gas based on background schlieren technology according to claim 3, characterized in that, The specific process of step S6 is as follows: S61. Obtain Glastondale constant from the table. k The value of is substituted into the solution of the Glaston-Dale equation to calculate the refractive index of the leaking gas; S62. Using the refractive index of the leaked gas as the Dirichlet boundary condition for the refractive index calculation equation, the refractive index calculation equation is as follows: in, Z D The distance from the background plate to the center of the gas flow field; Z I This is the distance from the lens of the CCD camera to the imaging plane. ΔZ D It is half the length of the gas flow field. n The refractive index of the leaked gas. Z B This is the distance from the imaging plane to the background plate; S63. The central difference method is used to iteratively solve the gas flow field to obtain the refractive index distribution field in the entire flow field, and then the density distribution of the gas flow field can be deduced.