3 ms·
> London - Paris makes sense. But 2London does not. I guess you know this, but for others: London-Paris makes sense, but has a different type to London and Par
by taejo 10y ago
> London - Paris makes sense. But 2London does not.
I guess you know this, but for others: London-Paris makes sense, but has a different type to London and Paris (it's a vector, not a position) and while 2London doesn't make sense, 2(London-Paris) does make sense (it's a vector with the same direction but twice the length).
Such a system, with two distinct types -- positions and vectors, with vectors being the differences between positions -- is called an affine space. You can identify positions with vectors by picking a distinguished origin, but then you don't get the type-safety that forbids ridiculous expressions like 2London.