{VERSION 3 0 "IBM INTEL NT" "3.0" } {USTYLETAB {CSTYLE "Maple Input" -1 0 "Courier" 0 1 255 0 0 1 0 1 0 0 1 0 0 0 0 }{CSTYLE "" -1 23 "Courier" 1 10 0 0 0 0 0 0 0 0 0 0 3 0 0 } {PSTYLE "Normal" -1 0 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 }0 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }} {SECT 0 {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 " > " 0 "" {MPLTEXT 1 0 500 "ez:=proc( )local arglist,s,a,b,k,i,j,S,al,r ,res:arglist:=[args]:s:=map( x -> abs(x) , arglist):a:=map( x -> signu m(x) , arglist):k:=nops(arglist):S:=add(s[j],j=1..k):b:=array(1..k):fo r j to k do b[j]:=product(a[i],i=1..j):od:al:=array(1..S):for j to S d o al[j]:=0:od:for j to k do r:=add( s[i], i=1..j): al[r]:=b[j]:od:res: =(-1)^k * Iz( seq(al[i],i=1..S) )+(-1)^(k+S) * Iz( seq(1-al[S+1-i],i=1 ..S) )+ add( (-1)^(r+k) * Iz( seq(1-al[r+1-i],i=1..r) ) * Iz( seq(al[r +i],i=1..S-r) ),r=1 .. S-1 ):res:end:" }}{PARA 0 "" 0 "" {TEXT 23 0 " " }}{PARA 0 "> " 0 "" {MPLTEXT 1 0 488 "Iz:=proc( )local p,n,d,t,c,j, m,r,N1,res:n:=nargs:p:=[args]:j:=0:for r to n do if(p[r]<>0) then j:=j +1: fi:od:m:=j:d:=array(1..m):t:=array(1..m):c:=array(1..m):j:=1:t[1]: =1:for r to n do if(p[r]<>0) then d[j]:=p[r]:if(j=1)then c[1]:=2*d[ 1]: else c[j]:=d[j]/d[j-1]: fi:if(r " 0 "" {MPLTEXT 1 0 308 "Isum:=proc( t:: list(integer), c::list(rational), imax::integer)local l,j,res,nk:if(no ps(t)=1) then res:= add( evalf(1/(nk^t[1]*c[1]^nk)) ,nk=1..imax)else r es:=0:l:=nops(t):for nk from l to imax do res:=res + evalf(1/(nk^t[1]* c[1]^nk))* Isum( [ seq(t[j],j=2..l) ], [ seq(c[j],j=2..l) ], nk-1 ): o d:fi:res:end:" }{TEXT 23 0 "" }}{PARA 0 "" 0 "" {TEXT 23 0 "" }}{PARA 0 "" 0 "" {TEXT 23 13 "# An example:" }}{PARA 0 "" 0 "" {TEXT 23 0 "" }}{PARA 0 "> " 0 "" {MPLTEXT 1 0 62 "for Digits from 5 to 15 by 5 do p rint( ez(2,1)/ez(-2,1) ); od;" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 532 "`evalf/abz` := proc(p::nume ric,a::list,b::list) local dig,os,j,s,i,n,S,c,t,z; dig := Digits; Digi ts := Digits + length(Digits+9)+4; c := 2; n := nops(a); if nops(b)<>n then ERROR(`lists must have the same number of elements`); fi; z := 1 ; os := -1.; if b=[] or \{op(b)\}=\{0\} then S := .5 else S := 0; fi; \+ for j to n do s[j] := 0 od; for i while os<>S do os := S; t := 1.; \+ for j to n do s[j] := s[j] + 1./i^a[j]; t := t*s[j]^b[j]; od; c \+ := iquo((4*i+2)*c,i+1); z := -z; S := S+z*t/c/(i+1)^p; od; Digits := dig; evalf(S);end:" }}{PARA 0 "> " 0 "" {MPLTEXT 1 0 505 "`evalf/bz` \+ := proc(p::numeric,a::list,b::list) local dig,os,j,s,i,n,S,c,t; dig := Digits;Digits := Digits + length(Digits+9)+4;c := 2; n := nops(a); if nops(b)<>n then ERROR(`lists must have the same number of elements`); fi; os := -1.; if b=[] or \{op(b)\}=\{0\} then S := .5 else S := 0; f i; for j to n do s[j] := 0 od; for i while os<>S do os := S; t := 1. ; for j to n do s[j] := s[j] + 1./i^a[j]; t := t*s[j]^b[j]; od; c := iquo((4*i+2)*c,i+1); S := S+t/c/(i+1)^p; od; Digits := dig; evalf (S);end:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 63 "#savelib('ez',' Iz','Isum','`evalf/bz`','`evalf/abz`','`ez.m`');" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 32 "lin_dep([abz(3,[],[]),Zeta(3)]);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 12 "readlib(ez);" }}}{EXCHG {PARA 0 "> \+ " 0 "" {MPLTEXT 1 0 8 "ez(2,1);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}}{MARK "1 0 0" 213 }{VIEWOPTS 1 1 0 3 4 1802 }