Chapter 3: Modeling of Linear Time-Invariant Systems
Lesson 4: Electrical Network and Op-Amp-Based System Models
This lesson develops rigorous models for linear electrical networks and operational-amplifier-based circuits used in control systems. Starting from Kirchhoff’s laws and constitutive relations of resistors, inductors, capacitors, and ideal op-amps, we derive linear differential equations suitable for control analysis and simulation, and we connect them to numerical implementations in Python, C++, Java, MATLAB/Simulink, and Wolfram Mathematica with a focus on robotics-related applications such as sensor conditioning and actuator drive electronics.
1. Role of Electrical Networks and Op-Amps in Control
In many control systems, especially in robotics and mechatronics, the actuators and sensors are interfaced through electrical sub-systems: power amplifiers, filters, and signal-conditioning circuits. To treat the overall system as a linear time-invariant (LTI) system, we need mathematical models of these electrical components that are compatible with the mechanical models introduced in previous lessons.
The basic modeling pipeline for electrical networks is:
flowchart TD
P["Physical circuit: R, L, C, op-amps"] --> KCL["Kirchhoff laws + element relations"]
KCL --> ODE["Linear ODEs in currents/voltages"]
ODE --> LAPLACE["Laplace-domain input-output relations"]
LAPLACE --> CTRL["Models used together with mechanical subsystems in control design"]
In this lesson we:
- Recall constitutive laws of R, L, C elements and show how they produce linear ODEs.
- Derive LTI models for simple RL, RC, and RLC networks.
- Develop an ideal op-amp model and apply it to amplifier, integrator, and differentiator circuits.
- Implement these models numerically in several programming languages used in control and robotics.
2. Basic Electrical Elements and Constitutive Relations
We consider three passive elements whose behavior is linear and time-invariant: resistors, inductors, and capacitors. Their voltage–current relations (constitutive laws) are:
\[ \begin{aligned} \text{Resistor:}\;& v_R(t) = R\,i_R(t), \quad R > 0, \\ \text{Inductor:}\;& v_L(t) = L\,\frac{d i_L(t)}{dt}, \quad L > 0, \\ \text{Capacitor:}\;& i_C(t) = C\,\frac{d v_C(t)}{dt}, \quad C > 0. \end{aligned} \]
Energies stored in inductors and capacitors (useful to identify system order) are:
\[ E_L(t) = \tfrac{1}{2} L\,i_L^2(t), \qquad E_C(t) = \tfrac{1}{2} C\,v_C^2(t). \]
For a circuit containing only R, L, C, ideal sources, and (later) ideal op-amps, the combination of:
- Kirchhoff’s Current Law (KCL),
- Kirchhoff’s Voltage Law (KVL), and
- the constitutive relations above
yields linear ordinary differential equations (ODEs) with constant coefficients. The number of state variables (system order) equals the number of independent energy-storage elements (inductors + capacitors), assuming an appropriate choice of state vector (inductor currents and capacitor voltages).
3. Dynamic Models of Simple RL, RC, and RLC Circuits
3.1 Series RL circuit (first-order system)
Consider a series RL circuit driven by an input voltage source \( u(t) \), with current \( i(t) \) through both elements:
\[ u(t) = v_R(t) + v_L(t) = R\,i(t) + L\,\frac{d i(t)}{dt}. \]
Rearranging gives a first-order linear ODE:
\[ L\,\frac{d i(t)}{dt} + R\,i(t) = u(t). \]
For a step input \( u(t) = U_0 \) and initial condition \( i(0) = 0 \), the solution is
\[ i(t) = \frac{U_0}{R}\left(1 - e^{-\frac{R}{L} t}\right). \]
This is a standard first-order response with time constant \( T = \frac{L}{R} \).
3.2 Series RC circuit (first-order system)
Consider a series RC circuit with input voltage \( u(t) \) and capacitor voltage \( v_C(t) \). The current through R and C is the same, denote it \( i(t) \). Then
\[ u(t) = v_R(t) + v_C(t) = R\,i(t) + v_C(t). \]
Using the capacitor law \( i(t) = C\,\frac{d v_C(t)}{dt} \), we obtain
\[ R C\,\frac{d v_C(t)}{dt} + v_C(t) = u(t). \]
Again, a first-order LTI system with time constant \( T = R C \). For a step \( u(t) = U_0 \) and \( v_C(0) = 0 \),
\[ v_C(t) = U_0\left(1 - e^{-\frac{t}{R C}}\right). \]
Such RC circuits are widely used as analog low-pass filters and sensor signal conditioners in robotic systems.
3.3 Series RLC circuit (second-order system)
Now consider a series RLC network with input \( u(t) \) and capacitor voltage \( v_C(t) \) as output. The current \( i(t) \) flows through all components:
\[ u(t) = v_R(t) + v_L(t) + v_C(t) = R\,i(t) + L\,\frac{d i(t)}{dt} + v_C(t). \]
Using \( i(t) = C\,\frac{d v_C(t)}{dt} \), we obtain
\[ u(t) = R C\,\frac{d v_C(t)}{dt} + L C\,\frac{d^2 v_C(t)}{dt^2} + v_C(t). \]
Rearranging:
\[ L C\,\frac{d^2 v_C(t)}{dt^2} + R C\,\frac{d v_C(t)}{dt} + v_C(t) = u(t). \]
This is a second-order linear ODE. In Laplace domain (using Chapter 2 tools), with zero initial conditions,
\[ \left(L C\,s^2 + R C\,s + 1\right)V_C(s) = U(s). \]
This relation will later be recognized as a standard second-order model in the time-response chapters.
4. General Network Modeling via Node Voltages
For larger electrical networks, systematic modeling is typically done using nodal analysis. Let \( \mathbf{v}(t) \) be the vector of node voltages (excluding the reference node), and let \( \mathbf{u}(t) \) be a vector collecting independent source variables (voltage or current sources).
For a linear RLC network without op-amps, one can derive a matrix differential equation of the form
\[ \mathbf{C}\,\frac{d \mathbf{v}(t)}{dt} + \mathbf{G}\,\mathbf{v}(t) = \mathbf{B}\,\mathbf{u}(t), \]
where:
- \( \mathbf{C} \) is a capacitance matrix (typically diagonal or sparse),
- \( \mathbf{G} \) is a conductance matrix obtained from resistors,
- \( \mathbf{B} \) connects the independent sources to the nodes.
Introducing a state vector based on capacitor voltages and inductor currents, one can rewrite this in the standard first-order form familiar from differential equations:
\[ \frac{d \mathbf{x}(t)}{dt} = \mathbf{A}\,\mathbf{x}(t) + \mathbf{B}_u\,\mathbf{u}(t). \]
Here, \( \mathbf{A} \) and \( \mathbf{B}_u \) depend only on circuit parameters \( R, L, C \) and the chosen state variables. This representation is particularly convenient for computer simulation and for interfacing electrical sub-systems with mechanical models in robotics.
5. Ideal Op-Amp Model and Virtual-Short Principle
An operational amplifier (op-amp) is a high-gain differential amplifier. In control and signal conditioning, op-amps are used as amplifiers, summers, integrators, differentiators, and filters. The ideal op-amp model is defined by:
\[ v_o(t) = A\,\bigl(v_p(t) - v_n(t)\bigr), \]
where \( v_p(t) \) and \( v_n(t) \) are the voltages at the non-inverting and inverting inputs, respectively, and \( v_o(t) \) is the output voltage.
Ideal assumptions:
- Infinite open-loop gain: \( A \to \infty \).
- Infinite input resistance: input currents \( i_p(t) = i_n(t) = 0 \).
- Zero output resistance: the op-amp can drive the load without internal voltage drop.
- Infinite bandwidth: gain is constant over frequency (LTI model).
Under negative feedback and in the linear unsaturated region \( \lvert v_o(t)\rvert \lt V_{\text{sat}} \), the infinite-gain assumption implies:
\[ v_o(t) = A \bigl(v_p(t) - v_n(t)\bigr), \quad A \to \infty \quad \Rightarrow \quad v_p(t) - v_n(t) \approx 0. \]
More precisely, for finite but large \( A \),
\[ v_p(t) - v_n(t) = \frac{v_o(t)}{A}, \]
so as \( A \to \infty \), any finite \( v_o(t) \) implies \( v_p(t) - v_n(t) \to 0 \). This leads to the virtual-short principle:
- \( v_p(t) \approx v_n(t) \), but
- no current flows between them (because of infinite input resistance).
These two facts, together with KCL at the input node, are the basis for deriving op-amp circuit relationships.
flowchart LR
VIN["vin(t)"] --> RIN["Rin (input resistor)"]
RIN --> NODE["Inverting node (approx 0 V)"]
NODE --> RF["Rf (feedback)"]
RF --> VOUT["vout(t)"]
NODE --> AMP["Ideal op-amp"]
AMP --> VOUT
GND["0 V reference"] --> NODE
6. Static and Dynamic Op-Amp Circuits
6.1 Inverting amplifier
Consider the standard inverting amplifier: the non-inverting input is grounded (so \( v_p(t) = 0 \)), the input signal \( v_{\text{in}}(t) \) passes through resistor \( R_1 \) into the inverting node, and a feedback resistor \( R_f \) connects the output \( v_o(t) \) back to the inverting node. Let the inverting-node voltage be \( v_n(t) \).
By the virtual-short condition, \( v_n(t) \approx v_p(t) = 0 \), so the inverting node is a virtual ground. KCL at the inverting node (input currents into the op-amp are zero):
\[ \frac{v_{\text{in}}(t) - v_n(t)}{R_1} + \frac{v_o(t) - v_n(t)}{R_f} = 0. \]
Setting \( v_n(t) = 0 \):
\[ \frac{v_{\text{in}}(t)}{R_1} + \frac{v_o(t)}{R_f} = 0 \quad \Rightarrow \quad v_o(t) = -\frac{R_f}{R_1}\,v_{\text{in}}(t). \]
Thus the inverting amplifier is algebraic (no dynamics) and perfectly linear under the ideal model.
6.2 Ideal integrator (dynamic op-amp circuit)
Replace the feedback resistor \( R_f \) by a capacitor \( C \) while keeping the input resistor \( R \). Again \( v_p(t) = 0 \), so \( v_n(t) \approx 0 \). The input current through \( R \) is
\[ i_R(t) = \frac{v_{\text{in}}(t) - v_n(t)}{R} = \frac{v_{\text{in}}(t)}{R}, \]
and this current must flow into the capacitor, since input currents to the op-amp are zero:
\[ i_C(t) = C\,\frac{d}{dt}\bigl(v_n(t) - v_o(t)\bigr) = -C\,\frac{d v_o(t)}{dt}. \]
Setting \( i_R(t) = i_C(t) \) yields the first-order ODE
\[ \frac{v_{\text{in}}(t)}{R} = -C\,\frac{d v_o(t)}{dt} \quad \Rightarrow \quad \frac{d v_o(t)}{dt} = -\frac{1}{R C}\,v_{\text{in}}(t). \]
Integrating from \( 0 \) to \( t \):
\[ v_o(t) = v_o(0) - \frac{1}{R C} \int_0^t v_{\text{in}}(\lambda)\,d\lambda. \]
Thus the circuit implements (up to sign and scale) a continuous-time integrator, a key block in many analog compensators and motion-control circuits.
6.3 Ideal differentiator (dynamic op-amp circuit)
If the input element is a capacitor \( C \) and the feedback element is a resistor \( R_f \), the current through the capacitor is
\[ i_C(t) = C\,\frac{d}{dt}\bigl(v_{\text{in}}(t) - v_n(t)\bigr) \approx C\,\frac{d v_{\text{in}}(t)}{dt}, \]
since \( v_n(t) \approx 0 \). This current must flow through \( R_f \):
\[ i_C(t) = \frac{v_n(t) - v_o(t)}{R_f} \approx -\frac{v_o(t)}{R_f}. \]
Equating:
\[ C\,\frac{d v_{\text{in}}(t)}{dt} = -\frac{v_o(t)}{R_f} \quad \Rightarrow \quad v_o(t) = -R_f C\,\frac{d v_{\text{in}}(t)}{dt}. \]
This ideal differentiator is mathematically linear but not physically robust at high frequencies. In practice, additional components are added to keep the overall system LTI within the intended bandwidth.
7. Python Implementation for RC and Op-Amp Integrator Models
We now implement the RC low-pass circuit from Section 3 and the ideal op-amp integrator from Section 6 using Python. The RC model:
\[ R C\,\frac{d v_C(t)}{dt} + v_C(t) = u(t) \quad \Rightarrow \quad \frac{d v_C(t)}{dt} = \frac{u(t) - v_C(t)}{R C}. \]
The op-amp integrator:
\[ \frac{d v_o(t)}{dt} = -\frac{1}{R_{\text{int}} C_{\text{int}}}\,v_{\text{in}}(t). \]
We simulate both with a step input using
scipy.integrate.solve_ivp. In robotics, similar models
appear in analog sensor filters and current/voltage drive electronics.
The python-control and
roboticstoolbox-python libraries can integrate these
electrical models with mechanical robot dynamics.
import numpy as np
from scipy.integrate import solve_ivp
import matplotlib.pyplot as plt
# Parameters for RC low-pass filter (sensor anti-alias filter)
R = 10_000.0 # 10 kOhm
C = 1e-6 # 1 microfarad
RC = R * C
# Parameters for op-amp integrator (e.g., analog velocity estimate)
R_int = 100_000.0 # 100 kOhm
C_int = 1e-6
k_int = 1.0 / (R_int * C_int)
def u_step(t, U0=1.0):
return U0 # unit step
def rc_ode(t, vC):
return (u_step(t) - vC) / RC
def integrator_ode(t, vo):
# integrate the same step input
return -k_int * u_step(t)
t_span = (0.0, 0.1)
t_eval = np.linspace(t_span[0], t_span[1], 1000)
sol_rc = solve_ivp(rc_ode, t_span, y0=[0.0], t_eval=t_eval)
sol_int = solve_ivp(integrator_ode, t_span, y0=[0.0], t_eval=t_eval)
plt.figure()
plt.plot(sol_rc.t, sol_rc.y[0], label="RC vC(t)")
plt.plot(sol_int.t, sol_int.y[0], label="Integrator vo(t)")
plt.xlabel("time (s)")
plt.ylabel("voltage (V)")
plt.legend()
plt.title("RC low-pass and op-amp integrator responses")
plt.grid(True)
plt.show()
# In larger robotics projects, you could also represent the RC circuit as
# a transfer function using python-control:
# import control
# G_rc = control.tf([1.0], [RC, 1.0])
8. C++ Implementation for Discrete-Time Simulation
In embedded control and robotics (e.g., within a ROS 2 control node), we often simulate or implement analog dynamics using a discrete-time approximation such as forward Euler. Starting from \( \dot{v}_C(t) = (u(t) - v_C(t))/(R C) \), we can discretize with sampling period \( h \):
\[ v_C[k+1] \approx v_C[k] + h\,\frac{u[k] - v_C[k]}{R C}. \]
The following C++ code simulates this recursion. Libraries like
Eigen are commonly used in robotics to handle larger state
vectors, but we keep the example scalar here.
#include <iostream>
#include <vector>
int main() {
double R = 10e3; // 10 kOhm
double C = 1e-6; // 1 microfarad
double RC = R * C;
double h = 1e-4; // 0.1 ms step
double T = 0.1; // 0.1 s total
int N = static_cast<int>(T / h);
double vC = 0.0; // initial capacitor voltage
double U0 = 1.0; // step input
std::vector<double> time;
std::vector<double> vC_hist;
time.reserve(N + 1);
vC_hist.reserve(N + 1);
time.push_back(0.0);
vC_hist.push_back(vC);
for (int k = 0; k < N; ++k) {
double t = (k + 1) * h;
double u = U0; // step
double dvC = (u - vC) / RC;
vC += h * dvC;
time.push_back(t);
vC_hist.push_back(vC);
}
// Print a few samples for inspection
for (int k = 0; k <= N; k += N / 10) {
std::cout << "t = " << time[k]
<< " s, vC = " << vC_hist[k] << " V\n";
}
return 0;
}
In a robotics controller, this update equation could be executed every sampling period inside a real-time loop, possibly as part of a more complex state update coupled with mechanical dynamics.
9. Java Implementation Using a Simple Simulation Class
For Java-based control or simulation environments (e.g., some mobile robotics or industrial control platforms), we can implement the same RC model with an object-oriented structure. Libraries such as Apache Commons Math or EJML provide matrix and ODE solvers for higher-dimensional systems.
public class RCLowPassSimulator {
private final double R;
private final double C;
private final double RC;
private final double h; // sampling period
private double vC; // state: capacitor voltage
public RCLowPassSimulator(double R, double C, double h) {
this.R = R;
this.C = C;
this.RC = R * C;
this.h = h;
this.vC = 0.0;
}
public double step(double u) {
// Forward Euler integration of dvC/dt = (u - vC)/(R*C)
double dvC = (u - vC) / RC;
vC += h * dvC;
return vC;
}
public double getState() {
return vC;
}
public static void main(String[] args) {
double R = 10_000.0;
double C = 1e-6;
double h = 1e-4;
double T = 0.1;
int N = (int) (T / h);
RCLowPassSimulator rc = new RCLowPassSimulator(R, C, h);
double U0 = 1.0;
for (int k = 0; k <= N; k += N / 10) {
double vC = rc.step(U0);
double t = (k + 1) * h;
System.out.printf("t = %.6f s, vC = %.4f V%n", t, vC);
}
}
}
In more advanced Java control frameworks, such a class could be combined with mechanical models of robot joints to represent the complete mechatronic system.
10. MATLAB/Simulink Implementation
MATLAB and Simulink are standard tools in control and robotics. The RC circuit and op-amp integrator can be modeled either as ODEs or as blocks in Simulink. Using the ODE representation:
\[ \dot{v}_C(t) = \frac{u(t) - v_C(t)}{R C}, \qquad \dot{v}_o(t) = -\frac{1}{R_{\text{int}} C_{\text{int}}}\,v_{\text{in}}(t). \]
% Parameters
R = 10e3; % 10 kOhm
C = 1e-6; % 1 microfarad
RC = R * C;
Rint = 100e3;
Cint = 1e-6;
k_int = 1 / (Rint * Cint);
u = @(t) 1.0; % unit step input
% ODE for RC low-pass
rc_ode = @(t, vC) (u(t) - vC) / RC;
% ODE for op-amp integrator
int_ode = @(t, vo) -k_int * u(t);
tspan = [0 0.1];
vC0 = 0;
vo0 = 0;
[t_rc, vC] = ode45(rc_ode, tspan, vC0);
[t_int, vo] = ode45(int_ode, tspan, vo0);
figure; hold on;
plot(t_rc, vC, "LineWidth", 1.5);
plot(t_int, vo, "LineWidth", 1.5);
xlabel("time (s)");
ylabel("voltage (V)");
legend("RC v_C(t)", "Integrator v_o(t)");
grid on;
title("RC and op-amp integrator dynamics");
% In Simulink, an equivalent RC circuit can be built with:
% - Step block (input u(t))
% - Transfer Fcn block with numerator [1] and denominator [RC 1]
% - Scope block showing v_C(t)
%
% Robotics System Toolbox can then combine this with joint-space models.
In Simulink, this RC circuit can be connected directly to mechanical models (e.g., a DC motor block), preserving the continuous-time dynamics of both electrical and mechanical components.
11. Wolfram Mathematica Implementation
Wolfram Mathematica provides symbolic and numerical tools that are convenient for analyzing electrical networks and op-amp systems. For the RC low-pass circuit with step input:
\[ R C\,\frac{d v_C(t)}{dt} + v_C(t) = U_0, \quad v_C(0) = 0. \]
We can solve symbolically and numerically as follows:
R = 10*10^3;
C = 1*10^-6;
RC = R*C;
U0 = 1;
(* Symbolic solution *)
solSym = DSolve[
{RC*vC'[t] + vC[t] == U0, vC[0] == 0},
vC, t
];
vCexpr[t_] = vC[t] /. First[solSym];
(* Numerical evaluation and plotting *)
tmax = 0.1;
Plot[vCexpr[t], {t, 0, tmax},
AxesLabel -> {"t (s)", "vC(t) (V)"},
PlotLegends -> {"RC response"}
]
(* Op-amp integrator: vo'(t) == -(1/(Rint*Cint))*uin(t) *)
Rint = 100*10^3;
Cint = 1*10^-6;
kInt = 1/(Rint*Cint);
uin[t_] := 1;
solInt = NDSolve[
{vo'[t] == -kInt*uin[t], vo[0] == 0},
vo, {t, 0, tmax}
];
Plot[Evaluate[vo[t] /. solInt],
{t, 0, tmax},
AxesLabel -> {"t (s)", "vo(t) (V)"},
PlotLegends -> {"Integrator response"}
]
In more advanced modeling, StateSpaceModel and
TransferFunctionModel
can be used to unify electrical and mechanical dynamics for robotic
systems.
12. Problems and Solutions
Problem 1 (Series RL model and step response): A series RL circuit with resistance \( R \) and inductance \( L \) is driven by a voltage source \( u(t) = U_0 \) for \( t \ge 0 \). The current is \( i(t) \). Derive the ODE and solve for \( i(t) \) with initial condition \( i(0) = 0 \).
Solution: From KVL,
\[ u(t) = R\,i(t) + L\,\frac{d i(t)}{dt} \quad \Rightarrow \quad L\,\frac{d i(t)}{dt} + R\,i(t) = U_0. \]
This is a first-order linear ODE. The homogeneous solution is \( i_h(t) = K e^{-\frac{R}{L}t} \). A constant particular solution is \( i_p(t) = \frac{U_0}{R} \). Imposing \( i(0) = 0 \):
\[ 0 = i(0) = K + \frac{U_0}{R} \quad \Rightarrow \quad K = -\frac{U_0}{R}. \]
Therefore,
\[ i(t) = \frac{U_0}{R}\left(1 - e^{-\frac{R}{L} t}\right). \]
Problem 2 (Series RLC ODE in capacitor voltage): For the series RLC circuit of Section 3.3 with input voltage \( u(t) \) and capacitor voltage \( v_C(t) \), derive the ODE in terms of \( v_C(t) \) only.
Solution: From KVL,
\[ u(t) = R\,i(t) + L\,\frac{d i(t)}{dt} + v_C(t). \]
Using \( i(t) = C\,\frac{d v_C(t)}{dt} \), we obtain
\[ u(t) = R C\,\frac{d v_C(t)}{dt} + L C\,\frac{d^2 v_C(t)}{dt^2} + v_C(t), \]
so the ODE is
\[ L C\,\frac{d^2 v_C(t)}{dt^2} + R C\,\frac{d v_C(t)}{dt} + v_C(t) = u(t). \]
Problem 3 (Gain of the inverting amplifier): In the ideal inverting amplifier of Section 6.1, show rigorously that the gain is \( -R_f/R_1 \) using KCL and the virtual-short assumption.
Solution: Let the inverting-node voltage be \( v_n(t) \). The non-inverting input is grounded, so \( v_p(t) = 0 \). Ideal op-amp with negative feedback implies \( v_n(t) \approx v_p(t) = 0 \). KCL at the inverting node (no current into op-amp inputs):
\[ \frac{v_{\text{in}}(t) - v_n(t)}{R_1} + \frac{v_o(t) - v_n(t)}{R_f} = 0. \]
Setting \( v_n(t) = 0 \) gives
\[ \frac{v_{\text{in}}(t)}{R_1} + \frac{v_o(t)}{R_f} = 0 \quad \Rightarrow \quad v_o(t) = -\frac{R_f}{R_1}\,v_{\text{in}}(t). \]
Hence the gain is \( -R_f/R_1 \).
Problem 4 (ODE of an op-amp integrator): For the ideal inverting integrator (Section 6.2) with input resistor \( R \) and feedback capacitor \( C \), derive the ODE that relates \( v_o(t) \) and \( v_{\text{in}}(t) \).
Solution: With \( v_p(t) = 0 \) and \( v_n(t) \approx 0 \), the current through the input resistor is
\[ i_R(t) = \frac{v_{\text{in}}(t) - v_n(t)}{R} = \frac{v_{\text{in}}(t)}{R}. \]
The current through the capacitor is
\[ i_C(t) = C\,\frac{d}{dt}\bigl(v_n(t) - v_o(t)\bigr) = -C\,\frac{d v_o(t)}{dt}. \]
Since input currents to the op-amp vanish, \( i_R(t) = i_C(t) \), so
\[ \frac{v_{\text{in}}(t)}{R} = -C\,\frac{d v_o(t)}{dt} \quad \Rightarrow \quad \frac{d v_o(t)}{dt} = -\frac{1}{R C}\,v_{\text{in}}(t). \]
Problem 5 (Order of an RLC network): Consider an arbitrary linear RLC network with \( N_L \) inductors and \( N_C \) capacitors. Using physical reasoning, argue that the resulting LTI model can be written as a system of \( N_L + N_C \) first-order ODEs.
Solution: Each inductor current \( i_{L,j}(t) \) and each capacitor voltage \( v_{C,k}(t) \) obeys a first-order relation:
\[ v_{L,j}(t) = L_j\,\frac{d i_{L,j}(t)}{dt}, \qquad i_{C,k}(t) = C_k\,\frac{d v_{C,k}(t)}{dt}. \]
Choosing the state vector \( \mathbf{x}(t) = \bigl(i_{L,1}(t),\dots,i_{L,N_L}(t),v_{C,1}(t),\dots,v_{C,N_C}(t)\bigr)^{\top} \), each component of \( \dot{\mathbf{x}}(t) \) appears linearly in KCL/KVL equations, leading to a system of \( N_L + N_C \) first-order linear ODEs. All other voltages and currents in the circuit can be expressed algebraically in terms of \( \mathbf{x}(t) \) and the inputs, so the dynamical order cannot exceed \( N_L + N_C \). Under mild non-degeneracy conditions (no redundant storage elements), this order is exactly \( N_L + N_C \).
13. Summary
In this lesson we developed linear time-invariant models for electrical networks and op-amp-based circuits:
- Using Kirchhoff’s laws and R, L, C constitutive relations, we derived first- and second-order ODEs for RL, RC, and RLC circuits.
- We formalized the ideal op-amp model, including the virtual-short and zero-input-current conditions, and applied them to compute the gain of inverting amplifiers.
- We showed that op-amp circuits with capacitors and resistors realize dynamic behaviors such as integration and differentiation, yielding LTI ODEs naturally compatible with control theory.
- We implemented these models numerically in Python, C++, Java, MATLAB/Simulink, and Wolfram Mathematica, linking them to typical robotics applications like sensor filtering and actuator drive modeling.
These electrical models will be combined with mechanical models in later chapters through the transfer-function and block-diagram framework, enabling full electromechanical control-system design.
14. References
- Carlin, H.J., & Youla, D.C. (1962). Network synthesis with negative resistors. Proceedings of the IRE, 50(5), 884–892.
- Desoer, C.A., & Kuh, E.S. (1969). Basic Circuit Theory. McGraw–Hill.
- Chua, L.O., Desoer, C.A., & Kuh, E.S. (1987). Linear and Nonlinear Circuits. McGraw–Hill.
- Horowitz, P., & Hill, W. (1989). The Art of Electronics. Cambridge University Press. (Chapters on op-amp theory.)
- Guillemin, E.A. (1957). Introductory Circuit Theory. Wiley.
- Kuh, E.S., & Rohrer, R.A. (1967). The state-variable approach to network analysis. Proceedings of the IEEE, 55(7), 1143–1158.
- Van Valkenburg, M.E. (1960). Network analysis. Prentice–Hall.
- Roberge, J.K. (1975). Operational Amplifiers: Theory and Practice. Wiley.