question

Sofia G21 avatar image
0 Likes"
Sofia G21 asked Sofia G21 commented

Tracked variable equals the sum of various processor labels

I have labels created at multiple processors on Simulation Start called "Repetitions". I want to make a tracked variable that is the sum of the Repetitions labels from 3 processors. How can I do that?

FlexSim 22.2.0
labelstracked variables
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

Jeanette F avatar image
0 Likes"
Jeanette F answered Sofia G21 commented

Hello @Sofia G21,

I set the labels on the processors to tracked variables so that then an event triggered source can tell when they change. Then the processors labels are summed and saved to a global variable.

Sum processor labels.fsm


· 3
5 |100000

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

Sofia G21 avatar image Sofia G21 commented ·

test.pngHi Jeanette. Thanks for your response!

In trying to replicate your process flow, I notice my 'event triggered source' does not have a "On Label Value Change' option. Is there another approach?

0 Likes 0 ·
test.png (30.4 KiB)
Jeanette F avatar image Jeanette F ♦♦ Sofia G21 commented ·

You have to set your label to be a tracked variable for it to show up as an event for those objects. You can do this by right clicking on the field, selecting assign data, and selecting assign tracked variable data.

1684250432369.png

1 Like 1 ·
1684250432369.png (29.0 KiB)
Sofia G21 avatar image Sofia G21 Jeanette F ♦♦ commented ·
That works!

Thanks for all of your help Jeanette! It was very helpful.

0 Likes 0 ·