This article introduces a modified simulated annealing triple-optimizer for finding the optimal energy management strategy in terms of financial gain maximization in grid-connected, storage-augmented, photovoltaics-supplied prosumer building microgrids in a variable grid price scenario. For evaluating the performance of the optimizer, a number of test cases are specified offering different trading options to the prosumers. Obtained results are compared to a total state space search reference method and demonstrate that the simulated annealing approach was for all test cases able to find a globally optimal or close to optimal solution in significantly less computation time than the total space search reference method.