Neural Network
Stack layers of simple neurons with nonlinear activations and they learn the curved decision boundaries a single perceptron never could.
Neural Network
A single Perceptron can only carve space with a straight line. Stack many of them in layers, feed each layer's outputs into the next, and you get a neural network — a function flexible enough to bend boundaries into any shape and approximate essentially any mapping from inputs to outputs. This is the engine of modern deep learning, and a many-layered network is still, at heart, a multilayer perceptron.
Each layer does two things. First a linear step — a matrix multiply by the layer's weights plus a bias, \mathbf{z} = W\mathbf{x} + \mathbf{b}. Then a nonlinear activation applied elementwise, \mathbf{a} = \sigma(\mathbf{z}). That nonlinearity is the whole trick: without it, stacking linear layers would just collapse into one big linear map (and one straight boundary again). With it, depth lets the network compose simple bends into arbitrarily intricate curved boundaries.
Signals flowing forward
Computing a network's output is forward propagation: activations flow left to right, layer by layer, each neuron summing its weighted inputs and squashing the result. Below, an input layer feeds two hidden layers and an output; pulses trace the connections, blue for excitatory (positive) weights and orange for inhibitory (negative) ones, and neurons brighten as the wave of activation reaches them.
The nonlinearity is the magic
The activation function bends straight lines. A common choice is the hyperbolic tangent, which smoothly saturates large inputs toward \pm 1:
Train the weights — usually by Gradient Descent guided by Backpropagation — and a network with even one hidden layer becomes a universal approximator: given enough neurons it can represent any continuous function to any accuracy. Depth makes that representation efficient, building rich features as a hierarchy of simpler ones.