document model R abstraction

This commit is contained in:
2026-07-06 09:16:13 +02:00
parent 173426c0d1
commit 6c6dc32822
+6
View File
@@ -30,6 +30,12 @@ class Tea3Model:
self.g = self.v[-1] self.g = self.v[-1]
def _abstract_R(self): def _abstract_R(self):
"""
Abstract all monomials involving intermediate R variables.
For each polynomial in ``R_bits``, monomials containing any ``R`` or ``g`` variable are replaced with a variable ``g``.
Monomials involving only ``x``, ``y``, and ``r`` variables are kept unchanged.
"""
one = self.S.one() one = self.S.one()
zero = self.S.zero() zero = self.S.zero()