Docsity
Docsity

Prepare for your exams
Prepare for your exams

Study with the several resources on Docsity


Earn points to download
Earn points to download

Earn points by helping other students or get them with a premium plan


Guidelines and tips
Guidelines and tips

Introduction to TC, AC and Arithmetic Circuits - Paper | 400 411, Papers of Food science

Material Type: Paper; Class: 400 - FOOD CHEMISTRY; Subject: FOOD SCIENCE; University: Rutgers University; Term: Summer 1999;

Typology: Papers

Pre 2010

Uploaded on 09/17/2009

koofers-user-2lq
koofers-user-2lq 🇺🇸

4.4

(9)

10 documents

1 / 35

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
On TC0,AC
0, and Arithmetic Circuits
Manindra Agrawal
Department of Computer Science
Indian Institute of Technology
Kanpur 208016, India
manindra@iitk.ac.in
Eric Allender
Department of Computer Science
Rutgers University
Piscataway, NJ 08855, USA
allender@cs.rutgers.edu
Samir Datta
Department of Computer Science
Rutgers University
Piscataway, NJ 08855, USA
sdatta@paul.rutgers.edu
May 26, 1999
Abstract
Continuing a line of investigation that has studied the function
classes #P [Val79b], #SAC1[Val79a, Vin91, AJMV], #L [AJ93b,
Vin91, AO94], and #NC1[CMTV96], we study the class of functions
#AC0. One way to define #AC0is as the class of functions computed
by constant-depth polynomial-size arithmetic circuits of unbounded
fan-in addition and multiplication gates. In contrast to the preceding
Part of this research was done while visi ting the University of Ulm under an Alexander
von Humboldt Fellowship.
Supported in part by NSF grants CCR-9509603 and CCR-9734918. Portions of the
work were performed while this author was a visiting scholar at the Institute of Mathe-
matical Sciences, Chennai, India
Supported in part by a Rutgers University Graduate Excellence Fellowship and by
NSF grants CCR-9509603 and CCR-9734918.
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16
pf17
pf18
pf19
pf1a
pf1b
pf1c
pf1d
pf1e
pf1f
pf20
pf21
pf22
pf23

Partial preview of the text

Download Introduction to TC, AC and Arithmetic Circuits - Paper | 400 411 and more Papers Food science in PDF only on Docsity!

On TC

, AC

, and Arithmetic Circuits

Manindra Agrawal∗

Department of Computer Science

Indian Institute of Technology

Kanpur 208016, India

manindra@iitk.ac.in

Eric Allender†

Department of Computer Science

Rutgers University

Piscataway, NJ 08855, USA

allender@cs.rutgers.edu

Samir Datta‡

Department of Computer Science

Rutgers University

Piscataway, NJ 08855, USA

sdatta@paul.rutgers.edu

May 26, 1999

Abstract Continuing a line of investigation that has studied the function classes #P [Val79b], #SAC^1 [Val79a, Vin91, AJMV], #L [AJ93b, Vin91, AO94], and #NC^1 [CMTV96], we study the class of functions #AC^0. One way to define #AC^0 is as the class of functions computed by constant-depth polynomial-size arithmetic circuits of unbounded fan-in addition and multiplication gates. In contrast to the preceding ∗Part of this research was done while visiting the University of Ulm under an Alexander von Humboldt Fellowship. †Supported in part by NSF grants CCR-9509603 and CCR-9734918. Portions of the work were performed while this author was a visiting scholar at the Institute of Mathe- matical Sciences, Chennai, India ‡Supported in part by a Rutgers University Graduate Excellence Fellowship and by NSF grants CCR-9509603 and CCR-9734918.

function classes, for which we know no nontrivial lower bounds, lower bounds for #AC^0 follow easily from established circuit lower bounds. One of our main results is a characterization of TC^0 in terms of #AC^0 : A language A is in TC^0 if and only if there is a #AC^0 function f and a number k such that x ∈ A ⇐⇒ f(x) = 2|x| k

. Using the naming conventions of [FFK94, CMTV96], this yields: TC^0 = PAC^0 = C=AC^0.

Another restatement of this characterization is that TC^0 can be sim- ulated by constant-depth arithmetic circuits, with a single threshold gate. We hope that perhaps this characterization of TC^0 in terms of AC^0 circuits might provide a new avenue of attack for proving lower bounds. Our characterization differs markedly from earlier characterizations of TC^0 in terms of arithmetic circuits over finite fields [RT92, BFS92]. Using our model of arithmetic circuits, computation over finite fields yields ACC^0. We also prove a number of closure properties and normal forms for #AC^0.

1 Introduction

The circuit complexity class AC^0 is well-studied and fairly well-understood. Many lower bound techniques have been developed, showing that exponen- tial size is required in order to compute many simple functions on AC^0 circuits. In contrast, the circuit complexity class TC^0 is only poorly under- stood, in spite of having been the object of many investigations. The class TC^0 is of special interest in computer science, since it characterizes the computational complexity of such important operations as multiplication, division, and sorting, as well as being a computational model for neural nets [RT92, CSV84, PS88]. It remains an open question as to whether every func- tion in #P has TC^0 circuits (although it is at least known that not all #P functions have Dlogtime-uniform TC^0 circuits [All]). The main contribution of this paper is to present a new connection between AC^0 and TC^0. We char- acterize TC^0 as being the class of languages that arises in several ways from counting the number of accepting subtrees of AC^0 circuits. Equivalently, we characterize TC^0 in terms of constant-depth arithmetic circuits. In order to make these notions precise, we need to discuss counting and enumeration classes.

Why study #AC^0? Our motivation comes in large part from a desire to obtain more lower bounds in circuit complexity. As we shall see, #AC^0 straddles the boundary marking the limits of current circuit lower bound technology. #AC^0 provides a characterization of TC^0 (for which no circuit lower bounds are known), but on the other hand #AC^0 is closely related to the classes AC^0 and AC^0 [2], and as a consequence we can prove that many simple functions are not in #AC^0. (This stands in contrast to the related classes #NC^1 , #L, #SAC^1 , and #P which, for all we know, may contain all of the functions in PNP.) We can also show that #AC^0 k is properly contained in #AC^0 k+1 for every k. A better understanding of #AC^0 should aid in advancing our store of lower bound techniques.

1.2 Language Classes

Counting classes such as #P and #L are closely related to associated lan- guage classes such as PP and PL. In order to develop this in a general setting, it is useful to define the “Gap” classes. The class GapP was defined in [FFK94], and by analogy GapL was studied in [Vin91, AO94], and GapNC^1 was studied in [CMTV96]. In all of these cases, there are two equivalent definitions:

  1. GapC is the class of functions that are the difference of two #C func- tions.
  2. GapC is the class of functions computed by the class of arithmetic circuits that characterize #C, when these circuits are augmented by having the constant −1.

(In fact, for the cases when C is one of NC^1 , L, and P, the cited papers give many other equivalent definitions, as well.) Now, for a given class C, GapC gives rise to two language classes:

PC = {A|∃f ∈ GapC, x ∈ A ⇐⇒ f(x) > 0 }, C=C = {A|∃f ∈ GapC, x ∈ A ⇐⇒ f(x) = 0}.

PP and PL were first studied in [Gil77] and have been considered in many papers; C=P was studied in [Wag86] and elsewhere, and C=L was studied in [ABO96] (see also [ST]). PNC^1 and C=NC^1 were defined and studied in [CMTV96] (see also [Mac]).

tion that does yield an alternative characterization of the classes we study was recently presented in [NS99].

A main result of this paper is that PAC^0 and C=AC^0 coincide with TC^0. However, there are two difficulties that must be overcome before we can even state this theorem. We must deal with (a) uniformity, and (b) the fact that the two most natural ways to define GapAC^0 do not seem to be equivalent (although both ways give rise to the same class PAC^0 = C=AC^0 = TC^0 ).

Definition 2 DiffAC^0 is the class of functions expressible as the difference of two #AC^0 functions.

Definition 3 For any k > 0 , GapAC^0 k is the class of functions computed by depth k circuits with +, ∗-gates (the usual arithmetic sum and product) hav- ing unbounded fan-in where inputs to the circuits are from { 0 , 1 , − 1 , xi, 1 − xi} where each xi ∈ { 0 , 1 }. Let GapAC^0 =

⋃ k> 0 GapAC 0 k.

Recall that for all the classes C ∈ {NC^1 , L, SAC^1 , P}, GapC can be defined equivalently either as #C − #C or in terms of arithmetic circuits with access to the constant −1. However, in all of those cases, the proof of equivalence relies on the fact that the PARITY language is in C; and of course this is not true for C= AC^0.

Open Question 1 Is DiffAC^0 = GapAC^0?

Open Question 2 Is (−1)Σxi^ in DiffAC^0?

∏^ (Note that DiffAC^0 is clearly contained in GapAC^0 , and that (−1)Σxi^ = (1 − 2 xi) ∈ GapAC^0 )^2. The classes DiffAC^0 and GapAC^0 each provide reasonable ways to define PAC^0 and C=AC^0. This leads to the following two definitions:

Definition 4 The class C=AC^0 (C=AC^0 circ) consists of those languages L for which there exists a function f in DiffAC^0 (GapAC^0 ) such that for all bit strings x,

  • If x ∈ L then f(x) = 0.
  • If x 6 ∈ L then f(x) 6 = 0.

Definition 5 The class PAC^0 (PAC^0 circ) consists of those languages L for which there exists a function f in DiffAC^0 (GapAC^0 ) such that for all bit strings x,

(^2) Very recently, it has been shown that DiffAC (^0) = GapAC (^0) [ABL98].

Figure 1: Logspace-uniform setting ([ABL98] shows these all coincide)

Figure 2: DLogtime-uniform setting (established here)

Figure 3: DLogtime-uniform setting (established in [ABL98])

We are also able to prove some normal form theorems for DiffAC^0. This allows us to present technically sharper characterizations. For instance, for any set A in (non-uniform or P-uniform) TC^0 , there exist a constant l, a function g(n), and a #AC^0 function h with the following property:

  • If x ∈ A, then h(x) = 2|x| l .
  • If x 6 ∈ A, then h(x) = 2|x| l + g(|x|).

(The function g is computable in Dlogtime-uniform #AC^0. The important point is that g depends only on |x|, and not on x itself.) Thus membership in a TC^0 set is determined in a very precise way by the number of accepting subtrees of a Boolean AC^0 circuit. It seems reasonable to conjecture that all of these classes collapse to TC^0 in the Logspace-uniform and Dlogtime-uniform settings, just as in the P- uniform and non-uniform cases. In the mean time, however, even some very basic properties of the classes C=AC^0 and PAC^0 remain to be established. We list a few such questions below:

Open Question 4 Is C=AC^0 (C=AC^0 circ) closed under complement in the Logspace-uniform (resp. Dlogtime-uniform) setting?

Open Question 5 Is PAC^0 closed under union or intersection in the Logspace-uniform or Dlogtime-uniform setting?

1.4 Organization

In Section 2 we take care of some preliminary matters. In Section 3 we es- tablish some closure properties and normal forms for the classes of functions we study. In Section 4 we prove our main results, characterizing the circuit complexity class TC^0. In Section 5 we briefly consider arithmetic circuits over finite fields. In Section 6 we present some concluding remarks.

2 Definitions and Notation

In this section we establish the notation and conventions used in the rest of the paper.

Definition 6 AC^0 (TC^0 ) is the class of languages accepted by constant- depth circuits of unbounded fan-in AND, OR, and NOT gates (MAJORITY gates, respectively).

an AND then no further restructuring is necessary. If the output gate is an OR of the form ∨mi=1Gi, then replace it by the unambiguous circuit

∨^ m

i=

(Gi ∧ (

i∧− 1

j=

¬Gj )),

and propagate the NOT gates to the leaves. Now consider multiple-output AC^0 circuits. Suppose the output bits bs... b 0 represent the binary representation of the output f(x), then

∨^ s

i=

[bi ∧ Ci]

is the required circuit showing that f(x) ∈ #AC^0 because the number of accepting subtrees is

∑ i bi^2 i.

Our first normal-form theorem is an analog of a statement that is triv- ially true for the classes #P and #L, as well as for other counting classes that can be modeled as the number of accepting paths of some sort of non- deterministic machine, where without loss of generality the machine makes one guess at each step. In the absence of such a model for #AC^0 , a more complicated argument seems necessary.

Theorem 3 For every AC^0 -circuit M (on n inputs) and for all “sufficiently- large” polynomials q(.), there is an AC^0 circuit N (on n inputs) such that,

∀x |x| = n ⇒ #N (x) = 2q(n)^ − #M (x).

Proof. We proceed by induction on the height of M (i.e., the length of the longest path from the root to a leaf). When the height is 0, the circuit consists simply of a literal or a constant (= 0 or 1). Thus #M (x) = 0 or 1. Thus it is sufficient to consider the following circuit,

N =

 

q(n ∨)− 1

i=

Ci

  (^) ∨ M ,

where M denotes the negation of the circuit M. Now, consider a circuit M of height h. There are two subcases:

  • M is a disjunction:

M =

∨^ k

i=

Mi,

where k = k(n) = nO(1)^ is the number of gates feeding into the topmost ∨ gate. In this case, for each Mi, let Ni be the circuit, guaranteed by the inductive hypothesis, such that #Ni(x) = 2q^1 (n)^ − #Mi(x). Let q(n) be any polynomial such that q(n) ≥ q 1 (n) + k(n), and let

N =

[ (^) k ∨

i=

Ni

] ∨

q(n)− ∨q 1 (n)−k

i=

Cq 1 (n).

Then,

#N (x) =

∑^ k

i=

#Ni(x) + (q(n) − q 1 (n) − k) 2q^1 (n)

∑^ k

i=

( 2 q^1 (n)^ − #Mi(x)

)

  • (q(n) − q 1 (n) − k) 2q^1 (n)

= (q(n) − q 1 (n))2q^1 (n)^ −

∑^ k

i=

#Mi(x)

= (q(n) − q 1 (n))2q^1 (n)^ − #M (x).

(In order to massage this into the precise form required, it suffices to appeal to Lemma 5 below.)

  • M is a conjunction:

M =

∧^ k

i=

Mi,

where k = k(n) = nO(1)^ is the number of gates feeding into the topmost ∧ gate. In this case, for each Mi, let Ni be the circuit such that, #Ni(x) = 2q^1 (n)^ − #Mi(x) and let M 0 = C 0. Let

N =

k∨− 1

i=

 Ciq 1 (n) ∧ Nk−i ∧

 

k−∧i− 1

j=

Mj

 

  (^).

Thus, with an appeal to Lemma 4 below, we have,

∑^ k

i=

ai^

( a − ak−(i−1)

) k−(i ∏−1)−^1

j=

aj + (a − ak+1)

∏^ k

i=

ai

∑^ k

i=

ai^

( a − a(k+1)−i

) (k+1) ∏−i−^1

j=

aj +

( a − a(k+1)− 0

) (k+1) ∏−^0 −^1

i=

ai

∑^ k

i=

ai^

( a − a(k+1)−i

) (k+1) ∏−i−^1

j=

aj.

Lemma 5 If q(n) and q 1 (n) are polynomials, and a(n) ∈ FAC^0 , where q(n) ≥ q 1 (n) + log a(n), and if the function a(n)2q^1 (n)^ − f(x) is in #AC^0 , then 2 q(n)^ − f(x) ∈ #AC^0.

Proof. Let c(n) be the value 2q(n)−q^1 (n)^ − a(n), and note that c(n) ∈ FAC^0. Let B(n) = {j | bit number j of the binary representation of c(n) is equal to 1 }. The lemma now follows by considering the following #AC^0 -computable function:

a(n)2q^1 (n)^ − f(x) +

 

j∈B(n)

Cj

  2 q^1 (n)

= a(n)2q^1 (n)^ − f(x) + (2q(n)−q^1 (n)^ − a(n))2q^1 (n) = 2 q(n)^ − f(x).

(End of the proof of Theorem 3.)

Corollary 6 DiffAC^0 = FAC^0 − #AC^0 = #AC^0 − FAC^0.

In fact, we have the stronger statement that if f and g are #AC^0 func- tions, then there exist polynomials q 1 , q 2 and #AC^0 functions h 1 , h 2 such that f(x) − g(x) = 2q^1 (|x|)^ − h 1 (x) = h 2 (x) − 2 q^2 (|x|). To see this, note that f(x) − g(x) = 2n k − ((2n k − f(x)) + g(x)). For large enough constant k, the function ((2n k − f(x)) + g(x)) is in #AC^0 , by Theorem 3.

3.2 Closure Properties

We begin with some simple closure properties. In [FFK94] the notions of “weak sum” and “weak product” were defined as follows:

Definition 8 Let C be a class of functions.

  • C is closed under weak sum if, for any f ∈ C and any k, the function g(x) =

∑nk i=1 f(x, i)^ is in^ C.

  • C is closed under weak product if, for any f ∈ C and any k, the function g(x) =

∏nk i=1 f(x, i)^ is in^ C.

Proposition 7 #AC^0 and GapAC^0 are closed under weak sum and weak product. DiffAC^0 is closed under weak sum.

Proposition 8 DiffAC^0 = GapAC^0 if and only if DiffAC^0 is closed under weak product.

In contrast to the foregoing two propositions, the following closure prop- erty seems to require a much more complicated proof. Although closure under the choose operation is easy to show for classes such as #L and #P, where a machine can simply guess and execute k computation paths simul- taneously, a different argument appears necessary for circuit-based counting classes.

Theorem 9 #AC^0 , DiffAC^0 and GapAC^0 are closed under the choose op- eration (i.e. if f(x) is a function in one of these classes, then so is

(f (x) k

)

for any positive constant k).

Proof.(of Theorem 9) Notice that once we know that #AC^0 is closed under the choose operation, it follows immediately that DiffAC^0 is closed as well (using essentially the same proof as that of Closure Property 5 in [FFK94]). We proceed by induction on the depth of the counting circuit computing the #AC^0 function. If the circuit has depth 0, then the claim follows trivially as f(x) assumes values 0 and 1 only. In order to prove the inductive step, we just need to prove that if f 1 (x),.. ., fn(x) are #AC^0 functions and for some constant k and all j ≤ k,

(f 1 (x) j

) ,... ,

(fn(x) j

)

~b∈Sk

(b 1 + b 2 + · · · + bk)! b 1 !b 2! · · · bk!

( (^) c b 1 +b 2 +···+bk

)(a 1

)b 1 · · ·

(a k

)bk .

Thus we have shown that

(ac k

) can be represented by a sum of πk terms. (As above, note that this equality holds also when a and c are integers.) For ~b ∈ Sk, let

F (n, k) =

(∏ni=1 fi(x) k

) ,

cn =

n∏− 1

i=

fi(x),

an = fn(x),

G(a,~b) =

(b 1 + b 2 + · · · + bk)! b 1 !b 2! · · ·bk!

(a 1

)b 1 · · ·

(a k

)bk .

Then using the above identity involving

(ac k

) , we have:

F (n, k) =

~b

G(an,~b)F (n − 1 ,

∑^ k

i=

bi).

Let R(n, k) denote the number of terms in this sum once the right hand side has been completely expanded as a sum of products. Then,

Claim 10 R(n, k) ≤ π 1 π 2 · · · πknk−^1.

Proof. The claim clearly holds for R(1, k). Now assume that the claim holds for all n′^ < n and all k′^ < k, and consider the induction step. Let S k′ be Sk − {〈k, 0 , , 0 ,... , 0 〉}. Then,

R(n, k) =

~b∈Sk

R

( n − 1 ,

∑ bi

)

= R(n − 1 , k) +

~b∈S k′

R

( n − 1 ,

∑ bi

)

≤ R(n − 1 , k) +

~b∈S k′

R(n − 1 , k − 1)

≤ R(n − 1 , k) + (πk − 1)R(n − 1 , k − 1) < R(n − 1 , k) + πk

( π 1 π 2 · · · πk− 1 (n − 1)k−^2

) ,

where the last inequality holds inductively. Thus,

R(n, k) < π 1 π 2 · · · πk

∑n− 1 i=0 i k− 2 < π 1 π 2 · · · πk

∑n− 1 i=0 n k− 2 = π 1 π 2 · · · πknk−^1.

This completes the proof of Theorem 9 for the #AC^0 case. Closure of GapAC^0 follows by an essentially identical proof. (The basis case needs to be augmented to deal with the constant −1.)

A proof along these lines can also be used to show that #NC^1 is closed under the choose operation – but (as was pointed out to us by David Mix Barrington) a much simpler proof suffices for #NC^1 , since one can show that #NC^1 is closed under the “monus” and “div m” operations for any constant m. (That is, if f is in #NC^1 , then so are the functions max(f(x) − 1 , 0), and df(x)/me.) Although one can show that #AC^0 is also closed under the monus operation, #AC^0 and GapAC^0 are not closed under div m for any m 6 = 2. Proofs of these and other recent results about #AC^0 will appear in upcoming work. This is a good time to observe that #AC^0 is not closed under some more general choose operations. For instance, let f(x) =

∑ i xi;^ f^ is clearly in #AC^0. For any function g(n) 6 = logO(1)^ n, the function

(f (x) g(n)

) is not in #AC^0 ,

since this function is 0 iff f(x) < g(n), and thus the underlying Boolean AC^0 circuit would be computing the g(n)-threshold function, which is not in AC^0

[FKPS85, DGS86]. (This shows merely that

(∑ i xi g(n)

) is not in #AC^0 ; for an

improvement of this result to a lower bound for GapAC^0 , see Theorem 11.) This argument leaves open the question of what happens when g(n) 6 = O(1) but g(n) = logO(1)^ n. For g in this range, the g(n) threshold is computable in AC^0 [FKPS85, DGS86], but the currently-known proofs of this fact do not preserve the number of accepting subtrees.

Open Question 6 Are the functions

(∑ i xi log n

) and

(∑ i xi log∗^ n

) in #AC^0?

Theorem 11 For every integer k ≥ 2 , there are infinitely many integers n with the property that there is some j ≤ log^3 k 2 n, such that there is no GapAC^0 k -circuit of size ≤ nlog k− (^1) n computing the function ( ∑n i=1 xi j

)

Further results relating to closure properties of these classes may be found in [AABDL].

4 C=AC^0 = PAC^0 = TC^0

The most important step in proving this characterization involves showing how to simulate threshold circuits.

Theorem 12 P-uniform TC^0 ⊆ P-uniform C=AC^0 and Dlogtime-uniform TC^0 ⊆ Dlogtime-uniform C=AC^0 circ.

Proof. We will need to use the following well-known fact (see e.g. [PS88]),

Fact 13 A problem is in TC^0 if and only if it is accepted by a constant- depth family of “exact-threshold” gates ETmm/ 2 (an ETsr gate has s inputs and outputs 1 iff exactly r of them are 1).

We will present a polynomial time algorithm that proceeds by induc- tion on the depth of a TC^0 -circuit^ C^ (composed only of^ ET^ m/m 2 gates) and constructs a DiffAC^0 (or Dlogtime-uniform GapAC^0 ) circuit f, such that, if C(x) = 0 then f(x) = 0, and if C(x) = 1 then f(x) is equal to a constant independent of x. The following paragraph provides details for the base case of depth 1 circuits. Let Km be

∏m j=0,j 6 =m/ 2 (m/^2 −^ j). It is easy to see that the function

∆(x 1 , x 2 ,.. ., xm) =

∏ j 6 =m/ 2 ((

∑ i xi)^ −^ j) Km

is 1 if

∑ i xi^ is^ m/2 and is 0 otherwise (the^ xi’s are Boolean variables). Thus ∆(x 1 , x 2 ,... , xm) = ET (^) m/m 2 (x 1 , x 2 ,... , xm). Consider the function P (X) =

∏ j 6 =m/ 2 (X^ −^ j).^ The naive algorithm that multiplies the terms (X − j) together to explicitly compute the coefficients of powers of X runs in polynomial time. (Note that the binary representations of the coeffi- cients are only polynomially long). Separating the positive and negative terms we get P (X) = Q(X) − R(X), where Q(.) and R(.) are polynomi- als with coefficients that can be computed by P-uniform #AC^0 circuits. Thus Q( ∑ i xi)^ −^ R(

∑ i xi) is a P-uniform DiffAC^0 function that is equal to 0 if C(x) = 0, and is equal to Km if C(x) = 1. On the other hand

∏ j 6 =m/ 2 ((

∑ i xi)^ −^ j) is already a Dlogtime-uniform GapAC (^0) function with

this property. This completes the basis step of our inductive argument. For the inductive step, in order to prove P-uniform TC^0 ⊆ P-uniform C=AC^0 , our inductive hypothesis will be: for every P-uniform family {Cn} of exact-threshold circuits, for every d, there is a function computable in time polynomial in n that, on input (n, Cn, C) outputs circuits Dn, D ′ n of depth O(d) such that if C is a gate at level d of Cn then for all x of length n, C(x) = 0 implies Dn(x)−D ′ n(x) = 0 and^ C(x) = 1 implies^ Dn(x)−D

′ n(x) = (Km)t^ (where t = t(m, d) is some function depending only on d and m). Note that we have established this claim for the case d = 1. Consider a depth d +1 exact-threshold circuit with output gate G, where the inputs to G are Gi (i = 1... m). We show how to construct, in polynomial time, a DiffAC^0 function that takes values (Km)t(m,d+1)^ = (Km)mt(m,d)+ and 0 whenever G outputs 1 and 0 respectively. Let the DiffAC^0 function corresponding to Gi be Fi = fi − gi (fi, gi are #AC^0 functions). From Theorem 3 we know that there exists an integer q and an #AC^0 function hi such that Fi = fi − gi = hi − 2 q. Furthermore, q depends only on the depth d and the size of Cn. Now the output of G is

( F 1 Ktm

Fm Ktm

)

∏ j 6 =m/ 2

( ∑ K^ i tFi m −j

)

Km

∏ j 6 =m/ 2 ((

∑ i Fi)−jK tm ) K mmt+

∏ j 6 =m/ 2 ((

∑ i hi)−m^2 q (^) −jKtm) K mmt+

Q′^ (∑ i hi )−R′^ (∑ i hi ) K mmt+^.

Here Q′ (.) and R′ (.) are polynomials with coefficients in #AC^0. They are obtained by expanding the product

∏ j (X^ −^ (m^2 q (^) + jKt ∑ m)) (where^ X^ = i hi) and separating the positive and negative terms. Just as in the base case their coefficients can be computed in time polynomial in n, and hence can be computed by P-uniform #AC^0 circuits constructed by our algorithm. To prove Dlogtime-TC^0 ⊆ C=AC^0 circ is even simpler. Inductively suppose the GapAC^0 function corresponding to Gi is Fi. Then proceeding the same