%I #22 Nov 27 2015 20:49:26
%S 0,1,3,5,7,13,17,19,23,27,29,31,35,37,41,43,51,53,57,59,61,65,67,71,
%T 73,77,79,143,149,151,155,157,161,163,173,177,179,181,185,191,193,199,
%U 203,209,211,215,219,223,231,233,237,239,241,249,251,263,267,269,271,277,285,291,293,299,303,315,317,321,327,331,335,337,341,347,349,357,359,369,515
%N a(n) = least k such that A155043(k) = n; positions of records in A155043.
%C Note that there are even terms besides 0, and they all seem to be squares: a(915) = 7744 (= 88^2), a(41844) = 611524 (= 782^2), a(58264) = 872356 (= 934^2), a(66936) = 1020100 (= 1010^2), a(95309) = 1503076 (= 1226^2), a(105456) = 1653796 (= 1286^2), ...
%H Antti Karttunen, <a href="/A261089/b261089.txt">Table of n, a(n) for n = 0..110880</a>
%F Other identities. For all n >= 0:
%F A155043(a(n)) = n.
%t lim = 80; a[0] = 0; a[n_] := a[n] = 1 + a[n - DivisorSigma[0, n]]; t = Table[a@ n, {n, 0, 12 lim}]; Table[First@ Flatten@ Position[t, n] - 1, {n, 0, lim}] (* _Michael De Vlieger_, Sep 29 2015 *)
%o (PARI)
%o allocatemem(123456789);
%o uplim = 2162160; \\ = A002182(41).
%o v155043 = vector(uplim);
%o v155043[1] = 1; v155043[2] = 1;
%o for(i=3, uplim, v155043[i] = 1 + v155043[i-numdiv(i)]);
%o A155043 = n -> if(!n,n,v155043[n]);
%o n=0; k=0; while(k <= 10000, if(A155043(n)==k, write("b261089.txt", k, " ", n); k++); n++;);
%o (Scheme, with _Antti Karttunen_'s IntSeq-library, two variants)
%o (definec (A261089 n) (let loop ((k 0)) (if (= n (A155043 k)) k (loop (+ 1 k)))))
%o (define A261089 (RECORD-POS 0 0 A155043))
%o (Haskell)
%o import Data.List (elemIndex); import Data.Maybe (fromJust)
%o a261089 = fromJust . (`elemIndex` a155043_list)
%o -- _Reinhard Zumkeller_, Nov 27 2015
%Y Cf. A000005, A155043, A049820, A259934, A261103.
%Y Cf. A262503 (the last occurrence of n in A155043).
%Y Cf. A262505 (difference between the last and the first occurrence).
%Y Cf. A262507 (the number of occurrences of n in A155043).
%Y Cf also A261085, A261088.
%K nonn
%O 0,3
%A _Antti Karttunen_, Sep 23 2015
|