# SVM decision non linear

As I understand, to perform a decision in a non linear case (using a kernel) I use the following:

$f(x) = sgn(\sum_{i=1}^{n} y_{i} \alpha_{i} \boldsymbol{k}(x,x_{i})+b)$

Where i=1,..n are the encountered support vectors.

So if I want to classify a new incoming test data vector $x$, I must to make a sum among all the encountered support vectors. An example of the output of Weka when training with the iris-setosa database using the PUK kernel is:

Classifier for classes: Iris-setosa, Iris-versicolor

BinarySMO

-       1      * <0.222222 0.541667 0.118644 0.166667 > * X]
-       0.8281 * <0.388889 1 0.084746 0.125 > * X]
+       1      * <0.222222 0.208333 0.338983 0.416667 > * X]
-       1      * <0.055556 0.125 0.050847 0.083333 > * X]
-       0.1813 * <0.027778 0.375 0.067797 0.041667 > * X]
+       0.7577 * <0.166667 0.166667 0.389831 0.375 > * X]
+       0.2662 * <0.194444 0 0.423729 0.375 > * X]
-       0.1038 * <0.194444 0.416667 0.101695 0.041667 > * X]
+       0.6434 * <0.75 0.5 0.627119 0.541667 > * X]
-       0.1494 * <0.194444 0.625 0.101695 0.208333 > * X]
+       0.0376 * <0.472222 0.083333 0.508475 0.375 > * X]
+       0.5577 * <0.472222 0.583333 0.59322 0.625 > * X]
-       0.0052

Number of support vectors: 12


So for every test point, I must perform all the formula above, which already describes $y_{i}$ , $\alpha_{i}$ and the kernel operation required among the support vectors and $x$.

If I want to classify out of Weka, lets say in an app in android. Should I have a copy of all the encountered support vectors, $y_{i}$ , $\alpha_{i}$ and then do that opperation? or there is a way of evaluating only an hyperplane without requiring all the support vectors such as in the linear case?

For example, the next weka results are using the polykernel with exp=1.

classifier for classes: Iris-setosa, Iris-versicolor

BinarySMO

Machine linear: showing attribute weights, not support vectors.

0.6829 * (normalized) sepallength
+      -1.523  * (normalized) sepalwidth
+       2.2034 * (normalized) petallength
+       1.9272 * (normalized) petalwidth
-       0.7091


In this former case, I only evaluate the hyperplane but not across the support vectors.