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

A102442 Number of iterations needed to transform n by A102440 into a 3-smooth number.

Original entry on oeis.org

0, 0, 0, 0, 1, 0, 1, 0, 0, 1, 2, 0, 2, 1, 1, 0, 2, 0, 2, 1, 1, 2, 3, 0, 1, 2, 0, 1, 3, 1, 3, 0, 2, 2, 1, 0, 2, 2, 2, 1, 3, 1, 3, 2, 1, 3, 4, 0, 1, 1, 2, 2, 3, 0, 2, 1, 2, 3, 4, 1, 4, 3, 1, 0, 2, 2, 3, 2, 3, 1, 4, 0, 4, 2, 1, 2, 2, 2, 3, 1, 0, 3, 4, 1, 2, 3, 3, 2, 4, 1, 2, 3, 3, 4, 2, 0, 3, 1, 2, 1, 3, 2, 3, 2, 1
Offset: 1

Views

Author

Reinhard Zumkeller, Jan 09 2005

Keywords

Examples

			A102440(A102440(A102440(41))) = 24 and A102440(24) = 24:
41 -> 3*13 -> 3*[13->2*5] = 2*3*5 -> 2*3*[5->2*2] = 3*2^3 = 24,
therefore a(41) = 3, A102443(41) = 24.
		

Crossrefs

Programs

  • Mathematica
    g[p_] := g[p] = For[k = p - 1, True, k--, If[PrimeOmega[k] == 2, Return[k]]]; f[n_] := Product[{p, e} = pe; If[p <= 3, p, g[p]]^e, {pe, FactorInteger[n]}]; a[n_] := -1 + Length @ NestWhileList[f, n, FactorInteger[#][[-1, 1]] > 3 &]; Array[a, 105] (* Amiram Eldar, Feb 04 2020 after Jean-François Alcover at A102440 *)

Formula

a(n) = 0 iff n is 3-smooth (A003586);
a(A102444(n)) = n and a(m) < n for m < a(A102444(n)).

A102443 a(n)=b(n, A102442(n)), where b(n,0)=n and b(n,k+1)=A102440(b(n,k)).

Original entry on oeis.org

1, 2, 3, 4, 4, 6, 6, 8, 9, 8, 8, 12, 8, 12, 12, 16, 12, 18, 12, 16, 18, 16, 16, 24, 16, 16, 27, 24, 16, 24, 16, 32, 24, 24, 24, 36, 24, 24, 24, 32, 24, 36, 24, 32, 36, 32, 32, 48, 36, 32, 36, 32, 36, 54, 32, 48, 36, 32, 32, 48, 32, 32, 54, 64, 32, 48, 32, 48, 48, 48, 48, 72, 48
Offset: 1

Views

Author

Reinhard Zumkeller, Jan 09 2005

Keywords

Comments

a(a(n)) = A102440(a(n)) = a(n).
Completely multiplicative because A102440 is. The conversion of every prime into a 3-smooth number is independent of any other prime. - Andrew Howroyd, Jul 31 2018

Examples

			See A102442.
		

Crossrefs

Programs

  • Mathematica
    g[p_] := (* greatest semiprime less than prime p *) g[p] = For[k = p - 1, True, k--, If[PrimeOmega[k] == 2, Return[k]]];
    A102440[n_] := Product[{p, e} = pe; If[p <= 3, p, g[p]]^e, {pe, FactorInteger[n]}];
    A102442[n_] := Length[NestWhileList[A102440, n, FactorInteger[#][[-1, 1]] > 3 & ] - 1];
    a[n_] := b[n, A102442[n]];
    b[n_, 0] := n;
    b[n_, k_] := A102440[b[n, k - 1]];
    Table[a[n], {n, 1, 100}] (* Jean-François Alcover, Oct 16 2021 *)
  • PARI
    a(n)={while(1, my(f=factor(n)); if(!#select(t->t>3, f[,1]), return(n), n=prod(i=1, #f~, my(p=f[i,1]); while(p>4 && bigomega(p)<>2, p--); p^f[i,2])))} \\ Andrew Howroyd, Jul 31 2018

A102441 a(n) = A102440(A102440(n)).

Original entry on oeis.org

1, 2, 3, 4, 4, 6, 6, 8, 9, 8, 8, 12, 8, 12, 12, 16, 12, 18, 12, 16, 18, 16, 20, 24, 16, 16, 27, 24, 20, 24, 20, 32, 24, 24, 24, 36, 24, 24, 24, 32, 30, 36, 30, 32, 36, 40, 44, 48, 36, 32, 36, 32, 45, 54, 32, 48, 36, 40, 52, 48, 52, 40, 54, 64, 32, 48, 40, 48, 60, 48, 66, 72, 66
Offset: 1

Views

Author

Reinhard Zumkeller, Jan 09 2005

Keywords

Comments

See A102442, A102443 for further iterations of A102440.

Crossrefs

Programs

  • Mathematica
    g[p_] := g[p] = For[k = p - 1, True, k--, If[PrimeOmega[k] == 2, Return[k]]]; f[n_] := Product[{p, e} = pe; If[p <= 3, p, g[p]]^e, {pe, FactorInteger[n]}]; a[n_] := f[f[n]]; Array[a, 100] (* Amiram Eldar, Feb 04 2020 after Jean-François Alcover at A102440 *)

A102415 Greatest semiprime less than n-th prime.

Original entry on oeis.org

4, 6, 10, 10, 15, 15, 22, 26, 26, 35, 39, 39, 46, 51, 58, 58, 65, 69, 69, 77, 82, 87, 95, 95, 95, 106, 106, 111, 123, 129, 134, 134, 146, 146, 155, 161, 166, 169, 178, 178, 187, 187, 194, 194, 209, 221, 226, 226, 226, 237, 237, 249, 254, 262, 267, 267, 274, 278, 278
Offset: 3

Views

Author

Reinhard Zumkeller, Jan 08 2005

Keywords

Examples

			a(3) = 4 since 4 is the greatest semiprime less than prime(3) = 5.
		

Crossrefs

Programs

  • Mathematica
    a[n_] := Module[{m = Prime[n] - 1}, While[PrimeOmega[m] != 2, m--]; m]; Array[a, 60, 3] (* Amiram Eldar, Feb 06 2020 *)
  • PARI
    a(n) = {sp = prime(n)-1; while(bigomega(sp) != 2, sp--); sp;} \\ Michel Marcus, Mar 04 2017

Formula

a(n) < A000040(n) < A102414(n).

A102444 Smallest number m such that A102442(m)=n.

Original entry on oeis.org

1, 5, 11, 23, 47, 149, 359, 719, 1439, 2879, 12097, 24197, 48407, 96821, 193649, 968237, 2614327, 5809201, 11618413, 25055857, 75167579, 225502703, 451005407, 2109888899, 4510054327, 14500925539, 43502776619, 87005553241, 174011106487
Offset: 1

Views

Author

Reinhard Zumkeller, Jan 09 2005

Keywords

Comments

Primes: a(n+1) > 2*a(n).

Crossrefs

Cf. A102440.
A056637 describes another iteration that reduces primes to 2 and 3.

Extensions

More terms from David Wasserman, Apr 04 2008
Showing 1-5 of 5 results.