From ae58bc5824d5cfb0316ed06f5eb7b14e7ba20270 Mon Sep 17 00:00:00 2001 From: marcbeunardeau88 Date: Fri, 18 Oct 2024 16:59:22 +0200 Subject: [PATCH] o1vm/pickles: fix selectors constraints --- o1vm/src/interpreters/mips/constraints.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/o1vm/src/interpreters/mips/constraints.rs b/o1vm/src/interpreters/mips/constraints.rs index 73a0bb59a8..ac55009cef 100644 --- a/o1vm/src/interpreters/mips/constraints.rs +++ b/o1vm/src/interpreters/mips/constraints.rs @@ -12,7 +12,7 @@ use crate::{ lookups::{Lookup, LookupTableIDs}, E, }; -use ark_ff::{Field, One, Zero}; +use ark_ff::{Field, One}; use kimchi::circuits::{ expr::{ConstantTerm::Literal, Expr, ExprInner, Operations, Variable}, gate::CurrOrNext, @@ -632,9 +632,9 @@ impl Env { (var.clone() - one.clone()) * var.clone() }) .collect(); - let enforce_one_activation = (0..N_MIPS_SEL_COLS).fold(E::::zero(), |res, i| { + let enforce_one_activation = (0..N_MIPS_SEL_COLS).fold(E::::one(), |res, i| { let var = self.variable(MIPSColumn::Selector(i)); - res + var.clone() + res - var.clone() }); enforce_bool.push(enforce_one_activation);