Spatial Link: Difference between revisions

From Planimate Knowledge Base
Jump to navigation Jump to search
mNo edit summary
No edit summary
 
(10 intermediate revisions by one other user not shown)
Line 1: Line 1:
[[Image:Splink Palette Icon.jpg]]<br>
<onlyinclude>
[[Image:Splink Palette Icon.jpg]]


Spatial links are objects that form a connection between portals. <br>
Spatial links are objects that form a connection between portals.


Spatial Link Objects can be classified as “Logical with Capacity and Process Delay”, as they can hold items, and time passes as they process items. <br>  
Spatial Link Objects can be classified as “Logical with Capacity and Process Delay”, as they can hold items, and time passes as they process items.  
</onlyinclude>  


Spatial links have no capacity limit, however they are restricted in that it is an error to allow an Item to be blocked from leaving a spatial link. <br>  
Spatial links have no capacity limit, however they are restricted in that it is an error to allow an Item to be blocked from leaving a spatial link. <br>  
Line 16: Line 18:


See also [[How to Build a Spatial Link Network|How to Build a Spatial Link Network]].  
See also [[How to Build a Spatial Link Network|How to Build a Spatial Link Network]].  
<br>


== Transit Target<br>  ==
== Transit Target<br>  ==
Line 35: Line 39:
The Transit Time you assign to the Item is the total time it will take moving from the Portal of origin to the Transit Target. If more that one Spatial Link needs to be traversed to reach th Target, the Transit Time across each link is apportioned according to the screen pixel length of each Link, in ratio to the entire Link distance. The animation of an Item’s transit over the links is performed such that the item arrives at the Transit Target in the specified interval.  
The Transit Time you assign to the Item is the total time it will take moving from the Portal of origin to the Transit Target. If more that one Spatial Link needs to be traversed to reach th Target, the Transit Time across each link is apportioned according to the screen pixel length of each Link, in ratio to the entire Link distance. The animation of an Item’s transit over the links is performed such that the item arrives at the Transit Target in the specified interval.  


== Dynamic Spatial Links<br> ==
<br>  


Spatial links between portals can be added and removed during a model run. When adding, if a link already exists (in either direction) a new one is not added. When deleting, link(s) in either direction are removed. No error is given if no links were in place between the 2 portals. Deleting a spatial link deletes any items on it. Copy spatial link function enables template spatial links to be copied which is useful for creating spatial link-pipes. The "Copy From" specifies a spatial link object which has been preconfigued with the required visualisation options.
== Dynamic Spatial Links  ==


== Spatial Link Bends<br>  ==
{{Breakout|Dynamic Spatial Links}}


Spatial Links can have bends added to them either during editing, or during a run by the model. [[Image:Splink Bend Points.jpg]]<br> The Settings / Display Options in the menu bar has an option "User Can Bend Spatial Links". This enables Model Users to see, move and add/delete bends to spatial links during the run.
<br>  


A Routine operation Spatial link - Add Spatial Link Bend enables a bend point to be appended to the current bend points of any spatial link going from one designated portal to another. This is intended for models which construct spatial link networks on the fly.
<br>


There is no way to remove a bend point; you need to instead re-create the link as required.
== Spatial Link Bends  ==


== Spatial Link color<br>  ==
Spatial Links can have bend points added to them.


Spatial link color can be changed. The link colour can by set during editing, or a routine operation can changes color of any link between two objects during a model run. If the link does not exist, nothing happens. A redraw is required after this if the link colour is not being set for a link added in the same routine/epoch. In these cases, an automatic redraw *is* scheduled. Colours once set persist across runs. Saving the model saves the link colours.  
These bend points can be moved around to re-shape the spatial link line on the screen display.  


While building a model, Modellers can right click on a link and select the Add Bend option.


== Link Cost ==
During a Model run, with the run paused, modellers can click on a link and add a bend.


This enables the modeller to set the "distance" of the link directly (default 0 uses screen distance).  
[[Image:Splink Bend Points.jpg]]<br>


This is useful where you have a short link connecting nodes but you don't want items to take that link as a "short cut" unless you specifically nominate a Portal connected to that link as a Transit Target.
The Settings / Display Options in the menu bar has an option "User Can Bend Spatial Links".&nbsp; This enables Model End Users to see, move and add/delete bends to spatial links during the run.  


Link Cost can also be set from a Routine.
'''Note: &nbsp;'''A Routine operation Spatial link - [[AddBendPoint|AddBendPoint]] enables a bend point to be appended to the current bend points of any spatial link going from one designated portal to another. This is intended for models which construct spatial link networks on the fly.<br>


<br>


== Directional spatial links<br>  ==
== Spatial Link color<br>  ==


An option during edit of the spatial link, plus a routine operation enables creation of a directional spatial link. Planimate® enables two spatial links to exist between a pair of objects if they are directional in opposite directions.  
Spatial link color can be changed. The link colour can by set during editing, or a routine operation can changes color of any link between two objects during a model run. If the link does not exist, nothing happens. A redraw is required after this if the link colour is not being set for a link added in the same routine/epoch. In these cases, an automatic redraw *is* scheduled. Colours once set persist across runs. Saving the model saves the link colours.  


== Spatial Link Pipe View<br> ==
<br>  


This option makes Spatial Links display like Pipe Objects, but without the complicated attribute handling of using pipes. The basic idea is that the Spatial Link gets divided into a number of sections.
== Link Cost  ==


[[Image:Splink as Pipe Option.jpg]]<br>
This enables the modeller to set the "distance" of the link directly (default 0 uses screen distance).  


Each section can have its colour set as an item moves through it along the pipe. In addition to the section colours, separate "activity animation" can occur for non-idle sections, to graphically illustrate material flow. Since multiple items can exist in a spatial link, multiple coloured "bands" can simultaneously animate down the "pipe".  
This is useful where you have a short link connecting nodes but you don't want items to take that link as a "short cut" unless you specifically nominate a Portal connected to that link as a Transit Target.  


=== Usage:<br>  ===
Link Cost can also be set from a Routine using the [[SetLinkCost|SetLinkCost]] operation.


In the options of a spatial link, turn on "Pipe Display Mode".
<br>


The Edit menu will now contain 2 new entries:
== Directional spatial links<br>  ==


Pipe Display Settings
An option during edit of the spatial link, plus a routine operation enables creation of a directional spatial link. Planimate® enables two spatial links to exist between a pair of objects if they are directional in opposite directions.


This contains constant pipe parameters such as width, section count, and activity update settings.
<br>


Pipe Parameters
== Spatial Link Pipe View  ==


This enables 3 dynamic attributes to be defined for the spatial link pipe: Section Colour
{{Breakout|Spatial Link Pipe View}}


The colour each section of the pipe will be set to as the item moves through it.<br>  
<br>  
 
Activity Colour
 
The activity animation colour (used for the entire pipe) to use.<br>
 
Run Control
 
The activity speed and direction, eg: 1 is forward, 0 is stoppped, -2 is reverse double speed etc.<br><br>
 
These parameters are looked up whenever an item enters the spatial link, moves between sections of the pipe or leaves the spatial link.
 
A section gets its colour set at the instant the item leaves it.
 
By dynamically changing these parameters as the item moves therough the pipe, some very interesting effects are possible.
 
Of all the parameters, the section count is the most important. IT determines how many graphical bins the pipe will be split into.
 
The more bins, the smoother the animation but the more FEC events will be scheduled as the item moves through the spatial link, slowing the model down. This slowdown occurs if the pipe is visible or not.


== Interactive Spatial Links  ==
== Interactive Spatial Links  ==


If you want the Spatial Links in a Panel to respond to mouse clicks, set the Panel Option "Send Spatial Link Clicks". This suppresses the normal link information menu. <br>
{{Breakout|Detecting clicks on spatial links using Link Clicked}}


Then, whenever the user clicks on a spatial link line a system broadcast "_link clicked" gets sent.
<br>  
 
The broadcast includes the following tuple attributes:
 
_x,_y
 
The screen co-ordinate clicked.<br><br>
 
_ratio
 
The ratio along the line where the&nbsp; user clicked, from near 0 (start of) approatching 1 (end of link)<br><br>
 
_from
 
Object label identifier of the "from" portal for the link.<br><br>
 
_to


Object label identifier of the "to" portal for the link.<br><br>
== Controlling Items on Spatial Links  ==


_buttons
{{Breakout|Controlling Items on Spatial Links}}
 
Indicates which button was clicked, Left = 1; Right = 2.


<br>  
<br>  


== Stoppable Spatial Links ==
== Spatial Link Routine Operations<br> ==


All spatial links have a control attribute (like a pipe). Whilst links still do not have "capacity" per se, this gives the modeller much more control over the use of spatial links to move items.  
The following is a list of the routine operations available for working specifically with Spatial Link Objects.<br>


By default it is 1, meaning "go".
*[[Routine Operations#AddBendPoint|AddBendPoint]]
*[[Routine Operations#AddDirectionalLink|AddDirectionalLink]]
*[[Routine Operations#AddSpatialLink|AddSpatialLink]]
*[[Routine Operations#ClearSpatialCache|ClearSpatialCache]]
*[[Routine Operations#CopySpatialLink|CopySpatialLink]]
*[[Routine Operations#DeletePanelSpatialLinks|DeletePanelSpatialLinks]]
*[[Routine Operations#RemoveSpatialLink|RemoveSpatialLink]]
*[[Routine Operations#SetItemTransitTarget|SetItemTransitTarget]]
*[[Routine Operations#SetItemTransitTime|SetItemTransitTime]]
*[[Routine Operations#SetLinkColor|SetLinkColor]]
*[[Routine Operations#SetLinkCost|SetLinkCost]]
*[[Routine Operations#SetSpatialLinkWidth|SetSpatialLinkWidth]]


If this attribute is set to 0, the link will be "stopped" with all items on the link being frozen and the end points of the link blocking any item attempting to enter them.  
<br> Note that additional new routine operations may exist since this article was last updated.<br>


You can also use the spatial link run/stop control to scale the item transit time. eg: 1.0 uses the nominal time, 0.5 doubles the time, 2 halves the item time.  
If so, they will appear first in the full Routine Operations Listing.<br>


Usage Note: The minimum "on" value is 0.01. Any lower value and the spatial link is considered stopped. The scaling occurs only once, as the item enters the spatial link and changes will not affect that item whilst its on the link
<br>Refer to Editing Object Properties for information about editing properties common to all objects.  
 
It is very important that the control attribute is something Planimate® can "unblock" from, so portal attributes and fixed cell references are OK, but item or dynamic table references are out.
 
Planimate® looks for the control attribute starting in the "from" portal of the spatial link.
 
Advanced user note: If you click on an item on a stopped spatial link, the "TIME" field will show the start model date + the time the item has spent MOVING on the link.
 
If the link is restarted and you click on an item, the "TIME" field will show the resume time - the time the item has spent moving on the link (ie: as if the link never stopped).
 
This is to keep the animation calculations consistent.
 
IF an item *with* a spatial link target set is about to go up to a portal with spatial links connected where no links accept the item, and that portal ALSO has flows connected to it, Planimate® will not attempt to take any of the outgoing flows of that portal, nor complain if there is no flows.
 
The item will block instead.
 
This is to support stoppable spatial links.
 
If NO spatial link leading to a target portal is found, it just "blocks" the item that cannot find a destination, as occurs with a stopped spatial link.
 
It is conceivable that a modeller may later add a spatial link, enabling the "blocked" item to proceed. <br> Refer to Building a Spatial Link for more details.
 
Refer to Editing Object Properties for information about editing properties common to all objects.  


<br>  
<br>  
<br> <br>


== Spatial Link Articles  ==
== Spatial Link Articles  ==
Line 185: Line 142:
</dpl>  
</dpl>  


<br> <br>  
<br>  


== Spatial Link Object Frequently Asked Questions  ==
== Spatial Link Object Frequently Asked Questions  ==
Line 195: Line 152:
order=descending
order=descending
</dpl>  
</dpl>  
<br>


<br>  
<br>  


[[Category:Object/SpatialLink]]
[[Category:Object/SpatialLink]]
[[Category:Training]]

Latest revision as of 20:15, 5 December 2012

Splink Palette Icon.jpg

Spatial links are objects that form a connection between portals.

Spatial Link Objects can be classified as “Logical with Capacity and Process Delay”, as they can hold items, and time passes as they process items.


Spatial links have no capacity limit, however they are restricted in that it is an error to allow an Item to be blocked from leaving a spatial link.


Splink Example.jpg

To send an Item on to a Spatial Link, you assign to it a “Transit Target” and usually a “Transit Time”.

This is usually done by adding Routine operations to a Change Object located inside one of the Portals the Spatial Link is connected to, then sending the Item to a Portal Exit.

See also How to Build a Spatial Link Network.


Transit Target

Upon being assigned a Transit Target, then sent to a Portal Exit, the item will seek to move on to a Spatial Link rather than a normal Item Path in its flow. The Transit Target need not always be a Portal at the other end of the Spatial Links connected to the portal the Item is in. Instead you can set a destination that may require crossing a number of Spatial Links before arriving.

Resolving how to reach the Target

If the Spatial Links network yields alternative routes that could be taken to reach the Transit Target, the system resolves this by selecting the route with the least number of links in it, and the shortest overall screen distance to travel. Each Portal connected to more than one Spatial Link in a network should provide within itself a path for the item to enter and depart the portal, so that it may continue on its journey.

Target Portals must be in the _Model Objects List

For a Portal to be a valid Transit Target, it must be added to the _Model Objects System Label list. This is done as you build your network of links. When you add a Spatial Link between Portals, the system prompts you to provide a name for the Portal, which is added to the _Model Objects list. This list is available for review under Data in the Menu Bar. The system gives an error if a movement to the origin Portal is attempted.


Transit Time

The Transit Time you assign to the Item is the total time it will take moving from the Portal of origin to the Transit Target. If more that one Spatial Link needs to be traversed to reach th Target, the Transit Time across each link is apportioned according to the screen pixel length of each Link, in ratio to the entire Link distance. The animation of an Item’s transit over the links is performed such that the item arrives at the Transit Target in the specified interval.


Dynamic Spatial Links

Spatial links between portals can be added and removed during a model run, using Routine Operations.

When adding, if a link already exists (in either direction) a new one is not added.

When deleting, link(s) in either direction are removed.


For full details refer to this page: Dynamic Spatial Links



Spatial Link Bends

Spatial Links can have bend points added to them.

These bend points can be moved around to re-shape the spatial link line on the screen display.

While building a model, Modellers can right click on a link and select the Add Bend option.

During a Model run, with the run paused, modellers can click on a link and add a bend.

Splink Bend Points.jpg

The Settings / Display Options in the menu bar has an option "User Can Bend Spatial Links".  This enables Model End Users to see, move and add/delete bends to spatial links during the run.

Note:  A Routine operation Spatial link - AddBendPoint enables a bend point to be appended to the current bend points of any spatial link going from one designated portal to another. This is intended for models which construct spatial link networks on the fly.


Spatial Link color

Spatial link color can be changed. The link colour can by set during editing, or a routine operation can changes color of any link between two objects during a model run. If the link does not exist, nothing happens. A redraw is required after this if the link colour is not being set for a link added in the same routine/epoch. In these cases, an automatic redraw *is* scheduled. Colours once set persist across runs. Saving the model saves the link colours.


Link Cost

This enables the modeller to set the "distance" of the link directly (default 0 uses screen distance).

This is useful where you have a short link connecting nodes but you don't want items to take that link as a "short cut" unless you specifically nominate a Portal connected to that link as a Transit Target.

Link Cost can also be set from a Routine using the SetLinkCost operation.


Directional spatial links

An option during edit of the spatial link, plus a routine operation enables creation of a directional spatial link. Planimate® enables two spatial links to exist between a pair of objects if they are directional in opposite directions.


Spatial Link Pipe View

This option makes Spatial Links display like Pipe Objects, but without the complicated attribute handling of using pipes.

The basic idea is that the Spatial Link gets divided into a number of sections.

Splink as Pipe Option.jpg

Each section can have its colour set as an item moves through it along the pipe. In addition to the section colours, separate "activity animation" can occur for non-idle sections, to graphically illustrate material flow. Since multiple items can exist in a spatial link, multiple coloured "bands" can simultaneously animate down the "pipe".


For full details refer to this page: Spatial Link Pipe View


Interactive Spatial Links

If you want the Spatial Links in a Panel to respond to mouse clicks, first set the Panel Option "Send Spatial Link Clicks".

This suppresses the normal link information menu.

Thereafter, whenever the modeller or user clicks on a spatial link line a system broadcast called "_Link Clicked" gets sent.


For full details refer to this page: Detecting clicks on spatial links using Link Clicked


Controlling Items on Spatial Links

All spatial links have a control attribute (like a pipe).

This control attribute means you can alter the item transit time, either scaling the transit time, or stopping item movement altogether.

This attribute gives the modeller much control over the use of spatial links to move items.


For full details refer to this page: Controlling Items on Spatial Links


Spatial Link Routine Operations

The following is a list of the routine operations available for working specifically with Spatial Link Objects.


Note that additional new routine operations may exist since this article was last updated.

If so, they will appear first in the full Routine Operations Listing.


Refer to Editing Object Properties for information about editing properties common to all objects.


Spatial Link Articles


Spatial Link Object Frequently Asked Questions