Effect of distance on gravity