<?xml version="1.0" encoding="UTF-8" standalone="yes"?><oembed><version><![CDATA[1.0]]></version><provider_name><![CDATA[Azimuth]]></provider_name><provider_url><![CDATA[https://johncarlosbaez.wordpress.com]]></provider_url><author_name><![CDATA[John Baez]]></author_name><author_url><![CDATA[https://johncarlosbaez.wordpress.com/author/johncarlosbaez/]]></author_url><title><![CDATA[Network Theory (Part&nbsp;30)]]></title><type><![CDATA[link]]></type><html><![CDATA[<p>The <a href="http://math.ucr.edu/home/baez/networks/">network theory</a> series is back!  You may have thought it died out, but in fact it&#8217;s just getting started.  Over the last year my grad students have made huge strides in working out the math of networks.  Now it&#8217;s time to explain what they&#8217;ve done.</p>
<p>In the last three episodes I explained how electrical circuits made of resistors, inductors and capacitors are a great metaphor for many kinds of <i>complex systems made of interacting parts</i>.  And it&#8217;s not just a metaphor; there are mathematically rigorous analogies&#8212;in other words, <i>isomorphisms</i>&#8212;between such electrical circuits and various other kinds of &#8216;passive linear networks&#8217;.</p>
<p>I showed you a chart of these analogies last time:</p>
<table border="1" align="center">
<tr>
<td> </td>
<td><b>displacement</b>: &nbsp;&nbsp; <img src='https://s0.wp.com/latex.php?latex=q&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='q' title='q' class='latex' /></td>
<td><b>flow</b>: &nbsp; &nbsp;&nbsp; <img src='https://s0.wp.com/latex.php?latex=%5Cdot+q&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='&#92;dot q' title='&#92;dot q' class='latex' />  </td>
<td><b>momentum</b>: &nbsp;&nbsp;&nbsp;&nbsp; <img src='https://s0.wp.com/latex.php?latex=p+&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='p ' title='p ' class='latex' /></td>
<td><b>effort</b>: &nbsp; &nbsp;&nbsp; &nbsp; &nbsp;&nbsp; <img src='https://s0.wp.com/latex.php?latex=%5Cdot+p&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='&#92;dot p' title='&#92;dot p' class='latex' /></td>
</tr>
<tr>
<td><b>Mechanics: translation</b></td>
<td> position</td>
<td> velocity </td>
<td> momentum </td>
<td> force </td>
</tr>
<tr>
<td><b>Mechanics: rotation</b></td>
<td> angle</td>
<td> angular velocity </td>
<td> angular momentum </td>
<td> torque </td>
</tr>
<tr>
<td><b>Electronics</b></td>
<td> charge </td>
<td> current </td>
<td> flux linkage </td>
<td> voltage </td>
</tr>
<td><b>Hydraulics</b></td>
<td> volume </td>
<td> flow </td>
<td> pressure momentum </td>
<td> pressure </td>
<tr>
<td><b>Thermal Physics</b></td>
<td> entropy </td>
<td> entropy flow </td>
<td> temperature momentum </td>
<td> temperature </td>
</tr>
<tr>
<td><b>Chemistry</b></td>
<td> moles </td>
<td> molar flow </td>
<td> chemical momentum </td>
<td> chemical potential </td>
</tr>
</table>
<p>But what do I mean by a &#8216;passive linear network&#8217;?  Let me explain this very roughly at first, since we&#8217;ll be painfully precise later on.</p>
<p>Right now by &#8216;network&#8217; I mean a graph with gizmos called &#8216;components&#8217; on the edges.  For example:</p>
<div align="center">
<img width="400" src="https://i1.wp.com/math.ucr.edu/home/baez/networks/electronics_circuit_diagram.jpg" />
</div>
<p>In a network there is some kind of &#8216;flow&#8217; running along each edge, and also some kind of &#8216;effort&#8217; across that edge.  For example, in electronics the flow is electrical current and the effort is voltage.  The chart shows the meaning of flow and effort in other examples.</p>
<p><a href="http://en.wikipedia.org/wiki/Passivity_%28engineering%29">&#8216;Passivity&#8217;</a> means roughly that none of the components put out energy that didn&#8217;t earlier come in.  For example, resistors lose energy (which goes into heat, which we&#8217;re not counting).  Capacitors can store energy and later release it.  So, resistors and capacitors are passive&#8212;and so are inductors.  But batteries and current sources actually <i>put out</i> energy, so we won&#8217;t allow them in our networks yet.  For now, we&#8217;re just studying how passive components <i>respond</i> to a source of flow or effort.</p>
<p>For some subtleties that show up when you try to make the concept of passivity precise, try:</p>
<p>&bull; <a href="http://en.wikipedia.org/wiki/Passivity_%28engineering%29">Passivity (engineering)</a>, Wikipedia.</p>
<p>Finally, <a href="http://en.wikipedia.org/wiki/Linear_circuit">&#8216;linearity&#8217;</a> means that the flow along each edge of our network is linearly related to the effort across that edge.   Here are the key examples:</p>
<p>&bull;  For electrical resistors, linearity is captured by Ohm&#8217;s law.  If an edge <img src='https://s0.wp.com/latex.php?latex=e&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='e' title='e' class='latex' /> in our network is labelled by a resistor of resistance <img src='https://s0.wp.com/latex.php?latex=R%2C&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='R,' title='R,' class='latex' /> usually drawn like this:</p>
<div align="center"><img src="https://i1.wp.com/math.ucr.edu/home/baez/networks/electronics_resistor_symbol.png" alt="" /></div>
<p>then Ohm&#8217;s law says:</p>
<p><img src='https://s0.wp.com/latex.php?latex=V+%3D+R+I+&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='V = R I ' title='V = R I ' class='latex' /></p>
<p>where <img src='https://s0.wp.com/latex.php?latex=V&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='V' title='V' class='latex' /> is the voltage across that edge and <img src='https://s0.wp.com/latex.php?latex=I&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='I' title='I' class='latex' /> is the current along that edge.</p>
<p>• If our edge <img src='https://s0.wp.com/latex.php?latex=e&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='e' title='e' class='latex' /> is labelled by an inductor of inductance <img src='https://s0.wp.com/latex.php?latex=L&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='L' title='L' class='latex' />:</p>
<div align="center"><img src="https://i2.wp.com/math.ucr.edu/home/baez/networks/electronics_inductor_symbol.png" alt="" /></div>
<p>we have</p>
<p><img src='https://s0.wp.com/latex.php?latex=%5Cdisplaystyle%7B+V+%3D+L+%5Cfrac%7Bd+I%7D%7Bd+t%7D+%7D+&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='&#92;displaystyle{ V = L &#92;frac{d I}{d t} } ' title='&#92;displaystyle{ V = L &#92;frac{d I}{d t} } ' class='latex' /></p>
<p>Here we need to think of the voltage and current as functions of time.</p>
<p>• If our edge <img src='https://s0.wp.com/latex.php?latex=e&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='e' title='e' class='latex' /> is labelled by a capacitor of capacitance <img src='https://s0.wp.com/latex.php?latex=C&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='C' title='C' class='latex' />:</p>
<div align="center"><img src="https://i2.wp.com/math.ucr.edu/home/baez/networks/electronics_capacitor_symbol.png" alt="" /></div>
<p>we write the equation</p>
<p><img src='https://s0.wp.com/latex.php?latex=%5Cdisplaystyle%7B+I+%3D+C+%5Cfrac%7Bd+V%7D%7Bd+t%7D+%7D+&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='&#92;displaystyle{ I = C &#92;frac{d V}{d t} } ' title='&#92;displaystyle{ I = C &#92;frac{d V}{d t} } ' class='latex' /></p>
<p>where again we think of the voltage and current as functions of time.</p>
<p>Both linearity and passivity are simplifying assumptions that we eventually want to drop.  If we include batteries or current sources, we&#8217;re dropping passivity.  And if include transistors, we&#8217;re dropping linearity.  Obviously both these are important!</p>
<p>However, there is a lot to do even <i>with</i> these simplifying assumptions.  And now it&#8217;s time to get started!</p>
<p>In what follows, I will not use the terms &#8216;flow&#8217; and &#8216;effort&#8217;, which are chosen to be neutral and subject-independent.  Instead, I&#8217;ll use the vocabulary from electronics, e.g. &#8216;current&#8217; and &#8216;voltage&#8217;.  The reason is that we&#8217;ve all heard of resistors, capacitors, Ohm&#8217;s law and Kirchhoff&#8217;s laws, and while these have analogues in every row of the chart, it seems pointless to make up weird new &#8216;neutral&#8217; terms for all these concepts.</p>
<p>But don&#8217;t be fooled by the jargon!  We&#8217;re not <i>merely</i> studying electrical circuits.  We&#8217;ll be studying passive linear networks in full generality&#8230; with the help of category theory.</p>
<h3> Linear passive networks as morphisms </h3>
<p>To get going, let&#8217;s think about circuits made of resistors.  We can do this without harm, because we&#8217;ll later include capacitors and inductors using a simple effortless trick.  Namely, we&#8217;ll generalize the &#8216;resistance&#8217; of a resistor, which is a real number, to something called &#8216;impedance&#8217;, which is an element of some larger field.  Everything will be so abstract that replacing resistances with impedances will be as easy as snapping our fingers.</p>
<p>Right now I want to define a category where the morphisms are circuits made of resistors.  Any morphism will go from some &#8216;inputs&#8217; to some &#8216;outputs&#8217;, like this:</p>
<div align="center">
<img width="350" src="https://i2.wp.com/math.ucr.edu/home/baez/networks/circuit_fong_1.jpg" />
</div>
<p>So a morphism is roughly a graph with edges labelled by numbers called &#8216;resistances&#8217;, with some special nodes called &#8216;inputs&#8217; and some special nodes called &#8216;outputs&#8217;.</p>
<p>What can do with morphisms?  Compose them!  So, suppose we have a second morphism whose inputs match the outputs of the first:</p>
<div align="center">
<img width="275" src="https://i1.wp.com/math.ucr.edu/home/baez/networks/circuit_fong_2.jpg" />
</div>
<p>Then we can compose them, attaching the outputs of the first to the inputs of the second.   We get this morphism as the result:</p>
<div align="center">
<img width="450" src="https://i1.wp.com/math.ucr.edu/home/baez/networks/circuit_fong_3.jpg" />
</div>
<p>So, composing morphisms is a way to build big electrical circuits&#8212;or other &#8216;linear passive networks&#8217;&#8212;out of little ones.</p>
<p>This seems pretty simple, but let&#8217;s try to formalize it and see why we have a category.  In fact it takes a bit of thought.  To check that we get a category, we need to check that composition is associative:</p>
<p><img src='https://s0.wp.com/latex.php?latex=%28fg%29h+%3D+f%28gh%29+&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='(fg)h = f(gh) ' title='(fg)h = f(gh) ' class='latex' /></p>
<p>and that each object <img src='https://s0.wp.com/latex.php?latex=x&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='x' title='x' class='latex' /> has an identity morphism <img src='https://s0.wp.com/latex.php?latex=1_x+%3A+x+%5Cto+x&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='1_x : x &#92;to x' title='1_x : x &#92;to x' class='latex' /> that does what an identity should:</p>
<p><img src='https://s0.wp.com/latex.php?latex=f+1_x+%3D+f+&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='f 1_x = f ' title='f 1_x = f ' class='latex' /></p>
<p><img src='https://s0.wp.com/latex.php?latex=1_x+g+%3D+g+&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='1_x g = g ' title='1_x g = g ' class='latex' /></p>
<p>All these equations seem obviously true in our example&#8230; until you try to prove them.</p>
<p>You might think an identity morphism should be a bunch of straight pieces of wire&#8212;a bunch of edges each with an input node and an output node&#8212;but that doesn&#8217;t quite work, since sticking an extra edge onto a graph gives a new graph with an extra edge!</p>
<p>Also, we are composing circuits by &#8216;sticking them together&#8217;.  This process is formalized in category theory using a <a href="http://en.wikipedia.org/wiki/Pushout_%28category_theory%29">pushout</a>, and pushouts are only defined &#8216;up to canonical isomorphism&#8217;.  The very simplest example is the <a href="http://en.wikipedia.org/wiki/Disjoint_union">disjoint union</a> of two sets.  We all know what it means, but if you examine it carefully, you&#8217;ll see it&#8217;s only defined up to canonical isomorphism, because it involves a <i>choice</i> of how we make the two sets disjoint, and this choice is somewhat arbitrary.</p>
<p>All this means the category we&#8217;re after is a bit subtler than you might at first expect; in fact, it&#8217;s most naturally thought of as a <a href="http://arxiv.org/abs/math.CT/9810017">bicategory</a>, meaning roughly that all the equations above hold only &#8216;up to canonical isomorphism&#8217;.</p>
<p>So, we proceed like this.</p>
<p>First we define a concept of &#8216;labelled graph&#8217;, where (for now) only the edges are labelled.  We do this because we want our circuits to have edges labelled by &#8216;resistances&#8217;, which are real numbers.  But we do it in greater generality because later we&#8217;ll want the edges to be labelled by &#8216;impedances&#8217;, which are elements of some other field.  And since we&#8217;re studying electrical circuits just as examples of networks, later still we will probably want graphs whose edges are labelled in still other ways.</p>
<p>So:</p>
<p><b>Definition.</b>  A <b>graph</b> consists a finite set <img src='https://s0.wp.com/latex.php?latex=E&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='E' title='E' class='latex' /> of <b>edges</b>, a finite set <img src='https://s0.wp.com/latex.php?latex=N&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='N' title='N' class='latex' /> of <b>nodes</b>, and two functions</p>
<p><img src='https://s0.wp.com/latex.php?latex=s%2Ct+%3A+E+%5Cto+N&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='s,t : E &#92;to N' title='s,t : E &#92;to N' class='latex' /></p>
<p>Thus each edge <img src='https://s0.wp.com/latex.php?latex=e&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='e' title='e' class='latex' /> will have some node <img src='https://s0.wp.com/latex.php?latex=s%28e%29&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='s(e)' title='s(e)' class='latex' /> as its <b>source</b> and some node <img src='https://s0.wp.com/latex.php?latex=t%28e%29&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='t(e)' title='t(e)' class='latex' /> as its <b>target</b>:</p>
<div align="center"><a href="http://en.wikipedia.org/wiki/Graph_theory"><img width="300" src="https://i1.wp.com/math.ucr.edu/home/baez/networks/graph_directed_with_labels.png" /></a></div>
<p><b>Definition.</b> Given a set <img src='https://s0.wp.com/latex.php?latex=L%2C&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='L,' title='L,' class='latex' /> we define an <b><img src='https://s0.wp.com/latex.php?latex=L&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='L' title='L' class='latex' />-labelled graph</b> to be a graph together with a function <img src='https://s0.wp.com/latex.php?latex=r+%3A+E+%5Cto+L.&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='r : E &#92;to L.' title='r : E &#92;to L.' class='latex' />  This assigns to each edge <img src='https://s0.wp.com/latex.php?latex=e+%5Cin+E&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='e &#92;in E' title='e &#92;in E' class='latex' /> its <b>label</b> <img src='https://s0.wp.com/latex.php?latex=r%28e%29+%5Cin+L.&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='r(e) &#92;in L.' title='r(e) &#92;in L.' class='latex' />  We call <img src='https://s0.wp.com/latex.php?latex=L&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='L' title='L' class='latex' /> the <b>label set</b>.</p>
<p>We use the letter <img src='https://s0.wp.com/latex.php?latex=r&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='r' title='r' class='latex' /> because for circuits of resistors we will take the label set to be</p>
<p><img src='https://s0.wp.com/latex.php?latex=L+%3D+%280%2C%5Cinfty%29+%5Csubset+%5Cmathbb%7BR%7D+&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='L = (0,&#92;infty) &#92;subset &#92;mathbb{R} ' title='L = (0,&#92;infty) &#92;subset &#92;mathbb{R} ' class='latex' /></p>
<p>the positive real numbers, and <img src='https://s0.wp.com/latex.php?latex=r%28e%29&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='r(e)' title='r(e)' class='latex' /> will be the <b>resistance</b> of the edge <img src='https://s0.wp.com/latex.php?latex=e.&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='e.' title='e.' class='latex' />   For circuits that also contain inductors and capacitors we will take the label set to be the positive elements of some larger field&#8230; but more about that later!</p>
<p>Now we want to give our <img src='https://s0.wp.com/latex.php?latex=L&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='L' title='L' class='latex' />-labelled graph a set of nodes called &#8216;inputs&#8217; and a set of nodes called &#8216;outputs&#8217;.  You might think the set of inputs should be disjoint from the set of outputs, but that&#8217;s a tactical error!  It turns out an identity morphism in our category should have the inputs being <i>exactly the same</i> as the outputs&#8230; and no edges at all:</p>
<div align="center">
<img width="250" src="https://i2.wp.com/math.ucr.edu/home/baez/networks/circuit_fong_4.jpg" />
</div>
<p>To handle this nicely, we need to make a category of <img src='https://s0.wp.com/latex.php?latex=L&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='L' title='L' class='latex' />-labelled graphs.  This works in the obvious way, if you&#8217;re used to this stuff.  A morphism from one <img src='https://s0.wp.com/latex.php?latex=L&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='L' title='L' class='latex' />-labelled graph to another sends edges to edges, nodes to nodes, and preserves everything in sight:</p>
<p><b>Definition.</b> Given <img src='https://s0.wp.com/latex.php?latex=L&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='L' title='L' class='latex' />-graphs <img src='https://s0.wp.com/latex.php?latex=%5CGamma+%3D+%28E%2CN%2Cs%2Ct%2Cr%29&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='&#92;Gamma = (E,N,s,t,r)' title='&#92;Gamma = (E,N,s,t,r)' class='latex' /> and <img src='https://s0.wp.com/latex.php?latex=%5CGamma%27+%3D+%28E%27%2CN%27%2Cs%27%2Ct%27%2Cr%27%29%2C&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='&#92;Gamma&#039; = (E&#039;,N&#039;,s&#039;,t&#039;,r&#039;),' title='&#92;Gamma&#039; = (E&#039;,N&#039;,s&#039;,t&#039;,r&#039;),' class='latex' /> a <b>morphism of</b> <img src='https://s0.wp.com/latex.php?latex=L&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='L' title='L' class='latex' /><b>-labelled graphs</b> from <img src='https://s0.wp.com/latex.php?latex=%5CGamma&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='&#92;Gamma' title='&#92;Gamma' class='latex' /> to <img src='https://s0.wp.com/latex.php?latex=%5CGamma%27&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='&#92;Gamma&#039;' title='&#92;Gamma&#039;' class='latex' /> is a pair of functions</p>
<p><img src='https://s0.wp.com/latex.php?latex=%5Cepsilon%3A+E+%5Cto+E%27&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='&#92;epsilon: E &#92;to E&#039;' title='&#92;epsilon: E &#92;to E&#039;' class='latex' /></p>
<p><img src='https://s0.wp.com/latex.php?latex=%5Cnu+%3A+N+%5Cto+N%27&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='&#92;nu : N &#92;to N&#039;' title='&#92;nu : N &#92;to N&#039;' class='latex' /></p>
<p>such that the following diagrams commute:</p>
<div align="center">
<img src="https://i2.wp.com/math.ucr.edu/home/baez/networks/morphism_of_labelled_graphs.jpg" />
</div>
<p>There is a category <img src='https://s0.wp.com/latex.php?latex=L%5Cmathrm%7BGraph%7D&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='L&#92;mathrm{Graph}' title='L&#92;mathrm{Graph}' class='latex' /> where the objects are <img src='https://s0.wp.com/latex.php?latex=L&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='L' title='L' class='latex' />-labelled graphs and the morphisms are as we&#8217;ve just defined them.</p>
<p>Warning: the morphisms in <img src='https://s0.wp.com/latex.php?latex=L%5Cmathrm%7BGraph%7D&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='L&#92;mathrm{Graph}' title='L&#92;mathrm{Graph}' class='latex' /> are not the morphisms of the kind we really want, the ones that look like this:</p>
<div align="center">
<img width="275" src="https://i1.wp.com/math.ucr.edu/home/baez/networks/circuit_fong_2.jpg" />
</div>
<p>They are just a step along the way.  A morphism of the kind we really want is a diagram like this in <img src='https://s0.wp.com/latex.php?latex=L%5Cmathrm%7BGraph%7D&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='L&#92;mathrm{Graph}' title='L&#92;mathrm{Graph}' class='latex' />:</p>
<div align="center">
<img width="205" src="https://i2.wp.com/math.ucr.edu/home/baez/networks/cospan.jpg" />
</div>
<p>where <img src='https://s0.wp.com/latex.php?latex=%5CGamma&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='&#92;Gamma' title='&#92;Gamma' class='latex' /> is an <img src='https://s0.wp.com/latex.php?latex=L&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='L' title='L' class='latex' />-labelled graph and <img src='https://s0.wp.com/latex.php?latex=I%2C+O&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='I, O' title='I, O' class='latex' /> are <img src='https://s0.wp.com/latex.php?latex=L&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='L' title='L' class='latex' />-labelled graphs <i>with no edges!</i></p>
<p>You see, if <img src='https://s0.wp.com/latex.php?latex=I&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='I' title='I' class='latex' /> and <img src='https://s0.wp.com/latex.php?latex=O&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='O' title='O' class='latex' /> have no edges, all they have is nodes.  We call the nodes of <img src='https://s0.wp.com/latex.php?latex=I&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='I' title='I' class='latex' /> the <b>inputs</b> and those of <img src='https://s0.wp.com/latex.php?latex=O&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='O' title='O' class='latex' /> the <b>outputs</b>.  The morphisms <img src='https://s0.wp.com/latex.php?latex=i%3A+I+%5Cto+%5CGamma&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='i: I &#92;to &#92;Gamma' title='i: I &#92;to &#92;Gamma' class='latex' /> and <img src='https://s0.wp.com/latex.php?latex=o+%3A+O+%5Cto+%5CGamma&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='o : O &#92;to &#92;Gamma' title='o : O &#92;to &#92;Gamma' class='latex' /> say how these nodes are included in <img src='https://s0.wp.com/latex.php?latex=%5CGamma.&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='&#92;Gamma.' title='&#92;Gamma.' class='latex' />  <img src='https://s0.wp.com/latex.php?latex=%5CGamma&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='&#92;Gamma' title='&#92;Gamma' class='latex' /> is our circuit made of resistors.</p>
<p>In general, any diagram shaped like this is called a <b>cospan</b>:</p>
<div align="center">
<img width="205" src="https://i2.wp.com/math.ucr.edu/home/baez/networks/cospan.jpg" />
</div>
<p>If we turned the arrows around it would be called a <b><a href="http://ncatlab.org/nlab/show/span#definition">span</a></b>.  Cospans are good whenever you a thing with an &#8216;input end&#8217; and an &#8216;output end&#8217;, and you want to describe how the ends are included in the thing.  So, they&#8217;re precisely what we need for describing a circuit made of resistors, like this:</p>
<div align="center">
<img width="350" src="https://i2.wp.com/math.ucr.edu/home/baez/networks/circuit_fong_1.jpg" />
</div>
<p>This makes us want to cook up a category <img src='https://s0.wp.com/latex.php?latex=L%5Cmathrm%7BCirc%7D&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='L&#92;mathrm{Circ}' title='L&#92;mathrm{Circ}' class='latex' /> where:</p>
<p>&bull; an object <img src='https://s0.wp.com/latex.php?latex=I&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='I' title='I' class='latex' /> is an <img src='https://s0.wp.com/latex.php?latex=L&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='L' title='L' class='latex' />-labelled graph with no edges.  We can alternatively think of it as a finite set: a set of nodes.</p>
<p>&bull; a morphism from <img src='https://s0.wp.com/latex.php?latex=I&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='I' title='I' class='latex' /> to <img src='https://s0.wp.com/latex.php?latex=O&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='O' title='O' class='latex' /> is a cospan of <img src='https://s0.wp.com/latex.php?latex=L&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='L' title='L' class='latex' />-labelled graphs:</p>
<div align="center">
<img width="205" src="https://i2.wp.com/math.ucr.edu/home/baez/networks/cospan.jpg" />
</div>
<p>We still need to say how to compose these morphisms.  We know it will amount to attaching the outputs of one circuit to the inputs of the next&#8212;that&#8217;s all there is to it!  But we need to make this precise and prove we get a category.  And as I&#8217;ve hinted, we will actually get something bigger and better: a <a href="http://arxiv.org/abs/math.CT/9810017">bicategory</a>! This will come as no surprise to if you&#8217;re familiar with span and cospan bicategories&#8211;but it may induce a heart attack otherwise.</p>
<p>This bicategory can then be &#8216;watered down&#8217; to give our category <img src='https://s0.wp.com/latex.php?latex=L%5Cmathrm%7BCirc%7D.&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='L&#92;mathrm{Circ}.' title='L&#92;mathrm{Circ}.' class='latex' />  And when we take</p>
<p><img src='https://s0.wp.com/latex.php?latex=L+%3D+%280%2C%5Cinfty%29+&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='L = (0,&#92;infty) ' title='L = (0,&#92;infty) ' class='latex' /></p>
<p>we&#8217;ll get the category where morphisms are circuits made of resistors!  We&#8217;ll call this <img src='https://s0.wp.com/latex.php?latex=%5Cmathrm%7BResCirc%7D.&#038;bg=ffffff&#038;fg=000&#038;s=0' alt='&#92;mathrm{ResCirc}.' title='&#92;mathrm{ResCirc}.' class='latex' /></p>
<p>Then I&#8217;ll explain what we can do with this category!  There&#8217;s no end of things we could do with it.  But the main thing Brendan does is study the &#8216;black-boxing&#8217; operation, where we take a circuit, forget its inner details, and only keep track of what it does.  This turns out to be quite interesting.</p>
<h3> References </h3>
<p>I thank Brendan Fong for drawing some of the pictures of circuits here.  For the details of what I&#8217;m starting to explain here, read our paper:</p>
<p>&bull; John Baez and Brendan Fong, <a href="http://math.ucr.edu/home/baez/circuits.pdf">A compositional framework for passive linear networks</a>.</p>
<p>You can learn more about the underlying ideas here:</p>
<p>&bull; Dean C. Karnopp, Donald L. Margolis and Ronald C. Rosenberg, <i>System Dynamics: a Unified Approach</i>, Wiley, New York, 1990.</p>
<p>&bull; Forbes T. Brown, <i>Engineering System Dynamics: a Unified Graph-Centered Approach</i>, CRC Press, Boca Raton, 2007.</p>
<p>&bull; Francois E. Cellier, <i>Continuous System Modelling</i>, Springer, Berlin, 1991.</p>
]]></html><thumbnail_url><![CDATA[https://i1.wp.com/math.ucr.edu/home/baez/networks/electronics_circuit_diagram.jpg?fit=440%2C330]]></thumbnail_url><thumbnail_height><![CDATA[325]]></thumbnail_height><thumbnail_width><![CDATA[440]]></thumbnail_width></oembed>