PDA

View Full Version : Alkalinity consumption and linear regression


JHawlz9989
06/15/2012, 10:43 PM
My alkalinity is slowly lowered down to 7, even with dosing saturated limewater. But since all my readings have a standard error because of the Hanna checker, would running a regression analysis on multiple data sets add more standard error, or remove some of the error built into the readings? Since IO salt has a high alkalinity, the new set of data would begin with each water change.

Josh

bertoni
06/15/2012, 11:34 PM
I'm not sure what you mean. Regression analysis might enable you to correlate the measurements to an equation. Error analysis would be an extra step. What are you trying to accomplish?

Duvallj
06/16/2012, 12:30 AM
Comparing multiple analysis wouldn't necessarily add to standard error. However if over time another variable (like seasonality of atmospheric co2/ temperature, coral demands for alk, ect) can skew the magnitude of standard error.


For example you track your alk decline from November to February and find that your alk decline is .5(+/-.1) per day and doesn't seem to change much week to week. However July comes around you find your alk decline is .2(+/-.1) for the month of July.

Something changed, ie you opened all of your windows during the summer months because it was hot. At the same time you decreased the atmospheric co2 concentration around your tank, which contributes to your alk decline.

Here is where standard error matters. If you measure for the whole year you'll find that your standard error will be larger due to your mean drifting (due to some variable, like co2). However if you eliminate that variable, like averaging only weeks where the windows have been shut for some time, you'll find that you'll have a smaller standard error (which ideally would be equal to the error inherent of your test method).

So yes, it could, but you can minimize this.



If you really, really... really (yes, I said it 3 times) wanted a good model you could test for all the factors you think affect your alkalinity. Take those means and do an ANOVA and contribute what part of your standard error goes to which variable and build a better model that way... I suspect however it might take atleast 2 years of data gathering to start to narrow down on a precise model... hence why I started off with saying really alot..

More practically I would try to observe known sources that deplete alk such as coral growth, calcium dosing, atmospheric co2 and do a linear regression in either a 3 month rolling average. After awhile you may just see that it is seasonal, which is what I suspect.

Randy Holmes-Farley
06/16/2012, 06:17 AM
I'm not sure what the goal is, but alkalinity consumption is not necessarily linear in time.

The decline from 11 to 10 dKH is likely a lot faster than the decline from 8 to 7 dKH. :)

JHawlz9989
06/16/2012, 09:02 AM
I'm not sure what you mean. Regression analysis might enable you to correlate the measurements to an equation. Error analysis would be an extra step. What are you trying to accomplish?

I was just wondering if fitting a least squares regression line to my data would provide a more accurate number for alkalinity consumption. I've always enjoyed statistics, so I was hoping I could actually use what I'd learned in school. :spin3:

Comparing multiple analysis wouldn't necessarily add to standard error. However if over time another variable (like seasonality of atmospheric co2/ temperature, coral demands for alk, ect) can skew the magnitude of standard error.

Here is where standard error matters. If you measure for the whole year you'll find that your standard error will be larger due to your mean drifting (due to some variable, like co2). However if you eliminate that variable, like averaging only weeks where the windows have been shut for some time, you'll find that you'll have a smaller standard error (which ideally would be equal to the error inherent of your test method).

So yes, it could, but you can minimize this.



If you really, really... really (yes, I said it 3 times) wanted a good model you could test for all the factors you think affect your alkalinity. Take those means and do an ANOVA and contribute what part of your standard error goes to which variable and build a better model that way... I suspect however it might take atleast 2 years of data gathering to start to narrow down on a precise model... hence why I started off with saying really alot..

More practically I would try to observe known sources that deplete alk such as coral growth, calcium dosing, atmospheric co2 and do a linear regression in either a 3 month rolling average. After awhile you may just see that it is seasonal, which is what I suspect.

The data will be collected over two or three weeks, so variables like that would be negligible, I imagine. Even if I had two years to collect this data, there's no way I could construct a model to really use analysis like that. I wouldn't even know how many variables to add! :uhoh2:

I'm not sure what the goal is, but alkalinity consumption is not necessarily linear in time.

The decline from 11 to 10 dKH is likely a lot faster than the decline from 8 to 7 dKH. :)

So if alkalinity consumption is not linear, I should be adding a quadratic variable then, right?

Thanks for the help guys. I'm probably making this more complicated than it needs to be, but... :crazy1:

Josh

JHawlz9989
06/16/2012, 09:07 AM
One of the reasons for doing this is, even though I am dosing saturated limewater, I still am experiencing some alkalinity consumption. The end goal would be to figure out how much I should be super saturating it. For the last three days, my readings have been 136, 133, and 129 (in ppm). The tank is dosed 1169mL of saturated kalk +/- the error of the BRS doser that I am using.

Randy Holmes-Farley
06/16/2012, 12:10 PM
What do you mean by supersaturating limewater? If normal limewater alone is not enough, a two part may be the next option.


So if alkalinity consumption is not linear, I should be adding a quadratic variable then, right?


If it is so changeable (and it is, varying also with pH), what value is any of this complex mathematical prediction?

It is always a better bet to determine demand by trial and error dosing and maintenance where you want it, rather than observing a drop and then determining what you need. :)

zigzag1
06/16/2012, 12:32 PM
... Something changed, ie you opened all of your windows during the summer months because it was hot. At the same time you decreased the atmospheric co2 concentration around your tank, which contributes to your alk decline. ...

I've always been curious about this relationship. Can someone explain a bit more please? My tank also has seemingly high alk consumption. I use saturated lime water, and a CO2 reactor. And often times (weekly) I still need to add baking soda dissolved in RO/DI to keep the alk up. I do have lots of large hard corals and clams contributing to consumption.

In the months when the house is closed up, I use a homemade CO2 scrubber (soda lime pellets) to keep the pH up too, as it will drift down below 7.8 without the CO2 scrubber. And at times when running the CO2 scrubber especially with fresh media the pH is usually 8.25 or more at night, and 8.3+ during the day.

Am I doing more harm to my alkalinity levels and increasing its consumption with the CO2 scrubber by boosting the pH? As I understand it, alkalinity is the ability to resist changes in pH toward lower values. And IME, hard corals seem healthier in appearance and growth with an alk maintained at 9 dkh or more.

I would be interested to learn more about the relationship of pH and alkalinity consumption. TIA!

Randy Holmes-Farley
06/16/2012, 01:16 PM
Actually, I missed that in the earlier post. Elevated CO2 does not contribute to alkalinity decline. If anything, elevated CO2 lowers pH and that lowers the demand for alkalinity, both from corals and from abiotic precipitation of calcium carbonate. :)

I discuss some of these issues here:

The Relationship Between Alkalinity and pH.
http://www.advancedaquarist.com/issues/may2002/chem.htm


and

A Simplified Guide to the Relationship Between Calcium, Alkalinity, Magnesium and pH
http://reefkeeping.com/issues/2006-06/rhf/index.php

JHawlz9989
06/16/2012, 01:31 PM
What do you mean by supersaturating limewater? If normal limewater alone is not enough, a two part may be the next option.

If it is so changeable (and it is, varying also with pH), what value is any of this complex mathematical prediction?

It is always a better bet to determine demand by trial and error dosing and maintenance where you want it, rather than observing a drop and then determining what you need. :)

"Supersaturating" may have been the incorrect term. By that, I meant using vinegar to increase the limewater's potency.

I figured observing the drop and then determining my needs would have been a better way. I suppose I can do trial and error, instead. :)

Thanks, guys!

Josh

Randy Holmes-Farley
06/16/2012, 01:55 PM
Bear in mind that you will be dosing vinegar and driving bacteria growth. IMO, mixing the two goals this way is tricky as you have two different things you are trying to optimize at once (calcium and alk dosing and vinegar dosing). :)

JHawlz9989
06/16/2012, 02:18 PM
Bear in mind that you will be dosing vinegar and driving bacteria growth. IMO, mixing the two goals this way is tricky as you have two different things you are trying to optimize at once (calcium and alk dosing and vinegar dosing). :)

Thanks, Randy. Per the Bingman article you link to in your article about limewater, I'll start with 3 mL/L of limewater, and go from there.

Josh

http://web.archive.org/web/20030418110415/http:/www.animalnetwork.com/fish2/aqfm/1999/oct/bio/default.asp

Randy Holmes-Farley
06/16/2012, 03:56 PM
OK,

FWIW, 3 ml /L is not much and won't allow much more lime to dissolve into the limewater. 3 tsp per gallon of lime dissolves with about 45 ml vinegar per gallon, but you need to be sure you really want that much vinegar.

good luck! :)