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.

Previous Showing 41-50 of 56 results. Next

A130679 a(n) = (n+1+(-1)^n)*A024167(n), related to alternating harmonic sums.

Original entry on oeis.org

1, 4, 15, 84, 470, 3552, 26796, 255840, 2435184, 28114560, 323405280, 4380445440, 59105255040, 918796677120, 14228252640000, 249644312064000, 4363865549568000, 85297521899520000, 1661265370695168000
Offset: 1

Views

Author

Paul Curtz, Jun 29 2007

Keywords

Comments

Inspired by a formula in the reference, the study of the singular points of planar differential systems leads to 3 two-dimensional polynomial families, one ordinary (degenerate case, considered in one dimension, see A129326) and two odd (the second, considered in one dimension, see A129587).
The first is in one dimension P(2n-1,x)=(n+1+x^n)*sum_{i=0..n-1} x^i/(i+1), n>=1.
The table of coefficients of P() with 2n coefficients per row starts:
2, 1;
3, 3/2, 1, 1/2;
4, 2, 4/3, 1, 1/2, 1/3;.. .
Rows multiplied by n!, the table becomes Q():
2, 1;
6, 3, 2, 1;
24, 12, 8, 6, 3, 2;
120, 60, 40, 30, 24, 12, 8, 6;
720, 360, 240, 180, 144,...
The sequence gives the alternating row sums of this table Q, positive sign for coefficients in front of even and negative sign for coefficients in front of odd powers of x.
The row sums of Q are (n+2)*A000254(n)= 3, 12, 55, 300...
Adding the alternating and ordinary row sums yields the sequence 4, 16, 70, 384....
The sequence of sums of antidiagonals in the Q table starts 2, 6+1=7, 24+3=27, 120+12+1=134.

Examples

			a(1) = 2-1.
a(2) = 6-3+2-1.
a(3) = 24-12+8-6+3-2.
		

Programs

  • Mathematica
    a[n_] := (1/2)*(n + (-1)^n + 1)*n!*((-1)^n*(HarmonicNumber[(n-1)/2] - HarmonicNumber[n/2]) + Log[4]); Table[a[n] // FullSimplify, {n, 1, 19}] (* Jean-François Alcover, Oct 03 2012 *)

Formula

a(n) = n!*(n+1+(-1)^n)*A058313(n)/A058312(n). - R. J. Mathar, Jul 28 2008

Extensions

Edited and extended by R. J. Mathar, Jul 28 2008

A035048 Numerators of alternating sum transform (PSumSIGN) of Harmonic numbers H(n) = A001008/A002805.

Original entry on oeis.org

1, 1, 4, 3, 23, 11, 176, 25, 563, 137, 6508, 49, 88069, 363, 91072, 761, 1593269, 7129, 31037876, 7381, 31730711, 83711, 744355888, 86021, 3788707301, 1145993, 11552032628, 1171733, 340028535787, 1195757
Offset: 1

Views

Author

Keywords

Comments

p^2 divides a(2p-2) for prime p>3. a(2p-2)/p^2 = A061002(n) = A001008(p-1)/p^2 for prime p>2. - Alexander Adamchuk, Jul 07 2006

Crossrefs

Programs

  • Maple
    S:= series(log(1-x)/(x^2-1), x, 101):
    seq(numer(coeff(S,x,j)), j=1..100); # Robert Israel, Jun 02 2015
  • Mathematica
    Numerator[Table[Sum[(-1)^(k+1)*Sum[(-1)^(i+1)*1/i,{i,1,k}],{k,1,n}],{n,1,50}]] (* Alexander Adamchuk, Jul 07 2006 *)
  • PARI
    a(n)=numerator(polcoeff(log(1-x)/(x^2-1)+O(x^(n+1)),n))

Formula

G.f. for A035048(n)/A035047(n) : log(1-x)/(x^2-1). - Benoit Cloitre, Jun 15 2003
a(n) = Numerator[Sum[(-1)^(k+1)*Sum[(-1)^(i+1)*1/i,{i,1,k}],{k,1,n}]]. - Alexander Adamchuk, Jul 07 2006
a(n) = numerator((-1)^(n+1)*1/2*(log(2)+(-1)^(n+1)*(gamma+1/2*(psi(1+n/2)-psi(3/2+n/2))+psi(2+n)))), with gamma the Euler-Mascheroni constant. - - Gerry Martens, Apr 28 2011

A128671 Least number k > 0 such that k^p does not divide the denominator of generalized harmonic number H(k,p) nor the denominator of alternating generalized harmonic number H'(k,p), where p = prime(n).

Original entry on oeis.org

20, 94556602, 444, 104, 77, 3504, 1107, 104, 2948, 903, 77, 1752, 77, 104, 370
Offset: 1

Views

Author

Alexander Adamchuk, Mar 24 2007, Mar 26 2007

Keywords

Comments

Generalized harmonic numbers are defined as H(m,k) = Sum_{i=1..m} 1/i^k. Alternating generalized harmonic numbers are defined as H'(m,k) = Sum_{i=1..m} (-1)^(i+1)*1/i^k.
a(18)..a(24) = {77,104,77,136,104,370,136}. a(26)..a(27) = {77,104}.
a(n) is currently unknown for n = {16,17,25,...}. See more details in Comments at A128672 and A125581.

Examples

			a(2) = A128673(1) = 94556602.
		

Crossrefs

Formula

a(n) = A128670(prime(n)).

Extensions

a(9) = 2948 and a(12) = 1752 from Max Alekseyev
Edited by Max Alekseyev, Feb 20 2019

A262031 Numerator of partial sums of a reordered alternating harmonic series.

Original entry on oeis.org

1, 4, 5, 31, 247, 389, 1307, 15637, 13327, 187111, 199123, 353201, 6364777, 127056883, 23083451, 24191987, 579694957, 535076383, 13912332463, 43224283189, 40355946289, 1210479158981, 38689398709811, 72866186391697, 75054119011297, 77117026909777, 73105817107177, 2777117009412349
Offset: 0

Views

Author

Wolfdieter Lang, Sep 08 2015

Keywords

Comments

For the denominators see A262022.
The reordered alternating harmonic series considered here is 1 + 1/3 - 1/2 + 1/5 + 1/7 - 1/4 + 1/9 + 1/11 - 1/6 + ... + ... - ...
The limit n -> infinity of the partial sums s(n) = a(n)/A262031(n) is 3*log(2)/2, approximately 1.03972077083991... For the decimal expansion see A262023.
Combining three consecutive terms of this series leads to the series b(0) + b(1) + ..., with b(k) = (1/2)*(8*k+5)/((4*k+1)*(4*k+3)*(k+1)). This produces partial sums 5/6, 13/140, 7/198, 29/1560, 37/3230, ..., which are given by s(3*n+2), n = 0, 1, .... Therefore, the limit is the same as the one given above, and it is obtained from Sum_{k=0..n} b(k) = (1/4)*Psi(n+5/4) + (1/4)*Psi(n+7/4) - (1/2)*Psi(n+2) + (3/2)*log(2), with the digamma function Psi(x).
This reordered alternating harmonic series appears as an example in the famous Dirichlet article, p. 319 (Werke I). Martin Ohm showed that for the reordering with alternating m consecutive positive terms followed by n negative terms (here n = 2 and m = 1) the sum becomes log(2) + (1/2)*log(m/n). See the reference, paragraph 8. p. 12-14. See also the Pringsheim reference.

Examples

			The first fractions s(n) (in lowest terms) are 1, 4/3, 5/6, 31/30, 247/210, 389/420, 1307/1260, 15637/13860, 13327/13860, 187111/180180, 199123/180180, 353201/360360, ...
The values s(10^n), for n=0..6, are (Maple 10 digits) [1.333333333, 1.105133755, 1.047114258, 1.040469694, 1.039795760, 1.039728271, 1.039721521], to be compared with 3*log(2)/2 (approximately 1.039720771).
		

Crossrefs

Cf. A262022 (denominator), A262023, A058313, A058312, A002162.

Programs

  • Mathematica
    Table[Numerator@ Sum[Which[Mod[k, 3] == 0, 3/(4 k + 3), Mod[k, 3] == 1, 3/(4 k + 5), True, -3/(2 (k + 1))], {k, 0, n} ], {n, 0, 27}] (* Michael De Vlieger, Jul 26 2016 *)
  • PARI
    lista(nn) = {my(s = 0); for (k=0, nn, if (k%3==2, t = -3/(2*(k+1)), if (k%3==1, t = 3/(4*k+5), t = 3/(4*k+3))); s += t; print1(numerator(s), ", "););} \\ Michel Marcus, Sep 13 2015

Formula

a(n) = numerator(s(n)) with s(n) = Sum_{k=0..n} c(k), where c(k) = 3/(4*k+3), 3/(4*k+5), -3/(2*(k+1)) if k == 0, 1, 2 (mod 3), respectively.

A305307 Expansion of e.g.f. 1/(1 - log(1 + x)/(1 - x)).

Original entry on oeis.org

1, 1, 3, 17, 120, 1084, 11642, 146446, 2101656, 33958344, 609431232, 12033015840, 259163792016, 6047213451408, 151953760489008, 4091057804809104, 117485988199385088, 3584814699783432960, 115816462543697120640, 3949619921174717629056, 141780511159572486530304, 5344008726418981985707776
Offset: 0

Views

Author

Ilya Gutkovskiy, May 29 2018

Keywords

Comments

a(n)/n! is the invert transform of [1, 1 - 1/2, 1 - 1/2 + 1/3, 1 - 1/2 + 1/3 - 1/4, 1 - 1/2 + 1/3 - 1/4 + 1/5, ...].

Examples

			E.g.f.: A(x) = 1 + x + 3*x^2/2! + 17*x^3/3! + 120*x^4/4! + 1084*x^5/5! + 11642*x^6/6! + ...
		

Crossrefs

Programs

  • Maple
    g:= proc(n) g(n):= `if`(n=1, 0, g(n-1))-(-1)^n/n end:
    b:= proc(n) option remember; `if`(n=0, 1,
          add(g(j)*b(n-j), j=1..n))
        end:
    a:= n-> b(n)*n!:
    seq(a(n), n=0..20);  # Alois P. Heinz, May 29 2018
  • Mathematica
    nmax = 21; CoefficientList[Series[1/(1 - Log[1 + x]/(1 - x)), {x, 0, nmax}], x] Range[0, nmax]!
    nmax = 21; CoefficientList[Series[1/(1 - Sum[Sum[(-1)^(j + 1)/j, {j, 1, k}] x^k , {k, 1, nmax}]), {x, 0, nmax}], x] Range[0, nmax]!
    a[0] = 1; a[n_] := a[n] = Sum[((-1)^(k + 1) LerchPhi[-1, 1, k + 1] + Log[2]) a[n - k], {k, 1, n}]; Table[n! a[n], {n, 0, 21}]

Formula

E.g.f.: 1/(1 - Sum_{k>=1} (A058313(k)/A058312(k))*x^k).
a(n) ~ n! * (2 - LambertW(exp(2))) / ((1 + 1/LambertW(exp(2))) * (LambertW(exp(2)) - 1)^(n+1)). - Vaclav Kotesovec, Aug 08 2021

A364317 Irregular triangle T read by rows: T(n, k) gives the number of permutations of [n] = {1, 2, ..., n} with a cycle of length m = floor(n/2) + k = A138099(n, k), for 1 <= k <= n - floor(n/2) = ceiling(n/2).

Original entry on oeis.org

1, 1, 3, 2, 8, 6, 40, 30, 24, 180, 144, 120, 1260, 1008, 840, 720, 8064, 6720, 5760, 5040, 72576, 60480, 51840, 45360, 40320, 604800, 518400, 453600, 403200, 362880, 6652800, 5702400, 4989600, 4435200, 3991680, 3628800
Offset: 1

Views

Author

Wolfdieter Lang, Aug 12 2023

Keywords

Comments

The length of row n is ceiling(n/2) = A008619(n-1).
The numbers for these cycles of permutations of [n], appear in the solution of the Locker Problem. See the link, p. 25.
For the probability of failures with the strategy used in the locker problem with n lockers and opening of up to floor(n/2) lockers see A058313(n)/A058312(n), for n > = 1. For n = 1 the one team member is not allowed to open the one locker (with the member's wallet) because (n/2) = 0; so certainly a failure.
For the probability of success in this locker problem for n lockers see A119248(n)/A058312(n), for n >= 1.

Examples

			The irregular triangle begins:
n\k       1       2       3       4       5       6 ...
-------------------------------------------------------
1:        1
2:        1
3:        3       2
4:        8       6
5:       40      30      24
6:      180     144     120
7:     1260    1008     840     720
8:     8064    6720    5760    5040
9:    72576   60480   51840   45360   40320
10:  604800  518400  453600  403200  362880
11: 6652800 5702400 4989600 4435200 3991680 3628800
...
T(5, 1) = 40 because m(5, 1) = 2 + 1 = 3, and for each of the binomial(5, 3) = 10 possibilities for choosing three numbers from [5] there are (3 - 1)! = 2 3-cycles if each starts with the smallest number, e.g., for {2, 3, 5} the cycles are (2, 3, 5) and (2, 5, 3). For the remaining 5-3 = 2 numbers there are 2! possible permutations; in the example permutations of {1, 4}, namely (1)(4) and (1,4). Thus T(5, 3) = binomial(5, 3)*2!*2! = 10*2*2 = 40 = 5!/3.
		

Crossrefs

Programs

Formula

T(n, k) = binomial(n, m(n, k))*(m(n, k) - 1)!*(n - m(n, k))! = n!/m(n, k), with m(n, k) = floor(n/2) + k = A138099(n, k), for n >= 1 and k = 1, 2, ..., ceiling(n/2).

A121595 Compressed version of A119788 (all entries equal to 1 are excluded).

Original entry on oeis.org

5, 7, 5, 11, 13, 17, 7, 29, 7, 37, 19, 47, 119, 41, 23, 5, 29, 31, 11, 37, 37, 41, 43, 71, 13, 7, 13, 13, 47, 13, 49, 7, 7, 7, 53, 5, 79, 59, 97, 61, 71, 103, 67, 17, 71, 61, 73, 139, 17, 17, 79, 19, 19, 19, 83, 19, 151, 89, 29, 29, 263, 97
Offset: 1

Views

Author

Alexander Adamchuk, Aug 09 2006

Keywords

Comments

Also the ratio of the numerators of n*H'(n) = A119787(n) and H'(n) = A058313(n) when they are different. (H'(n) is the alternating harmonic number H'(n) = Sum_{k=1..n} (-1)^(k+1)*1/k.)
The ratio of numerators A119787(n)/A058313(n) for n = 1..400 is given in A119788(n).
It appears that most a(n) are prime divisors of the corresponding indices A121594(n).
The first and only composite a(n) up to A119788(6000) is a(31) = 49 corresponding to A119788(1470).
It appears that all a(n) belong to A092579(n), which is a sieve using the Fibonacci sequence over the integers >= 2. [Edited by Petros Hadjicostas, May 11 2020]

Crossrefs

Programs

  • Mathematica
    Do[H=Sum[(-1)^(i+1)*1/i, {i, 1, n}]; a=Numerator[n*H]; b=Numerator[H]; If[ !Equal[a,b],Print[{n,a/b}]], {n,1,6000}]

Formula

a(n) = A119788(A121594(n)), while the corresponding indices are given in A121594(n).

A115388 Numerator of rational part of raw moment n of the line point picking problem.

Original entry on oeis.org

-1, 3, -4, 17, -41, 42, -289, 1171, -1739, 1753, -19157, 19262, -249251, 250241, -249383, 200107, -1696405, 1700409, -32239703, 161504821, -161227687, 161479627, -3708740681, 3713590526, -18545643343, 18566236531, -55641506293, 55694623643, -230529988171
Offset: 1

Views

Author

Eric W. Weisstein, Jan 21 2006

Keywords

Examples

			-1 + 2*log(2), 3 - 4*log(2), -4 + 6*log(2), 17/3 - 8*log(2), -41/6 + 10*log(2), ...
The above sequence of numbers is given by 4*Integral_{x = 0..Pi/4} tan(x)^(2*n+1) * cos(x)^2 dx for n >= 1, or, equivalently, by Integral_{y = 0..1} Integral_{x = 0..1} 2*n*(x*y)^n/(x + y)^2 dx dy for n >= 1. - _Peter Bala_, Jan 04 2023
		

Crossrefs

Programs

  • Maple
    a := n -> numer(1 + 2*n*add((-1)^(n+k+1)/k, k = 1..n)):
    seq(a(n), n = 1..28); # Peter Bala, Jan 05 2023
    # Alternative:
    a := n -> 2*n*((-1)^n*log(2) - LerchPhi(-1, 1, n + 1)) + 1:
    seq(numer(simplify(a(n))), n = 1..29); # Peter Luschny, Jan 05 2023

Formula

From Pontus von Brömssen, Nov 03 2019: (Start)
For even n, a(n)/A115389(n) = 2*n*Sum_{k = n/2..n-1} 1/k - 1.
For odd n >= 3, a(n)/A115389(n) = -2*n*((Sum_{k = (n-1)/2..n-2} 1/k) - 1/(n-1)) - 1. (End)
a(n) = numerator of 1 + (2*n)*Sum_{k = 1..n} (-1)^(n+k+1)/k. - Peter Bala, Jan 05 2023
a(n) = numerator of 2*n*((-1)^n*log(2) - LerchPhi(-1, 1, n + 1)) + 1. - Peter Luschny, Jan 05 2023

A115389 Denominator of rational part of raw moment n of the line point picking problem.

Original entry on oeis.org

1, 1, 1, 3, 6, 5, 30, 105, 140, 126, 1260, 1155, 13860, 12870, 12012, 9009, 72072, 68068, 1225224, 5819814, 5542680, 5290740, 116396280, 111546435, 535422888, 514829700, 1487285800, 1434168450, 5736673800, 5545451340, 166363540200, 644658718275, 312561802800
Offset: 1

Views

Author

Eric W. Weisstein, Jan 21 2006

Keywords

Examples

			-1 + 2*log(2), 3 - 4*log(2), -4 + 6*log(2), 17/3 - 8*log(2), -41/6 + 10*log(2), ...
		

Crossrefs

Programs

  • Maple
    a := n -> denom(1 + 2*n*add((-1)^(n+k+1)/k, k = 1..n)):
    seq(a(n), n = 1..30); # Peter Bala, Jan 05 2023
    # Alternative:
    a := n -> 2*n*((-1)^n*log(2) - LerchPhi(-1, 1, n + 1)) + 1:
    seq(denom(simplify(a(n))), n = 1..33); # Peter Luschny, Jan 05 2023

Formula

a(n) = denominator of 1 + (2*n)*Sum_{k = 1..n} (-1)^(n+k+1)/k. - Peter Bala, Jan 05 2023
a(n) = denominator of 2*n*((-1)^n*log(2) - LerchPhi(-1, 1, n + 1)) + 1. - Peter Luschny, Jan 05 2023

A262136 Number of distinct fractional parts of the numbers Sum_{i=j..k} (-1)^i/i with 1 <= j <= k <= n, where the fractional part of x is given by x - floor(x).

Original entry on oeis.org

1, 2, 4, 7, 11, 14, 20, 27, 35, 44, 54, 64, 76, 89, 103, 118, 134, 151, 169, 186, 206, 227, 249, 272, 296, 321, 347, 374, 402, 430, 460, 491, 523, 556, 590, 625, 661, 698, 736, 775, 815, 854, 896, 939, 983, 1028, 1074, 1121, 1169, 1218, 1268, 1319, 1371, 1424, 1478, 1532, 1588, 1645, 1703, 1762
Offset: 1

Views

Author

Zhi-Wei Sun, Sep 11 2015

Keywords

Comments

Note that (-1)^n/n+(-1)^(n+1)/(n+1) = (-1)^n/(n*(n+1)) for any n > 0.
Conjecture: (i) Suppose that Sum_{i=j..k} (-1)^i/i and Sum_{r=s..t} (-1)^r/r with 0 < min{2,k} <= j <= k, 0 < min{2,t} <= s <= t and j <= s have the same fractional part, but the ordered pairs (j,k) and (s,t) are different. Then Sum_{i=j..k} (-1)^i/i = Sum_{r=s..t} (-1)^r/r. Moreover, if j is odd, then j > 1, k = j*(j+1) and (s,t) = (j+2,j*(j+1)-1); if j is even, then either (k = j+1 and s = t = j*(j+1)), or (k = j*(j+1)-1 and (s,t) = (j+2,j*(j+1))).
(ii) Let a > b >= 0 and m > 0 be integers with gcd(a,b) = 1 < max{a,m}. For each r = 0,1, the numbers Sum_{i=j..k} (-1)^(i-r*j)/(a*i-b)^m with 1 <= j <= k and (j > 1 if k > a-b = 1) have pairwise distinct fractional parts.
This is an analog of the conjecture in A261878. Part (i) of the conjecture implies that a(n) = n*(n-1)/2 + 2 - floor((sqrt(4n+1)-1)/2) - floor((sqrt(4n+1)-1)/4) for all n > 1.

Examples

			a(6) = 14 since the sums (-1)^j/j+...+(-1)^k/k with 0 < min{k,2} <= j <= k <= 6 and (j,k) different from (4,6) and (6,6) have pairwise distinct fractional parts, but (-1)^6/6 = (-1)^2/2+(-1)^3/3 and 1/4-1/5+1/6 = 1/2-1/3+1/4-1/5.
		

Crossrefs

Programs

  • Mathematica
    frac[x_]:=x-Floor[x]
    u[0]:=0
    u[n_]:=u[n-1]+(-1)^n/n
    S[n_]:=Table[frac[u[n]-u[m-1]],{m,Min[2,n],n}]
    T[1]:=S[1]
    T[n_]:=Union[T[n-1],S[n]]
    Do[Print[n," ",Length[T[n]]],{n,1,60}]
Previous Showing 41-50 of 56 results. Next