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

A136681 Numbers k such that A058313(k) is prime.

Original entry on oeis.org

3, 4, 5, 6, 9, 10, 13, 16, 17, 18, 37, 43, 58, 121, 124, 126, 137, 203, 247, 283, 285, 286, 289, 317, 424, 508, 751, 790, 937, 958, 1066, 1097, 1151, 1166, 1194, 1199, 1235, 1414, 1418, 1460, 1498, 1573, 2090, 2122, 2691, 2718, 3030, 3426, 3600, 3653, 3737
Offset: 1

Views

Author

Alexander Adamchuk, Jan 16 2008

Keywords

Comments

A058313(k) = Numerator of Sum_{j=1..k} (-1)^(j+1)/j.

Crossrefs

Programs

  • Mathematica
    Do[ f=Numerator[ Sum[ (-1)^(k+1)*1/k, {k,1,n} ] ]; If[ PrimeQ[f], Print[ {n,f} ] ], {n,1,317} ]
  • PARI
    isok(n) = isprime(numerator(sum(k=1, n, (-1)^(k+1)/k))); \\ Michel Marcus, Mar 14 2019

Extensions

a(25)-a(30) from James R. Buddenhagen, Sep 22 2015
a(31)-a(51) from Amiram Eldar, Mar 14 2019

A119248 a(n) is the difference between denominator and numerator of the n-th alternating harmonic number Sum_{k=1..n} (-1)^(k+1)/k = A058313(n)/A058312(n).

Original entry on oeis.org

0, 1, 1, 5, 13, 23, 101, 307, 641, 893, 7303, 9613, 97249, 122989, 19793, 48595, 681971, 818107, 13093585, 77107553, 66022193, 76603673, 1529091919, 1752184789, 7690078169, 8719737569, 23184641107, 3721854001, 96460418429
Offset: 1

Views

Author

Alexander Adamchuk, Jul 22 2006

Keywords

Comments

a(n)/A058312(n) = 1 - A058313(n)/A058312(n) appears in the locker puzzle (see the links in A364317) for the probability of success with the strategy used there for n lockers and allowed openings of up to floor(n/2) lockers. Note that gcd(a(n), A058312(n)) = 1. - Wolfdieter Lang, Aug 12 2023

Crossrefs

Programs

  • Mathematica
    Denominator[Table[Sum[(-1)^(k+1)/k,{k,1,n}],{n,1,30}]]-Numerator[Table[Sum[(-1)^(k+1)/k,{k,1,n}],{n,1,30}]]
  • PARI
    a(n) = my(x=sum(k=1, n, (-1)^(k+1)/k)); denominator(x) - numerator(x); \\ Michel Marcus, May 07 2020

Formula

a(n) = denominator(Sum_{k=1..n} (-1)^(k+1)/k) - numerator(Sum_{k=1..n} (-1)^(k+1)/k).
a(n) = A058312(n) - A058313(n).
a(n) = A075829(n+1).
a(n) = numerator(Sum_{k=2..n} (-1)^k/k). (Cf. A024168.) - Petros Hadjicostas, May 17 2020

A123944 Numbers k such that A120301(k) differs from A058313(k).

Original entry on oeis.org

19, 28, 87, 99, 104, 196, 203, 210, 222, 228, 231, 238, 281, 328, 367, 499, 579, 620, 888, 967, 1036, 1147, 1204, 1352, 1372, 1403, 1419, 1430, 1470, 1481, 1498, 1503, 1666, 1693, 1907, 2211, 2359, 2440, 2499, 2521, 2556, 2678, 2948, 3407, 3467, 3504, 3537, 3892, 4046, 4079, 4108
Offset: 1

Views

Author

Alexander Adamchuk, Nov 22 2006

Keywords

Comments

The ratio A120301(n)/A058313(n) = 1 for most n.
The ratio A120301(a(n))/A058313(a(n)) = {5, 7, 11, 5, 13, 7, 17, 7, 37, 10, 29, 119, 47, 41, 23, 5, 29, 31, 37, 11, 37, 41, 43, 13, 7, 13, 71, 13, 49, 13, 7,...} is prime for the most a(n).
The first composite ratio A120301(a(n))/A058313(a(n)) corresponds to a(n) = a(29) = 1470 because A120301(1470)/A058313(1470) = 49 = 7^2. [Edited by Petros Hadjicostas, May 09 2020]

Crossrefs

Programs

  • Mathematica
    f=0; Do[f=f+(-1)^(n+1)*1/n; g=Abs[(2(-1)^n*n+(-1)^n-1)/4]*f; rfg=Numerator[g]/Numerator[f]; If[(rfg==1)==False, Print[{n,rfg}]], {n,1,15000}]
  • PARI
    isok(n) = my(sn = sum(k=1, n, (-1)^(k+1)/k)); numerator(sn) != abs(numerator((-1/4) * (2*(-1)^n*n + (-1)^n - 1)*sn));
    for (n=1, 4200, if (isok(n), print1(n, ", "))); \\ Michel Marcus, May 10 2020

Extensions

a(47)-a(51) from Petros Hadjicostas, May 09 2020

A128465 Numbers k such that k divides the numerator of alternating Harmonic number H'((k+1)/2) = A058313((k+1)/2).

Original entry on oeis.org

1, 5, 7, 71, 379, 2659
Offset: 1

Views

Author

Alexander Adamchuk, Mar 10 2007

Keywords

Comments

For k > 1 all 5 listed terms are primes.
The only known numbers k such that k divides the numerator of alternating Harmonic number H'((k-1)/2) = A058313((k-1)/2) are the Wieferich primes (A001220): 1093 and 3511.
An odd prime p = prime(n) belongs to this sequence iff Fermat quotient A007663(n) == A130912(n) == 2*(-1)^((p+1)/2) (mod p). - Max Alekseyev, Nov 30 2022

Crossrefs

Programs

  • Mathematica
    f=0; Do[ f = f + (-1)^(n+1)*1/n; g = Numerator[f]; If[ IntegerQ[ g/(2n-1) ], Print[2n-1]], {n,1,3000} ]

Extensions

Edited by Max Alekseyev, Nov 30 2022

A351789 Decimal expansion of Sum_{k>=1} AH(k)*F(k)/2^k, where AH(k) = A058313(k)/A058312(k) is the k-th alternating harmonic number and F(k) = A000045(k) is the k-th Fibonacci number.

Original entry on oeis.org

1, 5, 1, 4, 3, 7, 0, 3, 7, 4, 2, 0, 6, 2, 2, 1, 8, 7, 2, 4, 3, 4, 5, 9, 4, 7, 8, 9, 1, 6, 1, 6, 5, 0, 7, 7, 9, 6, 4, 8, 3, 1, 3, 1, 3, 3, 1, 6, 8, 8, 7, 6, 1, 7, 7, 9, 4, 2, 3, 0, 6, 1, 8, 4, 4, 6, 5, 0, 7, 5, 3, 9, 0, 1, 5, 1, 6, 6, 4, 2, 1, 7, 5, 0, 2, 8, 7, 8, 0, 1, 8, 1, 9, 2, 0, 0, 2, 1, 0, 1, 9, 3, 4, 9, 5
Offset: 1

Views

Author

Amiram Eldar, Feb 19 2022

Keywords

Examples

			1.51437037420622187243459478916165077964831313316887...
		

Crossrefs

Programs

  • Mathematica
    RealDigits[Log[5/4] + 6*Log[GoldenRatio]/Sqrt[5], 10, 100][[1]]

Formula

Equals log(5/4) + 6*log(phi)/sqrt(5), where phi is the golden ratio (A001622) (Stewart, 2022).

A351794 Decimal expansion of Sum_{k>=1} AH(k)*L(k)/2^k, where AH(k) = A058313(k)/A058312(k) is the k-th alternating harmonic number and L(k) = A000032(k) is the k-th Lucas number.

Original entry on oeis.org

2, 8, 2, 1, 4, 7, 5, 3, 5, 8, 7, 6, 2, 6, 4, 9, 4, 6, 1, 7, 4, 6, 0, 5, 1, 4, 3, 5, 6, 8, 2, 5, 3, 0, 6, 3, 7, 2, 4, 6, 6, 5, 6, 6, 6, 9, 3, 4, 5, 4, 6, 9, 9, 1, 4, 7, 9, 8, 8, 9, 4, 1, 3, 7, 4, 2, 4, 9, 8, 1, 3, 0, 8, 6, 1, 0, 4, 6, 4, 8, 0, 7, 0, 6, 2, 6, 7, 2, 9, 9, 5, 7, 8, 7, 1, 2, 6, 4, 8, 4, 1, 7, 9, 5, 4
Offset: 1

Views

Author

Amiram Eldar, Feb 19 2022

Keywords

Examples

			2.82147535876264946174605143568253063724665666934546...
		

Crossrefs

Programs

  • Mathematica
    RealDigits[3*Log[5/4] + 10*Log[GoldenRatio]/Sqrt[5], 10, 100][[1]]

Formula

Equals 3*log(5/4) + 10*log(phi)/sqrt(5), where phi is the golden ratio (A001622).
Equals (4/3)*log(5/4) + (5/3)*A351789.

A167372 a(n) = A120301(A123944(n))/A058313(A123944(n)).

Original entry on oeis.org

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

Views

Author

Alexander Adamchuk, Nov 02 2009

Keywords

Comments

The ratio A120301(n)/A058313(n) = 1 for most n.
a(n) is prime for most n.
The first composite ratio a(12) = 119 = 7*17 corresponds to A123944(12) = 238.
The next two composite ratios a(29) = a(76) = 49 = 7^2 correspond to A123944(29) = 1470 and A123944(76) = 10290. [Edited by Petros Hadjicostas, May 09 2020]

Crossrefs

Programs

  • Mathematica
    f = 0; Do[f = f + (-1)^(n + 1) * 1/n; g = Abs[(2(-1)^n * n + (-1)^n - 1)/4] * f; rfg = Numerator[g]/Numerator[f]; If[(rfg == 1) == False, Print[rfg]], {n, 1500}]
  • PARI
    lista(nn) = {for (n=1, nn, my(sn = sum(k=1, n, (-1)^(k+1)/k)); if ((s=numerator(sn)) != (ss=abs(numerator((-1/4) * (2*(-1)^n*n + (-1)^n - 1) * sn))), print1(ss/s, ", ")););} \\ Michel Marcus, May 10 2020

Extensions

a(32)-a(46) from Petros Hadjicostas, May 09 2020, using Michel Marcus's program and the data from A123944
a(47)-a(72) from Petros Hadjicostas, May 09 2020, using the Mathematica program

A173756 Partial sums of A058313.

Original entry on oeis.org

1, 2, 7, 14, 61, 98, 417, 950, 2829, 4456, 24873, 42980, 306091, 543462, 595741, 691290, 2459767, 4092108, 37557035, 193242042, 360012409, 516201296, 4341338257, 7943382348, 27024448579, 45075855410, 102204647503, 109956141102, 346222803073, 571398562364
Offset: 1

Views

Author

Jonathan Vos Post, Feb 23 2010

Keywords

Comments

Partial sum of the numerator of the n-th alternating harmonic number.

Crossrefs

Cf. A001008 (numerator of the n-th harmonic number), A025530, A058312 (denominators of the underlying sequence), A058313, A075830.

Programs

  • Maple
    a := proc(n) local i, k:
    add(numer(add((-1)^(k + 1)/k, k = 1 .. i)), i = 1 .. n): end proc:
    seq(a(n), n = 1 .. 40); # Petros Hadjicostas, May 06 2020
  • PARI
    a(n) = sum(i=1, n, numerator(sum(k=1, i, (-1)^(k+1)/k))); \\ Michel Marcus, May 07 2020

Formula

a(n) = Sum_{i=1..n} A058313(i) = Sum_{i=1..n} numerator(Sum_{k=1..i} (-1)^(k+1)/k). [Corrected by Petros Hadjicostas and Michel Marcus, May 06 2020]

Extensions

Data corrected and extended by Petros Hadjicostas, May 06 2020

A058312 Denominator of the n-th alternating harmonic number, Sum_{k=1..n} (-1)^(k+1)/k.

Original entry on oeis.org

1, 2, 6, 12, 60, 60, 420, 840, 2520, 2520, 27720, 27720, 360360, 360360, 72072, 144144, 2450448, 2450448, 46558512, 232792560, 232792560, 232792560, 5354228880, 5354228880, 26771144400, 26771144400, 80313433200, 11473347600
Offset: 1

Views

Author

N. J. A. Sloane, Dec 09 2000

Keywords

Comments

a(n) is a divisor of A003418(n). The first time this is a proper divisor, is a(15); see A269626. - Jeppe Stig Nielsen, Mar 01 2016

Examples

			1, 1/2, 5/6, 7/12, 47/60, 37/60, 319/420, 533/840, 1879/2520, ...
		

Crossrefs

Numerators are A058313. Cf. A025530.
Cf. A002805 (denominator of n-th harmonic number).

Programs

  • Haskell
    import Data.Ratio((%), denominator)
    a058312 n = a058312_list !! (n-1)
    a058312_list = map denominator $ scanl1 (+) $
                       map (1 %) $ tail a181983_list
    -- Reinhard Zumkeller, Mar 20 2013
  • Maple
    A058313 := n->denom(add((-1)^(k+1)/k,k=1..n));
    # Alternatively:
    a := n -> denom(harmonic(n) - harmonic((n-modp(n,2))/2)):
    seq(a(n), n=1..28); # Peter Luschny, May 03 2016
  • Mathematica
    a[n_] := Sum[(-1)^(k+1)/k, {k, 1, n}]; Table[a[n] // Denominator, {n, 1, 30}] (* Jean-François Alcover, May 26 2015 *)
    a[n_]:= (-1)^n(HarmonicNumber[n/2-1/2]-HarmonicNumber[n/2]+(-1)^n Log[4])/2; Table[a[n] // FullSimplify, {n, 1, 29}] // Denominator (* Gerry Martens, Jul 05 2015 *)
    Rest[Denominator[CoefficientList[Series[Log[1 + x]/(1 - x),{x, 0, 33}], x]]] (* Vincenzo Librandi, Jul 06 2015 *)
  • PARI
    a(n)=denominator(polcoeff(-log(1-x)/(x+1)+O(x^(n+1)),n))
    
  • PARI
    a(n)=denominator(sum(k=1,n,(-1)^(k+1)/k)) \\ Jeppe Stig Nielsen, Mar 01 2016
    

Formula

G.f. for A058313(n)/ A058312(n): log(1+x)/(1-x). - Benoit Cloitre, Jun 15 2003
a(n) = n*a(n-1)/gcd(n*a(n-1), n*A058313(n-1)+(-1)^(n-1)*a(n-1)). - Robert Israel, Jul 05 2015
a(n) = the (reduced) denominator of the continued fraction 1/(1 + 1^2/(1 + 2^2/(1 + 3^2/(1 + ... + (n-1)^2/(1))))). - Peter Bala, Feb 18 2024

A197070 Decimal expansion of the Dirichlet eta-function at 3.

Original entry on oeis.org

9, 0, 1, 5, 4, 2, 6, 7, 7, 3, 6, 9, 6, 9, 5, 7, 1, 4, 0, 4, 9, 8, 0, 3, 6, 2, 1, 1, 3, 3, 5, 8, 7, 4, 9, 3, 0, 7, 3, 7, 3, 9, 7, 1, 9, 2, 5, 5, 3, 7, 4, 1, 6, 1, 3, 4, 4, 2, 0, 3, 6, 6, 6, 5, 0, 6, 3, 7, 8, 6, 5, 4, 3, 3, 9
Offset: 0

Views

Author

R. J. Mathar, Oct 09 2011

Keywords

Comments

This constant is irrational by Apéry's theorem. - Charles R Greathouse IV, Feb 11 2024

Examples

			0.9015426773696957140498036211335874930737...
		

Crossrefs

Cf. A002117 (zeta(3)), A058312, A058313, A072691, A136675, A233090 (5*zeta(3)/8), A233091 (7*zeta(3)/8), A334582.

Programs

Formula

Equals 3*zeta(3)/4 = 3*A002117/4.
Also equals the integral over the unit cube [0,1]x[0,1]x[0,1] of 1/(1+x*y*z) dx dy dz. - Jean-François Alcover, Nov 24 2014
Equals Sum_{n>=1} (-1)^(n+1)/n^3. - Terry D. Grant, Aug 03 2016
Equals Lim_{n -> infinity} A136675(n)/A334582(n). - Petros Hadjicostas, May 07 2020
Equals Sum_{n>=1} AH(2*n)/n^2, where AH(n) = Sum_{k=1..n} (-1)^(k+1)/k = A058313(n)/A058312(n) is the n-th alternating harmonic number (Stewart, 2020). - Amiram Eldar, Oct 04 2021
Equals -int_0^1 log(x)log(1+x)/x dx [Barbieri] - R. J. Mathar, Jun 07 2024
Showing 1-10 of 56 results. Next