# Homework Help: Homogenous PDE with separation of variables

1. Jul 21, 2011

### spaceknight

1. The problem statement, all variables and given/known data
Sorry don't know how to use the partial symbol, bear with me

partial u wrt t=2*(2nd partial u wrt x)

Boundary conditions:
partial u wrt x (0,t)=partial u wrt x (1,t)=0

Initial conditions
u(x,0)=x(1-x)

2. Relevant equations

I get an answer that is different than the solution manual, but I am convinced the solution manual is wrong, so I would just like it if anyone had the spare time to verify the solution for me. I do have a few minor questions though.

1. When solving for the eigenvalues, is n=0,1,2,3... or does n=1,2,3...? I ask this because I get 0 as an eigenvalue when doing the case for lambda=0, but technically this woulda already shown itself when I did the other case when I got the "real" eigenvalues because it was to solve sqrt(-lambda)=npi, so if n=0 that would have already been taken care of.

3. The attempt at a solution

I get F(x)=Cncosnpix and G(t)= e^(-2pi^2n^2t) When I solve the fourier series I used L=1 and got ao=-1/3 and an = (4(-1)^n) )/ (pi^2n^2)

2. Jul 21, 2011

### hunt_mat

So the equation you want to solve is:
$$\frac{\partial u}{\partial t}=2\frac{\partial^{2}u}{\partial x^{2}}$$
with
$$\frac{\partial u}{\partial x}(t,0)=\frac{\partial u}{\partial x}(t,1)=0$$
with initial condition $u(0,x)=x(1-x)$?

What are your steps?

3. Jul 21, 2011

### spaceknight

Yeah that's correct.

As for my steps, I just followed normal procedure of separation of variables so

assume solution is u(x,t)=F(x)G(t)

So G'/(2G)=F''/F=λ and my 2 ODEs are:

1. G'-2Gλ=0
2. F''-Fλ=0

Then I solve for F using the three cases, λ<0, λ=0, λ>0 and the boundary values F'(0)=F'(1)=0. The only case that is non trivial is the λ<0 case which is when I get my λn=-n^2pi^2 and my Fn=Ccos(npix). I then plug in λn back into the other ODE to solve for G and I get G=e^(-2pi^2n^2t), and then I take the infinite sum and make it equal to the initial conditions which makes it a fourier series representation. Then I apply the integration formulas to solve for the coefficients.

4. Jul 21, 2011

### hunt_mat

Going back to your questions you already took care of $\lambda =0$, so you can just have n=1,2,3...

Was that all the questions you had?

Mat

5. Jul 21, 2011

### spaceknight

Well, when I take the infinite series do I start from n=0 then because lambda=0 is included? Cause then I take the first term and I get the ao constant, which I'm assuming is suppose to happen but I just wanted to clarify.

And I was kinda hoping if someone would solve it so I can compare my answers because the solution manual has another answer that I have no idea how they got and there are no steps.

6. Jul 21, 2011

### hunt_mat

I think you can say that $\lambda <0$ straight away as otherwise the solution will grow exponentially with t. So write $\lambda =-\mu^{2}$ and you get the two solutions:
$$G=Ae^{-2\mu^{2}t},\quad F=B\cos\mu x+C\sin\mu x$$
As this is just one particular solution and there are an infinite many so write:
$$u=\sum_{n=0}^{\infty}A_{n}e^{-2\mu_{n}^{2}t}(B_{n}\cos\mu_{n} x+C_{n}\sin\mu_{n} x)$$
Was that what you did?

7. Jul 21, 2011

### spaceknight

Yeah except there's no sin

8. Jul 21, 2011

### LCKurtz

I think you should check again the case where λ = 0. I think you will find that a constant works. And that's what you would expect given that you will be expanding a function in a cosine series.

9. Jul 21, 2011

### spaceknight

I know lambda=0 does work, but since its a constant doesnt it just merge with the coefficient in F=Ccos(npix) if I start n=0,1,2,3...

10. Jul 22, 2011

### LCKurtz

Yes. It does give you the constant term of the FS.