Overview
Comment: | Now handles numbered SS ports appearing at top level. |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | origin/master | trunk |
Files: | files | file ages | folders |
SHA3-256: |
74e4c1ec17273a3c6d3f7707ff995ead |
User & Date: | gawthrop@users.sourceforge.net on 1996-12-07 17:37:07 |
Other Links: | branch diff | manifest | tags |
Context
1996-12-07
| ||
18:06:50 | Now detects symbolic args ($1 etc) and ignores them. check-in: a9384aee7d user: gawthrop@users.sourceforge.net tags: origin/master, trunk | |
17:37:07 | Now handles numbered SS ports appearing at top level. check-in: 74e4c1ec17 user: gawthrop@users.sourceforge.net tags: origin/master, trunk | |
17:17:40 | Added some ; check-in: fe3cbf057e user: gawthrop@users.sourceforge.net tags: origin/master, trunk | |
Changes
Modified mttroot/mtt/bin/trans/m/cbg2ese.m from [3e4a5831fd] to [437f2f0d2d].
︙ | ︙ | |||
12 13 14 15 16 17 18 19 20 21 22 23 24 25 | % Structure matrix [states,nonstates,inputs,outputs,zero_outputs] % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % %% Version control history % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % %% $Id$ % %% $Log$ % %% Revision 1.8 1996/08/30 16:36:08 peter % %% More info written to ese files. % %% % %% Revision 1.7 1996/08/30 11:23:13 peter % %% Argument substitution implemented. % %% % %% Revision 1.6 1996/08/27 08:04:52 peterg | > > > > | 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 | % Structure matrix [states,nonstates,inputs,outputs,zero_outputs] % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % %% Version control history % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % %% $Id$ % %% $Log$ % %% Revision 1.9 1996/12/04 21:49:47 peterg % %% Compares full-name with empty string (instead of testing for zero % %% length) % %% % %% Revision 1.8 1996/08/30 16:36:08 peter % %% More info written to ese files. % %% % %% Revision 1.7 1996/08/30 11:23:13 peter % %% Argument substitution implemented. % %% % %% Revision 1.6 1996/08/27 08:04:52 peterg |
︙ | ︙ | |||
48 49 50 51 52 53 54 55 | if nargin<3 eqnfile = 'stdout'; end; if nargin<4 infofile = 'stdout'; end; % Create the (full) system name | > > > | | 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 | if nargin<3 eqnfile = 'stdout'; end; if nargin<4 infofile = 'stdout'; end; % Are we at the top level of the heirarchy? at_top_level = strcmp(full_name, ''); % Create the (full) system name if at_top_level full_name = system_name; full_name_repetition = system_name; system_type = system_name; else full_name = [full_name, '_', system_name]; full_name_repetition = [full_name_repetition, ... '_', system_name, '_', num2str(repetition)]; |
︙ | ︙ | |||
169 170 171 172 173 174 175 | full_name, full_name_repetition, ... k, structure, infofile); % Link up the bonds fprintf(filenum, ... '\n\t%s Equations linking up subsystem %s (%s)\n\n', ... pc, comp_name, comp_type); | < < | 176 177 178 179 180 181 182 183 184 185 186 187 188 189 | full_name, full_name_repetition, ... k, structure, infofile); % Link up the bonds fprintf(filenum, ... '\n\t%s Equations linking up subsystem %s (%s)\n\n', ... pc, comp_name, comp_type); name_comp_name = sprintf('%s_%s_%1.0f', ... full_name_repetition, comp_name, k); for port_number=1:length(bond_list) % Effort if comp_bonds(port_number,1)==1 % Source fprintf(filenum, '%s_MTTu%1.0f := %s;\n', ... |
︙ | ︙ | |||
202 203 204 205 206 207 208 | end; disp('---POP---'); else % its a simple component fprintf(filenum, '\n\t%s Equations for component %s (%s), repetition %1.0f\n\n', ... pc, comp_name, comp_type,k); | > > > > > > > > > > > > | | 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 | end; disp('---POP---'); else % its a simple component fprintf(filenum, '\n\t%s Equations for component %s (%s), repetition %1.0f\n\n', ... pc, comp_name, comp_type,k); % Take port SS to be ordinary SS at top level if at_top_level & strcmp(comp_type, 'SS') effort_attribute = cr; flow_attribute = args; if strcmp(effort_attribute, 'MTT_port') % Its a numbered port effort_attribute = 'external'; flow_attribute = 'external'; cr = effort_attribute; args = flow_attribute; end; end; eval(['structure = ', ... eqn_name, ... '(name_r,bond_list,comp_bonds,direction,cr,args,structure,filenum);' ]); end; end; end; fclose(filenum); |
︙ | ︙ |