cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A256293 Apply the transformation 0 -> 1 -> 2 -> 0 to the digits of n written in base 3, then convert back to base 10.

This page as a plain text file.
%I A256293 #8 Jan 21 2019 10:40:58
%S A256293 1,2,0,7,8,6,1,2,0,22,23,21,25,26,24,19,20,18,4,5,3,7,8,6,1,2,0,67,68,
%T A256293 66,70,71,69,64,65,63,76,77,75,79,80,78,73,74,72,58,59,57,61,62,60,55,
%U A256293 56,54,13,14,12,16,17,15
%N A256293 Apply the transformation 0 -> 1 -> 2 -> 0 to the digits of n written in base 3, then convert back to base 10.
%C A256293 Base 3 variant of A035327 (base 2) and A048379 (base 10).
%C A256293 See A256294 - A256299 for bases 4 through 9, and A256303 for the variant where the result is not converted back to base 10.
%e A256293 a(3) = 7 because 3 = 10[3] becomes 21[3] = 7.
%e A256293 a(8) = 0 because 8 = 22[3] becomes 00[3] = 0.
%t A256293 Table[FromDigits[IntegerDigits[n,3]/.{0->1,1->2,2->0},3],{n,0,100}] (* _Harvey P. Dale_, Jan 21 2019 *)
%o A256293 (PARI) A256293(n,b=3)=!n+apply(t->(t+1)%b,n=digits(n,b))*vector(#n,i,b^(#n-i))~
%K A256293 nonn,base,easy
%O A256293 0,2
%A A256293 _M. F. Hasler_, Mar 22 2015