# Another ODE

Benny
Hi can someone please give me some assistance with the following DE? I've posted a few of these questions, hopefully it isn't too much trouble.

$$\frac{{dy}}{{dx}}\frac{{d^3 y}}{{dx^3 }} - 2\left( {\frac{{d^2 y}}{{dx^2 }}} \right)^2 + \left( {\frac{{dy}}{{dx}}} \right)^2 = 0$$

Answer: cosech(Ay+B) +coth (Ay+B) = exp(-x).

I haven't gotten anywhere with this question but here are my thoughts. Normally when I see an equation with products of derivatives I try to 'reverse' the chain rule to see if I can write the LHS as a derivative with respect to the independent variable. However I think that method only works for linear DEs and I don't think this one is linear. Looking at this equation I'd probably substitute $$p = \frac{{dy}}{{dx}}$$. This should give me:

$$p\frac{{d^2 p}}{{dx^2 }} - 2\left( {\frac{{dp}}{{dx}}} \right)^2 + p^2 = 0$$

The book says make the same substitution as I did but the resulting equation seems to suggest that they've treated the equation for the case where the independent variable is not present in an explicit form. The way I've done it assumes that the dependent variable(in this case being y) is missing in an explicit form, which for this equation seems to be true. Anyway, after making the same substitution as I did, according to the book the resulting equation should be:

$$p\frac{{d^2 p}}{{dy^2 }} + 1 = \left( {\frac{{dp}}{{dy}}} \right)^2$$

Basically I'm not really sure how to start this question. Can someone explain what kind of a substitution should be made, how substituted variables should be treated(if understanding of this particular aspect is necessary), and if possible, the reasoning behind the required substitution? Any help would be great, thanks.

Homework Helper
Benny said:
$$p\frac{{d^2 p}}{{dy^2 }} + 1 = \left( {\frac{{dp}}{{dy}}} \right)^2$$

Basically I'm not really sure how to start this question. Can someone explain what kind of a substitution should be made, how substituted variables should be treated(if understanding of this particular aspect is necessary), and if possible, the reasoning behind the required substitution? Any help would be great, thanks.

Hello Benny. When you take the third derivative of y, you need to follow-through with the differentiation all the way to dy/dx:

$$y^{'''}=p\frac{d^2p}{dy^2}\frac{dy}{dx}+\frac{dp}{dy}\frac{dp}{dy}\frac{dy}{dx}$$

Now you should get the book's answer. As far as where to go after that, why not just turn the crank one more time. That is let:

$$p^{'}=v$$

Benny
Thanks for the help Saltydog, I'll try it again.

Homework Helper
Yea, you know I'm gonna' want an IVP out of this at some point. I'm not particular, just any old initial conditions, plot too for that matter. I mean, look at the answer. It's just as complicated as the problem. What do you do with it if you need to calculate a real trajectory of the space shuttle using this ODE?

Benny
Hmm...doing this question and calculating the derivatives, it seems that I've had to make at least one assumption which I'm not sure about the workings of. I'm pretty sure that its just the chain rule but in setting p = dy/dx and calculating the derivatives, it seems that I've assumed that p is a function of y. That is, p = p(y) (loose notation but as long as it's clear what I'm saying it should be fine) and the same assumption is made for all of p's derivatives so that p^(n) = (p^(n))(y).

It makes it a little difficult for me to decide which assumptions I need to make. For instance with the equation:

$$\frac{{d^2 y}}{{dx^2 }} + 2\frac{{dy}}{{dx}} = 4x$$

If I make the substitution p = dy/dx then according to an example if my book I can just write: $$\frac{{dp}}{{dx}} + 2p = 4x$$

Anyway, back to my original question. So I set p = dy/dx with the assumption(this assumption probably already follows from the substitution but I don't understand this stuff well enough to know which is quite a bother) that p is a function of y. That is, p = p(y).

Then by using the definition of the substitution and the chain rule I get:

$$\frac{{d^2 y}}{{dx^2 }} = \frac{d}{{dx}}\left( {p\left( y \right)} \right) = \frac{{dp}}{{dy}}\frac{{dy}}{{dx}} = \frac{{dp}}{{dy}}p = p\frac{{dp}}{{dy}}$$

Applying the chain rule, again with the assumption that the derivative of the above is a function of y:

$$\frac{{d^3 y}}{{dx^3 }} = \frac{d}{{dx}}\left( {p\left( y \right)\frac{{dp}}{{dy}}\left( y \right)} \right)$$

$$= \left( {\frac{{dp}}{{dy}}\frac{{dy}}{{dx}}} \right)\frac{{dp}}{{dy}} + p\left( {\frac{{d^2 p}}{{dy^2 }}\frac{{dy}}{{dx}}} \right)$$

$$= p\frac{{d^2 p}}{{dx^2 }}\frac{{dy}}{{dx}} + \frac{{dy}}{{dx}}\left( {\frac{{dp}}{{dy}}} \right)^2$$

Substituting back into the original DE with p = dy/dx we have:

$$p^3 \frac{{d^2 p}}{{dy^2 }}\frac{{dy}}{{dx}} + p^2 \left( {\frac{{dp}}{{dy}}} \right)^2 - 2p^2 \left( {\frac{{dp}}{{dy}}} \right)^2 + p^2 = 0$$

Dividing through by p^2.

$$p\frac{{d^2 p}}{{dy^2 }} + \left( {\frac{{dp}}{{dy}}} \right)^2 - 2\left( {\frac{{dp}}{{dy}}} \right)^2 + 1 = 0$$

Rearranging:

$$p\frac{{d^2 p}}{{dy^2 }} + 1 = \left( {\frac{{dp}}{{dy}}} \right)^2$$

I'll just submit this part for now.

Last edited:
Benny
Now for this part using your suggestion(which is the same as the book's hint) I set v = dp/dy. For this equation the dependent variable 'p' is clearly present so in this case using my book's examples I have no trouble in realising that the chain rule is required(unlike when I made the substitution p = dy/dx for the original equation which had neither the dependent(y) nor the independent(x) variables present in an explicit form).

With v = dp/dy I get:

$$\frac{{d^2 p}}{{dy^2 }} = \frac{d}{{dy}}\left( {v\left( p \right)} \right) = \frac{{dv}}{{dp}}\frac{{dp}}{{dy}} = v\frac{{dv}}{{dp}}$$

Even though with this part I was more assured as to what I was supposed to do(assume v = v(p)), there was still a bit of guess work involved.

$$p\frac{{d^2 p}}{{dy^2 }} - \left( {\frac{{dp}}{{dy}}} \right)^2 + 1 = 0$$

$$\Rightarrow pv\frac{{dv}}{{dp}} - v^2 + 1 = 0$$

$$pv\frac{{dv}}{{dp}} = v^2 - 1 \Rightarrow \int {\frac{v}{{v^2 - 1}}} dv = \int {\frac{{dp}}{p}} \Rightarrow \frac{1}{2}\log \left| {v^2 - 1} \right| = \log \left| p \right| + c$$

$$\log \left| {\frac{{\sqrt {v^2 - 1} }}{p}} \right| = c \Rightarrow \frac{{\sqrt {v^2 - 1} }}{p} = A$$ where A = exp(c).

$$\sqrt {v^2 - 1} = Ap$$

This is as far as I can get. The final hint given is to get to this point and substitute sinh(theta) = Ap which leads to the answer which I shown in my first post. To me that just came out of nowhere but that's probably because my book assumes knowledge from previous chapters(I've only been using one or two chpaters of the book). I don't know how this substitution can lead to the answer. I've only used trig substitution for integration, never hyperbolic.

Last edited:
Homework Helper
Benny said:
$$pv\frac{{dv}}{{dp}} = v^2 - 1 \Rightarrow \int {\frac{v}{{v^2 - 1}}} dv = \int {\frac{{dp}}{p}} \Rightarrow \frac{1}{2}\log \left| {v^2 - 1} \right| = \log \left| p \right| + c$$

So you have now:

$$v^2-1=Kp^2$$

Turn the crank one more time (well two more times actually).

$$\left(\frac{dp}{dy}\right)^2=Kp^2+1$$

$$\frac{dp}{dy}=\pm \sqrt{Kp^2+1}$$

Just do the positive one for now.

Last edited:
Benny
$$v^2 - 1 = Kp^2$$

$$\left( {\frac{{dp}}{{dy}}} \right)^2 - 1 = Kp^2$$

$$\frac{{dp}}{{dy}} = \sqrt {Kp^2 + 1}$$...taking positive root.

$$\int {\frac{{dp}}{{\sqrt {Kp^2 + 1} }}} = \int {dy}$$

$$\frac{1}{{\sqrt K }}\int {\frac{1}{{\sqrt {p^2 + \frac{1}{K}} }} = } \int {dy}$$ LHS integrate wrtp.

$$\frac{1}{{\sqrt K }}Arc\sinh \left( {\sqrt K p} \right) = y + d$$

$$Arc\sinh \left( {\sqrt K p} \right) = \sqrt K y + f$$

$$p = \frac{{dy}}{{dx}} = \frac{1}{{\sqrt K }}Sinh\left( {\sqrt K y + f} \right)$$

$$\int {\cos ech} \left( {\sqrt K y + f} \right)dy = \frac{1}{{\sqrt K }}\int {dx}$$

$$\int {\frac{{e^{\left( {\sqrt K y + f} \right)} }}{{e^{2\left( {\sqrt K y + f} \right)} - 1}}dy = } \frac{1}{{\sqrt K }}\int {dx}$$

$$\frac{1}{2}\int {\left( {\frac{1}{{e^{\left( {\sqrt K y + f} \right)} + 1}} + \frac{1}{{e^{\left( {\sqrt K y + f} \right)} - 1}}} \right)} dy = \frac{1}{{\sqrt K }}\int {dx}$$

Ok partial fractions won't work so go back to the previous line, LHS. Perhaps substitution might work. Let u = exp(sqrt(K)y+f) => du = sqrt(K)exp(sqrt(k)y+f).

$$I = \int {\frac{{e^{\left( {\sqrt K y + f} \right)} }}{{e^{2\left( {\sqrt K y + f} \right)} - 1}}dy}$$

$$= \frac{1}{{\sqrt k }}\int {\frac{1}{{u^2 - 1}}} du$$

$$= \frac{1}{{2\sqrt K }}\int {\left( {\frac{1}{{u - 1}} - \frac{1}{{u + 1}}} \right)} du$$

$$= \frac{1}{{2\sqrt K }}\log \left| {\frac{{u - 1}}{{u + 1}}} \right|$$

So the equation becomes:

$$\frac{1}{{2\sqrt K }}\log \left| {\frac{{e^{\left( {\sqrt K y + f} \right)} - 1}}{{e^{^{\left( {\sqrt K y + f} \right)} } + 1}}} \right| = \frac{1}{{\sqrt K }}x + g$$

$$\log \left| {\frac{{e^{\left( {\sqrt K y + f} \right)} - 1}}{{e^{^{\left( {\sqrt K y + f} \right)} } + 1}}} \right| = 2x + h$$

$$\frac{{e^{\left( {\sqrt K y + f} \right)} - 1}}{{e^{^{\left( {\sqrt K y + f} \right)} } + 1}} = Le^{2x}$$

$$e^{\left( {\sqrt K y + f} \right)} - 1 = Le^{2x} \left( {e^{^{\left( {\sqrt K y + f} \right)} } + 1} \right)$$

$$e^{\left( {\sqrt K y + f} \right)} - 1 = Le^{2x} \left( {e^{^{\left( {\sqrt K y + f} \right)} } + 1} \right)$$

$$\sqrt K y + f = \log \left( {\frac{{Le^{2x} + 1}}{{1 - Le^{2x} }}} \right)$$

It doesn't look like the expression for 'y' will be an expoential so I must've gone wrong somewhere. This will need to wait for another day, it's 1:00 am where I live. :zzz:

Homework Helper
Benny said:
$$v^2 - 1 = Kp^2$$

$$\left( {\frac{{dp}}{{dy}}} \right)^2 - 1 = Kp^2$$

$$\frac{{dp}}{{dy}} = \sqrt {Kp^2 + 1}$$...taking positive root.

$$\int {\frac{{dp}}{{\sqrt {Kp^2 + 1} }}} = \int {dy}$$

$$\frac{1}{{\sqrt K }}\int {\frac{1}{{\sqrt {p^2 + \frac{1}{K}} }} = } \int {dy}$$ LHS integrate wrtp.

$$\frac{1}{{\sqrt K }}Arc\sinh \left( {\sqrt K p} \right) = y + d$$

$$Arc\sinh \left( {\sqrt K p} \right) = \sqrt K y + f$$

$$p = \frac{{dy}}{{dx}} = \frac{1}{{\sqrt K }}Sinh\left( {\sqrt K y + f} \right)$$

$$\int {\cos ech} \left( {\sqrt K y + f} \right)dy = \frac{1}{{\sqrt K }}\int {dx}$$

I got:

$$\int csch \left[\sqrt{K}(y +c_2)\right]dy = \frac{1}{{\sqrt K }}\int {dx}$$

So that's just:

$$\int csch(ay+b)dy=\int \frac{1}{a}dx$$

You know:

$$\int csch(x)dx=ln\left |tanh(\frac{x}{2})\right |+c$$

I figure we have till Sunday night to get an IVP working; the shuttle is scheduled to lift off Tuesday and that should give them enough time. I'm in no hurry

(hope you catching all these edits to my equations)

Last edited:
Benny
It sure looks like some weird substitutions need to be made sometimes. I remember working through an IVP where I let C = A^5 to avoid introducing complex numbers.:D

$$I_2 = \int {\cos ech\left( {ay + b} \right)} dy$$

$$u = ay + b \Rightarrow du = ady$$

$$I_2 = \frac{1}{a}\int {\cos ech\left( u \right)} du$$

$$= \frac{1}{a}\log \left| {\tanh \left( {\frac{u}{2}} \right)} \right|$$

$$= \frac{1}{a}\log \left| {\tanh \left( {\frac{{ay + b}}{2}} \right)} \right|$$

$$\int {\cos ech\left( {ay + b} \right)} dy = \frac{1}{a}\int {dx}$$

$$\Rightarrow \frac{1}{a}\log \left| {\tanh \left( {\frac{{ay + b}}{2}} \right)} \right| = \frac{x}{a} + c_2$$

$$\Rightarrow \tanh \left( {\frac{{ay + b}}{2}} \right) = De^x$$

I'm thinking that there's an indentity I need to use here but I can't recall/think of any. BTW is the integral of cosech a standard result or is there an easy derivation?

Homework Helper
Benny said:
$$\Rightarrow \tanh \left( {\frac{{ay + b}}{2}} \right) = De^x$$

I'm thinking that there's an indentity I need to use here but I can't recall/think of any. BTW is the integral of cosech a standard result or is there an easy derivation?

The integral of csch(x) I just got off the back cover of my Calculus book (has a list of them). Suppose we could figure it out.

There's two approaches to take here. There is an identity between tanh(x/2) and some other hyberbolic functions that can be used to obtain the answer the book gives. However, that leaves y implicitly defined.

Don't forget that minus sign above that represented another ODE to solve. There's actually three solutions for the general case. Might be more. I'm not sure.

I think it's better to take the inverse hyberbolic tan of both sides to isolate y and obtain an explicit function of y in terms of x. That way, an IVP can be set up to obtain a particular solution, say:

$$\frac{{dy}}{{dx}}\frac{{d^3 y}}{{dx^3 }} - 2\left( {\frac{{d^2 y}}{{dx^2 }}} \right)^2 + \left( {\frac{{dy}}{{dx}}} \right)^2 = 0;\quad y(0)=0,\quad y{'}(0)=1,\quad y^{''}(0)=0$$

Last edited:
Benny
Well if instead I considered the negative root then a quick look through what I did for the positive root, with the appropriate substitutions along the way, gets me to the same implicit answer. The only difference is that the RHS has exp(-x) instead of exp(x). At the moment I can't think of a third solution but seeing that in considering the positive and negative roots I get the same LHS and a LHS with only the sign of the argument of the exponential differing then I get:

$$\tanh \left( {\frac{{ay + b}}{2}} \right) = De^{ \pm x} \Rightarrow y = \frac{2}{a}\arctan h\left( {De^{ \pm x} } \right) - \frac{b}{a}$$

Homework Helper
Benny said:
Well if instead I considered the negative root then a quick look through what I did for the positive root, with the appropriate substitutions along the way, gets me to the same implicit answer. The only difference is that the RHS has exp(-x) instead of exp(x). At the moment I can't think of a third solution but seeing that in considering the positive and negative roots I get the same LHS and a LHS with only the sign of the argument of the exponential differing then I get:

$$\tanh \left( {\frac{{ay + b}}{2}} \right) = De^{ \pm x} \Rightarrow y = \frac{2}{a}\arctan h\left( {De^{ \pm x} } \right) - \frac{b}{a}$$

Ok, anytime you have a homogeneous ODE with nothing but derivatives, then y(x)=c is always another solution right? Although I think this solution is obtained when D=0 above.

Homework Helper
Benny, I've checked my work and I get a slightly different answer than you:

$$y(x)=\frac{2Arctanh[\pm ce^x]-b}{a}$$

Are they equivalent?

Here's the Mathematica code to back-substitute:

Code:
$$y(x)=\frac{2Arctanh[ce^x]-b}{a}$$

yd1[x_] = D[y[x], x];
yd2[x_] = D[y[x], {x, 2}];
yd3[x_] = D[y[x], {x, 3}];

Simplify[yd1[x] yd3[x] - 2 yd2[x]^2 + yd1[x]^2]

Back-substitution returns 0 for $\pm c$ as well as $\pm$ the exponent. They all must be equilivant I suppose although I don't see it immediately.

Last edited:
Benny
I think the step where you have the equation with the logarithm and some variable on the other side, in considering the negative root(further back in the working) the answer will differ depending on how the equation is worked with. As in, for the both postive(in this case it makes no difference) and the negative root, do you manipulate the equation by leaving the negative sign on the RHS or LHS before exponentiating. Having said that, I'm not entirely sure if the answers are equivalent.

Homework Helper
Benny said:
I think the step where you have the equation with the logarithm and some variable on the other side, in considering the negative root(further back in the working) the answer will differ depending on how the equation is worked with. As in, for the both postive(in this case it makes no difference) and the negative root, do you manipulate the equation by leaving the negative sign on the RHS or LHS before exponentiating. Having said that, I'm not entirely sure if the answers are equivalent.

Alright, I see it:

$$sinh(-x)=-sinh(x)$$

I'm just a little slow that's all. And yes, I think the positive and negative exponents represent different solutions. For example, suppose the IVP above had a negative slope as the initial condition? Either I'll post the results of that IVP or you can. But it has to be done by Sunday night. We have a deadline after all.

Benny
$$y = \frac{2}{a}\arctan h\left( {De^{ \pm x} } \right) - \frac{b}{a} \Rightarrow y = \frac{1}{a}\left( {2\arctan h\left( {De^{ \pm x} } \right) - b} \right)$$

$$y' = \frac{1}{a}\left( {\frac{{ \pm De^{ \pm x} }}{{1 - D^2 e^{ \pm 2x} }}} \right)$$

$$y'' = \frac{1}{a}\left( {\frac{{\left( {1 - D^2 e^{ \pm 2x} } \right)\left( \pm \right)^2 De^{ \pm x} \mp De^{ \pm x} \left( { \mp 2D^2 e^{ \pm 2x} } \right)}}{{\left( {1 - D^2 e^{ \pm 2x} } \right)^2 }}} \right)$$

$$y'' = \frac{D}{a}\left( {\frac{{\left( {1 - D^2 e^{ \pm 2x} } \right)\left( \pm \right)^2 e^{ \pm x} \mp e^{ \pm x} \left( { \mp 2D^2 e^{ \pm 2x} } \right)}}{{\left( {1 - D^2 e^{ \pm 2x} } \right)^2 }}} \right)$$

$$y'' = \frac{D}{a}\left( {\frac{{\left( \pm \right)^2 e^{ \pm 2x} - D^2 e^{ \pm 3x} \left( \mp \right)^2 2D^2 e^{ \pm 3x} }}{{\left( {1 - D^2 e^{ \pm 2x} } \right)^2 }}} \right)$$

$$y''' = \frac{D}{a}\left( {\frac{{\left( {1 - D^2 e^{ \pm 2x} } \right)^2 \left( {\left( \pm \right)^3 2e^{ \pm 2x} \mp D^2 e^{ \pm 3x} \left( \mp \right)^3 6D^2 e^{ \pm 3x} } \right) \mp 4\left( {1 - D^2 e^{ \pm 2x} } \right)^2 ...}}{{\left( {1 - D^2 e^{ \pm 2x} } \right)^4 }}} \right)$$

I tried typing out the third derivative but it came out too long.

Just looking at these derivatives(which probably have lots of sign errors) and the original DE, it's going to be pretty difficult to convert this question from one whichr requires a general solution to an IVP. Uni starts on Monday so I probably won't be able to finish this one off because I'll be too busy with assigned questions and such. Perhaps once I get through my first ODE subject I'll be able to do more problems of this type. Thanks for the help you've given.

Homework Helper
Benny, here's the solution to the IVP. I didnt' realize it would involve complex analysis when I proposed it.

Writing the IVP in general terms with initial conditions h,j,k:

$$\frac{{dy}}{{dx}}\frac{{d^3 y}}{{dx^3 }} - 2\left( {\frac{{d^2 y}}{{dx^2 }}} \right)^2 + \left( {\frac{{dy}}{{dx}}} \right)^2 = 0;\quad y(0)=h,\quad y^{'}(0)=j,\quad y^{''}(0)=k$$

We determined the two solutions:

$$y_1(x)=\frac{2 Arctanh(ce^x)-b}{a}$$

$$y_2(x)=\frac{2 Arctanh(ce^{-x})-b}{a}$$

for arbitrary a,b, and c;

Case 1: Solution $y_1(x)$

Solving for a,b and c in terms of h,j and k we obtain:

$$a=\frac{2c}{j(1-c^2)}$$

$$b=2Arctanh(c)-ha$$

$$c=\sqrt{\frac{k-j}{j+k}}$$

Substituting in the values of h,j and k yields:

$$a=i$$

$$b=2Arctanh=\frac{\pi i}{2}$$

$$c=i$$

Now, even though we have complex arguments, the solution is still real-valued as follows:

\begin{align*} 2Arctanh[ie^x]&=ln\left(\frac{1+ie^x}{1-ie^x}\right) \\ &=ln(1+ie^x)-ln(1-ie^x) \\ &=(ln(r)+i\theta_1)-(ln(r)+i\theta_2) \\ &=i(\theta_1-\theta_2) \end{align}

Now:

$$\theta_1=-\theta_2$$

So that:

$$2Arctanh[ie^x]=2i\theta_1$$

Now:

$$\theta_1=Arctan[e^x]$$

Therefore:

$$2Arctanh[ie^x]=2iArctan[e^x]$$

Thus we have:

$$y_1(x)=\frac{2iArctan[e^x]-\frac{i\pi}{2}}{i}=2Arctan[e^x]-\frac{\pi}{2}$$

The first plot is $y_1(x)$. The second plot is a numerical analysis of the IVP. The third plot is a superposition of the two.

#### Attachments

• analytical sol.JPG
4.2 KB · Views: 323
• 3rd order numerical.JPG
4.2 KB · Views: 307
• superposition.JPG
4.2 KB · Views: 336
Benny
Interesting. I'll keep in mind the things you mentioned, might come in handy somewhere down the line.

Homework Helper
You know what, I'm never gonna' understand this stuf. Seriously. How come I get the same answer for this IVP whether I use the first or second solution? The first plot is y1 and the second one is y2. Same dif. Suppose I could go through the complex variable part and show that they're the same. But if they're the same then why have two? I just don't understand it.

Edit: Maybe too my calculations are wrong. I'll double check everything.

#### Attachments

• positive exp.JPG
4.2 KB · Views: 345
• negative exp.JPG
4.4 KB · Views: 355
Last edited:
Homework Helper
Just an update.

I've characterized the behavior of this ODE in terms of the starting values of the first and second derivatives, (j and k above) and have identified three regimes which it exhibits. This is summarized in the map below which separates the j-k plane into a real and complex regime depending on whether the constant "c" in the solution is real or complex. In the complex regime, the solution reaches a plateau (either positive or negative), the size of which is dependent on the difference between j and k. In the real regime, the solution is unbounded with an asymptote that is dependent on the value of c. When j=k, the solution has a limiting value of:

$$y(x)=h+j(e^x-1)$$

With regards to the question I had above. The solutions in the complex regime are identical by virtue of the following identity:

$$Arctan(a)=\frac{\pi}{2}-Arctan(1/a)$$

#### Attachments

• ODE regime.JPG
9.7 KB · Views: 344
Last edited: