Let P(x, y) be any point on line AB. Then,
Area of ∆ABP = 0
⇒ \(\frac{1}{2}\) \(\begin{vmatrix} 1 & 3 & 1\\ 0 & 0 & 1 \\ x & y & 1\end{vmatrix}\) = 0
⇒ \(\frac{1}{2}\) [1 (0 - y) - 3(0 - x) + 1(0 - 0)] = 0
⇒ 3x - y = 0
which is the required equation of AB.
Now, area ∆ABD = 3 sq. units

⇒ 1(0 - 0) - 3(0 - k) + 1(0 - 0) = ± 6
⇒ 3k = ± 6
Thus, k = ± 2