private void GenerateMap()
{
Random rand = new Random((int)DateTime.Now.Ticks);
// create coordinates array
map = new double[citiesCount, 2];
for (int i = 0; i < citiesCount; i++)
{
map[i, 0] = rand.Next(1001);
map[i, 1] = rand.Next(1001);
}
// set the map
chart.UpdateDataSeries("cities", map);
// erase path if it is
chart.UpdateDataSeries("path", null);
}