Overflows when using exponentials
see http://seldon.cs.kuleuven.be/idp/?src=55d607f6725aa0680050
I don't know yet if this is solver or grounder related.
Comments (7)
-
reporter -
reporter - edited description
-
reporter - changed title to Overflows when using exponentials
- edited description
This issue occurs because of overflow problems..
Printgrounding reveals
tseitin_504 <=> var_81 = 640942080. tseitin_504. tseitin_505 <=> var_82 = 937459712. tseitin_505. tseitin_506 <=> var_83 = -2049400832. tseitin_506. tseitin_507 <=> var_84 = 1733216256. tseitin_507. tseitin_508 <=> var_85 = 1620131072. tseitin_508. tseitin_509 <=> var_86 = 2025163840.
-
reporter Issue
#816was marked as a duplicate of this issue. -
reporter This issue can be resolved as follows:
-
In src/structure/NumericOperations.cpp take overlows into account. Carefully program this.
-
Make sure that other parts of the code all use these numericoperations. For example in src/Structure/StructureComponents, there still are manual calls to pow, manual sums, ....
-
-
Idea: re-use ArithmeticUtils? These use the "safeint" library that does these overflow checks for us
Or is there a reason not to reuse these?
Edit: is this only related to ints? Also: safeint3 does not support exponentials, but we could loop around this with multiplication.
-
reporter als dat al bestaat, goed idee
- Log in to comment
Related issue (failing on the same file but without CP support) is
#816