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

Allocation main network initialization #921

Closed
2 of 4 tasks
SouthEndMusic opened this issue Jan 8, 2024 · 0 comments · Fixed by #924
Closed
2 of 4 tasks

Allocation main network initialization #921

SouthEndMusic opened this issue Jan 8, 2024 · 0 comments · Fixed by #924
Labels
allocation Allocation layer

Comments

@SouthEndMusic
Copy link
Collaborator

SouthEndMusic commented Jan 8, 2024

What
There is already initialization of the optimization problems for subnetworks. This is also needed for the main network, which is slightly different.

How

  • Make sure that the model for the main allocation network is initialized first (just do them in ascending order by allocation network ID)
  • When initializing the main allocation model, collect edges to subnetworks (allocation_network_id != 1) in Allocation.main_network_connections.
  • Each edge to a subnetwork is treated as a user in the objective function and constraints of the optimization problem for the main network.
    To clarify: yes, this means that subnetwork can be represented by multiple 'users' in the optimization problem for the main network if there are multiple edges connecting the main network to the subnetwork. This is because the subnetwork will have different demands for each such connecting edge determined by the subnetwork structure. The choice of how to treat the distribution of demand from a subnetwork over these multiple connecting edges has a significant effect on the behavior of the solver, I think especially for non-linear objective functions.
  • In the optimization problems for the subnetworks, add constraints for the supply/capacity coming from the main network.

As discussed with @visr, users within the main network are allowed.

@SouthEndMusic SouthEndMusic added the allocation Allocation layer label Jan 8, 2024
@github-project-automation github-project-automation bot moved this to To do in Ribasim Jan 8, 2024
@SouthEndMusic SouthEndMusic moved this from To do to Sprint backlog in Ribasim Jan 8, 2024
@Jingru923 Jingru923 moved this from Sprint backlog to 🏗 In progress in Ribasim Jan 9, 2024
@SouthEndMusic SouthEndMusic linked a pull request Jan 11, 2024 that will close this issue
SouthEndMusic added a commit that referenced this issue Jan 16, 2024
@github-project-automation github-project-automation bot moved this from 🏗 In progress to ✅ Done in Ribasim Jan 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
allocation Allocation layer
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

1 participant