# Patent

## Title
Indirect measurement of diluents in a multi-component natural gas

## Abstract

A method of indirectly measuring the diluent (nitrogen and carbon dioxide) concentrations in a natural gas mixture. The molecular weight of the gas is modeled as a function of the speed of sound in the gas, the diluent concentrations in the gas, and constant values, resulting in a model equation. A set of reference gas mixtures with known molecular weights and diluent concentrations is used to calculate the constant values. For the gas in question, if the speed of sound in the gas is measured at three states, the three resulting expressions of molecular weight can be solved for the nitrogen and carbon dioxide concentrations in the gas mixture.

## Background
RELATED PATENT APPLICATION
This application claims the benefit of U.S. Provisional Application No. 60/458,049, filed Mar. 27, 2003 and entitled “Indirect Measurement of Diluents in a Multi-Component Natural Gas”.


GOVERNMENT LICENSE RIGHTS
The U.S. Government has a paid-up license in this invention and the right in certain circumstances to require the patent owner to license others on reasonable terms as provided for by the terms of Contract No. DE-FC21-96MC33033 for the U.S. Department of Energy.


FIELD OF THE INVENTION
This invention relates to the field of measuring constituent components of gas mixtures, and more particularly, to measuring the concentration of diluents in a natural gas mixture.
DESCRIPTION OF THE RELATED ART
The concentration of nitrogen in a gas mixture is difficult to measure directly. Nitrogen has low infrared absorption characteristics, which makes infrared sensing methods difficult. Also, it is chemically inert, which makes electrochemical sensing methods difficult.
Yet, it is often desired to determine the amount of nitrogen in a particular gas mixture. For example, in a natural gas, nitrogen is a diluent and the amount of nitrogen affects heating value. Experimentation has indicated that a plus or minus shift of 0.075 mole % in nitrogen concentration will produce a plus or minus shift of 1.0 BTU/SCF in standard volumetric heating value.
U.S. Pat. No. 6,604,051 B1, entitled “System and Method to Determine Thermophysical Properties of a Multi-Component Gas” and U.S. Pat. No. 6,704,660 entitled “A System and Method to Determine Thermophysical Properties of a Multi-Component Gas at Arbitrary Temperature and Pressure”, to K. Behring and T. Morrow, describe inferential methods for deriving the heating value of natural gas. These methods developed from correlation studies of the heating value of a large number of representative samples of natural gas and three independent physical parameters associated with the gas, namely, the speed of sound at specified pressure and temperature and the fractional concentrations of two diluent gas components (carbon dioxide and molecular nitrogen).
U.S. Pat. No. 6,604,051 B1 further describes various methods for determining the amount of molecular nitrogen in a natural gas sample. These methods are inferential in nature in that the concentration of nitrogen in representative natural gas mixtures, like the gas heating value, is correlated with the speed of sound and the carbon dioxide concentration at two independent thermodynamic states. Inferential nitrogen measurement techniques are further described in U.S. patent application Ser. No. 10/460,579, entitled “Indirect Measurement of Nitrogen in a Multi-Component Natural Gas by Heating the Gas” and in U.S. patent application Ser. No. 10/401,206, entitled “Indirect Measurement of Nitrogen in a Multi-Component Gas by Measuring the Speed of Sound at Two States of the Gas” filed Mar. 27, 2003, both continuations-in-part of U.S. Pat. No. 6,604,051 B1.



BRIEF DESCRIPTION OF THE FIGURES
FIG. 1 illustrates the characteristics of an example of a database for correlating molecular weight of natural gas to the speed of sound in the gas.
FIG. 2 illustrates a method of determining the diluent concentrations in a gas mixture in accordance with the invention.
FIG. 3 illustrates a two-channel diluent measurement system in accordance with the invention.



DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENT
As stated in the Background, U.S. Pat. No. 6,604,051 B1, entitled “System and Method to Determine Thermophysical Properties of a Multi-Component Gas” and U.S. Pat. No. 6,704,660 entitled “A System and Method to Determine Thermophysical Properties of a Multi-Component Gas at Arbitrary Temperature and Pressure”, describe methods for inferentially measuring heating value and energy flow rates of natural gas. U.S. Pat. No. 6,604,051 B1 further describes methods for inferentially measuring nitrogen. The nitrogen measurement methods are further described in U.S. patent application Ser. No. 10/371,419, entitled “Indirect Measurement of Nitrogen in a Multi-Component Natural Gas by Heating the Gas” and in U.S. patent application Ser. No. 10/401,206, entitled “Indirect Measurement of Nitrogen in a Multi-Component Gas by Measuring the Speed of Sound at Two States of the Gas” filed Mar. 27, 2003. These patent applications are incorporated by reference herein.
Two-State Nitrogen Measurement
For inferentially measuring nitrogen, two thermodynamic states may be established by changing the energy status of the test gas from a first state, at a stable and measured temperature and pressure condition, to a second stable and measurable temperature and pressure condition. The measured physical parameters include the pressure at the two states, the temperature at the two states, the speed of sound at the two states, and the carbon dioxide concentration at either state.
As explained below, with a sufficient change in state of the gas, the correlation relationships regarding the nitrogen content are sufficiently independent to yield a quantitative determination of the concentration of nitrogen in the test sample.
For purposes of this description, the gas mixture is assumed to be a natural gas, whose primary diluent components are carbon dioxide and nitrogen. The method is most accurate when the concentration of other diluent gases is low. The method described herein may be extended to other gases containing nitrogen, if those gases behave similarly to natural gases.
For the “two-state” inferential measurement of nitrogen, it is assumed that for the particular gas mixture in question, the speed of sound in the gas and the concentration of carbon dioxide are known or measurable by direct or indirect measurement. The variables, XCo2, XN2, and S represent the carbon dioxide concentration, nitrogen concentration, and speed of sound in the gas, respectively. Temperature and pressure of the gas are represented by T and P. Typically, these measurements are made using a finite gas sample.
The molecular weight of a natural gas mixture of unknown composition is constant for the specific mixture. However, the molecular weight is quantitatively unknown because the gas constituents are not known.
As explained in U.S. Pat. No. 6,604,051 B1, molecular weight of a gas mixture plots semi-linear with sound speed, with the scatter in the data (about 1%) being a function of the diluent concentrations. Molecular weight (MW) may be represented by the following equation, which relates molecular weight to speed of sound and the diluent gas concentrations:

MW=(A+B/S+C/S2)*(1+D*XCO2+E*XN2),  [1]

where MW is the molecular weight of a gas sample.

The constants A, B, C, D, and E are derived from a database containing reference gas mixtures, whose molecular weights are known. These constants are functions of the gas temperature and pressure, but they are not functions of the gas composition.
FIG. 1 summarizes a database composition range for a set of reference gas compositions. U.S. Pat. No. 6,604,051 B1, incorporated by reference above, provides an example of a suitable database, representing 102 unique gas compositions that fall within these ranges. For each reference gas mixture, the speed of sound can be calculated for a matrix of temperature and pressure values. The speed of sound calculations may be performed using commercially available computer software such as SONICWARE, manufactured by Lomic, Inc. By applying statistical methods to the database, values of the constants can be calculated for any given temperature and pressure state.
The database for producing the constant values may also comprise a smaller set of reference gas compositions, selected to be representative of different molecular weights and diluent concentrations. For example, a database of nine reference gas mixtures might comprise three categories of mixtures, one with high molecular weight, one with intermediate molecular weight, and one with low molecular weight. Each category could then comprise three mixtures, such as, one with no diluents, one with nitrogen as the only diluent, and one with carbon dioxide as the only diluent. An example of a suitable diluent concentration for this database would be 2.0 mole % of either nitrogen or carbon dioxide or both. Once a suitable set of reference gases is selected, standard matrix operations for solving algebraic equations can be used to produce values for the constants. For example, the database might comprise nine reference gases, each having a unique value of molecular weight. The sound speeds for each of the nine gases for a range of discrete temperature and pressure values is calculated and stored. As stated above, this calculation can be performed using commercially available software. Then, once the temperature and pressure of the subject natural gas is measured, interpolation can be used to estimate the speed of sound at that state for the reference gases. With nine values of sound speed, nine values of molecular weight, and nine values of CO2 and N2 for the nine reference gases, there is sufficient information to find the values of A, B, C, D and E at that state. As an alternative to storing pre-calculated sound speed values, the sound speeds for the reference gases could be calculated “on the fly” for the measured temperature and pressure, if appropriate programming is incorporated into the run time calculations.
The relations between the molecular weight (MW), the diluent gas concentrations (XN2 and XCO2), and the speed of sound (S) is, for a first thermodynamic state (P1 and T1): 



  
    
      
        MW
        =
        
          
            (
            
              
                A
                1
              
              +
              
                
                  B
                  1
                
                
                  S
                  1
                
              
              +
              
                
                  C
                  1
                
                
                  S
                  1
                  2
                
              
            
            )
          
          ⁢
          
            (
            
              1
              +
              
                
                  D
                  2
                
                ⁢
                
                  X
                  CO2
                
              
              +
              
                
                  E
                  2
                
                ⁢
                
                  X
                  N2
                
              
            
            )
          
        
      
    
    
      
        [
        2
        ]
      
    
  




If the speed of sound measurement is repeated at an additional and different pressure and temperature condition, the corresponding molecular weight expression at P2 and T2 is: 



  
    
      
        MW
        =
        
          
            (
            
              
                A
                2
              
              +
              
                
                  B
                  2
                
                
                  S
                  2
                
              
              +
              
                
                  C
                  2
                
                
                  S
                  2
                  2
                
              
            
            )
          
          ⁢
          
            (
            
              1
              +
              
                
                  D
                  2
                
                ⁢
                
                  X
                  CO2
                
              
              +
              
                
                  E
                  2
                
                ⁢
                
                  X
                  N2
                
              
            
            )
          
        
      
    
    
      
        [
        3
        ]
      
    
  




The second speed of sound measurement can be at a different pressure or temperature or both, as compared to the first speed of sound measurement. A change in either temperature or pressure or both fulfills the requirement that a measurement be made at a different thermodynamic state. If the two states are too close together, especially in pressure, the constants become closer in value and the nitrogen value less determinate.
One of the speed of sound measurements can be at standard temperature and pressure. This speed of sound measurement is referred to as the “standard sound speed”, where standard temperature is 60° F. and standard pressure is 14.73 psia.
For sufficiently accurate and independent measurements of the speed of sound values, S1, and S2, Equations [2] and [3] may be equated to eliminate molecular weight and to solve for the concentration of nitrogen, XN2, in terms of the carbon dioxide concentration, XCO2, 



  
    
      
        
          X
          N2
        
        =
        
          
            
              
                (
                
                  
                    A
                    2
                  
                  +
                  
                    
                      B
                      2
                    
                    
                      S
                      2
                    
                  
                  +
                  
                    
                      C
                      2
                    
                    
                      S
                      2
                      2
                    
                  
                
                )
              
              ⁢
              
                (
                
                  1
                  +
                  
                    
                      D
                      2
                    
                    ⁢
                    
                      X
                      CO2
                    
                  
                
                )
              
            
            -
            
              
                (
                
                  
                    A
                    1
                  
                  +
                  
                    
                      B
                      1
                    
                    
                      S
                      1
                    
                  
                  +
                  
                    
                      C
                      1
                    
                    
                      S
                      1
                      2
                    
                  
                
                )
              
              ⁢
              
                (
                
                  1
                  +
                  
                    
                      D
                      1
                    
                    ⁢
                    
                      X
                      CO2
                    
                  
                
                )
              
            
          
          
            
              
                E
                1
              
              ⁡
              
                (
                
                  
                    A
                    1
                  
                  +
                  
                    
                      B
                      1
                    
                    
                      S
                      1
                    
                  
                  +
                  
                    
                      C
                      1
                    
                    
                      S
                      1
                      2
                    
                  
                
                )
              
            
            -
            
              
                E
                2
              
              ⁡
              
                (
                
                  
                    A
                    2
                  
                  +
                  
                    
                      B
                      2
                    
                    
                      S
                      2
                    
                  
                  +
                  
                    
                      C
                      2
                    
                    
                      S
                      2
                      2
                    
                  
                
                )
              
            
          
        
      
    
    
      
        [
        4
        ]
      
    
  




The separate measurement of the carbon dioxide concentration, obtained from the gas sample at either one of the test states, may now be substituted into the above equation to obtain the molecular nitrogen concentration, XN2.
Three-State Diluent Measurement
By supplementing the two-state measurement method with a third state measurement, the need for measuring the carbon dioxide concentration in the test gas sample is eliminated. Three equations for molecular weight are obtained, and can be solved for both diluent concentrations (nitrogen and carbon dioxide).
FIG. 2 illustrates this “three-state” method of determining the diluent concentrations in a sample of natural gas. Step 20 is storing a database representing a number of gas mixtures whose molecular weights and diluent constituents are known. Step 21 is modeling molecular weight of any gas mixture as a function of the speed of sound in the gas, as described above.
Step 23 is measuring the speed of sound in the gas mixture at a first pressure and temperature. At that state, the equation for molecular weight is:

MW=(A1+B1/S1+C1/S12)*(1+D1*XN2+E1*XCO2)  [5]

In Step 24, values for the constants (A1, B1, . . . ) are calculated, using the reference gas data, which includes sound speed values at the pressure and temperature of this first state, using the techniques described above.
In Step 25, the speed of sound measurement is then repeated at a different state. The molecular weight is then expressed as:

MW=(A2+B2/S2+C2/S22)*(1+D2*XN2+E2*XCO2)  [6]

Step 26 is calculating the constants (A2, B2, . . . ), to obtain a new set of constant values at that state.
Step 27 is repeating the speed of sound measurement at a third thermodynamic state, P3, T3, to yield a third independent molecular weight expression:

MW=(A3+B3/S3+C3/S32)*(1+D3*XN2+E3*XCO2)  [7]

Step 28 is calculating the constants (A3, B3, . . . ), to obtain a new set of constant values at the third state.
Step 29 is using the three molecular weight equations to solve for the diluent concentrations. Equations [5] and [6] may be equated to eliminate molecular weight and to solve for the concentration of nitrogen, XN2, in terms of the carbon dioxide concentration. 



  
    
      
        
          X
          N2
        
        =
        
          
            
              
                (
                
                  
                    A
                    2
                  
                  +
                  
                    
                      B
                      2
                    
                    
                      S
                      2
                    
                  
                  +
                  
                    
                      C
                      2
                    
                    
                      S
                      2
                      2
                    
                  
                
                )
              
              ⁢
              
                (
                
                  1
                  +
                  
                    
                      D
                      2
                    
                    ⁢
                    
                      X
                      CO2
                    
                  
                
                )
              
            
            -
            
              
                (
                
                  
                    A
                    1
                  
                  +
                  
                    
                      B
                      1
                    
                    
                      S
                      1
                    
                  
                  +
                  
                    
                      C
                      1
                    
                    
                      S
                      1
                      2
                    
                  
                
                )
              
              ⁢
              
                (
                
                  1
                  +
                  
                    
                      D
                      1
                    
                    ⁢
                    
                      X
                      CO2
                    
                  
                
                )
              
            
          
          
            
              
                E
                1
              
              ⁡
              
                (
                
                  
                    A
                    1
                  
                  +
                  
                    
                      B
                      1
                    
                    
                      S
                      1
                    
                  
                  +
                  
                    
                      C
                      1
                    
                    
                      S
                      1
                      2
                    
                  
                
                )
              
            
            -
            
              
                E
                2
              
              ⁡
              
                (
                
                  
                    A
                    2
                  
                  +
                  
                    
                      B
                      2
                    
                    
                      S
                      2
                    
                  
                  +
                  
                    
                      C
                      2
                    
                    
                      S
                      2
                      2
                    
                  
                
                )
              
            
          
        
      
    
    
      
        [
        8
        ]
      
    
  




Similarly, Equations [6] and [7] may be equated to eliminate molecular weight and obtain a second equation for nitrogen concentration: 



  
    
      
        
          X
          N2
        
        =
        
          
            
              
                (
                
                  
                    A
                    3
                  
                  +
                  
                    
                      B
                      3
                    
                    
                      S
                      3
                    
                  
                  +
                  
                    
                      C
                      3
                    
                    
                      S
                      3
                      2
                    
                  
                
                )
              
              ⁢
              
                (
                
                  1
                  +
                  
                    
                      D
                      3
                    
                    ⁢
                    
                      X
                      CO2
                    
                  
                
                )
              
            
            -
            
              
                (
                
                  
                    A
                    2
                  
                  +
                  
                    
                      B
                      2
                    
                    
                      S
                      2
                    
                  
                  +
                  
                    
                      C
                      2
                    
                    
                      S
                      2
                      2
                    
                  
                
                )
              
              ⁢
              
                (
                
                  1
                  +
                  
                    
                      D
                      2
                    
                    ⁢
                    
                      X
                      CO2
                    
                  
                
                )
              
            
          
          
            
              
                E
                2
              
              ⁡
              
                (
                
                  
                    A
                    2
                  
                  +
                  
                    
                      B
                      2
                    
                    
                      S
                      2
                    
                  
                  +
                  
                    
                      C
                      2
                    
                    
                      S
                      2
                      2
                    
                  
                
                )
              
            
            -
            
              
                E
                3
              
              ⁡
              
                (
                
                  
                    A
                    3
                  
                  +
                  
                    
                      B
                      3
                    
                    
                      S
                      3
                    
                  
                  +
                  
                    
                      C
                      3
                    
                    
                      S
                      3
                      2
                    
                  
                
                )
              
            
          
        
      
    
    
      
        [
        9
        ]
      
    
  




Then, by eliminating XN2 in the two preceding equations, the carbon dioxide concentration, XCO2, may be expressed in terms of the three measured speeds of sound. That is, the carbon dioxide concentration is expressed as: 



  
    
      
        
          X
          CO2
        
        =
        
          
            [
            
              
                
                  
                    
                      (
                      
                        
                          A
                          1
                        
                        +
                        
                          
                            B
                            1
                          
                          
                            S
                            1
                          
                        
                        +
                        
                          
                            C
                            1
                          
                          
                            S
                            1
                            2
                          
                        
                      
                      )
                    
                    [
                    
                      
                        
                          (
                          
                            
                              A
                              2
                            
                            +
                            
                              
                                B
                                2
                              
                              
                                S
                                2
                              
                            
                            +
                            
                              
                                C
                                2
                              
                              
                                S
                                2
                                2
                              
                            
                          
                          )
                        
                        ⁢
                        
                          (
                          
                            
                              E
                              2
                            
                            -
                            
                              E
                              1
                            
                          
                          )
                        
                      
                      +
                    
                  
                
              
              
                
                  
                    
                      
                        
                          (
                          
                            
                              A
                              3
                            
                            +
                            
                              
                                B
                                3
                              
                              
                                S
                                3
                              
                            
                            +
                            
                              
                                C
                                3
                              
                              
                                S
                                3
                                2
                              
                            
                          
                          )
                        
                        ⁢
                        
                          (
                          
                            
                              E
                              1
                            
                            -
                            
                              E
                              3
                            
                          
                          )
                        
                      
                      ]
                    
                    +
                    
                      (
                      
                        
                          A
                          2
                        
                        +
                        
                          
                            B
                            2
                          
                          
                            S
                            2
                          
                        
                        +
                        
                          
                            C
                            2
                          
                          
                            S
                            2
                            2
                          
                        
                      
                      )
                    
                  
                
              
              
                
                  
                    
                      (
                      
                        
                          A
                          3
                        
                        +
                        
                          
                            B
                            3
                          
                          
                            S
                            3
                          
                        
                        +
                        
                          
                            C
                            3
                          
                          
                            S
                            3
                            2
                          
                        
                      
                      )
                    
                    ⁢
                    
                      (
                      
                        
                          E
                          3
                        
                        -
                        
                          E
                          2
                        
                      
                      )
                    
                  
                
              
            
            ]
          
          
            [
            
              
                
                  
                    
                      (
                      
                        
                          A
                          1
                        
                        +
                        
                          
                            B
                            1
                          
                          
                            S
                            1
                          
                        
                        +
                        
                          
                            C
                            1
                          
                          
                            S
                            1
                            2
                          
                        
                      
                      )
                    
                    [
                    
                      
                        
                          (
                          
                            
                              A
                              2
                            
                            +
                            
                              
                                B
                                2
                              
                              
                                S
                                2
                              
                            
                            +
                            
                              
                                C
                                2
                              
                              
                                S
                                2
                                2
                              
                            
                          
                          )
                        
                        ⁢
                        
                          (
                          
                            
                              
                                E
                                1
                              
                              ⁢
                              
                                D
                                2
                              
                            
                            -
                            
                              
                                E
                                2
                              
                              ⁢
                              
                                D
                                1
                              
                            
                          
                          )
                        
                      
                      +
                    
                  
                
              
              
                
                  
                    
                      
                        
                          (
                          
                            
                              A
                              3
                            
                            +
                            
                              
                                B
                                3
                              
                              
                                S
                                3
                              
                            
                            +
                            
                              
                                C
                                3
                              
                              
                                S
                                3
                                2
                              
                            
                          
                          )
                        
                        ⁢
                        
                          (
                          
                            
                              
                                E
                                3
                              
                              ⁢
                              
                                D
                                1
                              
                            
                            -
                            
                              
                                E
                                1
                              
                              ⁢
                              
                                D
                                3
                              
                            
                          
                          )
                        
                      
                      ]
                    
                    +
                    
                      (
                      
                        
                          A
                          2
                        
                        +
                        
                          
                            B
                            2
                          
                          
                            S
                            2
                          
                        
                        +
                        
                          
                            C
                            2
                          
                          
                            S
                            2
                            2
                          
                        
                      
                      )
                    
                  
                
              
              
                
                  
                    
                      (
                      
                        
                          A
                          3
                        
                        +
                        
                          
                            B
                            3
                          
                          
                            S
                            3
                          
                        
                        +
                        
                          
                            C
                            3
                          
                          
                            S
                            3
                            2
                          
                        
                      
                      )
                    
                    ⁢
                    
                      (
                      
                        
                          
                            E
                            2
                          
                          ⁢
                          
                            D
                            3
                          
                        
                        -
                        
                          
                            E
                            3
                          
                          ⁢
                          
                            D
                            2
                          
                        
                      
                      )
                    
                  
                
              
            
            ]
          
        
      
    
    
      
        [
        10
        ]
      
    
  




The value of XCO2 may then be calculated, using the calculated constant values and the three measured values of speed of sound. This value may then be substituted into either of the nitrogen equations to obtain the value of XN2. Then, the values of XCO2 and XN2 may be substituted into Equation [1], [2] or [3] to obtain the value of the test gas molecular weight, MW.
Diluent Measurement System
FIG. 3 illustrates a two-channel diluent measurement system 300, with which up to four different speed of sound measurements at predetermined and measurable pressures and temperatures may be obtained. System 300 uses two speed of sound sensors 306, one on each of two channels. On each channel, two cascaded pressure regulator valves 302 and 303 and a switched bypass valve 304 are used to change the pressure in the channel.
Each channel operates independently at two different selectable pressures from a common gas supply source. On each channel, the selectable pressures are preset by the two pressure regulator valves 302 and 303 arranged in cascade with the lower pressure regulator 302, located downstream of the higher pressure regulator 303, shunted by a solenoid-operated bypass valve 304. With this arrangement, the pressure conditions in each measurement channel can be quickly and automatically changed from high to low pressure and vice versa, without interaction between the two channels.
One of the measurement channels (Channel 1) operates at the system ambient temperature. The other channel (Channel 2) has an electric heater 305 as part of the speed of sound test chamber 306 to raise the temperature of the gas in that chamber above the system ambient temperature.
An example of a suitable speed of sound sensor 306 is described in U.S. patent application Ser. No. 10/406,518, entitled “Device for Precision Measurement of Speed of Sound in a Gas” and incorporated by reference herein. The speed of sound sensor described therein has a self-contained capillary flow channel made as an intimate part of the chamber for the purpose of equilibrating the gas temperature to that of the chamber prior to measuring the speed of sound.
Both channels of system 300 may be operated with gas flowing through the speed of sound sensors 306, provided that the flow rate does not prevent the gas temperature from equilibrating to the chamber temperature. If a carbon dioxide sensor 307 is desired, it may be located at the exit metering valve 309 of the ambient-temperature speed of sound test channel.
The pressure and temperature test conditions in each measurement channel are relatively arbitrary, but are within the limits for reliable measurement of speed of sound (typically above a few atmospheres pressure or higher). The pressure and temperature values also are sufficiently different to provide adequate differences among the two (or three or four) thermodynamic states used in the test measurements in order to provide distinctive and independent results in the measured speed of sound values and in the subsequent calculations of the diluent gas concentrations and molecular weight. The temperatures in the measurement channels may likewise be relatively arbitrary provided that the heated channel temperature is sufficiently higher than the ambient temperature channel so as to have an independent influence on the measured speeds of sound. The temperatures in the two measuring channels may actually change with time to track any changing ambient temperature conditions caused by variations in environmental temperature at the system installation.
Examples of suitable pressures and temperature ranges for the two measurement channels are:














Channel No. 1:
Channel No. 2:









75 psia < P1 < 1400 psia
75 psia < P2 < 1400 psia



deg F. < T1 = Tamb < 120 deg F.
T2 = Tamb + 40 deg F.










An advantage of the three-state measurement method is that the sensing requirements only involve the measurement of speed of sound at the various preset and accurately measured pressures and temperatures. No other gas sensors are required and the amount of heat energy added to the gas in the heated channel is not required to be known. Likewise, the gas flow rates in the two measuring channels, although preferably set to be approximately equal, may be different from one another and are not required to be known.
Processing unit 310 receives speed of sound, temperature, and pressure measurement from the corresponding sensors of FIG. 3. These inputs are used to calculate only nitrogen or both nitrogen and carbon dioxide concentrations, in accordance with the two-state or three-state methods described above. Processing unit 310 is programmed in accordance with the methods described above. For determining the constant values, processing unit 310 may include a look up table of reference gases and pre-calculated sound speed values as described above, so that the constant values may be determined. Alternatively, processing unit 310 may include stored reference gas compositions and programming for determining sound speed values for the reference gases at the measured temperature and pressure, so that the constants may be determined.
If the three-state inferential method does not provide sufficient accuracy in resolving the individual concentrations of the carbon dioxide and molecular nitrogen diluent gases, carbon dioxide sensor 307 may be used to constrain the concentration, XCO2, as a means for determining the concentration of molecular nitrogen, XN2, with acceptable accuracy. In this case, the speed of sound measurements are required at only two independent energy states in the test gas sample.
The methods described above take the two diluent gases into separate consideration in order to develop the underlying principles for measurements that potentially do not require a measurement of carbon dioxide. If the two diluent gases are not accurately separable by these relationships, substituting a measured value of XCO2 into either of the nitrogen equations to obtain the concentration of molecular nitrogen, XN2, may not yield a suitably accurate result. In that case, an alternate approach is to reformat Equations [1], [2], and [3], with XCO2 and XN2 merged into a single “combined” diluent gas parameter, XDIL, which represents the total diluent gas concentration. By eliminating MW among the equations as before, a value for XDIL can be obtained. Subtracting the measured value of XCO2 from XDIL will yield the concentration of molecular nitrogen, XN2, with a derived value potentially more accurate than that obtainable with the diluent concentration formulas involving separate gas constituent terms.

## Claims

1. A method of determining the diluent concentrations in a natural gas, comprising the steps of:
storing a database representing a number of reference natural gas mixtures whose molecular weights and carbon dioxide and nitrogen concentrations are known;
modeling the molecular weight of a gas mixture as a function of the speed of sound in the gas mixture, the carbon dioxide concentration, the nitrogen concentration, and a set of constant values, thereby obtaining a model equation;
at a first temperature and pressure state of the gas mixture: measuring the speed of sound in the gas mixture, determining the constant values for the gas mixture from the database, and substituting these values into the model equation, thereby obtaining a first equation for the molecular weight of the gas;
at a second temperature and pressure state of the gas mixture: measuring the speed of sound in the gas mixture, determining the constant values for the gas mixture from the database, and substituting these values into the model equation, thereby obtaining a second equation for the molecular weight of the gas;
at a third temperature and pressure state of the gas mixture: measuring the speed of sound in the gas mixture, determining the constant values for the gas mixture from the database, and substituting these values into the model equation, thereby obtaining a third equation for the molecular weight of the gas; and
solving the three equations for the diluent concentrations of the gas.

2. The method of claim 1, wherein at least one of the states is standard temperature and pressure.

3. The method of claim 1, wherein the model equation is expressed as:


MW=(A+B/S+C/S2)*(1+D*XCO2+E*XN2).

4. The method of claim 1, wherein the constant values D and E are further expressed as:


D=D0+D1/S+D2/S2 and E=E0+E1/S+E2/S2.

5. The method of claim 1, wherein the constants are determined by storing pre-calculated speed of sound values for the reference gases for a range of temperature and pressure values, and applying statistical methods to the stored values.

6. The method of claim 1, wherein the constants are determined by storing pre-calculated speed of sound values for the reference gases for a range of temperature and pressure values, interpolating the data to determine speed-of sound at a given state, substituting molecular weight, speed of sound, and diluent concentration values into the model equation for each of the reference gases, and solving the resulting system of equations for the constant values.

7. The method of claim 1, wherein the constants are determined by calculating speed of sound values for the reference gases for the measured temperature and pressure values, substituting molecular weight, speed of sound, and diluent concentration values into the model equation for each of the reference gases, and solving the resulting system of equations for the constant values.

8. A method of determining the combined diluent concentrations in a natural gas, comprising the steps of:
storing a database representing a number of reference gas mixtures whose molecular weights and diluent concentrations are known;
modeling the molecular weight of a gas mixture as a function of the speed of sound in the gas mixture, the diluent concentrations, and a set of constant values, thereby obtaining a model equation;
at a first temperature and pressure state of the gas mixture: measuring the speed of sound in the gas mixture, determining the constant values for the gas mixture from the database, and substituting these values into the model equation, thereby obtaining a first equation for the molecular weight of the gas;
at a second temperature and pressure state of the gas mixture: measuring the speed of sound in the gas mixture, determining the constant values for the gas mixture from the database, and substituting these values into the model equation, thereby obtaining a second equation for the molecular weight of the gas;
at a third temperature and pressure state of the gas mixture: measuring the speed of sound in the gas mixture, determining the constant values for the gas mixture from the database, and substituting these values into the model equation, thereby obtaining a third equation for the molecular weight of the gas; and
solving the three equations for the combined diluent concentrations of the gas.

9. The method of claim 8, further comprising the steps of measuring the carbon dioxide concentration in the gas and subtracting the carbon dioxide concentration from the combined diluent concentration.

10. A two-channel device for measuring the nitrogen concentration in a subject natural gas, comprising:
a first gas flow channel, having a high pressure valve and a low pressure valve, a bypass valve for bypassing at least one of the pressure valves, a speed of sound sensor, a temperature sensor, and a pressure sensor;
a second gas flow channel, having a high pressure valve and a low pressure valve, a bypass valve for bypassing at least one of the pressure valve, a speed of sound sensor, a temperature sensor, and a pressure sensor;
a carbon dioxide sensor for measuring the carbon dioxide concentration in the gas; and
a processing unit for receiving speed of sound measurements from the speed of sound sensors, for receiving temperature and pressure measurements from the temperature and pressure sensors, for receiving the carbon dioxide concentration from the carbon dioxide sensor, for storing reference gas data, and for calculating the nitrogen concentration of the subject natural gas based on the speed of sound measurements, the temperature and pressure measurements, the reference gas data, and the carbon dioxide concentration.

11. The device of claim 10, wherein the processing unit has a look up table for storing pre-calculated speed of sound values for a set of reference gases at a range of temperature and pressure states.

12. The device of claim 10, further comprising a heater for raising the temperature of the gas during sensing by at least one of the speed of sound sensors.

13. A two-channel device for measuring at least one of the diluent concentrations in a natural gas, comprising:
a first gas flow channel, having a high pressure valve and a low pressure valve, a bypass valve for bypassing at least one of the pressure valves, a speed of sound sensor, a temperature sensor, and a pressure sensor;
a second gas flow channel, having a high pressure valve and a low pressure valve, a bypass valve for bypassing at least one of the pressure valves, a speed of sound sensor, a temperature sensor, and a pressure sensor; and
a processing unit for receiving speed of sound measurements for the speed of sound sensors, for receiving temperature and pressure measurements from the temperature and pressure sensors, for storing reference gas data, and for calculating at least one diluent concentration of a subject gas based on the speed of sound measurements, the temperature and pressure measurements, and the reference gas data.

14. The device of claim 13, wherein the processing unit has a look up table for storing pre-calculated speed of sound values for a set of reference gases at a range of temperature and pressure states.

15. The device of claim 13, further comprising a heater for raising the temperature of the gas during sensing by at least one of the speed of sound sensors.