ATTENTIONThis FlexSim Community Forum is read-only. Please post any new questions, ideas, or discussions to our new community (we call it Answers) at https://answers.flexsim.com/. Our new Question & Answer site brings a modern, mobile-friendly interface and more focus on getting answers quickly. There are a few differences between how our new Q&A community works vs. a classic, threaded-conversation-style forum like the one below, so be sure to read our Answers Best Practices. |
flexsim.com |
#1
|
|||
|
|||
Travel Offset Distance
Hello,
I would like to calculate the total OFFSET distance traveled by my BasicTE? any suggestions are welcome. Well, what do you think about this? I see commands such as placeoffsetx and pickoffsetx. Should I use them right before TASKTYPE_PLACEOFFSET and TASKTYPE_PICKOFFSET in my commands and increment a label on my BasicTE. |
#2
|
|||
|
|||
You could extract the state data and calculate the time which is used for offset travel tasks and set it in relation to the total traveling distance.
It's not 100% precise, because it assumes a constant travelling speed - which is not correct, because a TE uses linear acceleration after un-/loading. Code:
treenode current = ownerobject(c); // Offset travel part of total time double offset_1 = getnodenum(node("MAIN:/project/model/Operator9>stats/state/state_profile/offset_travel_empty")); double offset_2 = getnodenum(node("MAIN:/project/model/Operator9>stats/state/state_profile/offset_travel_loaded")); double distance = getvarnum(current,"totaltraveldist"); // Gets the total travelled distance double percentage = (offset_1 + offset_2) / time(); // Calculates the ratio of offset travel tasks to totaltime double offsetway = percentage * distance; |
#3
|
||||
|
||||
If you look at your statistics tabpage you can find the totaltraveldistance of a taskexecuter. This number is stored on a variable "totaltraveldist". So this can be queried with: getvarnum( current, "totaltraveldist");
If you only want the offset travel I assume you have a network. If you have you can keep track or calculate the distances over the network and subtract those from the totaltraveldistance, the remainder is the offset travel. |
Tags |
basicte, offset, pickoffest, placeoffset, travel distance |
Thread | Thread Starter | Forum | Replies | Last Post |
Flowitem offset in Conveyor | Manoj Kumar | Q&A | 2 | 03-14-2012 04:37 AM |
Where can I find or get the information about the travel distance of each yard truck? | syseo | Container Terminal (CT) Library | 0 | 02-12-2011 12:24 AM |
Keeps a distance | Li Chin | Q&A | 3 | 12-18-2008 02:09 AM |
Setting the side offset for all nodes in the model | Brandon Peterson | Tips and Tricks | 0 | 04-28-2008 11:15 AM |
Offset Travel | AlanZhang | Q&A | 16 | 04-18-2008 10:25 AM |