Add support for 0-based partition IDs

Initial goal is to allow user commands to specify partition IDs as short integers `[0, ring_size)` instead of hash values. May consolidate other features such as Yokozuna's logical partitions later.
a few comments about this function:

1. I think it would be better if it lived in `riak_core_ring`. Then it could properly check that the only tuple its getting is the `riak_core_ring` record. As this function stands calls like `hash_to_partition_id(0, {something, that, is, not, a, ring})` will crash despite the function guards. 
2. Instead of throwing a custom function, we should just rely on erlang's support for partial functions and the error thrown there
3. I initially assumed we were only building this function w/ the assuming that the index passed in was a vnode identifier (a specific subset of hashes). Having it support for is probably better, since there is no way to nicely enforce what integers can be passed it, just curious why you decided to extend the scope?