diff --git a/class/LogicFunction.php b/class/LogicFunction.php index c1ae9cf..e2750fc 100644 --- a/class/LogicFunction.php +++ b/class/LogicFunction.php @@ -243,7 +243,7 @@ class LogicFunction implements JsonSerializable if ($r == "1") { $term = "("; for ($j = 0; $j < $N; $j++) { - $inv = (($i >> ($N - $j - 1)) & 1) ? "~" : ""; + $inv = (($i >> ($N - $j - 1)) & 1) ? "" : "~"; $term .= $inv . $this->input_vars[$j]; if ($j < ($N - 1)) { $term .= " & ";