Group Abstract Group Abstract

Message Boards Message Boards

Possible bug in FindShortestPath[] function?

GROUPS:

Hi @ all, I finally managed to get my hands on a Raspberry Pi and try out Mathematca/Wolfram Language with examples from the Code Gallery.

Unfortunately,the "City Tour" sample (http://www.wolfram.com/language/gallery/plan-a-city-tour/) doesn't seem to work properly on the RPI. The first CityData[] command runs fine, albeit somewhat slow, but I'm not going to complain about that...

I found that FindShortestPath[] only works with up to four points (input:"FindShortestTour[{{1, 1}, {1, 2}, {1, 3}, {1, 4}}]", output:"{6, {1, 2, 3, 4, 1}}"), as soon I go up to five or higher, the return is just the input ("FindShortestTour[{{1, 1}, {1, 2}, {1, 3}, {1, 4}, {1, 5}}]").

Although I did not expect it to make a difference, I tried it both in the Mathematica notebook interface as well as in the terminal via 'wolfram'.

Does anyone have a clue how to make the function run correctly?

POSTED BY: Simon K
Answer
2 months ago

FindShortestTour uses an external library which (for the moment) is not available in the Raspberry Pi version.

For the time being, it is possible to use the Method -> "Legacy" option in FindShortestTour.

POSTED BY: Ilian Gachevski
Answer
2 months ago

Works perfectly fine, thank you!

POSTED BY: Ignacio G.
Answer
2 months ago

Ignacio, Simon,

Thank you for pointing this out.

This will be fixed shortly with an update release.

If you need this more urgently, download this file: https://download.wolfram.com/?key=9DZAYM

And place it in this file location on your Raspberry Pi: /opt/Wolfram/WolframEngine/10.0/SystemFiles/Libraries/Linux-ARM

(Note, if you do this yourself, you will need to also remove this file manually before any later upgrades, so you may just want to wait for the next release).

POSTED BY: Arnoud Buzing
Answer
2 months ago

Thank you for a) your quick answer and b) the patch, which runs very fast, especially compared to the legacy method!

POSTED BY: Simon K
Answer
2 months ago

Hello.

I just downloaded the latest upgrade and now it is working perfectly with the default method.

Thanks!

POSTED BY: Ignacio G.
Answer
2 months ago