added softmax and fast row update functions