Ta có:
\(S=b^2-\left(a-c\right)^2\)
\(\Leftrightarrow\dfrac{1}{2}ac\sin B=a^2+c^2-2ac\cos B-a^2-c^2+2ac\)
\(\Leftrightarrow\dfrac{1}{2}ac\sin B=2ac\left(1-c\text{os}B\right)\)
\(\Leftrightarrow\sin B=4\left(1-c\text{os}B\right)\Leftrightarrow c\text{os}B=1-\dfrac{1}{4}sinB\left(1\right)\)
Mặt \(\ne:sin^2B+c\text{os}^2B=1\)
\(\Leftrightarrow sin^2B+\left(1-\dfrac{1}{4}sinB\right)^2=1\)
\(\Leftrightarrow\dfrac{17}{16}sin^2B-\dfrac{1}{2}sinB=0\)
\(\Leftrightarrow sinB=\dfrac{8}{17}\left(sinB>0\right)\)
Kết hợp với (1) ta đc: \(c\text{os}B=\dfrac{15}{17}\Rightarrow tanB=\dfrac{8}{15}\)