todo: finish back propogation, vectorize cost function