# Tag Info

If I understand correctly the TCP roundtrip time can be used as a posteriori proxi for the order entry gateway delay. So assuming the roundtrip time is composed of gate delay and independent other delays $RTT_g(t) = dT_g(t) + d_g(t)$ with assumed $Cov(dT_g,d_g)=0$ and $Cov(d_i,d_j)=0$. Minimizing the this combination of gate delay and other delays is ...
I think just picking minimum value for $d_i(t)$ will work optimal here, just how calculate that $d()$ function matters more, this can be last order delay from that gateway or some EMA of last X order delays. Important is query each gateway every some amount of time to prevent blocking gateway by one big anomaly delay that prevent $S(t)$ function from ...