This works but I can't seem to get the factor of 2 right.