Optimization Method: FOPDT to Data
![]() | ![]() | ![]() | ![]() | ![]() |
---|
A first-order linear system with time delay is a common empirical description of many stable dynamic processes. The equation
τpdy(t)dt=−y(t)+Kpu(t−θp)
has variables y(t) and u(t) and three unknown parameters.
Kp=Processgain
τp=Processtimeconstant
θp=Processdeadtime
These variables may be adjusted to match data. An explicit solution to the above equation for each time step j is:
yj=e−Δtτp(yj−1−y0)+(1−e−Δtτp)Kp(uj−θp−1−u0)+y0
where Δt is the time step length, y0 is the initial output or steady state condition, u0 is the initial input or steady state condition, yj-1 and uj-1 are values from the prior step and θp is the dead-time measured in number of time steps. When the matching process employs optimization, a model prediction is aligned with the measured values with the use of a solver. The solver often minimizes a measure of the alignment such as a sum of squared errors or sum of absolute errors. An optimization solver for Python is the SciPy.Optimize.Minimize function. Below is a tutorial on solving nonlinear optimization problems in Python.
The optimization can be applied to dynamic models as well. Below are tutorial examples using Excel or Python to adjust the parameters to fit the model predictions to data. Unlike a graphical method to fit an FOPDT model, optimization methods do not require a single step response but may include any sequence of input changes that produce a response in the output.
Fit FOPDT to Data with Excel
Fit FOPDT to Data with Python
Fit FOPDT to Data with PIDTuner
PID Tuner generates models such as an FOPDT from data through a web-interface.

Fit Multivariate Systems with Seeq SysID
Seeq SysID is a system identification package that runs as a Seeq plugin or in a Jupyter notebook.

A model is created for each relationship between manipulated variable (MV) and controlled variable (CV).

Time series, state space, Second Order Plus Dead Time (SOPDT), and FOPDT are model options. Many industrial processes use advanced control methods such as Model Predictive Control for systems with many MVs and CVs.

Graphical Fit versus Regression Fit
The graphical fitting approach is only for data with an input step response or other specialized input sequences. Use optimization to best match an FOPDT model to data with any input sequence or with more complex model. A common objective is to minimize a sum of squared error that penalizes deviation of the FOPDT model from the data. The optimization algorithm changes the parameters Kp,τp,θp to best match the data at specified time points.
Generate Simulated Data from Model

FOPDT Fit to Data
