Multiagent System for Real-Time Operation of a Microgrid in Real-Time Digital Simulator