square distances