Perceptron - XOR

Overview


The XOR function is similar to the OR function, except that the value when both inputs is 1 is 0 in this case.
{% f(0,0) = 0 %}
{% f(0,1) = 1 %}
{% f(1,0) = 1 %}
{% f(1,1) = 0 %}

Linear Separability


The categories in the XOR function cannot be separated by a line.

No matter how the linear boundary is drawn, the pattern cannot be separated by a linear boundary.

Solution With Multiple Perceptrons


Two perceptrons can be used to separate the points. Each line recognizes a single point. The combined model will output a 1 if either perceptron outputs a 1.