Author Topic: Acceleration as a function of speed and convoy stats  (Read 379 times)

0 Members and 1 Guest are viewing this topic.

Offline Rollmaterial

Acceleration as a function of speed and convoy stats
« on: September 01, 2017, 11:08:32 PM »
I am trying to calculate timetables from the convoy stats alone so I was wondering if someone could help me get the acceleration. Thanks in advance!

Offline DrSuperGood

Re: Acceleration as a function of speed and convoy stats
« Reply #1 on: September 02, 2017, 12:55:06 AM »
It has been requested in the past that such metrics be displayed with a graph to allow people to visualize time until a certain speed.

In the end trying to calculate time tables is likely not going to work out as there are too many factors to consider. Start small and raise as traffic requires.

Offline Ves

Re: Acceleration as a function of speed and convoy stats
« Reply #2 on: September 02, 2017, 02:22:08 AM »
I dont know what exactly is needed to calculate acceleration, but assuming you mean from the source code, if you look in the convoy.h file, there are a bunch of entries that looks like they could be used, like get_force(), get_starting_force(), get_current_friction().
If you go to simconvoy.cc, there is also some stuff that might be usefull, like
convoi_t::route_infos_t& convoi_t::get_route_infos()
There is some times recorded and shown in the halt_detail window in halt_detail_t. You could have a look how that is compilated and pull the data to create the timetable from that.
Even in halt_info_t, there is a timetable for arriving and departing vehicles, although when I played around with it, I could not make it produce entirely consistent results.
The actual formula, I dont know but should be possible to find on google.

I dont think it is impossible to do. All the information is already in the game, it is just a matter of collecting and process the required data.