validate icon indicating copy to clipboard operation
validate copied to clipboard

`$linear_coefficients` does not expand `var_group`

Open edwindj opened this issue 3 months ago • 0 comments

v <- validator(
  pos := var_group(x),
  pos = pos >= 0,
  lin = x + y == 20
)

v$linear_coefficients()

generates the following:

$A
         variable
validator pos x y
      pos  -1 0 0
      lin   0 1 1

$b
         variable
validator CONSTANT
      pos        0
      lin       20

$operators
  >=   == 
"<=" "==" 

Which is not as intended, var_group should be expanded or at least a warning should be generated. See also data-cleaning/deductive#3

edwindj avatar Mar 28 '24 11:03 edwindj