  Linear-Rate Multi-Mode Systems is a model that can be seen both as a subclass
of switched linear systems with imposed global safety constraints and as hybrid
automata with no guards on transitions. We study the existence and design of a
controller for this model that keeps the state of the system within a given
safe set for the whole time. A sufficient and necessary condition is given for
such a controller to exist as well as an algorithm that finds one in polynomial
time. We further generalise the model by adding costs on modes and present an
algorithm that constructs a safe controller which minimises the peak cost, the
average-cost or any cost expressed as a weighted sum of these two. Finally, we
present numerical simulation results based on our implementation of these
algorithms.
