I just saw this video of a mechanical calculator dividing by zero. Did any mechanical calculators or computers ever provide for a failure mode on divide by zero? Or did they always handle it by looping infinitely?

Did any of them have a certain check for the division, or error out on a certain amount of iterations?

  • 1
    Given that mechanical calculators would divide by repeated subtraction, possibly with shift, the natural reaction is a loop. Is it worthwhile to add additional mechanics to check for zero, and increase the price of the thing compared to the competition, when the user can easily make sure he never divides by zero? Probably not. So would mechanical calculators exist with this extra check? Probably not. – dirkt Jun 22 at 7:34
  • It's actually pretty easy to error out on overflow - Simply check for a carry on the uppermost digit and stop the machine. Not a big technical challenge. Some of the late Walthers I've seen that could do division had this. – tofro Jun 22 at 8:43
  • @tofro in theory easy to error out on overflow, yes. But how many extra gears do you need to fit for it? As far ad I know, each gear had some manual work in it, so the cost would be increased. I guess that many thought it was better to just add a warning in the manual. A reason to anyway have the check would be division that anyway would result in overflow. – UncleBod Jun 22 at 14:40
  • 2
    @tofro, btw, isn't your first comment an answer? Some did, but not all. – UncleBod Jun 22 at 15:27
  • 2
    @tofro Yeah; you should probably write that up as an answer, since answering in comments is problematic. – wizzwizz4 Jun 24 at 9:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.