## Thursday, 10 February 2011

### Numerical approximation II

I found that Q8 in the last passage was quite interesting so I'm going to discuss the question a bit.
1) Modolus approximation
Recall the four equation:
Find the smallest possible integer n>2 s.t.
i) {n^0.5-2^0.5}< 0.01
ii) {|n^0.5-2^0.5|}<0.01
iii) {n^0.5-2^0.5}<0.0001
iv) {|n^0.5-2^0.5|}<0.0001
Now let's modify the question to:
i) {n^0.5-2^0.5}<0.01
ii) {2^0.5-n^0.5}<0.01
iii) {n^0.5-2^0.5}<0.0001
iv) {2^0.5-n^0.5}<0.0001
Now consider the easier one {2^0.5-n^0.5}<0.01.
2^0.5\ < n^0.5 + 0.01 +a
1.4042  < n^0.5 + a
Square:
1.97 < (n+a^2) + 2an^0.5
This may help us to estimate the level of error (like the big O function)
Now the error level is 0.01 so after root squaring it becomes 0.1.
{n^0.5- 2^0.5} < 0.1 ~ 0
n = (a^2+2) + 2a2^0.5 where a is an integer
{0.8284a} < 0.1
Magifying the system, 8284a < 1000 mod 10000
Though they are all multiple of 4, it's still troublesome to get all solutions of a.
Here's the result with (=a mod 10000, a), readers can observe why only these numbers were selected.
(4,2331)
(8,2162)
(56,134)
(60,-35=2465)
(116,99)
(236,29)
(298,-6=2494)
(352,128)
(532,23)
(828,17)
The smallest a is 17, so we will have n ~ (17+2^0.5)^2 ~ 339
{2^0.5 - 339^0.5} = 0.00226... which is true.
Similarly, {2^0.5 - n^0.5} < 0.0001 is equivalent to 8284a < 100 mod 10000, which a = 134.
(134+2^0.5)^2 ~ 18337
{2^0.5-18337^0.5} = 0.00003 which is also true.

2) Differentiatial approximation
The formula is given by f(x+h) ~ f(x) + hf'(x)
Here's an simple example:
Estimate sin (pi/90).
we have sin (pi/90) ~ sin 0 + (pi/90)(sin 0)' = pi/90 ~ 0.3490
while sin (pi/90) ~ 0.03489, quite accurate!

Exercise
1) Complete {n^0.5-2^0.5}<0.01 and {n^0.5-2^0.5}<0.0001.
2) How many digits of 2^0.5 you should approximate to find n that {n^0.5-2^0.5}<10^-6?
3) Show that the answer obtained (339 and 18337) is really the smallest solution.
4) Show that there exist integer solution(s) in every interval [x^2,(x+1)^2] (x is real >2) which {n^0.5-2^0.5}<0.1.
5) Given tan (57pi/180) = 1.539864964..., find the smallest integer n such that {|tan (17n pi/180) - tan 57pi/180|} < 0.01 (four cases, same as {n^0.5-2^0.5})
6) Estimate 2^ 0.0101.
7) Estimate sin 79pi/180, suppose all value of sin x is NOT WELL KNOWN except sin 0 = 0 and sin pi/2 = 1. (Mean value theorem's approximation?)
8) Select integer p,q which is not bigger than 1000, in which (p/q)^2 is closet to 2. Now the n d.p. correction of (p/q) and 2^0.5 takes different value. Find the smallest n. (modified IMO prelim mock, 3M)