Closed Piranias closed 4 years ago
I don´t think that this is the issue. Can you upload your simulation data and also summarize the output in more detail here? Can you check the json_processed.json for "simulation_annuity" for both simulations?
what simulation data would be helpful? I left all parameters the same in both simulations. Only the project duration was changed in economic_data.csv. In both cases the json_processed.json shows a "simulation_annuity" of 0.0.
Outputs:
for 1 year project duration
for 10 year project duration
what simulation data would be helpful?
I was thinking of the whole input data zipped, or the json_processed zipped. Then I can check if there is anything wrong with the data.
I left all parameters the same in both simulations. Only the project duration was changed in economic_data.csv. In both cases the json_processed.json shows a "simulation_annuity" of 0.0.
That does not sound ideal. I did find the ´simulation_annuity´ to be something else then 0 however in the appropriate assets, so I would need to check your csv/json input files to know what´s going on.
Outputs:
for 1 year project duration
Here, there is PV implemented - but it not completely replace grid consumption, which means that at least storage still has a cost to implement.
for 10 year project duration
Here there is neither of the components PV or storage implemented, which should not be the case. We will have to recheck this.
ok, I sent you the zip via mail
Hi Inia! It was actually not attached to the mail. Ideally, it would be better to post it here anyway, to make it available to all and forever to reference.
here you go ;)
Hi @smartie2076 , did you take a look at the issue and the csv's yet? It would be great to know if this is solved already or if you have a clue what the behaviour is about.
Sorry about that @Piranias, I forgot about this issue as we were developing so many tests. I will take your input and run it through tomorrow.
Hi @Piranias! I am step by step looking into this issue today.
First of all: I found out that the changing project lifetime has nothing to do with a weirdly changing specific capex per unit to be installed:
When lifetime asset == project lifetime
the specific costs are always the same, otherwise, iflifetime < project lifetime
the specific costs increase, as the asset has to be replaced. The specific costs decrease if the lifetime > project life
, as replacement costs benefit the calculation. They close in asymptotically to the 0-cost-axis.
The following calculations - translating this into an annuity and simulation annuity - should not change this trend, as they are only multiplying by a factor.
The code for this test is this one: test_289.py.zip
So, that is not the issue. I will search some more.
I am documenting what I did from here on out.
The discount factor you chose is 1. Usually it is something far below 1, 0.16 or something. Still, when I plot the specific costs with this everything is allright.
input data I did a couple of adjustments to the input files, also because with release v0.3.0 there were some changes in the input files. Additionally, I changed: --- I did not get the timeseries data, so I used the Habour data. --- Without different PV profiles, I used the one I had and adapted the PV panel lifetimes to (lifetime,year,25,20,15) as to make them different in that way. --- The output directions of all three PV were to PV bus 1, and I changed those to individual PV busses. --- I removed the columns in 'fixcost.csv', as they currently are not considered anyway.
I think I mentioned it before in an issue but I think that below very low cost for installing storage capacities are somewhat unexpected from me. 0.2 €/kWh installed Li-Ion battery? I would say something like 700-900. You ran into some strange optimization resutls last time because of this.
,unit,storage capacity,input power,output power
specific_costs,currency/unit,0.2,0,0
Usually, I always connect the DSO/Electricity network through a Transformer Station to the Local Energy System. You connected it direktly. That is fine, but we'll have to see if this has any implications.
Overall, this is the input data I will use: inputs_bug_289.zip
This results in following energy system:
I notice the same issues as you do with the updated input files, @Piranias:
I do have some generation from the cheapest PV panel 1 over the whole year:
And the battery is used as a seasonal storage:
Only electricity consumption from the grid is used to meet demand:
up to 5 years: Substantial PV generation, dispatch profile only changes marginally from the one for 1 year project duration
up to 8 years: Decreasing potential in Battery/PV installation. PV used to decrease consumption in the summer time.
I think that what happens here is that the simulation_annuity (or, as we simulate a year, the specific annuity per installed CAP) of the assets to be installed increases with increasing project lifetime. Reasons for this are:
You can also see this relation in the table above.
To check this issue further, it would be best if we would output the specific (simulation) annuity in a table format in each of our simulations. I will create an issue for this.
Another point could be the amortization type we use (linear). With this, the residual value / re-sales value is much higher for the first investment in a simulation (as it is related to year 0). I think this results in a disproportional repay with short project lives, as the time value of money is not included... (discuss in #247). Sill, the benefit of the re-sales seem to wear off after 5 years in this case.
@SabineHaas this also has implications for the idea we had to simulate degradation of solar panels by "simulating 20 years in a row".
Okay. I think this is all I have to say for now ;)
Do you have comments @Piranias, @SabineHaas?
Hi @smartie2076, sorry for the late reply and thanks for this detailed reply. So overall I cannot follow exactly all the steps about the annuity as I am not familiar with the costs calculation.
With a longer project lifetime, reinvestments into the capacities are necessary, ie. into solar inverters (project lifetime > 15 a) and batteries (project lifetime > 10 a).
this makes sense for me
With a shorter project lifetime, the residual value that is subtracted from the costs is very high, and the annuity therefore really low. With the increasing project duration, the value of the assets at project lifetime decreases - and so the annuity increases.
I do not fully understand this point or what this residual is. But in my point of view the costs should be split equally on all years within this life time and not change in beteen the years.
So do you agree in the end that this is actually a bug that needs to be fixed? Is there somebody working on this already? I am afraid that I'm not a big help here, since I have no idea how the costs are calculated. But I'd aapreciate if somebody could look into this as I think it's of major importance for all simulations.
Just one point about the storage price:
* I think I mentioned it before in an issue but I think that below very low cost for installing storage capacities are somewhat unexpected from me. 0.2 €/kWh installed Li-Ion battery? I would say something like 700-900. You ran into some strange optimization resutls last time because of this.
I don't know where you got that number of 700-900 from. Can you share the reference? I looked into this and here the storage price is defined by 0.2 Euros/kWh. I'd be interested in why you think this is not correct!
Hi @Piranias I feel like this is not really a bug - @SabineHaas what is your take on this?
I have the number from the top of my head, but you can compare eg. this trader. Example: One AGM/PB Battery 12 V x 160 Ah = 1920 Wh = 1.9 kWh costs 290 €. I was citing Li prices, approx.
The 0.2 €/kWh that you found are not the investment costs, but the costs of storing 1 kWh electricity in a battery, judging from the title "Stromspeicher-Preise pro gespeicherter Kilowattstunde" and also the calculation of this value
16.500 € / (10 kWh * 1 Entladetiefe * 10.000 Zyklen * 0,98 Systemwirkungsgrad) = 16,83 Cent pro Kilowattstunde
These are the approximate costs per stored 1 kWh electricity based on the whole lifetime.
@SabineHaas I know we also talked about using the MVS sucessively for multiple years of operation in your case. I think, this would only make sense in an iterative way:
We think that the residual value calculation is incorrect as it does not consider the time value of money when the asset is sold, but a even share of the investment at the lates investment time. This connects to #247 and will fix that issue.
Outcome: @Piranias, please change the residual value calculation here to payment of present value:
capex = capex - linear_depreciation_last_investment * (
number_of_investments * lifetime - project_life
)/(1 + discount_factor) ** (project_life)
With (1 + discount_factor) ** (project_life)
calculating the present value of the sales revenue at the end of the project. Please update the docstrings as well then.
You will also have to change the tests for this function here, specifically 1, 2, 3.
The investment costs are apparently not calculated correctly regarding the project duration. I noticed that changing the project duration changes the installation of pv plants (in my case) completely. (With a project duration of 15 years no pv plants are installed, while with a project duration of one year only pv is used and no grid electricity.) Maybe this is connected to what @smartie2076 posted in #247 ?