Added document reordering and inverse mapping

added the document weights to the index. also added calculating
the document length as weights if no document mapping file is specified
during constrution. the correct document ids are now also "remapped"
after the search process to return the correct result.