Update NeuralNetworks.groovy

Added Error Function for each node.