added squared length L2 penalty, debugging results