With these gradients for the weights and biases calculated for all layers over a training set, weights and biases may be adjusted in each layer to optimise the network's output. These gradients are typically scaled by a learning rate 𝐾 𝑙 , which affects how quickly a model is trained in a trade off against potentially overshooting an optimal solution. Similarly, a learning momentum 𝐾 𝑚 may be applied to avoid the model stagnating in a local error minimum rather than finding the global error minimum. This is typically achieved by applying the error gradient calculated in a previous step, scaled by some factor (shown below for the weights 𝑾 of an arbitrary layer in equation 3. 10, but performed similarly for biases also). Δ𝑾 𝒏 (𝑖) = -𝐾 𝑙 ⋅ 𝜕𝑬 𝜕𝑾 𝒏 + 𝐾 𝑚 Δ𝑾 𝒏 (𝑖 -1) (3.9) 𝑾 𝒏 = 𝑾 𝒏 + Δ𝑾 𝒏 (𝑖) (3.10)