Go Down

Topic: CO2 ppmv & ppmw math (Read 3623 times) previous topic - next topic

mistergreen

Hi folks.
Anybody here knows CO2 atmospheric math?
I'm using this sensor to measure CO2.
http://www.co2meter.com/collections/co2-sensors/products/k-30-3-co2-sensor
It measures CO2 in ppm by volume aka atmosphere.
What I'm using it for is to measure CO2 concentration in water which is measured in ppm by weight.

This is what I have so far.
Code: [Select]

double co2 = K_30.getCO2('p') * 3; //returns co2 value in ppm ('p') or percent ('%')
 
  //there's a glitch sometimes with the sensor output
  if(co2 >= 0 && co2 <= 30000) {
      co2 = co2 * 0.8317 * 44.01 / 10000;
      //  quicker than co2/1000000 * 0.8317 * 44.01 / 1000000
      //  0.8317 accounts for Henry's Law
      // max ppmw will be 36.6 with 10,000 ppmv
  }



The sensor floats on the waterline detecting any CO2 bouncing out of the water. Do I even need to account for Henry's law?
Is the math right?

el_supremo

I don't see how you can relate the concentration of CO2 in air to the concentration of CO2 in water. In particular, I don't see how you can differentiate between the "CO2 bouncing out of the water" and the CO2 already in the air.

Pete

mistergreen

#2
Mar 24, 2014, 04:03 am Last Edit: Mar 24, 2014, 01:48 pm by mistergreen Reason: 1
Co2 is co2. I'm trying to convert ppmv to ppmw like how to convert Celsius to Fahrenheit . Just measurements.

robtillaart

Can you explain what your code does ?
And what is Henry's law?
Rob Tillaart

Nederlandse sectie - http://arduino.cc/forum/index.php/board,77.0.html -
(Please do not PM for private consultancy)

mistergreen

#4
Mar 25, 2014, 10:34 pm Last Edit: Mar 25, 2014, 10:36 pm by mistergreen Reason: 1
Henry's law has some to do with finding the concentration of a gas in water based on the amount of the gas bouncing out of the water i.e. gas concentration above the water.
The math for it is super complicated.

But In my wiki search I thought I found the constant 0.8317 is good enough for CO2, assuming normal water density (not salt water etc) and temp of 70F.
http://en.wikipedia.org/wiki/Henry's_law
-------------------------------------------------------

ppm is parts per million or
ppm(volume) = mg/L
ppm(weight) = molar weight/1000 kg/m^3

1000 kg/m^3 is the density of water and can be substituted with 1000000 mg/L to get the formula simplified.

for my thought to get the weight of it would be
co2_weight = co2_volume/1000000 * .8317 (henry's) * 44.01 (mole weight of CO2) / 1000000

el_supremo

The wiki page on Henry's Law says that the law does not apply when the gas reacts chemically with the solvent and gives the specific example of carbon dioxide and water which form carbonic acid. So you can't use Henry's Law.

Pete

mistergreen


The wiki page on Henry's Law says that the law does not apply when the gas reacts chemically with the solvent and gives the specific example of carbon dioxide and water which form carbonic acid. So you can't use Henry's Law.

Pete


Thanks!

zoomx

From Wikipedia
http://en.wikipedia.org/wiki/Carbonic_acid
Quote
When carbon dioxide dissolves in water it exists in chemical equilibrium producing carbonic acid:[2]
CO2 + H2O is in equilibrium with H2CO3
The hydration equilibrium constant at 25°C is called Kh, which in the case of carbonic acid is [H2CO3]/[CO2] ? 1.7×10?3 in pure water[3] and ? 1.2×10?3 in seawater.[4] Hence, the majority of the carbon dioxide is not converted into carbonic acid, remaining as CO2


I believe that you can still use Henry Law.

michinyon

The ability of the dissolved carbon dioxide to leave the water,  depends on a lot of things,  including the temperature,  the pH,  the amount of CO2 in the water,  how much you shake the bottle,   what other gases are present in the water and above it,   and how quickly the carbon dioxide that leaves the water can disperse into the atmosphere.
I am unconvinced that measuring the atmospheric concentration above the water,   can actually tell you very much that is meaningful about the concentration in the water, at all.

zoomx

I believe that mistergreen wants to measure dissolved CO2 in a fish tank.

Delta_G

If you want to measure the CO2 concentration in a fish tank that's way easy.  You don't measure it directly.  You measure carbonate alkalinity and pH and the CO2 concentration can be had from there via a very simple set of equations.   


zoomx

Measuring pH in a continuous mode is not a simple task. Usually sensors degrade with time because the liquid junction between the electrode and the liquid to measure and you need to recalibrate the meter very often because of the sensor drift.

I believe that mistergreen wants to measure dissolved CO2 in a fish tank in continuous mode.

michinyon

Assuming you had a stable setup where the amount of air circulation in the room,   and other such factors were controlled,  then you might be able to observe some variations in the atmospheric concentration of CO2 just above the water surface.   But I don't think you will see much variation.  Gases diffuse pretty fast.

But anyway, supposing you can detect variations,  you would need to make a series of measurements of the water concentration using the carbonate method,   and the atmospheric test,    and observe whatever correlation there might be,  or not.  If you actual get a useable correlation,  then use that for your process control.  Good luck.

Go Up