PDE: Wave Equation with Neumann conditions

• RJLiberator
In summary, the student is trying to solve the wave equation for a non-linear problem. They are using separation of variables and the Neumann conditions to find a nontrivial solution. They are having trouble with the boundary condition and need help from the instructor.
RJLiberator
Gold Member

Homework Statement

Consider the homogeneous Neumann conditions for the wave equation:
U_tt = c^2*U_xx, for 0 < x < l
U_x(0,t) = 0 = U_x(l, t)
U(x,0) = f(x), U_t(x,0) = g(x)
Using the separation of variables, find a nontrivial solution of (1).

Homework Equations

Separation of variables

The Attempt at a Solution

So I've been working away at this problem. First, the instructor gave us a semi-example of a very similar problem in class. Next, I've been using this link to help me ( ).

First, we suppose u(x,t) = X(x)T(t)
then, U_tt = X(x)T''(t) and U_xx = X''(x)T(t)
so, U_tt = c^2*U_xx => X(x)T''(t) = c^2X''(x)T(t)

we can rewrite it and get it into solvable separate equations as follows:
T''(t) = λT(t)
X''(x) = (λ/c^2)X(x)

I think I've done everything right up to this stage.
Now is where my understanding begins to get hazy

So from here, I would think the best idea is to separate them into cases where λ =0, λ >1, λ<1 as was done in the instructional YouTube video I posted earlier.
However, in my notes, the instructor just did turned the λ I had in my equations into -λ^2.
He mentioned he did this to include the complex numbers that may be in the solution.
Further a long in the instructional video, I think in the case λ < 1 the video replaces λ with ω^2, but it's still not quite the same.

I'm wondering if a) my instructor only did part of the problem, and if so, was it because of the boundary conditions.
b) Do I need to do all three cases? IF so, will they all intertwine in the end with my boundary conditions?
b) If in this particular problem, where my boundary conditions come into play? MY thinking is that when I solve the various cases I will get general solutions and then use the boundary conditions to get a nontrivial solution.

So my current plan is to solve the general solution for each case, and then hope that I can use the boundary conditions to find a nontrivial solution.

Am I thinking in the right way?

The reason to set it equal to ##-\lambda^2## is to get solutions for ##X(x)## the form ##X(x)=c_1 \cos (\lambda x) + c_2 \sin(\lambda x)##.
This fits very nicely with your boundary conditions where you can eliminate ##c_1## and impose a condition on ##\lambda##. You could perfectly well write it in terms of exponential functions or ##\sinh , \cosh## if you wanted but in this case the sine functions make it simpler.

You solution so far looks fine but putting it as ##-\lambda^2## will really simplify for you. I didn't watch the entire video but from taking a quick look it looks like he didn't have any boundary conditions in which case he would just be finding general eigenfunctions for the sturm-liouville problems. You know the boundary conditions and sine functions really fit with the ones imposed on ##X(x)##.

Edit: In summary because of your B.V. ##\lambda## can only take selected values so you only need to work with those values.

RJLiberator
Incand said:
The reason to set it equal to ##-\lambda^2## is to get solutions for ##X(x)## the form ##X(x)=c_1 \cos (\lambda x) + c_2 \sin(\lambda x)##.
This fits very nicely with your boundary conditions where you can eliminate ##c_1## and impose a condition on ##\lambda##. You could perfectly well write it in terms of exponential functions or ##\sinh , \cosh## if you wanted but in this case the sine functions make it simpler.

You can't use sinh or cosh here, since for $k > 0$ the only linear combination of $\cosh(kx)$ and $\sinh(kx)$ which is zero at both boundaries is the trivial combination which is zero everywhere.

RJLiberator
pasmith said:
You can't use sinh or cosh here, since for $k > 0$ the only linear combination of $\cosh(kx)$ and $\sinh(kx)$ which is zero at both boundaries is the trivial combination which is zero everywhere.
Of course you can use complex ##\sinh## and ##\cosh## but you get an imaginary argument, so you get functions which of course are equal to the trigonometric ones in the end.

Okay, I am trying to solve my problem here.

I have now set the following up:

T''(t) = -λ^2*T(t)
X''(x) = -(λ^2/c^2)*X(x)

X(x) = c_1 * cos(λx) + c_2 * sin(λx)
T(t) = c_3 * cos( cλt) + c_4 * sin(cλt)

Now, using homogeneous Neumann conditions,
X(0) = X(l) = 0
Did I use the boundary condition correct here?

Then c1 = 0 and λ = n*pi/l
Then we can write

u(x,t) = the sum from 1 to infinity of sin(n*pi*x)/l * (a_n*cos[(n*pi*c*t)/l]+b_n*sin[(n*pi*c*t)/l])

Am I working this out properly?

RJLiberator said:
Okay, I am trying to solve my problem here.
X(0) = X(l) = 0
Did I use the boundary condition correct here?
Correct! Everything else looks correct to me as well ,but it would be good if you write the equations in latex in the future, especially the last one is hard to read.

Your other conditions ##u(x,0)=f(x)## and ##u_t(x,0)=g(x)## let's you determine the Fourier coefficients. In this case you don't know the functions so you can't calculate ##a_n## and ##b_n## but you may still want to write up the formulas for ##a_n## and ##b_n## as part of your answer.

So the question asks for a 'nontrivial' solution.

You are saying that we can't calculate a_n and b_n which I agree. So a nontrivial solution would show what a_n and b_n would be based on the Fourier coefficient calculations.

And then I combine those results, with my summation result and I have a nontrivial solution.an = c_n+c_(-n)
b_n = i(cn-c_(-n))

I'm not sure what they meant with a non trivial solution here, I'm guessing it's just so you don't write a solution like ##u(x,t) = 0## to the wave equation but you're boundary conditions would tell you that doesn't work (unless ##f(x)=g(x)=0##).

What I meant with my earlier comment was that if you apply your last two boundary conditions to your solution, you are able to write up the formulas for ##a_n## and ##b_n## even if you can't calculate them (you should know how to get the coefficients for a sine series on an interval of length ##l##).

RJLiberator
I'm sorry to be a bother, but this problem has literally been on my mind for the past 6 days.
The professor did a problem in our lecture with essentially the same work/result which has been helping me, but he mentioned that this HW assignment had a slightly different boundary condition and I just don't understand the difference here with them.
He reached the same result as we did in this thread with the solution. So I am thinking something might be wrong, unless the trick is that they are identical.His problem had conditions
U_tt = c^2u_xx, u(0,t) = u(l,t) = 0, x from 0 to l

u(x,0) = f(x) and u_t(x,0) = g(x)

where mine in this thread are

U_tt = c^2*u_xx, for 0 < x < l
U_x(0,t) = 0 = U_x(l, t)
U(x,0) = f(x), U_t(x,0) = g(x)

So the only difference is in u_x.

The solutions reached are the same for both (the solution in this thread and the one in my notes).

Is there anything wrong going on here? Or is this how it is supposed to be.

Oh I'm sorry, I didn't read your B.V. properly. In this case you got the B.V. for the derivatives so your boundary weren't correct as I said I'm afraid. You would need to differentiate ##X(x)## and apply them to that.

So what you want would be ##X'(0) = X'(l)=0##.

RJLiberator
d/dx (c_1*cos(λx) + c_2*sin(λx) ) = c_2*λ*cos(λx)-c_1*λ*sin(λx)

Boundary condition states u_x (0,t) = 0 = u_x (l,t)

so, we input x =0 into the derivative and get 0?
so c_2 = 0 and λ = n*pi/l
?

Seems correct now. The difference from before is you get a cosine series instead of a sine one.

RJLiberator
Yes, so now I understand how to use boundary conditions as I see the difference here.

The solution is thus:
u(x,t) = sum [ cos(n*pi*x/l) (a_n*cos(n*pi*c*t/l) + b_n*sin(n*pi*c*t/l) ]

and a_n and b_n are defined by the Fourier coefficients integrals.

That seems logical to me.
The answer requested for a nontrivial solution, but since we don't know what c is and have no further help, we can't solve it more than what we have.

Seems fine to me.
There's also another thing when you have boundary conditions like those above. Note that ##u(x,t) = c_1+c_2t## is also a solution to the wave equation and in this case your first two B.V. don't rule this out any more. So depending on ##f## and ##g## you may want to add that before the series.

If you apply the last two B.V. you also get from the first one that ##f(x) = \sum_{1}^\infty a_n\cos \frac{n\pi x}{l} ## and hence you can write
##a_n = \frac{2}{l} \int_0^l f(x) \cos \frac{n \pi x}{l} dx## and similar for ##b_n##.

RJLiberator