12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
###############################################################
## Version control history
###############################################################
## $Id$
##
## $Log$
## Revision 1.20 2000/10/16 08:36:31 peterg
## Creat empty _aliased file if it doesn't exist
##
## Revision 1.19 2000/10/12 19:25:39 peterg
## Now generateds the _aliased.txt file
##
## Revision 1.18 2000/09/15 08:09:42 peterg
|
>
>
>
|
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
###############################################################
## Version control history
###############################################################
## $Id$
##
## $Log$
## Revision 1.21 2000/10/16 08:40:35 peterg
## Whoops! Must touch mtt_aliased
##
## Revision 1.20 2000/10/16 08:36:31 peterg
## Creat empty _aliased file if it doesn't exist
##
## Revision 1.19 2000/10/12 19:25:39 peterg
## Now generateds the _aliased.txt file
##
## Revision 1.18 2000/09/15 08:09:42 peterg
|
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
|
echo Creating $eqnfile $blurb
echo Creating $deffile
echo Creating $structurefile
# Use matrix manipulation to accomplish the transformation
$MATRIX << EOF > cbg2ese_m2r.log 2>mtt_error.txt
infofile = '$infofile';;
infofilenum = fopen(infofile,'w');
structurefile = '$structurefile';;
structurefilenum = fopen(structurefile,'w');
deffile = '$1_def.r';
deffilenum = fopen(deffile,'w');
system_name = '$1';
system_type = '';
system_cr = '';
system_args = '';
full_name = '';
full_name_repetition = '';
% Structure matrix [states,nonstates,inputs,outputs,zero_outputs]
structure = zeros(1,7); # Initialise structure vector
structure = cbg2ese(system_name, system_type, system_cr, ...
system_args, full_name, full_name_repetition, ...
1, structure, structurefilenum, infofilenum);
makedef(structure,deffilenum);
EOF
if [ "$info" = "info" ]; then
cat $infofile
fi
if [ -z "$partition" ]; then
# Don't partition
|
|
|
|
|
|
|
|
|
|
|
|
|
<
|
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
|
echo Creating $eqnfile $blurb
echo Creating $deffile
echo Creating $structurefile
# Use matrix manipulation to accomplish the transformation
$MATRIX << EOF > cbg2ese_m2r.log 2>mtt_error.txt
infofile = "$infofile";;
infofilenum = fopen(infofile,"w");
structurefile = "$structurefile";;
structurefilenum = fopen(structurefile,"w");
deffile = "$1_def.r";
deffilenum = fopen(deffile,"w");
system_name = "$1";
system_type = "";
system_cr = "";
system_args = "";
full_name = "";
full_name_repetition = "";
% Structure matrix [states,nonstates,inputs,outputs,zero_outputs]
structure = zeros(1,7); # Initialise structure vector
structure = cbg2ese(system_name, system_type, system_cr, ...
system_args, full_name, full_name_repetition, ...
1, structure, structurefilenum, infofilenum);
makedef(structure,deffilenum);
EOF
if [ "$info" = "info" ]; then
cat $infofile
fi
if [ -z "$partition" ]; then
# Don't partition
|