%I #8 Oct 03 2024 11:03:38
%S 1,2,3,5,4,6,10,8,12,7,11,9,15,21,13,19,17,18,16,22,14,20,23,32,28,30,
%T 35,25,33,26,34,24,29,31,27,36,46,53,50,40,52,44,48,42,54,37,49,43,47,
%U 39,51,41,38,45,60,76,66,63,79,55,71,65,58,74,62,57,67
%N a(n) is the unique k such that A376677(k) is the reversal of A376677(n), or -1 if no such k exists.
%C Is this sequence a permutation of the positive integers?
%H Rémy Sigrist, <a href="/A376686/b376686.txt">Table of n, a(n) for n = 1..10304</a>
%H Rémy Sigrist, <a href="/A376686/a376686.gp.txt">PARI program</a>
%H <a href="/index/K#Kolakoski">Index entries for sequences related to Kolakoski sequence</a>
%e The first terms, alongside the corresponding terms of A376677, are:
%e n a(n) A376677(n) A376677(a(n))
%e -- ---- ---------- -------------
%e 1 1 1 1
%e 2 2 2 2
%e 3 3 11 11
%e 4 5 12 21
%e 5 4 21 12
%e 6 6 22 22
%e 7 10 112 211
%e 8 8 121 121
%e 9 12 122 221
%e 10 7 211 112
%e 11 11 212 212
%e 12 9 221 122
%e 13 15 1121 1211
%e 14 21 1122 2211
%e 15 13 1211 1121
%e 16 19 1212 2121
%o (PARI) \\ See Links section.
%Y Cf. A000002, A376677, A376685.
%K nonn,base
%O 1,2
%A _Rémy Sigrist_, Oct 01 2024