I have the following problem:
Suppose that we have several points that cover some cities, with a cost associated to each point. This can be represented as a grid:
c1 c2 c3 c4 c5 cost
p1 1 0 1 0 1 200
p2 1 1 1 0 0 100
p3 0 1 0 1 1 300
...
etc. Where $c_n$ represents a city, and $p_m$ a point that connects the cities marked with $1$. Each point has a cost associated. My question is how to select those points in a way that they cover all the cities with minimum cost. If there is not a selection of points, the algorithm should inform about it.