Drift stability algorithms

I am currently looking for one or more algorithms in detecting a stable drift in the voltage/potential of a electrical measure device. I have googled a bit but I am having problems finding something relevant.

I must admit that drift is a relative new term for me, so there are perhaps some concepts which has eluded me concerning this topic. For the moment if there exists well known algorithms, just list their names and I will see if I can look them up somehow. I appreciate any help.

[499 byte] By [herrena] at [2007-10-2 10:46:04]
# 1
Hi Herren,Do you mean something like a PID (Proportional-Integral-Derivative) controller/algorithm?Maybe this is of interest to you: http://forum.java.sun.com/thread.jspa?threadID=677295
prometheuzza at 2007-7-13 2:58:41 > top of Java-index,Other Topics,Algorithms...
# 2

I do not think PID controller what I am looking for (but I could be wrong). Lets use an example.

Say we want to do a chemical titration, using chemical A (acid) and chemical B (base). In chemical A there is an pH-electrode.

We pour a certain volume of Chemical B in Chemical A. The pH increases and the measured values with the pH-electrode follows roughly a graph f(x)=1-e^(-x), which means the pH increases until a certain stability has been reach. When the measurement-drift has reached a certain stability-threshold, all measurement before this threshold are discarded, and a mean-value is computed and returned. Now we have a pH-reading and we can pour more of chemical B in chemical A.

I believe in PID control you already know the target value, which is not the case here.

I have found one calculation which is supposed to be good for detecting a stable drift.

Say we have measured values X1,...,Xn, with time t1,...,tn, where t1 is an offset relative to tn, and tn ist the last measured time. First we make a linear regression getting the values XX1,...XXn. Now we compute a standard deviation

std1 = sqrt( (sum(|X1-XX1|,|Xn-XXn|))^2/(n-1))

Now we compute regression of second degree, getting XXX1,...,XXXn, and its corresponding standard deviation (std2).

If |std1-std2| < threshold, then we have a stable drift.

Now there is a possibility of having a drift which is constantly increasing or decreasing. The start of the graph could look entirely different, with possibly a maxima and a minima value before going into a stable drift, but that is another story.

herrena at 2007-7-13 2:58:41 > top of Java-index,Other Topics,Algorithms...