ADDED mttroot/mtt/lib/examples/Mechanical/Mechanical-2D/TwoLink/TwoLink_simp.r Index: mttroot/mtt/lib/examples/Mechanical/Mechanical-2D/TwoLink/TwoLink_simp.r ================================================================== --- /dev/null +++ mttroot/mtt/lib/examples/Mechanical/Mechanical-2D/TwoLink/TwoLink_simp.r @@ -0,0 +1,11 @@ +%% Reduce comands to simplify output for system TwoLink (TwoLink_simp.r) + +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% %% Version control history +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% %% $Id$ +% %% $Log$ +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + + +END; ADDED mttroot/mtt/lib/examples/Mechanical/Mechanical-2D/TwoLink/TwoLink_subs.r Index: mttroot/mtt/lib/examples/Mechanical/Mechanical-2D/TwoLink/TwoLink_subs.r ================================================================== --- /dev/null +++ mttroot/mtt/lib/examples/Mechanical/Mechanical-2D/TwoLink/TwoLink_subs.r @@ -0,0 +1,16 @@ +%% Reduce substitution statements for system TwoLink (TwoLink_subs.r) + +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% %% Version control history +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% %% $Id$ +% %% $Log$ +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + + trig1 := {cos(~x)*cos(~y) => (cos(x+y)+cos(x-y))/2, + cos(~x)*sin(~y) => (sin(x+y)-sin(x-y))/2, + sin(~x)*sin(~y) => (cos(x-y)-cos(x+y))/2, + cos(~x)^2 => (1+cos(2*x))/2, + sin(~x)^2 => (1-cos(2*x))/2}; + LET trig1; +END;