question

Stan Davis avatar image
0 Likes"
Stan Davis asked Matthew Gillespie commented

HasSpace Return Value Changes Based on Stacking Order??

I am using the HasSpace method in a Find Slot activity. With a X+ > Y+ > Z+ stacking order, the HasSpace is failing to find space for 4 items when there is still plenty of space in the rack (1 slot per bay).

1665409548225.png

It appears it is returning 0 because the items' dimension would exceed the boundary at the back of the rack...

1665411493036.png


However, if I change the stacking order to X+ > Z+ > Y+, HasSpace finds space for all items...

1665410862376.png


With the X+ > Y+ > Z+ stacking order, if HasSpace can't find space on the first row, why doesn't it simply find space by starting a second row??

1665411124696.png


It seems you'll eventually you'll run into the same problem described above regardless of the stacking method. Thanks - Stan

FlexSim 22.2.2
find slothasspace
1665409548225.png (12.6 KiB)
1665410862376.png (149.6 KiB)
1665411124696.png (300.8 KiB)
1665411493036.png (296.4 KiB)
· 6
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 Jason Lightfoot ♦ commented ·

In my quick test it observes the stacking order - can you post your test model?

1665414889800.png

0 Likes 0 ·
1665414889800.png (155.7 KiB)
Stan Davis avatar image Stan Davis Jason Lightfoot ♦ commented ·

Jason, pls see attached model. I sanitized & scaled it down for submission, but it retains its issue.

1665428789882.png

The Find Slot's query also uses PartNo labels which are cleared and applied via 'Clear-Rack_Paint' and 'Update_Paint_Rack' respectively

The size of the items is controlled by the DimTable.

1665430270121.png

The items will be stored for certain changes in size.

I also discovered if the 4 remaining items (Grapes) are placed in the front of the arrival list, they are stored in the rack.

It's a mystery.

Thanks - Stan

Find Slot HasSpace Issue - 10OCT22.fsm


0 Likes 0 ·
Jeanette F avatar image Jeanette F ♦♦ Stan Davis commented ·

Hello @Stan Davis

Something went wrong in your upload. It shows the text in the body of your reply for a model but there is no attachment. Can you please upload again?1665434179945.png

0 Likes 0 ·
1665434179945.png (46.6 KiB)
Show more comments
Joerg Vogel avatar image Joerg Vogel commented ·
@Stan Davis , method hasSpace has got a really simple character. It keeps item orientation and stack each item accordingly the order. Optimizing space and produce a compact block is not its metric. You see it in Jasons picture. There are many holes and some items look like if they are floating.
0 Likes 0 ·
Stan Davis avatar image Stan Davis Joerg Vogel commented ·
Understood. I'm not expecting optimization just placement when there is truly space. Thanks
0 Likes 0 ·

1 Answer

·
Felix Möhlmann avatar image
0 Likes"
Felix Möhlmann answered Matthew Gillespie commented

I can corroborate the observation. This looks like a bug/oversight. It appears that if there is already at least one item in the current "row" and the next item would fit beside it going by its x-size but not by its y-size, the hasSpace method returns a false instead of checking if the item could be placed in a new layer.

This makes sense when the "row" is the first one, because the item not fitting in the y-dimension would mean that it is longer than the rack is deep. But for further rows the rack depth will be different from the available depth.

1665476146863.png

Blue would fit beside green in the x-direction but not y. -> Blue stays in the queue.

1665476218684.png

If blue is the first item in the "row", it is placed in a new layer.


1665476146863.png (113.7 KiB)
1665476218684.png (123.2 KiB)
· 4
5 |100000

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

Stan Davis avatar image Stan Davis commented ·
Thanks Felix.
0 Likes 0 ·
Jeanette F avatar image Jeanette F ♦♦ commented ·
I will send this in as a bug to the dev team.
0 Likes 0 ·
Stan Davis avatar image Stan Davis Jeanette F ♦♦ commented ·
Thanks Jeanette.
0 Likes 0 ·
Matthew Gillespie avatar image Matthew Gillespie ♦♦ commented ·
@Stan Davis @Felix Möhlmann This bug has been fixed for 22.0.10 which comes out next week.
0 Likes 0 ·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

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