Dev:Reversing trains and formations: Difference between revisions

From railML 2 Wiki
Jump to navigation Jump to search
[checked revision][checked revision]
mNo edit summary
(Update to railML 3)
Line 1: Line 1:
This article explains basic concepts, how to handle reversing trains and formations within the timetable subschema.
This article explains basic concepts of handling formation orientation within the timetable subschema.


{{deu|Dieser Artikel erklärt Grundlagen des Umganges mit Richtungsänderungen von zügen innerhalb des Timetable-Subschemas.}}
{{deu|Dieser Artikel erklärt die grundlegenden Konzepte des Umgangs mit der Fahrtrichtung von Zügen im Timetable-Subschema.}}
== Reversing trains and formations ==
== Reversing trains and formations ==


In the {{TT:Tag|timetable}} scheme, there are two attributes concerning the turn of the running direction of a train, train part and/or formation: {{TT:Tag|ocpTT}}.{{Attr|trainReverse}} and {{TT:Tag|formationTT}}.{{Attr|orientationReversed}}. They seem to be redundant and may possibly be mixed. This shall try to explain the difference of both:
In the {{TT:Tag|timetable}} scheme, there are two elements or attributes concerning the running direction of a train formation: {{TT:Tag|activityTrainReverse}} and {{TT:Tag|formationInformation}}.{{Attr|orientationReversed}}. They may seem to be redundant and may possibly be mixed. This shall try to explain the difference between the two:


=== Concerning the meaning of {{TT:Tag|ocpTT}}.{{Attr|trainReverse}} ===
=== Concerning the meaning of {{TT:Tag|activityTrainReverse}}===
   
   
It simply tells that the train(part) changes the direction - no matter whether the formation changes, reverses or neither of both.<br>
This indicates that the train (part) changes its running direction at the parent base itinerary point. It includes all operational actions that may be necessary to do so. Examples are:
* trainReverse with change of formation = e. g. running around with the engine, also known as [https://en.wikipedia.org/wiki/Headshunt headshunt]<br>
 
* trainReverse with reversing of formation = train(part) of several MUs or push-pull train<br>
* reversal with identical formation, but in reversed order (if it has more than one vehicle) and vehicle orientation (if it is given).
* trainReverse with neither of them = train(part) consists of a single vehicle (MU or engine)<br>
* reversal with the engine coupled to the other end of the formation, also known as [[wikipedia:Headshunt|run-around]].
* reversal with a different engine coupled to the other end of the formation.
 
This information is mainly intended for passenger information (systems). Some systems may, for example, show a ↔ symbol where the running direction of the train changes.
   
   
This information is mainly intended for passenger information (systems) which sometimes print a sign like <nowiki><-></nowiki> to notify the passenger where the running direction of the train changes.
=== Concerning the meaning of {{TT:Tag|formationInformation}}.{{Attr|orientationReversed}} ===
This has nothing to do with a train changing the running direction. It merely avoids the necessity of creating reversed copies of formations that run in both directions. Instead, a formation reference with {{TT:Tag|formationInformation}}.{{Attr|orientationReversed}} set to <code>true</code> is equivalent to a reference to a formation with all identical properties except for:
=== Concerning the meaning of {{TT:Tag|formationTT}}.{{Attr|orientationReversed}} ===
 
* the {{RS:Tag|trainOrder}}.{{Attr|orderNumber}} are in reversed order.
It has nothing to do with a train changing the running direction. It simply shall avoid the necessity to create each formation two times for both orientations. A train does not need to change its running direction for {{TT:Tag|formationTT}}.{{Attr|orientationReversed}}:
* the {{RS:Tag|trainOrder}}.{{Attr|orientation}} (if present) have the opposite value.
 
Let’s say a train with the formation<br>
This may be useful when the train has an {{TT:Tag|activityTrainReverse}}. But it may also be relevant in other cases.
* 1. propelling control car<br>
 
* 2. 2nd class carriage<br>
==== Example ====
* 3. 1st class carriage<br>
Consider a train with the following formation:
* 4. engine<br>
 
runs all day between Airport and a place called Pirna and vice versa. For the one direction the <nowiki><formation></nowiki> is fine, but for the other direction the formation would have to be created a second time:<br>
<syntaxhighlight lang="xml">
* 1. engine<br>
<formation id="fm-1">
* 2. 1st class carriage<br>
  <trainOrder orderNumber="1" vehicleRef="vh-1" orientation="normal"/> <!-- control car -->
* 3. 2nd class carriage<br>
  <trainOrder orderNumber="2" vehicleRef="vh-2"/>                      <!-- 2nd class carriage -->
* 4. propelling control car<br>
  <trainOrder orderNumber="3" vehicleRef="vh-3"/>                      <!-- 1st class carriage -->
  <trainOrder orderNumber="4" vehicleRef="vh-4" orientation="reverse"/><!-- engine -->
To avoid this, the attribute {{TT:Tag|formationTT}}.{{Attr|orientationReversed}} can be used at every second train.
</formation>
</syntaxhighlight>
Please note: None of the trains do ever change their running direction during a single run - as in practice between Airport and Pirna. ("I suppose you know the location.")
 
It runs all day between the stations Arnau and Cstadt.<ref>railML.org Simple Example: [https://www.railml.org/en/user/exampledata.html]</ref> For one direction, referencing <code>fm-1</code> would be fine:
So far, no need to use {{TT:Tag|formationTT}}.{{Attr|orientationReversed}} at a formation consisting of one vehicle only. This would have been paradox since one cannot change the order of a list containing only one element.
 
<syntaxhighlight lang="xml">
<formationInformation formationRef="fm-1"/>
</syntaxhighlight>
 
But the {{TT:Tag|operationalTrainSectionPart}} for the return journey would have to reference the following formation:


=== Semantical background ===
<syntaxhighlight lang="xml">
<formation id="fm-2">
  <trainOrder orderNumber="1" vehicleRef="vh-4" orientation="normal"/> <!-- engine -->
  <trainOrder orderNumber="2" vehicleRef="vh-3"/>                      <!-- 1st class carriage -->
  <trainOrder orderNumber="3" vehicleRef="vh-2"/>                      <!-- 2nd class carriage -->
  <trainOrder orderNumber="4" vehicleRef="vh-1" orientation="reverse"/><!-- control car -->
</formation>
</syntaxhighlight>


One should be aware that {{TT:Tag|ocpTT}}.{{Attr|trainReverse}} semantically applies to the whole {{TT:Tag|train}} while {{TT:Tag|formationTT}}.{{Attr|orientationReversed}} applies to the formation of one {{TT:Tag|trainPart}} only. This means that if {{Attr|trainReverse}} is specified for one {{TT:Tag|trainPart}} it should also be specified for all other {{TT:Tag|trainPart}}'s that travel alongside it ([https://www.railml.org/forum/index.php?t=msg&th=843&start=0& forum discussion]).
Instead of this near-duplicate, it could also reference the original formation <code>fm-1</code> itself, but with {{TT:Tag|formationInformation}}.{{Attr|orientationReversed}} set to <code>true</code>. So, the following are equivalent:


There is another way to change the orientation of the formation of a whole train without {{TT:Tag|formationTT}}.{{Attr|orientationReversed}}: Each vehicle forms its own {{TT:Tag|trainPart}}, may be due to different operating days or so.
<syntaxhighlight lang="xml">
<syntaxhighlight lang="xml">
<train>
<formationInformation formationRef="fm-2"/>
  <trainPartSequence>
<formationInformation formationRef="fm-1" orientationReversed="true"/>
    <trainPartRef ref=’TP1.1’ position=’1’>
</syntaxhighlight>
    <trainPartRef ref=’TP2.1’ position=’2’>
 
    <trainPartRef ref=’TP3.1’ position=’3’>
Please note: None of the trains do ever change their running direction during a single run.
  </trainPartSequence>
 
  <trainPartSequence>
=== Semantical Relationship ===
    <trainPartRef ref=’TP3.2’ position=’1’>
There is a certain correlation between {{TT:Tag|activityTrainReverse}} and {{TT:Tag|formationInformation}}.{{Attr|orientationReversed}}. But neither necessarily implies the other.
    <trainPartRef ref=’TP2.2’ position=’2’>
 
    <trainPartRef ref=’TP1.2’ position=’3’>
* A reversal with an engine change may result in a completely different formation.
  </trainPartSequence>
* If the formation changes due to shunting, the new formation could be in reversed orientation without the train changing its running direction.
</train>
* The exporter may choose to export reversed copies of formations, instead of using {{Attr|orientationReversed}}.
</syntaxhighlight>
* ...
 
There is another way to change the orientation of the formation of a whole train without {{TT:Tag|formationInformation}}.{{Attr|orientationReversed}}: If there is one {{TT:Tag|operationalTrainSectionPart}} for each vehicle, and no vehicle has a {{RS:Tag|trainOrder}}.{{Attr|orientation}} attribute:


Obviously the train reverses between both {{TT:Tag|trainPartSequence}}'s but there would be no change of {{TT:Tag|formationTT}}.{{Attr|orientationReversed}} at none of the {{TT:Tag|trainPart}}s if each consist of one MU only.
<syntaxhighlight lang="xml">
<operationalTrainSection>
  <operationTrainSectionPart><formationInformation formationRef="fm-1-1"/></operationTrainSectionPart>
  <operationTrainSectionPart><formationInformation formationRef="fm-1-2"/></operationTrainSectionPart>
  <operationTrainSectionPart><formationInformation formationRef="fm-1-3"/></operationTrainSectionPart>
  <operationTrainSectionPart><formationInformation formationRef="fm-1-4"/></operationTrainSectionPart>
</operationalTrainSection>
</syntaxhighlight>


=== Summary ===
Then the entire formation could be reversed by reversing the order of the {{TT:Tag|operationTrainSectionPart}}s:
1) A formation running in one direction (“forward”) without reversing:<br>
* {{TT:Tag|ocpTT}}.{{Attr|trainReverse}}: not used<br>
* {{TT:Tag|formationTT}}.{{Attr|orientationReversed}}: not used<br>
   
   
2) A formation of several vehicles running in the other direction (“backward”) without reversing:<br>
<syntaxhighlight lang="xml">
* {{TT:Tag|ocpTT}}.{{Attr|trainReverse}}: not used<br>
<operationalTrainSection>
* {{TT:Tag|formationTT}}.{{Attr|orientationReversed}}: shall be used<br>
  <operationTrainSectionPart><formationInformation formationRef="fm-1-4"/></operationTrainSectionPart>
  <operationTrainSectionPart><formationInformation formationRef="fm-1-3"/></operationTrainSectionPart>
3) A formation of several vehicles reverses direction without ‘running around’ of the engine (headshunt):<br>
  <operationTrainSectionPart><formationInformation formationRef="fm-1-2"/></operationTrainSectionPart>
* {{TT:Tag|ocpTT}}.{{Attr|trainReverse}}: shall be used<br>
  <operationTrainSectionPart><formationInformation formationRef="fm-1-1"/></operationTrainSectionPart>
* {{TT:Tag|formationTT}}.{{Attr|orientationReversed}}: shall be used<br>
</operationalTrainSection>
</syntaxhighlight>
4) A formation of several vehicles reverses direction with ‘running around’ of the engine  (headshunt):<br>
* {{TT:Tag|ocpTT}}.{{Attr|trainReverse}}: shall be used<br>
* {{TT:Tag|formationTT}}.{{Attr|orientationReversed}}: cannot be used since the formation changes<br>
To avoid no. #4, the engine may be put in an own {{TT:Tag|trainPart}} so that #4 becomes “two times #3”. This reduces the total number of necessary formations by trend but it increases the total number of train parts. (Since a train part normally has more overhead than a formation, it may be better to handle rather more formations than more train parts.)


=== Additional notes ===
=== Additional notes ===


* It is currently not defined "which way around" is the "normal" order of a formation and which is the "reverse" order of a formation. It is not enforced to define the engine as the first vehicle of a formation. Even for a formation which is used always in the same direction, it is up to the RailML writing software either to define it in one or the other orientation and possibly never use it without {{TT:Tag|formationTT}}.{{Attr|orientationReversed}} set to 'true'. So, the defined orientation of a formation (given in the RailML file) may be the first which occurs or the one which is mainly used or the one of which somebody thought that it may be the mainly used or none of that...
* The "standard" orientation can be chosen arbitrarily by the exporting software. It may be with the engine at the front, or with the engine at the end, or anything else.
* You should always treat the vehicle with the lowest {{Attr|orderNumber}} in a formation being the first vehicle in running direction (at the front of the train) and the vehicle with the highest {{Attr|orderNumber}} as the last one (at rear of the train) - except if {{TT:Tag|formationTT}}.{{Attr|orientationReversed}} is set to 'true' which of course makes it the other way 'round.
* There is no guarantee that the standard orientation of a formation is actually ever used in a railML document. It would be perfectly valid, if all references to a specific formation had {{TT:Tag|formationTT}}.{{Attr|orientationReversed}} set to <code>true</code>.
* It is currently not 'forbidden' to use {{TT:Tag|formationTT}}.{{Attr|orientationReversed}} with formation of one single vehicle. For some special cases it is the only way to define the running direction of one single vehicle. This could possibly apply e. g. to seat reservation: Whether certain seats are facing running direction or backwards. One could imagine a tramway operating between two terminal loops. If the tramway consists of one single bi-directional vehicle, the attribute {{Attr|orientationReversed}} is the only possibility to describe whether the tramway uses the terminal loops to turn around or just reverses.
* The order of the vehicles in a formation is defined by increasing {{TT:Tag|trainOrder}}.{{Attr|orderNumber}}. That is, the lowest order number is at the front of the train, while the highest order number is at the end of the train. Except if {{TT:Tag|formationTT}}.{{Attr|orientationReversed}} is set to <code>true</code>, which reverses the entire vehicle order.
* It is not forbidden to use {{TT:Tag|formationInformation}}.{{Attr|orientationReversed}} with a formation of one single vehicle, even if that vehicle does not have an orientation.
   
   
= References =
[[Category:GeneralDescription]]
[[Category:GeneralDescription]]
[[category:Timetable Concept]]
[[category:Timetable Concept]]

Revision as of 13:31, 8 March 2023

This article explains basic concepts of handling formation orientation within the timetable subschema.

Dieser Artikel erklärt die grundlegenden Konzepte des Umgangs mit der Fahrtrichtung von Zügen im Timetable-Subschema.

Reversing trains and formations

In the <timetable> scheme, there are two elements or attributes concerning the running direction of a train formation: <activityTrainReverse> and <formationInformation>.orientationReversed. They may seem to be redundant and may possibly be mixed. This shall try to explain the difference between the two:

Concerning the meaning of <activityTrainReverse>

This indicates that the train (part) changes its running direction at the parent base itinerary point. It includes all operational actions that may be necessary to do so. Examples are:

  • reversal with identical formation, but in reversed order (if it has more than one vehicle) and vehicle orientation (if it is given).
  • reversal with the engine coupled to the other end of the formation, also known as run-around.
  • reversal with a different engine coupled to the other end of the formation.

This information is mainly intended for passenger information (systems). Some systems may, for example, show a ↔ symbol where the running direction of the train changes.

Concerning the meaning of <formationInformation>.orientationReversed

This has nothing to do with a train changing the running direction. It merely avoids the necessity of creating reversed copies of formations that run in both directions. Instead, a formation reference with <formationInformation>.orientationReversed set to true is equivalent to a reference to a formation with all identical properties except for:

  • the <trainOrder>.orderNumber are in reversed order.
  • the <trainOrder>.orientation (if present) have the opposite value.

This may be useful when the train has an <activityTrainReverse>. But it may also be relevant in other cases.

Example

Consider a train with the following formation:

<formation id="fm-1">
  <trainOrder orderNumber="1" vehicleRef="vh-1" orientation="normal"/> <!-- control car -->
  <trainOrder orderNumber="2" vehicleRef="vh-2"/>                      <!-- 2nd class carriage -->
  <trainOrder orderNumber="3" vehicleRef="vh-3"/>                      <!-- 1st class carriage -->
  <trainOrder orderNumber="4" vehicleRef="vh-4" orientation="reverse"/><!-- engine -->
</formation>

It runs all day between the stations Arnau and Cstadt.[1] For one direction, referencing fm-1 would be fine:

<formationInformation formationRef="fm-1"/>

But the <operationalTrainSectionPart> for the return journey would have to reference the following formation:

<formation id="fm-2">
  <trainOrder orderNumber="1" vehicleRef="vh-4" orientation="normal"/> <!-- engine -->
  <trainOrder orderNumber="2" vehicleRef="vh-3"/>                      <!-- 1st class carriage -->
  <trainOrder orderNumber="3" vehicleRef="vh-2"/>                      <!-- 2nd class carriage -->
  <trainOrder orderNumber="4" vehicleRef="vh-1" orientation="reverse"/><!-- control car -->
</formation>

Instead of this near-duplicate, it could also reference the original formation fm-1 itself, but with <formationInformation>.orientationReversed set to true. So, the following are equivalent:

<formationInformation formationRef="fm-2"/>
<formationInformation formationRef="fm-1" orientationReversed="true"/>

Please note: None of the trains do ever change their running direction during a single run.

Semantical Relationship

There is a certain correlation between <activityTrainReverse> and <formationInformation>.orientationReversed. But neither necessarily implies the other.

  • A reversal with an engine change may result in a completely different formation.
  • If the formation changes due to shunting, the new formation could be in reversed orientation without the train changing its running direction.
  • The exporter may choose to export reversed copies of formations, instead of using orientationReversed.
  • ...

There is another way to change the orientation of the formation of a whole train without <formationInformation>.orientationReversed: If there is one <operationalTrainSectionPart> for each vehicle, and no vehicle has a <trainOrder>.orientation attribute:

<operationalTrainSection>
  <operationTrainSectionPart><formationInformation formationRef="fm-1-1"/></operationTrainSectionPart>
  <operationTrainSectionPart><formationInformation formationRef="fm-1-2"/></operationTrainSectionPart>
  <operationTrainSectionPart><formationInformation formationRef="fm-1-3"/></operationTrainSectionPart>
  <operationTrainSectionPart><formationInformation formationRef="fm-1-4"/></operationTrainSectionPart>
</operationalTrainSection>

Then the entire formation could be reversed by reversing the order of the <operationTrainSectionPart>s:

<operationalTrainSection>
  <operationTrainSectionPart><formationInformation formationRef="fm-1-4"/></operationTrainSectionPart>
  <operationTrainSectionPart><formationInformation formationRef="fm-1-3"/></operationTrainSectionPart>
  <operationTrainSectionPart><formationInformation formationRef="fm-1-2"/></operationTrainSectionPart>
  <operationTrainSectionPart><formationInformation formationRef="fm-1-1"/></operationTrainSectionPart>
</operationalTrainSection>

Additional notes

  • The "standard" orientation can be chosen arbitrarily by the exporting software. It may be with the engine at the front, or with the engine at the end, or anything else.
  • There is no guarantee that the standard orientation of a formation is actually ever used in a railML document. It would be perfectly valid, if all references to a specific formation had <formationTT>.orientationReversed set to true.
  • The order of the vehicles in a formation is defined by increasing <trainOrder>.orderNumber. That is, the lowest order number is at the front of the train, while the highest order number is at the end of the train. Except if <formationTT>.orientationReversed is set to true, which reverses the entire vehicle order.
  • It is not forbidden to use <formationInformation>.orientationReversed with a formation of one single vehicle, even if that vehicle does not have an orientation.

References

  1. railML.org Simple Example: [1]