  Model Predictive Control (MPC) is often tuned by trial and error. When a
baseline linear controller exists that is already well tuned in the absence of
constraints and MPC is introduced to enforce them, one would like to avoid
altering the original linear feedback law whenever they are not active. We
formulate this problem as a controller matching similar to [1]-[3], which we
extend to a more general framework. We prove that a positive-definite stage
cost matrix yielding this matching property can be computed for all stabilizing
linear controllers. Additionally, we prove that the constrained estimation
problem can also be solved similarly, by matching a linear observer with a
Moving Horizon Estimator (MHE). Finally, we discuss various aspects of the
practical implementation of the proposed technique in some examples.
