cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-2 of 2 results.

A318760 a(n) = (2^(p-2) + 3^(p-2) + 6^(p-2) - 1)/p where p = prime(n).

Original entry on oeis.org

50, 1150, 917990, 27921250, 27658786250, 890883616630, 953780917514270, 35292771610455205250, 1188569463078058297390, 46461372967525788391551250, 54339408694585566675022336250, 1865231796118578544316494648870, 2211609309235145328175672372758350, 91503540845067670142505715662203731250
Offset: 3

Views

Author

Jianing Song, Sep 02 2018

Keywords

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.

Examples

			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 ...
		

Crossrefs

For composite k such that (2^(k-2) + 3^(k-2) + 6^(k-2) - 1)/k is an integer, see A318761.

Programs

  • 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
  • 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 *)
  • PARI
    a(n) = (2^(prime(n)-2) + 3^(prime(n)-2) + 6^(prime(n)-2) - 1)/prime(n)
    

A238201 Primes p such that numerator(H(floor(p/6))) == 0 (mod p), where H(k) is the k-th harmonic number.

Original entry on oeis.org

2, 3, 5, 61, 1680023, 7308036881
Offset: 1

Views

Author

T. D. Noe, Feb 24 2014

Keywords

Comments

The H function is 0 for the first three primes. The term 61 comes from Schwindt's paper. The terms 1680023 and 7308036881 come from Dobson's paper.
Let q_2 = (2^(p-1) - 1)/p and q_3 = (3^(p-1) - 1)/p. Then, as proved by Emma Lehmer, H(floor(p/6)) == -2*q_2 - (3/2)*q_3 (mod p) when p > 3. This congruence provides an efficient means of detecting when H(floor(p/6)) vanishes mod p. - John Blythe Dobson, Mar 01 2014
Also {2, 3} union {primes p : p^2 divides 2^(p-2) + 3^(p-2) + 6^(p-2) - 1}. Except for the term 3, p is a term of this sequence if and only if p^2 is in A318761. There are no more terms up to 7*10^10. - Jianing Song, Dec 26 2018
More generally (see Lehmer's paper, p. 352, eq. 13), if p^2 divides 2^(p-2) + 3^(p-2) + 6^(p-2) - 1, then it also divides 2^(k(p-1)-1) + 3^(k(p-1)-1) + 6^(k(p-1)-1) - 1 for any natural number k. Also, since H(floor(p/6)) == -2*q_2 - (3/2)*q_3 == -q_4 - (1/2)q_27 == -(1/2)(q_16 + q_27) == -(1/2)q_432 (mod p), the terms of this sequence greater than 3 coincide with the values of p that divide q_432, and can be found in Richard Fischer's list of vanishing Fermat quotients, which extended to 1.31*10^14 at the last revision of 19 December 2020. - John Blythe Dobson, Jan 02 2021

Crossrefs

Programs

  • Mathematica
    Select[Prime[Range[1000]], Mod[Numerator[HarmonicNumber[Floor[#/6]]], #] == 0 &]
    Select[Prime[Range[1000]], Divisible[Numerator[HarmonicNumber[Quotient[#, 6]]], #] &] (* Jan Mangaldan, May 07 2014 *)
  • PARI
    is(n)=my(H=sum(i=1,n\6,1/i)); numerator(H)%n==0 && isprime(n) \\ Charles R Greathouse IV, Mar 02 2014
Showing 1-2 of 2 results.