>>James: Hello, everyone! Today you join me in Trinity College, Cambridge, with my guest today. This is Hugh Hunt, who will introduce himself.>>Hugh: Yes, I’m Hugh–hi! I’m a fellow of Trinity College. I’m a lecturer in the engineering department.>>James: And we’re here today in Hugh’s office which is a lot like my office, only much swankier! So it’s nothing like my office, in that case, apart from–>>Hugh: There’s lots of toys!>>James: Apart from having lots of toys, which is what we have in common. And this is one of Hugh’s toys, which is– he’s invited me over to see today. And this is one of those old mechanical calculators that they used to use in the early part of the 20th century. [calculator dings] And what is this called then? What’s its name?>>Hugh: Well, it’s called the Original Odhner.>>James: Odhner. Is it “odd-ner’ or ‘odd-en-er’?>>Hugh: Well, I don’t know.>>James: We’re not sure–we’re not sure. Can you tell me the history of this machine?>>Hugh: Well, these things date back to, I think, the late 1800’s.
>>James: Yep.>>Hugh: A Russian inventor came up with this mechanical adding machine,>>James: Right.>>Hugh: and really just worked out that multiplication is just glorified adding,>>James: Yes, yeah.>>Hugh: and division is glorified subtraction! And this was in the engineering department at Cambridge University,>>James: Mm-hmm. I see that.>>Hugh: It was probably in use for real, in the 1930’s, 1940’s, 1950’s. But then, when of course electronic– electrical computing machines came in, then in the 70’s and 80’s, then of course these things were just museum pieces. And I happen to have one.>>James: And you happen to have one, as well. Well, we’re not saying that you’re a museum piece, But– we are going to use this mechanical calculator today to do one of the more challenging operations, which is to find the square root of a number. But first of all, before we show you that, we’re going to show you some of the more basic operations. OK, so show me something simple. Show me how to add on this machine. So how do you add on a mechanical calculator like this?>>Hugh: Right. Well, let’s suppose I want–I’ve got a number like 4,698–>>James: Mm-hmm.>>Hugh: I key up for 4,698 onto here, and what I can do is just to crank this handle around once, and that’s added 4,698….
>>James: I can see it, yeah.>>Hugh: onto what was there before, which was zero. If I crank the handle around again, it adds it on.
>>James: So you’ve added it on twice.>>Hugh: Three times, four times. And it’s actually counting how many times I’ve added it on over here, so if I go five times, six times. Well, this is neat, because when I get to ten times, if I’ve added this number to itself ten times, well, I’ve just multiplied it by ten.>>James: So this shows that repeated addition is just another way to multiply.
>>Hugh: Mm-hmm.>>James: And that’s all we’re doing. So this is just repeated addition.>>Hugh: It is.
>>James: And how would we subtract with this?>>Hugh: Well, that’s easy. Just crank the handle backwards.>>James: I do like that! That’s really nice.>>Hugh: So I cranked the handle backwards ten times, and I’m back to zero.>>James: So if you want to subtract, you just turn the crank the opposite direction. That’s really easy. How would I divide a number with this machine?>>Hugh: So now, suppose I want to divide 4,698 by, say 162.>>James: OK.
>>Hugh: Well, what I’ll do is, first I’ll put that into this register here.
>>James: Right.>>Hugh: And now, I’m going to see how many times do I need to subtract 162?>>James: Right. So we’re dividing by 162–we’re just counting how many times we subtract it.>>Hugh: That’s right. Now, I could just put 162 into here, and then set my counter to count backwards for me, and I could just do this–one, two, three, four, five, and keep on going–I’m watching the number getting smaller and smaller and smaller, until eventually, there we are–zero.>>James: And so the answer is…
>>Hugh: 29.>>James: 29. So we got 29 on the counter here on the left-hand side. So if multiplication is just repeated addition, then I’m guessing that division is just repeated subtraction. OK, so now we’re going to work out the square root of a number, which is going to be a much more difficult thing to do. And there’s a nice little–surprising, really–little mathematical fact that you can do to work out the square root of a number.>>Hugh: That’s absolutely right, and it’s really nice. If I take the square root of something like four, then that’s 1 add 3.>>James: That is, yes.>>Hugh: If I take the square root of nine, that’s 1 add 3 add 5. The square root of 16 is one add three add five add seven.>>James: So you’re just adding up the odd numbers.>>Hugh: So if I’ve got 25 squares here,
>>James: Mm-hmm.>>Hugh: what I can do is I can work out that 25 is the square of 5 by subtracting 1 then 3 then 5 then 7 then 9. Five operations–5 must be the square root of 25.>>James: So to work out the square root of a number, you just subtract odd integers and the number of times you have to subtract is the answer.>>Hugh: And I can do that on this machine, so, for instance, I can put 25 into here, whiz that into the register there–OK. And now I go into subtracting mode, and so the first thing I’ll do is I’ll subtract off 1,>>James: OK.
>>Hugh: That gives us 24. Then I’ll subtract off 3. Then I’ll subtract off 5. Then I’ll subtract off 7. Then I’ll subtract off 9. And I’ve got nothing left. And how many times did I do it? Five. So 25 is a reasonably easy number. Let’s suppose I’ve got a number like 4489.
>>James: OK. 4489–that’s a big number.>>Hugh: Well, I happen to know that that’s 67 squared.
>>James: OK.>>Hugh: But what I’m interested to know is whether I can use some neat property of six and neat property of seven to get 4489. And what we discover is that 4489 is 60 squared,
>>Hugh: plus 7 squared,>>James: OK.
>>Hugh: plus two lots of 60 times 7.>>James: Ah!
>>Hugh: Now if I’m really careful, I can subtract off the 60 squared bit,>>James: Mm-hmm.>>Hugh: and I can subtract off the 7 squared bit, if I can keep track of the 2 lots of 60 times 7 then I’ve got my square root of 4489.>>James: So we know how to find the square root of 60 squared, we’ve worked that out. We know how to find the square root of 7 squared,
>>Hugh: 7 squared–>>James: and we just have to keep track of the rest of it. How would I do this if I wanted to work out something like the square root of 2?>>Hugh: Well, 67–there’s only two significant figures.
>>James: Mm-hmm.>>Hugh: So the square root of 4489, we didn’t have to do that many operations to get our answer of 67. Square root of 2 is 1.414…whatever, lots of decimal places. lots of significant figures. So if I want to get the square root of 2, I have to work quite a lot harder. So let’s–let’s just do it. The nice thing is the algorithm, the procedure, of looking after all those 20’s and 200’s is all done by the machine So I’m going to set up my two up here. Now, I’m putting it way up here because I need space to look after my decimal places. I need all this space to look after my decimal places. So now I’ve put the two into this register. Now I’m going to do my subtraction. [calculator dings] Now, that seems like black magic, and actually that’s what mathematics so often looks like, and the beauty of it, is that if you can decipher that black magic, suddenly, it’s just–boom! It’s obvious. And it’s just fantastic with this machine– it’s a way of keeping track of things that, if you had to do it by hand, you would make mistakes. [calculator noises–no speaking] So, 1.4142135.>>James: 35? So this is going to be our square root. You’re going to check that, are you?>>Hugh: 1.4142136–I’ve managed to calculate the square root of 2 to eight significant figures. on a machine that, really, all it can do is to add and subtract.