login
a(n) = gcd_{k=1..n} (prime(k+1)^n-1)/2.
7

%I #42 May 12 2024 16:01:31

%S 1,4,1,8,1,4,1,16,1,4,1,8,1,4,1,32,1,4,1,8,1,4,1,16,1,4,1,8,1,4,1,64,

%T 1,4,1,8,1,4,1,16,1,4,1,8,1,4,1,32,1,4,1,8,1,4,1,16,1,4,1,8,1,4,1,128,

%U 1,4,1,8,1,4,1,16,1,4,1,8,1,4,1,32,1,4,1,8,1,4,1,16,1,4,1,8,1,4,1,64,1,4,1,8

%N a(n) = gcd_{k=1..n} (prime(k+1)^n-1)/2.

%C If p is an odd prime and p^n is the length of the odd leg of a primitive Pythagorean triangle it constrains the other leg and hypotenuse to be (p^(2n)-1)/2 and (p^(2n)+1)/2. The resulting triangle has a semiperimeter of p^n(p^n+1)/2, an area of (p^n-1)p^n(p^n+1)/4 and an inradius of (p^n-1)/2. a(n) equals the GCD of the inradius terms (p^n-1)/2 for at least the first n odd primes.

%C Conjecture: a(n) equals the GCD of the inradius terms (p^n-1)/2 for all odd primes, i.e. a(n) = GCD_{k=1..oo} (prime(k+1)^n-1)/2.

%C From _David A. Corneth_, Dec 29 2017: (Start)

%C All terms are powers of 2. Proof: suppose p | a(n) for some odd prime p. Then p | (p^n - 1) / 2 and so p | (p^n - 1) which isn't the case.

%C If n is odd then a(n) = 1. Proof: 2 | (p^k - 1) for all k and odd primes p. 3^n - 1 = 3 * 9^k - 1 = 3 - 1 = 2 (mod 4), so 3^n - 1 is of the form 2*m for some odd m, hence the GCD of all (p^n - 1) / 2 is 1 for odd n. (End)

%C This is the even bisection of A059159. - _Rémy Sigrist_, Dec 30 2017

%C a(n) is the size of the group Z_2*/(Z_2*)^n, where Z_2 is the ring of 2-adic integers. We have that Z_2*/(Z_2*)^n is the inverse limit of (Z/2^iZ)*/((Z/2^iZ)*)^n as i tends to infinity. If n is odd, then the group is trivial. If n = 2^e * n' is even, where n' is odd, then the group is the product of a cyclic group of order 2^e and a cyclic group of order 2. See A370050. - _Jianing Song_, May 12 2024

%H Frank M Jackson, <a href="/A297402/b297402.txt">Table of n, a(n) for n = 1..10000</a>

%F It appears that for k > 0, a(2^k) = 2^(k+1).

%F a(n) = A006519(2n) for even n and a(n) = 1 for odd n. - _David A. Corneth_, Dec 29 2017

%F a(n) = A074723(n)/2. - _Iain Fox_, Dec 30 2017

%F Multiplicative with a(2^e) = 2^(e+1), a(p^e) = 1 for odd prime p. - _Andrew Howroyd_, Jul 25 2018

%F It appears that for m > 0, a(2m-1) = 1 (proved in comments) and a(2m) = 2^(k+1) where k is the exponent of the even prime in the prime factorization of 2m. - _Frank M Jackson_, Jul 28 2018

%F From _Amiram Eldar_, Nov 24 2023: (Start)

%F Dirichlet g.f.: zeta(s) * (1 + 1/2^s + 1/(2^(s-1) - 1)).

%F Sum_{k=1..n} a(k) ~ (n/log(2)) * (log(n) + gamma + log(2) - 1), where gamma is Euler's constant (A001620). (End)

%e a(4)=8 because for n=4 and for the first 4 odd primes {3, 5, 7, 11}, the term (p^n-1)/2 gives {40, 312, 1200, 7320} with a GCD of 8.

%t a[n_] := GCD @@ Array[(Prime[# +1]^n -1)/2 &, n]; Array[a, 90] (* slightly modified by _Robert G. Wilson v_, Jan 01 2018 *)

%t a[n_] := If[EvenQ[n], 2^(FactorInteger[n][[1]][[2]] + 1), 1]; Array[a, 90] (* _Frank M Jackson_, Jul 28 2018 *)

%o (PARI) a(n) = gcd(vector(n, i, (prime(i+1)^n-1)/2)) \\ _Iain Fox_, Dec 29 2017

%o (PARI) a(n)=if(n%2,1,2)<<valuation(n,2) \\ _Charles R Greathouse IV_, Jan 06 2018

%Y Cf. A001620, A006519, A059159, A074723, A127922, A171977, A202318.

%K nonn,easy,mult

%O 1,2

%A _Frank M Jackson_, Dec 29 2017