Use Cases > PTV xDima > How to Import and Export a Distance Matrix

How to Import and Export a Distance Matrix

In addition to modifying single entries in a distance matrix, it is also possible to import complete distance matrices from external sources to use them in PTV products. Similarly, in addition to requesting single distances and driving periods, it is also possible to export complete distance matrices that can be used by other systems without the need to access PTV xDima Server.

An external distance matrix consists of two files. One file contains the locations and the other file the distance table. There are two folders for the data exchange provided:

The possible data format of these files binary or text (ASCII) is described below.

Format Description of the Binary File Format

The file format of the binary location file is defined as follows:

The file format of the binary distance table file is defined as follows:

The following possible error values are stored in the distance part of a distance table entry:

  1. The route between the locations is not calculated yet.

  2. The route between the locations could not been found.

Format Description of the Text File Format

The file format of the text location file is defined as follows:

The file format of the text distance table file is defined as follows:

The following possible error values are stored in the distance part of a distance table entry: