\(\dfrac{\tan A}{\tan B}=\dfrac{\sin A}{\cos A}.\dfrac{\cos B}{\sin B}=\dfrac{\dfrac{a.\sin B}{b}\left(\dfrac{a^2+c^2-b^2}{2ac}\right)}{\dfrac{b^2+c^2-a^2}{2bc}.\sin B}=\dfrac{\dfrac{\sin B.\left(a^2+c^2-b^2\right)}{2bc}}{\dfrac{\sin B.\left(b^2+c^2-a^2\right)}{2bc}}=\dfrac{a^2+c^2-b^2}{b^2+c^2-a^2}\)