Question: Why does Maple return sometimes incorrect results for the imaginary part?

I am quite puzzled by the fact that Maple occasionally returns incorrect results when calculating the real and imaginary parts. I have attached an example script below. As shown, the returned value is erroneous unless the condition that k is real is explicitly specified.

Do you have any thoughts on this?

question.mw

Download question.mw

Please Wait...