With the push for greater energy conservation, the need for heating and/or power production is being filled by cogeneration facilities. Thus, the search for the best performance at the least cost for such multipurpose plants is made much more difficult by the fact that such facilities must meet differing goals or demands. Such a facility exists at the Ecole Polytechnique Fédérale de Lausanne (EPFL) and has been studied in order to find the optimum modes of operation as a function of time for variations in both the heating and electrical demands this facility must meet. The results of this study are presented here. The plant itself provides heat and electricity for both the EPFL and the University of Lausanne and is projected to supply electricity to the exterior utility grid provided it can be shown to be economically viable. The plant’s primary components include two gas turbines, a heat recovery system, two heat pumps, a set of heat storage tanks, and both medium and low-temperature district heating networks. In order to find the optimum mode of operation, a mixed-integer linear programming approach was used, which balances the competing costs of operation and minimizes these costs subject to the operational constraints placed on the system. The effects of both the cost of the fuel and the costs of electricity sold and bought on the best performance of the system are evaluated. In addition, the important features of the modeling process are discussed, in particular the heat storage tanks, which complicate the optimization of the series of steady-state models used to model the overall quasi-steady-state behavior of the system.