{VERSION 6 0 "IBM INTEL NT" "6.0" } {USTYLETAB {CSTYLE "Maple Input" -1 0 "Courier" 0 1 255 0 0 1 0 1 0 0 1 0 0 0 0 1 }{CSTYLE "2D Math" -1 2 "Times" 0 1 0 0 0 0 0 0 2 0 0 0 0 0 0 1 }{CSTYLE "2D Output" 2 20 "" 0 1 0 0 255 1 0 0 0 0 0 0 0 0 0 1 } {CSTYLE "" -1 256 "fixed" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 257 "" 1 14 0 0 0 0 0 1 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 258 "" 0 1 0 0 0 0 0 2 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 259 "" 1 14 0 0 0 0 0 2 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 260 "" 1 14 0 0 0 0 0 0 0 0 0 0 0 0 0 0 } {CSTYLE "" -1 261 "fixed" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 262 "Times" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 263 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 264 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 265 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 266 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 267 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 268 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 269 "fixed" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 270 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 } {PSTYLE "Normal" -1 0 1 {CSTYLE "" -1 -1 "Times" 1 12 0 0 0 1 2 2 2 2 2 2 1 1 1 1 }1 1 0 0 0 0 1 0 1 0 2 2 0 1 }{PSTYLE "Text Output" -1 2 1 {CSTYLE "" -1 -1 "Courier" 1 10 0 0 255 1 0 0 0 0 0 1 3 0 3 0 }1 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 2 6 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 2 0 0 0 }0 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "Maple Output" -1 11 1 {CSTYLE "" -1 -1 "Times" 1 12 0 0 0 1 2 2 2 2 2 2 1 1 1 1 }3 3 0 0 0 0 1 0 1 0 2 2 0 1 }{PSTYLE "" 11 12 1 {CSTYLE " " -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 }1 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "List Item" 0 14 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 }0 0 0 -1 3 3 0 0 0 0 0 0 14 5 }{PSTYLE "Title" -1 18 1 {CSTYLE "" -1 -1 "Times" 1 18 0 0 0 1 2 1 1 2 2 2 1 1 1 1 }3 1 0 0 12 12 1 0 1 0 2 2 19 1 }{PSTYLE "Author" -1 19 1 {CSTYLE "" -1 -1 "T imes" 1 12 0 0 0 1 2 2 2 2 2 2 1 1 1 1 }3 1 0 0 8 8 1 0 1 0 2 2 0 1 } } {SECT 0 {EXCHG {PARA 18 "" 0 "" {TEXT -1 3 "Bug" }{TEXT 258 0 "" } {TEXT 259 0 "" }{TEXT -1 39 " fix and Extension of Define in Maple 9" }}{PARA 19 "" 0 "" {TEXT -1 162 "Copyright (c) Oct-23-2001 -- 2004 by \+ Rafal Ablamowicz and Bertfried Fauser. All rights reserved.\nCreated u sing Patcher of Carl deVore and Helmut Kahovec, thanks!\n" }}{PARA 0 " > " 0 "" {MPLTEXT 1 0 1092 "########################################## ###################################\n# \+ #\n#DISCLAIMER: \+ #\n# \+ #\n#THERE IS NO WARRANTY FOR THE CLIFFORD, BIGEBRA, Cliplus, Octonion, GTP \+ #\n#PACKAGES TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OT HERWISE #\n#STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PART IES PROVIDE THE #\n#PROGRAM \"AS IS\" WITHOUT WARRANTY OF ANY KIND, \+ EITHER EXPRESSED OR IMPLIED, #\n#INCLUDING, BUT NOT LIMITED TO, THE IM PLIED WARRANTIES OF MERCHANTABILITY #\n#AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY #\n#AND PERFORMANCE OF \+ THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE #\n#DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR #\n#C ORRECTION. \+ #\n############################################################### ##############\n" }{TEXT -1 1 " " }}{PARA 0 "" 0 "" {TEXT -1 0 "" } {TEXT 263 14 "Document info:" }}{PARA 14 "" 0 "" {TEXT -1 40 "spell-ch ecked (with Maple 8): 2002-10-09" }}{PARA 14 "" 0 "" {TEXT -1 20 "vers ion: 1.00-stable" }}{PARA 14 "" 0 "" {TEXT -1 31 "filename: Define_co de.1.00.mws" }}{PARA 14 "" 0 "" {TEXT -1 58 "Maple versions supported: Should run on Maple 6, 7, 8, 9 " }}{PARA 14 "" 0 "" {TEXT -1 37 "plt forms: should run on all platforms" }}{PARA 14 "" 0 "" {TEXT -1 34 "UR L: http://math.tntech.edu/rafal/" }}{PARA 14 "" 0 "" {TEXT -1 21 "file type: libary file" }}{PARA 14 "" 0 "" {TEXT -1 12 "notes: set " } {TEXT 264 7 "libname" }{TEXT -1 25 " to a suitable value. In " }{TEXT 265 10 "libname[1]" }{TEXT -1 129 " there should be a path to a local \+ libary (not Maple's libary) where the new define can be stored. It mig ht be convenient to set " }{TEXT 266 7 "libname" }{TEXT -1 29 " during startup either in an " }{TEXT 268 10 ".mapleinit" }{TEXT -1 6 " or a \+ " }{TEXT 267 9 "maple.ini" }{TEXT -1 73 " (M$ Win platforms) or even \+ in the stratup script under unix as follows:" }}{PARA 14 "" 0 "" {TEXT -1 1 " " }{TEXT 269 307 "-- .mapleinit\n libname := //Cliffordlib,libname: \n-- maple.ini\n libname := / /Cliffordlib,libname:\n-- stratupscript, see //bin/maple, \+ \n change\n -> $\{Maple_Path\}/maple \n to\n -> $ \{Maple_Path\}/maple -b $\{Maple_Path\}/Cliffordlib -b $\{Maple_path\} /lib" }}{PARA 14 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 7 "We use " }{TEXT 257 11 "libname[1] " }{TEXT 260 0 "" } {TEXT -1 132 "to save the module Define and the wrapper functions defi ne and definemore, change either the code below or set libname[1] corr ectly." }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 8 "restart:" }}{PARA 0 "" 0 "" {TEXT -1 108 "The following code is based on the define code of Maple (R) versions 6 and 7. The structure is as follows:\n\n" } {TEXT 256 600 "--Define (The main module)\n exports: define, \+ # Patched code\n definemore # unaltered code \+ of Maple(R)\n locals: canonic, # Patched code\n \+ define/diff, # unaltered code of Maple(R)\n skele ton, # Patched code\n mlinear, # Patched c ode\n DefineTable, # unaltered code of Maple(R)\n \+ DefaultNameProps # unaltered code of Maple(R)\n--define \+ # a constructor method to make define globally available\n--definemor e # a constructor method to make definemore globally available \n" } {MPLTEXT 1 0 2 "\n\n" }}{PARA 0 "> " 0 "" {MPLTEXT 1 0 7560 "unprotect (Define);\nmodule Define() \n local canonic, `define/diff`, skeleton, mlinear, DefineTable, DefaultNameProps; \n export define, definemor e; \n option package, \n `Copyright (C) 1999 Waterloo Maple, I nc. All rights reserved. Patched Oct-23-2001 BF.`; \n description \"P atched (Oct-23-2001 BF.) module implementing the define and definemore routines\"; \n\n define := proc (functionname::name) \n local pro perties, prop, eprops, nprops, i; \n option `Copyright (c) 1999 Wat erloo Maple Inc. All rights reserved.`; \n\n if assigned(function name) then \n error \"%1 is assigned\", functionname \n elif t ype(functionname,'protected') then \n error \"%1 is protected\", \+ functionname \n end if; \n if member(convert('linear','`global`' ),[args[2 .. -1]]) and member(convert('multilinear','`global`'),[args[ 2 .. -1]]) then\n error \"linear and multilinear are mutually exc lusive\" \n end if; \n DefineTable[functionname] := ''args''; \n eprops, nprops := selectremove(type,[args[2 .. -1]],'\{specfunc(an ything,conditional), `=`\}');\n ##\n ## ==> restore default if n o domain is given by the user! \n ## \n if not member('domain',c onvert(map(lhs,eprops),set)) then\n userinfo(1,Bigebra,`define ca n have a user specified domain k for k-tensor products`,\n \+ lprint(`use option: 'domain'=''`));\n eprops:=[op( eprops),`domain`=`constant`];\n end if;\n ##\n eprops := map2 (canonic,functionname,eprops);\n nprops := [op(map2(canonic,functio nname,nprops)), op(DefaultNameProps)];\n if eprops = [] then \n \+ functionname := subs([op(nprops), ('_HASATABLE') = false, ('_TABLE') = eprops],eval(skeleton)) \n else \n eprops := compiletable(e props); \n functionname := subs([op(nprops), ('_HASATABLE') = tru e, ('_TABLE') = eprops],eval(skeleton)) \n end if;\n userinfo(3, Bigebra,`New operator`,functionname,`defined`); \n NULL \n end pr oc:\n\n definemore := proc () \n local fname; \n option `Copyri ght (c) 1999 Waterloo Maple Inc. All rights reserved.`; \n descript ion \"add to the definition of a function\"; \n\n if not type(args[ 1],'name') then \n error \"first argument is not a name\" \n e nd if; \n fname := args[1]; \n if not assigned(DefineTable[fname ]) then \n error \"nothing known about %1\", fname \n end if; \+ \n unassign(args[1]); \n define(DefineTable[fname],args[2 .. -1] );\n userinfo(3,Bigebra,`Property added sucessfully to`,fname); \n NULL \n end proc:\n\n\n canonic := proc (fname, prop)\n optio n `Copyright (c) 1999 Waterloo Maple Inc. All rights reserved. Patched Oct-23-2001 BF.`; \n\n if type(prop,'`=`') then\n ##\n ## \+ ==> new option 'domain' added\n ## domain replaces 'constant' i n all procedures\n ## involved in define and allows it to defin e\n ## e.g. tensor products over arbitrary 'rings'\n ##\n \+ ## a new global type `type/domain` is created\n ## \n if lhs(prop) = ('`domain`') then \n convert(`type/domain`,'`glo bal`');\n assign(`type/domain`,proc(_var) type(_var,rhs(prop)) \+ end proc):\n userinfo(3,Bigebra,`New global type created as typ e/domain:`,print(`type/domain`));\n elif member(lhs(prop),\{_LINE AR, _MLINEAR, _ORDERLESS, _FLAT\}) then\n ; \n elif lhs(p rop) = ('inverse') then \n fname(rhs(prop)(('`/X`')::anything)) = ('`/X`'), rhs(prop)(fname(('`/X`')::anything)) = ('`/X`') \n e lif lhs(prop) = ('zero') then \n fname(rhs(prop)) = 0 \n e lif lhs(prop) = ('identity') then \n fname(('`/X`')::anything,r hs(prop)) = ('`/X`'), fname(rhs(prop),('`/X`')::anything) = ('`/X`') \+ \n elif type(lhs(prop),'function') and op(0,lhs(prop)) = ('diff') then `define/diff`(prop) \n else \n if has(lhs(prop),fnam e) then \n lhs(prop) = subs(fname = `/FUNCNAME`,rhs(prop)) \n else \n error \"left hand side of equational property `%1' does not contain function name %2\", prop, fname \n end i f \n end if \n elif type(prop,'specfunc(anything,conditional)' ) then \n ('conditional')(op([1, 1],prop) = subs(fname = `/FUNCNA ME`,op([1, 2],prop)),op(2,prop)) \n elif member(prop,\{'flat', 'ass ociative'\}) then \n ('_FLAT') = true \n elif member(prop,\{'o rderless', 'commutative'\}) then \n ('_ORDERLESS') = true \n e lif prop = convert('linear','`global`') then \n ('_LINEAR') = tru e \n elif prop = convert('multilinear','`global`') then \n ('_ MLINEAR') = true\n else \n error \"unrecognised property\" \n \+ end if \n end proc:\n\n\n `define/diff`:=proc (In::equation) \n \+ local func, rt; \n option `Copyright (c) 1999 Waterloo Maple Inc. \+ All rights reserved.`; \n\n func := cat(`diff/`,op(0,op(1,lhs(In))) ); \n unprotect(diff); \n rt := op(4,eval(diff)); \n rt[op(lh s(In))] := evaln(rt[op(lhs(In))]); \n protect(diff); \n assign(f unc,proc (expr, var) subs(op(2,lhs(In)) = expr,rhs(In))*diff(expr,var) end proc); \n NULL \n end proc:\n\n skeleton := proc () \n lo cal theArgs, arg, look, me, cf, term; \n option `Copyright (c) 1999 Waterloo Maple Inc. All rights reserved. Patched Oct-23-2001 BF.`; \n description \"a Patched (Oct-23-2001, BF.) Maple procedure automat ically generated by define()\"; \n\n me := eval(procname,1); \n \+ ####\n if _ORDERLESS then \n theArgs := op(sort([args],'addres s')) \n else\n theArgs := args \n end if; \n ####\n i f _FLAT then \n look := theArgs; \n theArgs := map(proc (u) \+ if type(u,('specfunc')('anything',me)) then op(u) else u end if end pr oc,[theArgs]);\n ASSERT(type(theArgs,'list')); \n ####\n \+ if _ORDERLESS then \n theArgs := op(sort(theArgs,'address')) \+ \n else \n theArgs := op(theArgs) \n end if \n end if; \n ####\n if _MLINEAR then \n look := mlinear(op(eval( [theArgs],('me') = ('_FUNCNAME')))); \n if op(look) <> theArgs th en \n return eval(look,('_FUNCNAME') = ('me')) \n end if \+ \n end if; \n ####\n if _LINEAR then \n arg := args[1]; \+ \n if arg = 1 then \n NULL \n elif \n type(arg ,'name') then \n NULL \n elif type(arg,convert('domain','` global`')) then \n return arg*procname(1,args[2 .. -1]) \n \+ elif type(arg,'`+`') then \n return map(procname,args) \n \+ elif type(arg,'`*`') then \n cf,term := selectremove(type,arg, convert('domain','`global`')); \n if cf = 1 then \n re turn ('procname')(args) \n else \n return cf*procname( term,args[2 .. -1]) \n end if \n end if \n end if; \n \+ ####\n if _HASATABLE then \n look := tablelook(('procname')( theArgs),'_TABLE'); \n if look <> FAIL then \n eval(look,` /FUNCNAME` = procname) \n else \n ('procname')(theArgs) \n end if \n else \n ('procname')(theArgs) \n end if \n \+ end proc:\n\n\n mlinear := proc (OpName)\n local func, k, term, t erms, cf, coefficient; \n options remember, system, \n `C opyright (c) 1999 Waterloo Maple Inc. All rights reserved. Patched Oct -23-2001 BF.`; \n \n if nargs < 1 then \n 0 \n elif \n \+ nargs = 1 then \n if type(args[1],convert(`domain`,'`global`')) \+ then \n return args[1]*('_FUNCNAME(1)') \n elif type(args[ 1],'`+`') then \n return map('_FUNCNAME',args[1]) \n elif \+ type(args[1],'`*`') then\n ##\n ## ==> BUGfix, this code handles _FUNCNAME(fload*anything) correctly\n ## \n cf, term := selectremove(type,args[1],convert(`domain`,'`global`'));\n \+ return cf*('_FUNCNAME')(term) \n else \n '_FUNCNAME(ar gs)' \n end if \n" }{TEXT -1 0 "" }{MPLTEXT 1 0 1076 " elif 2 \+ <= nargs then \n if type(args[1],'`+`') then \n return map ('_FUNCNAME',args) \n elif type(args[2],'`+`') then \n ret urn map2('_FUNCNAME',args[1],args[2 .. -1]) \n else \n for k from 3 to nargs do \n if type(args[k],'`+`') then \n \+ return map(curry('_FUNCNAME',args[1 .. k-1]),args[k .. nargs]) \+ \n end if \n end do \n end if; \n ASSERT(map (type,\{args\},'`+`') = \{false\}); \n terms := map(proc (u) \n \+ if type(u,convert(`domain`,'`global`')) and u <> 1 th en \n [u, 1] \n elif type(u,'`*` ') then \n [selectremove(type,u,convert(`domain`,' `global`'))] \n else \n [1, u] \+ \n end if \n end proc,[args]); \n \+ coefficient := mul(k[1],k = terms); \n terms := map2(op,2,terms );\n if terms = [args] then \n '_FUNCNAME(args)' \n e lse \n coefficient*('_FUNCNAME')(op(terms)) \n end if \n \+ end if \n end proc:\n\n DefineTable := TABLE([]);" }{TEXT -1 0 "" }{MPLTEXT 1 0 97 "\n\n DefaultNameProps := [_LINEAR = false, _MLINEAR = false, _ORDERLESS = false, _FLAT = false];\n\n" }{TEXT -1 0 "" } {MPLTEXT 1 0 11 "end module:" }}{PARA 0 "" 0 "" {TEXT -1 419 "After th e package Define has been altered, we need two wrapper functions as co nstructor methods for define and definemore.\nThis prevents the user f rom having to type the long form Define:-define(more), but allows him \+ to use define(more) directly.\n\nTHIS implementation is awkward and do es not support module philosophy, but we failed to find a better way, \+ and we have not\nfigured out, how Maple(R) treats this problem.\n\n" } }{PARA 0 "" 0 "" {TEXT -1 53 "We unprotect the names Define, define an d definemore:" }}{PARA 0 "> " 0 "" {MPLTEXT 1 0 150 "unprotect('define ');\nunprotect('definemore');\n`define`:=proc() Define:-define(args) e nd proc:\n`definemore`:=proc() Define:-definemore(args) end proc:\n" } {TEXT -1 10 "assumiong " }{TEXT 270 10 "libname[1]" }{TEXT -1 41 " to \+ contain a writable user-define libary" }{MPLTEXT 1 0 127 "\nlibname[1] ;\nsave define, cat(libname[1],\"/\",\"define.m\");\nsave definemore, \+ cat(libname[1],\"/\",`definemore.m`);\nsavelib(Define);" }}{PARA 11 " " 1 "" {XPPMATH 20 "6#Q6C:\\Maple9/Cliffordlib6\"" }}}{EXCHG {PARA 0 " " 0 "" {TEXT -1 73 "Now restart Maple and see what was written into th e libary in libanme[1]:" }}{PARA 0 "> " 0 "" {MPLTEXT 1 0 8 "restart: " }}{PARA 0 "> " 0 "" {MPLTEXT 1 0 25 "march('list',libname[1]);" }} {PARA 0 "" 0 "" {TEXT -1 134 "You should find a list-of-lists where ea ch sublist gives informations about the stored entry. Check if you see the following entries:\n" }{TEXT 261 154 "-- [\"Define.m\",[Year,Mont h,Day,HH,MM,SS],no#,no#]\n-- [\"define.m\",[Year,Month,Day,HH,MM,SS],n o#,no#]\n-- [\"definemore.m\",[Year,Month,Day,HH,MM,SS],no#,no#]\n" } {TEXT 262 42 "if so, the module is now ready to be used." }}{PARA 12 " " 1 "" {XPPMATH 20 "6#7bt7&Q':-10.m6\"7(\"%.?\"#6\"#BF)\"#:\"#f\"&o\\ \"\"$n$7&Q':-81.mF&F'\"&bo&\"$#e7&Q':-68.mF&F'\"&>$e\"%bK7&Q&:-7.mF&F' \"&+(z\"%B:7&Q':-53.mF&F'\"&)e%*\"%sG7&Q':-25.mF&F'\"'W.6\"$u&7&Q':-96 .mF&7(F(F)F*F)\"#D\"#C\"'%\\R&\"%KB7&Q(:-149.mF&7(F(F)F*F)\"#T\"\"&\"' nkd\"%4:7&Q(:-162.mF&7(F(F)F*F)\"#YFM\"'Z7e\"$l#7&Q(:-177.mF&7(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'7&Q ':-87.mF&FE\"'E=a\"$!)*7&Q(:-153.mF&FL\"'vTdF_y7&Q(:-168.mF&FY\"'(H)e \"$N(7&Q(:-219.mF&F^q\"']xm\"%/67&Q':-29.mF&F'\"&c*>\"$j&7&Q':-14.mF&F '\"&>0#\"%$3#7&Q':-85.mF&F'\"&AM%\"&LM\"7&Q':-70.mF&F'\"&&ey\"$b$7&Q': -42.mF&F'\"&S*y\"$Y%7&Q':-57.mF&F'\"&gu*\"%5<7&Q*Cliplus.mF&FE\"'XF`\" $k$7&Q(:-151.mF&FL\"'XKd\"$a$7&Q(:-166.mF&FS\"'zJe\"%W<7&Q':-83.mF&F' \"&]<\"\"%k77&Q':-27.mF&F'\"&Pu&\"$#))7&Q&:-9.mF&F'\"&\\U'\"$@%7&Q':-5 5.mF&F'\"&q3(\"$D'7&Q':-12.mF&F'\"&IF(\"%$e\"7&Q':-40.mF&F'\"'F*4\"\"$ <%7&Q>P.mF&FL\"'lHd\"$!G7&Q(:-164.mF&FS\"'\"=#e\"$J#7&Q)define.mF&F^ q\"'4Qm\"#d" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 134 "To get some more \+ informations, we set in interface verboseproc to 3. Furthermore, we ca n set the infolevel of BIGEBRA to 3 or higher. " }}}{EXCHG {PARA 0 "> \+ " 0 "" {MPLTEXT 1 0 103 "interface(verboseproc=3): # for print comman ds\ninfolevel[Bigebra]:=3: # sets verbosity level higher" }}} {EXCHG {PARA 0 "" 0 "" {TEXT -1 279 "Now define the new operators, one using domain to specify the 'constants' over which the tensor product is build, in the example below\nwe define the tensor product to work \+ over a polynomial ring in the variables x over the integers Z[[x]]. Th e other case tests the default value." }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 30 "define(`&r`,multilinear,flat);" }}{PARA 6 "" 1 "" {TEXT -1 73 "define: define can have a user specified domain k for k -tensor products" }}{PARA 6 "" 1 "" {TEXT -1 35 "`use option: 'domain' =''`" }}{PARA 6 "" 1 "" {TEXT -1 50 "canonic: New global t ype created as type/domain:" }}{PARA 11 "" 1 "" {XPPMATH 20 "6#f*6#%%_ varG6\"F&F&-%%typeG6$9$-%$rhsG6#T$F&F&6$%%propG/%'domainG%)constantG" }}{PARA 6 "" 1 "" {TEXT -1 37 "define: New operator &r defined" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 32 "&r(3*x*e1),&r(2.6*e1,3*e2 ,a*e3);" }}{PARA 11 "" 1 "" {XPPMATH 20 "6$,$*&\"\"$\"\"\"-%#&rG6#*&% \"xGF&%#e1GF&F&F&,$*&$\"#y!\"\"F&-F(6%F,%#e2G*&%\"aGF&%#e3GF&F&F&" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 47 "anames();\nprint(`type/domai n`);\ntype(2,domain);" }}{PARA 11 "" 1 "" {XPPMATH 20 "6.%/convert/glo balG%*infolevelG%,type/domainG%3type/interfaceargsG%'assignG%,convert/ setG%'DefineG%'defineG%*interfaceG%&marchG%,savelibnameG%#&rG" }} {PARA 11 "" 1 "" {XPPMATH 20 "6#f*6#%%_varG6\"F&F&-%%typeG6$9$-%$rhsG6 #T$F&F&6$%%propG/%'domainG%)constantG" }}{PARA 11 "" 1 "" {XPPMATH 20 "6#%%trueG" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 72 "define(`&s`,f lat,multilinear,'domain'=polynom(integer,[x,y]),`&s`(0)=0);" }}{PARA 6 "" 1 "" {TEXT -1 50 "canonic: New global type created as type/doma in:" }}{PARA 11 "" 1 "" {XPPMATH 20 "6#f*6#%%_varG6\"F&F&-%%typeG6$9$- %$rhsG6#T$F&F&6$%%propG/%'domainG-%(polynomG6$%(integerG7$%\"xG%\"yG" }}{PARA 6 "" 1 "" {TEXT -1 37 "define: New operator &s defined" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 226 "We got some information about \+ the global new type type/domain and the module informs us that a new o perator is defined.\n\nLet us print out the source code of &s, note th at the work is done in sub-functions like Define:-mlinear." }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 12 "print(`&s`);" }}{PARA 12 "" 1 "" {XPPMATH 20 "6#f*6\"6(%(theArgsG%$argG%%lookG%#meG%#cfG%%termG6#%^pCop yright~(c)~1999~Waterloo~Maple~Inc.~All~rights~reserved.~Patched~Oct-2 3-2001~BF.GF$C,>8'-%%evalG6$9!\"\"\">8$9\">8&F7>F7-%$mapG6$f*6#%\"uGF$ F$F$@%-%%typeG6$9$-.%)specfuncG6$.%)anythingGT#-%#opG6#FFFFF$F$6$F)F07 #F7-%'ASSERTG6#-FD6$F7.%%listG>F7-FO6#F7>F:-FM6#-FO6#-F26$FR/.F0.%*_FU NCNAMEG@$0-FO6#F:F7O-F26$F:/F`oF_o>F:-%*tablelookG6$-.F4Ffn.7%-%%/POSG 6%F5%#&sGF5-%'/LITERG6%F5F5\"\"!-%)/PATTERNG6#Fip@%0F:%%FAILG-F26$F:/% */FUNCNAMEGF4F^p6#Q[pa~Patched~(Oct-23-2001,~BF.)~Maple~procedure~auto matically~generated~by~define()F$F$6$%(mlinearG%(mlinearG" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 291 "Finally let us give an example:\n\n2.5 i s a float and thus not an element of our polynom ring 'domain'. It is \+ treated as if it where a ring extension an n o t extracted \nfrom t he tensor. However, x, 4*x and x^2 are elements of 'domain' and are p ulled out of the tensor product (function). " }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 63 "whattype(2*x*y*e1);\n&s(2.5*x*y*e1);\n&s(2.5*x*e 1,4*x*e2+x^2*e3);" }}{PARA 11 "" 1 "" {XPPMATH 20 "6#%\"*G" }}{PARA 11 "" 1 "" {XPPMATH 20 "6#*(%\"xG\"\"\"%\"yGF%-%#&sG6#,$*&$\"#D!\"\"F% %#e1GF%F%F%" }}{PARA 11 "" 1 "" {XPPMATH 20 "6#,&*(\"\"%\"\"\")%\"xG\" \"#F&-%#&sG6$,$*&$\"#D!\"\"F&%#e1GF&F&%#e2GF&F&*&)F(\"\"$F&-F+6$F-%#e3 GF&F&" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 21 "print(`type/domain `);" }}{PARA 11 "" 1 "" {XPPMATH 20 "6#f*6#%%_varG6\"F&F&-%%typeG6$9$- %$rhsG6#T$F&F&6$%%propG/%'domainG-%(polynomG6$%(integerG7$%\"xG%\"yG" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 17 "type(2*x,domain);" }} {PARA 11 "" 1 "" {XPPMATH 20 "6#%%trueG" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 38 "Last revised: December 1, 2003 /BF/RA." }}}}{MARK "17 0 0" 0 }{VIEWOPTS 1 1 0 1 1 1803 1 1 1 1 }{PAGENUMBERS 0 1 2 33 1 1 }