Kirby wrote:I bet Araban's solution takes advantage of the 20 bystanders. There are 20 possible digits (10 per x).
Maybe I'm too pessimistic, but given 20 random adults, I'd expect maybe 10 of them to be able to get a 10 digit multiplication problem correct in 25 minutes under that kind of pressure.
Re: Arithmetic problem from Tobaku Haouden Zero.
Posted: Wed Jul 20, 2011 9:24 am
by ChradH
This reminds me of an interpolation method I learned some 30 years ago It gives one digit per iteration:
1.41421356 is too small (too short), and 1.41421357 is already too big, so lets take them for lower bound 'L' and upper bound 'U', respectively.
Calculate L^2 and U^2 and see where our goal 2 lies in between:
Let x = (2 - L^2) / (U^2 - L^2) = 0.237... for values above. Take first digit after the decimal point as the next digit of the root: 1.414213562 and repeat.
Next iteration gives 1.4142135623.
That's two (long) multiplications and one (shorter) division per iteration. As we need only the first digit of x, it might even be possible to break the multiplications off early when they have reached enough significant digits.
In any case this should be possible with pencil and paper in 25 minutes. I used a calculator, of course A really cool solution would use those 20 people around
Re: Arithmetic problem from Tobaku Haouden Zero.
Posted: Wed Jul 20, 2011 9:29 am
by Cassandra
Kirby wrote:I bet Araban's solution takes advantage of the 20 bystanders. There are 20 possible digits (10 per x).
If there are enough pencils and paper, parallel processing might be possible.
There are 20 helpers, so let them calculate the squares with
xx = 00, 05, 10, ... , 95.
After the first run, the hero will find that 20 gives a result below 2, 25 a result above.
For the second run, the hero can let his helpers calculate in steps of .4, i. e. 20.4, 20.8, 21.2, ..., with the result that 23.6 is below and 24.0 is above 2.
The third, and decisive, run is the one for the hero, who calculates 23.9, with a result above 2.
So he can be sure that xx is 23.
Re: Arithmetic problem from Tobaku Haouden Zero.
Posted: Wed Jul 20, 2011 10:54 am
by BobC
I think you can bastardise Taylors theorem for this. Take given: 1.41421356
1.41421356 - square it.. then turn the 56 into 57 - square it ( with one f the helpers) then turn 56 into 565 - square it.. compare answers to 2 then interpolate and repeat with increasing precision...
it's like playing the "hi lo guess a number game". Should get it out in about 7 squares..
Re: Arithmetic problem from Tobaku Haouden Zero.
Posted: Wed Jul 20, 2011 5:59 pm
by hyperpape
This could be personal preference, but it feels easier to use the formula for square of sums, then subtract and do division, using a lot of "safe" approximations.
[1] (a + b)^2 = a^2 + 2ab + b^2.
[2] a = 1.41421356
[3] a ^ 2 = 1.99999999328
[4] 2 - a ^ 2 = 67.2... * 10 ^-9 (as far as the calculation is concerned, you can forget the -9).
[5] 67.2 / 2a ≈ 23
[6] b = 2.3 * 10^-9
=========
At [3], the b^2 term is extremely small. Unless 2 - a^2 looks wrong, you can ignore it.
You can do [5] with all the digits of the 67.2... term, as well as all the digits of a. But you're almost certainly not going to need them all. I'd start with 67.2 / 1.41 and see whether I might need to backtrack.
Re: Arithmetic problem from Tobaku Haouden Zero.
Posted: Wed Jul 20, 2011 5:59 pm
by hyperpape
Oh, and if we want to test ourselves, someone should give us all the first 8 digits of 3 ^ (1/2)...
Re: Arithmetic problem from Tobaku Haouden Zero.
Posted: Wed Jul 20, 2011 6:58 pm
by daniel_the_smith
OK, go for it: 1.73205081
Edit: I tried calculating the above by hand with newton's method. I made a mistake somewhere. But using newton's method with a calculator, I got it correct. OK, I will try getting two more places by hand.
Re: Arithmetic problem from Tobaku Haouden Zero.
Posted: Wed Jul 20, 2011 7:53 pm
by hyperpape
Owwwww! I did that by hand. I believe 1.73205081 ^ 2 = 3.0000000084211561 (Python reports it as 3.0000000084216563, which fails a basic sanity check).
So we're a victim of rounding. We wanted 1.73205080.
Also, an important question is whether they have graph paper and what their handwriting is like. I did my first try on notebook paper, and it got out of alignment while I was squaring 1.73...
Re: Arithmetic problem from Tobaku Haouden Zero.
Posted: Wed Jul 20, 2011 7:57 pm
by illluck
I just tried to use the a^2+2ab approximation for root 3 by hand. It took me 20 minutes to do the calculations (my math sucks) and I made a mistake in there. Using a calculator, though, it does seem like the approximation is good enough.
Re: Arithmetic problem from Tobaku Haouden Zero.
Posted: Wed Jul 20, 2011 8:19 pm
by daniel_the_smith
hyperpape wrote:Owwwww! I did that by hand. I believe 1.73205081 ^ 2 = 3.0000000084211561 (Python reports it as 3.0000000084216563, which fails a basic sanity check).
So we're a victim of rounding. We wanted 1.73205080.
Also, an important question is whether they have graph paper and what their handwriting is like. I did my first try on notebook paper, and it got out of alignment while I was squaring 1.73...
Yeah, I realized it was evil to round it, but: someone already mentioned that the given digits might have been rounded, and ordinarily I would round a number like that if giving it to N digits, so...
I decided I didn't have the patience to try this by hand and instead wrote a computer program to calculate square roots to arbitrary precision. Here's the fist 100k digits of sqrt(3): http://pastebin.com/6aV2Dn68
Re: Arithmetic problem from Tobaku Haouden Zero.
Posted: Wed Jul 20, 2011 8:36 pm
by illluck
@hyperpape: My manual calculations give something close to the python result - 3.0000000084216561. I completely messed up the long division - I see no less than 3 errors in calculating 4 digits XD
For someone who doesn't fail as horribly as I do at math, though, the approximation is quite possible to do in 20 minutes (perhaps even less time, I had problems with aligning figures - would have been a good idea to just drew straight lines as grids).
Re: Arithmetic problem from Tobaku Haouden Zero.
Posted: Fri Jul 22, 2011 7:05 am
by Cassandra
I think, hyperpage's suggestion of
b = (2 - a * a) / (2 * a)
provides the fastest method, and it surely can be done in 25 minutes.
@ Araban: What method has been choosen by the Hero ?
Re: Arithmetic problem from Tobaku Haouden Zero.
Posted: Fri Jul 22, 2011 12:12 pm
by Solomon
Zero's method:
A lot less sophisticated than some of the answers here . He begins by multiplying 1.414213560 by itself. He uses the other people in the room to do the same calculation for verification. Next, he uses an arithmetic rule regarding multiplication of numbers differing by 1 value. Simply, once you know what 1414213560 * 1414213560 is, to check 1414213561 * 1414213561, you need to only add (1414213560 + 1414213560 + 1) to 1414213560 * 1414213560. In other words: 1414213560 * 1414213560 + 1414213560 + 1414213560 + 1 = 1414213561 * 1414213561
He decides to start with 2 for the 9th digit based on the answer he got for 1414213560 * 1414213560, which is 1.999999993287873600. Using the rule, he arrives at 1.999999998944727844. With 11:53 minutes left on the clock, he applies the same rule once again to arrive at 3 for his 10th digit:
In the game he was allowed 2 tries to determine the 'password' (the 9th and 10th digits). He uses 23 for his first try, only to realize he had to round it up based on:
Hence arriving at 24 as the correct password. If anyone's confused about what I said or want more detail (or just want to read the story), you can read the part in the manga here: http://www.mangafox.com/manga/tobaku_ha ... .2/96.html
Re: Arithmetic problem from Tobaku Haouden Zero.
Posted: Fri Jul 22, 2011 1:26 pm
by daniel_the_smith
First 8 digits of square root of five per Google: 2.23606798 (in case someone wants to try Zero's method)
Re: Arithmetic problem from Tobaku Haouden Zero.
Posted: Fri Jul 22, 2011 2:09 pm
by Solomon
daniel_the_smith wrote:First 8 digits of square root of five per Google: 2.23606798 (in case someone wants to try Zero's method)
Sigh...I actually did take the time to multiply this by itself by hand, only to get 5.0000000111812804, which had me confused because it had to be < 5. So I checked the first 8 digits of sqrt(5), only to realize that Google rounded up the 8th digit so the first 8 digits of sqrt(5) is actually 2.23606797__.
Those are 11 minutes I'm never getting back daniel_the_smith .