Find the Eigen value and Eigen function of the BVP $ \ y''+\lambda^2 y=0 \ , \ y(\pi)=0, \ \ y'( 3\pi )=0 \ $.
Answer:
For $ \ \lambda =0 \ $ , we get trivial solution.
For $ \lambda \neq 0 \ $ , the general solution is
$ y(x)=A \cos (\lambda x)+B \sin (\lambda x) \ $ ,
where $ \ A,B \ $ are arbitrary constants
Now satisfying the condition $ \ y(\pi)=0 \ \ $, we get
$ A \cos (\lambda \pi)+B \sin (\lambda \pi)=0 \ .......(1) $
Similarly using $ y'(3 \pi)=0 \ $ , we get
$ -A \cos (\lambda \pi)+B \sin (\lambda \pi)=0 \ ,.......(2) $
But I can not eliminate $ \ A,B \ $ from (1) and (2) in order to find the eigen value and eigen function.
help me doing this.
For convenience, we'll shift the solution so that the first boundary condition is at the origin. Set $t = x - \pi$ to get
$$ y''(t) + \lambda^2 y(t) = 0, \ y(0) = 0, y'(2\pi) = 0 $$
This obviously gives
$$ y(t) = A\cos(\lambda t) + B\sin(\lambda t) $$
The first B.C. gives $$ y(0) = A = 0 $$
The remaining constant is negligible (since the eigenfunction can be scaled up), therefore $$ y(t) = \sin(\lambda t) $$
The second and final B.C then gives $$ y'(2\pi) = \lambda \cos(2\pi \lambda) = 0 $$
This is achieved if $$ 2\pi \lambda = (2n+1)\frac{\pi}{2} $$
Then $$ \lambda_n = \frac{2n+1}{4} $$
And the final solution is $$ y_n(t) = y_n(x-\pi) = \sin\left[\frac{2n+1}{4}(x-\pi)\right] $$
EDIT: If you don't like this solution, you can do it the "normal" way. But first note that your second boundary equation is wrong, since $$ y'(x) = \lambda\big[{-A}\sin(\lambda x) + B\cos(\lambda x)\big] $$
Then $$ y'(3\pi) = 0 \implies -A\sin(3\pi\lambda) + B\cos(3\pi\lambda) = 0 $$
The system can be expressed as a matrix equation $$ \left[\begin{matrix} \cos(\pi\lambda) & \sin(\pi\lambda) \\ -\sin(3\pi\lambda) & \cos(3\pi\lambda) \end{matrix}\right] \left[\begin{matrix} A \\ B \end{matrix}\right] = M\left[\begin{matrix} A \\ B \end{matrix}\right] = 0 $$
If $\det(M) \ne 0$, then the only solution is $A=B=0$, which we don't want, so it must follow that $ \det(M) = 0 $ which gives
$$ \cos(\pi\lambda)\cos(3\pi\lambda) + \sin(\pi\lambda)\sin(3\pi\lambda) = \cos(2\pi\lambda) = 0 $$
This gives the same eigenvalues as above $$ \lambda_n = \frac{2n+1}{4} $$
You can then assign an arbitrary solution for the pair $(A,B)$ such that they satisfy one of the equations. Since $\det(M) = 0$, the remaining equation will automatically hold. So let's put $$ A = -\sin(\pi\lambda_n), B = \cos(\pi\lambda_n) $$
This gives
$$ y(x) = -\sin(\pi\lambda_n)\cos(\lambda x) + \cos(\pi\lambda_n)\sin(\lambda_n x) = \sin(\lambda_n(x-\pi)) $$
which shows why shifting the solution from the beginning is much better.