login
This site is supported by donations to The OEIS Foundation.
Logo

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A064024 a(n) = value of k such that absolute difference of 2^n and 3^k is minimized. 2
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 (list; graph; refs; listen; history; internal format)
OFFSET

0,5

COMMENTS

a(n) = minimum value of Abs[ 2^n - 3^k ]. [From Harry J. Smith (hjsmithh(AT)sbcglobal.net), Sep 06 2009]

LINKS

Harry J. Smith, Table of n, a(n) for n=0,...,500

EXAMPLE

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

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} ]

PROG

(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 ) } [From Harry J. Smith (hjsmithh(AT)sbcglobal.net), Sep 06 2009]

CROSSREFS

Cf. A056850.

Sequence in context: A046557 A125719 A070975 * A204138 A179118 A140657

Adjacent sequences:  A064021 A064022 A064023 * A064025 A064026 A064027

KEYWORD

nonn

AUTHOR

Robert G. Wilson v (rgwv(AT)rgwv.com), Sep 18 2001

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
Recent Additions | More pages | Superseeker | Maintained by The OEIS Foundation Inc.

Content is available under The OEIS End-User License Agreement .

Last modified February 15 03:59 EST 2012. Contains 205694 sequences.