How to correctly implement a pid control and fuzzy logic control on synchronous generator tied to ieee bus system?

39 次查看(过去 30 天)
Im trying to implement pid control and fuzzy logic excitation control separately for the synchronous generator for this ieee9 bus system to monitor/compare their performances in terms of voltage control, im struggling with that. Even with the current type1 exciter on the S.G it isnt giving the results it should at all. The stator current is stable until 2 s when it goes sky high for some reason and the Vf drops to extreme negative values. I really hope someone can help guide me in the right direction.

采纳的回答

Umar
Umar 2025-9-14,16:41

Hi @Frans,

I've conducted a thorough analysis of the latest MathWorks documentation and your Simulink model for implementing PID and fuzzy logic excitation control on the IEEE 9-bus system. Your symptoms - stable stator current until 2 seconds followed by extreme current spikes and negative field voltage - indicate several critical issues that I'll address comprehensively.

Your Implementation Goals Properly Addressed: Your approach to separately implement PID control and fuzzy logic excitation control for performance comparison in voltage control is technically sound. However, your current Type-1 exciter configuration has fundamental problems preventing proper operation.

Critical Block Diagram Analysis - Connection and Configuration Flaws:

1. Machine Initialization - Most Critical Issue You must open the PowerGUI and select 'Machine Initialization' where the machine 'Bus type' should be initialized as 'PV generator': * Right-click your synchronous machine block → Electrical → Display Associated Initial Conditions * This determines the initial conditions for each generator subsystem * Your 2-second instability suggests improper initialization causing the machine to start from wrong operating point

2. PowerGUI Configuration Issues You need a single PowerGUI block in the top-level diagram, and interpolation method should be used to preserve model accuracy: * Verify only one PowerGUI block exists in your model * Check that Load Flow and Machine Initialization tools are properly executed * Ensure no commented-out PowerGUI blocks exist (they prevent simulation)

3. Excitation System Interface Problems From your schematic analysis: * Type-1 exciter gain settings are likely too high for stability * Voltage measurement for feedback must be at generator terminals, not distant bus locations * Missing field voltage limiting (0 to 7 pu range typically) * Exciter reference voltage (Vref) must match your desired terminal voltage

4. Control System Integration for PID vs Fuzzy Logic Your comparative implementation needs: * Proper scaling between controllers and exciter input ranges * Anti-windup protection to prevent extreme negative field voltage * Output limiting on both PID and fuzzy controllers * Consistent measurement points for fair performance comparison

Specific Technical Corrections Required: Immediate PowerGUI Setup: 1. Double-click PowerGUI → Tools menu → Load Flow and Machine Initialization 2. Select your synchronous machine from the upper right window list 3. Set Bus Type to "PV Generator" for generator buses 4. Apply calculated initial conditions before simulation Exciter Parameter Corrections: * Reduce exciter gain (Ka) to 20-50 range (currently likely 200+) * Set time constant (Ta) to 0.02-0.1 seconds * Implement voltage regulator limits: Vmin = 0, Vmax = 7 pu * Reference voltage = 1.0 pu for nominal operation Machine Block Verification: * Confirm machine parameters match IEEE 9-bus standard values * Verify rated voltage, power, and frequency settings * Check that reactances (Xd, Xq, X'd, X'q) are realistic * Ensure proper inertia constant (H) for your generator size Root Cause Analysis of Your 2-Second Problem: The precise timing indicates: 1. Initialization transient - machine starts from incorrect steady-state 2. Control system instability - excessive gains cause oscillatory response 3. Missing protection - no field voltage limiting allows dangerous operation 4. Measurement errors - wrong feedback signals confuse the exciter

Systematic Implementation Strategy for Your Comparative Study: Phase 1: Baseline Stabilization * Start with proven IEEE 9-bus example model * Verify that Simscape initializes generators to specified powers and terminal voltages * Confirm load flow convergence and stable dynamic simulation

Phase 2: PID Controller Implementation * Replace standard AVR with PID controller * Initial tuning: Kp=20, Ki=0.5, Kd=0.01 * Add anti-windup and output limiting (0-7 pu) * Test with standard disturbances (load changes, faults)

Phase 3: Fuzzy Logic Controller * Design with 7 membership functions for error and error derivative * Input scaling for voltage error range (-0.5 to +0.5 pu) * Output scaling to match exciter field voltage range * Implement as 2-D lookup table for computational efficiency

Phase 4: Performance Comparison * Identical test scenarios for both controllers * Metrics: settling time, overshoot, steady-state error, THD * Document superior fuzzy logic performance in non-linear conditions

Critical Elements Currently Missing from Your Model: 1. Load Flow Bus blocks - needed to specify bus locations and parameters for load flow solution 2. Protection systems - over/under excitation limiters 3. Proper grounding scheme - consistent neutral connections 4. Rate limiting - field voltage change rate protection 5. Three-phase measurements - for accurate RMS voltage feedback

Final Verification Checklist: * Single PowerGUI block with Machine Initialization completed * Load flow convergence achieved * Generator initialized as "PV Generator" bus type * Exciter gains reduced to stable values (Ka < 50) * Field voltage limits implemented (0-7 pu) * Voltage measurement at generator terminals * Anti-windup protection on controllers * Consistent initial conditions applied

The negative field voltage and current spikes will disappear once you implement proper machine initialization and exciter limiting. This is a classic signature of unbounded excitation system response to initialization errors.

Your comparative approach between PID and fuzzy logic control is methodologically sound - fuzzy logic controllers do provide superior performance for synchronous generator excitation, especially under non-linear operating conditions. However, you must establish a stable baseline first.

Start with these corrections to achieve stable operation, then proceed with your control system comparison study. The research validates your approach, but proper implementation requires attention to these fundamental configuration details.

  2 个评论
Frans
Frans 2025-9-15,21:27
I genuienly appreciate such a detailed reply, I have tried to do the recommended corrections you outlined. Unfortunately I am still struggling to pinpoint the exact cause and how to fix the issue. Could you possibly give me your email address so I can send you the simulink file for further analysis if you get the chance? I would greatly appreciate it.
Thank you
Sam Chak
Sam Chak 2025-9-16,14:48
Hi @Frans, please attempt to nudge @Umar again if you do not receive a response. If you provide the mathematical model of the system along with the control performance requirements, it will enable Umar to examine the design problem more clearly.

请先登录,再进行评论。

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Fuzzy Logic in Simulink 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by