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

A213615 Triangle read by rows, coefficients of the Bernoulli polynomials B_{n}(x) times A144845(n) in descending order of powers.

Original entry on oeis.org

1, 2, -1, 6, -6, 1, 2, -3, 1, 0, 30, -60, 30, 0, -1, 6, -15, 10, 0, -1, 0, 42, -126, 105, 0, -21, 0, 1, 6, -21, 21, 0, -7, 0, 1, 0, 30, -120, 140, 0, -70, 0, 20, 0, -1, 10, -45, 60, 0, -42, 0, 20, 0, -3, 0, 66, -330, 495, 0, -462, 0, 330, 0, -99, 0, 5, 6, -33
Offset: 0

Views

Author

Peter Luschny, Jun 16 2012

Keywords

Examples

			b(0,x) =  1
b(1,x) =  2*x    -  1
b(2,x) =  6*x^2  -  6*x    + 1
b(3,x) =  2*x^3  -  3*x^2  + x
b(4,x) = 30*x^4  - 60*x^3  + 30*x^2  - 1
b(5,x) =  6*x^5  - 15*x^4  + 10*x^3  - x
		

Crossrefs

Programs

  • Maple
    seq(seq(coeff(denom(bernoulli(i,x))*bernoulli(i,x),x,i-j),j=0..i),i=0..12);
  • Mathematica
    Flatten[Table[p = Reverse[CoefficientList[BernoulliB[n, x], x]]; (LCM @@ Denominator[p])*p, {n, 0, 10}]] (* T. D. Noe, Nov 07 2012 *)

Formula

T(n,k) = A144845(n)*[x^(n-k)]B{n}(x).

A213616 Triangle read by rows, coefficients of the Bernoulli nabla polynomials BN_{n}(x) times A144845(n) in descending order of powers.

Original entry on oeis.org

1, 2, -3, 6, -18, 13, 2, -9, 13, -6, 30, -180, 390, -360, 119, 6, -45, 130, -180, 119, -30, 42, -378, 1365, -2520, 2499, -1260, 253, 6, -63, 273, -630, 833, -630, 253, -42, 30, -360, 1820, -5040, 8330, -8400, 5060, -1680, 239, 10, -135, 780, -2520, 4998, -6300
Offset: 0

Views

Author

Peter Luschny, Jun 16 2012

Keywords

Comments

The polynomials BN_{n}(x) have the e.g.f. t*exp(t*(x-1))/(exp(t)-1). The adjunct 'nabla' in the name refers to the backward difference operation.
BN_{n}(1) are the Bernoulli numbers.
In the difference table of the Bernoulli polynomials the polynomials BN_{n}(x) appear as the top row (see the link).

Examples

			bn(0,x) =  1,
bn(1,x) =  2*x   -   3,
bn(2,x) =  6*x^2 -  18*x   +  13,
bn(3,x) =  2*x^3 -   9*x^2 +  13*x   -   6,
bn(4,x) = 30*x^4 - 180*x^3 + 390*x^2 - 360*x   + 119,
bn(5,x) =  6*x^5 -  45*x^4 + 130*x^3 - 180*x^2 + 119*x - 30.
		

Crossrefs

Programs

  • Maple
    seq(seq(coeff(denom(bernoulli(i, x))*bernoulli(i, x - 1), x, i - j), j=0..i), i=0..12);
  • Mathematica
    Table[If[i == 0, 1, 1/First[ FactorTerms[ BernoulliB[i, x]]]]*Table[ Coefficient[ Denominator[ BernoulliB[i, x]]*BernoulliB[i, x-1], x, i-j], {j, 0, i}], {i, 0, 12}] // Flatten (* Jean-François Alcover, Sep 27 2013, after Maple *)

Formula

T(n,k) = A144845(n)*[x^(n-k)]BN{n}(x).

A213621 The denominator of the Bernoulli polynomial B(n,x) divided by the Clausen number C(n), A144845(n)/A141056(n).

Original entry on oeis.org

1, 1, 1, 1, 1, 3, 1, 3, 1, 5, 1, 3, 1, 105, 5, 3, 1, 15, 5, 105, 7, 165, 5, 15, 1, 273, 7, 7, 1, 15, 1, 231, 77, 1785, 35, 3, 1, 25935, 455, 105, 7, 1155, 55, 1155, 7, 2415, 35, 105, 1, 3315, 221, 429, 11, 165, 55, 399, 19, 435, 5, 15, 1, 465465, 5005, 2145
Offset: 0

Views

Author

Peter Luschny, Jun 16 2012

Keywords

Crossrefs

Cf. A213623.

Programs

  • Maple
    # Clausen(n,k) defined in A160014.
    seq(denom(bernoulli(i,x))/Clausen(i,1), i=0..63);
  • Mathematica
    c[0, ] = 1; c[n, k_] := Times @@ (Select[Divisors[n], PrimeQ[#+k]&] + k);
    Table[Denominator[BernoulliB[i, x] // Together]/c[i, 1], {i, 0, 63}] (* Jean-François Alcover, Aug 02 2019 *)

A213623 Numbers n such that the denominator of the Bernoulli polynomial B(n,x) equals the Clausen number C(n), {n | A144845(n) = A141056(n)}.

Original entry on oeis.org

0, 1, 2, 3, 4, 6, 8, 10, 12, 16, 24, 28, 30, 36, 48, 60, 120
Offset: 0

Views

Author

Peter Luschny, Jun 16 2012

Keywords

Comments

Is this a finite sequence?

Crossrefs

Programs

  • Maple
    # Clausen(n, k) defined in A160014.
    seq(`if`(denom(bernoulli(i,x))=Clausen(i,1),i,NULL), i=0..120);
  • Mathematica
    Clausen[n_, k_] := If[n == 0, 1, Times @@ (Select[Divisors[n], PrimeQ[# + k]&] + k)];
    Select[Range[0, 120], Denominator[BernoulliB[#, x] // Together] == Clausen[#, 1]&] (* Jean-François Alcover, Aug 13 2019 *)

A218853 Triangle read by rows, coefficients of the Bernoulli polynomials B_{n}(x) times A144845(n) in increasing powers.

Original entry on oeis.org

1, -1, 2, 1, -6, 6, 0, 1, -3, 2, -1, 0, 30, -60, 30, 0, -1, 0, 10, -15, 6, 1, 0, -21, 0, 105, -126, 42, 0, 1, 0, -7, 0, 21, -21, 6, -1, 0, 20, 0, -70, 0, 140, -120, 30, 0, -3, 0, 20, 0, -42, 0, 60, -45, 10, 5, 0, -99, 0, 330, 0, -462, 0, 495, -330, 66, 0, 5, 0
Offset: 0

Views

Author

T. D. Noe, Nov 07 2012

Keywords

Comments

See A213615 for the polynomials in decreasing powers.

Crossrefs

Cf. A213615.

Programs

  • Maple
    A218853_row := n -> seq(coeff(numer(bernoulli(n,x)),x,j),j=0..n):
    seq(A218853_row(n), n = 0..10); # Peter Luschny, Nov 22 2015
  • Mathematica
    Flatten[Table[ p = CoefficientList[BernoulliB[n, x], x]; (LCM @@ Denominator[p])*p, {n, 0, 10}]]

A006519 Highest power of 2 dividing n.

Original entry on oeis.org

1, 2, 1, 4, 1, 2, 1, 8, 1, 2, 1, 4, 1, 2, 1, 16, 1, 2, 1, 4, 1, 2, 1, 8, 1, 2, 1, 4, 1, 2, 1, 32, 1, 2, 1, 4, 1, 2, 1, 8, 1, 2, 1, 4, 1, 2, 1, 16, 1, 2, 1, 4, 1, 2, 1, 8, 1, 2, 1, 4, 1, 2, 1, 64, 1, 2, 1, 4, 1, 2, 1, 8, 1, 2, 1, 4, 1, 2, 1, 16, 1, 2, 1, 4, 1, 2, 1, 8, 1, 2, 1, 4, 1, 2, 1, 32, 1, 2, 1, 4, 1, 2
Offset: 1

Views

Author

Keywords

Comments

Least positive k such that m^k + 1 divides m^n + 1 (with fixed base m). - Vladimir Baltic, Mar 25 2002
To construct the sequence: start with 1, concatenate 1, 1 and double last term gives 1, 2. Concatenate those 2 terms, 1, 2, 1, 2 and double last term 1, 2, 1, 2 -> 1, 2, 1, 4. Concatenate those 4 terms: 1, 2, 1, 4, 1, 2, 1, 4 and double last term -> 1, 2, 1, 4, 1, 2, 1, 8, etc. - Benoit Cloitre, Dec 17 2002
a(n) = gcd(seq(binomial(2*n, 2*m+1)/2, m = 0 .. n - 1)) (odd numbered entries of even numbered rows of Pascal's triangle A007318 divided by 2), where gcd() denotes the greatest common divisor of a set of numbers. Due to the symmetry of the rows it suffices to consider m = 0 .. floor((n-1)/2). - Wolfdieter Lang, Jan 23 2004
Equals the continued fraction expansion of a constant x (cf. A100338) such that the continued fraction expansion of 2*x interleaves this sequence with 2's: contfrac(2*x) = [2; 1, 2, 2, 2, 1, 2, 4, 2, 1, 2, 2, 2, 1, 2, 8, 2, ...].
Simon Plouffe observes that this sequence and A003484 (Radon function) are very similar, the difference being all zeros except for every 16th term (see A101119 for nonzero differences). Dec 02 2004
This sequence arises when calculating the next odd number in a Collatz sequence: Next(x) = (3*x + 1) / A006519, or simply (3*x + 1) / BitAnd(3*x + 1, -3*x - 1). - Jim Caprioli, Feb 04 2005
a(n) = n if and only if n = 2^k. This sequence can be obtained by taking a(2^n) = 2^n in place of a(2^n) = n and using the same sequence building approach as in A001511. - Amarnath Murthy, Jul 08 2005
Also smallest m such that m + n - 1 = m XOR (n - 1); A086799(n) = a(n) + n - 1. - Reinhard Zumkeller, Feb 02 2007
Number of 1's between successive 0's in A159689. - Philippe Deléham, Apr 22 2009
Least number k such that all coefficients of k*E(n, x), the n-th Euler polynomial, are integers (cf. A144845). - Peter Luschny, Nov 13 2009
In the binary expansion of n, delete everything left of the rightmost 1 bit. - Ralf Stephan, Aug 22 2013
The equivalent sequence for partitions is A194446. - Omar E. Pol, Aug 22 2013
Also the 2-adic value of 1/n, n >= 1. See the Mahler reference, definition on p. 7. This is a non-archimedean valuation. See Mahler, p. 10. Sometimes called 2-adic absolute value of 1/n. - Wolfdieter Lang, Jun 28 2014
First 2^(k-1) - 1 terms are also the heights of the successive rectangles and squares of width 2 that are adjacent to any of the four sides of the toothpick structure of A139250 after 2^k stages, with k >= 2. For example: if k = 5 the heights after 32 stages are [1, 2, 1, 4, 1, 2, 1, 8, 1, 2, 1, 4, 1, 2, 1] respectively, the same as the first 15 terms of this sequence. - Omar E. Pol, Dec 29 2020

Examples

			2^3 divides 24, but 2^4 does not divide 24, so a(24) = 8.
2^0 divides 25, but 2^1 does not divide 25, so a(25) = 1.
2^1 divides 26, but 2^2 does not divide 26, so a(26) = 2.
Per _Marc LeBrun_'s 2000 comment, a(n) can also be determined with bitwise operations in two's complement. For example, given n = 48, we see that n in binary in an 8-bit byte is 00110000 while -n is 11010000. Then 00110000 AND 11010000 = 00010000, which is 16 in decimal, and therefore a(48) = 16.
G.f. = x + 2*x^2 + x^3 + 4*x^4 + x^5 + 2*x^6 + x^7 + 8*x^8 + x^9 + ...
		

References

  • Kurt Mahler, p-adic numbers and their functions, second ed., Cambridge University Press, 1981.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Partial sums are in A006520, second partial sums in A022560.
Sequences used in definitions of this sequence: A000079, A001511, A004198, A007814.
Sequences with related definitions: A038712, A171977, A135481 (GS(1, 6)).
This is Guy Steele's sequence GS(5, 2) (see A135416).
Related to A007913 via A225546.
A059897 is used to express relationship between sequence terms.
Cf. A091476 (Dgf at s=2).

Programs

  • Haskell
    import Data.Bits ((.&.))
    a006519 n = n .&. (-n) :: Integer
    -- Reinhard Zumkeller, Mar 11 2012, Dec 29 2011
    
  • Julia
    using IntegerSequences
    [EvenPart(n) for n in 1:102] |> println  # Peter Luschny, Sep 25 2021
    
  • Magma
    [2^Valuation(n, 2): n in [1..100]]; // Vincenzo Librandi, Mar 27 2015
    
  • Maple
    with(numtheory): for n from 1 to 200 do if n mod 2 = 1 then printf(`%d,`,1) else printf(`%d,`,2^ifactors(n)[2][1][2]) fi; od:
    A006519 := proc(n) if type(n,'odd') then 1 ; else for f in ifactors(n)[2] do if op(1,f) = 2 then return 2^op(2,f) ; end if; end do: end if; end proc: # R. J. Mathar, Oct 25 2010
    A006519 := n -> 2^padic[ordp](n,2): # Peter Luschny, Nov 26 2010
  • Mathematica
    lowestOneBit[n_] := Block[{k = 0}, While[Mod[n, 2^k] == 0, k++]; 2^(k - 1)]; Table[lowestOneBit[n], {n, 102}] (* Robert G. Wilson v Nov 17 2004 *)
    Table[2^IntegerExponent[n, 2], {n, 128}] (* Jean-François Alcover, Feb 10 2012 *)
    Table[BitAnd[BitNot[i - 1], i], {i, 1, 102}] (* Peter Luschny, Oct 10 2019 *)
  • PARI
    {a(n) = 2^valuation(n, 2)};
    
  • PARI
    a(n)=1<Joerg Arndt, Jun 10 2011
    
  • PARI
    a(n)=bitand(n,-n); \\ Joerg Arndt, Jun 10 2011
    
  • PARI
    a(n)=direuler(p=2,n,if(p==2,1/(1-2*X),1/(1-X)))[n] \\ Ralf Stephan, Mar 27 2015
    
  • Python
    def A006519(n): return n&-n # Chai Wah Wu, Jul 06 2022
  • Scala
    (1 to 128).map(Integer.lowestOneBit()) // _Alonso del Arte, Mar 04 2020
    

Formula

a(n) = n AND -n (where "AND" is bitwise, and negative numbers are represented in two's complement in a suitable bit width). - Marc LeBrun, Sep 25 2000, clarified by Alonso del Arte, Mar 16 2020
Also: a(n) = gcd(2^n, n). - Labos Elemer, Apr 22 2003
Multiplicative with a(p^e) = p^e if p = 2; 1 if p > 2. - David W. Wilson, Aug 01 2001
G.f.: Sum_{k>=0} 2^k*x^2^k/(1 - x^2^(k+1)). - Ralf Stephan, May 06 2003
Dirichlet g.f.: zeta(s)*(2^s - 1)/(2^s - 2) = zeta(s)*(1 - 2^(-s))/(1 - 2*2^(-s)). - Ralf Stephan, Jun 17 2007
a(n) = 2^floor(A002487(n - 1) / A002487(n)). - Reikku Kulon, Oct 05 2008
a(n) = 2^A007814(n). - R. J. Mathar, Oct 25 2010
a((2*k - 1)*2^e) = 2^e, k >= 1, e >= 0. - Johannes W. Meijer, Jun 07 2011
a(n) = denominator of Euler(n-1, 1). - Arkadiusz Wesolowski, Jul 12 2012
a(n) = A011782(A001511(n)). - Omar E. Pol, Sep 13 2013
a(n) = (n XOR floor(n/2)) XOR (n-1 XOR floor((n-1)/2)) = n - (n AND n-1) (where "AND" is bitwise). - Gary Detlefs, Jun 12 2014
a(n) = ((n XOR n-1)+1)/2. - Gary Detlefs, Jul 02 2014
a(n) = A171977(n)/2. - Peter Kern, Jan 04 2017
a(n) = 2^(A001511(n)-1). - Doug Bell, Jun 02 2017
a(n) = abs(A003188(n-1) - A003188(n)). - Doug Bell, Jun 02 2017
Conjecture: a(n) = (1/(A000203(2*n)/A000203(n)-2)+1)/2. - Velin Yanev, Jun 30 2017
a(n) = (n-1) o n where 'o' is the bitwise converse nonimplication. 'o' is not commutative. n o (n+1) = A135481(n). - Peter Luschny, Oct 10 2019
From Peter Munn, Dec 13 2019: (Start)
a(A225546(n)) = A225546(A007913(n)).
a(A059897(n,k)) = A059897(a(n), a(k)). (End)
Sum_{k=1..n} a(k) ~ (1/(2*log(2)))*n*log(n) + (3/4 + (gamma-1)/(2*log(2)))*n, where gamma is Euler's constant (A001620). - Amiram Eldar, Nov 15 2022
a(n) = n / A000265(n). - Amiram Eldar, May 22 2025

Extensions

More terms from James Sellers, Jun 20 2000

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)

A195441 a(n) = denominator(Bernoulli_{n+1}(x) - Bernoulli_{n+1}).

Original entry on oeis.org

1, 1, 2, 1, 6, 2, 6, 3, 10, 2, 6, 2, 210, 30, 6, 3, 30, 10, 210, 42, 330, 30, 30, 30, 546, 42, 14, 2, 30, 2, 462, 231, 3570, 210, 6, 2, 51870, 2730, 210, 42, 2310, 330, 2310, 210, 4830, 210, 210, 210, 6630, 1326, 858, 66, 330, 110, 798, 114, 870, 30, 30, 6
Offset: 0

Views

Author

Peter Luschny, Sep 18 2011

Keywords

Comments

If s(n) is the smallest number such that s(n)*(1^n + 2^n + ... + x^n) is a polynomial in x with integer coefficients then a(n)=s(n)/(n+1) (see A064538).
a(n) is squarefree, by the von Staudt-Clausen theorem on the denominators of Bernoulli numbers. - Kieren MacMillan and Jonathan Sondow, Nov 20 2015
Kellner and Sondow give a detailed analysis of this sequence and provide a simple way to compute the terms without using Bernoulli polynomials and numbers. They prove that a(n) is the product of the primes less than or equal to (n+2)/(2+(n mod 2)) such that the sum of digits of n+1 in base p is at least p. - Peter Luschny, May 14 2017
The equation a(n-1) = denominator(Bernoulli_n(x) - Bernoulli_n) = rad(n+1) has only finitely many solutions, where rad(n) = A007947(n) is the radical of n. It is conjectured that S = {3, 5, 8, 9, 11, 27, 29, 35, 59} is the full set of all such solutions. Note that (S\{8})+1 joined with {1,2} equals A094960. More precisely, the set S implies the finite sequence of A094960. See Kellner 2023. - Bernd C. Kellner, Oct 18 2023
As was observed in the example section of A318256: denominator(B_n(x)) = rad(n+1) if n is in {0, 1, 3, 5, 9, 11, 27, 29, 35, 59} = {A094960(n) - 1: 1 <= n <= 10}. - Peter Luschny, Oct 18 2023

Crossrefs

Programs

  • Julia
    using Nemo, Primes
    function A195441(n::Int)
        n < 4 && return ZZ([1,1,2,1][n+1])
        P = primes(2, div(n+2, 2+n%2))
        prod([ZZ(p) for p in P if p <= sum(digits(n+1, base=p))])
    end
    println([A195441(n) for n in 0:59]) # Peter Luschny, May 14 2017
    
  • Maple
    A195441 := n -> denom(bernoulli(n+1, x)-bernoulli(n+1)):
    seq(A195441(i),i=0..59);
    # Formula of Kellner and Sondow:
    a := proc(n) local s; s := (p,n) -> add(i,i=convert(n,base,p));
    select(isprime,[$2..(n+2)/(2+irem(n,2))]); mul(i,i=select(p->s(p,n+1)>=p,%)) end: seq(a(n), n=0..59); # Peter Luschny, May 14 2017
  • Mathematica
    a[n_] := Denominator[Together[(BernoulliB[n + 1, x] - BernoulliB[n + 1])]]; Table[a[n], {n, 0, 59}] (* Jonathan Sondow, Nov 20 2015 *)
    SD[n_, p_] := If[n < 1 || p < 2, 0, Plus @@ IntegerDigits[n, p]]; DD[n_] := Times @@ Select[Prime[Range[PrimePi[(n+2)/(2+Mod[n, 2])]]], SD[n+1, #] >= # &]; Table[DD[n], {n, 0, 59}] (* Bernd C. Kellner, Oct 18 2023 *)
  • PARI
    a(n) = {my(vp = Vec(bernpol(n+1, x)-bernfrac(n+1))); lcm(vector(#vp, k, denominator(vp[k])));} \\ Michel Marcus, Feb 08 2016
    
  • Python
    from math import prod
    from sympy.ntheory.factor_ import primerange, digits
    def A195441(n): return prod(p for p in primerange((n+2)//(2|n&1)+1) if sum(digits(n+1,p)[1:])>=p) # Chai Wah Wu, Oct 04 2023
  • Sage
    A195441 = lambda n: mul([p for p in (2..(n+2)//(2+n%2)) if is_prime(p) and sum((n+1).digits(base=p))>=p])
    print([A195441(n) for n in (0..59)]) # Peter Luschny, May 14 2017
    

Formula

a(n) = A064538(n)/(n+1). - Jonathan Sondow, Nov 12 2015
A001221(a(n)) = A001222(a(n)). - Kieren MacMillan and Jonathan Sondow, Nov 20 2015
a(2*n)/a(2*n+1) = A286516(n+1). - Bernd C. Kellner and Jonathan Sondow, May 24 2017
a(n) = A007947(A338025(n+1)). - Harald Hofstätter, Oct 10 2020
From Bernd C. Kellner, Oct 18 2023: (Start)
Note that the formulas here are shifted in index by 1 due to the definition of a(n) using index n+1!
a(n) = A324369(n+1) * A324370(n+1).
a(n) = A144845(n) / A324371(n+1).
a(n-1) = lcm(a(n), rad(n+1)), if n >= 3 is odd.
If n+1 is composite, then rad(n+1) divides a(n-1).
If m is a Carmichael number (A002997), then m divides both a(m-1) and a(m-2).
See papers of Kellner and Kellner & Sondow. (End)

Extensions

Definition simplified by Jonathan Sondow, Nov 20 2015

A053383 Triangle T(n,k) giving denominator of coefficient of x^(n-k) in Bernoulli polynomial B(n, x), n >= 0, 0 <= k <= n.

Original entry on oeis.org

1, 1, 2, 1, 1, 6, 1, 2, 2, 1, 1, 1, 1, 1, 30, 1, 2, 3, 1, 6, 1, 1, 1, 2, 1, 2, 1, 42, 1, 2, 2, 1, 6, 1, 6, 1, 1, 1, 3, 1, 3, 1, 3, 1, 30, 1, 2, 1, 1, 5, 1, 1, 1, 10, 1, 1, 1, 2, 1, 1, 1, 1, 1, 2, 1, 66, 1, 2, 6, 1, 1, 1, 1, 1, 2, 1, 6, 1, 1, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2730, 1, 2, 1, 1, 6, 1, 7, 1, 10, 1, 3, 1, 210, 1
Offset: 0

Views

Author

N. J. A. Sloane, Jan 06 2000

Keywords

Examples

			The polynomials B(0,x), B(1,x), B(2,x), ... are 1; x - 1/2; x^2 - x + 1/6; x^3 - (3/2)*x^2 + (1/2)*x; x^4 - 2*x^3 + x^2 - 1/30; x^5 - (5/2)*x^4 + (5/3)*x^3 - (1/6)*x; x^6 - 3*x^5 + (5/2)*x^4 - (1/2)*x^2 + 1/42; ...
Triangle A053382/A053383 begins:
  1;
  1, -1/2;
  1,  -1,  1/6;
  1, -3/2, 1/2, 0;
  1,  -2,   1,  0, -1/30;
  1, -5/2, 5/3, 0, -1/6, 0;
  1,  -3,  5/2, 0, -1/2, 0, 1/42;
  ...
Triangle A196838/A196839 begins (this is the reflected version):
    1;
  -1/2,   1;
   1/6,  -1,    1;
    0,   1/2, -3/2,  1;
  -1/30,  0,    1,  -2,    1;
    0,  -1/6,   0,  5/3, -5/2,  1;
   1/42,  0,  -1/2,  0,   5/2, -3, 1;
  ...
		

References

  • M. Abramowitz and I. A. Stegun, eds., Handbook of Mathematical Functions, National Bureau of Standards Applied Math. Series 55, 1964 (and various reprintings), p. 809.
  • L. Comtet, Advanced Combinatorics, Reidel, 1974, p. 48, [14a].
  • M. Kauers and P. Paule, The Concrete Tetrahedron, Springer 2011, p. 53.
  • H. Rademacher, Topics in Analytic Number Theory, Springer, 1973, Chap. 1.
  • Jerome Spanier and Keith B. Oldham, "Atlas of Functions", Hemisphere Publishing Corp., 1987, chapter 19, equations 19:4:1 - 19:4:8 at page 169.

Crossrefs

Three versions of coefficients of Bernoulli polynomials: A053382/A053383; for reflected version see A196838/A196839; see also A048998 and A048999.
Cf. A144845 (lcm of row n).

Programs

  • Maple
    with(ListTools): with(PolynomialTools):
    CoeffList := p -> Reverse(CoefficientList(p, x)):
    Trow := n -> denom(CoeffList(bernoulli(n, x))):
    Flatten([seq(Trow(n), n = 0..13)]); # Peter Luschny, Apr 10 2021
  • Mathematica
    t[n_, k_] := Denominator[ Coefficient[ BernoulliB[n, x], x, n - k]]; Flatten[ Table[t[n, k], {n, 0, 13}, {k, 0, n}]] (* Jean-François Alcover, Jan 15 2013 *)
  • PARI
    v=[];for(n=0,6,v=concat(v,apply(denominator,Vec(bernpol(n)))));v \\ Charles R Greathouse IV, Jun 08 2012

Extensions

More terms from James Sellers, Jan 10 2000

A064538 a(n) is the smallest positive integer such that a(n)*(1^n + 2^n + ... + x^n) is a polynomial in x with integer coefficients.

Original entry on oeis.org

1, 2, 6, 4, 30, 12, 42, 24, 90, 20, 66, 24, 2730, 420, 90, 48, 510, 180, 3990, 840, 6930, 660, 690, 720, 13650, 1092, 378, 56, 870, 60, 14322, 7392, 117810, 7140, 210, 72, 1919190, 103740, 8190, 1680, 94710, 13860, 99330, 9240, 217350, 9660, 9870, 10080, 324870
Offset: 0

Views

Author

Floor van Lamoen, Oct 08 2001

Keywords

Comments

a(n) is a multiple of n+1. - Vladimir Shevelev, Dec 20 2011
Let P_n(x) = 1^n + 2^n + ... + x^n = Sum_{i=1..n+1}c_i*x^i. Let P^*n(x) = Sum{i=1..n+1}(c_i/(i+1))*(x^(i+1)-x). Then b(n) = (n+1)*a(n+1)is the smallest positive integer such that b(n)*P^*n(x) is a polynomial with integer coefficients. Proof follows from the recursion P(n+1)(x) = x + (n+1)*P^*n(x). As a corollary, note that, if p is the maximal prime divisor of a(n), then p<=n+1. - _Vladimir Shevelev, Dec 21 2011
The recursion P_(n+1)(x) = x + (n+1)*P^*n(x) is due to Abramovich (1973); see also Shevelev (2007). - _Jonathan Sondow, Nov 16 2015
The sum S_m(n) = Sum_{k=0..n} k^m can be written as S_m(n) = n(n+1)(2n+1)P_m(n)/a(m) for even m>1, or S_m(n) = n^2*(n+1)^2*P_m(n)/a(m) for odd m>1, where a(m) is the LCM of the denominators of the coefficients of the polynomial P_m/a(m), i.e., the smallest integer such that P_m defined in this way has integer coefficients. (Cf. Michon link.) - M. F. Hasler, Mar 10 2013
a(n)/(n+1) is squarefree, by Faulhaber's formula and the von Staudt-Clausen theorem on the denominators of Bernoulli numbers. - Kieren MacMillan and Jonathan Sondow, Nov 20 2015
a(n) equals n+1 times the product of the primes p <= (n+2)/(2+(n mod 2)) such that the sum of the base-p digits of n+1 is at least p. - Bernd C. Kellner and Jonathan Sondow, May 24 2017

Examples

			1^3 + 2^3 + ... + x^3 = (x(x+1))^2/4 so a(3)=4.
1^4 + 2^4 + ... + x^4 = x(x+1)(2x+1)(3x^2+3x-1)/30, therefore a(4)=30.
		

References

  • M. Abramowitz and I. A. Stegun, eds., Handbook of Mathematical Functions, National Bureau of Standards Applied Math. Series 55, 1964 (and various reprints), p. 804, Eq. 23.1.4.

Crossrefs

Programs

  • Maple
    A064538 := n -> denom((bernoulli(n+1,x)-bernoulli(n+1))/(n+1)): # Peter Luschny, Aug 19 2011
    # Formula of Kellner and Sondow (2017):
    a := proc(n) local s; s := (p,n) -> add(i,i=convert(n,base,p));
    select(isprime,[$2..(n+2)/(2+irem(n,2))]);
    (n+1)*mul(i,i=select(p->s(p,n+1)>=p,%)) end: seq(a(n), n=0..48); # Peter Luschny, May 14 2017
  • Mathematica
    A064538[n_] := Denominator[ Together[ (BernoulliB[n+1, x] - BernoulliB[n+1])/(n+1)]];
    Table[A064538[n], {n, 0, 44}] (* Jean-François Alcover, Feb 21 2012, after Maple *)
  • PARI
    a(n) = {my(vp = Vec(bernpol(n+1, x)-bernfrac(n+1))/(n+1)); lcm(vector(#vp, k, denominator(vp[k])));} \\ Michel Marcus, Feb 07 2016
    
  • Python
    from _future_ import division
    from sympy.ntheory.factor_ import digits, nextprime
    def A064538(n):
        p, m = 2, n+1
        while p <= (n+2)//(2+ (n% 2)):
            if sum(d for d in digits(n+1,p)[1:]) >= p:
                m *= p
            p = nextprime(p)
        return m # Chai Wah Wu, Mar 07 2018
  • Sage
    A064538 = lambda n: (n+1)*mul([p for p in (2..(n+2)//(2+n%2)) if is_prime(p) and sum((n+1).digits(base=p)) >= p])
    print([A064538(n) for n in (0..48)]) # Peter Luschny, May 14 2017
    

Formula

a(n) = (n+1)*A195441(n). - Jonathan Sondow, Nov 12 2015
A001221(a(n)/(n+1)) = A001222(a(n)/(n+1)). - Kieren MacMillan and Jonathan Sondow, Nov 20 2015
rad(a(n)) = A007947(a(n)) = A144845(n) = A324369(n+1) * A324370(n+1) * A324371(n+1). - Bernd C. Kellner, Oct 12 2023
Showing 1-10 of 27 results. Next