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

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A118830 2-adic continued fraction of zero, where a(n) = if n=1(mod 2), -1, else +2*A006519(n/2). 5
-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 (list; graph; refs; listen; history; internal format)
OFFSET

1,2

COMMENTS

Limit of convergents equals zero; only the 6-th convergent is indeterminate. Other 2-adic continued fractions of zero are: A118821, A118824, A118827. A006519(n) is the highest power of 2 dividing n; A080277 = partial sums of A038712, where A038712(n) = 2*A006519(n) - 1.

EXAMPLE

For n>=1, convergents A118831(k)/A118832(k) are:

at k = 4*n: 1/(2*A080277(n));

at k = 4*n+1: 1/(2*A080277(n)-1);

at k = 4*n+2: 1/(2*A080277(n)-2);

at k = 4*n-1: 0.

Convergents begin:

-1/1, -1/2, 0/-1, -1/-2, 1/1, 1/0, 0/1, 1/8,

-1/-7, -1/-6, 0/-1, -1/-10, 1/9, 1/8, 0/1, 1/24,

-1/-23, -1/-22, 0/-1, -1/-26, 1/25, 1/24, 0/1, 1/32,

-1/-31, -1/-30, 0/-1, -1/-34, 1/33, 1/32, 0/1, 1/64, ...

PROG

(PARI) a(n)=local(p=-1, q=+2); if(n%2==1, p, q*2^valuation(n/2, 2))

CROSSREFS

Cf. A006519, A080277; convergents: A118831/A118832; variants: A118821, A118824, A118827; A100338.

Sequence in context: A068057 A003484 A118827 * A055975 A006519 A087258

Adjacent sequences:  A118827 A118828 A118829 * A118831 A118832 A118833

KEYWORD

cofr,sign

AUTHOR

Paul D. Hanna (pauldhanna(AT)juno.com), May 01 2006

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 13 20:26 EST 2012. Contains 205553 sequences.