OFFSET
3,1
COMMENTS
Related to 46th IMO 2005 Problem 4, which asks to find all positive integers k such that gcd(2^n + 3^n + 6^n - 1, k) = 1 for all n. The answer is k = 1. The main part of the solution is to show that for all primes p >= 5 satisfies p divides 2^(p-2) + 3^(p-2) + 6^(p-2) - 1. By Fermat's little theorem, 2^(p-1) == 3^(p-1) == 6^(p-1) == 1 (mod p), so 2^(p-2) + 3^(p-2) + 6^(p-2) - 1 == 2^(-1) + 3^(-1) + 6^(-1) - 1 == 0 (mod p). Here a^(-1) is the multiplicative inverse of a modulo p.
All terms are multiples of 10 but not divisible by 4. If prime(n) !== 3 (mod 8) then a(n) is divisible by 50; if n > 3 and prime(n) == 1 (mod 4) then a(n) is divisible by 250; if prime(n) == 1, 13, 17 (mod 20) then a(n) is divisible by 1250.
Note that a(1) = 1 is also an integer, while a(2) = 10/3 is not.
LINKS
International Mathematical Olympiad, 46th IMO 2005
EXAMPLE
a(3) = (2^3 + 3^3 + 6^3 - 1)/5 = 50, a(4) = (2^5 + 3^5 + 6^5 - 1)/7 = 1150, a(5) = (2^9 + 3^9 + 6^9 - 1)/11 = 917990 ...
MATHEMATICA
Table[(2^(Prime[n] - 2) + 3^(Prime[n] - 2) + 6^(Prime[n] - 2) - 1) / Prime[n], {n, 3, 20}] (* Vincenzo Librandi, Sep 03 2018 *)
PROG
(PARI) a(n) = (2^(prime(n)-2) + 3^(prime(n)-2) + 6^(prime(n)-2) - 1)/prime(n)
(Magma) [(2^(NthPrime(n)-2)+3^(NthPrime(n)-2)+6^(NthPrime(n)-2)- 1)/NthPrime(n): n in [3..20]]; // Vincenzo Librandi, Sep 03 2018
CROSSREFS
KEYWORD
nonn
AUTHOR
Jianing Song, Sep 02 2018
STATUS
approved