ATTENTION

This 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

Go Back   FlexSim Community Forum > FlexSim Software > Q&A
Downloads

Q&A Using Flexsim and building models

  #1  
Old 05-18-2010
harry qin harry qin is offline
Flexsim User
 
Join Date: Apr 2010
Posts: 19
Downloads: 5
Uploads: 0
Thanks: 19
Thanked 0 Times in 0 Posts
Rep Power: 123
harry qin is on a distinguished road
Default How to use Global Table as orderlist to move output works?

hi,everyone,now i wanna use order to install the output work.Now i put orderlist in a global table named "order".i would like use the "pull from port" node in queue1.when row=1 and column=1,cell(11)=x ,time=T, pulling x goods from rack1 when time=T ;when row =2 and column=2,cell(12)=y,time=W pulling y goods from rack2 when time=W.
can anybody help me?thx

I don't know whether i describe my question clearly.what i want is output a specified type and number goods in a specified time.And the type,number and time are given in Global Table.If i realize this function in "PULL FROM PORT" in queue's flow tab.How?

The attached files is a little sample model for my question.If there is something wrong with my uploaded file.Tell me
Attached Files
File Type: zip sample to forum.zip (41.2 KB, 187 views)
__________________
Harry Qin

Last edited by harry qin; 05-18-2010 at 03:39 AM. Reason: adding something
  #2  
Old 05-18-2010
Tom David's Avatar
Tom David Tom David is offline
Flexsim User
 
Join Date: Aug 2007
Location: Schwaebisch Gmuend, Germany
Posts: 430
Downloads: 157
Uploads: 47
Thanks: 486
Thanked 450 Times in 233 Posts
Rep Power: 520
Tom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant future
Default

Harry,

There are different ways to solve your task.
The solutions which come to my mind need coding, so as far as I see it, you can’t solve the task using pick list options.

Your idea to use Input / Pull could be one way to solve it.
I built once a model where a specific item type should not enter for a certain time.
So I used Pull From Port: Any Port, but used in the Pull Requirement: Array of Itemtypes, but modified the Array of Itemtypes code.

// LOCAL VARIABLES
int arraysize = 1;
doublearray array = makearray(arraysize);
int condition = 0;
// IF DAY 6 ONLY ALLOW ITEMTYPE 1 AND 3
if(time() >= 7200 && time() <= 8640)
{
arraysize = 2;
array = makearray(arraysize);
fillarray(array,1,3);
}
else// ELSE ALLOW ALL ITEMTYPES
{
arraysize = 3;
array = makearray(arraysize);
fillarray(array,1,2,3);
}
// SEARCH FOR AN ITEM
for(int index = 1; index <= arraysize && condition == 0; index++)
{
condition = (getitemtype(item) == array[index]);
}
// RETURN CONDITION
return condition;


But the code needs more modification and because you want not only limit the item type but also the number of items, I guess that’s not a good way to go.
Maybe there is a solution this way, but I would try something else.


If I understand your task correct, you want that specific item types enter at a specific time in a specific amount.
What I would try is to just put the number of items with the right item type at the specific time into the specific rack.
If the items enter the rack, the transporter will pick them up and bring them to the queue.

You could use one Source for each rack, where you modify the Arrival Schedule depending on a Global Table.
There is a Sample Model (Sample_Manipulation_of_arrival_schedule_MB) in the download section which shows how to modify the Arrival Schedule of a Source.
And there is a Sample Model (Sample_GlobalTableArrivalSchedule_TD ) in the download section which shows how to model arrivals in a Source depending on a Global Table.

Or you use one Source for all racks, but need to take care also of the Output Port. So I would use one Source for each Rack.

I hope this hints are helpful and will push you in the right direction.
__________________
tom the (A)tom: "We have solved our problems ... now we have to fight the solutions."
The Following 2 Users Say Thank You to Tom David For This Useful Post:
Lars-Olof Leven (05-18-2010)
  #3  
Old 05-18-2010
harry qin harry qin is offline
Flexsim User
 
Join Date: Apr 2010
Posts: 19
Downloads: 5
Uploads: 0
Thanks: 19
Thanked 0 Times in 0 Posts
Rep Power: 123
harry qin is on a distinguished road
Default

Hi,Tom
thanks.I build my model by your first method.And i really can control the output port.Yeah,this method can't control the amounts of the items.
For the second method.I am afraid i can't do it that way.Because i also have to analyse the inventory num.If i modify the arrival as order.then the inventory will be "0".Can you or some others have any idea about the amount of the items. thx

Harry
__________________
Harry Qin
  #4  
Old 05-18-2010
Lars-Olof Leven Lars-Olof Leven is offline
Flexsim Distributor
 
Join Date: Aug 2007
Location: Sweden, Borlnge
Posts: 312
Downloads: 278
Uploads: 2
Thanks: 300
Thanked 256 Times in 139 Posts
Rep Power: 330
Lars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to behold
Default

Hi,

I am not 100% sure if I understand what you want to do but if I understand it right I would remove the queue and use a combiner instead.

On port 1 I would have an item arriving representing the order, the itemtype should be the order number (your row) and also having a label called order (1 if an order).
Then OnEntry I would read from the table to know which rack to pick from and how many, take a look at Update Combiner Component List in the OnEntry trigger. It use columns instead of rows but it is not much work to get the code to work with rows instead.
Also in the combiner I would use Batch (not Pack or Join) and having the item representing the order leaving the combiner from its own port (if order==1 then send to port 1).

The items representing the orders is generated from a source with a arrival schedule. You can also have a queue between the source and the combiner if you are interested in to see if order will be waiting to be picked.

Lars-Olof
The Following 2 Users Say Thank You to Lars-Olof Leven For This Useful Post:
Tom David (05-19-2010)
  #5  
Old 05-19-2010
Tom David's Avatar
Tom David Tom David is offline
Flexsim User
 
Join Date: Aug 2007
Location: Schwaebisch Gmuend, Germany
Posts: 430
Downloads: 157
Uploads: 47
Thanks: 486
Thanked 450 Times in 233 Posts
Rep Power: 520
Tom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant future
Default

I like the idea of Lars-Olof using the Combiner, because it seems to be an “easy” way to go. Hopefully we do not oversee something.

And the idea with a Queue in front could also give you some information about the orders waiting.

Another way to go could be to use a virtual rack. Keep track of the items in a rack with a Global Table. You could also use an additional Global Table to keep track of the numbers of items, the different item types, etc. Ok, some coding is needed, but it can be a solution.
There is a Virtual Rack Model in the download section (Sample_VirtualRacks_TD).

Hopefully you are able to solve your task with the above hints. Good success.
__________________
tom the (A)tom: "We have solved our problems ... now we have to fight the solutions."
The Following User Says Thank You to Tom David For This Useful Post:
harry qin (05-21-2010)
  #6  
Old 05-21-2010
harry qin harry qin is offline
Flexsim User
 
Join Date: Apr 2010
Posts: 19
Downloads: 5
Uploads: 0
Thanks: 19
Thanked 0 Times in 0 Posts
Rep Power: 123
harry qin is on a distinguished road
Default

Hi,Lars-Olof,thanks,I thought you were busy then and didn't tend to disturb you.
May be i don't understand your method very well.But I can't add a new source to generate items as the order.All i can do is pulling items from rack.Because my source's arriving mode obeying a certain distribution mode.And i can't make the rack's inventory to zero.Because I have to analyse the inventory's value too.And I don't know how to charge the output time in your mothed.Can you explain?
__________________
Harry Qin
  #7  
Old 05-21-2010
Lars-Olof Leven Lars-Olof Leven is offline
Flexsim Distributor
 
Join Date: Aug 2007
Location: Sweden, Borlnge
Posts: 312
Downloads: 278
Uploads: 2
Thanks: 300
Thanked 256 Times in 139 Posts
Rep Power: 330
Lars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to behold
Default

Hi,

I think you need to explain what you try to simulate.
For example:
  • I have 4 racks with products, each rack have only one product.
  • I get an order from an order system that which tell me which product and how many of that product
  • etc.
With out this explanation it is almost impossibly to give you help that will put you in the right direction.

Remember that in the source you can use the schedule mode you schedule when an order should arrive.
You may also need to write your own logic to tell what product you should pick and how many of it.

First try to explain in words what you try to simulate and what question you want to have answer on.

Lars-Olof
The Following User Says Thank You to Lars-Olof Leven For This Useful Post:
Tom David (05-21-2010)
  #8  
Old 05-21-2010
harry qin harry qin is offline
Flexsim User
 
Join Date: Apr 2010
Posts: 19
Downloads: 5
Uploads: 0
Thanks: 19
Thanked 0 Times in 0 Posts
Rep Power: 123
harry qin is on a distinguished road
Default

laf.Ok,in my model i have some objects as follow:
1. I have four sources and four racks.
One source connects only one rack.Each source will make one type item.This type item will be sent to the only rack.(for example,if itemtype==1, it will be sent rack1).The source doesn't have arrival schedule. it's arrival obeying one distribution(Exponential distribution,Normal distribution,ect).
2.Following the racks i have a queue(or combiner) connecting the four racks.
Then i will make the output from racks by order.I wanna put all the orders in a grobal table which you can see in then next pic.When the time is 50,it is the time to execute order1.I wanna output 1 item1 from rack1,2 item2 from rack2, 2 item3 from rack3,1 item4 from rack4(which is the first row in my global table).when the time is 100,i will execute the order2.
3.Following the queue i have one convoyer and one sink.But these are not important.

I don't know is it clear.Tell me.Thank you.Lars-Olof

btw,what i wanna do by this model is analyse the utilization of transport,the change curve of the inventory,and anyother things.So i can't make the inventory empty.
Attached Thumbnails
Click image for larger version
Name:	未命名.jpg
Views:	220
Size:	12.7 KB
ID:	990  
__________________
Harry Qin
  #9  
Old 05-21-2010
Lars-Olof Leven Lars-Olof Leven is offline
Flexsim Distributor
 
Join Date: Aug 2007
Location: Sweden, Borlnge
Posts: 312
Downloads: 278
Uploads: 2
Thanks: 300
Thanked 256 Times in 139 Posts
Rep Power: 330
Lars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to behold
Default

Hi,

The solution I would use to solve what you want is the one I have proposed.

See the attached file.

Hope you understand what I have done.

Lars-Olof
Attached Files
File Type: zip GlobalTableOrder_LOL.zip (44.8 KB, 217 views)
The Following 2 Users Say Thank You to Lars-Olof Leven For This Useful Post:
Tom David (05-24-2010)
  #10  
Old 05-24-2010
harry qin harry qin is offline
Flexsim User
 
Join Date: Apr 2010
Posts: 19
Downloads: 5
Uploads: 0
Thanks: 19
Thanked 0 Times in 0 Posts
Rep Power: 123
harry qin is on a distinguished road
Default

Thanks,Lars-Olof.Fancy but useful way to deal my problem.An interesting method.
And I am interested in Virtual RACK method too.Thanks,Tom.I will work it out if I can.
__________________
Harry Qin


Thread Thread Starter Forum Replies Last Post
Set Arrival Sequence on reset with global table Patrick Cap Q&A 5 04-08-2009 11:12 PM
Can I make a column of a global table to type table? qin tian Q&A 0 10-01-2008 09:27 PM
Limit in the completion hints? Global Tables, Global Variables, etc.? Tom David Gripes and Goodies 6 09-09-2008 04:05 PM
Reading Stats function from global table David Chan Q&A 4 05-27-2008 08:51 AM
Global Table Number Precision Sung Kim Tips and Tricks 8 03-27-2008 04:25 PM


All times are GMT -6.
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2020, vBulletin Solutions Inc.
Copyright 1993-2018 FlexSim Software Products, Inc.