-
|
Hello, sorry for disturbing you. I tried to use comparison on SecFld type and found that only operator supported is '=='. For the other operators, it will return a type error. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
|
Comparisons like Mathematically it does not really make sense to support comparisons like |
Beta Was this translation helpful? Give feedback.
Comparisons like
<are (currently) not supported for (secure) field elements. To get secure integers with comparisons you can use types created withmpc.SecInt().Mathematically it does not really make sense to support comparisons like$<$ for finite fields because such an order lacks common properties such as $a\leq b \wedge c\leq d \Rightarrow a+c\leq b+d$ . But one can fix an order for the finite field elements anyway, e.g., for a binary field $\mathbb F_{2^n}$ view the elements as nonnegative integers between $0$ and $2^n-1$ . This may be useful in some applications, but is not supported yet in MPyC.