Solving an ODE: Seeking Suggestions

In summary, the person is trying to find a method to solve an ODE involving derivatives of both functions with respect to time. They are not sure how to take another derivative with respect to time and get the equation for the second derivative. Superposition does not work.
  • #1
metamathphys
9
0
Hello I am trying to solve this ODE


dx/dt=(f(x)+g(t))^(1/2)


I have been recalling what I learn in my ODE course and looking at my old textbook but I did not find what method is appropiate to try...any suggestions?

Thank you very much!
 
Physics news on Phys.org
  • #2
You can take another derivative wrt t to get:

d^2 x/dt^2 = [f'(x)dx/dt+g'(t)]/2(dx/dt) = f'(x)/2 + g'(t)dt/dx/2

Now try to solve d^2 x /dt^2 =f'(x)/2 and d^2 x / dt^2 =g'(t)/(2dx/dt)

Seperately, and then by superposition you get a solution for the ODE.
the second equation you can write the solution explicitly d(dx/dt)^2/dt = g'(t) by integration you get:
(dx/dt)^2 =g(t)+C
dx/dt = sqrt(g(t)+C) ...

I believe you get the picture now.
 
  • #3
MathematicalPhysicist said:
You can take another derivative wrt t to get:

d^2 x/dt^2 = [f'(x)dx/dt+g'(t)]/2(dx/dt) = f'(x)/2 + g'(t)dt/dx/2

Now try to solve d^2 x /dt^2 =f'(x)/2 and d^2 x / dt^2 =g'(t)/(2dx/dt)

Seperately, and then by superposition you get a solution for the ODE.
the second equation you can write the solution explicitly d(dx/dt)^2/dt = g'(t) by integration you get:
(dx/dt)^2 =g(t)+C
dx/dt = sqrt(g(t)+C) ...

I believe you get the picture now.

Sorry, but this is wrong. The equation you get when you differentiate wrt t is
[itex]\frac{dx}{dt}\frac{d^2x}{dt^2}-\frac{1}{2}\frac{df\left(x\right)}{dx}\frac{dx}{dt}=\frac{1}{2}\frac{dg\left(t\right)}{dt}[/itex]

The first term is nonlinear. The second term is also nonlinear, except for special cases of f(x). Thus this equation is nonlinear, and superposition does not hold!
 
  • #4
the_wolfman said:
Sorry, but this is wrong. The equation you get when you differentiate wrt t is
[itex]\frac{dx}{dt}\frac{d^2x}{dt^2}-\frac{1}{2}\frac{df\left(x\right)}{dx}\frac{dx}{dt}=\frac{1}{2}\frac{dg\left(t\right)}{dt}[/itex]
That too is wrong. A correct expression for the second derivative with respect to time is ##2\ddot x(t) = f'(x) + g'(x)##

That said, I don't think that this will help in general.
metamathphys said:
Hello I am trying to solve this ODE

dx/dt=(f(x)+g(t))^(1/2)
What might help is solving for t as a function of x yielding ##t=\int (f(x)+g(x))^{-1/2}\,dx## and then finding the inverse function that yields x as a function of t.
 
Last edited:
  • #5
First of all I wish to thank you all for taking some time looking at my post.

My first comment concerns all of those who suggest taking another time derivative. I do not agree with your results if I take another derivative what I get is:

[itex]\frac{d^2x}{dt^2}=\frac{f'(x)\frac{dx}{dt}+\frac{dg}{dt}}{2\sqrt{f+g}}[\itex]

Which does not look any easier...I do not know about any equation that simplifies when you perform higher derivatives.

Regarding the comment of D H

If I knew t as a function of x then I would be done no? All I had left to do is invert the relation to have x as a function of t and that all. So your method requires knowing the solution to the problem so I don't see how this can be of any help maybe I am misunderstanding something if it is so please show explicitly how to do it with some easy example
 
  • #6
D H said:
That too is wrong. A correct expression for the second derivative with respect to time is ##2\ddot x(t) = f'(x) + g'(x)##

Actually its not. In the original problem statement g is a function of t, not a function of x. If g was a function of x, then you would be correct.

First of all I wish to thank you all for taking some time looking at my post.

My first comment concerns all of those who suggest taking another time derivative. I do not agree with your results if I take another derivative what I get is:

[itex]\frac{d^2x}{dt^2}=\frac{f'(x)\frac{dx}{dt}+\frac{dg}{dt}}{2\sqrt{f+g}}[/itex]

Its the same thing. We are using the original equation ([itex]\frac{dx}{dt} = \sqrt{f(x)+g(t)}[/itex]) to simplify the denominator:
[itex]\frac{d^2x}{dt^2}=\frac{f'(x)\frac{dx}{dt}+\frac{dg}{dt}}{2\sqrt{f+g}}=\frac{f'(x)\frac{dx}{dt}+\frac{dg}{dt}}{2\frac{dx}{dt}}[/itex]


For the record, I recommend trying to directly solve the first order ode:

[itex]\frac{dx}{dt} = \sqrt{f(x)+g(t)}[/itex].


You might get lucky by taking more derivatives but I doubt it. In general first order nonlinear ODEs are the easiest to solve. Higher order non-linear ODEs get progressively harder to solve.

I also don't know if a general solution to this equation exists for arbitrary f and g. Do you know what f and g are.
 
  • #7
the_wolfman said:
Actually its not. In the original problem statement g is a function of t, not a function of x. If g was a function of x, then you would be correct.
Stupid me. You are correct. I didn't read the OP properly.
I also don't know if a general solution to this equation exists for arbitrary f and g.

Of course not. There certainly must exist some function x(t) defined over some subinterval over which ##f(x)## and ##g(t)## are bounded and continuous. However, good luck finding that x(t) in general. There's no guarantee that ##\frac{dx}{dt} = f(t)## has a solution in the elementary functions, let alone ##\frac{dx}{dt} = \sqrt{f(x)+g(t)}##.
Do you know what f and g are.
That is a key question.
 
  • #8
Yes, I believe you may be right, this trick of the derivative of square root seemed like it may work here.

So what's the context metamathphys?
 
  • #9
the_wolfman said:
Actually its not. In the original problem statement g is a function of t, not a function of x. If g was a function of x, then you would be correct.



Its the same thing. We are using the original equation ([itex]\frac{dx}{dt} = \sqrt{f(x)+g(t)}[/itex]) to simplify the denominator:
[itex]\frac{d^2x}{dt^2}=\frac{f'(x)\frac{dx}{dt}+\frac{dg}{dt}}{2\sqrt{f+g}}=\frac{f'(x)\frac{dx}{dt}+\frac{dg}{dt}}{2\frac{dx}{dt}}[/itex]


For the record, I recommend trying to directly solve the first order ode:

[itex]\frac{dx}{dt} = \sqrt{f(x)+g(t)}[/itex].


You might get lucky by taking more derivatives but I doubt it. In general first order nonlinear ODEs are the easiest to solve. Higher order non-linear ODEs get progressively harder to solve.

I also don't know if a general solution to this equation exists for arbitrary f and g. Do you know what f and g are.

Well, I can look at it as an equation of energy which is not constant of time.

I.e dx/dt is the velocity and we have v^2-f(x)=g(t) (or Lagrangian depending on the plus minus sign). So it's actually an equation of an energy which is not necessarily constant with time.

How to solve this analytically, I am afraid I don't know, but I guess some special function is in order...
 

1. What is an ODE?

An ODE, or ordinary differential equation, is a mathematical equation that describes how a variable changes over time, based on its current value and rate of change.

2. Why do we need to solve ODEs?

ODEs are used to model a wide range of phenomena in fields such as physics, engineering, and biology. Solving ODEs allows us to make predictions and understand the behavior of these systems.

3. What methods are used to solve ODEs?

There are various methods for solving ODEs, including analytical methods, numerical methods, and computer algorithms. Some common techniques include separation of variables, Euler's method, and Runge-Kutta methods.

4. How do I know which method to use?

The choice of method depends on the specific ODE and the desired level of accuracy. Analytical methods are often preferred when possible, as they provide exact solutions. However, for more complex or non-linear ODEs, numerical methods may be necessary.

5. Are there any common challenges when solving ODEs?

Yes, there can be several challenges when solving ODEs, such as finding appropriate initial conditions, dealing with singularities or discontinuities, and choosing the appropriate numerical method and step size. It is important to carefully consider these factors in order to obtain accurate and meaningful solutions.

Similar threads

  • Differential Equations
Replies
3
Views
1K
Replies
3
Views
1K
Replies
3
Views
787
  • Differential Equations
Replies
3
Views
2K
  • Differential Equations
Replies
6
Views
1K
Replies
3
Views
2K
Replies
2
Views
2K
  • Differential Equations
Replies
5
Views
1K
Replies
2
Views
1K
Replies
2
Views
2K
Back
Top