1
$\begingroup$

I should prefix this with a warning: I'm a programmer, not a mathematician, and I have a liberal arts background. I know just enough to be confused. Be gentle!

I'm looking for a class of functions to model a process which starts at 0 ($f(0) = 0$), and whose growth decays in proportion to $\frac{1}{2^x}$ while asymptotically approaching a particular value.

My first stab was $c-\frac{c}{2^{1-x}}$. This meets the basic requirement as far as I can tell, but I have an additional constraint to add. I want $f'(0) = c$.

I realised that this would be true if the derivative of the function was $\frac{c}{2^x}$. When I integrated that using an online integral calculator, I got: $$−\frac{c}{ln(2)⋅2^x}+C$$ That gave me the right derivative at 0, but it now approaches zero from $-1.442696c$. This is where I got stuck. I've tried adding in various correction factors, both to the function and its derivative, but I can't seem to find something that both meets the requirement to start at 0 and approach c asymptotically, AND have a derivative $f'()$ such that $f'(0) = c$.

Is this impossible? Am I missing something very obvious. Sorry if I've mangled the maths here, I'm struggling at the limits of my understanding :-(

EDIT: To try and clarify further, here's some more concrete detail. This is modelling charging a battery bank. At the start of the relevant charge stage, the current going in is (say) 50 amps (this is my derivative). The battery bank needs 100 amp hours put in to be fully charged, but the rate at which it will accept reduces in proportion to its charge level. When the battery bank is 50% charged (50 amp hours), it will only accept half the original current (25amps). As time goes by, it will get closer and closer to a theoretical 100% charge state and the rate at which it accepts current will trend towards zero. The starting current has a fixed relationship to the size of the battery bank. For the sake of the discussion so far I've said that the two are equal, but in fact the starting current in amps is usually 0.5 times the size of the bank in amp hours. I'm looking for a function that will give me a charge state in amp hours if I give it a time in hours.

$\endgroup$
  • $\begingroup$ I'm not sure to understand what you want but, if you take for the constant $C$ the value asymptotically approached by the function, id doesn't work?. $\endgroup$ – Emilio Novati Mar 9 '17 at 8:08
  • $\begingroup$ What do you mean by "in proportion to" when talking about how the growth decays? $\endgroup$ – Shinja Mar 9 '17 at 9:26
  • $\begingroup$ By "in proportion to" I just meant that I wanted the decay to follow that basic shape - it could be a multiple of $1/2^x$ or offset by a constant - providing that the shape of the curve was essentially the same. $\endgroup$ – hollandlef Mar 10 '17 at 9:15
1
$\begingroup$

Without loss of generality, $c=1$.

What you want to achieve is not possible with a function of the form

$$f(x)=a-b\,2^{-x}$$ because you are setting three conditions for only two parameters:

$$f(0)=0\to a=b,\\f(\infty)=1\to a=1,\\f'(0)=1\to b\log 2=1.$$

There are several possibilites to fix that, by adding terms such as $x2^{-x}$ or $2^{-2x}$... but you have to give additional criteria.


From the new problem description, it seems that the current is proportional to the remaining capacity, giving the differential equation

$$\frac{dU}{dt}=C-U,$$ which has the solution

$$U=C(1-e^{-t}).$$

This indeed gives $U(0)=0,U'(0)=C$ and $U(\infty)=C$, but the decay is not a power of $2$ but a power of $e$.

$\endgroup$
  • $\begingroup$ Why do you suppose $c=f(\infty)=f'(0)$ ? $\endgroup$ – JJacquelin Mar 10 '17 at 11:14
  • 1
    $\begingroup$ Because this is in the question. But once again, having two different values wouldn't make a solution more possible. Thanks for the downvote. $\endgroup$ – Yves Daoust Mar 10 '17 at 11:17
  • $\begingroup$ I believe that you have understood the problem correctly; if another term is needed, that's fine. I have tried to lay out the concrete problem I'm trying to solve in an edit to my question, perhaps that will help determine what an additional term should be. $\endgroup$ – hollandlef Mar 10 '17 at 14:16
  • $\begingroup$ @ Yves Daoust. From the last comment send by hollandlef to my answer, it is now clear that you are right. My interpretation of the initial wording of the problem was wrong. So I delete my answer and ill try to withdraw the downvote if possible. Sorry for the misunderstanding. $\endgroup$ – JJacquelin Mar 10 '17 at 16:02
  • 1
    $\begingroup$ @ Yves Daoust. Apparently it is not possible to withdraw a downvote except if the downvoted answer has been modified meanwhile. $\endgroup$ – JJacquelin Mar 10 '17 at 16:11

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.