I tried to find many papers finding a script of MPPT with shading , but i can't find it . Can you help me? to write this script? In those papers has only simulink
1 view (last 30 days)
Show older comments
% MATLAB Script to plot PV I-V and P-V curves under normal and abnormal conditions
% Parameters for PV module (adjust as needed)
V_oc = 40; % Open circuit voltage (V)
I_sc = 8; % Short circuit current (A)
MPP_normal = [30, 6.5]; % Normal MPP [Voltage, Current]
MPP_abnormal = [20, 3]; % Abnormal MPP (e.g., shaded or faulty) [Voltage, Current]
% Generate Voltage vector
V = linspace(0, V_oc, 100);
% I-V curve for normal condition
I_normal = I_sc * (1 - V / V_oc);
I_normal(V > MPP_normal(1)) = MPP_normal(2);
% I-V curve for abnormal condition (e.g., shading or fault reduces current)
I_abnormal = I_sc * (1 - V / V_oc) * 0.5; % 50% reduction in current
I_abnormal(V > MPP_abnormal(1)) = MPP_abnormal(2);
% P-V curve for normal and abnormal conditions
P_normal = V .* I_normal;
P_abnormal = V .* I_abnormal;
% Plotting
figure;
% I-V Curves
subplot(2, 2, 1);
plot(V, I_normal, 'b', 'LineWidth', 1.5); hold on;
plot(MPP_normal(1), MPP_normal(2), 'bo', 'MarkerFaceColor', 'w');
xlabel('PV Voltage (V)');
ylabel('PV Current (A)');
title('I-V Curve (Normal)');
grid on;
subplot(2, 2, 2);
plot(V, I_abnormal, 'r--', 'LineWidth', 1.5); hold on;
plot(MPP_abnormal(1), MPP_abnormal(2), 'ro', 'MarkerFaceColor', 'w');
xlabel('PV Voltage (V)');
ylabel('PV Current (A)');
title('I-V Curve (Abnormal)');
grid on;
% P-V Curves
subplot(2, 2, 3);
plot(V, P_normal, 'b', 'LineWidth', 1.5); hold on;
plot(MPP_normal(1), MPP_normal(1) * MPP_normal(2), 'bo', 'MarkerFaceColor', 'w');
xlabel('PV Voltage (V)');
ylabel('PV Power (W)');
title('P-V Curve (Normal)');
grid on;
subplot(2, 2, 4);
plot(V, P_abnormal, 'r--', 'LineWidth', 1.5); hold on;
plot(MPP_abnormal(1), MPP_abnormal(1) * MPP_abnormal(2), 'ro', 'MarkerFaceColor', 'w');
xlabel('PV Voltage (V)');
ylabel('PV Power (W)');
title('P-V Curve (Abnormal)');
grid on;
sgtitle('PV Characteristics: Normal vs. Abnormal Conditions');
1 Comment
Sandeep Mishra
on 2 Dec 2024
Hi @Prom
Could you clarify the question? You've shared a code snippet and output plots, but it's unclear what you're asking. The I-V and P-V curves differ from our studies. How should we determine the MPPT point?
Answers (1)
Sabin
on 12 Dec 2024
The question is unclear. I would advise to check this Simscape Electrical example as a starting point:
0 Comments
See Also
Categories
Find more on Sources in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!