I am trying to practice for an exam that will have material involving separation of variables with the heat equation. While searching for practice problems on the internet, I found this pdf of homework from the University of Tennessee Knoxville: https://web.math.utk.edu/~heather/435_Homework6_summer_solns.pdf . I am a little confused as to how they arrived at a derivation for the X(x) equation and was wondering if anyone could clear this up for me.
Question #1 asks to solve $u_{xx} + u_{yy} = 0$ on the rectangle $0<x<2$, $0<y<3$ with boundary conditions:
$u_{x}(0,y)=0$ | $u_{x}(2,y)=0$ | $u(x,0)=0$ | $u(x,3)=3x$
Now I get how to separate the variables and get: $X'' = \lambda X$ and $Y'' = - \lambda Y $, and how you want to look at cases of $\lambda$ being positive, negative, and zero. But I am confused with a calculation that they show when $\lambda < 0$.
So for what I understand is that since $\lambda < 0$, that means that $\lambda = -\beta^2$ for some $\beta > 0$. Meaning that you will have the equation for X of:
$X'' = -\beta^2 X$, which has a solution of:
$X = C_1cos(\beta x) + C_2sin(\beta x)$, and taking the derivative gives you:
$X' = \beta (-C_1 sin(\beta x) + C_2 cos(\beta x))$. And from there using the boundary condition $u_{x}(0,y) = X'(0) = 0$, you will get:
$X'(0) = \beta(0 + C_2) = \beta C_2 = 0$, showing that $C_2 = 0$. They also state that using the boundary conditions will yield:
$2\beta = n\pi, \beta = \frac{n\pi}{2}$. This is where I am confused. How did they get that $2\beta = n\pi$ from the boundary conditions?
The function $\sin(x)$ is zero at $x=n\pi$, so your boundary condition $X'(2)=0$ gives $X'(2)=-\beta \,C_{1}\sin(2\beta)=-\beta \,C_{1}\sin(n\pi)=0,\,\implies \beta=n\pi/2.$