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

A324370 Product of all primes p not dividing n such that the sum of the base-p digits of n is at least p, or 1 if no such prime exists.

Original entry on oeis.org

1, 1, 2, 1, 6, 1, 6, 3, 10, 1, 6, 1, 210, 15, 2, 3, 30, 5, 210, 21, 110, 15, 30, 5, 546, 21, 14, 1, 30, 1, 462, 231, 1190, 105, 6, 1, 51870, 1365, 70, 21, 2310, 55, 2310, 105, 322, 105, 210, 35, 6630, 663, 286, 33, 330, 55, 798, 57, 290, 15, 30, 1, 930930, 15015, 1430, 2145, 1122, 85, 82110, 2415, 70, 3, 330, 55, 21111090, 285285
Offset: 1

Views

Author

Keywords

Comments

The product is finite, as the sum of the base-p digits of n is n if p > n.
a(198) = 2465 is the only term below 10^6 that is a Carmichael number (A002997).
It appears that a(n)=1 if and only if n is in A094960. - Robert Israel, Mar 30 2020
It turns out that a(n) equals the denominator of the first derivative of the Bernoulli polynomial B(n,x). So a(n)=1 if and only if n is in A094960, also impyling that n+1 is prime. A324370 is also involved in such formulas regarding higher derivatives. See Kellner 2023. - Bernd C. Kellner, Oct 12 2023

Examples

			For p = 2, 3, and 5, the sum of the base p digits of 7 is 1+1+1 = 3 >= 2, 2+1 = 3 >= 3, and 1+2 = 3 < 5, respectively, so a(7) = 2*3 = 6.
		

Crossrefs

Programs

  • Maple
    N:= 100: # for a(1)..a(N)
    V:= Vector(N,1):
    p:= 1:
    for iter from 1 do
       p:= nextprime(p);
       if p >= N then break fi;
       for n from p+1 to N do
         if n mod p <> 0 and convert(convert(n,base,p),`+`)>= p then
           V[n]:= V[n]*p
         fi
    od od:
    convert(V,list); # Robert Israel, Mar 30 2020
    # Alternatively, note that this formula is suggesting offset 0 and a(0) = 1:
    seq(denom(diff(bernoulli(n, x), x)), n = 1..51); # Peter Luschny, Oct 13 2023
  • Mathematica
    SD[n_, p_] := If[n < 1 || p < 2, 0, Plus @@ IntegerDigits[n, p]];
    DD2[n_] := Times @@ Select[Prime[Range[PrimePi[(n+1)/(2+Mod[n+1, 2])]]], !Divisible[n, #] && SD[n, #] >= # &];
    Table[DD2[n], {n, 1, 100}]
    (* From Bernd C. Kellner, Oct 12 2023 (Start) *)
    (* Denominator of first derivative of BP *)
    k = 1; Table[Denominator[Together[D[BernoulliB[n, x], {x, k}]]], {n, 1, 100}]
    (* End *)
  • Python
    from math import prod
    from sympy.ntheory import digits
    from sympy import primefactors, primerange
    def a(n):
        nonpf = set(primerange(1, n+1)) - set(primefactors(n))
        return prod(p for p in nonpf if sum(digits(n, p)[1:]) >= p)
    print([a(n) for n in range(1, 75)]) # Michael S. Branicky, Jul 03 2022

Formula

a(n) * A324369(n) = A195441(n-1) = denominator(Bernoulli_n(x) - Bernoulli_n).
a(n) * A324369(n) * A324371(n) = A144845(n-1) = denominator(Bernoulli_{n-1}(x)).
a(n+1) = A195441(n)/A324369(n+1) = A144845(n)/A007947(n+1) = A318256(n). Essentially the same as A318256. - Peter Luschny, Mar 05 2019
From Bernd C. Kellner, Oct 12 2023: (Start)
a(n) = denominator(Bernoulli_n(x)').
k-th derivative: let (n)_m be the falling factorial.
For n > k, a(n-k+1)/gcd(a(n-k+1), (n)_{k-1}) = denominator(Bernoulli_n(x)^(k)). Otherwise, the denominator equals 1. (End)

A094960 Positive integers k such that the derivative of the k-th Bernoulli polynomial B(k,x) contains only integer coefficients.

Original entry on oeis.org

1, 2, 4, 6, 10, 12, 28, 30, 36, 60
Offset: 1

Views

Author

Benoit Cloitre, Jun 19 2004

Keywords

Comments

From Max Alekseyev, Dec 08 2011: (Start)
There are no other terms below 10^9.
k belongs to this sequence if k*binomial(k-1,m)*Bernoulli(m) is an integer for each m in 0..k-1. (End)
From Max Alekseyev, Jun 04 2012: (Start)
If for a prime p >= 3, k ends with base-p digits a,b with a+b >= p, then for m = (a+1)*(p-1), the number k*binomial(k-1,m)*Bernoulli(m) is not an integer (it contains p in the denominator). For p=3, this implies that k == 5, 7, or 8 (mod 9) are not in this sequence; for p=5, this implies that k == 9, 13, 14, 17, 18, 19, 21, 22, 23, or 24 (mod 25) are not in this sequence; and so on.
Conjecture: for every integer k > 78, there exists a prime p >= 3 such that the sum of last two base-p digits of k is at least p. This conjecture would imply that this sequence is finite and 60 is the last term. (End)
The conjecture is true for all k such that k+1 is not a prime, a power of 2, or a Giuga number (A007850). In this case, there exists a prime p >= 3 such that the base-p representation of k ends in a,p-1 with a > 0. - Max Alekseyev, Feb 16 2021
The sequence is finite and is a subsequence of A366169. The terms are those numbers k where A324370(k) = 1. It remains to show that 60 is the last term. This is very likely, since the terms depend on the estimation of a product of primes satisfying certain p-adic conditions that is connected with A324370. A proven asymptotic formula related to that product implies that this sequence is finite. See Kellner 2017, 2023, and BLMS 2018. - Bernd C. Kellner, Oct 02 2023

Examples

			B(6,x) = x^6 - 3*x^5 + (5/2)*x^4 - (1/2)*x^2 + 1/42 so B'(6,x) contains only integer coefficients and 6 is in the sequence.
		

Crossrefs

Programs

  • Maple
    p := n -> if denom(diff(bernoulli(n, x), x)) = 1 then n else fi:
    seq(p(n), n=1..100); # Emeric Deutsch
  • Mathematica
    (* From Bernd C. Kellner, Oct 02 2023. (Start) *)
    (* k-th derivative of BP: *)
    k = 1; Select[Range[1000], Denominator[Together[D[BernoulliB[#, x],{x, k}]]] == 1&]
    (* Exact denominator formula: *)
    SD[n_, p_] := If[n < 1 || p < 2, 0, Plus@@IntegerDigits[n, p]];
    DBP[n_, k_] := Module[{m = n-k+1, fac = FactorialPower[n, k]}, If[n < 1 || k < 1 || n <= k, Return[1]]; Times@@Select[Prime[Range[PrimePi[(m+1)/(2 + Mod[m+1, 2])]]], !Divisible[fac, #] && SD[m, #] >= #&]];
    k = 1; Select[Range[1000], DBP[#, k] == 1&]
    (* End *)
  • PARI
    is_A094960(k) = !#select(x->(denominator(x)!=1), Vec(deriv(bernpol(k)))); \\ Michel Marcus, Feb 15 2021
    
  • Python
    from itertools import count, islice
    from sympy import Poly, diff, bernoulli
    from sympy.abc import x
    def A094960_gen(): # generator of terms
        return filter(lambda k:k<=1 or all(c.is_integer for c in Poly(diff(bernoulli(k,x),x)).coeffs()),count(1))
    A094960_list = list(islice(A094960_gen(),10)) # Chai Wah Wu, Oct 03 2023

Formula

k is a term if A324370(k) = 1. - Bernd C. Kellner, Oct 02 2023
k is a term <=> 0 = Sum_{j=0..k-1} k*binomial(k - 1, j) mod Clausen(j), where Clausen(n) = A160014(n, 1). - Peter Luschny, Oct 04 2023

A366169 Positive integers k such that the second derivative of the k-th Bernoulli polynomial B(k,x) contains only integer coefficients.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 9, 10, 11, 12, 13, 15, 16, 21, 25, 28, 29, 30, 31, 36, 37, 55, 57, 60, 61, 70, 121, 190
Offset: 1

Views

Author

Bernd C. Kellner, Oct 02 2023

Keywords

Comments

The sequence is finite and is a supersequence of A094960. The terms are those numbers k where the denominator A366168(k) = 1. It remains to show that 190 is the last term. This is very likely, since the terms depend on the estimation of a product of primes satisfying certain p-adic conditions that is connected with A324370. A proven asymptotic formula related to that product implies that this sequence is finite. See Kellner 2017, 2023, and BLMS 2018.

Examples

			B(5,x) = x^5 - (5x^4)/2 + (5 x^3)/3 - x/6 and B''(5,x) = 20x^3 - 30x^2 + 10x, so 5 is a term.
		

Crossrefs

Programs

  • Maple
    aList := len -> select(n -> denom(diff(diff(bernoulli(n, x), x), x)) = 1, [seq(1..len)]): aList(200);  # Peter Luschny, Oct 03 2023
  • Mathematica
    (* k-th derivative of BP *)
    k = 2; Select[Range[1000], Denominator[Together[D[BernoulliB[#, x],{x, k}]]] == 1&]
    (* exact denominator formula *)
    SD[n_, p_] := If[n < 1 || p < 2, 0, Plus@@IntegerDigits[n, p]];
    DBP[n_, k_] := Module[{m = n-k+1, fac = FactorialPower[n, k]}, If[n < 1 || k < 1 || n <= k, Return[1]]; Times@@Select[Prime[Range[PrimePi[(m+1)/(2 + Mod[m+1, 2])]]], !Divisible[fac, #] && SD[m, #] >= #&]];
    k = 2; Select[Range[1000], DBP[#, k] == 1&]
  • PARI
    isok(k) = #select(x->denominator(x)>1, Vec(deriv(deriv(bernpol(k))))) == 0; \\ Michel Marcus, Oct 03 2023
    
  • Python
    from itertools import count, islice
    from sympy import Poly, diff, bernoulli
    from sympy.abc import x
    def A366169_gen(): # generator of terms
        return filter(lambda k:k<=2 or all(c.is_integer for c in Poly(diff(bernoulli(k,x),x,2)).coeffs()),count(1))
    A366169_list = list(islice(A366169_gen(),20)) # Chai Wah Wu, Oct 03 2023

Formula

k is a term if A366168(k) = 1.

A366426 a(n) = numerator(denominator(Bernoulli''(n, x)) / denominator(Bernoulli(n, 1))).

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 5, 1, 1, 3, 5, 5, 7, 1, 5, 15, 1, 1, 7, 7, 1, 1, 1, 1, 77, 7, 35, 3, 1, 1, 455, 35, 7, 21, 55, 55, 7, 7, 7, 105, 1, 5, 221, 13, 11, 33, 55, 1, 19, 1, 5, 15, 1, 1, 5005, 715, 143, 33, 17, 85, 161, 35, 1, 3, 11, 55, 95095
Offset: 0

Views

Author

Peter Luschny, Oct 13 2023

Keywords

Crossrefs

Cf. A366168/A027642, A366427 (denominator), A366570/A366152 (1st derivative).

Programs

  • Maple
    seq(numer(denom(diff(diff(bernoulli(n, x), x),x))/denom(bernoulli(n, 1))), n = 0..75);
  • PARI
    a(n) = numerator(lcm(apply(denominator, Vec(deriv(deriv(bernpol(n))))))/denominator(subst(bernpol(n, x), x, 1))); \\ Michel Marcus, Oct 14 2023

Formula

a(n) = numerator(A366168(n) / A027642(n)).

A366427 a(n) = denominator(denominator(Bernoulli''(n, x)) / denominator(Bernoulli(n, 1))).

Original entry on oeis.org

1, 2, 6, 1, 30, 1, 42, 1, 10, 1, 66, 1, 2730, 1, 2, 1, 510, 1, 798, 1, 110, 1, 138, 1, 546, 1, 2, 1, 870, 1, 14322, 1, 170, 1, 6, 1, 1919190, 1, 2, 1, 13530, 1, 1806, 1, 46, 1, 282, 1, 1326, 1, 22, 1, 1590, 1, 798, 1, 290, 1, 354, 1, 56786730, 1, 2, 1, 102, 1
Offset: 0

Views

Author

Peter Luschny, Oct 13 2023

Keywords

Crossrefs

Cf. A366168/A027642, A366426 (numerator), A366570/A366152 (1st derivative).

Programs

  • Maple
    seq(denom(denom(diff(diff(bernoulli(n, x), x),x))/denom(bernoulli(n, 1))), n = 0..65);
  • PARI
    a(n) = denominator(lcm(apply(denominator, Vec(deriv(deriv(bernpol(n))))))/denominator(subst(bernpol(n, x), x, 1))); \\ Michel Marcus, Oct 14 2023

Formula

a(n) = denominator(A366168(n) / A027642(n)).

A366572 a(n) = denominator(Bernoulli(n, x)) / denominator(Bernoulli''(n, x)).

Original entry on oeis.org

1, 2, 6, 2, 30, 6, 42, 6, 10, 10, 66, 6, 2730, 210, 2, 6, 510, 10, 798, 42, 110, 330, 138, 2, 546, 546, 2, 2, 870, 30, 14322, 462, 170, 510, 6, 2, 1919190, 51870, 2, 6, 13530, 110, 1806, 42, 46, 690, 1410, 2, 1326, 1326, 22, 66, 1590, 10, 798, 798, 290, 870
Offset: 0

Views

Author

Peter Luschny, Oct 13 2023

Keywords

Crossrefs

Cf. A144845/A366168, A366571, A144845/A324370 (1st derivative).

Programs

  • Maple
    seq(denom(bernoulli(n, x))/denom(diff(diff(bernoulli(n, x), x),x)), n=0..100);
  • PARI
    a(n) = lcm(apply(denominator, Vec(bernpol(n))))/lcm(apply(denominator, Vec(deriv(deriv(bernpol(n)))))); \\ Michel Marcus, Oct 14 2023

Formula

a(n) = A144845(n) / A366168(n).

A366571 a(n) = denominator(Bernoulli(n, x)) / denominator(Bernoulli'(n, x)).

Original entry on oeis.org

1, 2, 6, 1, 30, 1, 42, 1, 10, 1, 66, 1, 2730, 1, 2, 3, 170, 1, 798, 1, 110, 3, 46, 1, 546, 1, 2, 1, 870, 1, 14322, 1, 170, 3, 2, 1, 1919190, 1, 2, 3, 4510, 1, 1806, 1, 46, 15, 94, 1, 1326, 1, 22, 3, 530, 1, 798, 1, 290, 3, 118, 1, 56786730, 1, 2, 3, 34, 5, 64722
Offset: 0

Views

Author

Peter Luschny, Oct 13 2023

Keywords

Crossrefs

Cf. A144845/A324370, A366572, A144845/A366168 (2nd derivative).

Programs

  • Maple
    seq(denom(bernoulli(n, x))/denom(diff(bernoulli(n, x), x)), n = 0..66);
  • PARI
    a(n) = lcm(apply(denominator, Vec(bernpol(n))))/lcm(apply(denominator, Vec(deriv(bernpol(n))))); \\ Michel Marcus, Oct 14 2023

Formula

a(n) = A144845(n) / A324370(n).

A366573 a(n) = denominator(Bernoulli'(n, x)) / denominator(Bernoulli''(n, x)).

Original entry on oeis.org

1, 1, 1, 2, 1, 6, 1, 6, 1, 10, 1, 6, 1, 210, 1, 2, 3, 10, 1, 42, 1, 110, 3, 2, 1, 546, 1, 2, 1, 30, 1, 462, 1, 170, 3, 2, 1, 51870, 1, 2, 3, 110, 1, 42, 1, 46, 15, 2, 1, 1326, 1, 22, 3, 10, 1, 798, 1, 290, 3, 2, 1, 930930, 1, 2, 3, 34, 5, 966, 1, 2, 3, 110, 1
Offset: 0

Views

Author

Peter Luschny, Oct 13 2023

Keywords

Crossrefs

Programs

  • Maple
    seq(denom(diff(bernoulli(n, x), x))/denom(diff(diff(bernoulli(n, x), x),x)), n = 0..100);
  • PARI
    a(n) = lcm(apply(denominator, Vec(deriv(bernpol(n)))))/ lcm(apply(denominator, Vec(deriv(deriv(bernpol(n)))))); \\ Michel Marcus, Oct 14 2023

Formula

a(n) = A324370(n) / A366168(n).
Showing 1-8 of 8 results.