functions for picking rates and calculating conversions