Gas blender Toolkit, wrong calculation?

Please register or login

Welcome to ScubaBoard, the world's largest scuba diving community. Registration is not required to read the forums, but we encourage you to join. Joining has its benefits and enables you to participate in the discussions.

Benefits of registering include

  • Ability to post and comment on topics and discussions.
  • A Free photo gallery to share your dive photos with the world.
  • You can make this box go away

Joining is quick and easy. Log in or Register now!

I am sure the GERG-2004 model is much better researched than the Subsurface calculation (which is not really a model) and has much broader applicability. It is a model because it has a theoretical background (and justification for all the possible terms).

I should say, however, that research into these equations of state is mainly motivated by applications to the oil and gas drilling industry. Thus it is likely that their models are optimized for pressure/temperature/gas mixture values that are relevant there and which probably differ from those relevant to filling scuba cylinders at room temperature with breathing gases.

For us the only relevant variable is the compressibility for trimix mixes between 1 and 300 bar at room temperature. But at least for the three component gases He, O2 and N2 this is simply measured and tabulated and all the Subsurface calculation does is to interpolate these tabulated values. It makes a simple assumption about the compressibility of a mixture like trimix (namely that you can take the weighted average of the compressibilities of the components) but besides that, there is no theoretical justification, simply a pragmatic fit to the actual data.

I am pretty sure that this should be good enough for diving and blending applications.
 
I tried the following on a couple of programs:
desired mix: 18/45
start pressure: 1 bar of air, end pressure: 232bar

+ helium+ oxygen+ airfinal mix
MultiDeco107.4 bar (108.4 bar)19.3 bar (127.7 bar)104.3 bar (232 bar)18/45 232 barT=293K, z-factors correction
Gas blender toolkit99.0 bar (100 bar)19.2 bar (119.2 bar)112.8 bar (232 bar)18/45 232 barT=293K, vdW
Real gas blender109.9 bar (110.9 bar)19.1 bar (130.0 bar)102 bar (232 bar)18/45 232 barT=300K, real gas corrected
Scubadoctor104 bar (105 bar)19 bar (124 bar)108 bar (232 bar)18/45 232 barrounded values?
ideal gas104.4 bar (105.4 bar)18.6 bar (124 bar)108 bar (232 bar)18/45 232 barideal gas calculation

So which one is the best pick?

As far as I know, the pressures should be calculated with compressibility factors, which are unfortunately not linear for air.
Oxygen is not much of a problem, which is probably why those values in the table are close together.
Z-factors.png

Unfortunately I don't have the factors for helium, although helium seems to be linear according to some 60-year old research:
Screenshot 2021-12-22 at 02.15.39.png
 
Replied and didn't see the answer already there, ignore this.
 
So which one is the best pick?
Just on general credibility grounds, I'd be more inclined to rely on @atdotde and Real Gas Blender.

But this is an everyday occurrence for some of us (and me soon, I hope, when I get my lonely Haskel all connected). There is a big enough difference between, say, Gas Blender Toolkit (which I unfortunately just bought) and Real Gas Blender that I bet someone could tell us from actual experience, given the number of blenders on SB.

Anyone able to comment?
 
Just on general credibility grounds, I'd be more inclined to rely on @atdotde and Real Gas Blender.

But this is an everyday occurrence for some of us (and me soon, I hope, when I get my lonely Haskel all connected). There is a big enough difference between, say, Gas Blender Toolkit (which I unfortunately just bought) and Real Gas Blender that I bet someone could tell us from actual experience, given the number of blenders on SB.

Anyone able to comment?
My experience is that MultiDeco is spot on when you set the correct temperature and fill slow enough to keep the temperature as stable as possible. MultiDeco uses z-factor corrections.

The differences between Real Gas Blender and MultiDeco are in those z-factors used to correct the calculated ideal gas pressure to a real-world gas pressure.

Z-values have been empirically determined, and fitting such a table into a formula has been done with coefficients:
z-factor = c + c1 * P + c2 * P^2 + c3 * P^3 + c4 * P^4​
z-factor = c + c1 * P + c2 * P^2 + c3 * P^3​
rounded values of these coefficients are shown below.

4th order polynomial for compressibility curves (Atomox):
cc1c2c3c4
O21.00E+00-5.07E-058.58E-091.44E-12-2.12E-16
He1.00E+003.70E-05-7.14E-10-8.30E-141.89E-17
N21.00E+00-2.11E-051.55E-08-6.22E-13-6.54E-17
Air1.00E+00-2.62E-051.32E-089.05E-14-1.27E-16
3rd order polynomial used by SubSurface:
cc1c2c3
O21.00E+00-7.18E-042.82E-06-1.50E-09
He1.00E+004.87E-04-8.84E-085.33E-11
N21.00E+00-2.19E-04-8.84E-08-2.08E-09

But....these z-values are estimates, they divert a lot from the empirical values, and there's no temperature correction.

I'm trying to squeeze the blending formulas into a microprocessor, with a temperature correction. So I will stick with the z-factor tables. Tables for air, oxygen and nitrogen are easy to find. Helium is a more challenging quest. The linearity of helium z-factors is supposedly 1+0.00045*P (in bar) at a temperature of 300K. BAUE has a table on their website which seems to use 1+0.000499*P at an unknown temperature.

Lots of available research data is for temperatures below 160K, I'm looking for temperatures in the range of 273K - 320K.
@Storker looked into this about a year ago. Maybe our chemical engineer can share his opinion?
 
Helium is a more challenging quest. The linearity of helium z-factors is supposedly 1+0.00045*P (in bar) at a temperature of 300K. BAUE has a table on their website which seems to use 1+0.000499*P at an unknown temperature.

Lots of available research data is for temperatures below 160K, I'm looking for temperatures in the range of 273K - 320K.
@Storker looked into this about a year ago. Maybe our chemical engineer can share his opinion?

Not a chemical engineer, but I think depending on the edition Perry does have a Helium table at various isotherms.

For pure Helium you can extract the compressibility for an arbitrary isotherm from GREG-2004, which agrees well with the "Thermophysical Properties of Fluid Systems" in the NIST Chemistry WebBook. The helium page for the webbook references McCarty, R.D.; Arp, V.D., A New Wide Range Equation of State for Helium., Adv. Cryo. Eng., 1990, 35, 1465-1475. When searching for the title there also appears to be a 'recent' thesis from 2010. I think all of these sources support using a linear z factor, though there is clearly a temperature dependence for the slope.

The part that's still the most unclear to me is what the most theoretically justified z factor is for a helium mixture. I don't know for sure there is a trivial combination of the equation of states, though I think GREG-2004 does at least provide some justification for their mixing model.
 
I'm trying to squeeze the blending formulas into a microprocessor, with a temperature correction. So I will stick with the z-factor tables. Tables for air, oxygen and nitrogen are easy to find. Helium is a more challenging quest. The linearity of helium z-factors is supposedly 1+0.00045*P (in bar) at a temperature of 300K. BAUE has a table on their website which seems to use 1+0.000499*P at an unknown temperature.

Lots of available research data is for temperatures below 160K, I'm looking for temperatures in the range of 273K - 320K.
@Storker looked into this about a year ago. Maybe our chemical engineer can share his opinion?
Me, I'd try the vdW equation with suitable a and b values for your T/P range. As far as I understand, that polynomial model you're referring to doesn't consider temperature. The vdW equation does.

Completely disregarding the fact that there's no way in heck we can measure the temperature in our tanks with even half-acceptable accuracy. Unless they've been left on the filling station floor for about a day, in which case we can fairly safely assume they are at ambient temperature.
 
Completely disregarding the fact that there's no way in heck we can measure the temperature in our tanks with even half-acceptable accuracy. Unless they've been left on the filling station floor for about a day, in which case we can fairly safely assume they are at ambient temperature.
True. However, the supply banks are stationary. With a temperature sensor on each tank in the bank and a pressure gauge, the amount of transferred gas can still be calculated.
 
I created quite big list of blender software here:
IIRC PP Mixer v3.0 is using GREG 2004
 
https://www.shearwater.com/products/perdix-ai/
http://cavediveflorida.com/Rum_House.htm

Back
Top Bottom