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.

A257247 Numbers n such that A257245(n) = A257246(n), or equally, where A257244(2n) = A257244(2n-1).

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 8, 9, 10, 11, 12, 14, 17, 20, 23, 27, 31, 36, 49, 51, 56, 59, 63, 66, 67, 69, 74, 78, 81, 88, 89, 91, 93, 97, 99, 101, 102, 114, 116, 120, 123, 126, 134, 141, 144, 146, 148, 152, 161, 163, 172, 173, 179, 192, 194, 195, 202, 207, 214, 219, 223, 227, 235, 240, 242, 246, 250, 252, 256
Offset: 1

Views

Author

Antti Karttunen, Apr 19 2015

Keywords

Comments

The sequence gives numbers n such that A257244(2n) = A257244(2n-1), in other words, where the difference A256393(2n+1) - A256393(2n) is equal to the difference A256393(2n) - A256393(2n-1). This is equal to the condition that A256393(2n-1) and A256393(2n) share the same unique prime factor that A256393(2n) and A256393(2n+1) also share.
Also, numbers n such that the largest prime factor (A006530) of A256393(2n - 1) is equal to the smallest prime factor (A020639) of A256393(2n).

Examples

			Terms A256393[3949..3951] = (6299579580, 6299580499, 6299581418) factorize as 2*2*3*5*7*19*859*919, 919*919*7459, 2*13*919*263647. We see that gcd(A256393(3949),A256393(3950)) = gcd(A256393(3950),A256393(3951)) = 919, thus 3950/2 = 1975 is included in the sequence.
		

Crossrefs

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

A257244 First differences of A256393: a(n) = A256393(n+1) - A256393(n).

Original entry on oeis.org

2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 5, 5, 5, 3, 3, 3, 3, 3, 5, 5, 7, 7, 7, 7, 7, 3, 3, 3, 19, 7, 7, 3, 5, 5, 5, 3, 7, 5, 5, 5, 19, 11, 11, 3, 13, 13, 13, 3, 23, 13, 13, 5, 11, 11, 11, 3, 61, 7, 31, 3, 13, 13, 19, 3, 43, 13, 13, 3, 7, 5, 5, 5, 61, 11, 31, 23, 23, 3, 127, 7, 7, 3, 151, 7, 19, 3, 181, 7, 13, 3, 43, 31, 31
Offset: 1

Views

Author

Antti Karttunen, Apr 19 2015

Keywords

Comments

Sequence gives the differences between the successive terms of A256393, each difference being equal to their unique shared prime factor.

Crossrefs

Cf. A257245, A257246 (bisections), A257247 (positions where they coincide).
Cf. A256393.

Programs

  • Haskell
    a257244 n = a257244_list !! (n-1)
    a257244_list = zipWith gcd a256393_list $ tail a256393_list
    -- Reinhard Zumkeller, May 06 2015
  • Mathematica
    f[n_] := Block[{pf = First /@ FactorInteger@ n},
      If[EvenQ@ n, Max@ pf, Min@ pf]]; s = {2}; lmt = 94; For[k = 2,
    k <= lmt, k++, AppendTo[s, s[[k - 1]] + f@ s[[k - 1]]]]; Abs[
    Subtract @@@ Partition[s, 2, 1]] (* Michael De Vlieger, Apr 19 2015 *)

Formula

a(n) = A256393(n+1) - A256393(n).
a(n) = gcd(A256393(n+1), A256393(n)).

A257245 Odd bisection of A257244: a(n) = A257244(2n - 1).

Original entry on oeis.org

2, 3, 3, 3, 3, 5, 5, 3, 3, 5, 7, 7, 7, 3, 19, 7, 5, 5, 7, 5, 19, 11, 13, 13, 23, 13, 11, 11, 61, 31, 13, 19, 43, 13, 7, 5, 61, 31, 23, 127, 7, 151, 19, 181, 13, 43, 31, 233, 13, 13, 7, 11, 19, 31, 59, 31, 31, 163, 41, 41, 113, 11, 19, 19, 409, 41, 41, 41, 19, 41, 113, 29, 167, 13, 17, 11, 179, 19, 19, 13, 5
Offset: 1

Views

Author

Antti Karttunen, Apr 19 2015

Keywords

Crossrefs

Cf. also A257246 (the other bisection), A257247 (gives the positions where both bisections have the same value).

Formula

a(n) = A257244(2n - 1).
a(n) = A006530(A256393(2n - 1)). [Equally, the largest prime factor of A256393(2n-1).]
Other identities and observations:
For all n >= 1, a(n) >= A257246(n).
Showing 1-4 of 4 results.