# Coefficient solving for a PDE-eigenfunction

#### dwsmith

##### Well-known member
$$\varphi(x) = A\cos x\sqrt{\lambda} + B\frac{\sin x\sqrt{\lambda}}{\sqrt{\lambda}}$$

$$\text{B.C.} = \begin{cases} u(0,t) = u(L,t)\\u_x(0,t) = u_x(L,t)\end{cases}$$

Which leads to
$$A(1 - \cos L\sqrt{\lambda}) = B\frac{\sin L\sqrt{\lambda}}{\sqrt{\lambda}} \quad \text{and} \quad B(1 - \cos L\sqrt{\lambda}) = -A\sqrt{\lambda}\sin L\sqrt{\lambda}$$

I solved for B and obtained
$$B = \frac{-A\sqrt{\lambda}\sin L\sqrt{\lambda}}{1 - \cos L\sqrt{\lambda}}.$$

From this, I can substitute and get
$$A\left[(1 - \cos L\sqrt{\lambda})^2 - \sin^2 L\sqrt{\lambda}\right] = 0$$

So can I conclude A = 0? I am having a struggle to find A and B here so I can get the eigenfunction.

#### Ackbach

##### Indicium Physicus
Staff member
I have a few questions:

1. What is the original PDE?
2. Do you know what the time dependence is?
3. Are there constraints on where $A$, $B$, and $\lambda$ have to be? For example, do they all have to be real numbers?
4. If $A$, $B$, and $\lambda$ have to be real numbers, then you have some interesting things going on:

\begin{align*}AB\left(1-\cos\left(L\sqrt{\lambda}\right)\right)&=B^{2} \, \frac{ \sin\left( L \sqrt{\lambda}\right) }{ \sqrt{\lambda} }\\
AB \left( 1-\cos \left( L \sqrt{ \lambda} \right) \right)&=-A^{2} \sqrt{ \lambda } \sin \left( L \sqrt{ \lambda } \right)\implies
\end{align*}
$$B^{2} \, \frac{ \sin\left( L \sqrt{\lambda}\right) }{ \sqrt{\lambda} }=-A^{2} \sqrt{ \lambda } \sin \left( L \sqrt{ \lambda } \right).$$
This holds if either $\sin\left( L \sqrt{\lambda}\right)=0$ or $B^{2}=-A^{2}|\lambda|$. If the latter is true, then since everything is real, $A=B=0$, and you don't have eigenfunctions because everything is zero.

#### Opalg

##### MHB Oldtimer
Staff member
... I can substitute and get
$$A\left[(1 - \cos L\sqrt{\lambda})^2 - \sin^2 L\sqrt{\lambda}\right] = 0$$
That is correct except that it should be $A\left[(1 - \cos L\sqrt{\lambda})^2 \color{red}{+}\; \sin^2 L\sqrt{\lambda}\right] = 0.$

So can I conclude A = 0? I am having a struggle to find A and B here so I can get the eigenfunction.
No, because as Ackbach points out, that would imply that $B$ is also zero, so you get the zero function, which cannot be an eigenfunction. Therefore the only possibility is that $(1 - \cos L\sqrt{\lambda})^2 + \sin^2 L\sqrt{\lambda} = 0.$ Thus $\cos L\sqrt{\lambda} = 1$ and $\sin L\sqrt{\lambda} = 0$ and hence $L\sqrt{\lambda} = 2k\pi$ for some integer $k$. Hence $\lambda = \dfrac{4k^2\pi^2}{L^2}$, and those are the eigenvalues.

#### dwsmith

##### Well-known member
That is correct except that it should be $A\left[(1 - \cos L\sqrt{\lambda})^2 \color{red}{+}\; \sin^2 L\sqrt{\lambda}\right] = 0.$

No, because as Ackbach points out, that would imply that $B$ is also zero, so you get the zero function, which cannot be an eigenfunction. Therefore the only possibility is that $(1 - \cos L\sqrt{\lambda})^2 + \sin^2 L\sqrt{\lambda} = 0.$ Thus $\cos L\sqrt{\lambda} = 1$ and $\sin L\sqrt{\lambda} = 0$ and hence $L\sqrt{\lambda} = 2k\pi$ for some integer $k$. Hence $\lambda = \dfrac{4k^2\pi^2}{L^2}$, and those are the eigenvalues.
What is my $\varphi_n$ equation then? Is it the original equation?
So I would have

$$u(x,t) = \sum_{n=0}^{\infty}a_n\left(\cos x\sqrt{\lambda}+\frac{\sin x\sqrt{\lambda}}{\sqrt{\lambda}}\right)e^{-\lambda t}$$

---------- Post added at 11:42 ---------- Previous post was at 11:40 ----------

I have a few questions:

1. What is the original PDE?
2. Do you know what the time dependence is?
3. Are there constraints on where $A$, $B$, and $\lambda$ have to be? For example, do they all have to be real numbers?
4. If $A$, $B$, and $\lambda$ have to be real numbers, then you have some interesting things going on:

\begin{align*}AB\left(1-\cos\left(L\sqrt{\lambda}\right)\right)&=B^{2} \, \frac{ \sin\left( L \sqrt{\lambda}\right) }{ \sqrt{\lambda} }\\
AB \left( 1-\cos \left( L \sqrt{ \lambda} \right) \right)&=-A^{2} \sqrt{ \lambda } \sin \left( L \sqrt{ \lambda } \right)\implies
\end{align*}
$$B^{2} \, \frac{ \sin\left( L \sqrt{\lambda}\right) }{ \sqrt{\lambda} }=-A^{2} \sqrt{ \lambda } \sin \left( L \sqrt{ \lambda } \right).$$
This holds if either $\sin\left( L \sqrt{\lambda}\right)=0$ or $B^{2}=-A^{2}|\lambda|$. If the latter is true, then since everything is real, $A=B=0$, and you don't have eigenfunctions because everything is zero.
$u_{xx}=u_t$
The BC are above
The IC are
$$\begin{cases} u(x,0) = 1, & 0 < x < L/4\\ u(x,0) = 0, & L/4 < x < L\end{cases}$$

#### Opalg

##### MHB Oldtimer
Staff member
what is my $\varphi_n$ equation then? Is it the original equation?
So i would have

$$u(x,t) = \sum_{n=0}^{\infty}a_n\left(\cos x\sqrt{\lambda}+\frac{\sin x\sqrt{\lambda}}{\sqrt{\lambda}}\right)e^{-\lambda t}$$
What you should do here is to substitute $\sqrt\lambda = \dfrac{2n\pi}L$ to get the solution $$u(x,t) = \sum_{n=0}^{\infty}a_n\left(\cos \tfrac{2n\pi x}L +\tfrac L{2n\pi}\sin \tfrac{2n\pi x}L \right)e^{-4n^2\pi^2 t/L^2}.$$

#### dwsmith

##### Well-known member
What you should do here is to substitute $\sqrt\lambda = \dfrac{2n\pi}L$ to get the solution $$u(x,t) = \sum_{n=0}^{\infty}a_n\left(\cos \tfrac{2n\pi x}L +\tfrac L{2n\pi}\sin \tfrac{2n\pi x}L \right)e^{-4n^2\pi^2 t/L^2}.$$
I understand. I was trying to get a handle on $\varphi$.

---------- Post added at 12:00 ---------- Previous post was at 11:53 ----------

How can I contend for the IC?