Calculation of weight on Earth and other planets