From: gerard farmar Newsgroups: sci.math.research Subject: Applied problem. Date: 4 Sep 1996 16:45:12 GMT I have the following formula: g(x) = A^((B+x)^C) + D*exp(-E*(ln(x)-ln(F))^2) + GH^x where A,B,C,D,E,F,G and H are constants, and are positive real numbers, and where x is real. I wish to find a differential equation in terms of the function g(x) only (with terms such as df(x)/dx and d^2f(x)/dx^2) for which the above equation is the SOLUTION! (an interesting reversal) A differential equation for each part separated by the plus sign is easy to find. E.g. for f(x)=GH^x df(x)/dx = (ln(H))*f(x) But I have no idea how to do the same for the full expression. Just for background, this formula is a model for human mortality, and the three components are infant mortality, accidental mortality over the late teens and early twenties, and the mortality of ageing. All the parameters are positive real numbers. I need a differential equation for the purpose of "smoothing" some mortality data. I am not ignorant of mathematics, but know very little of the techniques and theory of differential equations. If you can help I'll be very grateful (and you'll get a mention in my master's thesis, for what it is worth!) ============================================================================== From: Peter-Lawrence.Montgomery@cwi.nl (Peter L. Montgomery) Newsgroups: sci.math.research Subject: Re: Applied problem. Date: Wed, 4 Sep 1996 21:06:54 GMT In article <50kbmo$lki@baloo.pipex-sa.net> gerard farmar writes: >I have the following formula: > > g(x) = A^((B+x)^C) + D*exp(-E*(ln(x)-ln(F))^2) + GH^x > >where A,B,C,D,E,F,G and H are constants, and are positive real numbers, >and where x is real. > >I wish to find a differential equation in terms of the function g(x) only >(with terms such as df(x)/dx and d^2f(x)/dx^2) for which the above >equation is the SOLUTION! >(an interesting reversal) > Since you have 8 constants, I assume you want an 8-th order differential equation. Using a symbolic algebra system, we can start with an equation like g(x) - (big expression) = 0. Solve this for one of the constants A, B, ..., H in terms of g(x), x and the other constants. Differentiate both sides of this equation with respect to x. The derivative of the left side is zero, and the derivative of the right gives an equation with fewer constants. Alas, the expressions can get complicated very quickly, And sometimes, such as in g(x) - C*exp(C*x) = 0, you may not be able to solve for the constant C directly, instead manipulating both the equation and its derivative to eliminate C. Here is a Maple program for part of your formula. eq1 := g(x) - c1^((c2 + x)^c3); c3 := solve(eq1, c3); eq2 := simplify(diff(c3, x)); ln_ln_c1 := solve(eq2, ln(ln(c1))); eq3 := simplify(diff(ln_ln_c1, x)/ln(c2 + x)); c2 := solve(eq3, c2); eq4 := factor(numer(simplify(diff(c2, x)))); quit; -- Peter L. Montgomery pmontgom@cwi.nl San Rafael, California Mother: Your room is a mess. Me: I don't see a mess. Mother: You need glasses. ============================================================================== From: rusin@vesuvius.math.niu.edu (Dave Rusin) Newsgroups: sci.math.research Subject: Re: Applied problem. Date: 5 Sep 1996 16:45:09 GMT In article <50kbmo$lki@baloo.pipex-sa.net>, gerard farmar wrote: >I have the following formula: > > g(x) = A^((B+x)^C) + D*exp(-E*(ln(x)-ln(F))^2) + GH^x > >where A,B,C,D,E,F,G and H are constants, and are positive real numbers, >and where x is real. > >I wish to find a differential equation in terms of the function g(x) only >(with terms such as df(x)/dx and d^2f(x)/dx^2) for which the above >equation is the SOLUTION! > >A differential equation for each part separated by the plus sign is easy >to find. E.g. >for f(x)=GH^x > >df(x)/dx = (ln(H))*f(x) > >But I have no idea how to do the same for the full expression. It's not immediately clear from this last comment what you want. I would have assumed from the first statement of the problem that you wanted a single differential equation F(x,y,y',y'',...)=0 which would be satisfied by the given g(x) for _every_ choice of A, B, ..., H; in particular, I assumed you wanted a DE not involving these constants. With that in mind, the appropriate equation for the last comment is f(x) * d^2f(x)/dx^2 = (df(x)/dx)^2. You can, in fact, find a polynomial F of _eleven_ variables with the property that F(x, y, dy/dx, ..., dy^9/dx^9) = 0 for all the functions y=g(x) which you described originally; that is, this is a polynomial 9-th order differential equation. I won't write out this polynomial explicitly but will explain how to find it. I have raised the degree of the DE by one more than expected to include the slightly larger family of functions g(x) = K*A^((B+x)^C) + D*exp(-E*(ln(x)-ln(F))^2) + G*H^x rather than simply those with K=1. This is not generosity on my part. Rather, the simplest differential equation satisfied by all functions y=A^((B+x)^C) is found by letting z=ln(y) and then noting z z' z'' - 2 z z''^2 + (z')^2 z'' = 0 You can of course express this as a DE satisfied by y but this would involve ln(y), taking us away from the simpler polynomial DE's. So I prefer to solve this last equation to say z=((z')^2 z'')/(2 z z''^2 - z' z'''), differentiate, and then substitute z'=y'/y and simplify the numerator. The resulting polynomial equation is linear in y'''', so you may express this differential equation in the form y'''' = F1(y, y', y'', y''') where F1 is a rational function of 4 variables (with constant coefficients). As noted earlier, the third summand of g(x) also satisfies a polynomial DE, which may be written y'' = (y')^2/y = F3(y, y'), again a rational function with constant coefficients. The second summand is just a bit different. Setting z=ln(y) again, we find z' + 3 x z'' + x^2 z''' = 0, where again we may set z'=y'/y to get a DE satisfied by y, a polynomial in y, y', y'', and y''', but this time with coefficients involving x. (One can actually eliminate x as well, at the expense of increasing the degree still further; this does not appear to be something you're interested in.) This time we would write y''' = F2(y, y', y'') where F2 is a rational function of the three variables, whose coefficients are polynomials in x. The next observation is to realize that these equations may in turn be differentiated with respect to x to express the higher derivatives of the functions in terms of the first few. For example, if y3 is the third summand of g(x), then we have seen y3'' = (y3')^2/y3 so that by differentiating and substituting back in we get y3''' = (2 y2 y3' y3'' - (y3')^3) / y3^2 = (y3')^3 / (y3)^2; likewise y3'''' and higher derivatives may be expressed as rational functions of y3 and y3' only. On the other hand, it's clear that the definition of g(x) g(x) = y1 + y2 + y3 may now be differentiated repeatedly to express each of the derivatives g^(n)(x) = (y1)^(n) + (y2)^(n) + (y3)^n, for n=0, 1, ..., 9, as a rational function of the nine functions y1 y1' y1'' y1''' y2 y2' y2'' y3 y3' (and x). Clear denominators if you like, and view these as 10 polynomial equations in 10 + 9 variables: the g^(n) and the above 9 functions. By elimination techniques, you can show that the 10 equations can be solved for the last 9 variables iff a polynomial condition on the other 10 variables is satisfied; equivalently, use resultants to eliminate the last 9 variables from these 10 polynomials, leaving a polynomial involving only g(x), ..., g^(9)(x) (and x itself). This is a polynomial differential equation satisfied by g. Since A through H (and K) have been eliminated, this same DE is satisfied by all functions in the family. I hope you didn't really need this equation explicitly; even writing out F1 in its most compact form would take several lines, so the equation g^(9)(x) = d^5 F1 / dx^5 + d^6 F2 / dx^6 + d^7 F3 / dx^7 is likely to be horrendous. Since in general eliminating a variable from two polynomial equations tends to give a resultant whose degree is the _product_ of the degrees on the starting two polynomials, one could only imagine that the final polynomial differential equation F(x, g, g', ..., g^(9) ) = 0 would have a degree well into the thousands. Any popular symbolic algebra package (e.g. Maple) would have the algorithms to substitute, simplify, differentiate, and eliminate; but the time and memory requirements may be beyond anything available. This is all quite formal, and glosses over some difficulties, such as the possibility that for some functions g in the family, some of the denominators in the rational functions above might vanish identically. dave