question

Devdatta D avatar image
0 Likes"
Devdatta D asked Jeanette F commented

ASRS distance along network egde

I have a user command which gets executed everytime a package is loaded onto ASRS. When this happens, I want to calculate the distance of ASRS along the network edge. However, as seen below the function is not returning the distance correctly.

1660857073843.png

File name is Warehouse_getDistance

FlexSim 22.1.1
warehousenetwork nodesasrs vehicleuser command
1660857073843.png (488.2 KiB)
· 2
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

Jason Lightfoot avatar image
0 Likes"
Jason Lightfoot answered Jason Lightfoot edited

Use vectors to find the distance along the path between two netnodes when the traveler is no longer travelling along the edge due to offset travel:

  1. Vec3 p1=Model.find("NN2").as(Object).location;
  2. Vec3 p2=Model.find("NN3").as(Object).location;
  3. Vec3 p12=p2-p1;
  4. Vec3 t=Model.find("Transporter1").as(Object).location;
  5. Vec3 p1t=t-p1;
  6. double distAlong=p12.dot(p1t)/p12.magnitude;
  7. return distAlong;



5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

Joerg Vogel avatar image
0 Likes"
Joerg Vogel answered Devdatta D commented

An ASRS Vehicle doesn’t drive on an Network in warehouse aisles. It performs only Offset travel tasks for load and unload tasks then. It is still connected to a networknode, which is taking part to be a transfer point of load and unload actions.

Perhaps you can evaluate kinematics of such an object to get your desired data.

· 2
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.