I just realized that every time there is change it to . Sorry if I may have caused confusion.Another solution could be: is periodic. So, and must differ by some multiple of . i.e.
for the given domain, let :
. This is where I believe the answers in the textbook got the extra solutions of and from.
However, you are correct to exclude them because tan is undefined for those values.
Therefore the answer should be: