Design and implement an algorithm to find the cheapest (total sum cost) way to provide houses with water. There are given n wells and kn houses (points on plane), each well provides k houses with water, where n, k and kn are positive integers. The distance with any given two points will be calculated by Euclidean distance formula. x and y are two given points in two dimensional space. Distance between them calculated as follows:
d(x,y) = sqrt ( (x1 - x2)**2 + (y1 - y2)**2 )
1. Connect every well with k number of houses
2. Find minimum total cost
More details are in the documentations.
Hüseyin Utku ASLAN, Tou AMMAR