Polynomials computed within a number of nodes #
ComputedWithin P s says that the polynomial P, in variables of any type σ, is computed by an
arithmetic circuit with at most s nodes: some n of its variables feed a circuit
c : Circuit (arithSignature K) n 1 whose output is P as a formal polynomial, and
n + c.size ≤ s. Inputs count one node each, like constants, additions and multiplications. This
is the node count of Arora and Barak, Section 6.1 and of the circuits of
Claude, VP ≠ VNP over every field, which are lists of s polynomials,
each a variable, a constant, or the sum or product of two earlier ones. For polynomial families
the convention does not matter: Cslib.Circuits.Arithmetic.mem_VP_iff characterizes VP by
ComputedWithin.
A polynomial is affine (IsAffine) when it is a constant or a * X i + b, and P is an affine
projection of Q (IsAffineProjection) when P arises from Q by substituting an affine
polynomial for every variable. Affine polynomials have total degree at most 1
(IsAffine.totalDegree_le), and substituting affine polynomials into one gives an affine
polynomial (IsAffine.aeval). Substituting affine polynomials into a circuit costs at most four
gates for each input, hence at most a factor five (ComputedWithin.of_isAffineProjection).
Main definitions #
Cslib.Circuits.ArithOp.map: the map of arithmetic signatures along a map of constants.Cslib.Circuits.Arithmetic.ComputedWithin:Pis computed by a circuit with at mostsnodes.Cslib.Circuits.Arithmetic.IsAffine,Cslib.Circuits.Arithmetic.IsAffineProjection: affine polynomials and affine projections.
Main results #
Cslib.Circuits.Circuit.map_eval_arith: ring homomorphisms commute with evaluation.Cslib.Circuits.Circuit.polynomial_mapOp_ringHom: mapping the constants of a circuit maps the coefficients of its polynomials.Cslib.Circuits.Arithmetic.ComputedWithin.add,Cslib.Circuits.Arithmetic.ComputedWithin.mul,Cslib.Circuits.Arithmetic.ComputedWithin.sum,Cslib.Circuits.Arithmetic.ComputedWithin.prod,Cslib.Circuits.Arithmetic.ComputedWithin.rename,Cslib.Circuits.Arithmetic.ComputedWithin.map: closure properties.Cslib.Circuits.Arithmetic.IsAffine.totalDegree_le,Cslib.Circuits.Arithmetic.IsAffine.aeval: affine polynomials have degree at most1and are closed under affine substitutions.Cslib.Circuits.Arithmetic.ComputedWithin.of_isAffineProjection: affine projections cost at most a factor five.Cslib.Circuits.Arithmetic.ComputedWithin.exists_steps: the gate list of a circuit, each entry a variable, a constant, or the sum or product of two earlier entries.Cslib.Circuits.Arithmetic.mem_VP_iff:VPin terms ofComputedWithin.
References #
Polynomials of combined circuits #
Renaming the variables of the polynomial computed by a circuit is evaluating the circuit at the renamed variables.
The arithmetic operation with its constant mapped along f.
Instances For
A ring homomorphism commutes with evaluating an arithmetic circuit.
The polynomial computed by a circuit with constants mapped along f is the circuit evaluated
with the constants C (f a).
Mapping the constants of a circuit along a ring homomorphism maps the coefficients of its polynomials.
Computation within a number of nodes #
P is computed by an arithmetic circuit with at most s nodes, counting its inputs: for some
n, a circuit with n inputs, fed with the variables x, computes P as a formal polynomial,
and n plus the number of its gates is at most s. Constants count as gates.
A bound on the number of nodes may be raised.
A circuit has at least one node: its output is an input or a gate.
Renaming the variables keeps the number of nodes.
Mapping the coefficients along a ring homomorphism keeps the number of nodes.
A variable is computed by one node, an input.
A constant is computed by one node, a constant gate.
A sum costs the nodes of both summands and one addition.
A product costs the nodes of both factors and one multiplication.
A sum of polynomials computed within s nodes each.
A product of polynomials computed within s nodes each.
A polynomial computed within s nodes is entry k < s of a list in which every entry below
s is a variable, a constant, or the sum or product of two earlier entries. The list holds the
values of the wires of the circuit in program order, inputs first, and 0 after them.
A polynomial computed within s nodes has a finite set of constants: along any ring
homomorphism whose range contains them, it is the image of a polynomial computed within s nodes.
The set holds the constants of the gates of a circuit for P, with 0 for the gates
that are not constants.
Affine projections #
P is affine: a constant, or a constant multiple of a variable plus a constant.
An affine polynomial has total degree at most 1.
Substituting affine polynomials into an affine polynomial gives an affine polynomial.
P is an affine projection of Q: substituting an affine polynomial for every variable of
Q gives P.
A projection, which substitutes variables and constants, is an affine projection.
Affine projections cost at most a factor five. Each input of a circuit for Q is replaced
by its own input and at most four gates computing the substituted affine polynomial.
VP #
VP by circuit sizes. A family is in VP exactly when it is a p-family whose members are
computed within a polynomially bounded number of nodes.