Index: mttroot/mtt/bin/mtt ================================================================== --- mttroot/mtt/bin/mtt +++ mttroot/mtt/bin/mtt @@ -13,10 +13,13 @@ ############################################################### ## Version control history ############################################################### ## $Header$ ## $Log$ +## Revision 1.276 2000/10/15 09:30:31 peterg +## *** empty log message *** +## ## Revision 1.275 2000/10/12 18:38:47 peterg ## New method of sympar generation implemented - uses mtt_make_sympar ## Check/update of numpar.txt is forced. ## ## Revision 1.274 2000/10/12 15:11:54 peterg @@ -1856,20 +1859,11 @@ #SUMMARY sympar symbolic parameters (tex) # txt to tex (LaTeX) sympar conversion $1_sympar.tex: $1_sympar.txt sympar_txt2tex $1 -#SUMMARY logic Dynamic switch logic (txt) -$1_logic.txt: - echo Creating $1_logic.txt - ( \ - echo '# -*-octave-*- Put Emacs into octave-mode'; \ - echo "# Simulation parameters for system $1 ($1_logic.txt)"; \ - echo "# Generated by MTT on" `date`.; \ - cat $MTTPATH/trans/rcs_header.sh; \ - echo ;\ - )> $1_logic.txt + #SUMMARY logic Dynamic switch logic (tex) #SUMMARY logic Dynamic switch logic (view) $1_logic.tex: $1_logic.txt txt2tex $1 logic txt @@ -1876,12 +1870,12 @@ #SUMMARY switch Dynamic switch information (txt) $1_switch.txt: $1_struc.txt struc2switch_txt $1 -$1_switchopen.m: $1_switch.txt $1_sympars.txt $1_logic.txt - switch_txt2m $1 +#$1_switchopen.m: $1_switch.txt $1_sympars.txt $1_logic.txt +# switch_txt2m $1 #SUMMARY sympars sympar + dynamic switch information (txt) $1_sympars.txt: $1_sympar.txt $1_switch.txt echo Creating $1_sympars.txt cat $1_sympar.txt $1_switch.txt > $1_sympars.txt @@ -1960,16 +1954,37 @@ mtt_update $1 numpar endif #SUMMARY state numerical state declaration -- default (txt) $1_state.txt : FORCE + mtt -q $1 struc txt mtt -q $1 sympar txt ifeq ($target,$1_state.txt) mtt_update $1 state update else mtt_update $1 state endif + +#SUMMARY state numerical state declaration -- default (txt) +$1_input.txt : FORCE + mtt -q $1 struc txt + mtt -q $1 sympar txt +ifeq ($target,$1_input.txt) + mtt_update $1 input update +else + mtt_update $1 input +endif + +#SUMMARY logic Dynamic switch logic (txt) +$1_logic.txt : FORCE + mtt -q $1 struc txt + mtt -q $1 sympar txt +ifeq ($target,$1_logic.txt) + mtt_update $1 logic update +else + mtt_update $1 logic +endif # Dummy target FORCE: #SUMMARY numpar numerical parameter declaration (m) @@ -1980,29 +1995,29 @@ #SUMMARY numpar numerical parameter declaration (view) $1_numpar.c: $1_numpar.txt $1_sympar.c txt2c $1 numpar #SUMMARY input numerical input declaration -- default (txt) -ifeq ($steadystate_computation,yes) -$1_input.txt: - mtt -q $mtt_switches $1 ss r - mtt -q $mtt_switches $1 struc txt - mtt -q $mtt_switches $1 switch txt - struc2input_txt2txt -ss $1 +#'ifeq ($steadystate_computation,yes) +#$1_input.txt: +# mtt -q $mtt_switches $1 ss r +# mtt -q $mtt_switches $1 struc txt +# mtt -q $mtt_switches $1 switch txt +# struc2input_txt2txt -ss $1 #$1_state.txt: # mtt -q $mtt_switches $1 ss r # mtt -q $mtt_switches $1 struc txt # struc2state_txt2txt -ss $1 -else -$1_input.txt: - mtt -q $mtt_switches $1 struc txt - mtt -q $mtt_switches $1 switch txt - struc2input_txt2txt $1 +#else +#$1_input.txt: +# mtt -q $mtt_switches $1 struc txt +# mtt -q $mtt_switches $1 switch txt +# struc2input_txt2txt $1 #$1_state.txt: # mtt -q $mtt_switches $1 struc txt # struc2state_txt2txt $1 -endif +#endif #ifeq ($switches,0) #$1_input.txt: # mtt $mtt_switches $1 struc txt; @@ -2019,10 +2034,14 @@ #SUMMARY input numerical input declaration (m) $1_input.m: $1_input.txt $1_sympars.txt mtt_txt2m $1 input + +#SUMMARY input numerical input declaration (m) +$1_logic.m: $1_logic.txt $1_switch.txt + mtt_txt2m $1 logic #SUMMARY state state declaration -- default (txt) #$1_state.txt: # mtt $mtt_switches $1 struc txt; # mtt $mtt_switches $1 ss r; @@ -2270,17 +2289,17 @@ # The main simulation programme ifeq ($integration_method,implicit) $1_ode2odes.m : $1_def.r $1_sympars.txt $1_smxa.$m $1_smxax.$m\ $1_simpar.m $1_numpar.m $1_state.m $1_input.m \ - $1_csex.$m $1_cseo.$m $1_switchopen.m + $1_csex.$m $1_cseo.$m $1_logic.m make_ode2odes $1 $integration_method endif ifeq ($integration_method,euler) $1_ode2odes.m : $1_def.r $1_sympars.txt\ $1_simpar.m $1_numpar.m $1_state.m $1_input.m \ - $1_ode.$m $1_odeo.$m $1_switchopen.m + $1_ode.$m $1_odeo.$m $1_logic.m make_ode2odes $1 $integration_method endif #Conversion of m to p to c @@ -2315,23 +2334,23 @@ mtt_m2p $1_smx.m $1_smxa.p : $1_def.r $1_smxa.m mtt_m2p $1_smxa.m $1_smxax.p : $1_def.r $1_smxax.m mtt_m2p $1_smxax.m -$1_switchopen.p : $1_def.r $1_switchopen.m - mtt_m2p $1_switchopen.m +$1_logic.p : $1_def.r $1_logic.m + mtt_m2p $1_logic.m ifeq ($integration_method,implicit) $1_ode2odes.p : $1_ode2odes.m $1_def.r $1_smxa.p $1_smxax.p\ $1_simpar.p $1_numpar.p $1_state.p $1_input.p \ - $1_csex.p $1_cseo.p $1_switchopen.p + $1_csex.p $1_cseo.p $1_logic.p mtt_m2p $1_ode2odes.m $integration_method $stdin endif ifeq ($integration_method,euler) $1_ode2odes.p : $1_ode2odes.m $1_def.r\ $1_simpar.p $1_numpar.p $1_state.p $1_input.p \ - $1_ode.p $1_odeo.p $1_switchopen.p + $1_ode.p $1_odeo.p $1_logic.p mtt_m2p $1_ode2odes.m $integration_method $stdin endif $1_ode2odes.c: $1_ode2odes.p mtt_p2c $info_switch $1 ode2odes @@ -2625,11 +2644,11 @@ ode2odes_r2c $1 $1_sms.c: $1_sm.c $1_def.r $1_sympar.r sm2sms_r2c $1 ifeq ($computation,octave) -$1_odes.dat2: $1_ode2odes.m $1_ode.m $1_odeo.m $1_numpar.m $1_switchopen.m \ +$1_odes.dat2: $1_ode2odes.m $1_ode.m $1_odeo.m $1_numpar.m $1_logic.m \ $1_def.m $1_input.m $1_state.m $1_simpar.m time octave_ode2odes $1 endif ifeq ($computation,c)