I am somewhat confused about how to determine the range of an attack. In PHB p. 191, one finds a "Creature Size" table, which determines the space a creature controls in combat in function of its size. What influence does this have upon calculating ranges (if any)?
Do I calculate the distance between the centers of the spaces occupied by the attacker and the target? Or should I regard these spaces as solid squares/boxes and use the minimal distance between any two points of them? Or something else?
For example, let's say Bob (a fictitious Human Fighter) has a reach of 5 ft. and wants to smack a nearby goblin with his axe. The center of the space occupied by the goblin is 8 ft. away from Bob's. For simplicity let's also assume Bob and the goblin's 5 by 5 ft. spaces are perfectly aligned with each other; i.e., if we trace a line between the center of Bob's space and the goblin's, then this line is perpendicular to the squares' edges.
If we measure the range as the distance between the centers of the two squares, then the attack is out of range. However if we use the distance between any point in the two squares, or the distance between the squares' nearest edges, then the range is 8 - 2.5 - 2.5 = 3 ft., and the attack is a hit (if Bob's attack roll is good). Which is correct in this situation?
Since grids are only a variant rule in 5e, this question disregards the use of one. You may mention grids in your answer, but please make sure to include how to calculate ranges without them.