Clear Filters
Clear Filters

Defining mutual inductance for a RLC circuit

11 views (last 30 days)
Manoj Samal
Manoj Samal on 7 Oct 2022
Edited: Nihal on 16 Jul 2024 at 6:53
I'd like to use power statespace to find the state space model for an RLC circuit with multiple R,L,C and mutual inductances. I'm having trouble defining the mutual insuctance of different inductors. Can anyone help me solve it with a simple example?

Answers (1)

Nihal
Nihal on 16 Jul 2024 at 6:49
Edited: Nihal on 16 Jul 2024 at 6:53
To model an RLC circuit with multiple resistors (R), inductors (L), capacitors (C), and mutual inductances using state space representation, you can use MATLAB's `power_statespace` function. Below is a simple example that demonstrates how to define mutual inductances in a state space model.
Example RLC Circuit with Mutual Inductance
Consider a simple circuit with:
- Two inductors L1 and L2
- One resistor R
- One capacitor C
- Mutual inductance M between L1 and L2
Step-by-Step Guide
1. Define the Circuit Components
- Inductors L1 and L2
- Resistor R
- Capacitor C
- Mutual inductance M
2. Write the State Space Equations
- Define the state variables: currents through the inductors and , and voltage across the capacitor .
- Write the differential equations based on Kirchhoff's laws and the mutual inductance.
3. Convert to State Space Representation
- Formulate the state space matrices A, B , C , and D .
Here's an example MATLAB code that demonstrates this process:
% Define component values
L1 = 1e-3; % Inductance of L1 in Henrys
L2 = 2e-3; % Inductance of L2 in Henrys
M = 0.5e-3; % Mutual inductance in Henrys
R = 10; % Resistance in Ohms
C = 1e-6; % Capacitance in Farads
% State variables: x = [i_L1; i_L2; v_C]
% where i_L1 is the current through L1, i_L2 is the current through L2,
% and v_C is the voltage across the capacitor
% State space matrices
A = [0, -R/L1, -1/L1;
-R/L2, 0, -1/L2;
1/C, 1/C, 0];
% Adjust for mutual inductance
A(1,2) = -M/L1/L2;
A(2,1) = -M/L1/L2;
B = [1/L1; 0; 0]; % Assuming input voltage source is applied to L1
C = eye(3); % Output all state variables
D = zeros(3,1); % No direct feedthrough
% Create state space model
sys = ss(A, B, C, D);
% Display the state space model
disp('State Space Model:');
disp(sys);
% Simulate the system response to a step input
t = 0:1e-6:1e-3; % Time vector
u = ones(size(t)); % Step input
[y, t, x] = lsim(sys, u, t);
% Plot the results
figure;
subplot(3,1,1);
plot(t, x(:,1));
title('Current through L1 (i_L1)');
xlabel('Time (s)');
ylabel('Current (A)');
subplot(3,1,2);
plot(t, x(:,2));
title('Current through L2 (i_L2)');
xlabel('Time (s)');
ylabel('Current (A)');
subplot(3,1,3);
plot(t, x(:,3));
title('Voltage across C (v_C)');
xlabel('Time (s)');
ylabel('Voltage (V)');
Explanation:
1. Component Values
- Define the values for L1, L2 , M , R , and C .
2. State Variables:
- : Current through inductor L1
- : Current through inductor L2
- : Voltage across capacitor C
3. State Space Matrices:
- Matrix A : Contains the coefficients of the state variables and mutual inductance.
- Matrix B : Represents the input to the system (voltage source applied to L1.
- Matrix C : Outputs all state variables.
- Matrix D : Represents direct feedthrough (none in this case).
4. Simulation:
- Use `lsim` to simulate the system response to a step input and plot the results

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!