login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A091110
Number of editing steps (deletion, insertion, or substitution) to transform the binary representation of n into the ternary representation of n.
1
0, 2, 1, 2, 2, 2, 2, 4, 1, 1, 2, 1, 1, 2, 3, 4, 4, 3, 3, 4, 3, 3, 4, 4, 4, 5, 3, 3, 3, 2, 2, 4, 3, 3, 4, 2, 2, 4, 3, 4, 4, 3, 3, 4, 4, 4, 5, 4, 4, 4, 4, 4, 5, 4, 4, 4, 4, 4, 4, 5, 5, 6, 5, 6, 6, 5, 5, 6, 6, 6, 6, 5, 5, 6, 5, 5, 6, 6, 6, 7, 2, 2, 3, 2, 2, 3, 4, 4, 4, 2, 2, 3, 2, 2, 3, 4, 4, 5, 4, 4, 4, 3
OFFSET
1,2
COMMENTS
a(A091111(n))=n and a(m)>n for m>A091111(n).
LINKS
Michael Gilleland, Levenshtein Distance [It has been suggested that this algorithm gives incorrect results sometimes. - N. J. A. Sloane]
Eric Weisstein's World of Mathematics, Binary
Eric Weisstein's World of Mathematics, Ternary
FORMULA
a(n) = LevenshteinDistance(A007088(n), A007088(n)).
CROSSREFS
Sequence in context: A226942 A030371 A029550 * A339660 A104659 A077197
KEYWORD
nonn
AUTHOR
Reinhard Zumkeller, Dec 20 2003
STATUS
approved