I need to efficiently calculate the euclidean weighted distances for every x,y point in a given array to every other x,y point in another
x,y
You could try removing the square root, since if a>b, it follows that a squared > b squared... and computers are REALLY slow at square roots normally.