def symbol_key(x)
      HTMLEntities.new.decode(x.text).gsub(/_/, ":").gsub(/`/, "").
        gsub(/[0-9]+/, "þ\\1")
    end
def symbol_key(x)
      HTMLEntities.new.decode(x.text).gsub(/_/, ":").gsub(/`/, "").
        gsub(/[0-9]+/, "þ\\1")
    end
We assume AsciiMath is being used in the terms & definitions.
 Indices sort after letter but before any following
 letter (x, x_m, x_1, xa); we use colon to force that sort order.
 Numbers sort *after* letters; we use thorn to force that sort order.