You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In PiecewiseLinearRotation, only num_state_qubits - 1 + 1 ancillas are ever used at the same time (instead of num_ancillas = num_state_qubits - 1 + len(self.breakpoints)).
For each breakpoint, the exact same ancillas could be reused, instead of changing each time which ancilla are used (by using the i_compare index) (or another way to say it.: everything would work the same if i_compare was fixed to 0 all the time).
In PolynomialPauliRotation, only max(1, min(degree - 1, num_state_qubits - 2)) are needed, instead of num_ancillas = max(1, self.degree - 1). (Because where the ancillas are used, l.341, 343 and 345, we have that len(rotation_coeffs[c]) <= min(degree + 1, num_state_qubits))