mdolab / mdolab/pyoptsparse

Non-linear Sparse Constraint Jacobians

Open
#377 5 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

documentation
Dominant language
Python
Stars
270
Forks
123
Avg merge
1d 18h
Merged PRs (30d)
3

Description

Description

The documentation regarding the constraint Jacobians mentions, "However, we have currently assumed that each of the blocks with an X in is a dense sub-block. pyOptSparse allows each of the sub-blocks to itself be sparse."

If I am passing a constraint Jacobian to a non-linear constraint as a simplified pyOptSparse sparse matrix format, the following error is shown, "pyOptSparse Error: The number of nonzero elements for constraint group 'constraint_1' with respect to var_1 was not the correct size. The supplied Jacobian has 1450 nonzero entries, but must contain 526350 nonzero entries." However, the number of nonzero elements in the Jacobian is 1450; the other entries are 0. The shape (725, 726) of the Jacobian is correct. Does the constraint Jacobians to a non-linear sub-block always have to be dense, or can it also be sparse?

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the documentation on constraint Jacobians and the simplified pyOptSparse sparse matrix format. Reproduce the nonlinear-constraint case using the reported (725, 726) Jacobian and error, then determine whether sparse sub-blocks are supported; done means the behavior is resolved or the documentation clearly states the limitation.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
tooling
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.