Input
Two numbers enter the network: x₁ = 1, x₂ = 0.50. Tap an input node to type another value.
Sum of the hidden layer
Each hidden neuron multiplies the two inputs by its own weights, adds them up and adds its bias: z₁ = 0.700, z₂ = 0.550. Together the four weights form a 2 × 2 matrix.
Activation of the hidden layer
The sums pass through the sigmoid and are squeezed between 0 and 1: h₁ = 0.668, h₂ = 0.634. These two numbers are new features the network draws from the input.
Sum of the output
The output neuron multiplies the hidden values by v₁ and v₂, adds them up and adds the bias c: z = 0.558. For the output the inputs are no longer x but h.
Output
z passes through the sigmoid and the network's prediction comes out: ŷ = 0.636. You can read it as the probability of class 1.
Loss
The target is t = 0. The squared error loss is L = ½ (ŷ − t)² = 0.202. The loss tells in one number how far the prediction is from the target; training tries to make this number smaller.
The same computation with matrices
All the steps fit in two lines: h = σ(W x + b) and ŷ = σ(v · h + c). W is the 2 × 2 weight matrix. Large networks compute exactly this; only the matrices grow, and the processor multiplies them fast.
Why it matters
The forward pass is both how a prediction is made and the first half of training. During training every intermediate value is kept, because backpropagation reuses these values when it computes the gradients.