LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Estimating exponential decay time constant - taking tangent lines

Solved!
Go to solution

Hello,

 

How would you go about estimating a first order decay time constant? I have a system that loses heat very slowly and I wish to estimate the time constant from the first part of the data to allow for more frequent tests (I know what it will end up decaying to). 

 

I know that I can make a good estimate based on the initial slope of the graph but I don't know how to implement this in LabVIEW. Does anyone know how I can make the VI calculate a tangent line to a graph and find where it intersects another line?

 


Thanks

0 Kudos
Message 1 of 5
(3,722 Views)
Solution
Accepted by topic author ipatka

How about using the

Exponential Fit VI

Owning Palette: Fitting VIs

Requires: Full Development System

Returns the exponential fit of a data set (X, Y) using the Least Square, Least Absolute Residual, or Bisquare method.

 

This VI uses the iterative general Least Square method and the Levenberg-Marquardt method to fit data to an exponential curve of the general form described by the following equation:

f = aebx + c

where x is the input sequence X, a is amplitude, b is damping, and c is offset. This VI finds the values of a, b, and c that best fit the observations (X, Y).

 

 

Greetings from Germany
Henrik

LV since v3.1

“ground” is a convenient fantasy

'˙˙˙˙uıɐƃɐ lɐıp puɐ °06 ǝuoɥd ɹnoʎ uɹnʇ ǝsɐǝld 'ʎɹɐuıƃɐɯı sı pǝlɐıp ǝʌɐɥ noʎ ɹǝqɯnu ǝɥʇ'


0 Kudos
Message 2 of 5
(3,697 Views)

Thank you! I had tried this before but I had an exponential decay that didn't die out to zero. This was causing weird results with the damping indicator. I solved it by subtracting the vertical offset from all of my values so it died out to zero and now it correctly gets the time constant.

0 Kudos
Message 3 of 5
(3,687 Views)

guess what the c is for 😉

Greetings from Germany
Henrik

LV since v3.1

“ground” is a convenient fantasy

'˙˙˙˙uıɐƃɐ lɐıp puɐ °06 ǝuoɥd ɹnoʎ uɹnʇ ǝsɐǝld 'ʎɹɐuıƃɐɯı sı pǝlɐıp ǝʌɐɥ noʎ ɹǝqɯnu ǝɥʇ'


Message 4 of 5
(3,670 Views)
Ah....I feel foolish
0 Kudos
Message 5 of 5
(3,663 Views)