Created
Apr 7, 2025
Last Modified
2 weeks ago

SVM

Support Vector Machine (SVM)

Support Vector Machine (SVM) is one of the most powerful supervised machine learning algorithms used for classification and regression tasks. The core idea behind SVM is simple yet elegant: it tries to find the best possible boundary that separates data points of different classes with maximum margin.

Support Vector Machine (SVM) Image Notehub

At the heart of SVM lies the concept of a hyperplane, which acts as a decision boundary in the feature space. Depending on the number of dimensions, this boundary takes different forms. In two dimensions, it is a straight line, while in three dimensions, it becomes a plane. In higher dimensions, it generalizes into what we call a hyperplane.

Equation of line



🔹 Support Vectors

The data points that are closest to the hyperplane.
These points directly influence the position and orientation of the hyperplane.

🔹 Hyperplane

A decision boundary that separates different classes in the feature space.
in
in

in
In higher dimensions → It's a hyperplane

This generalization allows SVM to work effectively even in high-dimensional datasets, which is one of its biggest strengths in real-world machine learning applications.

🔹 Equation of a Hyperplane (Line)

Projection of Vectors

Projection of vectors

📝 From the triangle OLB:

So,


🔷 Using Dot Product Formula:

So scalar projection becomes: