Veda2.0 Released!


UC on (average) investment cost
#1
Dear community

I am trying to implement lower and upper bounds for the annual investments in all car-technologies.
So far, I have implemented this in a scenario-file as an absolute lower and upper investement-budget in the milestone years 2020, 2030, 2040, and 2050 (see attached). However, working with these absolute numbers is not ideal, because the model invests in each year in a different total number of cars (capacity).

Therefore, it would be ideal if I could replace the fixed annual investment-budgets by an alternative budget that takes into account (1) The real-world average car price (let's say 40,000 USD per car) and (2) the amount of capacity that the model installs in the given year. 
For each year - 2020, 2030, 2040, and 2050 - the bound should be the product of the average car price and the installed capacity in the given year.

Is it possible to implement a variable in the UC, where I don't know the value is determined during the simulation, i.e. the amount of capacity installed in a given year?

If yes, could you please help me with setting up a User Constraint that takes this value into account?
If no, do you have suggestions for an alternative approach to tackle my above described issue?

I look forward to hearing back from you!

Thanks,
Sandro

PS: Now the attachement is added. Sorry for the inconvenience.


Attached Files
.xlsx   Scen_InvestmentUC.xlsx (Size: 207.09 KB / Downloads: 21)
Reply
#2
There was no attachment, and so the current approach was not fully illustrated.

Quote:For each year - 2020, 2030, 2040, and 2050 - the bound should be the product of the average car price and the installed capacity in the given year.

Yes, if that's what you want, I think it would imply just replacing the RHS constant by zero, and subtracting that product from the original LHS expression (or, by putting that product on the RHS side). The product can be defined by using UC_NCAP(uc_n,side,r,t,p) = real-world average car price(t).  Putting the product on the RHS side (using UC_NCAP(uc_n,RHS,r,t,p)) would require additionally using UC_ATTR(r,uc_n,RHS,NCAP,SYNC).
Reply
#3
(27-04-2020, 01:29 PM)Antti-L Wrote: There was no attachment, and so the current approach was not fully illustrated.

Quote:For each year - 2020, 2030, 2040, and 2050 - the bound should be the product of the average car price and the installed capacity in the given year.

Yes, if that's what you want, I think it would imply just replacing the RHS constant by zero, and subtracting that product from the original LHS expression (or, by putting that product on the RHS side). The product can be defined by using UC_NCAP(uc_n,side,r,t,p) = real-world average car price(t).  Putting the product on the RHS side (using UC_NCAP(uc_n,RHS,r,t,p)) would require additionally using UC_ATTR(r,uc_n,RHS,NCAP,SYNC).


Thanks for your feedback!
It seems like something went wrong when uploading the attachement in the first place. Now the attachement is really added to the first post. Please feel free to look into my initial approach again.

In the meanwhile, I am now trying to implement what you suggested. I will come back when it works or when something stays unclear.
Reply
#4
Ok, thanks for the attachment.

It reveals that you are using the INVCOST modifier, which is an "annuity modifier". Quote from the documentation:

"The annuity modifiers are applied to the variable terms by summing the VAR_NCAP
variables over all vintage periods tt ≤” t that have an annual investment payment in period t,
and multiplying these with the annual cost coefficient. The INVCOST modifier applies the
investment cost payments."

As you can see from the description, your expression on the LHS is the sum of annuities paid on the Milestone year of the constraint. Thus, I think it is not actually directly comparable with real-world average car price(t) multiplied by the installed capacity in that period.  This is because 1) the installed capacity in a period comprises the installed capacity in the whole period, not in a single year, and 2) the annuities are usually much larger than the price divided by the lifetime, especially if using NCAP_DRATE.

Possibly using the COST modifier might suit better here for your intended purpose?
Reply
#5
(27-04-2020, 04:08 PM)Antti-L Wrote: Ok, thanks for the attachment.

It reveals that you are using the INVCOST modifier, which is an "annuity modifier". Quote from the documentation:

"The annuity modifiers are applied to the variable terms by summing the VAR_NCAP
variables over all vintage periods tt ≤” t that have an annual investment payment in period t,
and multiplying these with the annual cost coefficient. The INVCOST modifier applies the
investment cost payments."

As you can see from the description, your expression on the LHS is the sum of annuities paid on the Milestone year of the constraint. Thus, I think it is not actually directly comparable with real-world average car price(t) multiplied by the installed capacity in that period.  This is because 1) the installed capacity in a period comprises the installed capacity in the whole period, not in a single year, and 2) the annuities are usually much larger than the price divided by the lifetime, especially if using NCAP_DRATE.

Possibly using the COST modifier might suit better here for your intended purpose?

Dear Antti-L

Thank you so much for the very informative and helpful response. 
In the meanwhile, I gave your comments some thoughts and looked deeper into this issue.

You mentioned that perhaps the COST-modifier might suit better for the intended purpose of defining a money budget range that consumers have to invest (only investment cost) on new cars in one year or in a range of years (I aim to represent how much money the population spends on cars). One issue is that I don't know upfront in how many cars the model will invest and therefore don't know the absolute cost-range - however, I know the average amount of money spent per car and the model should invest in different cars with different prices to match this average price +/- 20%. 

So far, my model uses NCAP_COST where for each process (cars) the investment cost is defined (e.g. 10,000USD for investing in one car). I am not sure how I would have to use the COST modifier for binding my model with such a above-mentioned money budget for the average of all cars the model invests in. Could you please elaborate how you would suggest implementing this with the COST-modifier?

For the time being, I am still trying to implement the money budget with the INVCOST modifier and to understand this attribute better. There are a few things which are not yet 100% clear to me. If you could answer the following questions, this would help me a lot in understanding some details of the typical TIMES-linguistic - and therefore the issues discussed in this thread:

  1. You wrote "the installed capacity in a period comprises the installed capacity in the whole period, not in a single year":
    So, when I have a period from 2017 to 2023 with INVCOST defined for the MS-year 2020, then the INVCOST-modifier would have to take the annual investment costs for all new capacities between 2017 and 2023 into account? This means that the INVCOST-constraint would refer to the following annual investment costs (example: investing each year in NCAP=1 car with 10,000USD investment cost and 20 years lifetime; let's assume there is no discount rate):
    • NCAP installed in 2017: Annual investment costs in 2017 - 2023 (INVCOST in 2020 refers to 3500USD = 10,000USD / 20 year * 7 years)

    • NCAP installed in 2018: Annual investment costs in 2018 - 2023 (INVCOST in 2020 refers to 3000USD = 10,000USD / 20 year * 6 years)

    • NCAP installed in 2019: Annual investment costs in 2019 - 2023 (INVCOST in 2020 refers to 2500USD = 10,000USD / 20 year * 5 years)

    • ...

    • NCAP installed in 2023: Annual investement costs in 2023 (INVCOST in 2020 refers to 500USD = 10,000USD / 20 year * 1 years)
      --> Would this be correct? Or would the INVCOST-modifier in 2020 see probably only NCAP installed until 2020, even though the period goes until 2023?



  2. You wrote "the annuities are usually much larger than the price divided by the lifetime, especially if using NCAP_DRATE" : Let's assume that I would not use a discount rate. Could you please elaborate why the annual investment cost is much higher than the price divided by the lifetime? 

  3. When I have one period from 2017 to 2023 with MileStone-year 2020, and defined INVCOST-value for 2020. Does this INVOST-bound take only the investments for new capacities during the years 2017 to 2020 into account? Or from 2017 to 2023?

  4. (following-up from the question before) When I have an additional INVCOST-bound in 2030 (MS-year of the next period, which goes from 2024 - 2036), does this one take all investments and new capacities from 2021 to 2030 into account? Or only those of the years that belong to same period like the year 2030?


I would highly appreciate your reply and any explanations. If anything is unclear, please let me know.

Best,
Sandro
Reply
#6
To explain the use of the COST modifier:
You are using NCAP,INVCOST under the column UC_ATTR~LHS. To use the COST modifier, just put NCAP,COST under it instead of NCAP,INVCOST.

By doing so, you would get the total (overnight) investment cost of the cars in each whole period.  By additionally using the BUILDUP modifier, you would get the investment costs divided by the number of years from T−1 to T (which would give you exactly the average annual investments, if you use OBJ=MOD).

Concerning the INVCOST modifier, as I said, it gives you the total amount of annuities paid in each Milestone year (i.e. in a single year of each period). Annuities refer to annual investment payments, which are paid annually over the economic lifetime of the physical asset related to the investment. These annuities can be from investments in the current period and also in any preceding period, because there are usually annual payments left from the investments in earlier periods as well (in accordance with the economic life). In each Milestone year, there can be annual investment payments only from those investments that have occurred in that Milestone year or earlier. The expression for the annual payments is described in the documentation; the payments are calculated with the capital recovery factors, and thereby normally result in considerably larger payments than the price divided by the lifetime, even if no NCAP_DRATE is used. It is all fully explained in the documentation.

INVCOST can thus be used when you want to refer to the amount of annual investment payments, which may have e.g. budget constraints. However, as mentioned, one should understand that these annual payments include the impact of the interest rate (according to general discount rate or NCAP_DRATE), as you can immediately see from the capital recovery factor. But of course, if we assume that both G_DRATE and NCAP_DRATE are zero, then there would be no impact of interest rate.
Reply
#7
Thanks for your explanations about the COST and INVCOST modifier. This made it more clear why the COST-modifier should be favored for the issue I am facing.

I am working with a larger model where I cannot just change the OBJ Function Variant. The model uses OBJ=Auto with selected "OBLONG" and "Mid-year Discounting". Does your specification give me in this case not the average annual ivestments?

I didn't work with the BUILDUP modifier before and would like to understand its meaning more in detail. In the documentation (version from July 2016), BUILDUP is only mentioned as possible UC in chapter 2.1, which refers to section 6.4.6 for more information. Unfortunately it misses in section 6.4.6, where I hoped to find more detailed information about this modifier, and i can also nowhere else find more information about the detailed meaning of BUILDUP. Could you point me to the right direction to find more information about BUILDUP?

Thanks again for your support!
Reply
#8
The documentation, Parts I–V, is available on Github.

https://github.com/etsap-TIMES/TIMES_Documentation/blob/master/Documentation_for_the_TIMES_Model-Part-II.pdf

It says: The BUILDUP modifier can only be applied only to the NCAP terms of user constraints,
when such exist. The NCAP term for each process is divided by the lead time (LEAD(T))
of the milestone year T of the NCAP variable, when the modifier is used, to get the annual
build-up of the new capacity.


I mentioned it just for curiosity, because I think it can be convenient. But you don't need to use the BUILDUP modifier.  I already explained to you a long time ago (in April 2020) that you can put the total investments in the period on the LHS side and the total installed capacity multiplied by (your average price ± X%) on the RHS side, and replace the RHS constant by zero.  But apparently you didn't want to take my suggestion.  Confused
Reply
#9
(10-06-2020, 01:27 PM)Antti-L Wrote: The documentation, Parts I–V, is available on Github.

https://github.com/etsap-TIMES/TIMES_Documentation/blob/master/Documentation_for_the_TIMES_Model-Part-II.pdf

Very good to know, I wasn't aware of this updated verison on Github. Thanks!

(10-06-2020, 01:27 PM)Antti-L Wrote: I already explained to you a long time ago (in April 2020) that you can put the total investments in the period on the LHS side and the total installed capacity multiplied by (your average price ± X%) on the RHS side, and replace the RHS constant by zero.  But apparently you didn't want to take my suggestion.  Confused

I tried to implement it now as you suggested (see attached file) with:
  • UC_ATTR~LHS: NCAP_COST

  • UC_ATTR~RHS: NCAP & SYNC

  • UC_NCAP~RHS: minimum/maximum value of average car price (I selected now by purpose extreme relaxation factors to make sure the model can find an optimal solution)

  • RHS Constant (CH-column): 0


Despite the extreme relaxation factors, the model becomes infeasible once I introduce such constraints. I already tried to deactivate all other constraints to make sure it doesn't interfer with something else, but it doesn't help. 
Probably I have defined the UC wrong and it represents something else than I have envisaged? Or does the UC look good from your perspective?

Thanks again!


Attached Files
.xlsx   Scen_InvestmentUC v2.xlsx (Size: 211.79 KB / Downloads: 9)
Reply
#10
Well, you are not using the COST modifier, although I suggested to use it.
You have NCAP_COST under UC_ATTR~LHS, which I guess is not meaningful (I am not sure how VEDA treats that).  Maybe you can post a screenshot from the VEDA Browse for UC_ATTR ?  But anyway, I suggested to put NCAP,COST under UC_ATTR~LHS.

Ahh... and I see that you no longer have any UC_NCAP term on the LHS, although you had one in your original version. So, you have removed the LHS term. But using the COST modifier for NCAP naturally requires that you do have an NCAP term on that side.
Reply
#11
(12-06-2020, 08:16 PM)Antti-L Wrote: Well, you are not using the COST modifier, although I suggested to use it.
You have NCAP_COST under UC_ATTR~LHS, which I guess is not meaningful (I am not sure how VEDA treats that).  Maybe you can post a screenshot from the VEDA Browse for UC_ATTR ?  But anyway, I suggested to put NCAP,COST under UC_ATTR~LHS.

Ahh... and I see that you no longer have any UC_NCAP term on the LHS, although you had one in your original version. So, you have removed the LHS term. But using the COST modifier for NCAP naturally requires that you do have an NCAP term on that side.

Aha, it seems I misunderstood the documentation with regard to the COST modifier. I thought I would have to use NCAP_COST to apply the COST-modifier for NCAP.

Now I have adapted the two things you mentioned: 
  1. Replacing NCAP_COST with NCAP,COST at UC_ATTR~LHS

  2. Adding the UC_NCAP~LHS with "1"-values again.



I have tested the model with those changes at it seems to work as wished - great! :-)

There are two things that are not yet fully clear to me: 
  1. Why does the RHS constant (column "CH") has to be 0? To which variable is this constant referring in this equation?

  2. My model contains also other cost terms for cars, such as NCAP_FOM, which should not be relevant for this constraint. Do I understand it correct that this UC takes now only the capacity investment costs into account and not such other costs??


I did browse the VEDA-FE to send you a screenshot, but I couldn't find "UC_ATTR" there. Can you specify where I should find this?

Thank you very much!
Reply
#12
Ok, good to hear that you got it working.

1. Why does the RHS constant (column "CH") has to be 0?

Because a) you always must have an RHS constant defined (any UC constraints are generated only when there is an RHS constant), and b) in this case the formulation of the constraint does not include any non-zero RHS constant, and so the constant must be zero. Besides, the RHS constant is the only way to pass the constraint type information (FX, LO, UP) to TIMES.

2. Do I understand it correct that this UC takes now only the capacity investment costs into account and not such other costs?

Sure, the COST modifier for NCAP refers to NCAP_COST. For activity (ACT) it refers to ACT_COST, and for flow (FLO) it refers to FLO_COST. There is currently no modifier for referring to NCAP_FOM, but if there were, I guess it would be called 'FOM'.

I can find all the UC_ATTR defined in my models under the Basic Functions → Browse → TIMES View. If you don't find them there, I think your VEDA must be malfunctioning...  but I am sure you have them there.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)