I know that the depth of a circuit is the maximal length from an input gate to the output gate of the circuit and its size is its number of gates.
Is there a formula that you can go from depth to size and can someone explain the steps?
I know that the depth of a circuit is the maximal length from an input gate to the output gate of the circuit and its size is its number of gates.
Is there a formula that you can go from depth to size and can someone explain the steps?
First of all, there are several types of (Boolean) circuits:
(There are even more types of circuits. For example, we could vary the set of gates. But such circuits are less commonly encountered.)
For circuits with unbounded fan-in, not much can be said about the relation between depth and side, since there are depth 1 circuits of arbitrary size.
For circuits with bounded fan-in, we can say that a circuit of depth $d$ has size at most roughly $2^d$. It also has size at least roughly $d$. Both of these are tight: a circuit whose shape is a depth $d$ complete binary tree and whose gates are AND computes the AND of $2^d$ inputs in depth $d$ and size roughly $2^d$, and in contrast, you can construct a "path" (a tree where the left child of every internal node is a leaf) which computes the AND of $d$ inputs in size and depth both roughly $d$.
For formulas you cannot improve on these relations, but you can there is another important property: a formula of size $s$ can always be converted to a formula of size $s^{O(1)}$ and depth $O(\log s)$, an operation we call balancing. It is conjectured that the same cannot be said for circuits (this is one interpretation of the $\mathsf{NC^1}$ vs $\mathsf{P}$ question), though every circuit of size $s$ can be converted to depth $s/\log s$.