The actual miles are used in the MPM calculation. You also need to check the routing for the fare, but usually you can connect through almost any United city as long as the stop is less than 24 hours. I would imagine that SFO-LAX-DEN-ORD-IAD-LHR would work. You also need to make sure that there is no limit for online transfers (that's the number of connections from United to United that you are permitted to make.) I think it will be unlimited as long as it's online United, but sometimes the fare rules will say the likes of 2 in each direction.
------------------
sftrvlr