Add indices support for giving the from/to point

Now the from/to points can be given by one or a list of indices points
in the molecules.