Tutorial Exercise 1

Exercise Information

Four wagons are parked 300 meters away from a station, we need to send a locomotive there in order to bring those wagons back to the station. The locomotive has a maximum speed of 2 m/s. The path from the station to the wagons is a straight rail. Create a model that represents this problem.

Creating objects

In order to achieve the solution for the problem, you should create the following objects:

  • Create one Source Train.
  • Create three Rails, then resize Rail2 xvalue to 300. Connect Source Train to the Rail1 connectpoint and then connect Rail1 to Rail2 and Rail2 to Rail3 via proximity.
  • Create a Rail Control Point and put it on Rail3.
Exercise1Objs

Your model should be looking like this.

Exercise1Objs

Processflow Configuration

In order to achieve the solution for the problem, you should create the following processflow tasks:

  • Create a Source.
  • Create a CreateTrain and a CreateWagon.
  • Create a MoveTrain.
  • Create a CoupleWagon.
  • Create a MoveTrain.
  • Create a Sink.

Your processflow should be looking like this.

Exercise1PF

To configure your processflow tasks follow the steps:

  • On CreateTrain points the SourceTrain reference to your SourceTrain and set the Locomotive Speed to the value 2.
  • On CreateWagon points the RailControlPoint reference to the RailControlPoint on Rail3 and set wagons quantity to 4.
  • On MoveTrain set train reference to token.train and destiny to the RailControlPoint on Rail3.
  • On CoupleWagon set train reference to token.train and wagon reference to token.wagon.
  • On MoveTrain set train reference to token.train and destiny to Rail1.
Exercise1PF

With this configuration your model is ready.