Skip to content

What's the purpose of method replaceStageCircular() and cycleProblem()? #288

Closed Answered by ManifoldFR
Zionshang asked this question in Q&A
Discussion options

You must be logged in to vote

When using Way 1 to change stages, is there a corresponding need to adjust the solver's workspace?

I notice that Way 2 explicitly requires calling cycleProblem() after problem.replaceStageCircular to properly update internal components like results_, workspace_, and linearSolver_. Does this imply that simply modifying stages through Way 1 might leave these critical solver internals in an inconsistent state, potentially leading to optimization failures in subsequent steps?

Yes unfortunately 😬
There's no automatic mechanism at the moment which will adjust the workspace if the user decides to do something like e.g. change a stage's dimensions (add a constraint, etc). There's no shortcut to…

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
2 replies
@ManifoldFR
Comment options

Answer selected by Zionshang
@Zionshang
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants