fixed delta x bug