Use double to do general computation