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

Include duration in the ramping constraints #773

Merged

Conversation

datejada
Copy link
Member

@datejada datejada commented Sep 6, 2024

Pull request details

Describe the changes made in this pull request

Include the duration in the ramping constraints in the RHS of the equations to account for that the ramp parameters are given as rates.

List of related issues or pull requests

Closes #772

Collaboration confirmation

As a contributor I confirm

  • I read and followed the instructions in README.dev.md
  • The documentation is up to date with the changes introduced in this Pull Request (or NA)
  • Tests are passing
  • Lint is passing

Copy link

codecov bot commented Sep 6, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (ce58465) to head (868aa1d).
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff            @@
##              main      #773   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           18        18           
  Lines          891       900    +9     
=========================================
+ Hits           891       900    +9     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@datejada datejada marked this pull request as ready for review September 6, 2024 10:42
Copy link
Member

@abelsiqueira abelsiqueira left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Summary of the comments:

  • Instead of storing a whole vector and computing the minimum, start with a large value and update the minimum every time. It's faster than push! and better for memory. An alternative would be to store a whole vector with predetermined size, but I am not sure that would be faster, and it would definitely use more memory.

@datejada datejada force-pushed the 772-include-durations-ramping-constraints branch from 8fc7a0a to 868aa1d Compare September 8, 2024 19:04
@datejada
Copy link
Member Author

datejada commented Sep 8, 2024

Summary of the comments:

  • Instead of storing a whole vector and computing the minimum, start with a large value and update the minimum every time. It's faster than push! and better for memory. An alternative would be to store a whole vector with predetermined size, but I am not sure that would be faster, and it would definitely use more memory.

@abelsiqueira, thanks for the suggestion. The PR is updated and rebased to the latest version in main 😄 Please let me know if you have more comments.

Copy link
Member

@abelsiqueira abelsiqueira left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR, LGTM.

@datejada datejada merged commit f454e39 into TulipaEnergy:main Sep 9, 2024
7 checks passed
@datejada datejada deleted the 772-include-durations-ramping-constraints branch September 9, 2024 06:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Include durations on the ramping constraints
2 participants