4

Solve the equation $$t\cdot\frac{dx}{dt}=x(\ln x - \ln t)$$

My try:

We consider the equation for $x, t >0$. $$tx'=x(\ln x - \ln t)$$ $$t \cdot \frac{dx}{dt}=x(\ln x - \ln t)$$ $$\frac{dx}{x}=(\ln x - \ln t)\frac{dt}t$$ $$\int \frac{1}{x}dx=\int \ln (\frac xt) \cdot \frac 1t dt$$ $\int \ln (\frac xt) \cdot \frac 1t dt=\begin{cases} u=\ln (\frac xt) \\ du = -\frac 1t dt \end{cases} = -\int u du = -\frac{u^2}2 +C = -\frac 12 \ln ^2 (\frac xt) +C$

We go back to our equation: $$\ln x =-\frac 12 \ln ^2 (\frac xt) +C$$ However, I think my way of solving is not the best, because I came to an equation from which it is difficult to determine $x(t)$.

MathFail
  • 21,128
qerty149
  • 116
  • 6
    Your integral of $\log(x/t)/t$ is incorrect. (Note that $x$ is also a function of $t$.) Also, the equation is screaming for the substitution $x=tu$. – Sangchul Lee May 20 '23 at 10:57

5 Answers5

2

This ODE can be recasted as $\dot{x} = u\ln u$, where $u = \frac{x}{t}$, hence $\dot{u} = \frac{\dot{x}}{t} - \frac{x}{t^2} = \frac{u\ln u-u}{t}$ and $\frac{\mathrm{d}u}{u(\ln u-1)} = \frac{\mathrm{d}t}{t}$ by separation of variables, which leads to $\ln(\ln u-1) - \ln(\ln u_0-1) = \ln t - \ln t_0$ after integration and finally $u(t) = \exp\left(1+\frac{t}{t_0}(\ln u_0-1)\right)$, with the initial condition $u(t_0) = u_0$.

Abezhiko
  • 8,153
  • 3
    For the sake of accuracy, shouldn't you consider $\ln|\ln u-1| - \ln|\ln u_0-1| = \ln t - \ln t_0$? But then we get two sollutions: $u(t) = \exp\left(1+\frac{t}{t_0}|\ln u_0-1|\right)$ and $u(t) = \exp\left(1-\frac{t}{t_0}|\ln u_0-1|\right)$ and I don't know if we can reject any. – qerty149 May 21 '23 at 06:49
  • This work is too coarse. I think you have to discuss and justify the absolute value more carefully. –  May 29 '23 at 09:54
2

Solve the equation $tx'=x(\ln x - \ln t)$

First note the domain $x>0\land t>0$. Next, we write this differential equation into standard form:

$$\frac{dx}{dt}=\frac{x}{t}\cdot\ln\left(\frac{x}{t}\right),~~~~~~~~~t>0\land x>0\land \color{red}{x\neq t}\tag{1}$$

Note for this implicit condition $$\color{red}{x\neq t}$$

otherwise, (1) gives

$$1=1\cdot\ln 1=0$$

Now, let's go back to (1). This is a homogeneous differential equation, which has the standard form:

$$\frac{dx}{dt}=F\left(\frac{x}{t}\right)$$

so we take the standard substitution $x=u\cdot t$ for solving homogeneous differential equations. The idea for this standard substitution is to convert the original differential equation into a separable equation. Note that $u=u(t)$ is function of $t$, by product rule, we get

$$\frac{dx}{dt}=t\frac{du}{dt}+u$$

Now, eq.(1) becomes:

$$t\frac{du}{dt}+u=u\ln u,~~~~~~~t>0\land u>0\land\color{red}{u\neq 1}\tag{2}$$

Note that the red-color restriction in (1) is equivalent to

$$\color{red}{x\neq t}\Longleftrightarrow\color{red}{u\neq 1}$$

Also, note for a trivial solution from (2):

$$\boxed{\color{blue}{u=e}}\tag{3}$$

We can see now this differential equation (2) becomes separable, namely:

$$\frac{du}{u\ln u-u}=\frac{dt}{t}$$

Under the restrictions $t>0\land u>0\land\color{red}{u\neq 1}\land \color{blue}{u\neq e}$, we can integrate both sides,

$$\ln t +C_1=\int\frac{1}{u\ln u-u}du=\int\frac{1}{\ln (u)-1}\cdot\frac{1}u~du$$

Note, in (1) and (2) we require $t>0$, hence we don't need the absolute value for $\ln t$ in the LHS. For RHS, let $\theta=\ln u,~~~\theta\in\mathbb{R}$ $$\ln t +C_1=\int\frac{1}{\theta-1}~d\theta=\ln|\theta-1|+C_2$$

Simplify and we get:

$$|\theta-1|=e^{\ln t}\cdot e^{C_1-C_2}=e^{C_1-C_2}\cdot t$$

Let $C=e^{C_1-C_2}>0$, hence:

$$\boxed{|\ln (u)-1|=C\cdot t,~~~~~t>0\land u>0\land\color{red}{u\neq 1}\land \color{blue}{u\neq e}}\tag{4}$$

So far, we are done for the integration steps. Next, we need to determine the constanst $C$ and the take off the absolute value, i.e. choose either $+$ or $-$ branch. This depends on your initial conditions. By the Existence and Uniqueness theorem, the solution is uniquely determined on the interval where your initial condition belongs to, and before the solution (curve) hits the nearest singularity. In our case, these singularities are those boundary points, such as $t=0, u=0, u=1, u=e$. You can find more details on this existence and uniqueness with my answers on other similar examples here and here.

Finally, we convert (3) and (4) into variable $x$ and $t$

Trivial solution:

$$\boxed{x=et,~~~~~t>0}\tag{5}$$

None trivial solution ($C>0$):

$$\boxed{~\left|\ln \left(\frac{x}t\right)-1\right|=C\cdot t,~~~~~t>0\land \frac{x}t>0\land\color{red}{\frac{x}t \neq 1}\land \color{blue}{\frac{x}t\neq e}~~}\tag{6}$$

$$=====================\text{Remarks}=====================$$

Note in (4) and (6), the entire domain for $u$ and $\frac{x}t$ are splited into three regions:

$$u\in (0,1)\cup(1,e)\cup(e,\infty)\Longleftrightarrow \frac{x}t\in (0,1)\cup(1,e)\cup(e,\infty)$$

By existence and uniqueness theorem, the solution is uniquely determined on one interval of them, which depends on the initial conditions. We choose the implicit form without taking off the absolute value, because this problem didn't specify the initial conditions. As long as the initial conditions are specified, we can immediately convert the implicit form into explicit form.

For example, if the initial condition is $t_0=1, x_0=2$, then we have

$$\frac{x_0}{t_0}=\frac{2}1=2\in (1,e)$$

So we know $\displaystyle \frac{x}t\in (1,e)$, hence

$$0<\ln\left(\frac{x}t\right)<1$$

Now we can take off the absolute value without any ambiguity for signs, hence (6) becomes

$$1-\ln \left(\frac{x}t\right)=C\cdot t,~~~~~t>0\land \frac{x}t\in (1,e)$$

Plug in initial condition $t_0=1, x_0=2$, we get

$$C=1-\ln2>0$$

hence

$$x=t\cdot e^{1-(1-\ln2)\cdot t}\Longrightarrow x=t\cdot 2^t\cdot e^{1-t}$$

MathFail
  • 21,128
  • Good answer ($+1$). But may I ask you something: Why are you using $\cap$ instead of $\wedge$? I only know $\cap$ and $\cup$ from set theory, but here you somehow use it without sets (I may be wrong here). – Kevin Dietrich Jun 03 '23 at 19:43
  • 1
    Yes, it is updated, thank you for catching this. – MathFail Jun 03 '23 at 19:55
1

Well, we are trying to solve:

$$t\text{x}'\left(t\right)=\text{x}\left(t\right)\left(\ln\left(\text{x}\left(t\right)\right)-\ln\left(t\right)\right)\tag1$$

First, let $\text{x}\left(t\right)=t\text{v}\left(t\right)$ which gives:

$$\frac{\text{d}\text{x}\left(t\right)}{\text{d}t}=t\cdot\frac{\text{d}\text{v}\left(t\right)}{\text{d}t}+\text{v}\left(t\right)\tag2$$

So, we get:

$$t\left(t\cdot\frac{\text{d}\text{v}\left(t\right)}{\text{d}t}+\text{v}\left(t\right)\right)=t\text{v}\left(t\right)\left(\ln\left(t\text{v}\left(t\right)\right)-\ln\left(t\right)\right)\tag3$$

Simplifying, using log-rules, gives:

$$t\left(t\cdot\frac{\text{d}\text{v}\left(t\right)}{\text{d}t}+\text{v}\left(t\right)\right)=t\text{v}\left(t\right)\ln\left(\text{v}\left(t\right)\right)\tag4$$

Now, solving for $\displaystyle\frac{\text{d}\text{v}\left(t\right)}{\text{d}t}$ gives:

$$\frac{\text{d}\text{v}\left(t\right)}{\text{d}t}=\frac{\text{v}\left(t\right)\ln\left(\text{v}\left(t\right)\right)-\text{v}\left(t\right)}{t}\tag5$$

Divide both sides by $\displaystyle \text{v}\left(t\right)\ln\left(\text{v}\left(t\right)\right)-\text{v}\left(t\right)$, gives:

$$\frac{\displaystyle\frac{\text{d}\text{v}\left(t\right)}{\text{d}t}}{\text{v}\left(t\right)\ln\left(\text{v}\left(t\right)\right)-\text{v}\left(t\right)}=\frac{1}{t}\tag6$$

Integrate both sides with respect to $t$:

$$\int\frac{\displaystyle\frac{\text{d}\text{v}\left(t\right)}{\text{d}t}}{\text{v}\left(t\right)\ln\left(\text{v}\left(t\right)\right)-\text{v}\left(t\right)}\space\text{d}t=\int\frac{1}{t}\space\text{d}t\tag7$$

Finding those two integrals which is not too hard, gives:

$$\ln\left|\ln\left(\text{v}\left(t\right)\right)-1\right|=\ln\left|t\right|+\text{C}\tag8$$

I'll let you finish.

Jan Eerland
  • 28,671
  • Ok, I get $v(t)=e^{1\pm te^C}$, so $x(t)=te^{1\pm te^C}$. Are both solutions correct or should we reject either? – qerty149 May 25 '23 at 11:36
0

As $\left(\ln\frac xt\right)'= -\frac 1t+\frac{x'}{x}$ we have

$$ t\left(\ln\frac xt\right)'=t\frac{x'}{x}-1\Rightarrow t\left(\ln\frac xt\right)'+1 = \ln \frac xt $$

now making $y = \ln \frac xt$ this ODE can be recast as

$$ t y'-y + 1 = 0 $$

with solution

$$ y = t c_0 + 1 $$

hence

$$ x = t e^{t c_0 + 1} $$

Cesareo
  • 33,252
0

$$tx'=x(\ln x - \ln t)$$ $$t\dfrac {x'}x-\ln x =- \ln t$$ $$t(\ln x)'-\ln x =- \ln t$$ This is a first order linear DE: $$\left (\dfrac {\ln x}{t}\right)'=-\dfrac {\ln t} {t^2}$$ Integrate by parts the RHS.

user577215664
  • 40,625