Differences From Artifact [202c842c74]:

To Artifact [e9500f09d1]:


8
9
10
11
12
13
14



15
16
17
18
19
20
21
# Copyright (C) 2000 by Peter J. Gawthrop

###############################################################
## Version control history
###############################################################
## $Id$
## $Log$



## Revision 1.16  2000/12/01 17:56:30  peterg
## Removed spurious  echo '## Set matrices to zero' - thanks Geraint
##
## Revision 1.15  2000/11/29 21:06:16  peterg
## Removed Npar creation - not needed??
##
## Revision 1.14  2000/11/27 11:51:43  peterg







>
>
>







8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# Copyright (C) 2000 by Peter J. Gawthrop

###############################################################
## Version control history
###############################################################
## $Id$
## $Log$
## Revision 1.17  2000/12/01 20:55:01  peterg
## Added Geraint's fix for zeroing matrices
##
## Revision 1.16  2000/12/01 17:56:30  peterg
## Removed spurious  echo '## Set matrices to zero' - thanks Geraint
##
## Revision 1.15  2000/11/29 21:06:16  peterg
## Removed Npar creation - not needed??
##
## Revision 1.14  2000/11/27 11:51:43  peterg
290
291
292
293
294
295
296

297

298
299
300
301
302
303
304
305
306
done
}
function declare_dummies(){
# Get the dummies
dummies="mtt_tmp"
rm -f mtt_dummies
for dummy in $dummies; do

    awk '{

     if (match($1,dummy)==1) print $1
     }' dummy=$dummy < ${fun_name}.m >> mtt_dummies
done

dummy_list=`sort -u mtt_dummies`

# Comments
cat <<EOF








>
|
>
|
|







293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
done
}
function declare_dummies(){
# Get the dummies
dummies="mtt_tmp"
rm -f mtt_dummies
for dummy in $dummies; do
    grep "${dummy}[0-9]* " < ${fun_name}.m |\
    awk '{ 
          # if (match(dummy,$1)==1)
             print $1
         }' dummy=$dummy | sort -u >> mtt_dummies
done

dummy_list=`sort -u mtt_dummies`

# Comments
cat <<EOF

332
333
334
335
336
337
338






339
340
341
342
343
344
345
# Parameters
if [ "$parameters" = "yes" ]; then
cat <<EOF

$Lc Parameters $Rc
EOF
sympar2par_txt2m ${system} ""  "$constant_declaration" "$minusone"






fi

# States
if [ "$states" = "yes" ]; then
cat <<EOF

$Lc States $Rc







>
>
>
>
>
>







337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
# Parameters
if [ "$parameters" = "yes" ]; then
cat <<EOF

$Lc Parameters $Rc
EOF
sympar2par_txt2m ${system} ""  "$constant_declaration" "$minusone"
cat <<EOF

$Lc Switches $Rc
EOF
strip_comments <${system}_logic.txt | awk '{printf("  int %s = 0;\n", tolower($1))}' 

fi

# States
if [ "$states" = "yes" ]; then
cat <<EOF

$Lc States $Rc

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