solving tan(1/x)=1/tan(x)