%I #5 Mar 30 2012 18:50:38
%S 0,0,0,0,1,0,0,0,1,1,0,0,1,1,1,0,0,1,1,0,0,0,1,0,1,1,1,1,1,1,1,1,0,0,
%T 0,1,2,1,1,1,2,1,1,1,2,1,0,0,0,1,1,1,1,1,1,1,1,0,1,0,1,0,1,1,0,0,1,1,
%U 1,0,1,1,2,1,1,1,2,1,1,1,2,2,1,1,1,2,1,1,1,2,2,2,1,1,1,1,0,0,1,1,0,1
%N Number of distinct square-subwords in ternary representation of n.
%C a(n) <= A088950(n).
%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/SquarefreeWord.html">Squarefree Word</a>
%e n=125: a(125)=2 because 125 -> '11122' has 3 square-subwords: 11, 11 and 22 (11---, -11-- and ---22) and two of them are distinct.
%Y Cf. A007089.
%K nonn
%O 0,37
%A _Reinhard Zumkeller_, Oct 25 2003
|