checked all distance functions; they work!, jay!