⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 control.m

📁 HSP系统是弹性腔理论用于心血管循环系统的模拟仿真
💻 M
📖 第 1 页 / 共 2 页
字号:
	'Position',[368.0689655172414 257.5862068965518 36.00000000000001 16.75862068965517], ...
	'String',eval('num2str(toup)'), ...
   'Callback','toup=str2num(get(gcbo, ''String''));', ...
   'Style','edit', ...
   'Tag','EditText1');

%Sympathetic efferent pathway
%fes1
h1 = uicontrol('Parent',h0, ...
	'Units','points', ...
	'BackgroundColor',[0.752941176470588 0.752941176470588 0.752941176470588], ...
	'ListboxTop',0, ...
	'Position',mat1, ...
	'String','fes1', ...
	'Style','text', ...
	'Tag','StaticText2');
h1 = uicontrol('Parent',h0, ...
	'Units','points', ...
	'BackgroundColor',[1 1 1], ...
	'ListboxTop',0, ...
   'Position',[288.4827586206897 224.6896551724138 36.00000000000001 16.75862068965517], ...
   'String',eval('num2str(fes1)'), ...
   'Callback','fes1=str2num(get(gcbo, ''String''));', ...
   'Style','edit', ...
   'Tag','EditText1');

%fes0
h1 = uicontrol('Parent',h0, ...
	'Units','points', ...
	'BackgroundColor',[1 1 1], ...
	'ListboxTop',0, ...
	'Position',mat2, ...
	'String',eval('num2str(fes0)'), ...
   'Callback','fes0=str2num(get(gcbo, ''String''));', ...
   'Style','edit', ...
	'Tag','EditText1');
h1 = uicontrol('Parent',h0, ...
	'Units','points', ...
	'BackgroundColor',[0.752941176470588 0.752941176470588 0.752941176470588], ...
	'ListboxTop',0, ...
	'Position',mat3, ...
	'String','fes0', ...
	'Style','text', ...
   'Tag','StaticText2');

%kes
h1 = uicontrol('Parent',h0, ...
	'Units','points', ...
	'BackgroundColor',[0.752941176470588 0.752941176470588 0.752941176470588], ...
	'ListboxTop',0, ...
	'Position',[97.58620689655174 224.6896551724138 22.96551724137932 12.41379310344828], ...
	'String','kes', ...
	'Style','text', ...
	'Tag','StaticText2');
h1 = uicontrol('Parent',h0, ...
	'Units','points', ...
	'BackgroundColor',[1 1 1], ...
	'ListboxTop',0, ...
	'Position',mat4, ...
	'String',eval('num2str(kes)'), ...
   'Callback','kes=str2num(get(gcbo, ''String''));', ...
   'Style','edit', ...
   'Tag','EditText1');

%fesmin
h1 = uicontrol('Parent',h0, ...
	'Units','points', ...
	'BackgroundColor',[1 1 1], ...
	'ListboxTop',0, ...
	'Position',[51.58620689655173 224.6896551724138 36.00000000000001 16.75862068965517], ...
	'String',eval('num2str(fesmin)'), ...
   'Callback','fesmin=str2num(get(gcbo, ''String''));', ...
   'Style','edit', ...
	'Tag','EditText1');
h1 = uicontrol('Parent',h0, ...
	'Units','points', ...
	'BackgroundColor',[0.752941176470588 0.752941176470588 0.752941176470588], ...
	'ListboxTop',0, ...
	'Position',[18.62068965517242 224.6896551724138 22.96551724137932 12.41379310344828], ...
	'String','fesmin', ...
	'Style','text', ...
   'Tag','StaticText2');

%Vagal efferent pathway
%fcs0
h1 = uicontrol('Parent',h0, ...
	'Units','points', ...
	'BackgroundColor',[0.752941176470588 0.752941176470588 0.752941176470588], ...
	'ListboxTop',0, ...
	'Position',[17.37931034482759 192.4137931034483 22.96551724137932 12.41379310344828], ...
	'String','fcs0', ...
	'Style','text', ...
	'Tag','StaticText2');
h1 = uicontrol('Parent',h0, ...
	'Units','points', ...
	'BackgroundColor',[1 1 1], ...
	'ListboxTop',0, ...
	'Position',[50.3448275862069 192.4137931034483 36.00000000000001 16.75862068965517], ...
	'String',eval('num2str(fcs0)'), ...
   'Callback','fcs0=str2num(get(gcbo, ''String''));', ...
   'Style','edit', ...
   'Tag','EditText1');

%kev
h1 = uicontrol('Parent',h0, ...
	'Units','points', ...
	'BackgroundColor',[1 1 1], ...
	'ListboxTop',0, ...
	'Position',[129.3103448275862 192.4137931034483 36.00000000000001 16.75862068965517], ...
	'String',eval('num2str(kev)'), ...
   'Callback','kev=str2num(get(gcbo, ''String''));', ...
   'Style','edit', ...
	'Tag','EditText1');
h1 = uicontrol('Parent',h0, ...
	'Units','points', ...
	'BackgroundColor',[0.752941176470588 0.752941176470588 0.752941176470588], ...
	'ListboxTop',0, ...
	'Position',[96.34482758620692 192.4137931034483 22.96551724137932 12.41379310344828], ...
	'String','kev', ...
	'Style','text', ...
   'Tag','StaticText2');

%fev0
h1 = uicontrol('Parent',h0, ...
	'Units','points', ...
	'BackgroundColor',[0.752941176470588 0.752941176470588 0.752941176470588], ...
	'ListboxTop',0, ...
	'Position',[175.3103448275862 192.4137931034483 22.96551724137932 12.41379310344828], ...
	'String','fev0', ...
	'Style','text', ...
	'Tag','StaticText2');
h1 = uicontrol('Parent',h0, ...
	'Units','points', ...
	'BackgroundColor',[1 1 1], ...
	'ListboxTop',0, ...
	'Position',[208.2758620689655 192.4137931034483 36.00000000000001 16.75862068965517], ...
	'String',eval('num2str(fev0)'), ...
   'Callback','fev0=str2num(get(gcbo, ''String''));', ...
   'Style','edit', ...
   'Tag','EditText1');

%fev1
h1 = uicontrol('Parent',h0, ...
	'Units','points', ...
	'BackgroundColor',[1 1 1], ...
	'ListboxTop',0, ...
	'Position',[287.2413793103448 192.4137931034483 36.00000000000001 16.75862068965517], ...
	'String',eval('num2str(fev1)'), ...
   'Callback','fev1=str2num(get(gcbo, ''String''));', ...
   'Style','edit', ...
	'Tag','EditText1');
h1 = uicontrol('Parent',h0, ...
	'Units','points', ...
	'BackgroundColor',[0.752941176470588 0.752941176470588 0.752941176470588], ...
	'ListboxTop',0, ...
	'Position',[254.2758620689655 192.4137931034483 22.96551724137932 12.41379310344828], ...
	'String','fev1', ...
	'Style','text', ...
	'Tag','StaticText2');


%-------------------------------------------------------------------------------% Config figure%-------------------------------------------------------------------------------%hFig = figure( ...%                'Name'          , 'Effectors'   , ...%                'Visible'       , 'on'                     , ...%                'Units'         , 'points'                  , ...%                'Position'      , [5 180 505 275]           , ...%                'numbertitle'   , 'off'                     , ...%                'Tag'           , 'effector'                   );
%-------------------------------------------------------------------------------% Set up grid of editable text boxes in the figure%-------------------------------------------------------------------------------xCoord  = (0:9)*70+5;yCoord  = (0:9)*17+20;uiWide  = 45;uiHigh  = 15;
parts   = {'Emax,lv','Emax,rv','Rsp','Rep', ...            'Vu,sv','Vu,ev','T,s','T,v'};            vars    = {'Gx','toux','Dx','initx'};nParts  = length(parts);nVars   = length(vars);etb     = zeros( nParts, nVars ); % array for storing editable text box handlesfor row = 1:nParts,    % Put in text label for row    txt = uicontrol( ...
        'Style'            , 'text'                                     , ...        'String'           , parts{nParts - row + 1}                    , ...        'Units'            , 'points'                                   , ...        'Position'         , [xCoord(1), yCoord(row), uiWide, uiHigh]   , ...        'Tag'              , 'PartText'                                 );            % Put in an etb for ea. column (ea. variable)    for col = 1:nVars,        % generate variable and callback strings        vText = [ vars{col} '(' num2str(nParts - row + 1) ')' ];        cText = [ vText '=str2num(get(gcbo,''String''));'];
        % generate the etb
        if row ~= 1 | col ~= 4,
           etb(row,col) = uicontrol( ...
              'Style'          , 'edit'                                    , ...
              'String'         , eval(['num2str(' vText ')'])              , ...
              'BackgroundColor', [1 1 1]                                   , ...
              'Units'          , 'points'                                  , ...
              'Position'       , [xCoord(col+1) yCoord(row) uiWide uiHigh ], ...
              'CallBack'       , [cText, 'set_param(gcb,''UserData'',1);'] , ...
              'Tag'            , [ parts{nParts - row + 1} '_' vars{col} ] );    
        end
        if row == 1,            % put labels on the top of the column            yPreCalc = yCoord(nParts + 1);            txt = uicontrol( ...
                'Style'          ,'text'                                , ...                'String'         ,vars{col}                             , ...                'Units'          ,'points'                              , ...                'Position'       ,[xCoord(col+1) yPreCalc uiWide uiHigh], ...                'Tag'            ,'VarText'                             );            end % if row =      end % for col =... end % for row =...
 

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -