How do I classify this partial differential equation? Inhomogeneous?

In summary, the conversation discusses a second order differential equation with a constant and one initial condition. The presence of the constant makes the equation inhomogeneous and the best method to solve it is to split it into simpler linear problems and add the solutions together. It is recommended to take a function of x that satisfies the boundary conditions and subtract it from the given initial condition, in order to solve for the complimentary functions. There is a missing initial condition on u_t, but it is suggested to assume it to be 0.
  • #1
Phys pilot
30
0
Hello,

I have to solve this second order differential equation. It's like a string vibrating equation but with a constant c:

$$\frac{{\partial^2 u}}{{\partial t^2}}=k\frac{{\partial^2 u}}{{\partial x^2}}+c$$

B.C $$u(0,t)=0$$ $$u(1,t)=2c_0$$ c_0 is also a constant

I.C $$u(x,0)=c_0(1-\cos\pi x)$$

This is new for me and I would like to know how to classify it and maybe some recommended book that includes this because mine doesn't and I think I can not separate variables. I have never seen a equation with a constant and then just one initial condition, they usually give us two.
thank you
 
Physics news on Phys.org
  • #2
The presence of a constant makes a linear DE like this inhomogeneous.

Can you solve the equation without the constant?

If so, what happens if you take that solution and add to it a function of only ##t## that, when differentiated twice wrt ##t##, gives ##c##?
 
  • #3
andrewkirk said:
The presence of a constant makes a linear DE like this inhomogeneous.

Can you solve the equation without the constant?

If so, what happens if you take that solution and add to it a function of only ##t## that, when differentiated twice wrt ##t##, gives ##c##?

Probably best to take a function of [itex]x[/itex] which when differentiated twice yields [itex]-c/k[/itex] and satisfies the boundary conditions at 0 and 1, since you can then subtract it from [itex]c_0(1 - \cos(\pi x))[/itex] and expand the difference as a sine series on [0,1] to get the initial conditions for the complimentary functions.
 
  • Like
Likes Chestermiller
  • #4
pasmith said:
Probably best to take a function of [itex]x[/itex] which when differentiated twice yields [itex]-c/k[/itex] and satisfies the boundary conditions at 0 and 1, since you can then subtract it from [itex]c_0(1 - \cos(\pi x))[/itex] and expand the difference as a sine series on [0,1] to get the initial conditions for the complimentary functions.
andrewkirk said:
The presence of a constant makes a linear DE like this inhomogeneous.

Can you solve the equation without the constant?

If so, what happens if you take that solution and add to it a function of only ##t## that, when differentiated twice wrt ##t##, gives ##c##?
I'm a little bit lost. So, I have to solve it first without the constant which should be easy. But then? I didn't understand the second part. Thats why I'm looking for a book or pdf solving a case like this. Because I found some that intead of a constant they add a function but then the B.C and I.C are different.

I have another doubt, I think that a u_t I.C is missing right? or can I solve it without it?
thanks, sorry for my english
 
  • #5
The thing about linear problems, such as this one, is that you can split them up into simpler linear problems which you can already solve. Then you just add the solutions together.

So here the simplest method is to write [tex]
u(x,t) = u_1(x) + u_2(x,t)[/tex] where [itex]u_1[/itex] satisfies [tex]
0 = k\frac{d^2u_1}{dx^2} + c[/tex] and [itex]u_2[/itex] satisfies [tex]
\frac{\partial^2 u_2}{\partial t^2} = k \frac{\partial^2 u_2}{\partial x^2}[/tex] so that the sum [itex]u[/itex] satisfies [tex]
\frac{\partial^2 u}{\partial t^2} = k \frac{\partial^2 u}{\partial x^2} + c[/tex]as required.

Now we need to satisfy the boundary conditions. Our only constraint is on the value of [itex]u_1 + u_2[/itex], so we are free to choose the conditions on [itex]u_1[/itex] to our advantage. My suggestion is to take [itex]u_1(0) = 0[/itex] and [itex]u_1(1) = 2c_0[/itex] so that [itex]u_2(0,t) = u_2(1,t) = 0[/itex]. The initial condition on [itex]u_2[/itex] must then be [tex]
u_1(x) + u_2(x,0) = c_0(1 - \cos(\pi x)).[/tex] Thus we are left with two problems:

(1) Solve [tex]\frac{d^2u_1}{dx^2} = -c/k[/tex] subject to [itex]u_1(0) = 0[/itex] and [itex]u_1(1)=2c_0[/itex].

(2) Solve [tex]\frac{\partial^2 u_2}{\partial t^2} = k \frac{\partial^2 u_2}{\partial x^2}[/tex] subject to [itex]u_2(0,t) = u_2(1,t) = 0[/itex] and [tex]u_2(x,0) = c_0(1 - \cos(\pi x)) - u_1(x).[/tex]

Hopfully you know how to solve each of those problems separately.

(There is a missing initial condition on [itex]u_t[/itex]. My suggestion is to assume that [itex]u_t(x,0) = 0[/itex].)

Why did I not follow @andrewkirk's suggestion of writing [itex]u(x,t) = u_3(t) + u_4(x,t)[/itex]? Because that leaves me with a problem for [itex]u_4[/itex] with boundary conditions [tex]
u_4(0,t) = -u_3(t), \qquad u_4(1,t) = 2c_0 - u_3(t),\qquad u_4(x,0) = c_0(1-\cos(\pi x)) - u_3(0)[/tex] which is much harder to solve than the problem for [itex]u_2[/itex] above.
 
  • Like
Likes Phys pilot
  • #6
pasmith said:
The thing about linear problems, such as this one, is that you can split them up into simpler linear problems which you can already solve. Then you just add the solutions together.

So here the simplest method is to write [tex]
u(x,t) = u_1(x) + u_2(x,t)[/tex] where [itex]u_1[/itex] satisfies [tex]
0 = k\frac{d^2u_1}{dx^2} + c[/tex] and [itex]u_2[/itex] satisfies [tex]
\frac{\partial^2 u_2}{\partial t^2} = k \frac{\partial^2 u_2}{\partial x^2}[/tex] so that the sum [itex]u[/itex] satisfies [tex]
\frac{\partial^2 u}{\partial t^2} = k \frac{\partial^2 u}{\partial x^2} + c[/tex]as required.

Now we need to satisfy the boundary conditions. Our only constraint is on the value of [itex]u_1 + u_2[/itex], so we are free to choose the conditions on [itex]u_1[/itex] to our advantage. My suggestion is to take [itex]u_1(0) = 0[/itex] and [itex]u_1(1) = 2c_0[/itex] so that [itex]u_2(0,t) = u_2(1,t) = 0[/itex]. The initial condition on [itex]u_2[/itex] must then be [tex]
u_1(x) + u_2(x,0) = c_0(1 - \cos(\pi x)).[/tex] Thus we are left with two problems:

(1) Solve [tex]\frac{d^2u_1}{dx^2} = -c/k[/tex] subject to [itex]u_1(0) = 0[/itex] and [itex]u_1(1)=2c_0[/itex].

(2) Solve [tex]\frac{\partial^2 u_2}{\partial t^2} = k \frac{\partial^2 u_2}{\partial x^2}[/tex] subject to [itex]u_2(0,t) = u_2(1,t) = 0[/itex] and [tex]u_2(x,0) = c_0(1 - \cos(\pi x)) - u_1(x).[/tex]

Hopfully you know how to solve each of those problems separately.

(There is a missing initial condition on [itex]u_t[/itex]. My suggestion is to assume that [itex]u_t(x,0) = 0[/itex].)

Why did I not follow @andrewkirk's suggestion of writing [itex]u(x,t) = u_3(t) + u_4(x,t)[/itex]? Because that leaves me with a problem for [itex]u_4[/itex] with boundary conditions [tex]
u_4(0,t) = -u_3(t), \qquad u_4(1,t) = 2c_0 - u_3(t),\qquad u_4(x,0) = c_0(1-\cos(\pi x)) - u_3(0)[/tex] which is much harder to solve than the problem for [itex]u_2[/itex] above.
Thank you. So it's the general solution of the homogeneous equation plus a particular solution.
I will try to solve the problem and post the solution here. Thank you again.
 
  • #7
pasmith said:
The thing about linear problems, such as this one, is that you can split them up into simpler linear problems which you can already solve. Then you just add the solutions together.

So here the simplest method is to write [tex]
u(x,t) = u_1(x) + u_2(x,t)[/tex] where [itex]u_1[/itex] satisfies [tex]
0 = k\frac{d^2u_1}{dx^2} + c[/tex] and [itex]u_2[/itex] satisfies [tex]
\frac{\partial^2 u_2}{\partial t^2} = k \frac{\partial^2 u_2}{\partial x^2}[/tex] so that the sum [itex]u[/itex] satisfies [tex]
\frac{\partial^2 u}{\partial t^2} = k \frac{\partial^2 u}{\partial x^2} + c[/tex]as required.

Now we need to satisfy the boundary conditions. Our only constraint is on the value of [itex]u_1 + u_2[/itex], so we are free to choose the conditions on [itex]u_1[/itex] to our advantage. My suggestion is to take [itex]u_1(0) = 0[/itex] and [itex]u_1(1) = 2c_0[/itex] so that [itex]u_2(0,t) = u_2(1,t) = 0[/itex]. The initial condition on [itex]u_2[/itex] must then be [tex]
u_1(x) + u_2(x,0) = c_0(1 - \cos(\pi x)).[/tex] Thus we are left with two problems:

(1) Solve [tex]\frac{d^2u_1}{dx^2} = -c/k[/tex] subject to [itex]u_1(0) = 0[/itex] and [itex]u_1(1)=2c_0[/itex].

(2) Solve [tex]\frac{\partial^2 u_2}{\partial t^2} = k \frac{\partial^2 u_2}{\partial x^2}[/tex] subject to [itex]u_2(0,t) = u_2(1,t) = 0[/itex] and [tex]u_2(x,0) = c_0(1 - \cos(\pi x)) - u_1(x).[/tex]

Hopfully you know how to solve each of those problems separately.

(There is a missing initial condition on [itex]u_t[/itex]. My suggestion is to assume that [itex]u_t(x,0) = 0[/itex].)

Why did I not follow @andrewkirk's suggestion of writing [itex]u(x,t) = u_3(t) + u_4(x,t)[/itex]? Because that leaves me with a problem for [itex]u_4[/itex] with boundary conditions [tex]
u_4(0,t) = -u_3(t), \qquad u_4(1,t) = 2c_0 - u_3(t),\qquad u_4(x,0) = c_0(1-\cos(\pi x)) - u_3(0)[/tex] which is much harder to solve than the problem for [itex]u_2[/itex] above.
Hello again, I had some problems. So when I solve this eq and I apply de boundar conditions y get this solution:
[tex]\frac{d^2u_1}{dx^2} = -c/k[/tex]
$$u_1(x)=2c_0x+\frac{c}{2k}x-\frac{h}{2k}x^2$$
I'm not sure if I did it correctly.
And when I solve the second eq, which is a typical wave equation I get this solution:
$$T_n(t)=C_n\cos{n \pi \sqrt{k} t}$$
$$X_n(x)=B_n \sin{n \pi x}$$
$$u_2(x,t)= \sum_{n=1}^\infty{} a_n \sin{n \pi x}\cos{n \pi \sqrt{k} t}$$
So when I apply the initial condition
[tex]u_2(x,0) = c_0(1 - \cos(\pi x)) - u_1(x).[/tex]
I get:
$$u_2(x,0)= \sum_{n=1}^\infty{} a_n \sin{n \pi x}=c_0(1 - \cos(\pi x)) - u_1(x)=c_0(1-2x-\cos{\pi x})+\frac{c}{2k}(x^2-x)=g(x)$$
Which seems impossible to solve in an easy way because doesn't look like a Fourier series.

Do you think is right? if so, which is the best method to solve it? thanks

EDIT:
So to calculate the coefficients a_n I deduce that I have to solve this integral:
$$a_n=2\int_0^1 g(x) \sin{n\pi x}$$
But introducing my g(x) is not giving me the supposed solution which apparently is:
$$a_n=\frac{2c_0}{n\pi}[1+(-1)^n]+\frac{2nc_0}{(n^2-1)\pi}[1-(-1)^n]+\frac{2c}{k\pi^3 n^3}[(-1)^n-1]$$

Actually, the solution to the problem is supposed to be:
$$u(x,t)=-\frac{cx^2}{2k}+(2c_0+\frac{c}{2k})x-\frac{4c}{k\pi}e^{-c\pi^2 t}\sin{\pi x}+ \sum_{n=2}^\infty{} a_n e^{-cn^2\pi^2 t}\sin{n\pi x}$$

As you can see, I'm not getting those exponentials of the general solution so I think I have a problem obtaining the function U(x) or/and a problem solving the temporal part of the homogeneous wave equation because I get a cosine. But I can not identify the mistake.
 
Last edited:
  • #8
Up please. I'm trying and trying and getting always the same result
 
  • #9
Is it possible that the PDE is actually [tex]
\frac{\partial u}{\partial t} = k \frac{\partial^2 u}{\partial x^2} + c?
[/tex] That would explain both the absence of an initial condition on [itex]\partial u/\partial t[/itex] and the expansion in terms of [itex]e^{-kn^2 \pi^2t}\sin(n\pi x)[/itex].

Since the Fourier coefficients depend only on the initial condition and not the time dependence of the eigenfunctions you still have to determine [itex]a_n[/itex] from [tex]
a_n = 2 \int_0^1 \left( c_0(1 - \cos(\pi x)) - \frac{c}{2k}x(x_0 - x)\right)\,dx[/tex] (Here [itex]x_0[/itex] is chosen so that [itex]u_1(1) = 2c_0[/itex]; the working is simplified if the actual value is not substituted until the final step.)

This involves finding the four separate Fourier series for [itex]1[/itex], [itex]x[/itex], [itex]x^2[/itex] and [itex]\cos(\pi x)[/itex].
 
Last edited:
  • #10
pasmith said:
Is it possible that the PDE is actually [tex]
\frac{\partial u}{\partial t} = k \frac{\partial^2 u}{\partial x^2} + c?
[/tex] That would explain both the absence of an initial condition on [itex]\partial u/\partial t[/itex] and the expansion in terms of [itex]e^{-kn^2 \pi^2t}\sin(n\pi x)[/itex].

Since the Fourier coefficients depend only on the initial condition and not the time dependence of the eigenfunctions you still have to determine [itex]a_n[/itex] from [tex]
a_n = 2 \int_0^1 \left( c_0(1 - \cos(\pi x)) - \frac{c}{2k}x(x_0 - x)\right)\,dx[/tex] (Here [itex]x_0[/itex] is chosen so that [itex]u_1(1) = 2c_0[/itex]; the working is simplified if the actual value is not substituted until the final step.)

This involves finding the four separate Fourier series for [itex]1[/itex], [itex]x[/itex], [itex]x^2[/itex] and [itex]\cos(\pi x)[/itex].
Yes! apparently there was a mistake on the equation and it's heat equation.
You wrote this:
[tex]
a_n = 2 \int_0^1 \left( c_0(1 - \cos(\pi x)) - \frac{c}{2k}x(x_0 - x)\right)\,dx[/tex]
But it should be:
[tex]
a_n = 2 \int_0^1 \left( c_0(1 - \cos(\pi x)) - \frac{c}{2k}x(x_0 - x)\right) \sin(n\pi x)\,dx[/tex]
right?

When you say that I have to find the separate Fourier series you mean that I have to solve 4 integral like these ones:

[tex]
2 \int_0^1 c_0\, \sin(n\pi x) dx[/tex]
[tex]
2 \int_0^1 - \cos(\pi x) \, \sin(n\pi x) dx[/tex]
[tex]
2 \int_0^1 - x_0\frac{c}{2k}x\, \sin(n\pi x) dx[/tex]
[tex]
2 \int_0^1 -\frac{c}{2k}x^2\, \sin(n\pi x) dx[/tex]

And then sum them. Or do I have to calculate the Fourier series for [itex]1[/itex], [itex]x[/itex], [itex]x^2[/itex] and [itex]\cos(\pi x)[/itex] and the coefficients [itex]a_0[/itex], [itex]a_n[/itex] and [itex]b_n[/itex]. If it is like this I don't understand why.

And also if you realize in the given solution the expansion starts in 2 because [itex]a_n[/itex] is not defined for [itex]a_1[/itex].So how do you get the part of the solution corresponding to $$-\frac{4c}{k\pi}e^{-k \pi^2 t} \sin(\pi x)$$ (which is out of the expansion in the solution).

Sorry for so many questions and thank you again.

Edit:
I don't understand. I keep solving the integrals like this:

$$a_n=2 \int_0^1 c_0\, \sin(n\pi x) dx+2 \int_0^1 -c_0\cos{\pi x}\, \sin(n\pi x) dx +2 \int_0^1 -2c_0x\, \sin(n\pi x) dx+2 \int_0^1 -\frac{c}{2k}x\, \sin(n\pi x) dx + \\2 \int_0^1 \frac{c}{2k}x^2\, \sin(n\pi x) dx$$

Which I understand that it's the solution of the coefficientes but I'm not getting the supposed solution and also my expansion doesn't start at 2
 
Last edited:

1. How do I determine if a partial differential equation is inhomogeneous?

A partial differential equation is considered inhomogeneous if it contains terms that are not dependent on the dependent variable or its derivatives. These terms are known as source or forcing terms and typically involve constants or functions of independent variables.

2. What is the difference between a homogeneous and inhomogeneous partial differential equation?

A homogeneous partial differential equation is one where all terms are dependent on the dependent variable and its derivatives. In contrast, an inhomogeneous partial differential equation contains terms that are not dependent on the dependent variable or its derivatives.

3. How do I classify a partial differential equation as inhomogeneous?

To classify a partial differential equation as inhomogeneous, you can look for terms that are not dependent on the dependent variable or its derivatives. These terms are known as source or forcing terms and typically involve constants or functions of independent variables. If the equation contains such terms, it is considered inhomogeneous.

4. Can a partial differential equation be both homogeneous and inhomogeneous?

No, a partial differential equation can only be either homogeneous or inhomogeneous. A homogeneous equation contains terms that are dependent on the dependent variable and its derivatives, while an inhomogeneous equation contains terms that are not dependent on the dependent variable or its derivatives.

5. How do I solve an inhomogeneous partial differential equation?

Solving an inhomogeneous partial differential equation involves finding a particular solution and a complementary solution. The particular solution is a solution to the inhomogeneous equation, while the complementary solution is a solution to the corresponding homogeneous equation. The sum of these two solutions gives the general solution to the inhomogeneous equation.

Similar threads

  • Differential Equations
Replies
7
Views
332
  • Differential Equations
Replies
3
Views
1K
  • Differential Equations
Replies
7
Views
2K
Replies
5
Views
1K
Replies
1
Views
1K
  • Differential Equations
Replies
3
Views
2K
  • Differential Equations
Replies
3
Views
1K
  • Differential Equations
Replies
1
Views
706
Replies
2
Views
2K
  • Differential Equations
Replies
1
Views
1K
Back
Top