Backpropagation in Sequential Deep Neural Networks