question

pc neo avatar image
0 Likes"
pc neo asked pc neo commented

FloWorks Time until next event error

I encounter the exception of "Time until next event error". I do not understand why?

error.png

The error will appear when the value for the OFT Storage max storage to be set at 0.001.

capture.png

However, if the value is change to 0.005 or 0, it model will run without error.

Attached is the model.

Any help is appreciated. sample-model.fsm

FlexSim 18.2.2
FloWorkstimetime until next event error
error.png (40.8 KiB)
capture.png (8.1 KiB)
sample-model.fsm (90.9 KiB)
· 1
5 |100000

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

pc neo avatar image pc neo commented ·

Adding in more description for the sample-model.fsm.

In this model, when the OGV is full and leaves the berth, the barges that are unloading onto the OGV will be "forced" to travel out of berth if they still hold some contents, otherwise they will stay at the berth and continue through the post-processing stage. The idea is to have the barges travel to other berths to fill up other OGVs.

The way that is done to "force" the barges out of the berth is done by first disconnect the loadingarm from the barge compartment and than have it travel out.

Hope this helps in understanding the model.

0 Likes 0 ·

1 Answer

Mischa Spelt avatar image
1 Like"
Mischa Spelt answered pc neo commented

Hi,

The problem you are seeing is a rounding issue. Computers cannot represent all floating point numbers accurately so they will store the closest number they can. Therefore, sometimes you will set a value to 0.4 and when you read it back you will get 0.3999999998. In FloWorks, we try to detect these issues and fix them - for example when we find the content of a tank is 0.00000001 below the maximum, we consider it as full and fire the On Full trigger.

The problem you are seeing when you set the OGV Storage to 0.001 is caused by this. Apparently your OGV size is a multiple of the barge size, so when you fill the OGV storage you will end up with a situation where you will bring in a full barge to fill the last 0.001 of the OGV's tank. Since the barge unload rate is 4000, this will only take a time of 0.001 / 4000 < 10 -6 time units. This falls below our detection threshold. Apparently when you set the OGV storage to 0.005 it does not (I have not checked but I think the threshold lies at 10-6). When you set the OGV storage to 0 the problem does not occur because your barges will always exactly fill up the OGV.

Possible solutions to the problem are:

If you do not want storage:

  • Set the content to 0
  • Keep its inputs and outputs closed
  • Adapt your Process Flow not to connect to it in the first place

If you do need a very tiny storage, consider changing the model time units to seconds instead of hours. In general, we never make FloWorks models in anything other than seconds or maybe minutes, because the rounding errors occur more easily with large time multiples especially when you have small content changes with large flow rates.

I hope that helps, please let me know if you require any additional support.

· 1
5 |100000

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

pc neo avatar image pc neo commented ·

thank you :). I will opt for changing to model units from hours to minutes.

0 Likes 0 ·