TechieYan Technologies



Solar power is the most abundant, renewable, reliable and pollution free resource. It is environment friendly and is economical as well. Despite having a vast form of energy we are not extracting efficient energy from it. Most of the sun rays which are falling on the earth surface are reflecting back into space. So, in this project, to get the maximum power output we are going to use photovoltaic power generation and the MPPT P AND O algorithm. The process of converting heat energy into electrical energy with the help of solar cells is called photovoltaic power generation. There are many photovoltaic applications i.e it is used to generate electricity to charge batteries, pump water, activate switches etc. they can be also used in irrigation as a power source. Although photovoltaic systems are environment friendly they have their own cons, as they are slightly not efficient in conversion of solar energy to electrical energy. To overcome this issue the PV(photovoltaic) module is integrated with MPPT. Maximum power point tracker(MPPT) is used to maximise the energy extraction and plays a significant role in extracting maximum power from PV generators irrespective of varying conditions like irradiation and change in temperature. It is a DC-DC converter. MPPT technique can be also used with wind turbines, thermophotovoltaics, optimal power transmission, etc.

Isometric 3D vector illustration solar panels for electricity generation

Code Description & Execution of MPPT P AND O Algorithm

Algorithm Description

PERTURBATION AND OBSERVATION (P&O) ALGORITHM : It is one of the most common and basic MPPT algorithms used to perturb the operating voltage to ensure the maximum power.

  • In this method voltage is varied to check the output power
  • If the value of power increases by increasing voltage then & will be increased
  • If the value of power decreases by increasing voltage then & will be decreased
  • If the value of power increases by decreasing voltage then the duty cycle is decreased

The above steps will be continued till maximum power point is reached.

Block Diagram of MPPT P AND O algorithm

Block diagram of PV module using MPPT P&O algorithm

Model Description

Steps to Execute the Code

MPPT P AND O algorithm

The above simulation is the photovoltaic system based on the MPPT P&O algorithm.

Note: simulink files or codes are saved in .mdl  and .slx format

(Don’t worry if you don’t know the basics of the MATLAB/SIMULINK Click here  to watch our video about MATLAB/SIMULINK software basics)

Steps to Execute the Code

  1. Download the zip file and unzip it
  2. Open matlab and click on simulink icon on home tab
  3. Click on ‘open’ option and select the file’s location
MPPT P AND O algorithm using MATLAB
  1. Once the file is open click on run in the simulate tab and when the simulation is ready doble click on scope to view the results

Results of MPPT P AND O Algorithm

The following are the results of PV system based MPPT using P&O algorithm

MPPT P AND O algorithm Results

Issues Faced

  • This simulink project is compatible with matlab version R2022a. If you have any other version other than R2022a, some modifications should be done according to your version.


+91 7075575787