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

#918 - vertices_list for AbstractHPolygon with infeasible constraints is incorrect #919

Merged
merged 2 commits into from
Nov 17, 2018

Conversation

schillic
Copy link
Member

Closes #918.

@schillic schillic requested a review from mforets November 16, 2018 21:53
@@ -109,6 +123,15 @@ function vertices_list(P::AbstractHPolygon{N},
end
points[n] = element(intersection(Line(P.constraints[n]),
Line(P.constraints[1])))

# check if polygon was empty
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

did you forget to use the flag check_feasibility below?


# check if polygon was empty
avg = sum(points) / length(points)
for c in constraints_list(P)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

note that one could ask for (see this function):

if avg  P
    return Vector{Vector{N}}(undef, 0)
end

@schillic
Copy link
Member Author

Thanks, I rebased.

@schillic schillic merged commit 3f9dda4 into master Nov 17, 2018
@schillic schillic deleted the schillic/918 branch November 17, 2018 13:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants