Category Theory
Zulip Server
Archive

You're reading the public-facing archive of the Category Theory Zulip server.
To join the server you need an invite. Anybody can get an invite by contacting Matteo Capucci at name dot surname at gmail dot com.
For all things related to this archive refer to the same person.


Stream: deprecated: chemistry

Topic: a puzzle from today's meeting


view this post on Zulip Sophie Libkind (May 03 2022 at 20:04):

Given a polynomial dynamical system, is it the law of mass action applied to some Petri net with rates?

view this post on Zulip Sam Tenka (May 03 2022 at 20:11):

My guess is yes (contrary to the claim! So my guess is probably wrong, but as an educational exercise I'll try to prove my guess tp see why...)

view this post on Zulip Sophie Libkind (May 03 2022 at 20:29):

@Sam Tenka, it would help me parse this if you used Latex! 1+1=21 + 1 = 2

view this post on Zulip Sophie Libkind (May 03 2022 at 20:29):

This is a very cool feature of Zulip imo :smiley:

view this post on Zulip Sam Tenka (May 03 2022 at 20:30):

@Sophie Libkind oh ah cool! I'll rewrite in LaTeX\LaTeX shortly!

view this post on Zulip Sam Tenka (May 03 2022 at 20:52):

NOTE :
my original proof from tens of minutes ago had an (easy-to-fix) arithmetic error, but instead of fixing it in a minimal way, I chose to replace it by an essentially different and somewhat simpler construction.

SETUP:
Let XX be a finite set of formal variables. The latter generate the ring R=R[X]R = \mathbb{R}[X]. A formal diffeq is an X|X|-tuplet (fx:xX)RX(f_x : x \in X) \in R^X of members of RR; each formal diffeq determines an actual diffeq (first order with X|X| equations): (Dx=fx(y:yX):xX)(D x = f_x(y : y\in X) : x\in X). Here, DD denotes differentiation-wrt-time.

Another structure we consider is that of a chemistry homework problem (CHP): a CHP is a member of M(R0×M(X)×M(X))M(\mathbb{R}_{\geq 0} \times M(X) \times M(X)). Here, M:SetSetM:\textsf{Set}\to\textsf{Set} is the "finite multiset constructor". MM sends a set to the set of finite multisets whose every member is in that set. Though MM is a functor with great properties, we're introducing it merely to save ink. Of course, the terminal object in Set\textsf{Set} induces for each XX a map weightX:M(X)M(1)=N\text{weight}_X:M(X)\to M(1)=\mathbb{N}. Using this and pullbacks, it's not hard to make the good ol' "tell me the multiplicity in a given multiset of an element" function countX:M(X)×XN\text{count}_X:M(X)\times X \to \mathbb{N}. Terminals and pullbacks are both limits, so it seems that counting is more "rightish/limity" than "leftish/colimity".

The point is that each CHP cc induces an formal diffEQ as follows: for each xXx\in X we define fx=(r,lin,lout)c(yliny)(countX(lin,x)+countX(lout,x))f_x = \sum_{(r,l_{in},l_{out}) \in c} (\prod_{y \in l_{in}} y) \cdot (- \text{count}_X(l_{in}, x) + \text{count}_X(l_{out}, x)).

Sam's CLAIM:
every formal diffEQ arises as above from some CHP.

PROOF (with a gap discussed at end):
Let's just construct cc from (fx:xX)(f_x : x\in X).
Observing that the construction from CHPs to formal diffEQs sends disjoint unions to component-wise sums, it suffices to consider the case where one fxf_x is a monomial and the other fyf_y's are zero. Say that fx=syLyf_x = s \cdot \prod_{y \in L} y, where sRs \in \mathbb{R} and LM(X)L \in M(X).

Well, if sR0s \in \mathbb{R}_{\geq 0} is non-negative, then we make the CHP c=[(s,L,yX(δ(y,x)+countX(L,y))[y])]c = [(s, L, \sum_{y\in X} (\delta(y,x)+\text{count}_X(L,y)) \cdot [y])]. Here, summing multisets just sums their multiplicities; multiplying a multiset by a natural number just multiplies all the multiplicities accordingly; and δ(y,x)\delta(y,x) is one on the diagonal and zero elsewhere. One verifies by staring hard that cc is a CHP and that it induces the desired formal diffEQ.

What if s=ss=-|s| is negative? Well, we make a CHP c=[(s/countX(L,x),L,[])]c^\prime = [(|s|/\text{count}_X(L,x), L, [])]. This gives us the right behavior for DxD x, but it decreases the concentrations of the other species too much; to fix this, we just apply the non-negative case to add more elements into our CHP to cancel out those decreases. One verifies by staring hard that making cc from cc^\prime in this way induces the desired formal diffEQ --- EXCEPT that in the process of staring hard, one finds that cc^\prime ain't always a well-defined CHP, since we might divide by zero!!!!!

Thus, QEND --- quod erat non demonstrandum.

REMARK:
the above proof works so long as the "diagonal counts" (countX(fx,x):xX)(\text{count}_X(f_x, x) : x\in X) are all non-zero (i.e. positive integers). Call a formal diffEQ for which this holds, everywhere loopy. Then

PROVEN CLAIM:
every everywhere loopy formal diffEQ arises from some chemistry homework problem!

(converse untrue)

view this post on Zulip Sophie Libkind (May 03 2022 at 20:54):

Another useful Zulip tip: You can use the button that looks like :eye: to preview your message before you send it. :stuck_out_tongue:

view this post on Zulip Sam Tenka (May 03 2022 at 20:58):

The above considerations suggest this system:

Dx=y,Dy=0D x = -y, D y = 0
or a cousin
Dx=y,Dy=xD x = -y, D y = -x

Can some invariant argument can show that one of these cannot come from a petri net with nonnegative rates?
I'm not sure!

view this post on Zulip John Baez (May 03 2022 at 21:16):

Sam Tenka said:

The above considerations suggest this system:

Dx=y,Dy=0D x = -y, D y = 0

or this cousin [...]

Can some invariant argument can show that one of these cannot come from a petri net with nonnegative rates?
I'm not sure!

This looks good. If a Petri net with rates gives the equation

ddtx=y \frac{d}{dt} x = - y

the law of mass action says there must be a transition (at least one) whose input is just one y. In theory such a transition could have any number of x's and y's as output, but no such transition can make the concentration of x decrease, as this equation does.

view this post on Zulip John Baez (May 03 2022 at 21:18):

This is not a rigorous proof but it's good enough for me right now.