5

I study SVM

It's known that the distance between two hyperplanes is $\frac{2}{\left \| w \right \|}$.

The problem is I cannot prove this. Let's start. We have two hyperplanes

$w \cdot x +b = 1$ and $w \cdot x +b = -1$

A plane is defined by $n$ and $r_0$, where $n$ is a vector from $r_0$ that is perpendicular to the plane and $r_0$ is the point on the plane.

For every point $r$ on the plane $n\cdot(r-r_0)=0$

In our case $n$ is $w$.

Case:1 $w \cdot x +b -1 =0$; $n\cdot r - n \cdot r_0 = 0$ ; $w \cdot r_0=1-b$

Case:2 $w \cdot x +b +1 =0$; $n\cdot r - n \cdot r_1 = 0$ ; $w \cdot r_1=-b-1$

So, $w(r_0-r_1)=2; r_0-r_1=\frac{2}{w};$

I feel like I am close to the proof, but still I have to ensure that a line of $r_0$ and $r_1$ is perpendicular to hyperplanes. Another point $(r_0 - r_1)$ does not define a distance, it defines a vector. It would be great if could finish my proof or publish yours.

com
  • 5,612

1 Answers1

5

The closest distance of a hyper-plane $w\cdot x + b = 0$ to the origin is given by $\frac{|b|}{||w||}$ .

If you want to see the proof, look here: https://en.wikipedia.org/wiki/Distance_from_a_point_to_a_plane

Thus the closest distance to the origin for w.x +b = 1 is given by $\frac{|1-b|}{||w||}$ and for $w\cdot x + b = -1$ it is given by $\frac{|-1-b|}{||w||}$ .

Thus the distance between the two hyper-planes is given by the difference which is $\frac{2}{||w||}$ .

GR4
  • 151