`p=(sinA)/(sinB)` and
`therefore p/q=(sinA//sinB)/(cosA//cosB)= (sinA)/(sinB).(cosB)/(sinB)`
`=tanA. cotB=tanA. 1/(tanB)=(tanA)/(tanB)`
`rArr (tanA)/p = (tanB)/(q)=k` (say)
`rArr tanA=p.k` and `tan B=q.k`
Now `(sinA)/(sinB)=p`
`rArr sinA=sinB`
`rArr (sinA)/(cosA. secA)= (p.sinA)/(cosB.secB)`
`rArr (tanA)/(sqrt(sec^(2)A))= (p.tanB)/(sqrt(sec^(2)B))`
`rArr (tanA)/(sqrt(1+tan^(2)A))= (ptanB)/(sqrt(sec^(2)B))`
`rArr (tanA)/(sqrt(1+tan^(2)A))=(ptanB)/(sqrt(1+tan^(2)B))`
`rArr (pk)/(sqrt(1+p^(2)k^(2)))= (p.qk)/(sqrt(1+q^(2)k^(2)))`
`rArr sqrt(1+q^(2)k^(2))=qsqrt(1+p^(2)k^(2))`
`rArr 1+q^(2)k^(2)=q^(2)(1+p^(2)k^(2))`
`= q^(2)+p^(2)q^(2)k^(2)`
`rArr q^(2)k^(2)(1-p^(2))=q^(2)-1`
`rArr k^(2)=(q^(2)-1)/(q^(2)(1-p^(2))`
`rArr k= +-1/qsqrt((q^(2)-1)/(1-p^(2)))`
`therefore tan A = +- p/q sqrt((q^(2)-1)/(1-p^(2)))`
and `tan B=+-sqrt((q^(2)-1)/(1-p^(2)))` Ans.