AnsweredAssumed Answered

vrf Regression

Question asked by bill.ossmann on Aug 3, 2003
Georg,

You have a good idea, one that I have used in other circumstances, but your linear form is not equivalent to the original. The problem is that

ln(1-exp(-t/C1)) does not equal -ln(exp(-t/C1)) as in your second formula.

Now if we were to differentiate the original and then take the logarithm, we would get something in a linear form:

Q  = C0 (1-exp(-t/C1))
dQ/dt  = (C0/C1)* (exp(-t/C1))
ln(dQ/dt) = ln(C0/C1) - t/C1

This equation is of the form y = m*x + n with
    y = ln(dQ/dt), m = 1/C1  and n = ln(C0/C1)

This has gotten us a method, but not one I would trust blindly. For one thing, differentiating can greatly exacerbate any noise problems, and requires fine sampling to get a reasonable approximation. Also, this sort of transformation is no longer a true
least squares fit, but it is often close enough. What you really want is something that will minimize

SUM( (Data(n) - C0(1-exp(-t(n)/C1)))^2 )

The Matlab function fmins will do this, but you need to write the sum of squares function to be minimized and have installed real Matlab on your machine so you can call user-written functions. A couple of years ago I wrote a VEE version of the fmins
routine, but I'm not sure how general it is. I could dig it up if there is interest. Alternatively, there are commercial curve-fitting routines available that may have Active-X interfaces, but I know almost nothing about them.

--
Bill Ossmann
Philips Ultrasound
e-mail:  bill.ossmann@philips.com





                                                   To:   "VEE vrf" <vrf@it.lists.it.agilent.com>
                                                   cc:   (bcc: Bill Ossmann/ANR/MS/PHILIPS)
                                                   Subject:    [vrf] Re: Regression

               <g.nied@gn-software.de>             Classification:

               08/02/2003 02:09
               Please respond to g.nied






Hello Ali,

to solve your regression, first transform your formula to a linear form:

       Q  = C0 (1-exp(-t/C1))              (1)

    ln(Q) = ln(C0) - ln(exp(-t/c1))

          = ln(C0) + t/C1                  (2)


This equation is of the form y = m*x + n with
    y = ln(Q), m = 1/C1  and n = ln(C0)

now make a linear regression with your (t,ln(Q)) data pairs and find the slope m and offset n.

>From the results you can get your coefficients c0 = exp(n) and c1 = 1/m


best regards,

G. Nied

-------------------------------------------------------------------------
Georg Nied  - Software-Development - Hansestr.7 - 51149 Cologne - Germany
Tel: +49 2203 9770915 - Fax: +49 2203 9770924 - eMail:info@gn-software.de
-------------------------------------------------------------------------




Original Message                                                                 processed by Tobit InfoCenter

Subject:                                 [vrf] Regression (01-Aug-2003 15:36)

From:                                    majed.ali@se.abb.com

To:                                      vrf@it.lists.it.agilent.com




Hi,

I have experimental data which can be solved by such equation, C0(1-e-t/C1). How can I use the regression object to get the coefficients of the equation.

Any feedback would be appreciated.

Majed Ali --- You are currently subscribed to vrf as: g.nied@gn-software.de To subscribe send a blank email to "join-vrf@it.lists.it.agilent.com". To unsubscribe send a blank email to "leave-vrf@it.lists.it.agilent.com". To send messages to this mailing
list, email "vrf@it.lists.it.agilent.com". If you need help with the mailing list send a message to "owner-vrf@it.lists.it.agilent.com".


To: majed.ali@se.abb.com
    vrf@it.lists.it.agilent.com
---
You are currently subscribed to vrf as: bill.ossmann@philips.com
To subscribe send a blank email to "join-vrf@it.lists.it.agilent.com".
To unsubscribe send a blank email to "leave-vrf@it.lists.it.agilent.com".
To send messages to this mailing list, email "vrf@it.lists.it.agilent.com".
If you need help with the mailing list send a message to "owner-vrf@it.lists.it.agilent.com".





---
You are currently subscribed to vrf as: rsb@soco.agilent.com
To subscribe send a blank email to "join-vrf@it.lists.it.agilent.com".
To unsubscribe send a blank email to "leave-vrf@it.lists.it.agilent.com".
To send messages to this mailing list,  email "vrf@it.lists.it.agilent.com". 
If you need help with the mailing list send a message to "owner-vrf@it.lists.it.agilent.com".

Outcomes