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 20 results. Next

A329618 a(n) = gcd(A001222(n), A324888(n)), where A324888(n) is the minimal number of primorials (A002110) that add to A108951(n).

Original entry on oeis.org

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

Views

Author

Antti Karttunen, Nov 18 2019

Keywords

Crossrefs

Programs

  • Mathematica
    With[{b = Reverse@ Prime@ Range@ 120}, Array[GCD[PrimeOmega@ #1, Total@ IntegerDigits[#2, MixedRadix[b]]] & @@ {#, Apply[Times, Map[#1^#2 & @@ # &, FactorInteger[#] /. {p_, e_} /; e > 0 :> {Times @@ Prime@ Range@ PrimePi@ p, e}]]} &, 105] ] (* Michael De Vlieger, Nov 18 2019 *)
  • PARI
    A034386(n) = prod(i=1, primepi(n), prime(i));
    A108951(n) = { my(f=factor(n)); prod(i=1, #f~, A034386(f[i, 1])^f[i, 2]) };  \\ From A108951
    A276086(n) = { my(m=1, p=2); while(n, m *= (p^(n%p)); n = n\p; p = nextprime(1+p)); (m); };
    A324886(n) = A276086(A108951(n));
    A329618(n) = gcd(bigomega(n), bigomega(A324886(n)));

Formula

a(n) = gcd(A001222(n), A324888(n)) = gcd(A001222(n), A001222(A324886(n))).

A329621 a(n) = gcd(A056239(n), A324888(n)) = gcd(A001222(A108951(n)), A001222(A324886(n))).

Original entry on oeis.org

1, 1, 1, 2, 1, 1, 1, 1, 2, 2, 1, 4, 1, 1, 1, 4, 1, 1, 1, 1, 6, 2, 1, 1, 6, 1, 2, 2, 1, 6, 1, 1, 1, 2, 1, 2, 1, 1, 2, 2, 1, 1, 1, 1, 1, 2, 1, 2, 8, 1, 3, 4, 1, 1, 2, 1, 2, 1, 1, 1, 1, 2, 2, 2, 1, 4, 1, 1, 1, 2, 1, 1, 1, 1, 2, 2, 9, 3, 1, 1, 8, 2, 1, 4, 2, 1, 6, 8, 1, 4, 2, 1, 1, 2, 1, 1, 1, 1, 3, 8, 1, 2, 1, 1, 1
Offset: 1

Views

Author

Antti Karttunen, Nov 18 2019

Keywords

Crossrefs

Programs

  • Mathematica
    With[{b = MixedRadix[Reverse@ Prime@ Range@ 500]}, Array[GCD @@ PrimeOmega@ {#, Function[k, Times @@ Power @@@ # &@ Transpose@ {Prime@ Range@ Length@ k, Reverse@ k}]@ IntegerDigits[#, b]} &@ Apply[Times, Map[#1^#2 & @@ # &, FactorInteger[#] /. {p_, e_} /; e > 0 :> {Times @@ Prime@ Range@ PrimePi@ p, e}]] &, 105]] (* Michael De Vlieger, Nov 18 2019 *)
  • PARI
    A034386(n) = prod(i=1, primepi(n), prime(i));
    A108951(n) = { my(f=factor(n)); prod(i=1, #f~, A034386(f[i, 1])^f[i, 2]) };  \\ From A108951
    A276086(n) = { my(m=1, p=2); while(n, m *= (p^(n%p)); n = n\p; p = nextprime(1+p)); (m); };
    A329621(n) = { my(u=A108951(n)); gcd(bigomega(u), bigomega(A276086(u))); };

Formula

a(n) = gcd(A056239(n), A324888(n)) = gcd(A001222(A108951(n)), A001222(A324886(n))).

A329622 a(n) = A056239(n) - A324888(n) = A001222(A108951(n)) - A001222(A324886(n)).

Original entry on oeis.org

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

Views

Author

Antti Karttunen, Nov 18 2019

Keywords

Crossrefs

Programs

  • Mathematica
    With[{b = MixedRadix[Reverse@ Prime@ Range@ 500]}, Array[Subtract @@ PrimeOmega@ {#, Function[k, Times @@ Power @@@ # &@ Transpose@ {Prime@ Range@ Length@ k, Reverse@ k}]@ IntegerDigits[#, b]} &@ Apply[Times, Map[#1^#2 & @@ # &, FactorInteger[#] /. {p_, e_} /; e > 0 :> {Times @@ Prime@ Range@ PrimePi@ p, e}]] &, 95]] (* Michael De Vlieger, Nov 18 2019 *)
  • PARI
    A034386(n) = prod(i=1, primepi(n), prime(i));
    A108951(n) = { my(f=factor(n)); prod(i=1, #f~, A034386(f[i, 1])^f[i, 2]) };  \\ From A108951
    A276086(n) = { my(m=1, p=2); while(n, m *= (p^(n%p)); n = n\p; p = nextprime(1+p)); (m); };
    A329622(n) = { my(u=A108951(n)); (bigomega(u) - bigomega(A276086(u))); };

Formula

a(n) = A056239(n) - A324888(n) = A001222(A108951(n)) - A001222(A324886(n)).

A108951 Primorial inflation of n: Fully multiplicative with a(p) = p# for prime p, where x# is the primorial A034386(x).

Original entry on oeis.org

1, 2, 6, 4, 30, 12, 210, 8, 36, 60, 2310, 24, 30030, 420, 180, 16, 510510, 72, 9699690, 120, 1260, 4620, 223092870, 48, 900, 60060, 216, 840, 6469693230, 360, 200560490130, 32, 13860, 1021020, 6300, 144, 7420738134810, 19399380, 180180, 240, 304250263527210, 2520
Offset: 1

Views

Author

Paul Boddington, Jul 21 2005

Keywords

Comments

This sequence is a permutation of A025487.
And thus also a permutation of A181812, see the formula section. - Antti Karttunen, Jul 21 2014
A previous description of this sequence was: "Multiplicative with a(p^e) equal to the product of the e-th powers of all primes at most p" (see extensions), Giuseppe Coppoletta, Feb 28 2015

Examples

			a(12) = a(2^2) * a(3) = (2#)^2 * (3#) = 2^2 * 6 = 24
a(45) = (3#)^2 * (5#) = (2*3)^2 * (2*3*5) = 1080 (as 45 = 3^2 * 5).
		

Crossrefs

Programs

  • Mathematica
    a[n_] := a[n] = Module[{f = FactorInteger[n], p, e}, If[Length[f]>1, Times @@ a /@ Power @@@ f, {{p, e}} = f; Times @@ (Prime[Range[PrimePi[p]]]^e)]]; a[1] = 1; Table[a[n], {n, 1, 42}] (* Jean-François Alcover, Feb 24 2015 *)
    Table[Times @@ Map[#1^#2 & @@ # &, FactorInteger[n] /. {p_, e_} /; e > 0 :> {Times @@ Prime@ Range@ PrimePi@ p, e}], {n, 42}] (* Michael De Vlieger, Mar 18 2017 *)
  • PARI
    primorial(n)=prod(i=1,primepi(n),prime(i))
    a(n)=my(f=factor(n)); prod(i=1,#f~, primorial(f[i,1])^f[i,2]) \\ Charles R Greathouse IV, Jun 28 2015
    
  • Python
    from sympy import primerange, factorint
    from operator import mul
    def P(n): return reduce(mul, [i for i in primerange(2, n + 1)])
    def a(n):
        f = factorint(n)
        return 1 if n==1 else reduce(mul, [P(i)**f[i] for i in f])
    print([a(n) for n in range(1, 101)]) # Indranil Ghosh, May 14 2017
  • Sage
    def sharp_primorial(n): return sloane.A002110(prime_pi(n))
    def p(f):
        return sharp_primorial(f[0])^f[1]
    [prod(p(f) for f in factor(n)) for n in range (1,51)]
    # Giuseppe Coppoletta, Feb 07 2015
    

Formula

Dirichlet g.f.: 1/(1-2*2^(-s))/(1-6*3^(-s))/(1-30*5^(-s))...
Completely multiplicative with a(p_i) = A002110(i) = prime(i)#. [Franklin T. Adams-Watters, Jun 24 2009; typos corrected by Antti Karttunen, Jul 21 2014]
From Antti Karttunen, Jul 21 2014: (Start)
a(1) = 1, and for n > 1, a(n) = n * a(A064989(n)).
a(n) = n * A181811(n).
a(n) = A002110(A061395(n)) * A331188(n). - [added Jan 14 2020]
a(n) = A181812(A048673(n)).
Other identities:
A006530(a(n)) = A006530(n). [Preserves the largest prime factor of n.]
A071178(a(n)) = A071178(n). [And also its exponent.]
a(2^n) = 2^n. [Fixes the powers of two.]
A067029(a(n)) = A007814(a(n)) = A001222(n). [The exponent of the least prime of a(n), that prime always being 2 for n>1, is equal to the total number of prime factors in n.]
(End)
From Antti Karttunen, Nov 19 2019: (Start)
Further identities:
a(A307035(n)) = A000142(n).
a(A003418(n)) = A181814(n).
a(A025487(n)) = A181817(n).
a(A181820(n)) = A181822(n).
a(A019565(n)) = A283477(n).
A001221(a(n)) = A061395(n).
A001222(a(n)) = A056239(n).
A181819(a(n)) = A122111(n).
A124859(a(n)) = A181821(n).
A085082(a(n)) = A238690(n).
A328400(a(n)) = A329600(n). (smallest number with the same set of distinct prime exponents)
A000188(a(n)) = A329602(n). (square root of the greatest square divisor)
A072411(a(n)) = A329378(n). (LCM of exponents of prime factors)
A005361(a(n)) = A329382(n). (product of exponents of prime factors)
A290107(a(n)) = A329617(n). (product of distinct exponents of prime factors)
A000005(a(n)) = A329605(n). (number of divisors)
A071187(a(n)) = A329614(n). (smallest prime factor of number of divisors)
A267115(a(n)) = A329615(n). (bitwise-AND of exponents of prime factors)
A267116(a(n)) = A329616(n). (bitwise-OR of exponents of prime factors)
A268387(a(n)) = A329647(n). (bitwise-XOR of exponents of prime factors)
A276086(a(n)) = A324886(n). (prime product form of primorial base expansion)
A324580(a(n)) = A324887(n).
A276150(a(n)) = A324888(n). (digit sum in primorial base)
A267263(a(n)) = A329040(n). (number of distinct nonzero digits in primorial base)
A243055(a(n)) = A329343(n).
A276088(a(n)) = A329348(n). (least significant nonzero digit in primorial base)
A276153(a(n)) = A329349(n). (most significant nonzero digit in primorial base)
A328114(a(n)) = A329344(n). (maximal digit in primorial base)
A062977(a(n)) = A325226(n).
A097248(a(n)) = A283478(n).
A324895(a(n)) = A324896(n).
A324655(a(n)) = A329046(n).
A327860(a(n)) = A329047(n).
A329601(a(n)) = A329607(n).
(End)
a(A181815(n)) = A025487(n), and A319626(a(n)) = A329900(a(n)) = n. - Antti Karttunen, Dec 29 2019
From Antti Karttunen, Jul 09 2021: (Start)
a(n) = A346092(n) + A346093(n).
a(n) = A346108(n) - A346109(n).
a(A342012(n)) = A004490(n).
a(A337478(n)) = A336389(n).
A336835(a(n)) = A337474(n).
A342002(a(n)) = A342920(n).
A328571(a(n)) = A346091(n).
A328572(a(n)) = A344592(n).
(End)
Sum_{n>=1} 1/a(n) = A161360. - Amiram Eldar, Aug 04 2022

Extensions

More terms computed by Antti Karttunen, Jul 21 2014
The name of the sequence was changed for more clarity, in accordance with the above remark of Franklin T. Adams-Watters (dated Jun 24 2009). It is implicitly understood that a(n) is then uniquely defined by completely multiplicative extension. - Giuseppe Coppoletta, Feb 28 2015
Name "Primorial inflation" (coined by Matthew Vandermast in A181815) prefixed to the name by Antti Karttunen, Jan 14 2020

A324886 a(n) = A276086(A108951(n)).

Original entry on oeis.org

2, 3, 5, 9, 7, 25, 11, 15, 35, 49, 13, 625, 17, 121, 117649, 225, 19, 1225, 23, 2401, 1771561, 169, 29, 875, 717409, 289, 55, 14641, 31, 184877, 37, 21, 4826809, 361, 36226650889, 1500625, 41, 529, 24137569, 77, 43, 143, 47, 28561, 1127357, 841, 53, 1715, 902613283, 514675673281, 47045881, 83521, 59, 3025, 8254129, 214358881, 148035889, 961, 61
Offset: 1

Views

Author

Antti Karttunen, Mar 30 2019

Keywords

Crossrefs

Programs

  • Mathematica
    With[{b = MixedRadix[Reverse@ Prime@ Range@ 120]}, Array[Function[k, Times @@ Power @@@ # &@ Transpose@ {Prime@ Range@ Length@ k, Reverse@ k}]@ IntegerDigits[Apply[Times, Map[#1^#2 & @@ # &, FactorInteger[#] /. {p_, e_} /; e > 0 :> {Times @@ Prime@ Range@ PrimePi@ p, e}]], b] &, 58]] (* Michael De Vlieger, Nov 18 2019 *)
    A276086[n0_] := Module[{m = 1, i = 1, n = n0, p}, While[n > 0, p = Prime[i]; m *= p^Mod[n, p]; n = Quotient[n, p]; i++]; m];
    (* b is A108951 *)
    b[n_] := b[n] = Module[{pe = FactorInteger[n], p, e}, If[Length[pe] > 1, Times @@ b /@ Power @@@ pe, {{p, e}} = pe; Times @@ (Prime[Range[ PrimePi[p]]]^e)]]; b[1] = 1;
    a[n_] := A276086[b[n]];
    Array[a, 100] (* Jean-François Alcover, Dec 01 2021, after _Antti Karttunen in A296086 *)
  • PARI
    A034386(n) = prod(i=1, primepi(n), prime(i));
    A108951(n) = { my(f=factor(n)); prod(i=1, #f~, A034386(f[i, 1])^f[i, 2]) };  \\ From A108951
    A276086(n) = { my(i=0,m=1,pr=1,nextpr); while((n>0),i=i+1; nextpr = prime(i)*pr; if((n%nextpr),m*=(prime(i)^((n%nextpr)/pr));n-=(n%nextpr));pr=nextpr); m; };
    A324886(n) = A276086(A108951(n));

Formula

a(n) = A276086(A108951(n)).
a(n) = A117366(n) * A324896(n).
A001222(a(n)) = A324888(n).
A020639(a(n)) = A117366(n).
A032742(a(n)) = A324896(n).
a(A000040(n)) = A000040(1+n).
From Antti Karttunen, Jul 09 2021: (Start)
For n > 1, a(n) = A003961(A329044(n)).
a(n) = A346091(n) * A344592(n).
a(n) = A346106(n) / A346107(n).
A003415(a(n)) = A329047(n).
A003557(a(n)) = A344592(n).
A342001(a(n)) = A342920(n) = A329047(n) / A344592(n).
(End)

A329902 Primorial deflation of the n-th highly composite number: the unique integer k such that A108951(k) = A002182(n).

Original entry on oeis.org

1, 2, 4, 3, 6, 12, 9, 24, 10, 20, 15, 40, 30, 60, 28, 21, 56, 42, 84, 63, 168, 126, 336, 140, 66, 189, 280, 132, 99, 264, 198, 528, 220, 396, 297, 440, 792, 156, 117, 312, 234, 624, 260, 468, 351, 520, 936, 390, 1040, 1872, 780, 585, 306, 1560, 340, 612, 459, 680, 1224, 510, 1360, 2448, 1020, 765, 342, 2040, 1530, 684, 513
Offset: 1

Views

Author

Antti Karttunen, Dec 22 2019

Keywords

Crossrefs

Programs

  • Mathematica
    Map[Times @@ Prime@(TakeWhile[Reap[FixedPointList[Block[{k = 1}, While[Mod[#, Prime@ k] == 0, k++]; Sow[k - 1]; #/Product[Prime@ i, {i, k - 1}]] &, #]][[-1, 1]], # > 0 &]) &, Take[Import["https://oeis.org/b002182.txt", "Data"][[All, -1]], 69] ] (* Michael De Vlieger, Jan 13 2020, imports b-file at A002182 *)

Formula

a(n) = A329900(A002182(n)) = A319626(A002182(n)).
a(n) = A181815(A306802(n)).
A108951(a(n)) = A002182(n). [Highly composite numbers (undeflated)]
A056239(a(n)) = A112778(n). [Number of prime factors, counted with multiplicity]
A001222(a(n)) = A112779(n). [Largest exponent in the prime factorization]
A329605(a(n)) = A002183(n). [Number of divisors]
A329040(a(n)) = A324381(n).
A324888(a(n)) = A324382(n).
a(A330748(n)) = A330743(n).

Extensions

More linking formulas added by Antti Karttunen, Jan 13 2020

A329040 Number of distinct primorials in the greedy sum of primorials adding to A108951(n).

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 2, 2, 1, 1, 1, 1, 1, 1, 2, 1, 2, 1, 1, 1, 1, 1, 2, 2, 1, 2, 1, 1, 2, 1, 2, 1, 1, 2, 2, 1, 1, 1, 2, 1, 2, 1, 1, 2, 1, 1, 2, 3, 2, 1, 1, 1, 2, 2, 1, 1, 1, 1, 2, 1, 1, 2, 2, 2, 1, 1, 1, 1, 2, 1, 3, 1, 1, 3, 1, 2, 1, 1, 2, 3, 1, 1, 2, 2, 1, 1, 1, 1, 2, 2, 1, 1, 1, 2, 2, 1, 3, 2, 3, 1, 1, 1, 1, 3
Offset: 1

Views

Author

Antti Karttunen, Nov 11 2019

Keywords

Comments

The greedy sum is also the sum with the minimal number of primorials used in the primorial base representation.

Examples

			For n = 18 = 2 * 3^2, A108951(18) = A034386(2) * A034386(3)^2 = 2 * 6^2 = 72 = 2*A002110(3) + 2*A002110(2) = 2*30 + 2*6, and because there occurs only two distinct primorials (30 and 6) in the sum, we have a(18) = 2.
		

Crossrefs

Cf. also A329045, A329046.

Programs

Formula

a(n) = A001221(A324886(n)).
a(n) = A267263(A108951(n)).
a(n) <= A324888(n).

A329348 The least significant nonzero digit in the primorial base expansion of primorial inflation of n, A108951(n).

Original entry on oeis.org

1, 1, 1, 2, 1, 2, 1, 1, 1, 2, 1, 4, 1, 2, 6, 2, 1, 2, 1, 4, 6, 2, 1, 3, 2, 2, 1, 4, 1, 5, 1, 1, 6, 2, 8, 4, 1, 2, 6, 1, 1, 1, 1, 4, 1, 2, 1, 1, 1, 4, 6, 4, 1, 2, 4, 8, 6, 2, 1, 3, 1, 2, 3, 2, 13, 12, 1, 4, 6, 5, 1, 3, 1, 2, 5, 4, 2, 12, 1, 2, 1, 2, 1, 2, 11, 2, 6, 8, 1, 2, 6, 4, 6, 2, 7, 2, 1, 2, 10, 1, 1, 12, 1, 8, 4
Offset: 1

Views

Author

Antti Karttunen, Nov 11 2019

Keywords

Comments

Number of occurrences of the least primorial present in the greedy sum of primorials adding to A108951(n).
The greedy sum is also the sum with the minimal number of primorials, used for example in the primorial base representation.

Examples

			For n = 24 = 2^3 * 3, A108951(24) = A034386(2)^3 * A034386(3) = 2^3 * 6 = 48 = 1*30 + 3*6, and as the factor of the least primorial in the sum is 3, we have a(24) = 3.
		

Crossrefs

Programs

Formula

a(n) = A067029(A324886(n)) = A276088(A108951(n)).
a(n) <= A324888(n).
From Antti Karttunen, Jan 15-17 2020: (Start)
a(n) = A331188(n) mod A117366(n).
a(n) = A001511(A246277(A324886(n))).
(End)

Extensions

Name changed by Antti Karttunen, Jan 17 2020

A329045 Lexicographically earliest infinite sequence such that a(i) = a(j) => A046523(A329044(i)) = A046523(A329044(j)) for all i, j.

Original entry on oeis.org

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

Views

Author

Antti Karttunen, Nov 08 2019

Keywords

Comments

Restricted growth sequence transform of function f(n) = A046523(A329044(n)).
For all i, j:
A305800(i) = A305800(j) => a(i) = a(j),
a(i) = a(j) => A324888(i) = A324888(j),
a(i) = a(j) => A329046(i) = A329046(j).

Crossrefs

Programs

  • PARI
    up_to = 65537;
    rgs_transform(invec) = { my(om = Map(), outvec = vector(length(invec)), u=1); for(i=1, length(invec), if(mapisdefined(om,invec[i]), my(pp = mapget(om, invec[i])); outvec[i] = outvec[pp] , mapput(om,invec[i],i); outvec[i] = u; u++ )); outvec; };
    A034386(n) = prod(i=1, primepi(n), prime(i));
    A108951(n) = { my(f=factor(n)); prod(i=1, #f~, A034386(f[i, 1])^f[i, 2]) };  \\ From A108951
    A276086(n) = { my(m=1, p=2); while(n, m *= (p^(n%p)); n = n\p; p = nextprime(1+p)); (m); };
    A324886(n) = A276086(A108951(n));
    A064989(n) = {my(f); f = factor(n); if((n>1 && f[1,1]==2), f[1,2] = 0); for (i=1, #f~, f[i,1] = precprime(f[i,1]-1)); factorback(f)};
    A329044(n) = A064989(A324886(n));
    A046523(n) = { my(f=vecsort(factor(n)[, 2], , 4), p); prod(i=1, #f, (p=nextprime(p+1))^f[i]); }; \\ From A046523
    v329045 = rgs_transform(vector(up_to, n, A046523(A329044(n))));
    A329045(n) = v329045[n];

A329343 Difference between the indices of the smallest and the largest primorial in the greedy sum of primorials adding to A108951(n).

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 1, 1, 0, 2, 0, 0, 1, 0, 2, 0, 0, 1, 1, 0, 0, 0, 1, 0, 1, 0, 0, 1, 0, 0, 1, 2, 1, 0, 0, 0, 2, 1, 0, 0, 0, 0, 1, 0, 0, 1, 2, 1, 0, 0, 0, 0, 1, 0, 2, 0, 0, 2, 0, 1, 0, 0, 1, 2, 0, 0, 1, 1, 0, 0, 0, 0, 1, 1, 0, 0, 0, 1, 1, 0, 2, 1, 2, 0, 0, 0, 0, 2
Offset: 1

Views

Author

Antti Karttunen, Nov 11 2019

Keywords

Comments

The greedy sum is also the sum with the minimal number of primorials, used for example in the primorial base representation.
Positions of the records (and conjecturally, the positions of the first occurrences of each n) begin as 1, 8, 27, 162, 289, 529, 841, 1369, 1681, 2209, 2809, 3481, 4489, 5041, 5329, 6889, ..., that after 162 all seem to be squares of certain primes. See also A329051.

Examples

			For n = 18 = 2 * 3^2, A108951(18) = A034386(2) * A034386(3)^2 = 2 * 6^2 = 72 = 30 + 30 + 6 + 6, and as the largest primorial in the sum is 30 = A002110(3), and the least primorial is 6 = A002110(2), we have a(18) = 3-2 = 1.
		

Crossrefs

Programs

Formula

a(n) = A243055(A324886(n)).
Showing 1-10 of 20 results. Next