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

A056576 Highest k with 2^k <= 3^n.

Original entry on oeis.org

0, 1, 3, 4, 6, 7, 9, 11, 12, 14, 15, 17, 19, 20, 22, 23, 25, 26, 28, 30, 31, 33, 34, 36, 38, 39, 41, 42, 44, 45, 47, 49, 50, 52, 53, 55, 57, 58, 60, 61, 63, 64, 66, 68, 69, 71, 72, 74, 76, 77, 79, 80, 82, 84, 85, 87, 88, 90, 91, 93, 95, 96, 98, 99, 101, 103, 104, 106, 107
Offset: 0

Views

Author

Henry Bottomley, Jun 29 2000

Keywords

Examples

			a(3)=4 because 3^3=27 and 2^4=16 is power of 2 immediately below 27.
		

Crossrefs

Cf. A000079 (powers of 2), A000244 (powers of 3), A020914, A022921.
Cf. A056850, A117630 (complement), A020857 (decimal expansion of log_2(3)), A076227, A100982.

Programs

Formula

a(n) = floor(log_2(3^n)) = log_2(A000244(n)-A056576(n)) = a(n-1)+A022921(n-1).
a(n) = A020914(n) - 1. - L. Edson Jeffery, Dec 12 2014

A064024 a(n) = minimum value of abs(2^n - 3^k).

Original entry on oeis.org

0, 1, 1, 1, 7, 5, 17, 47, 13, 217, 295, 139, 1909, 1631, 3299, 13085, 6487, 46075, 84997, 7153, 517135, 502829, 588665, 3605639, 2428309, 9492289, 24062143, 5077565, 118985033, 149450423, 88519643, 985222181, 808182895, 1870418611
Offset: 0

Views

Author

Robert G. Wilson v, Sep 18 2001

Keywords

Examples

			a(5) = 5 because |2^5 - 3^3| = 5.
		

Crossrefs

Cf. A056850.

Programs

  • Mathematica
    Do[ k = 0; While[ Abs[ 2^n - 3^k ] > Abs[ 2^n - 3^(k + 1) ], k++ ]; Print[ Abs[ 2^n - 3^k ]], {n, 0, 40} ]
  • PARI
    { p=t=1; for (n=0, 500, while ((a=abs(p - t)) > abs(p - 3*t), t*=3); write("b064024.txt", n, " ", a); p*=2 ) } \\ Harry J. Smith, Sep 06 2009

Extensions

Name changed by Sean A. Irvine, Jun 08 2023

A014122 Numbers of form |2^i +- 3^j|.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 7, 8, 9, 10, 11, 13, 15, 17, 19, 23, 25, 26, 28, 29, 31, 33, 35, 37, 41, 43, 47, 49, 55, 59, 61, 63, 65, 67, 73, 77, 79, 80, 82, 83, 85, 89, 91, 97, 101, 113, 115, 119, 125, 127, 129, 131, 137, 139, 145, 155, 175, 179, 209, 211, 217, 227
Offset: 1

Views

Author

Richard C. Schroeppel

Keywords

Comments

Based on checking i <= 100 and j <= 60.
Existing sequence correct for j <= 200000. - Sean A. Irvine, Oct 04 2018
2*k is a term iff 2*k = 3^j +- 1. - Sean A. Irvine, Oct 04 2018
Existing sequence correct for j <= 10^6. - David A. Corneth, Oct 04 2018
3*k is a term iff 3*k = 2^j +- 1. - Jon E. Schoenfield, Oct 04 2018

Crossrefs

Extensions

Constraint on search moved from title to comments by Sean A. Irvine, Oct 04 2018

A086453 Least difference between 5^n and a power of 2.

Original entry on oeis.org

0, 1, 7, 3, 113, 971, 759, 12589, 128481, 144027, 1377017, 15273693, 24294831, 146961301, 1808548329, 3842160243, 15148937153, 213183639237, 583349245479, 1481300283709, 24998687462961, 86112795218187, 132385977330377
Offset: 0

Views

Author

Lekraj Beedassy, Sep 09 2003

Keywords

Crossrefs

Formula

min(5^n-2^A061785(n), 2^(A061785(n)+1)-5^n), where A061785(n) is Beatty sequence for log[2](5). - Vladeta Jovovic, Sep 11 2003

Extensions

More terms from Ray Chandler and John W. Layman, Sep 10 2003
Showing 1-4 of 4 results.