fixed some math errors maybe?
fixed math errros