{VERSION 5 0 "IBM INTEL NT" "5.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 8" }}{PARA 19 "" 0 "" {TEXT -1 162 "Copyright (c) Oct-23-2001 -- 2003 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 "veri son: 1.00-stable" }}{PARA 14 "" 0 "" {TEXT -1 31 "filename: Define_co de.1.00.mws" }}{PARA 14 "" 0 "" {TEXT -1 55 "Maple versions supported: Should run on Maple 6, 7, 8 " }}{PARA 14 "" 0 "" {TEXT -1 37 "pltfor ms: should run on all platforms" }}{PARA 14 "" 0 "" {TEXT -1 34 "URL: \+ http://math.tntech.edu/rafal/" }}{PARA 14 "" 0 "" {TEXT -1 21 "filetyp e: 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 liba ry (not Maple's libary) where the new define can be stored. It might b e convenient to set " }{TEXT 266 7 "libname" }{TEXT -1 29 " during sta rtup 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 := //Cl iffordlib,libname: \n-- maple.ini\n libname := //Cliff ordlib,libname:\n-- stratupscript, see //bin/maple, \n \+ change\n -> $\{Maple_Path\}/maple \n to\n -> $\{Mapl e_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 "t o save the module Define and the wrapper functions define and definemo re, change either the code below or set libname[1] correctly." }}} {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, # Pa tched code\n definemore # unaltered code of Maple(R )\n locals: canonic, # Patched code\n define /diff, # unaltered code of Maple(R)\n skeleton, \+ # Patched code\n mlinear, # Patched code\n \+ DefineTable, # unaltered code of Maple(R)\n \+ DefaultNameProps # unaltered code of Maple(R)\n--define # a const ructor method to make define globally available\n--definemore # a con structor method to make definemore globally available \n" }{MPLTEXT 1 0 2 "\n\n" }}{PARA 0 "> " 0 "" {MPLTEXT 1 0 7560 "unprotect(Define);\n module Define() \n local canonic, `define/diff`, skeleton, mlinear, D efineTable, DefaultNameProps; \n export define, definemore; \n opti on package, \n `Copyright (C) 1999 Waterloo Maple, Inc. All rig hts reserved. Patched Oct-23-2001 BF.`; \n description \"Patched (Oct -23-2001 BF.) module implementing the define and definemore routines\" ; \n\n define := proc (functionname::name) \n local properties, pr op, eprops, nprops, i; \n option `Copyright (c) 1999 Waterloo Maple Inc. All rights reserved.`; \n\n if assigned(functionname) then \+ \n error \"%1 is assigned\", functionname \n elif type(functio nname,'protected') then \n error \"%1 is protected\", functionnam e \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 exclusive\" \n end if; \n DefineTable[functionname] := ''args''; \n eprops, nprops := selectremove(type,[args[2 .. -1]],'\{specfunc(anything,cond itional), `=`\}');\n ##\n ## ==> restore default if no domain is given by the user! \n ## \n if not member('domain',convert(map( lhs,eprops),set)) then\n userinfo(1,Bigebra,`define can have a us er specified domain k for k-tensor products`,\n lprint (`use option: 'domain'=''`));\n eprops:=[op(eprops),`do main`=`constant`];\n end if;\n ##\n eprops := map2(canonic,fu nctionname,eprops);\n nprops := [op(map2(canonic,functionname,nprop s)), op(DefaultNameProps)];\n if eprops = [] then \n functionn ame := subs([op(nprops), ('_HASATABLE') = false, ('_TABLE') = eprops], eval(skeleton)) \n else \n eprops := compiletable(eprops); \n \+ functionname := subs([op(nprops), ('_HASATABLE') = true, ('_TABLE ') = eprops],eval(skeleton)) \n end if;\n userinfo(3,Bigebra,`Ne w operator`,functionname,`defined`); \n NULL \n end proc:\n\n de finemore := proc () \n local fname; \n option `Copyright (c) 199 9 Waterloo Maple Inc. All rights reserved.`; \n description \"add t o the definition of a function\"; \n\n if not type(args[1],'name') \+ then \n error \"first argument is not a name\" \n end if; \n \+ fname := args[1]; \n if not assigned(DefineTable[fname]) then \n \+ error \"nothing known about %1\", fname \n end if; \n unass ign(args[1]); \n define(DefineTable[fname],args[2 .. -1]);\n use rinfo(3,Bigebra,`Property added sucessfully to`,fname); \n NULL \n end proc:\n\n\n canonic := proc (fname, prop)\n option `Copyrigh t (c) 1999 Waterloo Maple Inc. All rights reserved. Patched Oct-23-200 1 BF.`; \n\n if type(prop,'`=`') then\n ##\n ## ==> new opt ion 'domain' added\n ## domain replaces 'constant' in all proce dures\n ## involved in define and allows it to define\n ## \+ e.g. tensor products over arbitrary 'rings'\n ##\n ## a n ew global type `type/domain` is created\n ## \n if lhs(prop ) = ('`domain`') then \n convert(`type/domain`,'`global`');\n \+ assign(`type/domain`,proc(_var) type(_var,rhs(prop)) end proc): \n userinfo(3,Bigebra,`New global type created as type/domain:` ,print(`type/domain`));\n elif member(lhs(prop),\{_LINEAR, _MLINE AR, _ORDERLESS, _FLAT\}) then\n ; \n elif lhs(prop) = ('i nverse') then \n fname(rhs(prop)(('`/X`')::anything)) = ('`/X`' ), rhs(prop)(fname(('`/X`')::anything)) = ('`/X`') \n elif lhs(pr op) = ('zero') then \n fname(rhs(prop)) = 0 \n elif lhs(pr op) = ('identity') then \n fname(('`/X`')::anything,rhs(prop)) \+ = ('`/X`'), fname(rhs(prop),('`/X`')::anything) = ('`/X`') \n eli f type(lhs(prop),'function') and op(0,lhs(prop)) = ('diff') then `defi ne/diff`(prop) \n else \n if has(lhs(prop),fname) then \n \+ lhs(prop) = subs(fname = `/FUNCNAME`,rhs(prop)) \n els e \n error \"left hand side of equational property `%1' does \+ not contain function name %2\", prop, fname \n end if \n e nd if \n elif type(prop,'specfunc(anything,conditional)') then \n \+ ('conditional')(op([1, 1],prop) = subs(fname = `/FUNCNAME`,op([1, \+ 2],prop)),op(2,prop)) \n elif member(prop,\{'flat', 'associative'\} ) then \n ('_FLAT') = true \n elif member(prop,\{'orderless', \+ 'commutative'\}) then \n ('_ORDERLESS') = true \n elif prop = \+ convert('linear','`global`') then \n ('_LINEAR') = true \n eli f 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 fun c, rt; \n option `Copyright (c) 1999 Waterloo Maple Inc. All rights reserved.`; \n\n func := cat(`diff/`,op(0,op(1,lhs(In)))); \n u nprotect(diff); \n rt := op(4,eval(diff)); \n rt[op(lhs(In))] := evaln(rt[op(lhs(In))]); \n protect(diff); \n assign(func,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 local theArg s, arg, look, me, cf, term; \n option `Copyright (c) 1999 Waterloo \+ Maple Inc. All rights reserved. Patched Oct-23-2001 BF.`; \n descri ption \"a Patched (Oct-23-2001, BF.) Maple procedure automatically gen erated by define()\"; \n\n me := eval(procname,1); \n ####\n \+ if _ORDERLESS then \n theArgs := op(sort([args],'address')) \n \+ else\n theArgs := args \n end if; \n ####\n if _FLAT th en \n look := theArgs; \n theArgs := map(proc (u) if type(u, ('specfunc')('anything',me)) then op(u) else u end if end proc,[theArg s]);\n ASSERT(type(theArgs,'list')); \n ####\n if _ORDE RLESS then \n theArgs := op(sort(theArgs,'address')) \n el se \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 then \n \+ return eval(look,('_FUNCNAME') = ('me')) \n end if \n end i f; \n ####\n if _LINEAR then \n arg := args[1]; \n if \+ arg = 1 then \n NULL \n elif \n type(arg,'name') th en \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('do main','`global`')); \n if cf = 1 then \n return ('proc name')(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 i f \n else \n ('procname')(theArgs) \n end if \n end proc: \n\n\n mlinear := proc (OpName)\n local func, k, term, terms, cf, \+ coefficient; \n options remember, system, \n `Copyright ( c) 1999 Waterloo Maple Inc. All rights reserved. Patched Oct-23-2001 B F.`; \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 := se lectremove(type,args[1],convert(`domain`,'`global`'));\n return cf*('_FUNCNAME')(term) \n else \n '_FUNCNAME(args)' \n \+ end if \n" }{TEXT -1 0 "" }{MPLTEXT 1 0 1076 " elif 2 <= nargs t hen \n if type(args[1],'`+`') then \n return map('_FUNCNAM E',args) \n elif type(args[2],'`+`') then \n return map2(' _FUNCNAME',args[1],args[2 .. -1]) \n else \n for k from 3 \+ to nargs do \n if type(args[k],'`+`') then \n retu rn map(curry('_FUNCNAME',args[1 .. k-1]),args[k .. nargs]) \n \+ end if \n end do \n end if; \n ASSERT(map(type,\{arg s\},'`+`') = \{false\}); \n terms := map(proc (u) \n \+ if type(u,convert(`domain`,'`global`')) and u <> 1 then \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 coefficien t := mul(k[1],k = terms); \n terms := map2(op,2,terms);\n if terms = [args] then \n '_FUNCNAME(args)' \n else \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, _O RDERLESS = false, _FLAT = false];\n\n" }{TEXT -1 0 "" }{MPLTEXT 1 0 11 "end module:" }}{PARA 0 "" 0 "" {TEXT -1 419 "After the package Def ine has been altered, we need two wrapper functions as constructor met hods for define and definemore.\nThis prevents the user from having to type the long form Define:-define(more), but allows him to use define (more) directly.\n\nTHIS implementation is awkward and does not suppor t module philosophy, but we failed to find a better way, and we have n ot\nfigured out, how Maple(R) treats this problem.\n\n" }}{PARA 0 "" 0 "" {TEXT -1 53 "We unprotect the names Define, define and definemore :" }}{PARA 0 "> " 0 "" {MPLTEXT 1 0 150 "unprotect('define');\nunprote ct('definemore');\n`define`:=proc() Define:-define(args) end proc:\n`d efinemore`:=proc() Define:-definemore(args) end proc:\n" }{TEXT -1 10 "assumiong " }{TEXT 270 10 "libname[1]" }{TEXT -1 41 " to contain a wr itable user-define libary" }{MPLTEXT 1 0 127 "\nlibname[1];\nsave defi ne, cat(libname[1],\"/\",\"define.m\");\nsave definemore, cat(libname[ 1],\"/\",`definemore.m`);\nsavelib(Define);" }}{PARA 11 "" 1 "" {XPPMATH 20 "6#Q6C:\\Maple8/Cliffordlib6\"" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 73 "Now restart Maple and see what was written into the libar y 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 each sub list gives informations about the stored entry. Check if you see the f ollowing entries:\n" }{TEXT 261 154 "-- [\"Define.m\",[Year,Month,Day, HH,MM,SS],no#,no#]\n-- [\"define.m\",[Year,Month,Day,HH,MM,SS],no#,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#7cq7&Q':-81.m6\"7(\"%.?\"\"\"\"\"&\"#8\"#P\"\")\"&!p< \"$\"e7&Q':-10.mF&F'\"&2A$\"$m$7&Q':-25.mF&F'\"&tD$\"$t&7&Q':-53.mF&F' \"&k(Q\"%qG7&Q&:-7.mF&F'\"&W]%\"%A:7&Q':-68.mF&F'\"&**4*\"%aK7&Q':-51. mF&F'\"&@+#\"$q(7&Q&:-5.mF&F'\"&Jv#\"%D:7&Q':-66.mF&F'\"&ga(\"$#))7&Q' :-23.mF&F'\"&s#y\"$e%7&Q':-38.mF&F'\"&T4)\"%!>\"7&Q&:-3.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.mF&F'\"&#>N\"%j77&Q':-55.mF&F'\"&57(\"$C'7&Q&:-9.mF&F'\"&tH(\" $?%7&Q':-40.mF&F'\"&J@)\"$;%7&Q':-12.mF&F'\"&[y)\"%#e\"7&Q)define.mF&F ho\"'R-a\"#d" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 134 "To get some more informations, we set in interface verboseproc to 3. Furthermore, we c an set the infolevel of BIGEBRA to 3 or higher. " }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 103 "interface(verboseproc=3): # for print comma nds\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 40 "Last changed: November 16, 2002 /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 }