You are correct that

but remember to equate the real parts as well as the imaginary parts

so

equating real parts as well gives us

now solve the two equations simultaneously to find the answer

as an aside you can always check your answer by plugging a few numbers in, if we try a=1 b=-0.5 which satisfy your condition we have

therefore it cannot be correct on its own