Main Menu

News:

Please be aware of the Forum Rules of Conduct.

Caravans - what is the logic for allowed routes?

Started by Jens Namtrah, August 16, 2011, 09:58:29 AM

Previous topic - Next topic

Anaris

Quote from: Jens Namtrah on August 17, 2011, 06:50:50 AM
The calculations bit has to do with the Dykstra algorithm used in the travel code, to find the shortest route. It uses a lot of resources to test all the variable paths for time AND distance; these generally need to be rerun each time, because so many things can affect the routes' times even from turn to turn.

And it doesn't help that each step along the way needs to hit the database, to find out which regions are adjacent.
Timothy Collett

"The only thing you can't trade for your heart's desire...is your heart." "You are what you do.  Choose again, and change." "One of these days, someone's gonna plug you, and you're going to die saying, 'What did I say? What did I say?'"  ~ Miles Naismith Vorkosigan

^ban^

Quote from: Pelgart on August 17, 2011, 03:32:51 PM
stuff

As a networking student, I find this post adorable. The specific algorithms used by the various routing protocols are largely useless to us. Terms such as link-state have no real application in BM terminology unless we take the time to track region changes.

Quote
Sorry. I could not help it. It never dawned on me that computing the patch between regions in BattleMaster would be a lot like computing paths between routers in a network. Sounds like BM has it's own link-state routing protocol. Who would have guessed!

Both problems fall under the subset of graphing solutions. There are many, many other places where such problems arise. If you're a networking student of some sort and are interested in these sorts of things, you should start reading about graph theory.
Born in Day they knew the Light; Rulers, prophets, servants, and warriors.
Life in Night that they walk; Gods, heretics, thieves, and murderers.
The Stefanovics live.