interface change of basis; established tests passing#54
Draft
tweisser wants to merge 2 commits intojump-dev:masterfrom
Draft
interface change of basis; established tests passing#54tweisser wants to merge 2 commits intojump-dev:masterfrom
tweisser wants to merge 2 commits intojump-dev:masterfrom
Conversation
blegat
reviewed
Jun 11, 2020
src/constraint.jl
Outdated
| cone = getdefault(model, NonNegPoly()) | ||
| coefs = non_constant_coefficients(constraint.polynomial_or_matrix) | ||
| monos = monomials(constraint.polynomial_or_matrix) | ||
| monos = MB.MonomialBasis(monomials(constraint.polynomial_or_matrix)) |
blegat
reviewed
Jun 11, 2020
src/constraint.jl
Outdated
| kws...) | ||
| coefs = non_constant_coefficients(p) | ||
| monos = monomials(p) | ||
| monos = MB.basis_covering_monomials(basis_type, monomials(p)) |
blegat
reviewed
Jun 11, 2020
test/testpolymodule.jl
Outdated
|
|
||
| function JuMP.build_constraint(_error::Function, p::AbstractPolynomialLike, | ||
| s::TestNonNeg; kwargs...) | ||
| s::TestNonNeg; basis_type = MB.MonomialBasis, kwargs...) |
Member
There was a problem hiding this comment.
Maybe replace basis_type by basis to be consistent with SumOfSquares
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Use MultivariateBases for comparing coefficients. Dual is MM.Measure in MB.
The TestNonNegPoly is adapted in a way that it passes the tests, but is not necessarily useful.