1. A method of developing a set of computer readable control algorithms stored on non-transitory computer readable media for simulation of operation of a microgrid system, including: developing a model of a physical form of the microgrid system; identifying a plurality of loads and sources in the modeled microgrid system; assigning one or more state variables to each of the loads and sources in the modeled microgrid system, wherein the state variables represent a plurality of possible states; implementing candidate algorithmic control structures on the modeled microgrid system as state machine model elements that simulate control of the respective state variables of the loads and sources, wherein the state variables represent power routing of the microgrid system; simulating operation of the microgrid system according to the implemented candidate control algorithmic control structures; determining an overall power balance on the microgrid system based on individual states of aggregate system power sources and loads of the model, wherein the power balance is based on a value of each of the state variables of each of the loads and sources; selecting an optimal set of the algorithmic control structures for use in performing simulations of the microgrid, said selection being based on the selected set of control algorithms being capable of controlling a simulation of a desired simulation period within a minimal amount of computer processing time; and storing the selected set of control algorithms on the non-transitory computer readable media.