question

nicofdz10 avatar image
0 Likes"
nicofdz10 asked Jason Lightfoot edited

how do i set the limit of items created in a source (number)?

Just wanted to know, if I am generating items all the time how to stop the source with one exact number. With the proccessor it´s okay too, the one that is more simple.

FlexSim 23.1.1
limit of items
5 |100000

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

1 Answer

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

Hi @nicofdz10 ,

A simple way to do this is using an Arrival Schedule for your source. This lets you specify each arrival that comes in, the quantity of items in each arrival, and the arrival time. You could also use Arrival Sequence (this option doesn't allow you to specify the time).

Another way to do this is by setting a trigger on your queue to close and open ports. You would want to close input on the current object when the following condition is met: current.stats.input.count >= x, with x being your limiting number.

· 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.

Ignacio H2 avatar image Ignacio H2 commented ·

Hola @Natalie White , me puedes dejar el código para insertarlo? gracias!

0 Likes 0 ·
Jason Lightfoot avatar image Jason Lightfoot ♦♦ Ignacio H2 commented ·

Natalie has supplied the condition expression to use - you just needed to look for the right trigger and action.

1710766208367.png

1710766272292.png


0 Likes 0 ·
1710766208367.png (16.2 KiB)