a(n)=(1/2)*Sum{|d(i)-e(i)|} where Sum{d(i)*6^i} is the base 6 representation of n and e(i) are the digits d(i) in nondecreasing order.

A037883

a(n)=(1/2)*Sum{|d(i)-e(i)|} where Sum{d(i)*6^i} is the base 6 representation of n and e(i) are the digits d(i) in nondecreasing order.

Terms

    a(0) =0a(1) =0a(2) =0a(3) =0a(4) =0a(5) =0a(6) =0a(7) =1a(8) =2a(9) =3a(10) =4a(11) =0a(12) =0a(13) =0a(14) =1a(15) =2a(16) =3a(17) =0a(18) =0a(19) =0a(20) =0a(21) =1a(22) =2a(23) =0a(24) =0a(25) =0a(26) =0a(27) =0a(28) =1a(29) =0

External references