Overview
Comment:Don't copy port bond causality if already set -- allows subsystem
causality to be preset directely on named SS.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | origin/master | trunk
Files: files | file ages | folders
SHA3-256: 084adb76c9d3013e3cc8a40c3498a7a1ce35c053bab98a07238fdf40001c875d
User & Date: gawthrop@users.sourceforge.net on 1996-12-31 11:49:09
Other Links: branch diff | manifest | tags
Context
1996-12-31
16:14:53
Now handles multi-character subscripts. check-in: dbdafa4472 user: gawthrop@users.sourceforge.net tags: origin/master, trunk
11:49:09
Don't copy port bond causality if already set -- allows subsystem
causality to be preset directely on named SS.
check-in: 084adb76c9 user: gawthrop@users.sourceforge.net tags: origin/master, trunk
11:42:36
*** empty log message *** check-in: 49d12edd47 user: gawthrop@users.sourceforge.net tags: origin/master, trunk
Changes

Modified mttroot/mtt/bin/trans/m/abg2cbg.m from [e9b917dd58] to [c7cfca2b49].

13
14
15
16
17
18
19



20
21
22
23
24
25
26
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29







+
+
+







% [bonds,status] = abg2cbg(system_name, system_type, full_name, port_bonds, infofile)

% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %% Version control history
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% %% $Id$
% %% $Log$
% %% Revision 1.12  1996/12/31 11:42:36  peterg
% %% *** empty log message ***
% %%
% %% Revision 1.11  1996/12/07  17:10:48  peterg
% %% Allows port SS at top level - ie takes it to be an ardianry SS at top
% %% level.
% %%
% %% Revision 1.10  1996/12/04 21:48:55  peterg
% %% Compares full-name with empty string (instead of testing for zero
% %% length.
125
126
127
128
129
130
131
132

133
134
135
136






137
138
139
140
141
142
143
128
129
130
131
132
133
134

135
136
137


138
139
140
141
142
143
144
145
146
147
148
149
150







-
+


-
-
+
+
+
+
+
+







  % Find number of port bonds
  [n_port_bonds,columns] = size(port_bonds);

  % Check compatibility - if ok copy port bonds to the internal bonds list.
  if n_port_bonds~=n_ports
    mtt_info(sprintf('%1.0f port bonds incompatible with %1.0f ports', ...
	n_port_bonds, n_ports), infofile);
  else % Copy the port bonds
  else % Copy the port bonds -- but only if not set already
    for i = 1:n_ports      % The port SSs come first
      j = abs(components(i,1)); % Get the bonds attached to the ports
      direction = -sign(components(i,1)); 
      bonds(j,:) = direction*port_bonds(i,:);
      direction = -sign(components(i,1));
      for k=1:2
	if bonds(j,k)==0 % causality not set yet - so copy.
	  bonds(j,k) = direction*port_bonds(i,k);
	end;
      end;
    end;
  end;
end;


% Set initial status
status = -ones(n_components,1);


MTT: Model Transformation Tools
GitHub | SourceHut | Sourceforge | Fossil RSS ]