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

A177931 Locations of records in A177930.

Original entry on oeis.org

1, 2, 4, 8, 10, 16, 20, 24, 29, 33, 36, 46, 76, 99, 108, 132, 179, 213, 217, 251, 286, 397, 431, 439, 445, 471, 535, 658, 677, 702, 780, 889, 1227, 1296, 1388, 1395, 1430, 1438, 1624, 1817, 2082, 2396, 2423, 2978, 3133, 3138, 3432, 3511, 3699, 3838, 4024, 4104, 4589, 4930
Offset: 1

Views

Author

Vladimir Shevelev, May 15 2010

Keywords

Comments

Or: positions m for which A177929(m)-1 and A177929(m)+1 are twin primes.

Crossrefs

Programs

  • Maple
    A020639 := proc(n) numtheory[factorset](n) ; min(op(%)) ; end proc:
    A177929 := proc(n) option remember; if n = 1 then 4; else d1 := A020639(procname(n-1)-1) ; d2 := A020639(procname(n-1)+1) ; procname(n-1)+min(d1,d2) -1; end if; end proc:
    A177930 := proc(n) d1 := A020639(A177929(n)-1) ; d2 := A020639(A177929(n)+1) ; min(d1,d2) ; end proc:
    read("transforms") ; L := [seq(A177930(n),n=1..1300)] ; RECORDS(L)[2] ; # R. J. Mathar, May 31 2010
  • Mathematica
    lpf[n_] := FactorInteger[n][[1, 1]];
    b[n_] := b[n] = If[n == 1, 4, b[n-1] + lpf[b[n-1]^2-1]-1];
    Position[Table[b[n], {n, 1, 1000}], k_ /; PrimeQ[k-1] && PrimeQ[k+1]] // Flatten (* Jean-François Alcover, Feb 24 2024 *)

Extensions

Extended by R. J. Mathar, May 31 2010
More terms from Jean-François Alcover, Feb 24 2024

A177932 Records in A177930.

Original entry on oeis.org

3, 5, 11, 29, 59, 137, 281, 569, 1151, 2309, 4649, 9341, 19139, 38711, 77489, 155381, 311681, 624047, 1248101, 2497421, 4998941, 10002437, 20005289, 40010609, 80021309, 160043909, 320090921, 640196267, 1280392739, 2560793201, 5121618767
Offset: 1

Views

Author

Vladimir Shevelev, May 15 2010

Keywords

Comments

By the construction of A177929, this is a subsequence of A001359.

Crossrefs

Formula

a(n) = A177930(A177931(n)) .

Extensions

Extended by R. J. Mathar, May 31 2010

A177961 a(1)=2. Otherwise the average of the smallest prime divisors of 2n-1 and 2n+1.

Original entry on oeis.org

2, 4, 6, 5, 7, 12, 8, 10, 18, 11, 13, 14, 4, 16, 30, 17, 4, 21, 20, 22, 42, 23, 25, 27, 5, 28, 29, 4, 31, 60, 32, 4, 36, 35, 37, 72, 38, 5, 43, 41, 43, 44, 4, 46, 48, 5, 4, 51, 50, 52, 102, 53, 55, 108, 56, 58, 59, 4, 5, 9, 7, 4, 66, 65, 67, 69, 5, 70, 138, 71, 7, 8, 4, 76, 150, 77, 4, 81
Offset: 1

Views

Author

Vladimir Shevelev, May 16 2010, May 22 2010

Keywords

Comments

As n tends to infinity, we have 1) lim inf (a(n)/n)=0; 2) if there exist infinitely many twin primes, then lim sup (a(n)/n)=2, otherwise, lim sup (a(n)/n)=1.

Crossrefs

Programs

  • Magma
    [2] cat [1/2*(Min(PrimeFactors(2*n-1))+ Min(PrimeFactors(2*n+1))):n in [2..80]]; // Vincenzo Librandi, Feb 07 2016
  • Maple
    N:= 100: # to get a(1) to a(N)
    S:= [1,seq(min(numtheory:-factorset(2*i-1)),i=2..N+1)]:
    (S[2..-1]+S[1..-2])/2; # Robert Israel, Jul 31 2015
  • Mathematica
    Table[If[n == 1, 2, Mean[{FactorInteger[2 n - 1][[1, 1]], FactorInteger[2 n + 1][[1, 1]]}]], {n, 78}] (* Michael De Vlieger, Aug 02 2015 *)
  • PARI
    a(n) = if (n==1, 2, (vecmin(factor(2*n-1)[,1]) + vecmin(factor(2*n+1)[,1]))/2); \\ Michel Marcus, Feb 07 2016
    

Formula

a(n) = (A090368(n)+A090368(n+1))/2. [R. J. Mathar, May 31 2010]

Extensions

More terms from R. J. Mathar, May 31 2010

A177942 Smallest prime divisor of (A177941(n))^2-4.

Original entry on oeis.org

3, 3, 7, 13, 5, 3, 5, 3, 37, 7, 79, 7, 163, 5, 3, 5, 3, 11, 3, 349, 17, 3, 5, 3, 5, 3, 17, 3, 5, 3, 5, 3, 757, 17, 3, 5, 3, 23, 3, 5, 3, 1567, 13, 5, 3, 5, 3, 7, 3163, 5, 3, 5, 3, 17, 3, 5, 3, 5, 3, 23, 3, 5, 3, 37, 7, 17, 3, 7, 23, 3, 13, 7, 5, 3, 5, 3, 7, 11, 3, 5, 3, 5, 3, 6547, 7, 13099, 7, 73
Offset: 1

Views

Author

Vladimir Shevelev, May 15 2010

Keywords

Comments

Records are in A177945, indices of records in A177943.

Crossrefs

Programs

  • Mathematica
    Differences[NestList[# + FactorInteger[#^2 - 4][[1, 1]] - 1 &, 5, 100]] + 1 (* Amiram Eldar, Dec 14 2018 after Michael De Vlieger at A177941 *)
  • PARI
    listap(nn) = {my(va = vector(nn), p); va[1] = 5; for (n=2, nn, p = factor(va[n-1]^2-4)[1,1]; print1(p, ", "); va[n] = va[n-1] + p - 1;);} \\ Michel Marcus, Dec 14 2018

Formula

a(n) = A020639((A177941(n))^2-4) .

Extensions

Entries checked by R. J. Mathar, Jun 30 2010

A177943 Locations of records in A177942.

Original entry on oeis.org

1, 3, 4, 9, 11, 13, 20, 33, 42, 49, 84, 86, 107, 109, 123, 128, 191, 295, 296, 318, 330, 337, 396, 453, 481, 616, 663, 771, 882, 1105, 1180, 1257, 1431, 1659, 1856, 1936, 2130, 2370, 2584, 2651, 2790, 2959, 3009, 3080, 3121, 3189, 3503, 3639, 3879, 3902, 3961
Offset: 1

Views

Author

Vladimir Shevelev, May 15 2010

Keywords

Comments

Also: indices m for which A177941(m)-2 and A177941(m)+2 are cousin primes (A023200).

Crossrefs

Programs

  • PARI
    listai(nn) = {my(va = vector(nn), rec = 0, ind = 1); va[1] = 5; for (n=2, nn, p = factor(va[n-1]^2-4)[1,1]; if (p > rec, print1(n-1, ", "); rec = p); va[n] = va[n-1] + p - 1;);} \\ Michel Marcus, Dec 14 2018

Extensions

1 inserted, a(10) corrected and sequence extended by R. J. Mathar, Jun 30 2010
More terms from Michel Marcus, Dec 14 2018

A177945 Record values in A177942.

Original entry on oeis.org

3, 7, 13, 37, 79, 163, 349, 757, 1567, 3163, 6547, 13099, 26497, 52999, 106273, 212557, 426889, 855427, 1710853, 3421903, 6845869, 13691767, 27385087, 54771007, 109542907, 219096259, 438203677, 876417229, 1752875893, 3505814527, 7011656629, 14023322167, 28046754727, 56093637367
Offset: 1

Views

Author

Vladimir Shevelev, May 15 2010

Keywords

Comments

From the construction of A177941, this is a subsequence of A023200.

Crossrefs

Programs

  • PARI
    listar(nn) = {my(va = vector(nn), rec = 0); va[1] = 5; for (n=2, nn, p = factor(va[n-1]^2-4)[1,1]; if (p > rec, print1(p, ", "); rec = p); va[n] = va[n-1] + p - 1;);} \\ Michel Marcus, Dec 14 2018

Extensions

Sequence extended by R. J. Mathar, Jun 30 2010
More terms from Michel Marcus, Dec 14 2018
Showing 1-6 of 6 results.