# Polynomials in graphs

I have part of a physical simulation which I've realised can be modelled using a directed graph where each node is a polynomial. I then calculate this graph by functional composition and summing to calculate a "function flow" as shown in the example below.

e.g. three polynomials $f(x)$, $g(x)$, $h(x)$ are connected as follows: $f$ -> $g$ -> $h$

We start at $f(x)$ because it only has an outgoing connection. Because $f(x)$ has an outgoing edge to $g(x)$ we combine them to make $g(f(x))$. Because $g(x)$ has an outgoing edge to $h(x)$ we combine them to make $h(g(f(x)))$. Because $h(x)$ has no outgoing edges we stop.

If there were multiple incoming edges to a node, the incoming polynomials would be summed before the composition. Also loops are allowed as the compositions will converge in my case.

The question is, is this something that has already been studied somewhere? I imagine there are a lot of physical processes like this. It also looks very Category-like.

-
Interesting process, mind stating what you're simulating? –  j.c. Aug 30 '11 at 16:00
Yea, sure. It's a electricity supply chain. So we have a transformer powering a distribution system powering some heavy equipment, for example. The functions are related to losses, which happen to be close enough to polynomial for the types of devices we're looking at. So we want to say things like if I draw x at my equipment end, what should I expect to be drawn at the power socket. –  Kevin Aug 30 '11 at 17:12