Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.
%I #3 Mar 30 2012 18:50:38
%S 1,0,0,1,0,0,1,1,1,0,0,0,1,2,1,2,2,0,0,1,1,1,0,2,1,1,0,0,1,0,1,1,1,2,
%T 0,2,0,2,1,1,1,0,1,0,1,0,0,0,1,2,2,2,1,1,0,1,2,1,1,1,1,1,1,0,0,1,1,0,
%U 2,2,1,0,0,0,0,1,1,2,1,2,1,0,0,1,1,0,2,2,0,0,0,2,1,1,0,0,1,2,0,0,1,1
%N Value of n-th digit in ternary representation of n^n.
%C a(n)=d(n) with n^n = Sum(d(k)*3^k: 0<=d(k)<3, k>=0).
%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/Ternary.html">Ternary</a>
%F a(n) = floor(n^n / 3^n) mod 3.
%e n=7, 7^7=3110367 -> '1112211200121', '111221-------': a(7)=1.
%Y Cf. A007089, A000312, A088150, A088152, A088153, A088154, A088155, A088156, A088157.
%K nonn,base
%O 0,14
%A _Reinhard Zumkeller_, Sep 20 2003