how to solve this first order nonlinear differential equation
$begingroup$
I'm reading nonlinear control systems book. The author provides this example
$$
dot{x} = r + x^2, quad r < 0.
$$
I would like to compute the analytical solution for the proceeding ODE. My attempt is
$$
begin{align}
frac{dx}{dt} &= r + x^2 \
frac{dx}{r+x^2} &= dt \
int^{x(t)}_{x_0} frac{1}{r+x^2} dx &= int^{t}_{t_0} dtau \
frac{tan^{-1}left(frac{x}{sqrt{r}}right)}{sqrt{r}} Big|^{x(t)}_{x_0} &= (t-t_0)
end{align}
$$
Now the problem with the assumption that $r<0$, how I can handle the substitution for the left side? I need to reach the final step where $x(t)$ is solely in the left side.
ordinary-differential-equations nonlinear-system
$endgroup$
|
show 3 more comments
$begingroup$
I'm reading nonlinear control systems book. The author provides this example
$$
dot{x} = r + x^2, quad r < 0.
$$
I would like to compute the analytical solution for the proceeding ODE. My attempt is
$$
begin{align}
frac{dx}{dt} &= r + x^2 \
frac{dx}{r+x^2} &= dt \
int^{x(t)}_{x_0} frac{1}{r+x^2} dx &= int^{t}_{t_0} dtau \
frac{tan^{-1}left(frac{x}{sqrt{r}}right)}{sqrt{r}} Big|^{x(t)}_{x_0} &= (t-t_0)
end{align}
$$
Now the problem with the assumption that $r<0$, how I can handle the substitution for the left side? I need to reach the final step where $x(t)$ is solely in the left side.
ordinary-differential-equations nonlinear-system
$endgroup$
1
$begingroup$
Substitute $u = frac{x}{sqrt{-r}}$. You'll get an inverse hyperbolic tangent.
$endgroup$
– Christoph
Jan 30 at 6:16
1
$begingroup$
So it is $x^2 - a^2$ at the bottom. Could use partial fractions.
$endgroup$
– Arctic Char
Jan 30 at 6:16
$begingroup$
@Christoph, why did you put the minus ? Also, how to handle the square root of negative number?
$endgroup$
– CroCo
Jan 30 at 6:21
1
$begingroup$
If $r<0$ you have $-r>0$, so you can take the square root of that.
$endgroup$
– Christoph
Jan 30 at 6:22
1
$begingroup$
$-a^2=r$, so $a$ is the square root of the positive number $-r$.
$endgroup$
– Hans Lundmark
Jan 30 at 6:23
|
show 3 more comments
$begingroup$
I'm reading nonlinear control systems book. The author provides this example
$$
dot{x} = r + x^2, quad r < 0.
$$
I would like to compute the analytical solution for the proceeding ODE. My attempt is
$$
begin{align}
frac{dx}{dt} &= r + x^2 \
frac{dx}{r+x^2} &= dt \
int^{x(t)}_{x_0} frac{1}{r+x^2} dx &= int^{t}_{t_0} dtau \
frac{tan^{-1}left(frac{x}{sqrt{r}}right)}{sqrt{r}} Big|^{x(t)}_{x_0} &= (t-t_0)
end{align}
$$
Now the problem with the assumption that $r<0$, how I can handle the substitution for the left side? I need to reach the final step where $x(t)$ is solely in the left side.
ordinary-differential-equations nonlinear-system
$endgroup$
I'm reading nonlinear control systems book. The author provides this example
$$
dot{x} = r + x^2, quad r < 0.
$$
I would like to compute the analytical solution for the proceeding ODE. My attempt is
$$
begin{align}
frac{dx}{dt} &= r + x^2 \
frac{dx}{r+x^2} &= dt \
int^{x(t)}_{x_0} frac{1}{r+x^2} dx &= int^{t}_{t_0} dtau \
frac{tan^{-1}left(frac{x}{sqrt{r}}right)}{sqrt{r}} Big|^{x(t)}_{x_0} &= (t-t_0)
end{align}
$$
Now the problem with the assumption that $r<0$, how I can handle the substitution for the left side? I need to reach the final step where $x(t)$ is solely in the left side.
ordinary-differential-equations nonlinear-system
ordinary-differential-equations nonlinear-system
asked Jan 30 at 6:07


CroCoCroCo
271221
271221
1
$begingroup$
Substitute $u = frac{x}{sqrt{-r}}$. You'll get an inverse hyperbolic tangent.
$endgroup$
– Christoph
Jan 30 at 6:16
1
$begingroup$
So it is $x^2 - a^2$ at the bottom. Could use partial fractions.
$endgroup$
– Arctic Char
Jan 30 at 6:16
$begingroup$
@Christoph, why did you put the minus ? Also, how to handle the square root of negative number?
$endgroup$
– CroCo
Jan 30 at 6:21
1
$begingroup$
If $r<0$ you have $-r>0$, so you can take the square root of that.
$endgroup$
– Christoph
Jan 30 at 6:22
1
$begingroup$
$-a^2=r$, so $a$ is the square root of the positive number $-r$.
$endgroup$
– Hans Lundmark
Jan 30 at 6:23
|
show 3 more comments
1
$begingroup$
Substitute $u = frac{x}{sqrt{-r}}$. You'll get an inverse hyperbolic tangent.
$endgroup$
– Christoph
Jan 30 at 6:16
1
$begingroup$
So it is $x^2 - a^2$ at the bottom. Could use partial fractions.
$endgroup$
– Arctic Char
Jan 30 at 6:16
$begingroup$
@Christoph, why did you put the minus ? Also, how to handle the square root of negative number?
$endgroup$
– CroCo
Jan 30 at 6:21
1
$begingroup$
If $r<0$ you have $-r>0$, so you can take the square root of that.
$endgroup$
– Christoph
Jan 30 at 6:22
1
$begingroup$
$-a^2=r$, so $a$ is the square root of the positive number $-r$.
$endgroup$
– Hans Lundmark
Jan 30 at 6:23
1
1
$begingroup$
Substitute $u = frac{x}{sqrt{-r}}$. You'll get an inverse hyperbolic tangent.
$endgroup$
– Christoph
Jan 30 at 6:16
$begingroup$
Substitute $u = frac{x}{sqrt{-r}}$. You'll get an inverse hyperbolic tangent.
$endgroup$
– Christoph
Jan 30 at 6:16
1
1
$begingroup$
So it is $x^2 - a^2$ at the bottom. Could use partial fractions.
$endgroup$
– Arctic Char
Jan 30 at 6:16
$begingroup$
So it is $x^2 - a^2$ at the bottom. Could use partial fractions.
$endgroup$
– Arctic Char
Jan 30 at 6:16
$begingroup$
@Christoph, why did you put the minus ? Also, how to handle the square root of negative number?
$endgroup$
– CroCo
Jan 30 at 6:21
$begingroup$
@Christoph, why did you put the minus ? Also, how to handle the square root of negative number?
$endgroup$
– CroCo
Jan 30 at 6:21
1
1
$begingroup$
If $r<0$ you have $-r>0$, so you can take the square root of that.
$endgroup$
– Christoph
Jan 30 at 6:22
$begingroup$
If $r<0$ you have $-r>0$, so you can take the square root of that.
$endgroup$
– Christoph
Jan 30 at 6:22
1
1
$begingroup$
$-a^2=r$, so $a$ is the square root of the positive number $-r$.
$endgroup$
– Hans Lundmark
Jan 30 at 6:23
$begingroup$
$-a^2=r$, so $a$ is the square root of the positive number $-r$.
$endgroup$
– Hans Lundmark
Jan 30 at 6:23
|
show 3 more comments
4 Answers
4
active
oldest
votes
$begingroup$
Let $r=-a^2$. Then
$$intfrac{dx}{x^2-a^2}=int dt$$
$$-frac{log{left( x+aright) }-log{left( x-aright) }}{2 a}=t+c$$
Take $c=frac{log C}{2a}$.
$$log{left( frac{x-a}{C, left( x+aright) }right) }=2 a t,$$
$$frac{x-a}{x+a}=C, {{e}^{2 a t}}.$$
General solution is
$$x=frac{a(1+Ce^{2at})}{1-Ce^{2at}}.$$
$endgroup$
add a comment |
$begingroup$
Let us consider
$$dot x=x^2-1$$ for convenience.
When $|x|<1$, we solve the separable equation with
$$frac{dx}{1-x^2}=-dt$$ and
$$text{artanh }x-text{artanh }x_0=t_0-t,$$
i.e.
$$x=tanh(t_0-t+text{artanh }x_0).$$
When $|x|>1$, we solve with
$$text{arcoth }x-text{arcoth }x_0=t_0-t,$$
i.e.
$$x=coth(t_0-t+text{arcoth }x_0).$$
Notice that this solution has a vertical asymptote at $t=t_0+text{arcoth }x_0$.
Finally, $x=pm1$ are two valid solutions.
$endgroup$
add a comment |
$begingroup$
Solve it as Riccati equation by setting $x=-frac{u'}{u}$. Then
$$
u''-a^2u=0
$$
has the solution $u(t)=Ce^{at}+De^{-at}$ and thus
$$
y(x)=-afrac{Ce^{at}-De^{-at}}{Ce^{at}+De^{-at}}
$$
with some redundancy in the parameter pair $(C,D)$.
$endgroup$
add a comment |
$begingroup$
We use separation of variables to solve the ODE $dot{x} = r + x^2$, $r < 0$:
We first find the constant solutions $x equiv pm sqrt{-r}$. In the following steps we shall assume $r+x^2 not equiv 0$.
We use the Leibniz notation and we separate the variables: $frac{dx}{dt} = r + x^2$, $frac{1}{r+x^2} dx = dt$.
We integrate on both sides: $int frac{1}{r+x^2} , mathrm{d}x = int 1 , mathrm{d}t$.
We solve the integral on the left-hand side using the substitution $x = sqrt{-r} u$, $dx = sqrt{-r} du$:
begin{eqnarray}
int frac{1}{r+x^2} , mathrm{d}x &=& int frac{1}{r-ru^2} sqrt{-r} , mathrm{d}u = frac{sqrt{-r}}{r} int frac{1}{1-u^2} , mathrm{d}u = frac{sqrt{-r}}{r} left{ begin{array}{ll}
operatorname{artanh}(u) + tilde{C}, & |u| < 1\
operatorname{arcoth}(u) + tilde{C}, & |u| > 1
end{array}
right.\
&=& frac{sqrt{-r}}{r} left{ begin{array}{ll}
operatorname{artanh}left(frac{x}{sqrt{-r}}right) + tilde{C}, & |x| < sqrt{-r}\
operatorname{arcoth}left(frac{x}{sqrt{-r}}right) + tilde{C}, & |x| > sqrt{-r}
end{array}
right., quad tilde{C} in mathbb{R}.
end{eqnarray}
Thus we now obtain the nonlinear equations
begin{eqnarray}
operatorname{artanh}left(frac{x}{sqrt{-r}}right) = C -sqrt{-r} t, quad |x| < sqrt{-r},\
operatorname{arcoth}left(frac{x}{sqrt{-r}}right) = C -sqrt{-r} t, quad |x| > sqrt{-r},
end{eqnarray}
with a constant $C in mathbb{R}$.
Finally, we obtain 4 possible solutions of the ODE, depending on the initial value $x(t_0) = x_0 in mathbb{R}$:
begin{eqnarray}
x(t) &=& sqrt{-r} cothleft(operatorname{arcoth}left(frac{x_0}{sqrt{-r}}right)-sqrt{-r}(t-t_0)right), quad |x_0| > sqrt{-r},\
x(t) &=& -sqrt{-r}, quad x_0 = -sqrt{-r},\
x(t) &=& sqrt{-r}, quad x_0 = sqrt{-r},\
x(t) &=& sqrt{-r} tanhleft(operatorname{artanh}left(frac{x_0}{sqrt{-r}}right)-sqrt{-r}(t-t_0) right), quad |x_0| < sqrt{-r}.
end{eqnarray}
$endgroup$
add a comment |
Your Answer
StackExchange.ifUsing("editor", function () {
return StackExchange.using("mathjaxEditing", function () {
StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix) {
StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["$", "$"], ["\\(","\\)"]]);
});
});
}, "mathjax-editing");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "69"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
noCode: true, onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3093160%2fhow-to-solve-this-first-order-nonlinear-differential-equation%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
4 Answers
4
active
oldest
votes
4 Answers
4
active
oldest
votes
active
oldest
votes
active
oldest
votes
$begingroup$
Let $r=-a^2$. Then
$$intfrac{dx}{x^2-a^2}=int dt$$
$$-frac{log{left( x+aright) }-log{left( x-aright) }}{2 a}=t+c$$
Take $c=frac{log C}{2a}$.
$$log{left( frac{x-a}{C, left( x+aright) }right) }=2 a t,$$
$$frac{x-a}{x+a}=C, {{e}^{2 a t}}.$$
General solution is
$$x=frac{a(1+Ce^{2at})}{1-Ce^{2at}}.$$
$endgroup$
add a comment |
$begingroup$
Let $r=-a^2$. Then
$$intfrac{dx}{x^2-a^2}=int dt$$
$$-frac{log{left( x+aright) }-log{left( x-aright) }}{2 a}=t+c$$
Take $c=frac{log C}{2a}$.
$$log{left( frac{x-a}{C, left( x+aright) }right) }=2 a t,$$
$$frac{x-a}{x+a}=C, {{e}^{2 a t}}.$$
General solution is
$$x=frac{a(1+Ce^{2at})}{1-Ce^{2at}}.$$
$endgroup$
add a comment |
$begingroup$
Let $r=-a^2$. Then
$$intfrac{dx}{x^2-a^2}=int dt$$
$$-frac{log{left( x+aright) }-log{left( x-aright) }}{2 a}=t+c$$
Take $c=frac{log C}{2a}$.
$$log{left( frac{x-a}{C, left( x+aright) }right) }=2 a t,$$
$$frac{x-a}{x+a}=C, {{e}^{2 a t}}.$$
General solution is
$$x=frac{a(1+Ce^{2at})}{1-Ce^{2at}}.$$
$endgroup$
Let $r=-a^2$. Then
$$intfrac{dx}{x^2-a^2}=int dt$$
$$-frac{log{left( x+aright) }-log{left( x-aright) }}{2 a}=t+c$$
Take $c=frac{log C}{2a}$.
$$log{left( frac{x-a}{C, left( x+aright) }right) }=2 a t,$$
$$frac{x-a}{x+a}=C, {{e}^{2 a t}}.$$
General solution is
$$x=frac{a(1+Ce^{2at})}{1-Ce^{2at}}.$$
answered Jan 30 at 6:41


Aleksas DomarkasAleksas Domarkas
1,62317
1,62317
add a comment |
add a comment |
$begingroup$
Let us consider
$$dot x=x^2-1$$ for convenience.
When $|x|<1$, we solve the separable equation with
$$frac{dx}{1-x^2}=-dt$$ and
$$text{artanh }x-text{artanh }x_0=t_0-t,$$
i.e.
$$x=tanh(t_0-t+text{artanh }x_0).$$
When $|x|>1$, we solve with
$$text{arcoth }x-text{arcoth }x_0=t_0-t,$$
i.e.
$$x=coth(t_0-t+text{arcoth }x_0).$$
Notice that this solution has a vertical asymptote at $t=t_0+text{arcoth }x_0$.
Finally, $x=pm1$ are two valid solutions.
$endgroup$
add a comment |
$begingroup$
Let us consider
$$dot x=x^2-1$$ for convenience.
When $|x|<1$, we solve the separable equation with
$$frac{dx}{1-x^2}=-dt$$ and
$$text{artanh }x-text{artanh }x_0=t_0-t,$$
i.e.
$$x=tanh(t_0-t+text{artanh }x_0).$$
When $|x|>1$, we solve with
$$text{arcoth }x-text{arcoth }x_0=t_0-t,$$
i.e.
$$x=coth(t_0-t+text{arcoth }x_0).$$
Notice that this solution has a vertical asymptote at $t=t_0+text{arcoth }x_0$.
Finally, $x=pm1$ are two valid solutions.
$endgroup$
add a comment |
$begingroup$
Let us consider
$$dot x=x^2-1$$ for convenience.
When $|x|<1$, we solve the separable equation with
$$frac{dx}{1-x^2}=-dt$$ and
$$text{artanh }x-text{artanh }x_0=t_0-t,$$
i.e.
$$x=tanh(t_0-t+text{artanh }x_0).$$
When $|x|>1$, we solve with
$$text{arcoth }x-text{arcoth }x_0=t_0-t,$$
i.e.
$$x=coth(t_0-t+text{arcoth }x_0).$$
Notice that this solution has a vertical asymptote at $t=t_0+text{arcoth }x_0$.
Finally, $x=pm1$ are two valid solutions.
$endgroup$
Let us consider
$$dot x=x^2-1$$ for convenience.
When $|x|<1$, we solve the separable equation with
$$frac{dx}{1-x^2}=-dt$$ and
$$text{artanh }x-text{artanh }x_0=t_0-t,$$
i.e.
$$x=tanh(t_0-t+text{artanh }x_0).$$
When $|x|>1$, we solve with
$$text{arcoth }x-text{arcoth }x_0=t_0-t,$$
i.e.
$$x=coth(t_0-t+text{arcoth }x_0).$$
Notice that this solution has a vertical asymptote at $t=t_0+text{arcoth }x_0$.
Finally, $x=pm1$ are two valid solutions.
edited Jan 30 at 10:14
answered Jan 30 at 10:03
Yves DaoustYves Daoust
132k676229
132k676229
add a comment |
add a comment |
$begingroup$
Solve it as Riccati equation by setting $x=-frac{u'}{u}$. Then
$$
u''-a^2u=0
$$
has the solution $u(t)=Ce^{at}+De^{-at}$ and thus
$$
y(x)=-afrac{Ce^{at}-De^{-at}}{Ce^{at}+De^{-at}}
$$
with some redundancy in the parameter pair $(C,D)$.
$endgroup$
add a comment |
$begingroup$
Solve it as Riccati equation by setting $x=-frac{u'}{u}$. Then
$$
u''-a^2u=0
$$
has the solution $u(t)=Ce^{at}+De^{-at}$ and thus
$$
y(x)=-afrac{Ce^{at}-De^{-at}}{Ce^{at}+De^{-at}}
$$
with some redundancy in the parameter pair $(C,D)$.
$endgroup$
add a comment |
$begingroup$
Solve it as Riccati equation by setting $x=-frac{u'}{u}$. Then
$$
u''-a^2u=0
$$
has the solution $u(t)=Ce^{at}+De^{-at}$ and thus
$$
y(x)=-afrac{Ce^{at}-De^{-at}}{Ce^{at}+De^{-at}}
$$
with some redundancy in the parameter pair $(C,D)$.
$endgroup$
Solve it as Riccati equation by setting $x=-frac{u'}{u}$. Then
$$
u''-a^2u=0
$$
has the solution $u(t)=Ce^{at}+De^{-at}$ and thus
$$
y(x)=-afrac{Ce^{at}-De^{-at}}{Ce^{at}+De^{-at}}
$$
with some redundancy in the parameter pair $(C,D)$.
answered Jan 30 at 8:09
LutzLLutzL
60.2k42057
60.2k42057
add a comment |
add a comment |
$begingroup$
We use separation of variables to solve the ODE $dot{x} = r + x^2$, $r < 0$:
We first find the constant solutions $x equiv pm sqrt{-r}$. In the following steps we shall assume $r+x^2 not equiv 0$.
We use the Leibniz notation and we separate the variables: $frac{dx}{dt} = r + x^2$, $frac{1}{r+x^2} dx = dt$.
We integrate on both sides: $int frac{1}{r+x^2} , mathrm{d}x = int 1 , mathrm{d}t$.
We solve the integral on the left-hand side using the substitution $x = sqrt{-r} u$, $dx = sqrt{-r} du$:
begin{eqnarray}
int frac{1}{r+x^2} , mathrm{d}x &=& int frac{1}{r-ru^2} sqrt{-r} , mathrm{d}u = frac{sqrt{-r}}{r} int frac{1}{1-u^2} , mathrm{d}u = frac{sqrt{-r}}{r} left{ begin{array}{ll}
operatorname{artanh}(u) + tilde{C}, & |u| < 1\
operatorname{arcoth}(u) + tilde{C}, & |u| > 1
end{array}
right.\
&=& frac{sqrt{-r}}{r} left{ begin{array}{ll}
operatorname{artanh}left(frac{x}{sqrt{-r}}right) + tilde{C}, & |x| < sqrt{-r}\
operatorname{arcoth}left(frac{x}{sqrt{-r}}right) + tilde{C}, & |x| > sqrt{-r}
end{array}
right., quad tilde{C} in mathbb{R}.
end{eqnarray}
Thus we now obtain the nonlinear equations
begin{eqnarray}
operatorname{artanh}left(frac{x}{sqrt{-r}}right) = C -sqrt{-r} t, quad |x| < sqrt{-r},\
operatorname{arcoth}left(frac{x}{sqrt{-r}}right) = C -sqrt{-r} t, quad |x| > sqrt{-r},
end{eqnarray}
with a constant $C in mathbb{R}$.
Finally, we obtain 4 possible solutions of the ODE, depending on the initial value $x(t_0) = x_0 in mathbb{R}$:
begin{eqnarray}
x(t) &=& sqrt{-r} cothleft(operatorname{arcoth}left(frac{x_0}{sqrt{-r}}right)-sqrt{-r}(t-t_0)right), quad |x_0| > sqrt{-r},\
x(t) &=& -sqrt{-r}, quad x_0 = -sqrt{-r},\
x(t) &=& sqrt{-r}, quad x_0 = sqrt{-r},\
x(t) &=& sqrt{-r} tanhleft(operatorname{artanh}left(frac{x_0}{sqrt{-r}}right)-sqrt{-r}(t-t_0) right), quad |x_0| < sqrt{-r}.
end{eqnarray}
$endgroup$
add a comment |
$begingroup$
We use separation of variables to solve the ODE $dot{x} = r + x^2$, $r < 0$:
We first find the constant solutions $x equiv pm sqrt{-r}$. In the following steps we shall assume $r+x^2 not equiv 0$.
We use the Leibniz notation and we separate the variables: $frac{dx}{dt} = r + x^2$, $frac{1}{r+x^2} dx = dt$.
We integrate on both sides: $int frac{1}{r+x^2} , mathrm{d}x = int 1 , mathrm{d}t$.
We solve the integral on the left-hand side using the substitution $x = sqrt{-r} u$, $dx = sqrt{-r} du$:
begin{eqnarray}
int frac{1}{r+x^2} , mathrm{d}x &=& int frac{1}{r-ru^2} sqrt{-r} , mathrm{d}u = frac{sqrt{-r}}{r} int frac{1}{1-u^2} , mathrm{d}u = frac{sqrt{-r}}{r} left{ begin{array}{ll}
operatorname{artanh}(u) + tilde{C}, & |u| < 1\
operatorname{arcoth}(u) + tilde{C}, & |u| > 1
end{array}
right.\
&=& frac{sqrt{-r}}{r} left{ begin{array}{ll}
operatorname{artanh}left(frac{x}{sqrt{-r}}right) + tilde{C}, & |x| < sqrt{-r}\
operatorname{arcoth}left(frac{x}{sqrt{-r}}right) + tilde{C}, & |x| > sqrt{-r}
end{array}
right., quad tilde{C} in mathbb{R}.
end{eqnarray}
Thus we now obtain the nonlinear equations
begin{eqnarray}
operatorname{artanh}left(frac{x}{sqrt{-r}}right) = C -sqrt{-r} t, quad |x| < sqrt{-r},\
operatorname{arcoth}left(frac{x}{sqrt{-r}}right) = C -sqrt{-r} t, quad |x| > sqrt{-r},
end{eqnarray}
with a constant $C in mathbb{R}$.
Finally, we obtain 4 possible solutions of the ODE, depending on the initial value $x(t_0) = x_0 in mathbb{R}$:
begin{eqnarray}
x(t) &=& sqrt{-r} cothleft(operatorname{arcoth}left(frac{x_0}{sqrt{-r}}right)-sqrt{-r}(t-t_0)right), quad |x_0| > sqrt{-r},\
x(t) &=& -sqrt{-r}, quad x_0 = -sqrt{-r},\
x(t) &=& sqrt{-r}, quad x_0 = sqrt{-r},\
x(t) &=& sqrt{-r} tanhleft(operatorname{artanh}left(frac{x_0}{sqrt{-r}}right)-sqrt{-r}(t-t_0) right), quad |x_0| < sqrt{-r}.
end{eqnarray}
$endgroup$
add a comment |
$begingroup$
We use separation of variables to solve the ODE $dot{x} = r + x^2$, $r < 0$:
We first find the constant solutions $x equiv pm sqrt{-r}$. In the following steps we shall assume $r+x^2 not equiv 0$.
We use the Leibniz notation and we separate the variables: $frac{dx}{dt} = r + x^2$, $frac{1}{r+x^2} dx = dt$.
We integrate on both sides: $int frac{1}{r+x^2} , mathrm{d}x = int 1 , mathrm{d}t$.
We solve the integral on the left-hand side using the substitution $x = sqrt{-r} u$, $dx = sqrt{-r} du$:
begin{eqnarray}
int frac{1}{r+x^2} , mathrm{d}x &=& int frac{1}{r-ru^2} sqrt{-r} , mathrm{d}u = frac{sqrt{-r}}{r} int frac{1}{1-u^2} , mathrm{d}u = frac{sqrt{-r}}{r} left{ begin{array}{ll}
operatorname{artanh}(u) + tilde{C}, & |u| < 1\
operatorname{arcoth}(u) + tilde{C}, & |u| > 1
end{array}
right.\
&=& frac{sqrt{-r}}{r} left{ begin{array}{ll}
operatorname{artanh}left(frac{x}{sqrt{-r}}right) + tilde{C}, & |x| < sqrt{-r}\
operatorname{arcoth}left(frac{x}{sqrt{-r}}right) + tilde{C}, & |x| > sqrt{-r}
end{array}
right., quad tilde{C} in mathbb{R}.
end{eqnarray}
Thus we now obtain the nonlinear equations
begin{eqnarray}
operatorname{artanh}left(frac{x}{sqrt{-r}}right) = C -sqrt{-r} t, quad |x| < sqrt{-r},\
operatorname{arcoth}left(frac{x}{sqrt{-r}}right) = C -sqrt{-r} t, quad |x| > sqrt{-r},
end{eqnarray}
with a constant $C in mathbb{R}$.
Finally, we obtain 4 possible solutions of the ODE, depending on the initial value $x(t_0) = x_0 in mathbb{R}$:
begin{eqnarray}
x(t) &=& sqrt{-r} cothleft(operatorname{arcoth}left(frac{x_0}{sqrt{-r}}right)-sqrt{-r}(t-t_0)right), quad |x_0| > sqrt{-r},\
x(t) &=& -sqrt{-r}, quad x_0 = -sqrt{-r},\
x(t) &=& sqrt{-r}, quad x_0 = sqrt{-r},\
x(t) &=& sqrt{-r} tanhleft(operatorname{artanh}left(frac{x_0}{sqrt{-r}}right)-sqrt{-r}(t-t_0) right), quad |x_0| < sqrt{-r}.
end{eqnarray}
$endgroup$
We use separation of variables to solve the ODE $dot{x} = r + x^2$, $r < 0$:
We first find the constant solutions $x equiv pm sqrt{-r}$. In the following steps we shall assume $r+x^2 not equiv 0$.
We use the Leibniz notation and we separate the variables: $frac{dx}{dt} = r + x^2$, $frac{1}{r+x^2} dx = dt$.
We integrate on both sides: $int frac{1}{r+x^2} , mathrm{d}x = int 1 , mathrm{d}t$.
We solve the integral on the left-hand side using the substitution $x = sqrt{-r} u$, $dx = sqrt{-r} du$:
begin{eqnarray}
int frac{1}{r+x^2} , mathrm{d}x &=& int frac{1}{r-ru^2} sqrt{-r} , mathrm{d}u = frac{sqrt{-r}}{r} int frac{1}{1-u^2} , mathrm{d}u = frac{sqrt{-r}}{r} left{ begin{array}{ll}
operatorname{artanh}(u) + tilde{C}, & |u| < 1\
operatorname{arcoth}(u) + tilde{C}, & |u| > 1
end{array}
right.\
&=& frac{sqrt{-r}}{r} left{ begin{array}{ll}
operatorname{artanh}left(frac{x}{sqrt{-r}}right) + tilde{C}, & |x| < sqrt{-r}\
operatorname{arcoth}left(frac{x}{sqrt{-r}}right) + tilde{C}, & |x| > sqrt{-r}
end{array}
right., quad tilde{C} in mathbb{R}.
end{eqnarray}
Thus we now obtain the nonlinear equations
begin{eqnarray}
operatorname{artanh}left(frac{x}{sqrt{-r}}right) = C -sqrt{-r} t, quad |x| < sqrt{-r},\
operatorname{arcoth}left(frac{x}{sqrt{-r}}right) = C -sqrt{-r} t, quad |x| > sqrt{-r},
end{eqnarray}
with a constant $C in mathbb{R}$.
Finally, we obtain 4 possible solutions of the ODE, depending on the initial value $x(t_0) = x_0 in mathbb{R}$:
begin{eqnarray}
x(t) &=& sqrt{-r} cothleft(operatorname{arcoth}left(frac{x_0}{sqrt{-r}}right)-sqrt{-r}(t-t_0)right), quad |x_0| > sqrt{-r},\
x(t) &=& -sqrt{-r}, quad x_0 = -sqrt{-r},\
x(t) &=& sqrt{-r}, quad x_0 = sqrt{-r},\
x(t) &=& sqrt{-r} tanhleft(operatorname{artanh}left(frac{x_0}{sqrt{-r}}right)-sqrt{-r}(t-t_0) right), quad |x_0| < sqrt{-r}.
end{eqnarray}
answered Jan 30 at 9:39
ChristophChristoph
59616
59616
add a comment |
add a comment |
Thanks for contributing an answer to Mathematics Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
Use MathJax to format equations. MathJax reference.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3093160%2fhow-to-solve-this-first-order-nonlinear-differential-equation%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
1
$begingroup$
Substitute $u = frac{x}{sqrt{-r}}$. You'll get an inverse hyperbolic tangent.
$endgroup$
– Christoph
Jan 30 at 6:16
1
$begingroup$
So it is $x^2 - a^2$ at the bottom. Could use partial fractions.
$endgroup$
– Arctic Char
Jan 30 at 6:16
$begingroup$
@Christoph, why did you put the minus ? Also, how to handle the square root of negative number?
$endgroup$
– CroCo
Jan 30 at 6:21
1
$begingroup$
If $r<0$ you have $-r>0$, so you can take the square root of that.
$endgroup$
– Christoph
Jan 30 at 6:22
1
$begingroup$
$-a^2=r$, so $a$ is the square root of the positive number $-r$.
$endgroup$
– Hans Lundmark
Jan 30 at 6:23