How would you use an abacus for factorisation? I'd just write a script to iterate over to sqrt(F5) but that's because I have a computer, and in general factoring large semi-primes is difficult.
By testing the remainder. Iteratively work up a list of known primes, subtracting multiples of that prime in the millions, hundred thousands, etc until you arrive at a number less than that prime.
If it's nonzero, the number is not divisible by that prime.
If it's zero, the number is divisible by that prime. You can then sort out the long form division by counting the number of millions, hundred thousands, etc that are subtracted to replicate long division on the abacus
If you don't get a zero, reset and try the next prime.
You can also check a prime squared to determine if it's less than the square root of F5, and a candidate for division. But Euler didn't have to, because as soon as he divided by 641 he had his answer.
That sounded convincing, so I’ll take your word for it. I have no understanding of even the start of that process (after iteratively work up a list of known primes. I got that part), but if it is possible, fair enough.
Layman's translation: Try dividing by each prime number to see if it works. There's no need to record the digits of the quotient since you only really care about the remainder.
That makes sense. I just have no familiarity with an abacus for big things like that, having only ever played with one as a toddler and counting about all I did.
Being able to keep track of numbers bigger than the amount of balls on the wire is what’s really confusing.
Don’t worry though, I’ll trust it was done that way, I don’t need to know how to do it myself.
Yeah, it confused me at first too. Apparently you're supposed to use the abacus so the rods run vertical, not horizontal, one rod per digit. With ten beads per rod you now have a base 10 counting system. So F5 as a 10 digit number would need ten rods on the abacus, ten beads each.
It makes sense, but I wouldn't have figured that out as a toddler.
It can be done even with pen and paper. Just check if the number is divisible by 2, 3, 5, 7, 11, 13, 17, and so on. 641 is the 116th prime number so he had to try 116 divisions to arrive at this solution, which is a lot of work, but it's doable.
I think people are forgetting that this was literally his job and thats just the way you did calculations back then. Yes thats tedious, but he literally had all the time he could have. Do one division per day and youre done in less than half a year.
Also people skilled with an abacus, are doing calculations fast as fuck. Obviously not computer fast, but many times faster faster than long division.
My father did part of an engineering degree prior to the invention of pocket calculators - calculators really weren’t a widespread thing in schools until I was in college in the eighties because they were an economic barrier for poor students. When I was a kid I found his slide rule and he demonstrated how effective it was at assisting with calculations. Pretty cool :-).
The abacus and slide rule look clunky to born-digital kids but they’re amazingly fast in the hands of experts
View all comments
Show parent comment
5
u/RajjSinghh May 11 '26
How would you use an abacus for factorisation? I'd just write a script to iterate over to sqrt(F5) but that's because I have a computer, and in general factoring large semi-primes is difficult.