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-10 of 12 results. Next

A076272 Largest prime factor of A076271(n): A006530(A076271(n)).

Original entry on oeis.org

1, 2, 2, 3, 3, 3, 5, 5, 5, 5, 7, 7, 7, 7, 7, 7, 11, 11, 11, 11, 11, 11, 13, 13, 13, 13, 13, 13, 17, 17, 17, 17, 17, 17, 19, 19, 19, 19, 19, 19, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 29, 29, 29, 29, 29, 29, 29, 29, 31, 31, 31, 31, 31, 31, 31, 31, 37, 37, 37, 37, 37, 37, 37, 37
Offset: 1

Views

Author

Reinhard Zumkeller, Oct 04 2002

Keywords

Crossrefs

See A180101 for a variant.

Programs

  • Mathematica
    Differences[NestList[#+FactorInteger[#][[-1,1]]&,1,100]] (* Paolo Xausa, Dec 09 2023 *)

Formula

a(n) = A076271(n+1) - A076271(n) for all n;
a(A076273(k)+j) = A008578(k) for k>0 and 0 <= j < A075527(k-1).

A331032 Number of iterations of n -> n + gpf(n) needed for the trajectory of n to join the trajectory of A076271, where gpf(n) is the greatest prime factor of n.

Original entry on oeis.org

0, 0, 1, 0, 2, 0, 4, 2, 0, 1, 6, 0, 10, 3, 0, 4, 12, 3, 16, 0, 2, 5, 18, 2, 0, 9, 1, 1, 22, 0, 28, 12, 4, 11, 0, 9, 30, 15, 8, 5, 36, 0, 40, 3, 4, 17, 42, 11, 0, 3, 10, 7, 46, 15, 2, 0, 14, 21, 52, 7, 58, 27, 0, 2, 6, 1, 60, 9, 16, 0, 66, 11, 70, 29, 10, 13
Offset: 1

Views

Author

Michael C. Case, Jan 08 2020

Keywords

Comments

Record values occur at prime values of n, and equal one less than the next lowest prime number (see Formula). Because of this, a(n) is always less than n, so for any positive integer starting value n, iterations of n -> n + gpf(n) will eventually join A076271.

Examples

			a(8)=2 because the trajectory for 1 (sequence A076271) starts 1->2->4->6->9->12->15->20... and the trajectory for 8 starts 8->10->15->20... so the sequence beginning with 8 joins A076271 after 2 steps.
		

Crossrefs

Programs

  • PARI
    gpf(n) = if (n==1, 1, my (f=factor(n)); f[#f~, 1])
    a(n) = { my (o=1); for (k=0, oo, while (oRémy Sigrist, Apr 05 2020

Formula

a(k*p) = prevprime(p) - k for all k <= prevprime(p).
a(p) = prevprime(p) - 1 for p > 2.

A076918 a(1) = 1, a(n+1) = A076271(n+1) divided by the highest common factor of A076271(n) and A076271(n+1).

Original entry on oeis.org

1, 2, 2, 3, 3, 4, 5, 4, 5, 6, 7, 6, 7, 8, 9, 10, 11, 8, 9, 10, 11, 12, 13, 12, 13, 14, 15, 16, 17, 14, 15, 16, 17, 18, 19, 18, 19, 20, 21, 22, 23, 20
Offset: 1

Views

Author

Amarnath Murthy, Oct 17 2002

Keywords

Comments

If a(k) is the first occurrence of a prime p(r), the r-th prime then a(k+1) = p(r-1) + 1,... a(k+m) = p(r-1) + m until a(k + p(r)-p(r-1))= p(r) again.( the second and the last occurrence of p(r)).

Crossrefs

Cf. A076271.

A076274 2p-1 where p is 1 or a prime.

Original entry on oeis.org

1, 3, 5, 9, 13, 21, 25, 33, 37, 45, 57, 61, 73, 81, 85, 93, 105, 117, 121, 133, 141, 145, 157, 165, 177, 193, 201, 205, 213, 217, 225, 253, 261, 273, 277, 297, 301, 313, 325, 333, 345, 357, 361, 381, 385, 393, 397, 421, 445, 453, 457, 465, 477, 481, 501, 513, 525, 537, 541
Offset: 1

Views

Author

Reinhard Zumkeller, Oct 04 2002

Keywords

Crossrefs

Positions of squares in A076271.
Subsequence of A186621 and of A005408.

Programs

Formula

A076271(a(n)) = A008578(n)^2 for all n.
a(n+1) - a(n) = 2*A075526(n) for all n.
G.f.: 1 + Sum_{ j>=1 } Sum_{ k>=1 } x^(pi(k/2)+j), where pi(k) is the prime counting function. - Benedict W. J. Irwin, Jun 13 2016
a(n) = 2*A008578(n) - 1. - Alois P. Heinz, Nov 28 2023

Extensions

New definition from Thomas Baruchel, Oct 21 2003
Offset changed from Vincenzo Librandi, Jul 31 2017

A070229 Next m>n such that m is divisible by lpf(n), lpf=A006530 largest prime factor.

Original entry on oeis.org

2, 4, 6, 6, 10, 9, 14, 10, 12, 15, 22, 15, 26, 21, 20, 18, 34, 21, 38, 25, 28, 33, 46, 27, 30, 39, 30, 35, 58, 35, 62, 34, 44, 51, 42, 39, 74, 57, 52, 45, 82, 49, 86, 55, 50, 69, 94, 51, 56, 55, 68, 65, 106, 57, 66, 63, 76, 87, 118, 65, 122
Offset: 1

Views

Author

Reinhard Zumkeller, May 07 2002

Keywords

Comments

Or, for n>1, n + (largest prime divisor of n). [Anne Robinson, daughter of Herman P. Robinson, Oct 08 1981]

Crossrefs

Cf. A036441.
Iterations: A076271 (start=1), A036441 (start=2), A123581 (start=3).

Programs

Formula

a(n) = (n/lpf(n)+1)*lpf(n).
a(n) = n+lpf(n) where lpf=A006530 largest prime factor. For example, a(14)=14+7=21 (instead of ((14/7)+1)*7). - Philippe Lallouet (philip.lallouet(AT)wanadoo.fr), Jun 14 2007

A256393 Start from a(1) = 2, then alternately add either the largest (if n is even), or the smallest (if n is odd) prime factor of the preceding term a(n-1) to get a(n).

Original entry on oeis.org

2, 4, 6, 9, 12, 15, 18, 21, 24, 27, 30, 35, 40, 45, 48, 51, 54, 57, 60, 65, 70, 77, 84, 91, 98, 105, 108, 111, 114, 133, 140, 147, 150, 155, 160, 165, 168, 175, 180, 185, 190, 209, 220, 231, 234, 247, 260, 273, 276, 299, 312, 325, 330, 341, 352, 363, 366, 427
Offset: 1

Views

Author

Jan Guichelaar, Mar 28 2015

Keywords

Comments

After the initial term, each even-indexed term equals the preceding term plus its largest prime factor, and each odd-indexed term equals the preceding term plus its smallest prime factor.
See also sequence A076271 where a(n+1) = a(n) + lpf(a(n)).
Each term shares exactly one prime factor with the immediately preceding term, and because the sequence is strictly increasing, all the terms after 2 are composite. - Antti Karttunen, Apr 19 2015
From a(3) onward, the terms are alternately even and odd. - Jan Guichelaar, Apr 24 2015
a(2*n) = A070229(a(2*n-1)); a(2*n+1) = A061228(a(2*n)). - Reinhard Zumkeller, May 06 2015
For prime p let [p] denote the sequence with a(1)=p, and generated as for the terms of the current sequence (which according to this notation is then the same as [2]). It so happens that the sequence [p] (for any p?) merges with [2] sooner or later, taking the form of a "tree" as shown in the attached image (Including prime starts up to p=67). Is this pattern of merging bounded or not? Is there just one tree or are there many? Interesting to speculate. The numbers corresponding to the arrival points in [2] of [p] is the sequence 2,6,15,21,51,57,77,84.... The sequence of ("excluded") numbers which do not arise in [p] for any prime p starts as 8,16,20,25,28,32,36,44... Other sequences may refer to the number of iterations required to merge [p] into [2]. See tree picture. - David James Sycamore, Aug 25 2016
In this picture, one could also include some [c] sequences, with composite c, see A276269. - Michel Marcus, Aug 26 2016

Crossrefs

Cf. A006530 (greatest prime factor), A020639 (least prime factor), A076271.
Cf. A257244 (the first differences; the unique prime factors shared by each pair of successive terms), A257245, A257246 (their bisections), A257247 (numbers n such that GCD(a(2n-1),a(2n)) = GCD(a(2n),a(2n+1)), which is prime).

Programs

  • Haskell
    a256393 n = a256393_list !! (n-1)
    a256393_list = 2 : zipWith ($) (cycle [a070229, a061228]) a256393_list
    -- Reinhard Zumkeller, May 06 2015
  • Maple
    a[1]:= 2;
    for n from 2 to 100 do
      if n::even then a[n]:= a[n-1] + max(numtheory:-factorset(a[n-1]))
      else a[n]:= a[n-1] + min(numtheory:-factorset(a[n-1]))
      fi
    od:
    seq(a[i],i=1..100); # Robert Israel, May 03 2015
  • Mathematica
    f[n_] := Block[{pf = First /@ FactorInteger@ n}, If[EvenQ@ n, Max@ pf, Min@ pf]]; s = {2}; lmt = 58; For[k = 2, k <= lmt, k++, AppendTo[s, s[[k - 1]] + f@ s[[k - 1]]]]; s (* Michael De Vlieger, Apr 19 2015 *)
    FoldList[Function[f, If[EvenQ@ #2, #1 + First@ f, #1 + Last@ f]][FactorInteger[#1][[All, 1]]] &, Range[2, 59]] (* Michael De Vlieger, Aug 26 2016 *)
  • PARI
    lista(nn) = {print1(a = 2, ", "); for (n=2, nn, f = factor(a); if (n % 2, a += f[1, 1], a += f[#f~, 1]); print1(a, ", "););} \\ Michel Marcus, Apr 02 2015
    
  • Scheme
    ;; With memoization-macro definec.
    (definec (A256393 n) (cond ((= 1 n) 2) ((even? n) (+ (A256393 (- n 1)) (A006530 (A256393 (- n 1))))) (else (+ (A256393 (- n 1)) (A020639 (A256393 (- n 1))))))) ;; Antti Karttunen, Apr 18 2015
    

Formula

a(1) = 2; a(2n) = a(2n-1) + gpf(a(2n-1)), a(2n+1) = a(2n) + lpf(a(2n)), where gpf = greatest prime factor = A006530, lpf = least prime factor = A020639.

Extensions

More terms from Michel Marcus, Apr 02 2015
Replaced the name with more succinct description, moved old name to comments - Antti Karttunen, Apr 18-19 2015

A036441 a(n+1) = next number having largest prime dividing a(n) as a factor, with a(1) = 2.

Original entry on oeis.org

2, 4, 6, 9, 12, 15, 20, 25, 30, 35, 42, 49, 56, 63, 70, 77, 88, 99, 110, 121, 132, 143, 156, 169, 182, 195, 208, 221, 238, 255, 272, 289, 306, 323, 342, 361, 380, 399, 418, 437, 460, 483, 506, 529, 552, 575, 598, 621, 644, 667, 696, 725, 754, 783, 812, 841, 870
Offset: 1

Views

Author

Frederick Magata (frederick.magata(AT)uni-muenster.de)

Keywords

Comments

a(n) satisfies the following inequality: (1/4)*(n^2 + 3*n + 1) <= a(n) <= (1/4)*(n+2)^2. [Corrected by M. F. Hasler, Apr 08 2015]
The present sequence is the special case a(n) = a(2,n) with a more general a(m, n) := a(m, n-1) + gpf(a(m, n-1)), a(m, 1) := m, where gpf(x) := "greatest prime factor of x" = A006530(x). Also a(a(r,k), n) = a(r,n+k-1), for all n,k in N\{0} and all r in N\{0,1}; a(prime(k), n) = a(prime(i), n + prime(k) - prime(i)), for all k,i,n in N\{0}, with k >= i, n >= prime(k-1) and with prime(x) := x-th prime.
Essentially the same as A076271 and A180107, cf. formula.

Examples

			a(2,2) = 4 because 2 + gpf(2) = 2 + 2 = 4;
a(2,3) = 6 because 4 + gpf(4) = 4 + 2 = 6.
		

Crossrefs

Cf. A006530. See A076271 and A180107 for other versions.
Cf. A123581.
Partial sums of A076973.

Programs

  • Haskell
    a036441 n = a036441_list !! (n-1)
    a036441_list = tail a076271_list
    -- Reinhard Zumkeller, Nov 08 2015, Nov 14 2011
    
  • Mathematica
    f[n_]:=Last[First/@FactorInteger[n]];Join[{a=2},Table[a+=f[a],{n,2,100}]] (* Vladimir Joseph Stephan Orlovsky, Feb 08 2011*)
    NestList[#+FactorInteger[#][[-1,1]]&,2,60] (* Harvey P. Dale, Dec 02 2012 *)
  • PARI
    a(n)=(n+2-if(n\2+1<(p=nextprime(n\2+1))&&n+1M. F. Hasler, Apr 08 2015

Formula

a(n) = p(m)*(n+2-p(m)), where p(k) is the k-th prime and m is the smallest index such that n+2 <= p(m) + p(m+1). - Max Alekseyev, Oct 21 2008
a(n) = A076271(n+1) = A180107(n+2). - M. F. Hasler, Apr 08 2015
a(n+1) = A070229(a(n)). - Reinhard Zumkeller, Nov 07 2015

Extensions

Better description from Reinhard Zumkeller, Feb 04 2002
Edited by M. F. Hasler, Apr 08 2015

A180107 Partial sums of terms in A180101.

Original entry on oeis.org

0, 1, 1, 2, 4, 6, 9, 12, 15, 20, 25, 30, 35, 42, 49, 56, 63, 70, 77, 88, 99, 110, 121, 132, 143, 156, 169, 182, 195, 208, 221, 238, 255, 272, 289, 306, 323, 342, 361, 380, 399, 418, 437, 460, 483, 506, 529, 552, 575, 598, 621, 644, 667, 696, 725, 754, 783, 812, 841, 870, 899, 930, 961, 992, 1023, 1054, 1085, 1116, 1147, 1184, 1221, 1258, 1295, 1332, 1369, 1406, 1443, 1480, 1517, 1558, 1599, 1640
Offset: 0

Views

Author

N. J. A. Sloane, Jan 16 2011

Keywords

Comments

Apart from initial terms, same as A036441 and A076271, but the simple definition warrants an independent entry.

Crossrefs

A123581 a(1) = 3, a(n) = a(n-1) + greatest prime factor of a(n-1).

Original entry on oeis.org

3, 6, 9, 12, 15, 20, 25, 30, 35, 42, 49, 56, 63, 70, 77, 88, 99, 110, 121, 132, 143, 156, 169, 182, 195, 208, 221, 238, 255, 272, 289, 306, 323, 342, 361, 380, 399, 418, 437, 460, 483, 506, 529, 552, 575, 598, 621, 644, 667, 696, 725, 754, 783, 812, 841, 870
Offset: 1

Views

Author

Ben Paul Thurston, Nov 12 2006

Keywords

Examples

			a(16) = 88 because a(15) is 77 whose largest prime factor is 11 so 77 + 11 = 88.
		

Crossrefs

Essentially the same as A036441 and A076271.
Cf. A070229.

Programs

  • Haskell
    a123581 n = a123581_list !! (n-1)
    a123581_list = iterate a070229 3  -- Reinhard Zumkeller, Nov 07 2015
  • Maple
    A123581:= proc(n) option remember;
    local t;
    t:= procname(n-1);
    t + max(numtheory[factorset](t));
    end proc;
    A123581(1):= 3;
    seq(A123581(n),n=1..100); # Robert Israel, May 18 2014
  • Mathematica
    a[1] = 3; a[n_] := a[n] = a[n - 1] + FactorInteger[a[n - 1]][[ -1, 1]]; Array[a, 56] (* Robert G. Wilson v *)
  • PARI
    {print1(a=3,",");for(n=2,57,print1(a=a+vecmax(factor(a)[,1]),","))} \\ Klaus Brockhaus, Nov 19 2006
    

Formula

a(n+1) = A070229(a(n)). - Reinhard Zumkeller, Nov 07 2015

Extensions

More terms from Robert G. Wilson v and Klaus Brockhaus, Nov 18 2006

A367504 a(1) = 2; for n > 1, a(n) = a(n-1) + 2*gpf(a(n-1)), where gpf(k) = A006530(k) = greatest prime dividing k.

Original entry on oeis.org

2, 6, 12, 18, 24, 30, 40, 50, 60, 70, 84, 98, 112, 126, 140, 154, 176, 198, 220, 242, 264, 286, 312, 338, 364, 390, 416, 442, 476, 510, 544, 578, 612, 646, 684, 722, 760, 798, 836, 874, 920, 966, 1012, 1058, 1104, 1150, 1196, 1242, 1288, 1334, 1392, 1450, 1508, 1566, 1624, 1682, 1740, 1798
Offset: 1

Views

Author

Scott R. Shannon, Nov 21 2023

Keywords

Comments

Conjecture: with the requirement that the prime factorization of each term is written so that the primes are ordered from smallest to largest, the sequence is the lexicographically earliest infinite sequence of distinct positive numbers such that gpf(a(n-1)) * lpf(a(n)) = |a(n) - a(n-1)|, where gpf(k) = A006530(k) = greatest prime factor of k and lpf(k) = A020639(k) = least prime factor of k. In this way the sequence is the ordered prime factorization version of the 'Commas sequence', A121805. One can show that, for such a sequence to be infinite, no odd number can appear. Although for many terms a lower even number can be chosen for the following term, which can lead to even lower numbers for further terms, it is conjectured all such choices will ultimately halt the sequence as a number is eventually reached for which no unused next number exists which follows the required rule for the difference between the terms. Therefore all terms must be larger than the previous, and the earliest such infinite sequence is the given sequence.
See A367465 for the sequence when the requirement that the primes in the factorization of each term must be in order is removed.

Examples

			a(7) = 40 as a(6) = 30 = 2*3*5, thus A006530(30) = 5 and a(7) = a(6) + 2*5 = 30 + 2*5 = 40.
		

Crossrefs

Programs

  • Mathematica
    NestList[#+2FactorInteger[#][[-1,1]]&,2,100] (* Paolo Xausa, Dec 31 2023 *)

Formula

a(n) = 2*A123581(n). The exponent of 2 in a(2n) is 1+A367624(n). - N. J. A. Sloane, Dec 06 2023
Showing 1-10 of 12 results. Next