top of page

MATLAB Implementation of Grid Tied PV Battery System

System Overview

This project presents a simulation model for a grid-tied PV battery system using a SEPIC converter in the PV side. The key components of the system include:

  • PV Array

  • SEPIC Converter

  • DC Bus

  • Battery Storage

  • Inverter

  • LCL Filter

  • Grid Connection

The overall objective is to efficiently extract power from the PV array, store excess energy in the battery, and inject surplus energy into the grid when available.



PV Panel Specifications

The PV array is modeled with the following parameters:

  • Single panel rating: 213.15 W

  • Open circuit voltage: 36.3 V

  • Short circuit current: 7.84 A

  • Voltage at max power point (Vmp): 29 V

  • Current at max power point (Imp): 7.35 A

  • Number of panels in series: 8

  • Total power generation: ~1,705 W at 1000 W/m² irradiance

System Configuration

The system is designed such that:

  • The PV panel output is fed into a SEPIC converter, which is connected to a DC bus.

  • A 12V battery is also connected to the DC bus for energy storage, with a 40 Ah capacitor.

  • The DC output is inverted through an inverter, passed through an LCL filter, and finally connected to the 230V RMS grid.



Control Strategies

Two major control mechanisms are employed:

1. MPPT Control Using Perturb & Observe (P&O)

  • The SEPIC converter is managed using a P&O MPPT algorithm, which adjusts the duty cycle based on changes in PV voltage and power.

  • If both changes are in the same direction (positive or negative), the duty cycle is decreased; if opposite, it is increased.

  • This ensures the PV array consistently operates near its maximum power point.

2. Inverter Control Using Neural Network and DQ Logic

  • The inverter is controlled through a DQ transformation-based control loop.

  • A neural network-based energy management system (EMS) calculates a reference current based on PV power and the State of Charge (SOC) of the battery.

  • This reference current is transformed into a sinusoidal form and used to generate control pulses for the inverter via a PI controller.

Training the Neural Network EMS

To manage energy flow effectively:

  • A neural network is trained using sample data sets, including SOC and PV power.

  • Using MATLAB’s neural network fitting tool, the model is trained to generate the correct reference current under varying conditions.

  • This current is then used to regulate energy sharing between battery and grid.

Simulation and Results

The simulation includes a step change in irradiance:

  • Initially, the irradiance is 1000 W/m², resulting in:

    • ~1,700 W PV output

    • ~424 W charging the battery

    • ~1,250 W sent to the grid

  • At 3 seconds, irradiance drops to 500 W/m², leading to:

    • ~850 W PV output

    • The battery draws power from the grid, shown by a negative reference current

    • The neural network adapts dynamically to ensure proper energy flow

Grid and inverter current waveforms show in-phase alignment, indicating active power transfer to the grid during generation surplus.

Customization and Future Enhancements

  • The neural network EMS can be retrained using user-specific data for better accuracy and adaptability.

  • Users can modify the MPPT logic, battery specs, and converter design equations as needed for different applications or load profiles.

Conclusion

This MATLAB model provides a comprehensive simulation environment for testing and analyzing a grid-tied PV battery system with a SEPIC converter and intelligent control strategies. Such systems offer practical insight into energy management for sustainable and grid-interactive solar power setups.

Comments


bottom of page