# Homework Help: Separation of variables wave equation

1. Dec 21, 2009

### coverband

1. Solve the wave equation u_(tt) = 4u_(xx) on the interval [0, π] subject to the
conditions
u(x, 0) = cos x, u_t(x, 0) = 1, u(0, t) = 0 = u(π, t).

2. Relevant equations

3. Hello. This appears to be a common separation of variables question. Only problem is after using the boundary conditions and initial conditions, I am left with an unknown constant.

So, after using 2 b.c. and first i.c. i'm left with U=∑_(n=1)^(n=∞)▒〖E_n Sin(nx)Cos2nt〗+F_n/2n Sin(2nt)Sin(nx)

The problem is when i use my last i.c. this tells me the value of constant E but I'm left with F!!!

2. Dec 21, 2009

### HallsofIvy

One problem you have is that the initial condition u(x,0)= cos(x) tells us that u(0,0)= 1 while the boundary condition u(0,t)= 0 tells us that u(0,0)= 0. That's not a crucial problem- it means that the solution cannot be continuous and so, strictly speaking, cannot satisfy the differential equation where it is not continuous.

It's impossible to tell what you might have done wrong because you haven't told us what you did! But it is not clear what you mean by "the first i.c." and "the second i.c." The two boundary conditions tell us that there is no "cos(nx}" in the solution and those alone give us
$$u(x,t)= \sum_{n=0}^\infty (E_n cos(2nt)+ F_n sin(2nt))sin(nx)$$

I would have thought of "$u_t(x,0)= 0$" as the "second" i.c. but that's the easy one:
$$u_t(x,t)= \sum_{n=0}^\infty (-2nE_n sin(2nt)+ 2nF_n cos(2nt))sin(nx)$$
so
$$u_t(x,0)= \sum_{n=0}^\infty 2nF_n sin(nx)= 0$$
so that Fn= 0 for all n.

The other i.c. becomes
$$u_t(x,0)= \sum_{n=0}^\infty E_n sin(nx)= cos(x)$$

To find E_n, for all n, do what you would do if you had
$$\sum_{n=0}^\infty E sin(nx)= F(x)$$
for any function F- write F(x) as a Fourier sine series. Here, of course, F(x)= cos(x) so you want to write cos(x) as a sine series! You are going to have discontinuities at x= 0 and $\pi$ but since you find the Fourier coefficients by integrating, that is not a problem.

3. Dec 29, 2009

### coverband

Hello

There is a mistake in your proposed solution. You wrote

when in fact if you reread the question:

$$u_t(x,0)= \sum_{n=0}^\infty 2nF_n sin(nx)= 1$$

Now. How would one go about solving for $$F_n$$ here!? Thanks

4. Dec 30, 2009

### HallsofIvy

You are right. I completely missed that. One way to find the coefficients is, of course, to expand "1" in a Fourier sine series.