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

A275735 Prime-factorization representations of "factorial base level polynomials": a(0) = 1; for n >= 1, a(n) = 2^A257511(n) * A003961(a(A257684(n))).

Original entry on oeis.org

1, 2, 2, 4, 3, 6, 2, 4, 4, 8, 6, 12, 3, 6, 6, 12, 9, 18, 5, 10, 10, 20, 15, 30, 2, 4, 4, 8, 6, 12, 4, 8, 8, 16, 12, 24, 6, 12, 12, 24, 18, 36, 10, 20, 20, 40, 30, 60, 3, 6, 6, 12, 9, 18, 6, 12, 12, 24, 18, 36, 9, 18, 18, 36, 27, 54, 15, 30, 30, 60, 45, 90, 5, 10, 10, 20, 15, 30, 10, 20, 20, 40, 30, 60, 15, 30, 30, 60, 45, 90, 25, 50, 50, 100, 75
Offset: 0

Views

Author

Antti Karttunen, Aug 09 2016

Keywords

Comments

These are prime-factorization representations of single-variable polynomials where the coefficient of term x^(k-1) (encoded as the exponent of prime(k) in the factorization of n) is equal to the number of times a nonzero digit k occurs in the factorial base representation of n. See the examples.

Examples

			For n = 0 whose factorial base representation (A007623) is also 0, there are no nonzero digits at all, thus there cannot be any prime present in the encoding, and a(0) = 1.
For n = 1 there is just one 1, thus a(1) = prime(1) = 2.
For n = 2 ("10"), there is just one 1-digit, thus a(2) = prime(1) = 2.
For n = 3 ("11") there are two 1-digits, thus a(3) = prime(1)^2 = 4.
For n = 18 ("300") there is just one 3, thus a(18) = prime(3) = 5.
For n = 19 ("301") there is one 1 and one 3, thus a(19) = prime(1)*prime(3) = 2*5 = 10.
For n = 141 ("10311") there are three 1's and one 3, thus a(141) = prime(1)^3 * prime(3) = 2^3 * 5^1 = 40.
		

Crossrefs

Cf. also A275725, A275733, A275734 for other such prime factorization encodings of A060117/A060118-related polynomials, and also A276076.
Differs from A227154 for the first time at n=18, where a(18) = 5, while A227154(18) = 4.

Programs

  • PARI
    A276076(n) = { my(i=0,m=1,f=1,nextf); while((n>0),i=i+1; nextf = (i+1)*f; if((n%nextf),m*=(prime(i)^((n%nextf)/f));n-=(n%nextf));f=nextf); m; };
    A181819(n) = factorback(apply(e->prime(e),(factor(n)[,2])));
    A275735(n) = A181819(A276076(n)); \\ Antti Karttunen, Apr 03 2022
  • Python
    from sympy import prime
    from operator import mul
    import collections
    def a007623(n, p=2): return n if n

Formula

a(0) = 1; for n >= 1, a(n) = 2^A257511(n) * A003961(a(A257684(n))).
Other identities and observations. For all n >= 0:
a(n) = A275734(A225901(n)).
A001221(a(n)) = A275806(n).
A001222(a(n)) = A060130(n).
A048675(a(n)) = A275729(n).
A051903(a(n)) = A264990(n).
A008683(a(A265349(n))) = -1 or +1 for all n >= 0.
A008683(a(A265350(n))) = 0 for all n >= 1.
From Antti Karttunen, Apr 03 2022: (Start)
A342001(a(n)) = A351954(n).
a(n) = A181819(A276076(n)). (End)

A278236 Filter-sequence for factorial base (digit values): least number with the same prime signature as A276076(n).

Original entry on oeis.org

1, 2, 2, 6, 4, 12, 2, 6, 6, 30, 12, 60, 4, 12, 12, 60, 36, 180, 8, 24, 24, 120, 72, 360, 2, 6, 6, 30, 12, 60, 6, 30, 30, 210, 60, 420, 12, 60, 60, 420, 180, 1260, 24, 120, 120, 840, 360, 2520, 4, 12, 12, 60, 36, 180, 12, 60, 60, 420, 180, 1260, 36, 180, 180, 1260, 900, 6300, 72, 360, 360, 2520, 1800, 12600, 8, 24, 24, 120, 72, 360, 24, 120, 120, 840, 360, 2520
Offset: 0

Views

Author

Antti Karttunen, Nov 16 2016

Keywords

Comments

This sequence can be used for filtering certain factorial base related sequences, because it matches only with any such sequence b that can be computed as b(n) = f(A276076(n)), where f(n) is any function that depends only on the prime signature of n (some of these are listed under the index entry for "sequences computed from exponents in ...").
Matching in this context means that the sequence a matches with the sequence b iff for all i, j: a(i) = a(j) => b(i) = b(j). In other words, iff the sequence b partitions the natural numbers to the same or coarser equivalence classes (as/than the sequence a) by the distinct values it obtains.
Any such sequence should match where the result is computed from the nonzero digits (that may also be > 9) in the factorial base representation of n, but does not depend on their order. Some of these are listed on the last line of the Crossrefs section.
Note that as A275735 is present in that list it means that the sequences matching to its filter-sequence A278235 form a subset of the sequences matching to this sequence. Also, for A275735 there is a stronger condition that for any i, j: a(i) = a(j) <=> A275735(i) = A275735(j), which if true, would imply that there is an injective function f such that f(A275735(n)) = A278236(n), and indeed, this function seems to be A181821.

Crossrefs

Similar sequences: A278222 (base-2 related), A069877 (base-10), A278226 (primorial base), A278225, A278234, A278235 (other variants for factorial base),
Differs from A278226 for the first time at n=24, where a(24)=2, while A278226(24)=16.
Sequences that partition N into same or coarser equivalence classes: A275735 (<=>), A034968, A060130, A227153, A227154, A246359, A257079, A257511, A257679, A257694, A257695, A257696, A264990, A275729, A275806, A275948, A275964, A278235.

Programs

  • Mathematica
    a[n_] := Module[{k = n, m = 2, r, s = {}}, While[{k, r} = QuotientRemainder[k, m]; k != 0|| r != 0, AppendTo[s, r]; m++]; s = ReverseSort[s]; Times @@ (Prime[Range[Length[s]]] ^ s)]; Array[a, 100, 0] (* Amiram Eldar, Feb 07 2024 *)
  • Scheme
    (define (A278236 n) (A046523 (A276076 n)))

Formula

a(n) = A046523(A276076(n)).
a(n) = A181821(A275735(n)). [Empirical formula found with the help of equivalence class matching. Not yet proved.]

A208575 Product of digits of n in factorial base.

Original entry on oeis.org

0, 1, 0, 1, 0, 2, 0, 0, 0, 1, 0, 2, 0, 0, 0, 2, 0, 4, 0, 0, 0, 3, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 2, 0, 0, 0, 2, 0, 4, 0, 0, 0, 3, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 4, 0, 0, 0, 4, 0, 8, 0, 0, 0, 6, 0, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 6, 0, 0, 0, 6, 0, 12, 0, 0, 0, 9, 0, 18
Offset: 0

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    (* For the definition of the factorial base version of IntegerDigits, see A007623 *) Table[Times@@factBaseIntDs[n], {n, 0, 99}] (* Alonso del Arte, Feb 28 2012 *)
  • PARI
    a(n)=my(k=1,s=1);while(n,s*=n%k++;n\=k);s
    
  • Python
    from functools import reduce
    from operator import mul
    def A(n, p=2):
        return n if n

A227153 Product of nonzero digits of n in factorial base.

Original entry on oeis.org

1, 1, 1, 1, 2, 2, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 4, 4, 3, 3, 3, 3, 6, 6, 1, 1, 1, 1, 2, 2, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 4, 4, 3, 3, 3, 3, 6, 6, 2, 2, 2, 2, 4, 4, 2, 2, 2, 2, 4, 4, 4, 4, 4, 4, 8, 8, 6, 6, 6, 6, 12, 12, 3, 3, 3, 3, 6, 6, 3, 3, 3, 3, 6, 6, 6, 6, 6, 6
Offset: 0

Views

Author

Antti Karttunen, Jul 04 2013

Keywords

Comments

a(0) = 1 as an empty product always gives 1.

Crossrefs

A227157 gives the positions where equal with A208575.

Programs

  • Mathematica
    a[n_] := Module[{k = n, m = 2, r, p = 1}, While[{k, r} = QuotientRemainder[k, m]; k != 0|| r != 0, If[r > 0, p *= r]; m++]; p]; Array[a, 100, 0] (* Amiram Eldar, Feb 07 2024 *)
  • Python
    from functools import reduce
    from operator import mul
    def A(n, p=2):
        return n if n
  • Python
    def a(n, k=2): return max(n % k, 1) * a(n // k, k + 1) if n else 1 # David Radcliffe, May 22 2025

Formula

For all n, a(A227157(n)) = A208575(A227157(n)).

A317826 Number of partitions of n with carry-free sum in factorial base.

Original entry on oeis.org

1, 1, 1, 2, 2, 4, 1, 2, 2, 5, 4, 11, 2, 4, 4, 11, 9, 26, 3, 7, 7, 21, 16, 52, 1, 2, 2, 5, 4, 11, 2, 5, 5, 15, 11, 36, 4, 11, 11, 36, 26, 92, 7, 21, 21, 74, 52, 198, 2, 4, 4, 11, 9, 26, 4, 11, 11, 36, 26, 92, 9, 26, 26, 92, 66, 249, 16, 52, 52, 198, 137, 560, 3, 7, 7, 21, 16, 52, 7, 21, 21, 74, 52, 198, 16, 52, 52, 198, 137, 560, 31, 109
Offset: 0

Views

Author

Antti Karttunen, Aug 08 2018

Keywords

Comments

"Carry-free sum" in this context means that when the digits of summands (written in factorial base, see A007623) are lined up (right-justified), then summing up of each column will not result in carries to any columns left of that column, that is, the sum of digits of the k-th column from the right (with the rightmost as column 1) over all the summands is the same as the k-th digit of n, thus at most k. Among other things, this implies that in any solution, at most one of the summands may be odd. Moreover, such an odd summand is present if and only if n is odd.
a(n) is the number of set partitions of the multiset that contains d copies of each number k, collected over all k in which digit-positions (the rightmost being k=1) there is a nonzero digit d in true factorial base representation of n, where also digits > 9 are allowed.
Distinct terms are the distinct terms in A050322, that is, A045782. - David A. Corneth & Antti Karttunen, Aug 10 2018

Examples

			  n  in fact.base  a(n) carry-free partitions
------------------------------
  0     "0"         1   {}    (unique empty partition, thus a(0) = 1)
  1     "1"         1   {1}
  2    "10"         1   {2}
  3    "11"         2   {2, 1} and {3}, in fact.base: {"10", "1"} and {"11"}
  4    "20"         2   {2, 2} and {4}, in fact.base: {"10" "10"} and {"20"}
  5    "21"         4   {2, 2, 1}, {3, 2}, {4, 1} and {5},
    in factorial base:  {"10", "10", "1"}, {"11", "10"}, {"20", "1"} and {"21"}.
		

Crossrefs

Cf. A001055, A007623, A025487, A045782 (range of this sequence), A050322, A276076, A278236.
Cf. A317827 (positions of records), A317828 (record values), A317829.
Cf. also A227154, A317836.

Programs

  • PARI
    fcnt(n, m) = {local(s); s=0; if(n == 1, s=1, fordiv(n, d, if(d > 1 & d <= m, s=s+fcnt(n/d, d)))); s};
    A001055(n) = fcnt(n, n); \\ From A001055
    A276076(n) = { my(i=0,m=1,f=1,nextf); while((n>0),i=i+1; nextf = (i+1)*f; if((n%nextf),m*=(prime(i)^((n%nextf)/f));n-=(n%nextf));f=nextf); m; };
    A317826(n) = A001055(A276076(n));
    
  • PARI
    \\ Slightly faster, memoized version:
    memA001055 = Map();
    A001055(n) = {my(v); if(mapisdefined(memA001055,n), v = mapget(memA001055,n), v = fcnt(n, n); mapput(memA001055,n,v); (v));}; \\ Cached version.
    A276076(n) = { my(i=0,m=1,f=1,nextf); while((n>0),i=i+1; nextf = (i+1)*f; if((n%nextf),m*=(prime(i)^((n%nextf)/f));n-=(n%nextf));f=nextf); m; };
    A046523(n) = { my(f=vecsort(factor(n)[, 2], , 4), p); prod(i=1, #f, (p=nextprime(p+1))^f[i]); }; \\ From A046523
    A317826(n) = A001055(A046523(A276076(n)));

Formula

a(n) = A001055(A276076(n)) = A001055(A278236(n)).
a(A000142(n)) = 1.
a(A001563(n)) = A000041(n).
a(A033312(n+1)) = A317829(n) for n >= 1.

A244318 Product of digits+1 of n in Greedy Catalan Base (A014418).

Original entry on oeis.org

1, 2, 2, 4, 3, 2, 4, 4, 8, 6, 3, 6, 6, 12, 2, 4, 4, 8, 6, 4, 8, 8, 16, 12, 6, 12, 12, 24, 3, 6, 6, 12, 9, 6, 12, 12, 24, 18, 9, 18, 18, 36, 2, 4, 4, 8, 6, 4, 8, 8, 16, 12, 6, 12, 12, 24, 4, 8, 8, 16, 12, 8, 16, 16, 32, 24, 12, 24, 24, 48, 6, 12, 12, 24, 18, 12, 24, 24, 48
Offset: 0

Views

Author

Antti Karttunen, Jul 02 2014

Keywords

Crossrefs

A376887 The number of divisors of n that are products of factors of the form p^(k!) with multiplicities not larger than their multiplicity in n, where p is a prime and k >= 1, when the factorization of n is uniquely done using the factorial-base representation of the exponents in the prime factorization of n.

Original entry on oeis.org

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

Views

Author

Amiram Eldar, Oct 08 2024

Keywords

Comments

See A376885 for details about this factorization.
If n = Product p_i^e_i is the canonical prime factorization of n, then the divisors that are counted by this function are d = Product p_i^s_i, where all the digits of s_i in factorial base are not larger than the corresponding digits of e_i.
The sum of these divisors is given by A376888(n).

Examples

			For n = 12 = 2^2 * 3^1, the representation of 2 in factorial base is 10, i.e., 2 = 2!, so 12 = (2^(2!))^1 * (3^(1!))^1 and a(12) = (1+1) * (1+1) = 4, corresponding to the 4 divisors 1, 3, 4 and 12.
		

Crossrefs

Programs

  • Mathematica
    fdigprod[n_] := Module[{k = n, m = 2, r, s = 1}, While[{k, r} = QuotientRemainder[k, m]; k != 0 || r != 0, s *= (r+1); m++]; s]; f[p_, e_] := fdigprod[e]; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100]
  • PARI
    fdigprod(n) = {my(k = n, m = 2, r, s = 1); while([k, r] = divrem(k, m); k != 0 || r != 0, s *= (r+1); m++); s;}
    a(n) = {my(e = factor(n)[, 2]); prod(i = 1, #e, fdigprod(e[i]));}

Formula

Multiplicative with a(p^e) = A227154(e).
Showing 1-7 of 7 results.