dizk icon indicating copy to clipboard operation
dizk copied to clipboard

remove assumption that first column of constraint system is always 1

Open bh2smith opened this issue 5 years ago • 2 comments

The edited lines were somewhat restrictive to the assumption that the first column of the constraint system is always 1. This does not appear to be necessary (even when the first component of the input vector is 1). The changes here result in equivalent evaluation for the project's example(s) and enables satisfiability for more general constraints systems.

If there is any particular reason for this that I may have overlooked, please let me know.

bh2smith avatar Nov 26 '18 13:11 bh2smith

As an alternative, equivalent, suggestion

The line

final FieldT value = index == 0 ? one : input.get((int) index).mul(terms.get(i).value());

could also be replaced with

final FieldT value = index == 0 ? one.mul(terms.get(i).value()) : input.get((int) index).mul(terms.get(i).value());

But this doesn't appear to add much value.

bh2smith avatar Nov 26 '18 15:11 bh2smith

This would solve Issue #11.

alexpArtos avatar Apr 25 '19 09:04 alexpArtos