How do I describe this simple case? [message #152] |
Thu, 28 April 2005 17:16 |
tobias
Messages: 8 Registered: April 2005
|
Junior Member |
|
|
I wish to use the infrastructure scheme to describe something very simple,
namely a set of stations and lines between these stations. Suppose I have
four stations like in the figure below:
A ------- B ------ C
/
D -----
I want it to be clear from the description that a train going from A to D
have to reverse in B, while a train from A to C doesn't.
After studying the nifty example file (DemoNet), it is clear that this
scheme can describe very complex things, but I am unsure how to describe
this simple case. This is how far I have got:
- Stations need to be entered as operationControlPoints (ocps).
- The only way to reference an ocp is through the crossSection element.
- The crossSection element has an attribute called "dir" which is
described as "Direction validity of element". I don't understand this, but
it is the only way I have found to specify in which "end" of the station
the line starts or stops.
Given this, I defined the direction "up" to be to the right in my figure
and tried the implementation below. I described each line as going from
one ocp to another and consisting of a single track. I used the mainDir
attribute to specify which way the trains can travel, although I am not
certain this is the correct way to use this attribute. For the
pos-attribute I said that a line starts at 0.0 and ends at 1.0.
Can someone please tell me if I am on the right track here (no pun
intended).
<railml>
<infrastructure>
<operationControlPoints>
<ocp ocpID="A"/>
<ocp ocpID="B"/>
<ocp ocpID="C"/>
<ocp ocpID="D"/>
</operationControlPoints>
<lines>
<line lineID="AB">
<tracks>
<track trackID="1" mainDir="both">
<trackTopology>
<trackBegin>
<bufferStop elemID="StartTrack1" pos="0.0"/>
</trackBegin>
<trackEnd>
<bufferStop elemID="EndTrack1" pos="1.0"/>
</trackEnd>
<crossSections>
<crossSection pos="0.0" dir="up" ocpIDRef="A"/>
<crossSection pos="1.0" dir="down" ocpIDRef="B"/>
</crossSections>
</trackTopology>
</track>
</tracks>
</line>
<line lineID="BC">
<tracks>
<track trackID="1" mainDir="both">
<trackTopology>
<trackBegin>
<bufferStop elemID="StartTrack1" pos="0.0"/>
</trackBegin>
<trackEnd>
<bufferStop elemID="EndTrack1" pos="1.0"/>
</trackEnd>
<crossSections>
<crossSection pos="0.0" dir="up" ocpIDRef="B"/>
<crossSection pos="1.0" dir="down" ocpIDRef="C"/>
</crossSections>
</trackTopology>
</track>
</tracks>
</line>
<line lineID="BD">
<tracks>
<track trackID="1" mainDir="both">
<trackTopology>
<trackBegin>
<bufferStop elemID="StartTrack1" pos="0.0"/>
</trackBegin>
<trackEnd>
<bufferStop elemID="EndTrack1" pos="1.0"/>
</trackEnd>
<crossSections>
<crossSection pos="0.0" dir="down" ocpIDRef="B"/>
<crossSection pos="1.0" dir="up" ocpIDRef="D"/>
</crossSections>
</trackTopology>
</track>
</tracks>
</line>
</lines>
</infrastructure>
</railml>
|
|
|
Re: How do I describe this simple case? [message #153 is a reply to message #152] |
Wed, 04 May 2005 13:45 |
Matthias Hengartner
Messages: 57 Registered: August 2003
|
Member |
|
|
Hello,
> I wish to use the infrastructure scheme to describe something very simple,
> namely a set of stations and lines between these stations. Suppose I have
> four stations like in the figure below:
>
> A ------- B ------ C
> /
> D -----
>
> I want it to be clear from the description that a train going from A to D
> have to reverse in B, while a train from A to C doesn't.
>
> After studying the nifty example file (DemoNet), it is clear that this
> scheme can describe very complex things, but I am unsure how to describe
> this simple case. This is how far I have got:
>
> - Stations need to be entered as operationControlPoints (ocps).
> - The only way to reference an ocp is through the crossSection element.
> - The crossSection element has an attribute called "dir" which is
> described as "Direction validity of element". I don't understand this, but
> it is the only way I have found to specify in which "end" of the station
> the line starts or stops.
hmm, AFAIK the "dir"-attribute of <crossSection> has no meaning (please
correct me if I'm wrong). I think that <crossSection> is "only" used for the
assignment of a <track> to an <ocp>.
Below I have a possible way to describe your case. Please note that there is
no explicit description of how to get e.g. from A to D, but it can be
figured out (computed) implicitly by means of <crossSection>-, <switch>- and
<connection>-element and their attributes (in particular "orientation" of
<switch>).
[This information is kind of a higher-level topology-information, which has
to be computed out of the detailed topology-information. Perhaps it makes
sense to discuss about a possibility to integrate such higher-level
information about the topology in a future version of the schema].
Best regards,
Matthias Hengartner
(see also the graphical representation of this topology:
http://matthias.theband.ch/railml/crossSections.jpg)
<infrastructure>
<lines>
<line lineID="line1">
<tracks>
<track trackID="track1">
<trackTopology>
<trackBegin>
<bufferStop pos="0.0" elemID="startTrack1"/>
</trackBegin>
<trackEnd>
<bufferStop pos="3.0" elemID="endTrack1"/>
</trackEnd>
<connections>
<switch pos="1.0" elemID="switch1">
<connection orientation="incoming" connectionID="con1"
branchIDRef="con2" branchTrackIDRef="track2"/>
</switch>
</connections>
<crossSections>
<crossSection pos="0.5" ocpIDRef="A"/>
<crossSection pos="1.5" ocpIDRef="B"/>
<crossSection pos="2.5" ocpIDRef="C"/>
</crossSections>
</trackTopology>
</track>
<track trackID="track2">
<trackTopology>
<trackBegin>
<simpleConnection pos="0" elemID="startTrack2">
<connection connectionID="con2" branchIDRef="con1"
branchTrackIDRef="track1"/>
</simpleConnection>
</trackBegin>
<trackEnd>
<bufferStop pos="1.0" elemID="endTrack2"/>
</trackEnd>
<crossSections>
<crossSection pos="0.5" ocpIDRef="D"/>
</crossSections>
</trackTopology>
</track>
</tracks>
</line>
</lines>
<operationControlPoints>
<ocp ocpID="A"/>
<ocp ocpID="B"/>
<ocp ocpID="C"/>
<ocp ocpID="D"/>
</operationControlPoints>
</infrastructure>
--
****************************
Matthias Hengartner
IVT ETH Zürich
hengartner(at)ivtbaugethzch
++ 41 44 633 68 16
****************************
|
|
|