Bus rapid transit (BRT) systems are massive transport systems with medium/high capacity, high quality service and low infrastructure and operating costs. TransMilenio is Bogot´a¿s most important mass transportation system and one of the biggest BRT systems in the world, although it only has completed its third construction phase out of a total of eight. In this paper we review the proposals in the literature to optimize BRT system operation, with a special emphasis on TransMilenio, and propose a mathematical model that adapts elements of the above proposals and incorporates novel elements accounting for the features of TransMilenio system.