login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A277011 Left inverse of A277012. 3

%I #8 Sep 26 2016 20:46:54

%S 0,1,2,2,6,3,4,3,24,7,8,4,12,5,6,4,120,25,26,8,30,9,10,5,48,13,14,6,

%T 18,7,8,5,720,121,122,26,126,27,28,9,144,31,32,10,36,11,12,6,240,49,

%U 50,14,54,15,16,7,72,19,20,8,24,9,10,6,5040,721,722,122,726,123,124,27,744,127,128,28,132,29,30,10,840,145,146,32

%N Left inverse of A277012.

%H Antti Karttunen, <a href="/A277011/b277011.txt">Table of n, a(n) for n = 0..8191</a>

%H <a href="/index/Bi#binary">Index entries for sequences related to binary expansion of n</a>

%H <a href="/index/Fa#facbase">Index entries for sequences related to factorial base representation</a>

%F a(n) = A276075(A005940(1+n)).

%F For all n >= 0, a(A277012(n)) = n.

%o (Scheme)

%o ;; Standalone iterative implementation:

%o (define (A277011 n) (let loop ((s 0) (n n) (r 0) (i 2) (f 1)) (cond ((zero? n) (+ s (* r f))) ((even? n) (loop (+ s (* r f)) (/ n 2) 0 (+ 1 i) (* i f))) (else (loop s (/ (- n 1) 2) (+ 1 r) i f)))))

%Y Left inverse of A277012.

%Y Cf. A005940, A276075.

%Y Cf. also A277007.

%K nonn,base

%O 0,3

%A _Antti Karttunen_, Sep 25 2016

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified July 23 01:22 EDT 2024. Contains 374544 sequences. (Running on oeis4.)