资源简介

3电平光伏并网逆变器matlab/simulink仿真模型,可正常使用。

资源截图

代码片段和文件信息

function [sysx0strts] =PWM_G(txuflag)

switch flag

  %%%%%%%%%%%%%%%%%%
  % Initialization %
  %%%%%%%%%%%%%%%%%%
  case 0
    [sysx0strts]=mdlInitializeSizes;

  %%%%%%%%%%%%%%%
  % Derivatives %
  %%%%%%%%%%%%%%%
  case 1
    sys=mdlDerivatives(txu);

  %%%%%%%%%%
  % Update %
  %%%%%%%%%%
  case 2
    sys=mdlUpdate(txu);

  %%%%%%%%%%%
  % Outputs %
  %%%%%%%%%%%
  case 3
    sys=mdlOutputs(txu);

  %%%%%%%%%%%%%%%%%%%%%%%
  % GetTimeOfNextVarHit %
  %%%%%%%%%%%%%%%%%%%%%%%
  case 4
    sys=[];

  %%%%%%%%%%%%%
  % Terminate %
  %%%%%%%%%%%%%
  case 9
    sys=[];

  %%%%%%%%%%%%%%%%%%%%
  % Unexpected flags %
  %%%%%%%%%%%%%%%%%%%%
  otherwise
    error([‘Unhandled flag = ‘num2str(flag)]);

end
end

% end sfuntmpl

%
%=============================================================================
% mdlInitializeSizes
% Return the sizes initial conditions and sample times for the S-function.
%=============================================================================
%
function [sysx0strts]=mdlInitializeSizes

%
% call simsizes for a sizes structure fill it in and convert it to a
% sizes array.
%
% Note that in this example the values are hard coded.  This is not a
% recommended practice as the characteristics of the block are typically
% defined by the S-function parameters.
%
sizes = simsizes;

sizes.NumContStates  = 0;
sizes.NumDiscStates  = 0;
sizes.NumOutputs     = 12;
sizes.NumInputs      = 8;
sizes.DirFeedthrough = 1;
sizes.NumSampleTimes = 1;   % at least one sample time is needed

sys = simsizes(sizes);

%
% initialize the initial conditions
%
x0  = [];

%
% str is always an empty matrix
%
str = [];

%
% initialize the array of sample times
%
ts  = [0 0];
end

% end mdlInitializeSizes

%
%=============================================================================
% mdlDerivatives
% Return the derivatives for the continuous states.
%=============================================================================
%
function sys=mdlDerivatives(txu)

sys = [];
end

% end mdlDerivatives

%
%=============================================================================
% mdlUpdate
% Handle discrete state updates sample time hits and major time step
% requirements.
%=============================================================================
%
function sys=mdlUpdate(txu)

sys = [];
end

% end mdlUpdate

%
%=============================================================================
% mdlOutputs
% Return the block outputs.
%=============================================================================
%
function sys=mdlOutputs(txu)
 
  T1=u(1);T2=u(2);S=u(3);N=u(4);theta=u(5);tri=u(6);ug=u(7);uh=u(8);

  
sys=zeros(112);
T3=1-T1-T2; 
if(S==1 || S==3 || S==5)

switch N
    case 1  %  onn oon ooo poo      ppo poo ooo oon
       if(ug>=uh)
           tap=0;
           

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----

     文件     132512  2013-12-24 20:06  3L_inverter_PV\inverter_3L_PV_250kW.mdl

     文件     160723  2013-06-02 10:49  3L_inverter_PV\inverter_3L_PV_250kW.mdl.r2007b

     文件      13428  2013-05-21 09:30  3L_inverter_PV\PWM_DPWM.m

     文件      13969  2013-05-21 10:02  3L_inverter_PV\PWM_DPWM0.m

     文件       8868  2013-05-21 10:17  3L_inverter_PV\PWM_DPWM1.m

     文件       8954  2013-07-09 14:24  3L_inverter_PV\PWM_G.m

     文件       8127  2013-04-18 15:14  3L_inverter_PV\PWM_G1.m

     文件       5603  2013-04-18 09:22  3L_inverter_PV\Sector_N.m

     文件     419840  2013-12-24 20:08  3L_inverter_PV\sfchart_she111222_sfun.mexw32

     文件        209  2012-03-31 10:54  3L_inverter_PV\SimulinkScope.m

     文件       4835  2013-12-24 20:08  3L_inverter_PV\slprj\_sfprj\sfchart_she111222\_self\sfun\info\binfo.mat

     文件       2832  2013-12-24 20:08  3L_inverter_PV\slprj\_sfprj\sfchart_she111222\_self\sfun\info\chart6_H6nFyHAw3BPo9k54bWSv3D.mat

     文件       2104  2013-12-24 20:08  3L_inverter_PV\slprj\_sfprj\sfchart_she111222\_self\sfun\info\chart7_TDrfoQAFBc9j5ZH6TQGYKH.mat

     文件      74264  2013-12-24 20:08  3L_inverter_PV\slprj\_sfprj\sfchart_she111222\_self\sfun\src\c1_sfchart_she111222.c

     文件       1333  2013-12-24 20:08  3L_inverter_PV\slprj\_sfprj\sfchart_she111222\_self\sfun\src\c1_sfchart_she111222.h

     文件      46465  2013-12-24 20:08  3L_inverter_PV\slprj\_sfprj\sfchart_she111222\_self\sfun\src\c1_sfchart_she111222.obj

     文件      74264  2013-12-24 20:08  3L_inverter_PV\slprj\_sfprj\sfchart_she111222\_self\sfun\src\c2_sfchart_she111222.c

     文件       1333  2013-12-24 20:08  3L_inverter_PV\slprj\_sfprj\sfchart_she111222\_self\sfun\src\c2_sfchart_she111222.h

     文件      46465  2013-12-24 20:08  3L_inverter_PV\slprj\_sfprj\sfchart_she111222\_self\sfun\src\c2_sfchart_she111222.obj

     文件      74264  2013-12-24 20:08  3L_inverter_PV\slprj\_sfprj\sfchart_she111222\_self\sfun\src\c3_sfchart_she111222.c

     文件       1333  2013-12-24 20:08  3L_inverter_PV\slprj\_sfprj\sfchart_she111222\_self\sfun\src\c3_sfchart_she111222.h

     文件      46465  2013-12-24 20:08  3L_inverter_PV\slprj\_sfprj\sfchart_she111222\_self\sfun\src\c3_sfchart_she111222.obj

     文件      74264  2013-12-24 20:08  3L_inverter_PV\slprj\_sfprj\sfchart_she111222\_self\sfun\src\c4_sfchart_she111222.c

     文件       1333  2013-12-24 20:08  3L_inverter_PV\slprj\_sfprj\sfchart_she111222\_self\sfun\src\c4_sfchart_she111222.h

     文件      46465  2013-12-24 20:08  3L_inverter_PV\slprj\_sfprj\sfchart_she111222\_self\sfun\src\c4_sfchart_she111222.obj

     文件      74264  2013-12-24 20:08  3L_inverter_PV\slprj\_sfprj\sfchart_she111222\_self\sfun\src\c5_sfchart_she111222.c

     文件       1333  2013-12-24 20:08  3L_inverter_PV\slprj\_sfprj\sfchart_she111222\_self\sfun\src\c5_sfchart_she111222.h

     文件      46465  2013-12-24 20:08  3L_inverter_PV\slprj\_sfprj\sfchart_she111222\_self\sfun\src\c5_sfchart_she111222.obj

     文件      38259  2013-12-24 20:08  3L_inverter_PV\slprj\_sfprj\sfchart_she111222\_self\sfun\src\c6_sfchart_she111222.c

     文件        893  2013-12-24 20:08  3L_inverter_PV\slprj\_sfprj\sfchart_she111222\_self\sfun\src\c6_sfchart_she111222.h

............此处省略38个文件信息

评论

共有 条评论