SetDirectory["~/www/cp/src_free"];

sr[str_]:=Module[{f,r},
	f = StringToStream[str];
	r = ReadList[f,Number];
	Close[f];
	r
]

data = Flatten[ReadList["berlin52.tsp",String,RecordLists->True]];
a = Position[data,"NODE_COORD_SECTION"][[1,1]]+1;
e = Position[data,"EOF"][[1,1]]-1;

points = Take[#,-2]& /@ (sr /@ Take[data,{a,e}]);

data = Flatten[ReadList["berlin52.opt.tour",String,RecordLists->True]];
a = Position[data,"TOUR_SECTION"][[1,1]]+1;
e = Position[data,"EOF"][[1,1]]-1;

opt = Append[#,#[[1]]]&[Drop[Flatten[sr /@ Take[data,{a,e}]],-1]];

anneal = Append[#,#[[1]]]&[Take[#,-2]& /@ ReadList["travel.dat",Number,RecordLists->True]];

Show[ListPlot[anneal,PlotJoined->True,PlotStyle->{RGBColor[0,0,0],Thickness[0.005]},DisplayFunction->Identity],ListPlot[(points[[#]]& /@ opt),PlotJoined->True,PlotStyle->{RGBColor[0,1,0]},DisplayFunction->Identity],
ListPlot[points,PlotStyle->{RGBColor[1,0,0]},DisplayFunction->Identity],
DisplayFunction->$DisplayFunction,AspectRatio->1];