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

Trivial cycle resolution #1

Open
mscuttari opened this issue Feb 17, 2022 · 3 comments
Open

Trivial cycle resolution #1

mscuttari opened this issue Feb 17, 2022 · 3 comments
Assignees
Labels
bug Something isn't working

Comments

@mscuttari
Copy link
Member

mscuttari commented Feb 17, 2022

Considering the system of equations:

x + y + z = 1 // eq1: matched x
x + y - z = 2 // eq2: matched y
x - y + z = 3 // eq3: matched z

Explicitating eq1 with respect to x would give x = - y - z + 1
But the substitution within eq2 would yield to - y - z + 1 + y - z = 2
Which is equivalent to 0y - 2z + 1 = 0
And would lead to the division by 0 y = (2z - 1) / 0

The system, however, is trivially solvable with x = 5/2, y = -1, z = -1/2

@mscuttari mscuttari added the bug Something isn't working label Feb 17, 2022
@mscuttari mscuttari self-assigned this Feb 17, 2022
mscuttari added a commit that referenced this issue Jun 8, 2022
@mscuttari
Copy link
Member Author

Commit 7df8123 introduces the detection of division by zero. This allows to stop the compilation process if the issue is detected.

An implementation of the Cramer's rule can now be introduced to solve this issue without relying to external solvers.

@casella
Copy link
Contributor

casella commented Jun 13, 2023

@mscuttari is this issue still open?

If so, do we wait for @StefanoAzzone to finish his job in order to have a proper solution?

@mscuttari
Copy link
Member Author

Yes, the solution is part of Stefano's work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants