msolve icon indicating copy to clipboard operation
msolve copied to clipboard

Specify explicitly that repeated monomials in input files are not expected

Open vneiger opened this issue 8 months ago • 4 comments

Fixes #202 .

A note about this has been added in the README file as well as in the tutorial msolve-tutorial.tex.

vneiger avatar Apr 01 '25 21:04 vneiger

Couldn't we at least throw an error when this happens? The current behavior of msolve, which exits with a segmentation fault for arbitrary input, really worries me...

wegank avatar Apr 02 '25 11:04 wegank

Couldn't we at least throw an error when this happens? The current behavior of msolve, which exits with a segmentation fault for arbitrary input, really worries me...

What input do you have in mind, that causes a segmentation fault? (for the one in the linked issue, I thought it would just take the last encountered occurrence of the repeated monomial... ?)

vneiger avatar Apr 02 '25 19:04 vneiger

The easiest one I can think of is to take the example in https://github.com/algebraic-solving/msolve?tab=readme-ov-file#input-file-format and remove the comma on the third line.

wegank avatar Apr 03 '25 07:04 wegank

For this, the README file and the msolve-tutorial.pdf document both specify very clearly that polynomials should be separated by a comma. So we can consider that it is the responsability of the user to respect this requirement. If the user does not respect the specifications, then there are many many ways to trigger segmentation faults in C or with msolve...

This being said, any contribution to improve the file interface would be welcome, I suppose.

vneiger avatar Apr 03 '25 07:04 vneiger