Converting a problem solved with numerical analysis to a simple exponential

bill.connelly
Messages
21
Reaction score
0
I'm just a neuroscientist, so forgive me if the answer to this question is either obvious, or the answer is that it is impossible, obviously.

Basically, this image should outline the question clearly
http://img713.imageshack.us/img713/2569/mathsissuefixedyxs.gif
(And Y0 is always 1)Also, I tried just fitting an exponential to the output. For instance, if I set Y0=1, i = 1, k = 1 and D=0.5, then the output is explained by the curve Yn = (1 - 0.7746)*e^(1.693 * t) + 0.7746 so I can't see the relation, between the fit constants constants in the numerical method

Oh, and just in case anyone is confused about the exponential recovery process equation
yn = (y(n-1) * D) + (1 - y(n-1) * D) * (1 - e^(-k*i))
I modeled it after the general equation for exponential recovery
Y = initial value + (asymptote - initial value) * (1 - e^(-k*x))
 
Last edited by a moderator:
Physics news on Phys.org
Your difference equation is of the form y(n) = A*y(n-1) + B, where y(0) = 1.

The solution I get is y(n) = A^n + B/(1-A)

I'm guess the A<1 in your case, since the solution decreases? I have assumed that A is not 1.

But I may have made a mistake. I used the common method of first finding the solution to the homogeneous equation (B=0), and then find a particular solution of the inhomogeneous equation.

Torquil
 
Okay... and how do your constants of A and B relate to my constants Y0, i, k and D?
 
Last edited:
A = De^(-k i)

B = 1 - e^(-k i)
 
Interesting... the seems to match very closely apart from the fact that the initial value is not 1, i.e. when n = 1
 
bill.connelly said:
Interesting... the seems to match very closely apart from the fact that the initial value is not 1, i.e. when n = 1

The general solution is:

y(n) = K A^n + B/(1-A)

where K is some arbitrary constant that you can adjust to get the correct initial value. Putting n = 1 gives

y(1) = K A + B/(1-A) --->

K = [y(1) - B/(1-A)]/A
 
Ah, excellent. That is amazing!

How complicated does it get if between events, instead of the process recoverying with a single exponential, it recovery with a bi-exponential

i.e. the equation for the second event would be

Y=Y1*D + (1-Y1*D)*PercentFast*(1-exp(-KFast*i)) + (1-Y1*D)*(1-PercentFast)*(1-exp(-KSlow*i))
 
Is that too hard to calculate the difference equation for? Is it likely there is another forum that someone might be able to do it?
 
As far as I can see, this is still of the same form y(n+1) = A*y(n) + B, so the solution is the same, only with other values of A and B. A is everything that multiplies y(n) on the right hand side of your equation, and B is the rest.

Torquil
 
Back
Top