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-4 of 4 results.

A024702 a(n) = (prime(n)^2 - 1)/24.

Original entry on oeis.org

1, 2, 5, 7, 12, 15, 22, 35, 40, 57, 70, 77, 92, 117, 145, 155, 187, 210, 222, 260, 287, 330, 392, 425, 442, 477, 495, 532, 672, 715, 782, 805, 925, 950, 1027, 1107, 1162, 1247, 1335, 1365, 1520, 1552, 1617, 1650, 1855, 2072, 2147, 2185, 2262, 2380, 2420, 2625, 2752, 2882, 3015
Offset: 3

Views

Author

Clark Kimberling, Dec 11 1999

Keywords

Comments

Note that p^2 - 1 is always divisible by 24 since p == 1 or 2 (mod 3), so p^2 == 1 (mod 3) and p == 1, 3, 5, or 7 (mod 8) so p^2 == 1 (mod 8). - Michael B. Porter, Sep 02 2016
For n > 3 and m > 1, a(n) = A000330(m)/(2*m + 1), where 2*m + 1 = prime(n). For example, for m = 8, 2*m + 1 = 17 = prime(7), A000330(8) = 204, 204/17 = 12 = a(7). - Richard R. Forberg, Aug 20 2013
For primes => 5, a(n) == 0 or 2 (mod 5). - Richard R. Forberg, Aug 28 2013
The only primes in this sequence are 2, 5 and 7 (checked up to n = 10^7). The set of prime factors, however, appears to include all primes. - Richard R. Forberg, Feb 28 2015
Subsequence of generalized pentagonal numbers (cf. A001318): a(n) = k_n*(3*k_n - 1)/2, for k_n in {1, -1, 2, -2, 3, -3, 4, 5, -5, -6, 7, -7, 8, 9, 10, -10, ...} = A024699(n-2)*((A000040(n) mod 6) - 3)/2, n >= 3. - Daniel Forgues, Aug 02 2016
The only primes in this sequence are indeed 2, 5 and 7. For a prime p >= 5, if both p + 1 and p - 1 contains a prime factor > 3, then (p^2 - 1)/24 = (p + 1)*(p - 1)/24 contains at least 2 prime factors, so at least one of p + 1 and p - 1 is 3-smooth. Let's call it s. Also, If (p^2 - 1)/24 is a prime, then A001222(p^2-1) = 5. Since A001222(p+1) and A001222(p-1) are both at least 2, A001222(s) <= 5 - 2 = 3. From these we can see the only possible cases are p = 7, 11 and 13. - Jianing Song, Dec 28 2018

Examples

			For n = 6, the 6th prime is 13, so a(6) = (13^2 - 1)/24 = 168/24 = 7.
		

Crossrefs

Subsequence of generalized pentagonal numbers A001318.
Cf. A075888.

Programs

Formula

a(n) = (A000040(n)^2 - 1)/24 = (A001248(n) - 1)/24. - Omar E. Pol, Dec 07 2011
a(n) = A005097(n-1)*A006254(n-1)/6. - Bruno Berselli, Dec 08 2011
a(n) = A084920(n)/24. - R. J. Mathar, Aug 23 2013
a(n) = A127922(n)/A000040(n) for n >= 3. - César Aguilera, Nov 01 2019

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

Original entry on oeis.org

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, 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, 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
Offset: 1

Views

Author

Frank M Jackson, Dec 29 2017

Keywords

Comments

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.
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.
From David A. Corneth, Dec 29 2017: (Start)
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.
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)
This is the even bisection of A059159. - Rémy Sigrist, Dec 30 2017
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

Examples

			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.
		

Crossrefs

Programs

  • Mathematica
    a[n_] := GCD @@ Array[(Prime[# +1]^n -1)/2 &, n]; Array[a, 90] (* slightly modified by Robert G. Wilson v, Jan 01 2018 *)
    a[n_] := If[EvenQ[n], 2^(FactorInteger[n][[1]][[2]] + 1), 1]; Array[a, 90] (* Frank M Jackson, Jul 28 2018 *)
  • PARI
    a(n) = gcd(vector(n, i, (prime(i+1)^n-1)/2)) \\ Iain Fox, Dec 29 2017
    
  • PARI
    a(n)=if(n%2,1,2)<Charles R Greathouse IV, Jan 06 2018

Formula

It appears that for k > 0, a(2^k) = 2^(k+1).
a(n) = A006519(2n) for even n and a(n) = 1 for odd n. - David A. Corneth, Dec 29 2017
a(n) = A074723(n)/2. - Iain Fox, Dec 30 2017
Multiplicative with a(2^e) = 2^(e+1), a(p^e) = 1 for odd prime p. - Andrew Howroyd, Jul 25 2018
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
From Amiram Eldar, Nov 24 2023: (Start)
Dirichlet g.f.: zeta(s) * (1 + 1/2^s + 1/(2^(s-1) - 1)).
Sum_{k=1..n} a(k) ~ (n/log(2)) * (log(n) + gamma + log(2) - 1), where gamma is Euler's constant (A001620). (End)

A202318 Let (n)_p denote the exponent of prime p in the prime power factorization of n. Then a(n) is defined by the formulas a(1)=1; for n >= 2, (a(n))_2 = (n)_2, (a(n))_3 = (n)_3 and, for p >= 5, (a(n))_p = 1 + ((2n)/(p-1))_p if p-1|2*n, and (a(n))_p = 0 otherwise.

Original entry on oeis.org

1, 10, 21, 20, 11, 2730, 1, 680, 1197, 550, 23, 5460, 1, 290, 7161, 1360, 1, 5757570, 1, 45100, 6321, 230, 47, 185640, 11, 530, 3591, 580, 59, 283933650, 1, 2720, 32361, 10, 781, 840605220, 1, 10, 1659, 1533400, 83, 23830170, 1, 40940, 408177, 470, 1, 36014160, 1, 277750, 2163, 1060, 107, 1882725390
Offset: 1

Views

Author

Keywords

Comments

a(n)=1 iff n has form 6n+-1 and, if d >= 5 is a divisor of n, then 2*d+1 is not prime. The places of 1's form sequence A045979.
If p is an odd prime and p^n is the side length of the odd leg of a primitive Pythagorean triangle (PPT) it constrains the other leg and hypotenuse to be (p^(2n)-1)/2 and (p^(2n)+1)/2 and the area to be (p^n-1)p^n(p^n+1)/4. Now consider the term (p^n-1)p^n(p^n+1): it must at least be divisible by 24 for all odd primes p because the area of a PPT is divisible by 6 (see A127922 for n=1). a(n) equals the common divisor of the term (p^n-1)p^n(p^n+1)/24 for all odd primes p. - Frank M Jackson, Dec 09 2017

Examples

			Let n=6. Since 2*6+1=13 is prime, the max p that should be considered is 13. We have
  (a(6))_2  = (a(6))_3 = 1,
  (a(6))_5  = (12/4)_5 + 1 = 1,
  (a(6))_7  = (12/6)_7 + 1 = 1,
  (a(6))_13 = (12/12)_13 + 1 = 1.
Thus a(6) = 2*3*5*7*13 = 2730.
		

Crossrefs

Programs

  • Mathematica
    Table[Numerator[Exp[Re[Limit[Zeta[s] (Zeta[-1]^(s - 1) - Zeta[-(2*n - 1)]^(s - 1)), s -> 1]]]], {n, 1, 54}] (* Mats Granvik, Feb 05 2016 *)
    Table[(lst=Table[p=Prime[m+1]; (p^n-1)p^n(p^n+1), {m, 1, 10}]; GCD@@lst/24), {n, 1, 100}] (* Frank M Jackson, Dec 09 2017 *)
    a[n_] := Product[p^Sum[Floor[(n-1)/((p-1) p^k)], {k, 0, n}], {p, Prime[Range[n]]}]; Array[a[2#+1]/(24 a[2#-1]) &, 100] (* using Jean-François Alcover's program A053657 *)(* Frank M Jackson, Dec 16 2017 *)
  • PARI
    a(n) = {my(r = 1); forprime(p=2, 2*n+1, if (p<=3, r *= p^valuation(n, p), if (! (2*n % (p-1)), r *= p^(1+valuation((2*n)/(p-1), p))););); r;} \\ Michel Marcus, Feb 06 2016

Formula

a(n) = (1/24)*b(2n+1)/b(2n-1), where b(n) = A053657(n).
a(p) = A002445(p)/6, for prime p >= 5.
a(n) = numerator of e^(real(lim_{s -> 1} (zeta(s)*(zeta(-1)^(s-1) - zeta(-(2*n-1))^(s-1))))). - Mats Granvik, Feb 05 2016
a(n) = A036283(n)/6. - Hugo Pfoertner, Dec 18 2022

A177049 Numerator of (3n+1)*(3n+2)/4.

Original entry on oeis.org

1, 5, 14, 55, 91, 68, 95, 253, 325, 203, 248, 595, 703, 410, 473, 1081, 1225, 689, 770, 1711, 1891, 1040, 1139, 2485, 2701, 1463, 1580, 3403, 3655, 1958, 2093, 4465, 4753, 2525, 2678, 5671, 5995, 3164, 3335, 7021, 7381, 3875, 4064, 8515, 8911
Offset: 0

Views

Author

Paul Curtz, Dec 09 2010

Keywords

Comments

A trisection of A064038.

Crossrefs

Programs

  • Mathematica
    Table[Numerator[(3 n + 1) (3 n + 2)/4], {n, 0, 50}] (* Wesley Ivan Hurt, Jun 14 2014 *)
    LinearRecurrence[{3,-6,10,-12,12,-10,6,-3,1},{1,5,14,55,91,68,95,253,325},50] (* Harvey P. Dale, Jan 18 2020 *)

Formula

Conjecture: a(n)= +3*a(n-1) -6*a(n-2) +10*a(n-3) -12*a(n-4) +12*a(n-5) -10*a(n-6) +6*a(n-7) -3*a(n-8) +a(n-9) with g.f. -(x^2+4*x+1)*(x^6-2*x^5+12*x^4-13*x^3+12*x^2-2*x+1) / ( (x-1)^3*(x^2+1)^3 ). - R. J. Mathar, Dec 12 2010
The conjecture is correct. - Charles R Greathouse IV, Feb 08 2012
a(n) ~ -27/8*n^2 - 27/8*n. - Ralf Stephan, Jun 16 2014
Sum_{n>=0} 1/a(n) = (4/(3*sqrt(3)) - 1/3)*Pi. - Amiram Eldar, Aug 13 2022
Showing 1-4 of 4 results.