Skip to content

EXIT: Converged to a point of local infeasibility. Problem may be infeasible. #719

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

You must be logged in to vote

Corrected the code by changing the line:
nnz_jac_g = n*m;
Added the following code to Jacobian part:

// Define the Jacobian of the constraints
        virtual bool eval_jac_g(Index n, const Number* x, bool new_x, Index m, Index nele_jac, Index* iRow, Index* jCol, Number* values) {
        if (values == NULL) {
            // Return the structure of the Jacobian by setting iRow and jCol
            for (Index i = 0; i < m; i++) {
                for (Index j = 0; j < n; j++) {
                    iRow[i * n + j] = i;
                    jCol[i * n + j] = j;
                }
            }
        }
        return true;
    }

Added the line:
app->Options()->SetStringValue("jacobian_approx…

Replies: 2 comments 7 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
7 replies
@svigerske
Comment options

@wladimirpetrov
Comment options

@svigerske
Comment options

@wladimirpetrov
Comment options

Answer selected by svigerske
@wladimirpetrov
Comment options

@svigerske
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