Looking for assistance with a tsp library file in JavaScript. The specific file, named file1.tsp, contains the following data:
NAME: a280
COMMENT: drilling problem (Ludwig)
TYPE: TSP
DIMENSION: 280
EDGE_WEIGHT_TYPE: EUC_2D
NODE_COORD_SECTION
1 288 149
2 288 129
3 270 133
4 256 141
5 256 157
6 246 157
7 236 169
8 228 169
9 228 161
10 220 169
11 212 169
12 204 169
13 196 169
14 188 169
15 196 161
16 188 145
17 172 145
18 164 145
EOF
The goal is to extract the numbers and organize them into arrays as follows:
node =[1,2,3,4,...]
x=[288,288,...]
y=[149,129,...]
If anyone is able to provide guidance on how to achieve this, your help would be greatly appreciated. Thanks in advance!