Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[sumo-user] how to modify /add vType in original trips.xml

Hi, everyone
There is a problem that I would like to ask for your help! Appreciate in advance!
If the definition of the type like below:

http://sumo.dlr.de/wiki/Definition_of_Vehicles,_Vehicle_Types,_and_Routes
  
<routes>
    <vTypeDistribution id="typedist1">
        <vType id="passenger2a" accel="0.8" length="5" maxSpeed="70" probability="0.9"/>
        <vType id="passenger2b" accel="1.8" length="15" maxSpeed="50" probability="0.1"/>
    </vTypeDistribution>
</routes>


How to let the type defined for every vehicle in the route.xml to fit the distribution? For example
If we have the OD matrix? Or we  have already had a trip.xml and we would like to define two different types of vehicle with the vType  above, how to modify the original trips.xm? 
 <vehicle id="randUni18368:1" type="passenger2a" depart="0.00" departPos="random" departSpeed="0.00" arrivalPos="random" arrivalSpeed="0.00">
        <route edges="-31606#0 -31606#1 --31634 --30768#1 --30768#0 -31230#2 -32628 --31272#2 --31272#1 --31272#0 -30528#21 -30528#22 -30528#23 -30528#24 -30528#25 -30528#26 -30528#27 -30528#28 -30528#29 -30528#30 -31888#0 -31888#1 -30496#4"/>
    </vehicle>

    <vehicle id="randUni834:1" type="passenger2b" depart="5.00" departPos="random" departSpeed="0.00" arrivalPos="random" arrivalSpeed="0.00">
        <route edges="--32406#3 --32406#2 --32406#1 --31212"/>
    </vehicle>

Best regards!

Jane

Back to the top