Subscribe via feed.

What a difference

Posted by Chris on April 7, 2011 – 6:40 am

If m and n are positive integers and 33^m – 7^n = d, what is the smallest magnitude of d if d is positive and if d is negative? (That’s two questions).


This post is under “MathsChallenge” and has 16 respond so far.
If you enjoy this article, make sure you subscribe to my RSS Feed.

16 Responds so far- Add one»

  1. 1. DP Said:

    it appears we are looking for something better than the quick answer of 33^1 – 7^1 = 26 & 33^1 – 7^2 = -16. This might take some itterations…I’ll be back if no one gets to the answer before me.

  2. 2. Andy Said:

    I think I might have the positive part. At least through 1000 integers

    d = 33^m -7^n
    solving this equation for zero
    0 = 33^m – 7^n
    7^n = 33^m
    n*ln(7)=m*ln(33)
    n = m * ln(33)/ln(7) gives the equation wehre d = 0
    aprox = 1.797
    To find the integers that get me closest to this line,
    i divided all of the integers between 1 and 1000 by this value.
    find where ((n/1.797)-round(n/1.797,0)) is at a minimum
    This gives m = 64 and n = 115 (the rounded value is n)

  3. 3. Andy Said:

    I have now convinced myself I am wrong. Using the same method for the 1st 1 million integers i get:

    n = 605,231
    m = 336,829

    whic i also believe to be incorrect or at best a limited solution.

  4. 4. Chris Said:

    Hi all. If you only use a computer, unless you get 0, you’ll never be sure if there’s a smaller value.

  5. 5. John24 Said:

    I have to go with DP on this one. 26 and -16 given how fast these numbers increase in size it seems very unlikely to get closer to 0 thand 26 and -16.

    Powers of seven
    2 49
    3 343
    4 2401
    5 16807
    6 117649
    7 823543
    8 5764801
    9 40353607
    10 282475249
    11 1977326743
    12 1 3841287201
    13 9 6889010407
    14 67 8223072849
    15 474 7561509943
    16 3323 2930569601
    17 23263 0513987207
    18 162841 3597910449
    19 1139889 5185373143
    20 7979226 6297612001
    21 55854586 4083284007
    22 390982104 8582988049
    23 2736874734 0080916343
    24 1 9158123138 0566414401
    25 13 4106861966 3964900807
    26 93 8748033764 7754305649
    27 657 1236236353 4280139543
    28 4599 8653654473 9960976801
    29 32199 0575581317 9726837607
    30 225393 4029069225 8087863249
    31 1577753 8203484580 6615042743
    32 11044276 7424392064 6305299201
    33 77309937 1970744452 4137094407
    34 541169560 3795211166 8959660849
    35 3788186922 6566478168 2717625943
    36 2 6517308458 5965347177 9023381601
    37 18 5621159210 1757430245 3163671207
    38 129 9348114471 2302011717 2145698449
    39 909 5436801298 6114082020 5019889143
    40 6366 8057609090 2798574143 5139224001
    41 44567 6403263631 9590019004 5974568007
    42 311973 4822845423 7130133032 1821976049
    43 2183814 3759917965 9910931225 2753832343
    44 15286700 6319425761 9376518576 9276826401
    45 107006904 4235980333 5635630038 4937784807
    46 749048330 9651862334 9449410269 4564493649
    47 5243338316 7563036344 6145871886 1951455543

  6. 6. cazayoux Said:

    I believe, that given the growing gap that you see, it is possible, if not likely, that the power of one will ‘lap’ the other. I mean that this gap will not continue to only get larger, but may reach a point that the delta could jump to a much smaller number.

    I’m anxious to look into it more.

  7. 7. Chris Said:

    OK, here’s a bone – modulo arithmetic.

  8. 8. Chris Said:

    Another bone. Try mod 16 (^^) and one other.

  9. 9. Chris Said:

    A solution. DP had correctly identified the values, but obviously didn’t know that this really was the best that could be done.

    33m – 7n. In modulo 16 we get 33m = 1m = 1, for all m ≥ 0.
    As 72 = 49 = 1 (mod 16), we get for even n that 33m – 7n = 0 (mod 16)
    and for odd n we get 33m – 7n = -6 = 10 (mod 16).

    So if n is odd, 33m – 7n must be of the form 16p+10 =>
    …,-54,-38,-22,-6,10,26,42,58,74,… and if n is even 33m-7n must be of
    the form 16p => …,-48,-32,-16,0,16,32,48,…

    Now try mod 3 (say). Then 33m – 7n = 0 – 1 = 2 (mod 3), all m,n.
    So 33m – 7n must be of the form 3p+2 => …,-19,-16,-13,-10,-7,-4,-1,
    2,5,8,11,14,17,20,23,26,27,30,…

    Clearly, candidate results must be common to both lists. We find -16 and +26 satisfy that, and fortunately, it is pretty easy to see that m = n = 1 =>
    33m – 7n = 26; and m = 1, n = 2 => 33^m-7^n = -16.

    This doesn’t let us readily see if other values of m,n do the job (or even if there are other values).

    That was a Harvard grade problem.

  10. 10. Abhinav Said:

    26 and -16 are the answers

  11. 11. Chris Said:

    Hi Abhinav. That’s right, but how do you know that?

  12. 12. Chris Said:

    Just for a giggle I’ve tried brute force, but with some cunning, to see if another m,n pair can give 26.

    We want 33m – 7n = 26 => 7n = 7 (mod 33). Euler’s generalisation of Fermat’s Lttle Theorem => 7^20 = 1 (mod 33). Where 20 = φ(33), and φ() is Euler’s totient function. A couple of checks shows that there is no smaller power (other than the trivial 0) that does it. So n has to be of the form 20p + 1, to give 33m – 720p+1 = 26.

    That can be solved for m as m = log(26 + 720p+1)/log(33).
    That is equivalent to log_base_33(26 + 720p+1).

    I actually wrote this as (Mathematica code):

    For[p = 0, p < 100 000, p++, {
        m = Round[Log[33, 26 + 7^(1 + 20 p)]],
        If[33^m - 7^(1 + 20 p) == 26, Print[m, " ", 33^m - 7^(1 + 20 p)],]
      }
    ]

    It only found the solution that we already knew.

  13. 13. Chris Said:

    Looking at it in mod 26 we get 33m – 7n = 26 =>
    7m = 7n (mod 26). φ(26) = 26(1 – 1/2)(1 – 1/13) = 12, whwre φ() is Euler’s totient function. So 7φ(26) = 712 = 1 (mod 26). And it turns out that 12 is the smallest power that does that. So n (in particular) is of the form 12q. As LCM(12,20) = 60 the 20 I used in the above program can be replaced by 60. I have done that and I’m currently running the program, starting from where the previous one had got to. At this moment I have got to n = 2 760 000 without finding another solution.

    I don’t think I can come up with such a rapid test using rules for m. Worse still, I haven’t found a mathematical proof that no other powers will do it.

  14. 14. Chris Said:

    Ooops, I think I’ve goofed that last bit, not sure that multiples of 60 is right anymore. I’m done, unless I have a brainwave. But if 60 is OK then I’ve just got to n = 3 000 000.

  15. 15. BeccaBeth Said:

    M would be 1 if you are trying to make D have the least positive value and since an integer goes from every negative number, and negative fractions, which also include decimals, and 7^1.796 is just under 33. and so 33-the product of 7^1.796 equals 0.055 which is positive still, and one of the lowest answers for D, however, by making the decimal that powers 7 smaller and more elaborate, you get a smaller answer for d. As for a negative answer for d, you could just make N 1.797 or even more elaborate and get a smaller negative number for D.

  16. 16. Chris Said:

    Hi BeccaBeth. The question said m and n are positive integers. Fractions and decimal numbers are not integers. Also negative numbers are not positive numbers. The positive integers are 1,2,3,4,5,… and m and n have to be one of those.

    If we allowed m and n to be any old number, then there are infinitely many choices for m and n such that 33m – 7n = 0. i.e. m/n = log33/log7 = 1.79684943992092337566530703483053783529606780447361015067173…
    I’m pretty sure that’s an irrational number.

Post a reply




PHP Warning: PHP Startup: Unable to load dynamic library 'C:\Program Files (x86)\Parallels\Plesk\Additional\PleskPHP5\ext\php_mssql.dll' - The specified module could not be found. in Unknown on line 0 PHP Warning: PHP Startup: Unable to load dynamic library 'C:\Program Files (x86)\Parallels\Plesk\Additional\PleskPHP5\ext\php_pdo_mssql.dll' - The specified module could not be found. in Unknown on line 0