question

Raul Vazquez avatar image
0 Likes"
Raul Vazquez asked Raul Vazquez commented

Traffic dense visual with A*Star

Hello All,

Is there a way in Flexsim that we can show the traffic by using dense lines like a spaghetti map on the layout.

I guess that is something similar to heat map with A*Sart ,or exist any other that could be measurement?

basically we want to show where we have "dense trafic" after run the model 1 week in order to increase/drecrease the layout..

Thanks

R.V

FlexSim 19.1.0
traffic controla stardensity
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

·
Joshua S avatar image
1 Like"
Joshua S answered Raul Vazquez commented

With the data that can be extracted from A*, drawing lines isn't easily done. The data that can be extracted only gives the amount of time the nodes were allocated. This is how the heat map is generated with the color change surrounding that specific node. Now you could do something else with that data, I attached an example model where all the code can be found on the OnDraw Trigger of the BasicFR1 object to access this data.

astartraffic.fsm


astartraffic.fsm (26.0 KiB)
· 7
5 |100000

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

Raul Vazquez avatar image Raul Vazquez commented ·

Hi @Joshua S. thank a lot for the quick response,

Im new in flexscrip, could you help me to comment the code please?

Could you help me to make this change please?:

-Only increase when we have a different "traveler" in the same "grid"

-I tried to do it(please see attached) but seems to be that does not work

Thanks a lot

travelers.fsm

0 Likes 0 ·
travelers.fsm (31.9 KiB)
Joshua S avatar image Joshua S Raul Vazquez commented ·

So the information you will get from A* is only the hits each node gets from being allocated, not who allocated it. You could try something different with Network nodes and have a counter on each network node of who passed on the node, but there won't be avoidance built in, it will follow predesignated routes.

0 Likes 0 ·
Raul Vazquez avatar image Raul Vazquez Joshua S commented ·

ok, could be a different color by traveler? and the Sphere could be with same size?

0 Likes 0 ·
Show more comments
Raul Vazquez avatar image Raul Vazquez commented ·

Hi @Joshua S

I did this model following the "Operator Location" instead A*Star and does exactly what i need, the only issue is that i need to create manually all the variables and all the user event per "Operator", do you know if there is any way to optimize? please see attached, I mean, only ussing one "variablex" one "variabley" and one "UserEvent" for alll of the travelers?

modelspagghettidiagram-1.fsm

0 Likes 0 ·
Raul Vazquez avatar image Raul Vazquez Raul Vazquez commented ·

Please see my model for reference...fixed doing what i need

modelspagghettidiagram-3.fsm

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.