Simulation and case study of AC Microgrid