Added scaling functions to be used later