Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[sumo-user] How to modell sharp turns of long vehicles that need a hole in the opposing trafic

Hi,

I need to model a truck not being able to do a right turn on a sharp corner
(160° turn) while traffic blocks the opposing lane. A small example, which
might help to clearify things:

test.nod.xml:
<nodes>
  <node id="n1" x="0" y="0"/>
  <node id="n2" x="0" y="50"/>
  <node id="n3" x="200" y="0"/>
  <node id="n4" x="400" y="0"/>
</nodes>

test.edg.xml:
<edges>
  <edge id="e1a" from="n1" to="n3" speed="4" width="2.5"/>
  <edge id="e1b" from="n3" to="n1" speed="4" width="2.5"/>
  <edge id="e2a" from="n2" to="n3" speed="4"/>
  <edge id="e3a" from="n3" to="n4" speed="4"/>
  <edge id="e3b" from="n4" to="n3" speed="4"/>
</edges>

test.rou.xml:
<routes>
  <vType id="c1" guiShape="passenger"/>
  <vType id="c2" guiShape="truck" length="10"/>
  <route id="r1" edges="e1a e3a"/>
  <route id="r2" edges="e2a e1b"/>
  <flow id="v1" begin="0" end="7200" period="1" type="c1" route="r1"/>
  <vehicle id="v0" depart="35" route="r2" type="c2"/>
</routes>

In this example the truck just turns, without regarding the stream of cars on
the opposing lane. (Visually the back of the truck moves outside of the road
(in step 85).)

While searching for a solution for this, I found the prohibition-tag, adding
test.con.xml:

<connections>
  <prohibition prohibitor="e1a->e3a" prohibited="e2a->e1b"/>
</connections>

This works partially: The truck stops for a while.

But:
a) After some time it moves on, although there are still opposing cars.
b) All other vehicles having to do this turn stop too, even when short enough.

Does anyone know a good solution to this problem?

Yours, Bernhard Seckinger

--
Bernhard Seckinger <bernhard.seckinger@xxxxxxxxxx>


Back to the top