MATLAB: Hi all. I need some help in State flow. I am trying to find out the maximum power that can be delivered by a solar panel in a day

maximization in stateflowsimulinkstateflow

Hi all. I need some help in State flow. I am trying to find out the maximum power that can be delivered by a solar panel in a day.I want to calculate the max Power value in state flow and update my value. I gave the inputs to the State flow as I and V from the solar panel. The power value changes as the voltage and the current changes as the irradiation given to the panel changes. So for a given number of changes, I want to calculate the maximum power delivered by the panel.

Best Answer

in your state write this code, I guess your are familar with during.
du: power=max(power,u*i)
% u and i are input from simulink to your chart
% power is your output to simumlink from your chart
Related Question