faq 109100389 - matsim-org/matsim-code-examples GitHub Wiki
by Daniele Miranda on 2017-04-26 16:00:27
Hello,
I am running a simulation in MATSim 8.0.1 and I am using the free version of VIS to visualise outputs. I started with TUB Tutorial and I made some modifications in the original CreateDemand class in order to create my own demand. The point is: the output I get from MATSim shows vehicles travelling very slow! Not even close to the link freespeed I've set. In addition, travel lengths shown are way longer than correct. A trip that should take about 6km is shown as taking over 300km!!
I tried the following analysis already:
- I chose an agent to follow in VIS simulation. Acording to its plan, it should have taken 17 hours to complete its trip, but VIS shows it arriving in less than 3 hours (I checked the route taken in VIS and it is exaclty the one shown in the plan);
- I checked units, everything is fine: flow capacity is given in vehicles/lane/hour, link speed in m/s;
- I also checked Geographic Coordinates, everything is UTM 23S.
- Following agens in VIA simulation, I checked that they travel faster on 60km/h links that have 3 lanes than on 80km/h links that have only 1 lane. However, none of the travel speeds seem correct.
I have absolutely no idea why vehicles are traveling so slow. Does anybody have a guess?
Thank you very much,
Daniele Miranda,
University of Brasilia, Brazil.
by Kai Nagel on 2017-04-27 16:13:41
From the hip, it looks like a unit mismatch. MATSim will always take link lengths and link speeds from the link data, so the distance in coordinates does not matter. So if your link is 300'000 (= 300km) long, and you have a link speed of, say, 30 (m/s), then it will take 300'000/30=10'000sec to traverse the link. If, however, the coordinates of the toNode and fromNode of the link are only 6km apart, this will look very slow in the visualizer.