Skip to content

Qelim fixes#106

Merged
Philipp15b merged 3 commits intomainfrom
better-qelim
Dec 19, 2025
Merged

Qelim fixes#106
Philipp15b merged 3 commits intomainfrom
better-qelim

Conversation

@Philipp15b
Copy link
Copy Markdown
Collaborator

Fix for #105, and fix for another typo. Since this code is pretty easy to get wrong, I'd like a second pair of eyes on the fixes.

Fixes #105.

Before, we did qelim with operands that could be infinite. We now
disallow that because it leads to unsoundness (see linked issue).

Instead of checking that the LHS operand is a constant, we now check
that it is finite only. Thus, we now allow expressions with variables
inside. As a consequence, quantifier elimination after prob. choices
with variables inside now works.

I also added support for traversal of the algorithm through parenthesis
expressions. Those don't come from vcgen, but only from user-written
code.
Copy link
Copy Markdown
Member

@darionhaase darionhaase left a comment

Choose a reason for hiding this comment

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

The implemented logic looks good to me. The very basic is_finite check could be improved. But maybe this should be done in a different (future) issue?

Comment thread src/opt/qelim.rs
Comment thread src/opt/qelim.rs
Comment thread src/opt/qelim.rs
Comment thread src/opt/qelim.rs
Comment thread src/opt/qelim.rs
@Philipp15b Philipp15b enabled auto-merge December 19, 2025 15:03
@Philipp15b Philipp15b disabled auto-merge December 19, 2025 15:10
@Philipp15b Philipp15b merged commit 3fb8352 into main Dec 19, 2025
9 of 11 checks passed
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