Tag mathematics of supply chain