1. An engine controller for controlling at least part of an engine of a vehicle during normal use of the vehicle in the field, the engine controller comprising: one or more inputs for receiving one or more input signals from one or more engine sensors; two or more outputs for providing control signals to two or more actuators that control two or more inputs to the engine; a controller coupled to the one or more inputs and the two or more outputs, the controller implementing a multi-parameter model that models the effects of changes in the two or more actuators on each of one or more engine operating parameters; and wherein the controller is configured to use the one or more input signals and adjust two or more actuators of the engine such that a performance index is optimized, wherein the performance index includes terms that are related to the one or more engine operating parameters.