A Fast Analytical Method for Economic Dispatch Considering Network Losses