There is an entire practice around this question. SLAM or Simultaneous Location And Mapping (http://openslam.org
) is the practice of identifying where you are within an environment, and mapping it for future use.
That said, a lot relies on the sensors you are using. One inch granularity was my goal as well, but I was only using Maxsonar sensors and infrared distance sensors. You could get pretty good distance measurements by sample averaging, but unless the room was very small, and you could see both from and back or left and right walls simultaneously then you have to add odometer to your wheels.
Odometer in and of itself also poses problems. Wheel slip, encoder ticks missed for various reasons, turning which induces more ticks on one side than the other....
From what I've read, you really need good laser range finders to map out your environment for that level of granularity.
I actually moved away from my one inch resolution goal. My rover is 13 inches in length. It is good enough to know where it is within 1/4 of its length or roughly 3inches.
Anyway, best of luck.