Page 1 of 1

bad lookup initializing delay

Posted: Tue May 19, 2020 1:47 pm
by Baschwitz
Hello,

I am using the delay conveyor function to exit units from a stock precisely each year.
I have two error messages:
bad lookup initializing delay
floating point error

Are these two errors related

Sometimes when I start a run it even crashes Vensim which closes suddenly and then the file closes each time it is reopened.

Thank you for your help,
AB

Re: bad lookup initializing delay

Posted: Tue May 19, 2020 2:11 pm
by Administrator
It looks like there is a bug with the :EXCEPT: statements, I'm looking into it now.

In the meantime, you can use the attached model and CIN file to do what you need to. I've put the lookup table into the CIN file, to use it, you click Model->Simulate and on the changes tab, click "Load changes from" and select the CIN file.

Re: bad lookup initializing delay

Posted: Mon May 25, 2020 9:06 am
by Baschwitz
Hello,
Thank you for your quick answer. I will look at your proposal. I don't know the CIN files...
Did you have time to look further where there is a bug?

Thanks,
AB

Re: bad lookup initializing delay

Posted: Mon May 25, 2020 9:27 am
by Administrator
There is a bug here, but it's not something we can fix quickly. It's related to the :EXCEPT: statements for the lookups.

CIN files are easy to use and are good for keeping input data separate from the model. They are plain text and contain a list of constants/lookups to use in the model.

Re: bad lookup initializing delay

Posted: Tue May 26, 2020 2:45 pm
by Baschwitz
I'm new to VENSIM and I'm having a really hard time with data management.
How do you create a CIN file?
And would it be possible to initialize the conveyor with information year by year rather than like this:
(2010,0),(2021,0),(2021,1),(2022,1),
(2022,6),(2023,6),(2023,5),(2024,5),
(2024,3),(2026,3),(2026,1),(2030,1),
(2030,0),(2050,0))

Thanks,
AB

Re: bad lookup initializing delay

Posted: Tue May 26, 2020 3:54 pm
by Administrator
CIN files are plain text, you can create them with any text editor (including Vensim).

Click File->Edit text and that will get you started.

Regarding initialisation, you can do it year by year. To create the sample CIN file, all I did was copy/paste the values from your model.

Re: bad lookup initializing delay

Posted: Tue May 26, 2020 4:14 pm
by tomfid

Re: bad lookup initializing delay

Posted: Tue Jun 30, 2020 7:49 am
by Baschwitz
Hello,
I've made a bit of progress on the issue of CIN files and the initialisation of lookups. However, when I change Something in the CIN and then Simulate and "load changes from" it does'nt take the changes into account. What am I doing wrong?
Thanks in advance,
Anne

Re: bad lookup initializing delay

Posted: Tue Jun 30, 2020 10:38 am
by Administrator
Can you detail step by step what you are doing? CIN files work fine for me.

Re: bad lookup initializing delay

Posted: Mon Jul 27, 2020 1:48 pm
by Baschwitz
Hello,
I had finally succeeded in initializing my lookup (before I did not do correctly to choose the file in "simulation control") but now when I want to edit file to see the lookups.CIN file it suddenly closes VENSIM. And I didn't do anything new except install the new version of VENSIM ... Can you help me?
Can you also explain to me how to present this data more simply with data for each time step.
Thanks in advance, Anne

Re: bad lookup initializing delay

Posted: Mon Jul 27, 2020 1:57 pm
by Administrator
Are you on Windows or Mac? And what is the exact version of Vensim you are using?

>> Can you also explain to me how to present this data more simply with data for each time step.
The format of the data is hopefully fairly easy to follow. For example, if I wanted an additional point in the lookup below at time = 2010.5,

change
PROFIL D'ARRÊT OU DE PROLONGEMENT DE L'EXISTANT[GENII 1450](
(2010,0),(2039,0),(2039,1),(2043,1),(2043,0),(2050,0))

to
PROFIL D'ARRÊT OU DE PROLONGEMENT DE L'EXISTANT[GENII 1450](
(2010,0),(2010.5,1),(2039,0),(2039,1),(2043,1),(2043,0),(2050,0))

Re: bad lookup initializing delay

Posted: Tue Jul 28, 2020 7:20 am
by Baschwitz
Hello,I am on Windows. Last week I have installed the latest version 8.1.0 of the Vensim DSS.

For me, since I have lots of datas to enter to initialise the conveyors (18 subscripts over 40 years) it would be easier just to take them from an excel file with one line the time and one line the datas.

Thanks in advance,
Anne

Re: bad lookup initializing delay

Posted: Tue Jul 28, 2020 7:35 am
by Administrator
Are you using the new GUI? If yes, can you try Tools->Switch back to old sketch, hopefully the text editor will now work.

How long do things stay on the conveyor? You only need to initialize the conveyor for this period. 40 years does seem like a long conveyor. But I don't know what you are attempting to build a model of.

Re: bad lookup initializing delay

Posted: Tue Jul 28, 2020 8:24 am
by Baschwitz
What is the new GUI?
No, I think I am with the old one since it says "switch to new sketch (beta)
The text editor doesn't work in the old or new version.

I am modelling the energy sector and some power plants have 40 years of lifetime.

Anne

Re: bad lookup initializing delay

Posted: Tue Jul 28, 2020 10:29 am
by Administrator
I'm getting version 8.1.1 ready at the moment, that should fix the text editor problems.

>> I am modelling the energy sector and some power plants have 40 years of lifetime.
ok. Do you really need the conveyor to be 40 years long?

Re: bad lookup initializing delay

Posted: Tue Jul 28, 2020 12:09 pm
by Baschwitz
OK for the new version. But I have the impression of always falling on the bugs of Vensim...

Regarding the question of the conveyors, I do not understand what you are saying. If I want the power plant to remain in the conveyor for the duration of its lifespan, the lifespan has to be 40 years. I must therefore distribute the initial units over the 40 years, musn't I?

Besides I have another question: in the attached file I modeled more simply the lookup. But as a result, I don't have exactly integer numbers of power plants that are shut down every year. It looks like it interpolates the datas and takes the mid-year value? But that's not what I want. I want to keep integer numbers of power plants.

Thanks,
Anne

Re: bad lookup initializing delay

Posted: Tue Jul 28, 2020 2:15 pm
by tomfid
I generally avoid conveyors, because the discrete lifetime implied is not realistic for most capital goods. Early or delayed retirement is common. A third order delay is often sufficient to capture the distribution.

A conveyor is more realistic for something like mortgages or bonds, which have a fixed lifetime, though even then, aggregation may inject enough diversity into the lifetime for this not to matter.

Re: bad lookup initializing delay

Posted: Tue Jul 28, 2020 3:06 pm
by Baschwitz
what you are explaining may work when the number of units is large. In my model these are energy production plants that I install and uninstall. They must be whole numbers and not half factories. And they have specific lifespans.

Anne

Re: bad lookup initializing delay

Posted: Tue Jul 28, 2020 3:30 pm
by tomfid
Makes sense. Because the number of units is small, it might be simpler to have an array of individual units, rather than using conveyors. Then each unit can easily have a unique retirement date, and that date can be changed if there's a retrofit, accident, etc.