Changed binary functions into a single op case

Will reduce repetition in the future