Thu Feb 25 19:32:32 MST 1999 aquarius% maple |\^/| Maple V Release 5.1 (WMI Campus Wide License) ._|\| |/|_. Copyright (c) 1981-1998 by Waterloo Maple Inc. All rights \ MAPLE / reserved. Maple and Maple V are registered trademarks of <____ ____> Waterloo Maple Inc. | Type ? for help. # ----------[ M a p l e ]---------- #interface(echo = 3); # ---------- Initialization ---------- > readlib(showtime): > _Envadditionally:= true: > on; # ---------- Determining Zero Equivalence ---------- # The following expressions are all equal to zero O1 := sqrt(997) - (997^3)^(1/6); 1/2 1/6 997 - 991026973 time = 0.04, bytes = 42610 O2 := simplify(%); 0 time = 0.10, bytes = 156378 O3 := sqrt(999983) - (999983^3)^(1/6); 1/2 1/6 999983 - 999949000866995087 time = 0.00, bytes = 5146 O4 := simplify(%); 0 time = 0.06, bytes = 72890 O5 := (2^(1/3) + 4^(1/3))^3 - 6*(2^(1/3) + 4^(1/3)) - 6; 1/3 1/3 3 1/3 1/3 (2 + 4 ) - 6 2 - 6 4 - 6 time = 0.00, bytes = 5006 O6 := simplify(%); 0 time = 0.05, bytes = 58986 O7 := cos(x)^3 + cos(x)*sin(x)^2 - cos(x); 3 2 cos(x) + cos(x) sin(x) - cos(x) time = 0.01, bytes = 18246 O8 := simplify(%); 0 time = 0.06, bytes = 93026 # See Joel Moses, ``Algebraic Simplification: A Guide for the Perplexed'', # _Communications of the Association of Computing Machinery_, Volume 14, # Number 8, August 1971, 527--537. This expression is zero if Re(x) is # contained in the interval ((4 n - 1)/2 pi, (4 n + 1)/2 pi) for n an integer: # ..., (-5/2 pi, -3/2 pi), (-pi/2, pi/2), (3/2 pi, 5/2 pi), ... O9 := expr:= log(tan(1/2*x + Pi/4)) - arcsinh(tan(x)); ln(tan(1/2 x + 1/4 Pi)) - arcsinh(tan(x)) time = 0.05, bytes = 34142 O10 := combine(simplify(convert(expr, ln))); bytes used=1000256, alloc=786288, time=0.70 _ sin(1/2 x + 1/4 Pi) sin(x) + csgn(cos(x)) ln(-------------------) - ln(---------------------) cos(1/2 x + 1/4 Pi) cos(x) time = 1.04, bytes = 1092610 O11 := assume(-Pi/2 < x, x < Pi/2): time = 0.04, bytes = 36338 O12 := combine(simplify(convert(expr, ln))); bytes used=2001416, alloc=1376004, time=1.91 0 time = 0.81, bytes = 553178 O13 := x:= 'x': time = 0.01, bytes = 4082 # Use a roundabout method---show that expr is a constant equal to zero O14 := dexpr:= diff(expr, x); 2 1/2 + 1/2 tan(1/2 x + 1/4 Pi) 2 1/2 ------------------------------ - (tan(x) + 1) tan(1/2 x + 1/4 Pi) time = 0.01, bytes = 9370 O15 := simplify(expand(dexpr)); _ csgn(cos(x)) - 1 - ---------------- cos(x) time = 0.14, bytes = 162334 O16 := assume(-Pi/2 < x, x < Pi/2): time = 0.01, bytes = 11278 O17 := simplify(expand(dexpr)); 0 time = 0.13, bytes = 133350 O18 := x:= 'x': time = 0.01, bytes = 3654 O19 := dexpr:= 'dexpr': time = 0.00, bytes = 3998 O20 := simplify(subs(x = 0, expr)); 0 time = 0.02, bytes = 10174 O21 := expr:= 'expr': time = 0.01, bytes = 3826 O22 := log((2*sqrt(r) + 1)/sqrt(4*r + 4*sqrt(r) + 1)); 1/2 2 r + 1 ln(---------------------) 1/2 1/2 (4 r + 4 r + 1) time = 0.02, bytes = 29226 O23 := simplify(%); 0 time = 0.18, bytes = 137866 O24 := (4*r + 4*sqrt(r) + 1)^(sqrt(r)/(2*sqrt(r) + 1)) O24 := * (2*sqrt(r) + 1)^(1/(2*sqrt(r) + 1)) - 2*sqrt(r) - 1; / 1/2 \ | r | / 1 \ |----------| |----------| | 1/2 | | 1/2 | \2 r + 1/ \2 r + 1/ 1/2 1/2 1/2 (4 r + 4 r + 1) (2 r + 1) - 2 r - 1 time = 0.01, bytes = 9430 O25 := simplify(%); bytes used=3001592, alloc=1638100, time=3.19 / 1/2 \ | r | / 1 \ |----------| |----------| | 1/2 | | 1/2 | \2 r + 1/ \2 r + 1/ 1/2 1/2 1/2 (4 r + 4 r + 1) (2 r + 1) - 2 r - 1 time = 0.47, bytes = 289922 # [Gradshteyn and Ryzhik 9.535(3)] O26 := 2^(1 - z)*GAMMA(z)*Zeta(z)*cos(z*Pi/2) - Pi^z*Zeta(1 - z); (1 - z) z 2 GAMMA(z) Zeta(z) cos(1/2 z Pi) - Pi Zeta(1 - z) time = 0.03, bytes = 24970 O27 := simplify(%); (1 - z) z 2 GAMMA(z) Zeta(z) cos(1/2 z Pi) - Pi Zeta(1 - z) time = 0.14, bytes = 139986 # ---------- Quit ---------- O28 := quit bytes used=3430400, alloc=1638100, time=3.62 real 4.52 user 3.66 sys 0.82