# Changing Bases: Multistage Optimization for Matroids and Matchings

This paper is motivated by the fact that many systems need to be maintained continually while the underlying costs change over time. The challenge is to continually maintain near-optimal solutions to an underlying optimization problem, without creating too much churn in the solution itself. We model this as a multistage combinatorial optimization problem where the input is a sequence of cost functions (one for each time step); while we can change the solution from step to step, we incur an additional cost for every such change.

We first study the multistage matroid maintenance problem, where we need to maintain a base of a matroid in each time step under changing cost functions and acquisition costs for adding new elements. The online version generalizes online paging. E.g., given a graph, we need to maintain a spanning tree *T* *t* at each step: we pay *c* *t* (*T* *t* ) for the cost of the tree at time *t*, and also | *T* *t* ∖ *T* *t* − 1 | for the number of edges changed at this step. Our main result is a polynomial time *O*(log*m* log*r*)-approximation to the online problem, where *m* is the number of elements/edges and *r* is the rank of the matroid. This improves on results of Buchbinder et al. [7] who addressed the *fractional* version of this problem under uniform acquisition costs, and Buchbinder, Chen and Naor [8] who studied the fractional version of a more general problem. We also give an *O*(log*m*) approximation for the offline version of the problem. These bounds hold when the acquisition costs are non-uniform, in which case both these results are the best possible unless P=NP.

We also study the perfect matching version of the problem, where we maintain a perfect matching at each step under changing cost functions and costs for adding new elements. Surprisingly, the hardness drastically increases: for any constant *ε* > 0, there is no *O*(*n* 1 − *ε* )-approximation to the multistage matching maintenance problem, even in the offline case.