Smart management energy systems in industry 4.0