For your convenience, GiNaC offers the container template exhashmap<T>
that can be used as a drop-in replacement for the STL
std::map<ex, T, ex_is_less>, using hash tables to provide faster,
typically constant-time, element look-up than map<>.
exhashmap<> supports all map<> members and operations, with the
following differences:
lower_bound() and upper_bound() methods
rbegin()/rend()
operator<(exhashmap, exhashmap)
key_compare is hardcoded to
ex_is_less
exhashmap(size_t n) allows specifying the minimum
initial hash table size (the actual table size after construction may be
larger than the specified value)
size_t bucket_count() returns the current size of the hash
table
insert() and erase() operations invalidate all iterators