︙ | | | ︙ | |
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
# Copyright (C) 2000 by Peter J. Gawthrop
###############################################################
## Version control history
###############################################################
## $Header$
## $Log$
## Revision 1.253 2000/08/24 08:53:35 peterg
## New makesubs to create a .subs.r file with output switches to simplify output.
##
## Revision 1.252 2000/08/09 10:31:17 peterg
## Use -d option to find if its a book-style report
##
## Revision 1.251 2000/08/04 10:54:33 peterg
|
>
>
>
|
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
# Copyright (C) 2000 by Peter J. Gawthrop
###############################################################
## Version control history
###############################################################
## $Header$
## $Log$
## Revision 1.254 2000/08/29 09:59:47 peterg
## Version 4.5 -- includes code optimisation using the "Scope" package in reduce
##
## Revision 1.253 2000/08/24 08:53:35 peterg
## New makesubs to create a .subs.r file with output switches to simplify output.
##
## Revision 1.252 2000/08/09 10:31:17 peterg
## Use -d option to find if its a book-style report
##
## Revision 1.251 2000/08/04 10:54:33 peterg
|
︙ | | | ︙ | |
976
977
978
979
980
981
982
983
984
985
986
987
988
989
|
start_at_abg='yes';;
-stdin )
mtt_switches="$mtt_switches $1";
stdin=stdin;;
-oct )
mtt_switches="$mtt_switches $1";
m='oct';;
--version)
echo 'MTT version' $version; exit;;
--versions)
mtt_versions; exit;;
*)
echo "$1 is an invalid argument - ignoring" ;;
esac
|
>
>
|
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
|
start_at_abg='yes';;
-stdin )
mtt_switches="$mtt_switches $1";
stdin=stdin;;
-oct )
mtt_switches="$mtt_switches $1";
m='oct';;
-opt ) mtt_switches="$mtt_switches $1";
optimise='-optimise';;
--version)
echo 'MTT version' $version; exit;;
--versions)
mtt_versions; exit;;
*)
echo "$1 is an invalid argument - ignoring" ;;
esac
|
︙ | | | ︙ | |
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
|
echo ' -d <dir> use directory <dir>'
echo ' -dc Maximise derivative (not integral) causality'
echo ' -dc Maximise derivative (not integral) causality'
echo ' -i implicit Use implicit integration'
echo ' -i euler Use Euler integration'
echo ' -o ode is same as dae'
echo ' -oct use oct files in place of m files where appropriate'
echo ' -p print environment variables'
echo ' -r reset time stamp on representation'
echo ' -s try to generate sensitivity BG (experimental)'
echo ' -ss use steady-state info to initialise simulations'
echo ' -stdin read input data from standard input for simulations'
echo ' -t tidy mode (default)'
echo ' -u untidy mode (leaves files in current dir)'
|
>
|
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
|
echo ' -d <dir> use directory <dir>'
echo ' -dc Maximise derivative (not integral) causality'
echo ' -dc Maximise derivative (not integral) causality'
echo ' -i implicit Use implicit integration'
echo ' -i euler Use Euler integration'
echo ' -o ode is same as dae'
echo ' -oct use oct files in place of m files where appropriate'
echo ' -opt optimise code generation'
echo ' -p print environment variables'
echo ' -r reset time stamp on representation'
echo ' -s try to generate sensitivity BG (experimental)'
echo ' -ss use steady-state info to initialise simulations'
echo ' -stdin read input data from standard input for simulations'
echo ' -t tidy mode (default)'
echo ' -u untidy mode (leaves files in current dir)'
|
︙ | | | ︙ | |
2029
2030
2031
2032
2033
2034
2035
2036
2037
2038
2039
2040
2041
2042
2043
2044
2045
2046
2047
2048
2049
2050
2051
2052
2053
2054
2055
2056
2057
2058
2059
2060
|
#Constrained-state equations
$1_cse.r: $1_dae.r $1_def.r $1_sympar.r $1_subs.r
dae2cse_r $Solve $1; tidy $1_cse.r $1_subs.r
#$1_cse.m: $1_def.r $1_cse.r $1_sympar.r $1_subs.r
# cse_r2m $1; matlab_tidy $1_cse.m
$1_cse.m: $1_def.m $1_cse.r $1_sympars.txt
mtt_r2m -parameters $1 cse; matlab_tidy $1_cse.m; matlab_tidy $1_cseo.m;
$1_cseo.m: $1_cse.m
touch $1_cseo.m
$1_cse.tex: $1_cse.r $1_sympar.r $1_simp.r
cse_r2tex $1 $2; latex_tidy $1_cse.tex
#SUMMARY scse sensitivity constrained-state equations (r)
#SUMMARY scse sensitivity constrained-state equations (tex)
#SUMMARY scse sensitivity constrained-state equations (ps)
$1_scse.r: $1_cse.r $1_def.r
cse2scse_r $1 "$4"; tidy $1_scse.r
#$1_cse.m: $1_def.r $1_cse.r $1_sympar.r $1_subs.r
# cse_r2m $1; matlab_tidy $1_cse.m
$1_scse.m: $1_def.m $1_scse.r $1_sympars.txt
mtt_r2m -parameters $1 scse;
matlab_tidy $1_scse.m; matlab_tidy $1_scseo.m;
$1_scse.tex: $1_scse.r $1_sympar.r $1_simp.r
cse_r2tex $1 $2; latex_tidy $1_scse.tex
#SUMMARY ode ordinary differential equations (r)
#SUMMARY ode* ordinary differential equations (m)
|
|
|
|
2035
2036
2037
2038
2039
2040
2041
2042
2043
2044
2045
2046
2047
2048
2049
2050
2051
2052
2053
2054
2055
2056
2057
2058
2059
2060
2061
2062
2063
2064
2065
2066
|
#Constrained-state equations
$1_cse.r: $1_dae.r $1_def.r $1_sympar.r $1_subs.r
dae2cse_r $Solve $1; tidy $1_cse.r $1_subs.r
#$1_cse.m: $1_def.r $1_cse.r $1_sympar.r $1_subs.r
# cse_r2m $1; matlab_tidy $1_cse.m
$1_cse.m: $1_def.m $1_cse.r $1_sympars.txt
mtt_r2m $optimise -parameters $1 cse; matlab_tidy $1_cse.m; matlab_tidy $1_cseo.m;
$1_cseo.m: $1_cse.m
touch $1_cseo.m
$1_cse.tex: $1_cse.r $1_sympar.r $1_simp.r
cse_r2tex $1 $2; latex_tidy $1_cse.tex
#SUMMARY scse sensitivity constrained-state equations (r)
#SUMMARY scse sensitivity constrained-state equations (tex)
#SUMMARY scse sensitivity constrained-state equations (ps)
$1_scse.r: $1_cse.r $1_def.r
cse2scse_r $1 "$4"; tidy $1_scse.r
#$1_cse.m: $1_def.r $1_cse.r $1_sympar.r $1_subs.r
# cse_r2m $1; matlab_tidy $1_cse.m
$1_scse.m: $1_def.m $1_scse.r $1_sympars.txt
mtt_r2m $optimise -parameters $1 scse;
matlab_tidy $1_scse.m; matlab_tidy $1_scseo.m;
$1_scse.tex: $1_scse.r $1_sympar.r $1_simp.r
cse_r2tex $1 $2; latex_tidy $1_scse.tex
#SUMMARY ode ordinary differential equations (r)
#SUMMARY ode* ordinary differential equations (m)
|
︙ | | | ︙ | |
2072
2073
2074
2075
2076
2077
2078
2079
2080
2081
2082
2083
2084
2085
2086
|
ifeq ($dae_is_ode,1)
$1_ode.r: $1_dae.r
echo Copying $1_dae.r to $1_ode.r
cp $1_dae.r $1_ode.r
endif
$1_ode.m: $1_def.m $1_ode.r $1_subs.r $1_sympars.txt
mtt_r2m -parameters $1 ode m; matlab_tidy $1_ode.m
$1_ode.oct: $1_def.r $1_ode.p $1_sympars.txt
mtt_p2oct $1 ode
$1_odeo.oct: $1_def.r $1_odeo.p $1_sympars.txt
mtt_p2oct $1 odeo
|
|
|
2078
2079
2080
2081
2082
2083
2084
2085
2086
2087
2088
2089
2090
2091
2092
|
ifeq ($dae_is_ode,1)
$1_ode.r: $1_dae.r
echo Copying $1_dae.r to $1_ode.r
cp $1_dae.r $1_ode.r
endif
$1_ode.m: $1_def.m $1_ode.r $1_subs.r $1_sympars.txt
mtt_r2m $optimise -parameters $1 ode m; matlab_tidy $1_ode.m
$1_ode.oct: $1_def.r $1_ode.p $1_sympars.txt
mtt_p2oct $1 ode
$1_odeo.oct: $1_def.r $1_odeo.p $1_sympars.txt
mtt_p2oct $1 odeo
|
︙ | | | ︙ | |
2178
2179
2180
2181
2182
2183
2184
2185
2186
2187
2188
2189
2190
2191
2192
|
#SUMMARY obs observer equations for CGPC (tex)
#SUMMARY obs* observer equations for CGPC (view)
#SUMMARY obs observer equations for CGPC (ps)
#Observer functions for GPC
$1_obs.r: $1_ode.r $1_def.r $1_obspar.r $1_subs.r
ode2obs_r $1; tidy $1_obs.r
$1_obs.m: $1_def.r $1_sympars.txt $1_obs.r $1_obspar.r $1_numpar.m
mtt_r2m -parameters $1 obs
$1_obs.tex: $1_obs.r $1_sympar.r $1_simp.r
obs_r2tex $1; latex_tidy $1_obs.tex
#SUMMARY rfe robot-form equations (r)
#SUMMARY rfe robot-form equations (tex)
#SUMMARY rfe* robot-form equations (view)
|
|
|
2184
2185
2186
2187
2188
2189
2190
2191
2192
2193
2194
2195
2196
2197
2198
|
#SUMMARY obs observer equations for CGPC (tex)
#SUMMARY obs* observer equations for CGPC (view)
#SUMMARY obs observer equations for CGPC (ps)
#Observer functions for GPC
$1_obs.r: $1_ode.r $1_def.r $1_obspar.r $1_subs.r
ode2obs_r $1; tidy $1_obs.r
$1_obs.m: $1_def.r $1_sympars.txt $1_obs.r $1_obspar.r $1_numpar.m
mtt_r2m $optimise -parameters $1 obs
$1_obs.tex: $1_obs.r $1_sympar.r $1_simp.r
obs_r2tex $1; latex_tidy $1_obs.tex
#SUMMARY rfe robot-form equations (r)
#SUMMARY rfe robot-form equations (tex)
#SUMMARY rfe* robot-form equations (view)
|
︙ | | | ︙ | |
2216
2217
2218
2219
2220
2221
2222
2223
2224
2225
2226
2227
2228
2229
2230
2231
2232
2233
2234
2235
2236
2237
2238
2239
2240
2241
2242
2243
2244
2245
|
#SUMMARY dm descriptor matrices (tex)
#SUMMARY dm* descriptor matrices (view)
#SUMMARY dm descriptor matrices (ps)
#Linearised system: descriptor matrices
$1_dm.r: $1_dae.r $1_def.r $1_cr.r $1_ss.r $1_sympar.r
dae2dm_r $1; tidy $1_dm.r
$1_dm.m: $1_def.r $1_dm.r $1_sympars.txt
mtt_r2m -parameters $1 dm
$1_dm.tex: $1_dm.r $1_sympar.r $1_simp.r
dm_r2tex $1; latex_tidy $1_dm.tex
#SUMMARY csm constrained-state matrices (r)
#SUMMARY csm constrained-state matrices (m)
#SUMMARY csm constrained-state matrices (tex)
#SUMMARY csm constrained-state matrices (view)
#SUMMARY csm constrained-state matrices (ps)
#Linearised system: constrained-state matrices
$1_csm.r: $1_cse.r $1_def.r $1_cr.r $1_sspar.r
cse2csm_r $1 csm; tidy $1_csm.r
$1_csm.m: $1_def.r $1_csm.r $1_sympars.txt
mtt_r2m -parameters $1 csm; matlab_tidy $1_csm.m
$1_csm.tex: $1_csm.r $1_sympar.r $1_simp.r
csm_r2tex $1 csm; latex_tidy $1_csm.tex
#SUMMARY scsm sensitivity constrained-state matrices (r)
#SUMMARY scsm sensitivity constrained-state matrices (m)
#SUMMARY scsm sensitivity constrained-state matrices (tex)
#SUMMARY scsm sensitivity constrained-state matrices (view)
#SUMMARY scsm sensitivity constrained-state matrices (ps)
|
|
|
|
2222
2223
2224
2225
2226
2227
2228
2229
2230
2231
2232
2233
2234
2235
2236
2237
2238
2239
2240
2241
2242
2243
2244
2245
2246
2247
2248
2249
2250
2251
|
#SUMMARY dm descriptor matrices (tex)
#SUMMARY dm* descriptor matrices (view)
#SUMMARY dm descriptor matrices (ps)
#Linearised system: descriptor matrices
$1_dm.r: $1_dae.r $1_def.r $1_cr.r $1_ss.r $1_sympar.r
dae2dm_r $1; tidy $1_dm.r
$1_dm.m: $1_def.r $1_dm.r $1_sympars.txt
mtt_r2m $optimise -parameters $1 dm
$1_dm.tex: $1_dm.r $1_sympar.r $1_simp.r
dm_r2tex $1; latex_tidy $1_dm.tex
#SUMMARY csm constrained-state matrices (r)
#SUMMARY csm constrained-state matrices (m)
#SUMMARY csm constrained-state matrices (tex)
#SUMMARY csm constrained-state matrices (view)
#SUMMARY csm constrained-state matrices (ps)
#Linearised system: constrained-state matrices
$1_csm.r: $1_cse.r $1_def.r $1_cr.r $1_sspar.r
cse2csm_r $1 csm; tidy $1_csm.r
$1_csm.m: $1_def.r $1_csm.r $1_sympars.txt
mtt_r2m $optimise -parameters $1 csm; matlab_tidy $1_csm.m
$1_csm.tex: $1_csm.r $1_sympar.r $1_simp.r
csm_r2tex $1 csm; latex_tidy $1_csm.tex
#SUMMARY scsm sensitivity constrained-state matrices (r)
#SUMMARY scsm sensitivity constrained-state matrices (m)
#SUMMARY scsm sensitivity constrained-state matrices (tex)
#SUMMARY scsm sensitivity constrained-state matrices (view)
#SUMMARY scsm sensitivity constrained-state matrices (ps)
|
︙ | | | ︙ | |
2258
2259
2260
2261
2262
2263
2264
2265
2266
2267
2268
2269
2270
2271
2272
2273
2274
2275
2276
2277
2278
2279
2280
2281
2282
2283
2284
2285
2286
2287
2288
2289
2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300
2301
2302
2303
2304
2305
2306
2307
|
#SUMMARY sm state matrices (c)
#SUMMARY sm* state matrices (view)
#SUMMARY sm state matrices (ps)
#Linearised system: state matrices
$1_sm.r: $1_csm.r $1_def.r $1_cr.r $1_ss.r $1_sympar.r
csm2sm_r $1 sm; tidy $1_sm.r
$1_sm.m: $1_def.r $1_sm.r $1_sympars.txt
mtt_r2m -parameters $1 sm
$1_sm.icad: $1_sm.m $1_numpar.m
sm_m2icad $1
$1_sm.c: $1_def.r $1_sm.r $1_sympar.c
sm_r2c $1
$1_sm.tex: $1_sm.r $1_sympar.r $1_simp.r
sm_r2tex $1 sm; latex_tidy $1_sm.tex
#SUMMARY ssm sensitivity state matrices (r)
#SUMMARY ssm sensitivity state matrices (icad)
#SUMMARY ssm sensitivity state matrices (tex)
#SUMMARY ssm sensitivity state matrices (c)
#SUMMARY ssm sensitivity state matrices (ps)
#Linearised system: sensitivity state matrices
$1_ssm.r: $1_scsm.r $1_def.r $1_cr.r $1_ss.r $1_sympar.r
csm2sm_r $1 ssm; tidy $1_ssm.r
$1_ssm.m: $1_def.r $1_ssm.r $1_sympars.txt
mtt_r2m -parameters $1 ssm
$1_ssm.tex: $1_ssm.r $1_sympar.r $1_simp.r
sm_r2tex $1 ssm; latex_tidy $1_ssm.tex
#SUMMARY smx state matrices with variable state x (r)
#SUMMARY smx state matrices with variable state x (m)
#SUMMARY smxx Sparse computation of Ax (m)
#SUMMARY smxtx Sparse computation of ATx (m)
$1_smx.r: $1_def.r $1_def.m $1_ode.r $1_subs.r
ode2smx_lang $1 r; tidy $1_smx.r
$1_smx.m: $1_def.r $1_def.m $1_cse.r $1_sympars.txt $1_subs.r
cse2smx_lang -parameters $1 smx m
$1_smxa.m: $1_def.r $1_def.m $1_cse.r $1_sympars.txt $1_subs.r
cse2smx_lang -parameters $matrix_smxa $1 smxa m
$1_smxax.m: $1_def.r $1_def.m $1_cse.r $1_sympars.txt $1_subs.r
cse2smx_lang -parameters $1 smxax m
#SUMMARY smc controller form state matrices etc. - siso only (r)
#SUMMARY smc controller form state matrices etc. - siso only (tex)
#SUMMARY smc* controller form state matrices etc. - siso only (m)
#SUMMARY smc* controller form state matrices etc. - siso only (view)
#SUMMARY smc controller form state matrices etc. - siso only (ps)
#Linearised system: controller form state matrices etc.
|
|
|
|
|
|
|
2264
2265
2266
2267
2268
2269
2270
2271
2272
2273
2274
2275
2276
2277
2278
2279
2280
2281
2282
2283
2284
2285
2286
2287
2288
2289
2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300
2301
2302
2303
2304
2305
2306
2307
2308
2309
2310
2311
2312
2313
|
#SUMMARY sm state matrices (c)
#SUMMARY sm* state matrices (view)
#SUMMARY sm state matrices (ps)
#Linearised system: state matrices
$1_sm.r: $1_csm.r $1_def.r $1_cr.r $1_ss.r $1_sympar.r
csm2sm_r $1 sm; tidy $1_sm.r
$1_sm.m: $1_def.r $1_sm.r $1_sympars.txt
mtt_r2m $optimise -parameters $1 sm
$1_sm.icad: $1_sm.m $1_numpar.m
sm_m2icad $1
$1_sm.c: $1_def.r $1_sm.r $1_sympar.c
sm_r2c $1
$1_sm.tex: $1_sm.r $1_sympar.r $1_simp.r
sm_r2tex $1 sm; latex_tidy $1_sm.tex
#SUMMARY ssm sensitivity state matrices (r)
#SUMMARY ssm sensitivity state matrices (icad)
#SUMMARY ssm sensitivity state matrices (tex)
#SUMMARY ssm sensitivity state matrices (c)
#SUMMARY ssm sensitivity state matrices (ps)
#Linearised system: sensitivity state matrices
$1_ssm.r: $1_scsm.r $1_def.r $1_cr.r $1_ss.r $1_sympar.r
csm2sm_r $1 ssm; tidy $1_ssm.r
$1_ssm.m: $1_def.r $1_ssm.r $1_sympars.txt
mtt_r2m $optimise -parameters $1 ssm
$1_ssm.tex: $1_ssm.r $1_sympar.r $1_simp.r
sm_r2tex $1 ssm; latex_tidy $1_ssm.tex
#SUMMARY smx state matrices with variable state x (r)
#SUMMARY smx state matrices with variable state x (m)
#SUMMARY smxx Sparse computation of Ax (m)
#SUMMARY smxtx Sparse computation of ATx (m)
$1_smx.r: $1_def.r $1_def.m $1_ode.r $1_subs.r
ode2smx_lang $1 r; tidy $1_smx.r
$1_smx.m: $1_def.r $1_def.m $1_cse.r $1_sympars.txt $1_subs.r
cse2smx_lang $optimise -parameters $1 smx m
$1_smxa.m: $1_def.r $1_def.m $1_cse.r $1_sympars.txt $1_subs.r
cse2smx_lang $optimise -parameters $matrix_smxa $1 smxa m
$1_smxax.m: $1_def.r $1_def.m $1_cse.r $1_sympars.txt $1_subs.r
cse2smx_lang $optimise -parameters $1 smxax m
#SUMMARY smc controller form state matrices etc. - siso only (r)
#SUMMARY smc controller form state matrices etc. - siso only (tex)
#SUMMARY smc* controller form state matrices etc. - siso only (m)
#SUMMARY smc* controller form state matrices etc. - siso only (view)
#SUMMARY smc controller form state matrices etc. - siso only (ps)
#Linearised system: controller form state matrices etc.
|
︙ | | | ︙ | |