top of page

How To Measure Total Harmonic Distortion of Voltage and Current in MATLAB

How To Measure Total Harmonic Distortion of Voltage and Current in MATLAB


We'll explore how to measure the total harmonics of voltage and current using MATLAB in a three-phase system. The focus will be on analyzing a system with a non-linear load and understanding the harmonic distortion.

Simulation Setup: To measure total harmonics, a three-phase voltage source and a diode bridge rectifier (Universal Bridge) are used. The non-linear load is connected to the three-phase source, and measurements for current and grid voltage are taken. The simulation includes an RLC filter branch acting as a filter. Default values are initially used for simplicity.

Simulation Steps:

  1. Connect three-phase voltage source.

  2. Use a diode bridge (Universal Bridge) for the rectification.

  3. Connect a non-linear load to the three-phase source.

  4. Measure current and grid voltage.

  5. Use RLC branch as a filter (initially with default values).

  6. Simulate the model.

Data Logging: Data from the simulation, including voltage (VG) and current (IG), is logged using the To Workspace block. Scopes are employed to visualize waveforms. The simulation results showcase the voltage and grid current waveforms.

Total Harmonic Distortion (THD) Analysis: After simulating the model, MATLAB's Powergui tool is utilized for total harmonic distortion analysis. The tool helps calculate the THD for both voltage and current waveforms. The frequency axis can be displayed in terms of harmonic order or frequency, providing a comprehensive view of harmonic content.

Results and Analysis: The total harmonic distortion for both voltage and current waveforms is displayed, allowing engineers to assess the impact of harmonics on the system. By changing parameters and analyzing different scenarios, users can gain insights into improving power quality and mitigating harmonic distortions.

Conclusion: This tutorial has demonstrated the process of measuring total harmonics of voltage and current in MATLAB for a three-phase system with a non-linear load. The analysis tools provided by MATLAB empower engineers to evaluate and optimize power system performance.

10 views0 comments


bottom of page