|\^/| Maple V Release 4 (INRIA) ._|\| |/|_. Copyright (c) 1981-1996 by Waterloo Maple Inc. All rights \ MAPLE / reserved. Maple and Maple V are registered trademarks of <____ ____> Waterloo Maple Inc. | Type ? for help. # The following examples are presented as is. They accompany the # paper ``Non-commutative Elimination in Ore Algebras Proves # Multivariate Identities'', by Frederic Chyzak and Bruno Salvy. # # Some results of this session may differ from those of the paper due # to changes in the program. For the reason of changes and new bugs, # I also did not reproduce all the examples of the paper. This will # be done in the future. # # Frederic Chyzak, July 8, 1997. > # Change this according to your configuration. > libname:=`/export/chyzak/ArchivesMgfun/Lib2.0-5.4-released`,libname: > with(Ore_algebra): > with(Groebner): > # Section 1.4.1. Jacobi polynomials > A:=skew_algebra(comm=[a,b],shift=[Sn,n],diff=[Dx,x]): > G:=[2*(n+2)*(n+a+b+2)*(2*n+a+b+2)*Sn^2 > -((2*n+a+b+3)*(a^2-b^2)+(2*n+a+b+2) > *(2*n+a+b+3)*(2*n+a+b+4)*x)*Sn > +2*(n+a+1)*(n+b+1)*(2*n+a+b+4), > (2*n+a+b+2)*(1-x^2)*Dx*Sn-(n+1) > *(a-b-(2*n+a+b+2)*x)*Sn-2*(n+a+1)*(n+b+1)]: > skew_elim(G[1],G[2],Sn,A); bytes used=2017600, alloc=1834672, time=0.51 bytes used=4163208, alloc=2752008, time=1.11 bytes used=6202136, alloc=2883056, time=1.67 bytes used=8213832, alloc=3276200, time=2.16 bytes used=10214232, alloc=3276200, time=2.77 2 2 2 2 -n a - n - n b - n + Dx a x + Dx x b + 2 Dx x + Dx a - Dx b + Dx x - Dx > # Section 1.4.2. Gauss's hypergeometric function > A:=skew_algebra(comm=[b,c],diff=[Dz,z],shift=[Sa,a]): > P:=z*(1-z)*Dz^2+(c-(a+b+1)*z)*Dz-a*b: > H:=a*Sa-(z*Dz+a): > skew_elim(P,H,Dz,A); 2 2 2 a + z a Sa - 2 a Sa - z a Sa + a Sa - c + 1 - z b Sa - 2 Sa + Sa c + Sa 2 + z Sa - z Sa > A:=skew_algebra(comm=[a,b,c],diff=[Dz,z]): > GCD:=skew_gcdex(P,z*Dz+a,Dz,A): > B:=collect((a-1)*subs(a=a-1,GCD[3]/GCD[1]),Dz,factor); z (-1 + z) Dz -c + z b + a B := ------------- + ------------ a - c a - c > # Section 1.4.3. Partially hypergeometric series > A:=shift_algebra([Sn,n],[Sk,k],[comm,z]): > h:=(-1)^k*binomial(n,k)^2*binomial(n+k,k)^2; k 2 2 h := (-1) binomial(n, k) binomial(n + k, k) > G:=numer(normal({Sn-subs(n=n+1,h)/h,Sk-subs(k=k+1,h)/h},expanded)): > G:=collect(G,{Sn,Sk},factor); 2 2 4 2 2 G := {Sn (n + 1 - k) - (n + 1 + k) , Sk (k + 1) + (n + 1 + k) (n - k) } > L:=op(select(has,G,Sk)); 4 2 2 L := Sk (k + 1) + (n + 1 + k) (n - k) # You can run this if you have gfun in the share library. # #with(share): #readshare(gfun,analysis): #with(gfun): #applyopr(L,u(k),A); #rectodiffeq({"},u(k),f(z)); #M:=collect(subs({seq((D@@i)(f)(z)=Dz^i,i=0..4)},"),Dz,factor); # # Otherwise, here is the result. > M:=z^3*(z+1)*Dz^4+2*z^2*(4*z+3)*Dz^3-z*(-14*z+2*z*n+2*z*n^2-7)*Dz^2 > +(-4*z*n^2+4*z-4*z*n+1)*Dz+(n+1)^2*n^2; 3 4 2 3 2 2 M := z (z + 1) Dz + 2 z (4 z + 3) Dz - z (-14 z + 2 z n + 2 z n - 7) Dz 2 2 2 + (-4 z n + 4 z - 4 z n + 1) Dz + (n + 1) n > H:=Sn; H := Sn # Naive method that returns an operator of order 7. > normal(applyopr(H,h,A)/h,expanded); bytes used=12215312, alloc=3276200, time=3.56 2 2 n + 2 n + 2 n k + 1 + 2 k + k ------------------------------- 2 2 n + 2 n - 2 n k + 1 - 2 k + k > P:=numer("): Q:=denom(""): > A:=skew_algebra(diff=[Dz,z],shift=[Sn,n]): > P2:=collect(subs({seq(k^i=skew_power(z*Dz,i,A), > i=1..degree(P,k))},P),Dz,factor); 2 2 2 P2 := z Dz + z (2 n + 3) Dz + (n + 1) > Q2:=collect(subs({seq(k^i=skew_power(z*Dz,i,A), > i=1..degree(Q,k))},Q),Dz,factor); 2 2 2 Q2 := z Dz - z (2 n + 1) Dz + (n + 1) > collect(Q2*H-P2,{Dz,Sn},distributed,factor); 2 2 2 2 2 (n + 1) Sn + z Dz Sn - z (2 n + 1) Dz Sn - z Dz - z (2 n + 3) Dz 2 - (n + 1) # The contiguity relation of order 7 is: > C[7]:=collect(skew_elim(",M,Dz,A),Sn,factor); bytes used=14216616, alloc=3276200, time=4.34 bytes used=16251064, alloc=3276200, time=5.04 bytes used=18251464, alloc=3276200, time=5.64 bytes used=20289056, alloc=3276200, time=6.30 bytes used=22358432, alloc=3276200, time=6.91 bytes used=24371976, alloc=3407248, time=7.43 bytes used=26387128, alloc=3407248, time=7.91 bytes used=28387464, alloc=3538296, time=8.40 bytes used=30483544, alloc=3669344, time=8.91 bytes used=32503384, alloc=3931440, time=9.41 bytes used=34517584, alloc=3931440, time=9.88 bytes used=36521512, alloc=3931440, time=10.41 bytes used=38604072, alloc=4062488, time=10.91 bytes used=40604464, alloc=4062488, time=11.80 bytes used=42605008, alloc=4062488, time=12.72 bytes used=44961024, alloc=4848776, time=13.45 bytes used=46986648, alloc=4848776, time=14.01 bytes used=49023768, alloc=4848776, time=14.45 bytes used=51033296, alloc=4848776, time=14.88 bytes used=53115568, alloc=4848776, time=15.37 bytes used=55220032, alloc=4848776, time=15.79 bytes used=57301776, alloc=4848776, time=16.47 bytes used=59364400, alloc=4848776, time=17.20 bytes used=61366944, alloc=4848776, time=17.83 bytes used=63368624, alloc=4848776, time=18.78 bytes used=65422080, alloc=4848776, time=19.35 bytes used=67431200, alloc=4848776, time=19.87 bytes used=69465632, alloc=4848776, time=20.36 bytes used=71472904, alloc=4848776, time=20.94 bytes used=73482752, alloc=4848776, time=21.41 bytes used=75498712, alloc=4848776, time=21.86 bytes used=77501920, alloc=4848776, time=22.30 bytes used=79512840, alloc=4848776, time=22.77 bytes used=81514528, alloc=4848776, time=23.21 bytes used=83521640, alloc=4848776, time=23.64 bytes used=85521992, alloc=4848776, time=24.10 bytes used=87522400, alloc=4848776, time=24.58 bytes used=89615784, alloc=4848776, time=25.09 bytes used=91620456, alloc=4848776, time=25.54 bytes used=93626232, alloc=4848776, time=25.97 bytes used=95628520, alloc=4848776, time=26.39 bytes used=97629952, alloc=4848776, time=26.82 bytes used=99673728, alloc=5110872, time=27.29 bytes used=101745784, alloc=5504016, time=27.75 bytes used=103804392, alloc=5504016, time=28.20 bytes used=105834256, alloc=5504016, time=28.65 bytes used=107840592, alloc=5504016, time=29.09 bytes used=109849408, alloc=5504016, time=29.54 bytes used=111867008, alloc=5504016, time=29.99 bytes used=113882984, alloc=5504016, time=30.44 bytes used=115892872, alloc=5504016, time=30.89 bytes used=117945360, alloc=5635064, time=31.35 bytes used=120012640, alloc=5635064, time=31.81 bytes used=122014520, alloc=5635064, time=32.42 bytes used=124014896, alloc=5635064, time=33.35 bytes used=126030760, alloc=5897160, time=33.98 bytes used=128066016, alloc=6290304, time=34.53 bytes used=130090008, alloc=6421352, time=35.09 bytes used=132166960, alloc=6421352, time=35.66 bytes used=134214008, alloc=6421352, time=36.22 bytes used=136271184, alloc=6421352, time=36.78 bytes used=138278032, alloc=6683448, time=37.35 bytes used=140306392, alloc=6683448, time=37.91 bytes used=142370800, alloc=6683448, time=38.49 bytes used=144439648, alloc=6683448, time=39.06 bytes used=146452944, alloc=6683448, time=39.63 bytes used=148497856, alloc=6945544, time=40.19 bytes used=150512888, alloc=6945544, time=40.76 bytes used=152924256, alloc=7076592, time=41.37 bytes used=154978624, alloc=7076592, time=41.97 bytes used=156991232, alloc=7076592, time=42.43 bytes used=159044864, alloc=7076592, time=42.89 bytes used=161070160, alloc=7076592, time=43.35 bytes used=163077768, alloc=7076592, time=43.81 bytes used=165079352, alloc=7076592, time=44.27 bytes used=167122648, alloc=7076592, time=44.74 bytes used=169145288, alloc=7076592, time=45.27 bytes used=171165520, alloc=7076592, time=45.80 bytes used=173167328, alloc=7076592, time=46.31 bytes used=175173784, alloc=7076592, time=46.84 bytes used=177190904, alloc=7076592, time=47.37 bytes used=179206640, alloc=7076592, time=47.90 bytes used=181210136, alloc=7076592, time=48.42 bytes used=183227376, alloc=7076592, time=48.95 bytes used=185240840, alloc=7076592, time=49.47 bytes used=187266016, alloc=7207640, time=50.01 bytes used=189273808, alloc=7207640, time=50.53 bytes used=191281080, alloc=7207640, time=51.06 bytes used=193302160, alloc=7207640, time=51.59 bytes used=195319440, alloc=7207640, time=52.13 bytes used=197327624, alloc=7207640, time=52.66 bytes used=199338624, alloc=7207640, time=53.20 bytes used=201363224, alloc=7207640, time=53.73 bytes used=203395472, alloc=7207640, time=54.28 bytes used=205412896, alloc=7207640, time=54.81 bytes used=207413288, alloc=7338688, time=55.43 bytes used=209415592, alloc=7338688, time=56.43 bytes used=211417088, alloc=7338688, time=57.47 bytes used=213417472, alloc=7338688, time=58.53 bytes used=216174024, alloc=7993928, time=59.47 bytes used=218195768, alloc=9173360, time=60.18 bytes used=220226824, alloc=9435456, time=60.94 bytes used=222243880, alloc=9435456, time=61.70 bytes used=224265336, alloc=9566504, time=62.46 bytes used=226291712, alloc=9566504, time=63.22 bytes used=228304160, alloc=9566504, time=63.99 bytes used=230316424, alloc=9697552, time=64.77 bytes used=232335144, alloc=9697552, time=65.56 bytes used=234432136, alloc=9828600, time=66.31 bytes used=236441352, alloc=9828600, time=67.09 bytes used=238446464, alloc=9959648, time=67.84 bytes used=240448128, alloc=10090696, time=68.62 bytes used=242451864, alloc=10090696, time=69.38 bytes used=244477088, alloc=10090696, time=70.15 bytes used=246479584, alloc=10090696, time=70.92 bytes used=248483992, alloc=10090696, time=71.70 bytes used=250492544, alloc=10090696, time=72.47 bytes used=252493504, alloc=10090696, time=73.24 bytes used=254500400, alloc=10090696, time=74.00 bytes used=256520240, alloc=10090696, time=74.78 bytes used=258536376, alloc=10090696, time=75.53 bytes used=260554224, alloc=10090696, time=76.33 bytes used=262619720, alloc=10483840, time=77.18 bytes used=265046928, alloc=10876984, time=78.18 bytes used=267135376, alloc=10876984, time=79.29 bytes used=269159168, alloc=10876984, time=80.38 bytes used=271185648, alloc=10876984, time=81.13 bytes used=273313424, alloc=10876984, time=81.99 bytes used=275406848, alloc=10876984, time=82.77 bytes used=277407160, alloc=10876984, time=84.12 bytes used=279407544, alloc=10876984, time=86.04 bytes used=281407848, alloc=10876984, time=87.98 bytes used=283408256, alloc=10876984, time=89.93 bytes used=285408736, alloc=10876984, time=91.89 bytes used=287409024, alloc=10876984, time=93.84 bytes used=289409424, alloc=10876984, time=95.80 bytes used=291409712, alloc=10876984, time=97.70 bytes used=293410000, alloc=10876984, time=99.52 bytes used=295410384, alloc=10876984, time=101.36 bytes used=297410848, alloc=10876984, time=103.20 bytes used=299411320, alloc=10876984, time=105.08 bytes used=301411832, alloc=10876984, time=106.95 bytes used=303412248, alloc=10876984, time=108.80 bytes used=305413456, alloc=10876984, time=110.55 bytes used=307599808, alloc=10876984, time=111.51 bytes used=309763216, alloc=10876984, time=112.40 bytes used=311772736, alloc=10876984, time=113.24 bytes used=313790808, alloc=10876984, time=114.10 bytes used=315952928, alloc=10876984, time=114.97 bytes used=317982288, alloc=10876984, time=115.82 bytes used=319998064, alloc=10876984, time=116.66 bytes used=322290576, alloc=10876984, time=117.55 bytes used=324344192, alloc=10876984, time=118.37 bytes used=326404128, alloc=10876984, time=119.20 bytes used=328426896, alloc=10876984, time=120.00 bytes used=330522968, alloc=10876984, time=120.80 bytes used=332668536, alloc=10876984, time=121.60 bytes used=334990480, alloc=10876984, time=122.51 bytes used=337134376, alloc=10876984, time=123.33 bytes used=339853688, alloc=10876984, time=124.20 bytes used=341881552, alloc=10876984, time=125.04 bytes used=343964976, alloc=10876984, time=125.97 bytes used=345967440, alloc=10876984, time=126.78 bytes used=347967920, alloc=10876984, time=128.34 bytes used=349968280, alloc=10876984, time=130.30 bytes used=351968656, alloc=10876984, time=132.30 bytes used=353969104, alloc=10876984, time=134.27 bytes used=355969552, alloc=10876984, time=136.24 bytes used=357969992, alloc=10876984, time=138.22 bytes used=359970336, alloc=10876984, time=140.14 bytes used=361970744, alloc=10876984, time=142.03 bytes used=363971184, alloc=10876984, time=143.91 bytes used=365971992, alloc=10876984, time=145.80 bytes used=367972576, alloc=10876984, time=147.68 bytes used=369990416, alloc=10876984, time=149.19 bytes used=372089008, alloc=10876984, time=150.11 bytes used=374172912, alloc=10876984, time=150.96 bytes used=376375432, alloc=10876984, time=151.84 bytes used=378574288, alloc=10876984, time=152.70 bytes used=380738720, alloc=10876984, time=153.59 bytes used=382917168, alloc=10876984, time=154.45 bytes used=384994560, alloc=10876984, time=155.28 bytes used=387039432, alloc=10876984, time=156.07 bytes used=389047328, alloc=10876984, time=156.85 bytes used=391388600, alloc=10876984, time=157.69 bytes used=393667680, alloc=10876984, time=158.56 bytes used=395680272, alloc=10876984, time=159.33 bytes used=397688136, alloc=10876984, time=160.10 bytes used=399704200, alloc=10876984, time=160.86 bytes used=401901944, alloc=10876984, time=161.72 bytes used=404106584, alloc=10876984, time=162.58 bytes used=406125192, alloc=10876984, time=163.39 bytes used=408382568, alloc=10876984, time=164.22 bytes used=410383424, alloc=10876984, time=165.01 bytes used=412416912, alloc=10876984, time=165.79 bytes used=414432336, alloc=10876984, time=166.56 bytes used=416707072, alloc=10876984, time=167.41 bytes used=418708400, alloc=10876984, time=168.19 bytes used=420709096, alloc=10876984, time=168.95 bytes used=423368560, alloc=11008032, time=170.22 bytes used=425530656, alloc=11008032, time=171.08 bytes used=427751904, alloc=11008032, time=171.98 bytes used=429984584, alloc=11008032, time=172.87 bytes used=432229816, alloc=11008032, time=173.74 bytes used=434241336, alloc=11008032, time=174.54 bytes used=436586320, alloc=11008032, time=175.41 bytes used=438830480, alloc=11008032, time=176.28 bytes used=440832400, alloc=11008032, time=177.09 bytes used=443173144, alloc=11008032, time=177.95 bytes used=445193152, alloc=11008032, time=178.79 bytes used=447348288, alloc=11008032, time=179.66 bytes used=449548952, alloc=11008032, time=180.56 bytes used=451692272, alloc=11008032, time=181.43 bytes used=453899216, alloc=11008032, time=182.32 bytes used=455926008, alloc=11008032, time=183.15 bytes used=458226872, alloc=11008032, time=184.03 bytes used=460235744, alloc=11008032, time=184.83 bytes used=462242520, alloc=11008032, time=185.67 bytes used=464403968, alloc=11008032, time=186.55 bytes used=466557784, alloc=11008032, time=187.44 bytes used=468785408, alloc=11008032, time=188.34 bytes used=470819440, alloc=11008032, time=189.21 bytes used=473147848, alloc=11008032, time=190.09 bytes used=475158296, alloc=11008032, time=190.92 bytes used=477193248, alloc=11008032, time=191.79 bytes used=479206600, alloc=11008032, time=192.66 bytes used=481472216, alloc=11008032, time=193.52 bytes used=483479336, alloc=11008032, time=194.34 bytes used=485481760, alloc=11008032, time=195.17 bytes used=487523560, alloc=11008032, time=195.87 bytes used=489555352, alloc=11008032, time=196.42 bytes used=491592304, alloc=11008032, time=196.98 bytes used=493603480, alloc=11008032, time=197.58 bytes used=495607288, alloc=11008032, time=198.13 bytes used=497758528, alloc=11008032, time=198.82 bytes used=499798496, alloc=11008032, time=199.42 bytes used=502008496, alloc=11008032, time=200.15 bytes used=504017816, alloc=11008032, time=201.26 bytes used=506018200, alloc=11008032, time=202.26 bytes used=508018872, alloc=11008032, time=203.37 2 4 6 C[7] := -(2 n + 5) (2 n + 3) (n + 3) (2 n + 7) (n + 6) (n + 7) (80 n z 6 2 6 5 5 5 2 4 + 64 n z + 16 n + 336 n + 1680 n z + 1344 n z + 14024 z n 4 2 4 3 2 3 3 2 + 11068 n z + 2812 n + 59136 z n + 45192 z n + 11928 n + 26929 n 2 2 2 2 + 132146 z n + 95317 z n + 148470 z n + 97839 z n + 30723 n + 65892 z 2 7 2 + 37926 z + 13926) Sn - (2 n + 5) (2 n + 3) (n + 3) (2 n + 13) (n + 6) 3 2 3 3 2 2 (5805308712 z n + 4496164156 z n - 267188865 n + 7294149117 z n 3 5 2 + 4178435604 z n - 90076386 + 35742924 z + 747533139 n z 4 2 5 3 4 3 5 + 2446159284 n z + 684014160 n z + 2167153888 n z - 2810946 n z 3 7 6 5 6 + 1260508536 z - 237936 n z - 1157982 n z - 36558969 n - 7634895 n 7 2 6 2 2 - 1064208 n - 343911303 n + 153854757 n z + 1942323726 z 4 3 2 2 3 - 118027892 n - 253024934 n + 5719229619 z n + 5308699674 z n 3 8 8 2 7 2 8 + 21778944 z n - 27864 n z + 1854108 n z + 21115680 n z - 94980 n 4 8 3 7 3 6 3 + 217344 z n + 1781376 n z + 20079744 n z + 144030240 n z 2 10 9 10 2 + 74932194 z n + 61213146 z n - 112 n - 4912 n + 2112 n z 9 2 9 10 9 3 10 3 6 + 94272 n z - 1776 n z - 48 n z + 91136 n z + 2048 n z ) Sn - 3 2 3 3 (2 n + 5) (2 n + 3) (2 n + 11) (13682650948296 z n + 13511037661940 z n 2 2 3 + 85986404676 n + 7414419736502 z n + 8210026188432 z n 4 12 4 10 4 + 1002247646400 z + 966656 n z + 282250162032 z + 418210816 n z 11 4 5 2 4 2 + 25930752 n z + 2115800273987 n z + 4661946810770 n z 5 3 4 3 4 2 + 4053512450028 n z + 8838498205900 n z + 7022713614000 z n 4 3 5 4 8 + 7210521226000 z n + 483287935450 n z + 34459329792 z n 3 7 6 5 + 2200064944896 z + 38728426434 n z + 159600076920 n z + 42906452495 n 6 7 2 4 9 + 14420346306 n + 3564500133 n + 142476377942 n + 4517690624 z n 6 2 13 12 2 + 694980071674 n z + 336 n + 19392 n + 1240168995240 z 4 3 4 7 + 92611050594 n + 140759325855 n + 190570480448 z n 4 5 13 4 2 + 2284329208368 z n + 16384 n z + 4528595526708 z n 2 3 3 8 + 7214712213739 z n + 1637039252154 z n + 6914943860 n z 13 3 8 2 7 2 12 3 + 26624 n z + 29689194154 n z + 167545606625 n z + 1580032 n z 13 2 12 2 8 13 12 + 13120 n z + 783872 n z + 648860962 n + 3216 n z + 189888 n z 4 4 4 4 + 1060559347776 z n + 4862476649552 z n + 4004292023424 z n 4 6 8 3 7 3 + 771940158784 z n + 58286832432 n z + 326533490992 n z 6 3 2 + 1343604801980 n z + 1027535345112 z n + 1680767812396 z n 10 9 11 10 2 + 8079996 n + 86013981 n + 509884 n + 348550828 n z 9 2 9 10 9 3 + 3824465873 n z + 898404042 n z + 82653816 n z + 7559783776 n z 11 2 11 3 10 3 11 + 21306988 n z + 42668928 n z + 693507584 n z + 5104760 n z 5 3 2 + 23350952808) Sn + (2 n + 9) (2 n + 3) (2 n + 13) (13910092243648 z n 3 3 2 2 + 15156416516288 z n + 46053809388 n + 8311331715330 z n 3 4 12 4 + 7602320946336 z n + 807866136000 z + 2605056 n z + 231596949360 z 10 4 11 4 5 2 + 906654720 n z + 62702592 n z + 3231341124665 n z 4 2 5 3 4 3 + 6396147845746 n z + 5603671818176 n z + 10987462278952 n z 4 2 4 3 5 + 6631955306064 z n + 7461641061744 z n + 634562643130 n z 4 8 3 7 + 60008279808 z n + 1866003515040 z + 62787989214 n z 6 5 6 7 + 232646448964 n z + 33085521973 n + 12249111378 n + 3338131859 n 2 4 9 6 2 13 + 83182050706 n + 8777472768 z n + 1185181654754 n z + 560 n 12 2 4 3 + 29440 n + 1160209491000 z + 64925778266 n + 89917367765 n 4 7 4 5 13 4 + 297655968192 z n + 2884936058448 z n + 49152 n z 2 2 3 3 + 4623878113500 z n + 8926613181009 z n + 1758422210082 z n 8 13 3 8 2 7 2 + 12483737564 n z + 90112 n z + 63547672678 n z + 319814508279 n z 12 3 13 2 12 2 8 + 4782080 n z + 50368 n z + 2676224 n z + 670104558 n 13 12 4 4 4 + 9968 n z + 528640 n z + 1257462926348 z n + 5546371391664 z n 4 4 6 8 3 + 3476991692160 z n + 1082954631744 z n + 112293555296 n z 7 3 6 3 + 562342435424 n z + 2071109198296 n z + 917574777528 z n 2 10 9 11 + 1642199836716 z n + 10136540 n + 97936163 n + 704100 n 10 2 9 2 9 10 + 941280204 n z + 9191040175 n z + 1807328726 n z + 185331192 n z 9 3 11 2 11 3 + 16305338944 n z + 64691060 n z + 115392256 n z 10 3 11 4 + 1675034624 n z + 12756616 n z + 11523220920) Sn - (2 n + 7) 3 2 3 3 (2 n + 3) (2 n + 13) (8531414872896 z n + 9712518187968 z n 2 2 3 + 34497078156 n + 4859515283350 z n + 4468121065632 z n 4 12 4 10 4 + 484905960000 z + 2506752 n z + 127804460880 z + 804842496 n z 11 4 5 2 4 2 + 57984000 n z + 2207367226009 n z + 4150173636854 n z 5 3 4 3 4 2 + 3930740514624 n z + 7363953429720 n z + 4245061542960 z n 4 3 5 4 8 + 4954911455088 z n + 8428824360 + 447680623994 n z + 48974588160 z n 3 7 6 5 + 1052358864480 z + 48624025054 n z + 172031841612 n z + 27352736917 n 6 7 2 4 9 + 10382799574 n + 2900711699 n + 63836711782 n + 7473224448 z n 6 2 13 12 2 + 851895678246 n z + 560 n + 28800 n + 610197447720 z 4 3 4 7 + 52351911278 n + 70724042517 n + 232808309184 z n 4 5 13 4 2 + 2074421627472 z n + 49152 n z + 2564826281340 z n 2 3 3 8 + 5499248038545 z n + 1126781871522 z n + 10115487316 n z 13 3 8 2 7 2 12 3 + 90112 n z + 50463545810 n z + 241721896055 n z + 4589568 n z 13 2 12 2 8 13 12 + 50368 n z + 2562048 n z + 596796138 n + 9968 n z + 508032 n z 4 4 4 4 + 845762274820 z n + 3829409246160 z n + 2151373929600 z n 4 6 8 3 7 3 + 811887892416 z n + 90406827424 n z + 432470082144 n z 6 3 2 + 1521125868328 n z + 532621021560 z n + 1001893454084 z n 10 9 11 10 2 + 9471620 n + 89361763 n + 673380 n + 822649876 n z 9 2 9 10 9 3 + 7661023215 n z + 1530795606 n z + 163909832 n z + 13735426624 n z 11 2 11 3 10 3 11 + 59210612 n z + 106151680 n z + 1475258368 n z + 11767432 n z) 3 3 2 Sn + (2 n + 5) (2 n + 13) (2 n + 11) (369397670424 z n 3 3 2 2 + 519696090996 z n + 4434266916 n + 125422522194 z n 3 4 12 4 + 155812968720 z n + 19845000000 z + 737280 n z + 3989481552 z 10 4 11 4 5 2 + 179682304 n z + 14920704 n z + 133451236003 n z 4 2 5 3 4 3 + 194504508774 n z + 315665832108 n z + 484252867348 n z 4 2 4 3 5 + 244498146000 z n + 341168970000 z n + 41624849882 n z 4 8 3 7 6 + 8035664640 z n + 29438640000 z + 6507045058 n z + 19278024184 n z 5 6 7 2 + 6182227951 n + 2689603670 n + 858452261 n + 9462409362 n 4 9 6 2 13 12 + 1435778304 z n + 65065622078 n z + 336 n + 15552 n 2 4 3 4 7 + 6911840376 z + 10297384054 n + 12083336671 n + 32398803776 z n 4 5 13 4 2 + 204293021232 z n + 16384 n z + 45826603284 z n 2 3 3 8 13 3 + 194646861355 z n + 70073637818 z n + 1602053980 n z + 26624 n z 8 2 7 2 12 3 13 2 + 5846250782 n z + 22915448929 n z + 1188864 n z + 13120 n z 12 2 8 13 12 + 580608 n z + 201021446 n + 3216 n z + 144576 n z 4 4 4 4 + 64633238480 z n + 315535254320 z n + 104050800000 z n 4 6 8 3 7 3 + 95267825856 z n + 12638717904 n z + 50670026032 n z 6 3 2 10 + 148124954820 n z + 21208829592 z n + 50161182276 z n + 4079140 n 9 11 10 2 9 2 + 34114141 n + 325564 n + 136576628 n z + 1069412113 n z 9 10 9 3 11 2 + 284375882 n z + 35403464 n z + 2271110496 n z + 11550316 n z 11 3 10 3 11 2 + 23892864 n z + 285908480 n z + 2929784 n z + 939708216) Sn + 2 3 2 (2 n + 11) (2 n + 3) (n + 5) (2 n + 13) (n + 2) (723291528 z n 3 3 2 2 3 + 733073092 z n - 35950959 n + 807453069 z n + 404481900 z n 5 2 4 2 5 3 - 16917444 z + 205519773 n z + 501150588 n z + 194382768 n z 4 3 5 3 7 + 466223200 n z - 11678046 n z + 97335000 z - 9631386 - 402576 n z 6 5 6 7 2 - 2671326 n z - 12667479 n - 3326031 n - 578544 n - 58553847 n 6 2 2 4 3 + 56145957 n z + 112682934 z - 32345036 n - 54664538 n 2 2 3 3 8 + 460142493 z n + 802740966 z n - 65617152 z n - 38232 n z 8 2 7 2 8 4 + 1149084 n z + 10105824 n z - 63876 n - 34080048 z n 8 3 7 3 6 3 + 1117824 n z + 9780096 n z + 53820960 n z - 55681602 z n 2 10 9 10 2 9 2 - 79896102 z n - 112 n - 4048 n + 2112 n z + 74688 n z 9 10 9 3 10 3 - 2064 n z - 48 n z + 72704 n z + 2048 n z ) Sn + (n + 5) 2 4 6 6 2 (2 n + 13) (2 n + 11) (2 n + 9) (n + 2) (n + 1) (80 n z + 64 n z 6 5 5 5 2 4 4 2 + 16 n + 432 n + 2160 n z + 1728 n z + 23624 z n + 18748 n z 4 3 2 3 3 2 2 + 4732 n + 133632 z n + 104184 z n + 26856 n + 83185 n + 411698 z n 2 2 2 + 311701 z n + 655146 z n + 475425 z n + 133389 n + 421428 z 2 + 288750 z + 86670) # (This needs several minutes.) # Improved method that returns an operator of order 3. > GCD:=subs(n=n+1,skew_gcdex(subs(n=n-1,Q2),M,Dz,A)): bytes used=510020088, alloc=11008032, time=204.34 > U:=collect(GCD[2],Dz,factor); 3 3 2 2 U := 4 z (z + 1) Dz + 3 z (z n + 9 z + n + 5) Dz 2 2 2 3 - z (-9 - 31 z + 3 z n + 6 z n - 7 n - 2 n ) Dz + 3 n + 3 n + n + 1 2 3 - 4 z - 24 z n - 21 z n - 5 z n > factor(GCD[1]); 5 (n + 1) # We reduce U&*P/GCD[1] modulo M. > PR:=collect(skew_product(U,P2,A),Dz,factor): > PDIV:=skew_pdiv(PR,M,Dz,A): # Therefore, H=Sn is > R:=collect(PDIV[3]/PDIV[1]/GCD[1],Dz,factor); 3 3 2 2 z (z + 1) Dz z (2 z n + 2 n + 11 + 14 z) Dz R := 12 -------------- + 4 -------------------------------- 3 3 (n + 1) (n + 1) 2 2 z (-n + 5 z n - 4 n + 2 z n - 9 z - 6) Dz -n + 16 z n - 1 + 4 z - 4 ------------------------------------------- - --------------------- 3 n + 1 (n + 1) # (Fraction-free) Gaussian elimination: > T[1]:=[1,1]: > T[Sn]:=[numer(R),denom(R)]: > T[Sn^2]:=[skew_product(subs(n=n+1,"[1]),numer(R),A),subs(n=n+1,"[2])*denom(R)]: > T[Sn^3]:=[skew_product(subs(n=n+1,"[1]),numer(R),A),subs(n=n+1,"[2])*denom(R)]: bytes used=512067376, alloc=11008032, time=205.23 > T[Sn^4]:=[skew_product(subs(n=n+1,"[1]),numer(R),A),subs(n=n+1,"[2])*denom(R)]: > skew_pdiv(T[Sn^2][1],M,Dz,A): bytes used=514071552, alloc=11008032, time=205.87 > T[Sn^2]:=["[3],T[Sn^2][2]*"[1]]: > skew_pdiv(T[Sn^3][1],M,Dz,A): bytes used=516158280, alloc=11008032, time=206.64 > T[Sn^3]:=["[3],T[Sn^3][2]*"[1]]: > skew_pdiv(T[Sn^4][1],M,Dz,A): bytes used=518177776, alloc=11008032, time=207.37 bytes used=520213824, alloc=11008032, time=208.05 bytes used=522223488, alloc=11008032, time=208.75 bytes used=524283112, alloc=11008032, time=209.43 > T[Sn^4]:=["[3],T[Sn^4][2]*"[1]]: > Z:=collect(add(eta[i]*T[Sn^i][1]/T[Sn^i][2],i=0..4),Dz,numer@normal): > SOL:=solve({coeffs(Z,Dz)},{seq(eta[i],i=0..4)}): bytes used=526922504, alloc=11008032, time=210.19 bytes used=528922792, alloc=11008032, time=211.84 bytes used=530926000, alloc=11008032, time=212.80 bytes used=533848112, alloc=11008032, time=213.68 bytes used=542407712, alloc=13497944, time=215.90 # The contiguity relation of order 4 is: > C[4]:=collect(primpart(subs(SOL,add(eta[i]*Sn^i,i=0..4)),Sn),Sn,factor); bytes used=544408192, alloc=13497944, time=217.01 C[4] := 3 2 2 4 (n + 3) (2 n + 3) (n + 4) (16 z n + 4 n + 64 z n + 16 n + 63 z + 15) Sn 4 4 2 4 2 3 + (2 n + 3) (n + 3) (2 n + 7) (32 z n + 256 n z - 8 n + 2816 z n 3 3 2 2 2 2 - 88 n + 352 z n - 350 n + 1418 z n + 11344 z n + 2445 z n - 591 n 2 2 3 3 2 + 19752 z n + 12516 z - 354 + 1482 z) Sn + (2 n + 5) (2162304 z n 3 3 2 2 3 + 1216000 z n + 10735 n + 2141280 z n + 2011520 z n + 151522 z 5 2 4 2 5 3 4 3 5 + 61440 n z + 377024 n z + 61440 n z + 377600 n z + 12960 n z 3 6 5 6 2 6 2 + 764400 z + 864 n z + 360 n + 24 n + 11997 n + 4096 n z 2 4 3 2 2 3 + 745500 z + 2194 n + 6940 n + 1978400 z n + 1210240 z n 3 4 6 3 2 + 253540 z n + 79354 z n + 4096 n z + 407275 z n + 445305 z n + 3886) 2 4 4 4 2 3 Sn + (2 n + 3) (n + 2) (2 n + 7) (32 z n - 8 n + 256 n z + 288 z n 2 3 3 2 2 2 2 2 + 2304 z n - 72 n + 7504 z n + 938 z n - 230 n + 10488 z n - 309 n 2 + 1335 z n - 149 + 5356 z + 707 z) Sn 3 2 2 + (2 n + 7) (n + 2) (n + 1) (16 z n + 4 n + 24 n + 96 z n + 143 z + 35) > # Section 1.4.4 Sylvester's dialytic elimination > A:=shift_algebra([Sn,n],[Sm,m],[comm,alpha],[comm,x],polynom=m): > (-1)^m*GAMMA(alpha+n-m)/m!/(n-2*m)!*(2*x)^(n-2*m): > numer(normal([Sn-subs(n=n+1,")/",Sm-subs(m=m+1,")/"],expanded)): > skew_elim(op("),m,A); 2 2 2 x Sn Sm n + 2 x Sm Sn + 2 x Sn alpha Sm - n - Sn Sm n - 2 Sm Sn - 2 alpha > map(collect,series(",Sm=1),Sn,factor); 2 ((-n - 2) Sn + 2 x (n + alpha + 1) Sn - n - 2 alpha) + 2 ((-n - 2) Sn + 2 x (n + alpha + 1) Sn) (Sm - 1) > # Section 1.5. First example (Jacobi polynomials) > A:=skew_algebra(comm=[a,b],shift=[Sn,n],diff=[Dx,x]): > G:=[2*(n+2)*(n+a+b+2)*(2*n+a+b+2)*Sn^2 > -((2*n+a+b+3)*(a^2-b^2)+(2*n+a+b+2) > *(2*n+a+b+3)*(2*n+a+b+4)*x)*Sn > +2*(n+a+1)*(n+b+1)*(2*n+a+b+4), > (2*n+a+b+2)*(1-x^2)*Dx*Sn-(n+1) > *(a-b-(2*n+a+b+2)*x)*Sn-2*(n+a+1)*(n+b+1)]: > T:=termorder(A,plex(Sn,Dx)): > remove(has,gbasis(G,T),Sn); bytes used=546408584, alloc=13497944, time=218.00 bytes used=548438184, alloc=13497944, time=219.00 bytes used=550452656, alloc=13497944, time=219.78 bytes used=552469688, alloc=13497944, time=220.60 2 2 2 2 [Dx x + Dx a x + 2 Dx x + Dx b x + Dx a - n a - n - n b - Dx - Dx b - n ] > # Section 2.2.2. Example of addition of partial finite functions # The methods by rectangular systems or by the FGLM algorithm are not # directly available in Mgfun2.0, so that they are not demonstrated. # The method by intersection of ideals is as follows. > A:=diff_algebra([Dx,x],[Dy,y],[comm,mu],[comm,nu],[comm,t],polynom=t): > T:=termorder(A,lexdeg([t],[Dx,Dy])): > G:=[t*(Dx-mu),t*(Dy-nu),(1-t)*(x^2*Dx^2+x*Dx+x^2-mu^2), > (1-t)*(y^2*Dy^2+y*Dy+y^2-nu^2)]; 2 2 2 2 G := [t (Dx - mu), t (Dy - nu), (1 - t) (Dx x + Dx x + x - mu ), 2 2 2 2 (1 - t) (y Dy + y Dy + y - nu )] > GB:=gbasis(G,T): bytes used=554470048, alloc=13497944, time=221.62 bytes used=556470896, alloc=13497944, time=222.55 > collect(remove(has,GB,t),{Dx,Dy},distributed,factor); bytes used=558471272, alloc=13497944, time=223.44 2 2 2 2 2 2 2 2 2 2 2 2 2 [y nu x - y nu mu + y nu x - x y mu + x nu mu - x mu y - y nu mu 2 2 2 2 2 2 2 + x mu nu + x (y - nu + y nu + y nu) Dx 2 2 2 2 2 2 2 2 2 2 - y (x mu + x mu + x - mu ) Dy - y (x mu + x mu + x - mu ) Dy 2 2 2 2 2 2 + x (y - nu + y nu + y nu) Dx , 2 2 2 2 4 3 4 2 3 4 4 2 -nu (-y - 2 y nu - nu + nu + y nu - nu y - 3 y nu + y + y nu ) 2 2 4 4 2 4 2 4 2 2 3 3 + (-y - nu + y - nu y + y nu + nu - 4 y nu - y nu ) Dy 2 2 3 3 3 3 2 - y (-y - 2 y nu + 3 nu + y nu + y nu - y nu ) Dy 2 2 2 2 2 3 + y (y - nu + y nu + y nu) Dy , -mu (y - nu) (y + nu) 2 2 2 2 + (y - nu) (y + nu) Dx + Dx y Dy - mu y Dy - mu y Dy + Dx y Dy ] > # Section 3.2. Example of creative telescoping by Groebner bases > A:=skew_algebra(comm=[a,b],shift=[Sn,n],diff=[Dx,x],diff=[Dy,y],polynom=n): > G:=[2*(n+2)*(n+a+b+2)*(2*n+a+b+2)*Sn^2 > -y*(2*n+a+b+3)*(a^2-b^2+4*x*n^2+4*x*n*a+4*x*n*b > +12*x*n+x*a^2+2*x*a*b+6*x*a+x*b^2+6*x*b+8*x)*Sn > +2*(n+a+1)*(n+b+1)*(2*n+a+b+4)*y^2, > -2*(n+a+1)*(n+b+1)*y+(n+1)*(-a+b+2*x*n+x*a+x*b+2*x)*Sn > -(x-1)*(x+1)*(2*n+a+b+2)*Dx*Sn, > n*(n+a+b+1)+(b-a-x*a-x*b-2*x)*Dx-(x-1)*(x+1)*Dx^2, > y*Dy-n]: > T:=termorder(A,lexdeg([n],[Sn,Dx,Dy])): > GB:=gbasis(G,T): bytes used=560476240, alloc=13497944, time=224.49 bytes used=562487936, alloc=13497944, time=225.50 bytes used=564488432, alloc=13497944, time=226.40 bytes used=566492168, alloc=13497944, time=227.25 bytes used=568502800, alloc=13497944, time=228.18 bytes used=570513168, alloc=13497944, time=229.16 bytes used=572532800, alloc=13497944, time=230.14 bytes used=574537744, alloc=13497944, time=230.98 > CT:=collect(subs(Sn=1,remove(has,GB,n)),[Dx,Dy],distributed,factor); 2 CT := [(-b + a + x a + x b + 2 x) Dx - y (a + b + 2) Dy + (x - 1) (x + 1) Dx 2 2 - y Dy , 2 y (b + 1) (1 + a) + (x - 1) (x + 1) (a + b) Dx - y (-2 y a - 2 y b - 6 y + x b + 2 x - a + b + x a) Dy 2 2 - 2 y (-y + x) Dy + 2 y (x - 1) (x + 1) Dy Dx, 2 2 2 2 y (x a + x a + a + a - x b - x b + b + b) + (x - 1) (x + 1) (b - y b + y a + a) Dx + y (x a y + y a + y b - x b y + b - a - x b - x a) Dy, -2 y (b + 1) (1 + a) (2 x a + a - b + 2 x b + 2 x) 2 2 - (x - 1) (x + 1) (b - a + 4 y b + 4 y a b + 4 y a + 4 y) Dx - y (28 x y 2 2 + 24 x b y - 2 b y - 6 y b + 24 x a y + 12 x y a b + 4 x b y + 6 y a 2 2 2 2 2 2 + 4 x a y + 2 a y - 6 a - b - 6 b - 4 - a + x a - 6 a b - x b ) Dy 3 2 3 3 - 4 y (x - 1) (x + 1) Dy Dx - 4 y (x y - 1) Dy 2 2 - 2 y (y a + 4 x a y - y b + 4 x b y + 12 x y - 3 b - 6 - 3 a) Dy 2 - 4 y (x - 1) (x + 1) (b + 3 + a) Dy Dx, -2 x + 2 y - a - 3 x a + b 2 2 2 2 - 2 x a b + b - x b - x a + 2 y a b + 2 y a - a - 3 x b + 2 y b - 2 (x - 1) (x + 1) Dx 2 2 2 + (2 a + 6 y + 2 b + 2 y b + 2 y a - 4 x a y + 2 - 4 x b y - 8 x y) Dy 2 2 - 2 y (-y + 2 x y - 1) Dy ] > R:=sqrt(1-2*x*y+y^2): P:=1/(R*(1-y+R)^a*(1+y+R)^b): > map(simplify,map(applyopr,CT,P,A)); bytes used=576538120, alloc=13497944, time=232.13 bytes used=578619896, alloc=13497944, time=232.98 bytes used=580620248, alloc=13497944, time=233.81 bytes used=582853872, alloc=13497944, time=234.82 bytes used=585616064, alloc=13497944, time=235.92 bytes used=587638352, alloc=13497944, time=236.79 bytes used=589638968, alloc=13497944, time=237.98 bytes used=591639344, alloc=13497944, time=239.26 bytes used=593650640, alloc=13497944, time=240.07 bytes used=596805088, alloc=13497944, time=241.11 bytes used=598812472, alloc=13497944, time=241.92 bytes used=600836080, alloc=13497944, time=242.75 bytes used=602846008, alloc=13497944, time=243.63 bytes used=604893680, alloc=13497944, time=244.59 bytes used=606913160, alloc=13497944, time=245.55 bytes used=609023560, alloc=13497944, time=246.55 bytes used=611122064, alloc=13497944, time=247.57 bytes used=614159328, alloc=13891088, time=248.85 bytes used=616166000, alloc=13891088, time=249.78 bytes used=618238400, alloc=13891088, time=250.60 bytes used=620255136, alloc=13891088, time=251.45 bytes used=622267464, alloc=13891088, time=252.32 bytes used=624286896, alloc=13891088, time=253.33 bytes used=626293176, alloc=13891088, time=254.25 bytes used=628315400, alloc=13891088, time=255.29 bytes used=630533128, alloc=13891088, time=256.40 bytes used=633052104, alloc=14546328, time=257.65 bytes used=635690432, alloc=14546328, time=258.93 bytes used=637782856, alloc=14546328, time=260.01 bytes used=650517296, alloc=18346720, time=264.70 bytes used=653549600, alloc=20574536, time=266.50 bytes used=658585512, alloc=24374928, time=269.46 bytes used=660595864, alloc=24374928, time=270.77 bytes used=662677480, alloc=24374928, time=271.59 [0, 0, 0, 0, 0] > # The functions hdefsum, hdefqsum and hdefint have not been # reimplemented in version 2.0, and the examples of the following # sections are not demonstrated here. # Section 3.3. Extension of Takayama's algorithm for definite integral # Section 3.4.1. An identity between Franel and Apery numbers # Section 3.4.2. A Rogers-Ramanujan identity > quit bytes used=663019440, alloc=24374928, time=271.73