Energy storage in Micro-grid and Smart grid