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!)
A366796 Lexicographically earliest infinite sequence such that a(i) = a(j) => A366795(i) = A366795(j) for all i, j >= 0. 3

%I #6 Oct 26 2023 13:22:24

%S 1,2,3,1,4,5,1,2,6,7,8,3,1,2,3,1,5,8,9,4,10,11,4,5,1,2,3,1,4,5,1,2,12,

%T 13,10,6,11,14,6,7,14,15,16,8,6,7,8,3,1,2,3,1,4,5,1,2,6,7,8,6,1,2,3,1,

%U 7,17,18,5,19,15,5,8,20,21,22,9,5,8,9,4,23,22,24,10,25,25,10,11,5,8,9,4,10,11,4,5,1

%N Lexicographically earliest infinite sequence such that a(i) = a(j) => A366795(i) = A366795(j) for all i, j >= 0.

%C Restricted growth sequence transform of A366795.

%H Antti Karttunen, <a href="/A366796/b366796.txt">Table of n, a(n) for n = 0..65537</a>

%o (PARI)

%o up_to = 65537;

%o rgs_transform(invec) = { my(om = Map(), outvec = vector(length(invec)), u=1); for(i=1, length(invec), if(mapisdefined(om,invec[i]), my(pp = mapget(om, invec[i])); outvec[i] = outvec[pp] , mapput(om,invec[i],i); outvec[i] = u; u++ )); outvec; };

%o A001615(n) = if(1==n,n, my(f=factor(n)); prod(i=1, #f~, f[i, 1]^f[i, 2] + f[i, 1]^(f[i, 2]-1))); \\ After code in A001615

%o A005940(n) = { my(p=2, t=1); n--; until(!n\=2, if((n%2), (t*=p), p=nextprime(p+1))); (t); };

%o A344695(n) = gcd(sigma(n), A001615(n));

%o A366795(n) = A344695(A005940(1+n));

%o v366796 = rgs_transform(vector(1+up_to,n,A366795(n-1)));

%o A366796(n) = v366796[1+n];

%Y Cf. A005940, A344695, A366795.

%Y Cf. also A366802, A366805.

%K nonn

%O 0,2

%A _Antti Karttunen_, Oct 26 2023

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 May 12 03:46 EDT 2024. Contains 372431 sequences. (Running on oeis4.)