Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Introduce variable for storage losses #1090

Merged
merged 8 commits into from
Jul 10, 2024
Merged

Introduce variable for storage losses #1090

merged 8 commits into from
Jul 10, 2024

Conversation

p-snft
Copy link
Member

@p-snft p-snft commented Jul 9, 2024

I think it makes a lot of sense, e.g. for adding custom constraints, to have an explicit variable for the losses of the storage. Note that the formula for the relative lasses is more complicated

losses(t) = energy(t) * (1-(1-b)**tau))
energy(t+1)= energy(t)-losses(t)

vs

energy(t+1) = energy(t) * (1-b)**tau

but I think the additional variable and constraint is useful and the 1-(1-b)**tau instead of (1-b)**tau changes a value in the lp file, so it will not significantly increase computational time.

PS: I existentially pushed this change to dev, so this PR reverts the revert.

@p-snft p-snft self-assigned this Jul 9, 2024
p-snft and others added 2 commits July 9, 2024 12:00
This commit includes changed line orders in the LP files,
as the order is just random and I was too lazy to change
everything by hand.
I didn't actually touch this but having a separate PR
doesn't make too much sense, IMHO.
This one first slipped through due to too many irrelevant changes
in the LP files. I now added a unit test that is independent of lp files.

Note that the formula is more complicated but it just changes a value
in the lp file, so it will not significantly increase computational time.
@p-snft p-snft requested a review from a team July 9, 2024 14:30
@p-snft p-snft marked this pull request as ready for review July 9, 2024 14:31
@p-snft p-snft added this to the v0.5.x milestone Jul 10, 2024
@Maxhi77
Copy link

Maxhi77 commented Jul 10, 2024

The possibility to add custom constraint for the losses looks advantageous to me

@p-snft p-snft merged commit 9e06569 into dev Jul 10, 2024
14 checks passed
@p-snft p-snft deleted the feature/storage_losses branch July 10, 2024 08:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants