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.

A008837 a(n) = p*(p-1)/2 for p = prime(n).

Original entry on oeis.org

1, 3, 10, 21, 55, 78, 136, 171, 253, 406, 465, 666, 820, 903, 1081, 1378, 1711, 1830, 2211, 2485, 2628, 3081, 3403, 3916, 4656, 5050, 5253, 5671, 5886, 6328, 8001, 8515, 9316, 9591, 11026, 11325, 12246, 13203, 13861, 14878, 15931, 16290, 18145, 18528, 19306
Offset: 1

Views

Author

Keywords

Comments

Whereas A034953 is the sequence of triangular numbers with prime indices, this is the sequence of triangular numbers with numbers one less than primes for indices. - Alonso del Arte, Aug 17 2014
From Jianing Song, Apr 13 2019: (Start)
a(n) is both the number of quadratic residues and the number of nonresidues modulo prime(n)^2 that are coprime to prime(n).
For k coprime to prime(n), k^a(n) == +-1 (mod prime(n)^2). (End)

Crossrefs

Half the terms of A036689.
Cf. A000217 (triangular numbers), A112456 (least triangular number divisible by n-th prime). - Klaus Brockhaus, Nov 18 2008
Column 1 of A257253. (Row 1 of A257254).

Programs

Formula

a(n) = binomial(prime(n), 2) = A000217(A000040(n)-1). - Enrique Pérez Herrero, Dec 10 2011
a(n) = (1/2)*A072230(A000040(n)). - L. Edson Jeffery, Apr 07 2012
a(n) = (phi(prime(n))^2 + phi(prime(n)))/2, where phi(n) is Euler's totient function, A000010. - Alonso del Arte, Aug 22 2014
a(n) = A036689(n)/2. - Antti Karttunen, May 01 2015
Product_{n>=2} (1 - 1/a(n)) = A271780. - Amiram Eldar, Nov 22 2022

Extensions

Offset changed from 2 to 1 by Harry J. Smith, Jul 25 2009

A269844 Primes equal to the sum of a pair of consecutive integers which are both squarefree.

Original entry on oeis.org

5, 11, 13, 29, 43, 59, 61, 67, 83, 131, 139, 157, 173, 211, 227, 229, 277, 283, 317, 331, 347, 373, 389, 419, 421, 443, 461, 509, 547, 563, 571, 619, 643, 653, 659, 661, 691, 709, 733, 787, 797, 821, 853, 859, 877, 907, 941, 947, 997, 1019, 1021, 1069, 1091, 1093, 1109, 1123, 1163, 1181, 1213
Offset: 1

Views

Author

Bill McEachen, Mar 06 2016

Keywords

Comments

The associated prime factors will always include 2 and 3.
Will every prime number be encountered as a prime factor from the sequence entries?
The sequence appears to share many of it terms with A001122.
What is the asymptotic behavior?
Conjecture: sequence has density A271780/2 = A005597*4/Pi^2 = 0.2675535... in the primes. - Charles R Greathouse IV, Jan 24 2018
The prime terms of A179017 (except 3). - Bill McEachen, Oct 21 2021

Examples

			277 = 138 + 139 = 2*3*23 + 139 is in the sequence since both terms are squarefree.
281 = 140 + 141 = 2^2*5*7 + 3*47 is not in the sequence since the former term is divisible by 2^2.
		

Crossrefs

Cf. A001122 (primes with primitive root 2), A179017.

Programs

  • Mathematica
    Select[Prime@ Range[3, 200], PrimeOmega@ # == PrimeNu@ # &[# (# + 1)] &@ Floor[#/2] &] (* Michael De Vlieger, Mar 07 2016 *)
  • PARI
    genit(maxx)={for(i5=3,maxx,n=prime(i5);a=factor(floor(n/2.));b=factor(ceil(n/2.));clear=1;for(j5=1,omega(floor(n/2.)),if(a[j5,2]<>1,clear=0));
    for(j7=1,omega(ceil(n/2.)),if(b[j7,2]<>1,clear=0));if(clear>0,print1(n,",")));}
    
  • PARI
    is(n)=isprime(n) && issquarefree(n\2) && issquarefree(n\2+1) \\ Charles R Greathouse IV, Jan 24 2018
    
  • PARI
    list(lim)=my(v=List(),t=1); forfactored(k=3,(lim+1)\2, if(vecmax(k[2][,2])>1, t=0, ; if(t && isprime(t=2*k[1]-1), listput(v,t)); t=1)); Vec(v) \\ Charles R Greathouse IV, Jan 24 2018

A271869 Decimal expansion of Matthews' constant C_3, an analog of Artin's constant for primitive roots.

Original entry on oeis.org

0, 6, 0, 8, 2, 1, 6, 5, 5, 1, 2, 0, 3, 0, 5, 0, 8, 6, 0, 0, 5, 6, 3, 2, 2, 7, 5, 4, 6, 1, 9, 2, 0, 8, 5, 5, 4, 3, 1, 3, 3, 7, 3, 7, 3, 4, 7, 5, 7, 6, 7, 9, 4, 1, 9, 8, 2, 6, 4, 3, 4, 0, 3, 1, 5, 0, 4, 0, 8, 0, 4, 3, 5, 0, 7, 2, 1, 2, 5, 6, 1, 6, 9, 5, 8, 6, 1, 8, 8, 8, 7, 3, 4, 8, 5, 8, 6, 6, 2, 4, 6, 8, 7, 3, 4, 0
Offset: 0

Views

Author

Jean-François Alcover, Apr 16 2016

Keywords

Examples

			0.0608216551203050860056322754619208554313373734757679419826434...
		

References

  • Steven R. Finch, Mathematical Constants, Cambridge University Press, 2003, Section 2.4 Artin's constant, p. 105.

Crossrefs

Programs

  • Mathematica
    digits = 70; $MaxExtraPrecision = 1000; m0 = 2000; dm = 200; Clear[s]; LR =
    LinearRecurrence[{2, 2, -6, 4, -1}, {0, 6, 0, 22, 5}, 2 m0]; r[n_Integer] := LR[[n]]; s[m_] := s[m] = NSum[-r[n] PrimeZetaP[n]/n, {n, 2, m}, NSumTerms -> 2 m0, WorkingPrecision -> digits+10] // Exp; s[m0]; s[m = m0+dm]; While[RealDigits[s[m], 10, digits][[1]] != RealDigits[ s[m-dm], 10, digits][[1]], Print[m]; m = m + dm]; Join[{0}, RealDigits[ s[m], 10, digits][[1]]]
  • PARI
    prodeulerrat(1 - (p^3 - (p - 1)^3)/(p^3*(p - 1))) \\ Amiram Eldar, Mar 16 2021

Formula

C_3 = Product_{p prime} 1 - (p^3 - (p - 1)^3)/(p^3*(p - 1)).

Extensions

More digits from Vaclav Kotesovec, Jun 19 2020

A271877 Decimal expansion of Matthews' constant C_4, an analog of Artin's constant for primitive roots.

Original entry on oeis.org

0, 2, 6, 1, 0, 7, 4, 4, 6, 3, 1, 4, 9, 1, 7, 7, 0, 8, 0, 8, 3, 2, 4, 9, 3, 9, 4, 3, 1, 3, 8, 2, 1, 4, 6, 7, 2, 5, 5, 6, 2, 6, 6, 7, 3, 6, 4, 0, 5, 5, 3, 8, 0, 4, 5, 2, 7, 6, 1, 1, 7, 3, 3, 7, 1, 0, 2, 4, 9, 8, 2, 0, 0, 5, 6, 5, 8, 7, 0, 1, 4, 0, 9, 9, 6, 8, 4, 7, 0, 4, 8, 1, 5, 1, 1, 5, 2, 2, 6, 0, 3, 8, 6, 9, 4, 0
Offset: 0

Views

Author

Jean-François Alcover, Apr 16 2016

Keywords

Examples

			0.026107446314917708083...
		

References

  • Steven R. Finch, Mathematical Constants, Cambridge University Press, 2003, Section 2.4 Artin's constant, p. 105.

Crossrefs

Programs

  • Mathematica
    $MaxExtraPrecision = 2000; LR = LinearRecurrence[{2, 3, -10, 10, -5, 1}, {0, -8, 6, -40, 35, -194}, 10^4]; r[n_Integer] := LR[[n]]; NSum[r[n] PrimeZetaP[n]/n, {n, 2, Infinity}, NSumTerms -> 2000, WorkingPrecision -> 300, Method -> "AlternatingSigns"] // Exp // RealDigits[#, 10, 20]& // First // Prepend[#, 0]&
    $MaxExtraPrecision = 1000; Clear[f]; f[p_] := 1 - (p^4 - (p - 1)^4)/(p^4*(p - 1)); Do[c = Rest[CoefficientList[Series[Log[f[1/x]], {x, 0, m}], x]]; Print[f[2] * Exp[N[Sum[Indexed[c, n]*(PrimeZetaP[n] - 1/2^n), {n, 2, m}], 105]]], {m, 100, 1000, 100}] (* Vaclav Kotesovec, Jun 19 2020 *)
  • PARI
    prodeulerrat(1 - (p^4 - (p - 1)^4)/(p^4*(p - 1))) \\ Amiram Eldar, Mar 16 2021

Formula

C_4 = Product_{p prime} 1 - (p^4 - (p - 1)^4)/(p^4*(p - 1)).

Extensions

More digits from Vaclav Kotesovec, Jun 19 2020
Showing 1-4 of 4 results.