login
Permutation of nonnegative integers: a(n) = A013928(A019565(n)).
5

%I #31 Jul 04 2018 20:22:36

%S 0,1,2,4,3,6,10,18,5,9,13,27,22,43,64,128,7,14,20,40,33,68,100,202,47,

%T 93,143,282,232,469,702,1404,8,16,25,48,39,79,119,235,56,110,167,333,

%U 278,553,832,1660,88,175,260,520,437,872,1303,2609,608,1216,1826,3649

%N Permutation of nonnegative integers: a(n) = A013928(A019565(n)).

%C From _Antti Karttunen_, Aug 24 2014: (Start)

%C The original name of the sequence was: "Inverse of sequence A048672 considered as a permutation of the nonnegative integers".

%C However, the real inverse to A048672 is A246353(n) (= a(n)+1), satisfying A246353(A048672(n)) = n for all n. This sequence subtracts one from the terms of A246353 so as to obtain a permutation of nonnegative integers (bijection [0..] --> [0..]).

%C Sequence is obtained when the range of A019565 is compacted so that it becomes surjective, thus the logarithmic scatter plots look very similar. (Same applies to A246353.) Compare also to the plot of A005940.

%C (End)

%H Antti Karttunen, <a href="/A064273/b064273.txt">Table of n, a(n) for n = 0..478</a>

%H <a href="/index/Per#IntegerPermutation">Index entries for sequences that are permutations of the natural numbers</a>

%F From _Antti Karttunen_, Aug 24 2014: (Start)

%F a(n) = A013928(A019565(n)).

%F a(n) = A246353(n) - 1.

%F (End)

%o (PARI)

%o allocatemem(234567890);

%o default(primelimit, 2^22)

%o uplim_for_13928 = 13123111;

%o v013928 = vector(uplim_for_13928); A013928(n) = v013928[n];

%o v013928[1]=0; n=1; while((n < uplim_for_13928), if(issquarefree(n), v013928[n+1] = v013928[n]+1, v013928[n+1] = v013928[n]); n++);

%o A019565(n) = {factorback(Mat(vector(if(n, #n=vecextract(binary(n), "-1..1")), j, [prime(j), n[j]])~))}; \\ _M. F. Hasler_

%o A064273(n) = A013928(A019565(n));

%o for(n=0, 478, write("b064273.txt", n, " ", A064273(n))); \\ _Antti Karttunen_, Aug 23 2014

%o (Scheme) (define (A064273 n) (let loop ((n n) (i 1) (p 1)) (cond ((zero? n) (- (A013928 (+ 1 p)) 1)) ((odd? n) (loop (/ (- n 1) 2) (+ 1 i) (* p (A000040 i)))) (else (loop (/ n 2) (+ 1 i) p))))) ;; _Antti Karttunen_, Aug 23 2014

%Y One less than A246353.

%Y Cf. A000040, A005940, A013928, A019565, A048672.

%K easy,nonn

%O 0,3

%A _Howard A. Landman_, Sep 23 2001

%E More terms from _Carl R. White_, Apr 19 2006

%E Name changed by _Antti Karttunen_, Aug 23 2014