# Infinite square well energy

Hi

I have attached my attempt of solving the infinite square well for Energy. The value I get is different from that of the book, also in the attachment,
Kindly explain if my answer is correct given the fact that I proceeded step by step and used no tricks.
Thank you.

#### Attachments

• 20121116_194438.jpg
16.8 KB · Views: 416
• question.png
44.5 KB · Views: 437

You assumed the solution is of the form ψ = cos kx. There are also solutions of the form ψ = sin kx.

yes, but as you see in the excerpt of the book, they have proved that the the given E holds for cos(kx) too

I think my solution wrong because I have taken k*a/2 = (n+ 0.5)*pi
For the given situation, for x=a/2 for cos((n+ 0.5)*pi*x)=0 is only possible if n=0, but we are taking n>0.