setKnownEffectToPermutation(permutationFunc) {
        this.gate.knownPermutationFuncTakingInputs = permutationFunc;
        this.gate._knownMatrixFunc = _ => Matrix.generateTransition(1 << this.gate.height, permutationFunc);
        this.gate._stableDuration = Infinity;
        this.gate._hasNoEffect = false;
        this.gate._effectPermutesStates = true;
        this.gate._effectCreatesSuperpositions = false;
        this.gate._isDefinitelyUnitary = true;
        return this;
    }
Provides a permutation function asserted to be equivalent to the gate's effect.

Determines various properties of the gate (e.g. unitarity) and also used by tests to check if the gate's shader's
behavior is correct.

@param {!function(val: !int) : !int} permutationFunc Returns the output state for each input state.
@returns {!GateBuilder}