[
Date Prev][Date Next][
Thread Prev][Thread Next][
Date Index][
Thread Index]
[
List Home]
|
Re: [sumo-user] Vehicle Route Conconation
|
Hi Sven,
it would be rather similar to the repeated loop concept in the
sense that it is merely some parsing/generating code before the
simulation starts. I imagine this is similar to what you do now
externally.
- define / load shorter routes first
- define a new route which refers to a sequence of previously
defined routes in a special attribute "concatenate" (maybe there
is a better name)
- when parsing the route, check for the attribute
"concatenate"
- look up the referred routes, return an error if they cannot
be found or cannot be joined through the common last/first
edge
- otherwise get the edges of the routes and join, adapting
until values
Best regards,
Mirko
Am 01.07.2026 um 19:36 schrieb Sven:
Hi Mirko,
thank you for your response.
Im afraid looping and flows are not suited for my goal of
simulating persistent vehicles operating accoarding
to multi-line schedules.
Your Idea for a "conconation" attribute however sounds
very interesting.
How would that work? Could you elaborate on that?
If there is a way for me to implement a functionality like
that myself, id be very willing to put in the time.
Best regards
Sven
-------- Original Message --------
On Wednesday, 07/01/26 at 19:26 Mirko Barthauer via sumo-user
<sumo-user@xxxxxxxxxxx> wrote:
Hi Sven,
AFAIK there is currently no such thing like creating a new
route from 2+ arbitrary route building blocks internally or
even keeping a list of routes to take one after another. As
it seems just another way of defining routes, this may be
possible to implement. I'd rather define a new attribute
"concatenate" where the building blocks can be put so there
is no confusion whether there are routes and edges of the
same name.
However if you have bus services repeatedly serving the
same line (both directions), you can make it a looped route
(see docs). That
way you can define it once and then set the repeat attribute
(which internally will make sumo copy the route edges).
Best regards,
Mirko
Am 01.07.2026 um 17:40 schrieb
Sven via sumo-user:
Dear
SUMO-Community,
my
name is Sven, ive written here before, a few weeks ago. I
have since continued to work on a project concerning the
charging behaviour of electric buses.
Many
thanks to Moritz Schweppenhäuser, i really like your work
and your scenario is very helpful to me.
However,
i seem to have hit a blockade within my own approach of
simulating.
While
SUMO provides routes, flows and some interaction via
TraCI, there seems to be no supported way of having
vehicles use what id call "modular routes".
For
my bus-simulation, it would be ideal to have vehicles
perform their service one route after another, by
providing a list of pre-defined routes, to then have a vehicle perform multiple of these, one after another:
<routes> <vType id="bus" vClass="bus"/>
<route id="161_A" color="" edges="A B C">
<stop busStop="X1" duration="20.0" until="20.0" parking="true"/>
<stop busStop="X2" duration="20.0" until="80.0" parking="true"/>
</route>
<route id="161_B" color="" edges="C D E">
<stop busStop="X3" duration="20.0" until="20.0" parking="true"/>
<stop busStop="X4" duration="20.0" until="80.0" parking="true"/>
</route>
</routes>
<routes>
<vType id="type1" accel="0.8" decel="4.5" sigma="0.5" length="5" maxSpeed="70"/>
<vehicle id="0" type="type1" route="161_A 161_B" depart="0" color="1,0,0"/>
<vehicle id="1" type="type1" route="161_B 161_A" depart="0" color="0,1,0"/>
</routes>
My current plan is to generate new routes from these partial-routes beforehand, but this requieres a lot of effort, of calculating possible combinations, and "until" values, for potentially many hundred routes.
I am therefore asking, wether there are more convinient ways to achive what im planning, or if such a feature could potentially be implemented sometime.
Best
regards
Sven
_______________________________________________
sumo-user mailing list
sumo-user@xxxxxxxxxxx
To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/sumo-user