Finding the scale factor