openfermion.measurements.apply_constraints

Function to use linear programming to apply constraints.

operator FermionOperator

FermionOperator with only 1- and 2-body terms that we wish to vectorize.

n_fermions int

The number of particles in the simulation.

modified_operator FermionOperator

The operator with reduced norm that has been modified with equality constraints.