Electricity has traditionally been a commodity that is bought and sold through a rigid marketplace between an electric utility and a ratepayer. Today, however, the electricity market is rapidly evolving to be comprised of distributed energy resources and microgrids that change the structure of the technical and financial relationship between utilities and ratepayers. Regulation, a reduction in cost of renewable energy technologies, interoperability and improved communications, and public interest in green power are facilitating this transition. Microgrids require an additional layer of control, often use preprogrammed rule sets, and lack bi-directional selfawareness, self-management, and self-diagnostics necessary to dynamically adapt to changes on-site and in the grid. Research is needed in optimization and controls. This study explores the viability of self-organizing control algorithms to manage multiple distributed energy resources within a distribution network and reduce electricity cost to one or more ratepayers having such resources installed on-site. Such research provides insight into the transition from a traditional power distribution architecture into a flexible smart network that is better prepared for future technological advances, renewables integration, and customer-side control. Agent-based techniques are employed for least-cost optimization and implements these to manage transactions between three decentralized distributed energy resource systems within an electrical network.