GATE DA 2026 · Support Vector Machine (SVM)

NAT · 2 marks · Problem ML-SVM-0007

A hard-margin support vector machine (SVM) is trained on three points in \(\mathbb{R}^2\): class \(+1\): \(\mathbf{x}_1 = (0, 0)^T\) and \(\mathbf{x}_2 = (2, 0)^T\); class \(-1\): \(\mathbf{x}_3 = (1, 1)^T\).The geometric margin of the optimal separating hyperplane (its distance to the nearest training point) is .

Numerical answer (NAT).

Solve it on GATE DA practice →More Supervised Learning — Classification problems

Show the worked solution\[\boxed{\text{geometric margin}=\frac{1}{\lVert\mathbf w\rVert}=\tfrac12\times\text{distance between the convex hulls of the two classes}}\]The positive hull is the segment from \((0,0)\) to \((2,0)\); its closest point to \((1,1)\) is \((1,0)\), at distance \(1\). The best hyperplane is the perpendicular bisector of this gap, \(y=0.5\), i.e. \(\mathbf w=(0,-2)\), \(b=1\).Check: \(y_i(\mathbf w^{\top}\mathbf x_i+b)=1\) for all three points, and \(\mathbf w=\sum_i\alpha_iy_i\mathbf x_i\), \(\sum_i\alpha_iy_i=0\) hold with \(\alpha=(1,1,2)\ge0\), so the KKT conditions are met.\[\text{margin}=\frac{1}{\lVert\mathbf w\rVert}=\frac12=0.5 .\](\(1\) is the full width \(2/\lVert\mathbf w\rVert\) between the two margin lines.)Answer: 0.5

GATE DA practice: past exam problems by chapter, with worked solutions · gatedaprep.com