(*********************************************************************** Mathematica-Compatible Notebook This notebook can be used on any computer system with Mathematica 3.0, MathReader 3.0, or any compatible application. The data for the notebook starts with the line of stars above. To get the notebook into a Mathematica-compatible application, do one of the following: * Save the data starting with the line of stars above into a file with a name ending in .nb, then open the file inside the application; * Copy the data starting with the line of stars above to the clipboard, then use the Paste menu command inside the application. Data for notebooks contains only printable 7-bit ASCII and can be sent directly in email or through ftp in text mode. Newlines can be CR, LF or CRLF (Unix, Macintosh or MS-DOS style). NOTE: If you modify the data for this notebook not in a Mathematica- compatible application, you must delete the line below containing the word CacheID, otherwise Mathematica-compatible applications may try to use invalid cache data. For more information on notebooks and Mathematica-compatible applications, contact Wolfram Research: web: http://www.wolfram.com email: info@wolfram.com phone: +1-217-398-0700 (U.S.) Notebook reader applications are available free of charge from Wolfram Research. ***********************************************************************) (*CacheID: 232*) (*NotebookFileLineBreakTest NotebookFileLineBreakTest*) (*NotebookOptionsPosition[ 86097, 2324]*) (*NotebookOutlinePosition[ 87152, 2360]*) (* CellTagsIndexPosition[ 87108, 2356]*) (*WindowFrame->Normal*) Notebook[{ Cell[TextData[ "(* To do... look up in algebra book, 0 * 1 etc put in IdRing at 4.G a=\nnd \ 4.H *)\n\ndo we need this elsewhere?\n\n(* add the rule for multiplication by \ additive identity *)\nIdRngMult=C4[a___,IdRng=C9[0],b___]:=3DIdRng=C9[0]"], "3D input", AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["InheritRules.m Example File"], "3D section", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "(* This file consists of different examples for the package *)\n(* \ InheritRules.m. It tries to cover the basic and advanced*)\n(* operation of \ InheritRules. It also illustrates the use of*)\n(* all of the options of \ InheritRules. Further to this it *)\n(* sets up some conventions for the \ naming of elements and *)\n(* operators. *)\n(* Jason F Harris 3 July 1994. \ *)"], "3D input", AspectRatioFixed->True], Cell[TextData["<True, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["Naming Conventions"], "3D subsection", Evaluatable->False, AspectRatioFixed->True], Cell["", "3D input", AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["Layout of this Notebook"], "3D subsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[{ StyleBox[ "(* This Note Book is split into five basic sections.\n\n1. Example of f & \ W : this is a look at basic rule inheritance.\n\n2. Structures Typed Through \ Heads : This is the", AspectRatioFixed->True, FontFamily->"Monaco", FontSize->9], StyleBox[" Mathematic", AspectRatioFixed->True, FontFamily->"Monaco", FontSize->9, FontSlant->"Italic"], StyleBox[ "a version o=\nf the\n ISSAC paper (Note there are problems with typing \ through the head\n and these are addressed in the following section, but \ typing throu=\ngh\n the head is a very easy way to introduce rewrite rule \ inheritance=\n=20\n structures.) (If the reader would like they could go to \ section 4\n and then come back to 2 & 3. )\n\n3. The Problems of Typing \ through the head are described and the foll=\nowing\n sections are \ outlined.\n\n4. Untyped and Semi-typed Structures : A manual way to inherit \ sets o=\nf Rules\n from multiple symbols to multiple symbols.\n =20\n5. A \ Simple System of Exports: A simple system to automate inheritanc=\ne\n from \ multiple symbols to multiple symbols.\n\n6. The handling of proper types. *)", AspectRatioFixed->True, FontFamily->"Monaco", FontSize->9] }], "3D input", AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["Code used through out this notebook"], "3D subsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData["Friendly On / Off of System Messages."], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "(* friendlyOff will turn off a message. friendlyOn will turn *)\n(* that \ message on only if it was on before the friendlyOff. *)\n\n\ SetAttributes[friendlyOff,HoldAll]=09\nfriendlyOff[mesg_MessageName]:=3D\n\ =09(mesgWasOn[Hold[mesg]]=3D(Head[mesg]=3D!=3D$Off);Off[mesg];)\n\n\ SetAttributes[friendlyOn,HoldAll]\nfriendlyOn[mesg_MessageName]:=3D\n\ =09If[mesgWasOn[Hold[mesg]],On[mesg]]\n"], "3D input", AspectRatioFixed->True]}, Open]], Cell[TextData["Define Blanks for pattern matching"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData[ "(* Through out this section it is useful to define Blanks. It is just=\n *)\ \n(* any number of blanks one, many or none. e.g. (b:Blanks)[t] matches=\n \ *)\n(* _t or __t or ___t .*)\n\nfriendlyOff[General::spell1];\nBlanks =3D \ (Blank | BlankSequence| BlankNullSequence);\nfriendlyOn[General::spell1];"], "3D input", AspectRatioFixed->True], Cell[TextData[ "General::spell1: Possible spelling error: new symbol name \"Blanks\"\n \ is similar to existing symbol \"Blank\"."], "3D message", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData["1. Example of f & w"], "3D section", Evaluatable->False, AspectRatioFixed->True, FontFamily->"3D= times"], Cell[TextData["friendlyOff[General::spell1];"], "3D input", AspectRatioFixed->True], Cell[OutputFormData["\<\ f/: f[x_]+g[y_]:=3Dh[x,y] f/: f[t_,r]:=3Dh[t]\ \>", "\<\ f/: f[x_] + g[y_] :=3D h[x, y]; f/: f[t_, r] :=3D h[t]\ \>"], "3D input",\ AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["?f"], "3D input", AspectRatioFixed->True], Cell[TextData[ "Global`f\n\nf/: f[x_] + g[y_] :=3D h[x, y]\n=20\nf[t_, r] :=3D h[t]"], "3D print", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[TextData["Clear[w];\nInheritRules[w,{f}]"], "3D input", AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["?w"], "3D input", AspectRatioFixed->True], Cell[TextData[ "Global`w\n\nw/: w[x_] + g[y_] :=3D h[x, y]\n=20\nw[t_, r] :=3D h[t]"], "3D print", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[TextData[ "Clear[u];\nInheritRules[u,{f,h->ans},{w,t->x,r->l}]"], "3D input", AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["?u"], "3D input", AspectRatioFixed->True], Cell[TextData[ "Global`u\n\nu/: u[x_] + g[y_] :=3D ans[x, y]\n=20\nu[t_, r] :=3D ans[t]\n=20\ \nu[x_, l] :=3D h[x]"], "3D print", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["?InheritRules"], "3D input", AspectRatioFixed->True], Cell[TextData[ "InheritRules[child,{parent},opts] will create inherited rules for chi=\nld \ prescribed by\n the rules of the parent as in\n Rules[child] =3D \ Rules[parent] /. {parent->child}\n\n \ InheritRules[child,{parent1,replacements1},...,{parenti,replacements=\n\ i},opts] will\n create inherited rules for child prescribed by the rules of \ the pa=\nrents and their\n replacements as in=20\n Rules[child] =3D Join[ \ Rules[parent1] /. {parent1->child,replacement=\ns1},...,\n \ Rules[parenti] /. {parenti->child,replacementsi=\n}]"], "3D print", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData["2. Structures typed through Heads."], "3D section", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["A. Full Names"], "3D subsection", Evaluatable->False, InitializationCell->True], Cell[TextData[ "(* Using Aliases? uncomment this line and comment the next*)\n(* \ Needs[\"Aliases`\",\"MyPackages`Aliases`\"] *)\n\n\ Unprotect[Alias];ClearAll[Alias];Alias[a___]:=3Da;\n\n(* If you do not like \ abbreviations here then you can use the *)\n(* package Aliases.m written \ by me with the aliases below. Note *)\n(* the specific order of the aliases \ (e.g. if =A0Id=C4 was first then=\n*)\n(* it would replace the =A0Id=C4 in \ =A0AssocId=C4). You can obtain =\n *)\n(* Aliases.m from MathSource. If \ you do not mind abbreviations *)\n(* then note that the following lines \ could be the full names of *)\n(* the Operators and the type of the elements \ they work on. *)\n\nAlias[\"=A0AssocId=C9\" -> \ \"elementOfAssociativeWithIdentity\"];\nAlias[\"=A0AssocId=C4\" -> \ \"associativeWithIdentityOperation\"];\nAlias[\"=A0Assoc=C9\" -> \ \"elementOfAssociative\"];\nAlias[\"=A0Assoc=C4\" -> \"associativeOperation\ \"];\nAlias[\"=A0Id=C9\" -> \"elementOfIdentityStructure\"];\n\ Alias[\"=A0Id=C4\" -> \"IdentityStructureOperation\"];\n\ Alias[\"=A0CommGrp=C9\" -> \"elementOfCommutativeGroup\"];\n\ Alias[\"=A0CommGrp=C4\" -> \"commutativeGroupOperation\"];\nAlias[\"=A0Grp=C9\ \" -> \"elementOfGroup\"];\nAlias[\"=A0Grp=C4\" -> \ \"groupOperation\"];\nAlias[\"=A0Rng=C9\" -> \"elementOfRing\"];\n\ Alias[\"=A0RngAdd=C4\" -> \"ringAddition\"];\nAlias[\"=A0RngMult=C4\" -> \ \"ringMultiplication\"];"], "3D input", AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["B. Comment on typed vs. non-Typed"], "3D subsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[{ StyleBox[ "(* In my ISSAC paper. I said we would classify elements by their Head=\ns \ *)\n(* e.g. Grp=C9[e] would be the group element (Grp=C9) identity e. ie =\n\ we *)\n(* have specified the type of this element since it has the head \ Grp=\n=C9. *)\n(* This is typing through the Head. It means whatever head a \ symbol h=\nas*)\n(* is its type. *)\n\n(* I purposely wanted to", AspectRatioFixed->True, FontFamily->"Monaco", FontSize->9], StyleBox[" gloss over", AspectRatioFixed->True, FontFamily->"Monaco", FontSize->9, FontSlant->"Italic"], StyleBox[ " the Mathematica details in the IS=\nSAC*)\n(* paper to give the maximum \ exposure to those", AspectRatioFixed->True, FontFamily->"Monaco", FontSize->9], StyleBox[" that didn'", AspectRatioFixed->True, FontFamily->"Monaco", FontSize->9, FontSlant->"Italic"], StyleBox[ "t know Mathe=\nmatica.*)\n(* Those people that know Mathematica, will \ realise that *)\n(* typing through the head is fairly cumbersome. For this \ reason I wi=\nll*)\n(* make the distinct of two different kinds of structure. \ Those typed=\n *)\n(* through the head, and those that are typed otherwise \ or have no ty=\nping.*)\n(* Throughout the rest of this Notebook, structures \ that are typed =\n *)\n(* through the head will by convention have symbol \ names beginning wi=\nth =A0 *)\n\n(* It is also mentioned that typing through \ the head is still a =\n *)\n(* good way to introduce inheritance of the \ rewrite rule structures. =\n *)", AspectRatioFixed->True, FontFamily->"Monaco", FontSize->9] }], "3D input", AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["C. Generics"], "3D subsection", Evaluatable->False, InitializationCell->True, FontFamily->"3Dtimes"], Cell[CellGroupData[{Cell[TextData[ "Generic rules for a typed associative structure"], "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[CellGroupData[{Cell[TextData[ "(* these are the rules for the elements elementOfAssociative *)\n\n\ =A0Assoc=C9/: =A0Assoc=C4[a_=A0Assoc=C9] :=3D a\n=A0Assoc=C9/: \ =A0Assoc=C4[a___=A0Assoc=C9,=A0Assoc=C4[b___=A0Assoc=\n=C9],c___=A0Assoc=C9] \ :=3D\n=09=09=09=09=A0Assoc=C4[a,b,c]"], "3D input", InitializationCell->True, AspectRatioFixed->True], Cell[TextData[ "General::spell1: Possible spelling error: new symbol name \"=A0Assoc=\n=C4\"\ \n is similar to existing symbol \"=A0Assoc=C9\"."], "3D message", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData[ "Generic rules for a structure with identity=20"], "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[CellGroupData[{Cell[TextData[ "(* these are the rules for the elements elementOfGenericIdentityStruc=\nture \ *)\n\n=A0Id=C9/: =A0Id=C4[a___=A0Id=C9,=A0Id=C9[e],c___=A0Id=C9] :=3D =A0Id=\n\ =C4[a,c]"], "3D input", InitializationCell->True, AspectRatioFixed->True], Cell[TextData[ "General::spell1: Possible spelling error: new symbol name \"=A0Id=C4\"\n \ is similar to existing symbol \"=A0Id=C9\"."], "3D message", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData[ "A generic associative structure with identity=20"], "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[CellGroupData[{Cell[TextData[ "(* to get the rules for elements elementOfAssociativeBinaryWithIdenti=\nty \ *)\n(* we get the rules from elementOfAssociativeBinary and *)\n(* \ elementOfGenericIdentityStructure *)\n(* i.e. inherit the rules from the \ Associative Structure elements to =\nthe *)\n(* Associative Structure with \ Identity elements. We also inherit the =\n*)\n(* rules from the Identity \ Structure to the Associative Structure *)\n(* with Identity elements. *)\n\n\ ClearAll[=A0AssocId=C9];\nInheritRules[=A0AssocId=C9,\n=09=09=09 \ {=A0Assoc=C9,=A0Assoc=C4->=A0AssocId=C4},\n=09=09=09 \ {=A0Id=C9,=A0Id=C4->=A0AssocId=C4}]"], "3D input", InitializationCell->True, AspectRatioFixed->True], Cell[TextData[ "General::spell1: Possible spelling error: new symbol name \"=A0AssocId=\n=C4\ \"\n is similar to existing symbol \"=A0AssocId=C9\"."], "3D message", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[TextData["A look at the inherited rules"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["?=A0AssocId=C9"], "3D input", AspectRatioFixed->True], Cell[TextData[ "Global`=A0AssocId=C9\n\n=A0AssocId=C4[a_=A0AssocId=C9] ^:=3D a\n=20\n\ =A0AssocId=C9/: =A0AssocId=C4[a___=A0AssocId=C9, =A0AssocId=C4[b___=\n\ =A0AssocId=C9], c___=A0AssocId=C9] :=3D=20\n =A0AssocId=C4[a, b, c]\n=20\n\ =A0AssocId=C4[a___=A0AssocId=C9, =A0AssocId=C9[e], c___=A0AssocId=\n=C9] \ ^:=3D =A0AssocId=C4[a, c]"], "3D print", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData["Generic rules for inverse elements"], "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[CellGroupData[{Cell[TextData[ "=A0Inv=C9/: =A0Inv=C4[a___=A0Inv=C9,=A0Inv=C9[b_],=A0Inv=C9[b_^(-1)],=\n\ c___=A0Inv=C9]:=3D\n=09=09=09=A0Inv=C4[a,=A0Inv=C9[e],c]\n=A0Inv=C9/: \ =A0Inv=C4[a___=A0Inv=C9,=A0Inv=C9[b_^(-1)],=A0Inv=C9[b_],=\n\ c___=A0Inv=C9]:=3D\n=09=09=09=A0Inv=C4[a,=A0Inv=C9[e],c]"], "3D input", InitializationCell->True, AspectRatioFixed->True], Cell[TextData[ "General::spell1: Possible spelling error: new symbol name \"=A0Inv=\n=C4\"\n \ is similar to existing symbol \"=A0Inv=C9\"."], "3D message", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData["Generic rules for Commutativity"], "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[CellGroupData[{Cell[TextData[ "=A0Comm=C4[a___=A0Comm=C9, =A0Comm=C9[b_], =A0Comm=C9[c_],d___=A0Comm=\n=C9] \ ^:=3D\n=09=09=A0Comm=C4[a,=A0Comm=C9[c],=A0Comm=C9[b], d]/; Not[OrderedQ[{b,=\ \nc}]]\n"], "3D input", AspectRatioFixed->True], Cell[TextData[ "General::spell1: Possible spelling error: new symbol name \"=A0Comm=\n=C9\"\n\ is similar to existing symbol \"=A0Comm=C4\"."], "3D message", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData["D. Groups"], "3D subsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["Group"], "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[TextData[ "(* We can now easily form groups from our generics. Since groups have=\n *)\n\ (* the associative property, the identity, and inverse then inherit =\n*)\n\ (* these. *)"], "3D input", InitializationCell->True, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData[ "ClearAll[=A0Grp=C9];\nInheritRules[=A0Grp=C9,\n=09=09=09 \ {=A0Assoc=C9,=A0Assoc=C4->=A0Grp=C4},\n=09=09=09 \ {=A0Id=C9,=A0Id=C4->=A0Grp=C4},\n=09=09=09 \ {=A0Inv=C9,=A0Inv=C4->=A0Grp=C4}];"], "3D input", InitializationCell->True, AspectRatioFixed->True], Cell[TextData[ "General::spell1: Possible spelling error: new symbol name \"=A0Grp=\n=C4\"\n \ is similar to existing symbol \"=A0Grp=C9\"."], "3D message", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData["A look at the inherited Rules"], "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[CellGroupData[{Cell[TextData["?=A0Grp=C9"], "3D input", InitializationCell->True, AspectRatioFixed->True], Cell[TextData[ "Global`=A0Grp=C9\n\n=A0Grp=C4[a_=A0Grp=C9] ^:=3D a\n=20\n=A0Grp=C9/: \ =A0Grp=C4[a___=A0Grp=C9, =A0Grp=C4[b___=A0Grp=C9], c___=\n=A0Grp=C9] :=3D \ =A0Grp=C4[a, b, c]\n=20\n=A0Grp=C4[a___=A0Grp=C9, =A0Grp=C9[e], \ c___=A0Grp=C9] ^:=3D =A0Grp=\n=C4[a, c]\n=20\n=A0Grp=C4[a___=A0Grp=C9, \ =A0Grp=C9[b_], =A0Grp=C9[(b_)^(-1)], c___=\n=A0Grp=C9] ^:=3D =A0Grp=C4[a, \ =A0Grp=C9[e], c]\n=20\n=A0Grp=C4[a___=A0Grp=C9, =A0Grp=C9[(b_)^(-1)], \ =A0Grp=C9[b_], c___=\n=A0Grp=C9] ^:=3D =A0Grp=C4[a, =A0Grp=C9[e], c]"], "3D print", Evaluatable->False, InitializationCell->True, AspectRatioFixed->True]}, Open]], Cell[TextData["A few simple Calculations=20"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["=A0Grp=C4 @@ ( =A0Grp=C9 /@ {x,y,z,x})"], "3D input", AspectRatioFixed->True], Cell[OutputFormData[ "\<\ =A0Grp=C4[=A0Grp=C9[x], =A0Grp=C9[y], =A0Grp=C9[z], =A0Grp=C9[x]]\ \>", "\<\ =A0Grp=C4[=A0Grp=C9[x], =A0Grp=C9[y], =A0Grp=C9[z], =A0Grp=C9[x]]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["=A0Grp=C4 @@ ( =A0Grp=C9 /@ {x,y,z,y,(y)^(-1)})"], "3D input", AspectRatioFixed->True], Cell[OutputFormData[ "\<\ =A0Grp=C4[=A0Grp=C9[x], =A0Grp=C9[y], =A0Grp=C9[z]]\ \>", "\<\ =A0Grp=C4[=A0Grp=C9[x], =A0Grp=C9[y], =A0Grp=C9[z]]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["=A0Grp=C4 @@ ( =A0Grp=C9 /@ {x,(x)^(-1)})"], "3D input", AspectRatioFixed->True], Cell[OutputFormData["\<\ =A0Grp=C9[e]\ \>", "\<\ =A0Grp=C9[e]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData["E. A Commutative Group"], "3D subsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData["Commutative group"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData[ "(* To get a commutative group we simply inherit from the Group elemen=\nts \ Grp=C9*)\n(* and add the rule for commutativity. *)\n\n\ InheritRules[=A0CommGrp=C9,{=A0Grp=C9,=A0Grp=C4->=A0CommGrp=C4}];\n\n(* get \ the commutativity from =A0Comm=C9 *)\n\n\ InheritRules[=A0CommGrp=C9,{=A0Comm=C9,=A0Comm=C4->=A0CommGrp=C4}];"], "3D input", AspectRatioFixed->True], Cell[TextData[ "General::spell1: Possible spelling error: new symbol name \"=A0CommGrp=\n=C4\ \"\n is similar to existing symbol \"=A0CommGrp=C9\"."], "3D message", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[TextData["A look at the inherited Rules"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["?=A0CommGrp=C9"], "3D input", AspectRatioFixed->True], Cell[TextData[ "Global`=A0CommGrp=C9\n\n=A0CommGrp=C4[a_=A0CommGrp=C9] ^:=3D a\n=20\n\ =A0CommGrp=C9/: =A0CommGrp=C4[a___=A0CommGrp=C9, =A0CommGrp=C4[b___=\n\ =A0CommGrp=C9], c___=A0CommGrp=C9] :=3D=20\n =A0CommGrp=C4[a, b, c]\n=20\n\ =A0CommGrp=C4[a___=A0CommGrp=C9, =A0CommGrp=C9[e], c___=A0CommGrp=\n=C9] \ ^:=3D =A0CommGrp=C4[a, c]\n=20\n=A0CommGrp=C4[a___=A0CommGrp=C9, \ =A0CommGrp=C9[b_], =A0CommGrp=C9[(b_=\n)^(-1)], c___=A0CommGrp=C9] ^:=3D=20\n \ =A0CommGrp=C4[a, =A0CommGrp=C9[e], c]\n=20\n=A0CommGrp=C4[a___=A0CommGrp=C9, \ =A0CommGrp=C9[(b_)^(-1)], =A0CommGrp=\n=C9[b_], c___=A0CommGrp=C9] ^:=3D=20\n \ =A0CommGrp=C4[a, =A0CommGrp=C9[e], c]\n=20\n=A0CommGrp=C4[a___=A0CommGrp=C9, \ =A0CommGrp=C9[b_], =A0CommGrp=C9[c_]=\n, d___=A0CommGrp=C9] ^:=3D=20\n \ =A0CommGrp=C4[a, =A0CommGrp=C9[c], =A0CommGrp=C9[b], d] /; !Ordered=\nQ[{b, \ c}]"], "3D print", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[TextData["A few simple Calculations=20"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData[ "=A0CommGrp=C4[=A0CommGrp=C9[x],=A0CommGrp=C9[y],=A0CommGrp=C9[x]]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData[ "\<\ =A0CommGrp=C4[=A0CommGrp=C9[x], =A0CommGrp=C9[x], =A0CommGrp=C9[y]]\ \>", "\<\ =A0CommGrp=C4[=A0CommGrp=C9[x], =A0CommGrp=C9[x], \ =A0CommGrp=C9[y]]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData[ "=A0CommGrp=C4[=A0CommGrp=C9[x],=A0CommGrp=C9[z],=A0CommGrp=C9[y],=\n\ =A0CommGrp=C9[y^(-1)],=A0CommGrp=C9[y]]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData[ "\<\ =A0CommGrp=C4[=A0CommGrp=C9[x], =A0CommGrp=C9[y], =A0CommGrp=C9[z]]\ \>", "\<\ =A0CommGrp=C4[=A0CommGrp=C9[x], =A0CommGrp=C9[y], \ =A0CommGrp=C9[z]]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData["F. A Ring"], "3D subsection", Evaluatable->False, AspectRatioFixed->True, FontFamily->"=3Dtimes"], Cell[TextData["Ring"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "(* To obtain a Ring we simply inherit the properties of the commutati=\nve*)\ \n(* group part to the ring add, and then the monoid part to the ring =\n *)\ \n(* multiply. We then have to change a few things like e -> 0 etc. To =\n *)\ \n(* complete the ring we must add the rule for distributivity. *)\n\n\ InheritRules[=A0Rng=C9,{=A0CommGrp=C9,=A0CommGrp=C4->=A0RngAdd=C4,e->=\n\ 0,Power[x_,-1]->-x},\n=09=09=09=09 \ {=A0Assoc=C9,=A0Assoc=C4->=A0RngMult=C4}]\n\n(* add the rule for \ distributivity *)\n\n=A0Rng=C9/: \ =A0RngMult=C4[a___=A0Rng=C9,=A0RngAdd=C4[b___=A0Rng=C9],c=\n___=A0Rng=C9]:=3D\ \n=09=09=09=A0RngAdd=C4 @@ Map[=A0RngMult=C4[a,#,c]&,{b}];\n"], "3D input", AspectRatioFixed->True]}, Open]], Cell[TextData["A look at the inherited Rules"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["?=A0Rng=C9"], "3D input", AspectRatioFixed->True], Cell[TextData[ "Global`=A0Rng=C9\n\n=A0RngAdd=C4[a_=A0Rng=C9] ^:=3D a\n=20\n=A0Rng=C9/: \ =A0RngAdd=C4[a___=A0Rng=C9, =A0RngAdd=C4[b___=A0Rng=C9], =\nc___=A0Rng=C9] \ :=3D =A0RngAdd=C4[a, b, c]\n=20\n=A0RngAdd=C4[a___=A0Rng=C9, =A0Rng=C9[0], \ c___=A0Rng=C9] ^:=3D =A0Rng=\nAdd=C4[a, c]\n=20\n=A0RngAdd=C4[a___=A0Rng=C9, \ =A0Rng=C9[b_], =A0Rng=C9[-(b_)], c___=\n=A0Rng=C9] ^:=3D =A0RngAdd=C4[a, \ =A0Rng=C9[0], c]\n=20\n=A0RngAdd=C4[a___=A0Rng=C9, =A0Rng=C9[-(b_)], \ =A0Rng=C9[b_], c___=\n=A0Rng=C9] ^:=3D =A0RngAdd=C4[a, =A0Rng=C9[0], c]\n=20\n\ =A0RngAdd=C4[a___=A0Rng=C9, =A0Rng=C9[b_], =A0Rng=C9[c_], d___=A0Rng=\n=C9] \ ^:=3D=20\n =A0RngAdd=C4[a, =A0Rng=C9[c], =A0Rng=C9[b], d] /; !OrderedQ[{b, \ c}]\n=20\n=A0RngMult=C4[a_=A0Rng=C9] ^:=3D a\n=20\n=A0Rng=C9/: \ =A0RngMult=C4[a___=A0Rng=C9, =A0RngMult=C4[b___=A0Rng=\n=C9], c___=A0Rng=C9] \ :=3D =A0RngMult=C4[a, b, c]\n=20\n=A0Rng=C9/: =A0RngMult=C4[a___=A0Rng=C9, \ =A0RngAdd=C4[b___=A0Rng=C9],=\n c___=A0Rng=C9] :=3D=20\n \ Apply[=A0RngAdd=C4, (=A0RngMult=C4[a, #1, c] & ) /@ {b}]"], "3D print", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[TextData["A few simple Calculations=20"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData[ "X=3D=A0Rng=C9[x];Y=3D=A0Rng=C9[y];Z=3D=A0Rng=C9[z];XInv=3D=A0Rng=C9[-=\n\ x];YInv=3D=A0Rng=C9[-y];ZInv=3D=A0Rng=C9[-z];\n\nFormat[=A0Rng=C9[a_]]:=3Da"], "3D input", AspectRatioFixed->True], Cell[TextData[ "General::spell1: Possible spelling error: new symbol name \"YInv\"\n is \ similar to existing symbol \"XInv\"."], "3D message", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "General::spell: Possible spelling error: new symbol name \"ZInv\"\n is \ similar to existing symbols {XInv, YInv}."], "3D message", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["=A0RngAdd=C4[X,Y,Z,ZInv,YInv,Z]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData["\<\ =A0RngAdd=C4[=A0Rng=C9[x], =A0Rng=C9[z]]\ \>", "\<\ =A0RngAdd=C4[x, z]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["=A0RngAdd=C4[X,XInv]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData["\<\ =A0Rng=C9[0]\ \>", "\<\ 0\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["=A0RngMult=C4[X,XInv]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData["\<\ =A0RngMult=C4[=A0Rng=C9[x], =A0Rng=C9[-x]]\ \>", "\<\ =A0RngMult=C4[x, -x]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["=A0RngMult=C4[X,=A0RngAdd=C4[X,Y,ZInv],Z]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData[ "\<\ =A0RngAdd=C4[=A0RngMult=C4[=A0Rng=C9[x], =A0Rng=C9[x], =A0Rng=C9[z]],= =20 =20 =A0RngMult=C4[=A0Rng=C9[x], =A0Rng=C9[y], =A0Rng=C9[z]], =A0RngMult= =C4[=A0Rng=C9[x], =A0Rng=C9[-z], =A0Rng=C9[z]]]\ \>", "\<\ =A0RngAdd=C4[=A0RngMult=C4[x, x, z], =A0RngMult=C4[x, y, z], =A0RngMu= lt=C4[x, -z, z]]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData["3. Problems with typing through the Head"], "3D section", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["A. Problems"], "3D subsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[{ StyleBox["(*\nI purposely wanted to gloss over some", AspectRatioFixed->True, FontFamily->"Monaco", FontSize->9], StyleBox[" Mathematica", AspectRatioFixed->True, FontFamily->"Monaco", FontSize->9, FontSlant->"Italic"], StyleBox[ " details in the ISSA=\nC\npaper to give the maximum exposure to those that \ didn't kn", AspectRatioFixed->True, FontFamily->"Monaco", FontSize->9], StyleBox["ow Mathemat=", AspectRatioFixed->True, FontFamily->"Monaco", FontSize->9, FontSlant->"Italic"], StyleBox[ "\nica.\nGoing into the details to the degree we are about to would be kind \ of=\n rough\ngoing for those that didn't understand the basics of pattern \ matching=\n etc.=20\n\nFor the average ISSAC reader to think that,\n\nG/: ...\ \n\nmeans associate the rule with the type G. Is exactly what I wanted hi=\nm \ to think\n\nUnfo", AspectRatioFixed->True, FontFamily->"Monaco", FontSize->9], StyleBox["rtunately in", AspectRatioFixed->True, FontFamily->"Monaco", FontSize->9, FontSlant->"Italic"], StyleBox[ " Mathematica, its not quite this simple. This is due =\nto the=20\nfact \ that the symbol G is not really what we mean by the type G. G is=\n just a \ symbol.\nWe will now see why with typing through the head is not always so \ goo=\nd.=20\n\nIn our example of groups we want things like \ =A0Grp=C4[=A0Grp=C9[_],.=\n..] to be of type Group.\nBut it doesn't have Head \ =A0Grp=C9 it has Head =A0Grp=C4 therefore it=\n isn't of type Group.\n\ Oppps!!.\n\nIn fact consider the rule\n\n =A0Grp=C9/: \ =A0Grp=C4[a___=A0Grp=C9, =A0Grp=C4[b___=A0Grp=C9], c=\n___=A0Grp=C9] :=3D \ =A0Grp=C4[a, b, c]\n=20\nSo if enter\n\n =A0Grp=C4[ \ (=A0Grp=C4[=A0Grp=C9[w], =A0Grp=C9[p]]), (=A0Grp=C4[=\n=A0Grp=C9[q], \ =A0Grp=C9[r]]) ]\n\nit will not reduce to=20\n\n =A0Grp=C4[ =A0Grp=C9[w], \ =A0Grp=C9[p], =A0Grp=C9[q], =A0Grp=C9[r=\n] ]\n\neven though b will match \ =A0Grp=C9[q], =A0Grp=C9[r]\nand c will match {}\na will not match =", AspectRatioFixed->True, FontFamily->"Monaco", FontSize->9], StyleBox["A0Grp=C", AspectRatioFixed->True, FontFamily->"Monaco", FontSize->9, FontVariations->{"CompatibilityType"->"Superscript"}], StyleBox[ "4[=A0Grp=C9[w], =A0Grp=C9[p]] since its head=\n is =A0Grp=C4 and not \ =A0Grp=C9\n =20\nor in other words (w * p) * (q * r) will not reduce to \ w*p*q*r.\n\nOppps(lots) !!!!\n\nActually this isn't too big a disaster \ because there are several simp=\nle ways\nto alleviate the situation. The \ down side is that all of them involve=\n rule sets\nassociated with more than \ one symbol (But we all new this was going t=\no have\nto happen anyway(didn't \ we?)). *)", AspectRatioFixed->True, FontFamily->"Monaco", FontSize->9] }], "3D input", AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["B. Solutions"], "3D subsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "(*\nAll the solutions to typing through the head involve (in general) ass=\n\ ociating\nthe sets of rules for our structure with more than one symbol.\n\n\ We can do inheritance to multiple symbols in two general ways.\n\n1. By hand \ (i.e. for each child in our structure make an InheritRules=\n call)\n\n2. \ make an automated system of doing the above. (we can do this very =\nsimply).\ \n\nBoth ways rely fundamentally on inheritance from parents to a single =\n\ child\ndefined above.\n\nIn the coming sections we also look at 2 new \ distinct ways to look at=\n rules\nsemi-typed or even semi-typed, and proper \ typing.\n\nFirst no typing. All endings on the symbols will be removed. e.g. \ a__=\n_Grp=C9\nwould be change to a___ etc. We shall see that this will lead \ to Rule\nsets that will be associated with more than one symbol.\n\nThe \ second is very similar but handles typing properly.\n\nFor instance consider\n\ \n Grp=C9/: Grp=C4[a___Grp=C9, Grp=C4[b___Grp=C9], c___Grp=C9] :=\n=3D \ Grp=C4[a, b, c]\n\nshould really be something like.\n\n Grp=C9/: \ Grp=C4[a___?TypeGrpQ, Grp=C4[b___?TypeGrpQ], c___?TypeGr=\npQ] :=3D Grp=C4[a, \ b, c]\n\nWhere\n\n TypeGrpQ[(Grp=C9[___] | Grp=C4[___])]:=3DTrue;\n \ TypeGrpQ[___]:=3DFalse;\n\nBut if you examine the new preposed rule, one can \ see that Grp=C9 doe=\ns not occur\nanywhere in this rule so we cannot \ associate the rule with Grp=C9. Fu=\nrthermore\neven though we want to \ associate this rule with the type TypeGrp, we =\ncannot\nassociate ANY rules \ with TypeGrp since it will always occur as ?TypeG=\nrp.\n\nSo we will have to \ associate the rule with Grp=C4. This isn't so bad =\nfor groups\nbut for a \ ring we have 2 operations. both + and * so our structure wi=\nll have\n2 sets \ of rules associated with it and we can no longer inherit the r=\nules\n=66rom \ the parents to a single child. We need multiple children. *)\n"], "3D input", AspectRatioFixed->True]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData["4. Untyped and Semi-Typed Structures"], "3D section", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["A. Comparison to Typed structures."], "3D subsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "(* We can obtain most of the untyped and semi-typed structures direct=\nly \ *)\n(* from the Head typed structures. *)"], "3D input", AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["B. Untyped Generics (Actually Semi-typed)"], "3D subsection", Evaluatable->False, InitializationCell->True, FontFamily->"3Dtimes"], Cell[CellGroupData[{Cell[TextData[ "Generic rules for a semi-typed associative structure"], "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[TextData[{ StyleBox[ "(* This is the same as before except we have to add a *)\n(* Literal \ on to the Assoc=C4. Why? Because no", InitializationCell->True, AspectRatioFixed->True, FontFamily->"Monaco", FontSize->9], StyleBox["w Mathemati", InitializationCell->True, AspectRatioFixed->True, FontFamily->"Monaco", FontSize->9, FontSlant->"Italic"], StyleBox[ "ca *)\n(* can get smart and replace Assoc=C4[b___] by b___ giving *)\n\ (* Assoc=C4[a___,b___,c___] :=3D Assoc=C4[a,b,c]. This does not *)\n(* have \ anything to do with InheritRules it is just to do *)\n(* with eva", InitializationCell->True, AspectRatioFixed->True, FontFamily->"Monaco", FontSize->9], StyleBox["luation in ", InitializationCell->True, AspectRatioFixed->True, FontFamily->"Monaco", FontSize->9, FontSlant->"Italic"], StyleBox[ "Mathematica. *)\n\nAssoc=C4[a_] :=3D a\n\ Assoc=C4[a___,Literal[Assoc=C4[b___]],c___] :=3D\n\ =09=09=09=09Assoc=C4[a,b,c]", InitializationCell->True, AspectRatioFixed->True, FontFamily->"Monaco", FontSize->9] }], "3D input", InitializationCell->True, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["?Assoc=C4"], "3D input", AspectRatioFixed->True], Cell[TextData[ "Global`Assoc=C4\n\nAssoc=C4[a_] :=3D a\n=20\nAssoc=C4[a___, Assoc=C4[b___], \ c___] :=3D Assoc=C4[a, b, c]"], "3D print", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData[ "Generic rules for a semi-typed structure with identity=20"], "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[TextData["Id=C4[a___,Id=C9[e],c___] :=3D Id=C4[a,c]"], "3D input", InitializationCell->True, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData[ "A generic semi-typed associative structure with identity=20"], "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[TextData[ "ClearAll[AssocId=C4];\nInheritRules[AssocId=C4,\n=09=09=09 \ {Assoc=C4,Assoc=C9->AssocId=C9},\n=09=09=09 {Id=C4,Id=C9->AssocId=C9}]"], "3D input", InitializationCell->True, AspectRatioFixed->True], Cell[TextData["(* or from the typed =A0AssocId=C9 *)"], "3D input", AspectRatioFixed->True], Cell[TextData[ "ClearAll[AssocId=C4];\nInheritRules[AssocId=C4,\n=09=09=09 \ {=A0AssocId=C9,b___[=A0AssocId=C9]->b[],\n=09=09=09 =09=09 \ =A0AssocId=C9[c___]->c,\n=09=09=09 =09=09 \ =A0AssocId=C4->AssocId=C4},StrictInheritance->Fals=\ne]"], "3D input", InitializationCell->True, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["Generic rules for inverse elements"], "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[TextData[ "Inv=C4[a___,Inv=C9[b_],Inv=C9[b_^(-1)],c___]:=3D Inv=C4[a,Inv=C9[e],c=\n]\n\ Inv=C4[a___,Inv=C9[b_^(-1)],Inv=C9[b_],c___]:=3D Inv=C4[a,Inv=C9[e],c=\n]"], "3D input", InitializationCell->True, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["Generic rules for commutativity"], "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[TextData[ "Comm=C4[a___, Comm=C9[b_], Comm=C9[c_],d___] :=3D\n\ =09=09Comm=C4[a,Comm=C9[c],Comm=C9[b], d]/; Not[OrderedQ[{b,c}]]\n"], "3D input", AspectRatioFixed->True]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData[ "C. A strictly untyped Group from a head typed Group"], "3D subsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData["Comment"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "(* It is not to difficult to remove the typing information from the =\n \ *)\n(* typed symbols above i.e. we can get rid of all the =A0Grp=C9 symbo=\n\ ls *)\n(* appearing in the generic group. Below we create the untyped \ group =\nGrp=C4.*)\n\n(* The call below is quite simple. =A0Grp=C9 is the \ single parent. Gr=\np=C4 is *)\n(* the child. The b___[=A0Grp=C9]->b[] just \ removes the =A0Grp=C9 fro=\nm the *)\n(* patterns. =A0Grp=C9[c___]->c \ just removes the =A0Grp=C9 that are h=\neads. *)\n(* Finally all the \ =A0Grp=C4 are changed to Grp=C4. =\n *)=20"], "3D input", AspectRatioFixed->True]}, Open]], Cell[TextData["A strictly untyped group"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "(* We could standardly inherit the properties of a group from those a=\nbove \ *)\n(* e.g. *)"], "3D input", AspectRatioFixed->True], Cell[TextData[ "ClearAll[Grp=C4];\nInheritRules[Grp=C4,\n=09=09=09 \ {Assoc=C4,Assoc=C9[a_]->a},\n=09=09=09 {Id=C4,Id=C9[a_]->a},\n=09=09=09 \ {Inv=C4,Inv=C9[a_]->a}];"], "3D input", AspectRatioFixed->True], Cell[TextData[ "(* Or we could inherit off the rules of =A0Grp=C9 and remove the typi=\nng \ *)\n(* information. Note this is changing a lot since we are inheriting \ f=\nrom a *)\n(* head typed group element. To an untyped group operation. \ *)"], "3D input", AspectRatioFixed->True], Cell[TextData[ "ClearAll[Grp=C4];\nInheritRules[Grp=C4,\n=09=09=09 \ {=A0Grp=C9,(b:Blanks)[=A0Grp=C9]->b[],\n=09=09=09=09 =A0Grp=C9[c___]->c,\n\ =09=09=09=09 =A0Grp=C4->Grp=C4},StrictInheritance->False]"], "3D input", AspectRatioFixed->True]}, Open]], Cell[TextData["A look at the untyped group"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "(* If we have entered the latter version of Grp=C4 then *)"], "3D input", AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["?Grp=C4"], "3D input", AspectRatioFixed->True], Cell[TextData[ "Global`Grp=C4\n\nGrp=C4[a___, Grp=C4[b___], c___] :=3D Grp=C4[a, b, c]\n=20\n\ Grp=C4[a_] :=3D a\n=20\nGrp=C4[a___, e, c___] :=3D Grp=C4[a, c]\n=20\n\ Grp=C4[a___, b_, (b_)^(-1), c___] :=3D Grp=C4[a, e, c]\n=20\nGrp=C4[a___, \ (b_)^(-1), b_, c___] :=3D Grp=C4[a, e, c]"], "3D print", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[TextData[ "(* Note the rules have changed order. Why? In going from =A0Grp=C9 to=\n \ Grp=C4 *)\n(* some UpValues have changed to DownValues. Lets do this \ inheritance=\n *)\n(* again with Verbose on. (In fact a lot has changed, \ since we have g=\none*)\n(* from head typed UpValues to strictly untyped Down \ and Up Values. *=\n)"], "3D input", AspectRatioFixed->True]}, Open]], Cell[TextData[ "A strictly untyped group with Verbose -> On"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData[ "ClearAll[Grp=C4];\nInheritRules[Grp=C4,\n=09=09=09 \ {=A0Grp=C9,b___[=A0Grp=C9]->b[],\n=09=09=09=09 =A0Grp=C9[c___]->c,\n\ =09=09=09=09 =A0Grp=C4->Grp=C4},StrictInheritance->False,Verbose->T=\n\ rue]"], "3D input", AspectRatioFixed->True], Cell[TextData[ "UpValues that should be DownValues =3D=20\n=20\n {Literal[Grp=C4[a_]] :> a, \ Literal[Grp=C4[a___, e, c___]] :> Grp=\n=C4[a, c],=20\n=20\n \ 1\n Literal[Grp=C4[a___, b_, --, c___]] :> Grp=C4[a, e, c],=20\n \ b_\n=20\n 1\n \ Literal[Grp=C4[a___, --, b_, c___]] :> Grp=C4[a, e, c]}\n \ b_\nDownValues that should be UpValues =3D {}\nFinal assigned UpValues =3D \ {Literal[Grp=C4[a___, Grp=C4[b___], c___]=\n] :> Grp=C4[a, b, c]}\nFinal \ assigned DownValues =3D {Literal[Grp=C4[a_]] :> a,=20\n=20\n \ Literal[Grp=C4[a___, e, c___]] :> Grp=C4[a, c],=20\n=20\n \ 1\n Literal[Grp=C4[a___, b_, --, c___]] :> Grp=C4[a, e, c],=20\n \ b_\n=20\n 1\n Literal[Grp=C4[a___, \ --, b_, c___]] :> Grp=C4[a, e, c]}\n b_"], "3D print", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[TextData[ "(* We can clearly now see why the rule order has changed only\nGrp=C4[a___, \ Grp=C4[b___], c___] :=3D Grp=C4[a, b, c]\nis still an UpValue while the \ others are now DownValues *)"], "3D input", AspectRatioFixed->True]}, Open]], Cell[TextData["A few simple Calculations=20"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["Grp=C4 @@ {x,y,z,x}"], "3D input", AspectRatioFixed->True], Cell[OutputFormData["\<\ Grp=C4[x, y, z, x]\ \>", "\<\ Grp=C4[x, y, z, x]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["Grp=C4 @@ {x,y,z,y,(y)^(-1),k}"], "3D input", AspectRatioFixed->True], Cell[OutputFormData["\<\ Grp=C4[x, y, z, k]\ \>", "\<\ Grp=C4[x, y, z, k]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["Grp=C4 @@ {x,(x)^(-1)}"], "3D input", AspectRatioFixed->True], Cell[OutputFormData["\<\ e\ \>", "\<\ e\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData[ "D. A semi-typed Group from a head typed Group"], "3D subsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData["(* This will override the definitions above. *)"], "3D input", AspectRatioFixed->True], Cell[TextData["Semi typed Group"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "(* Here we leave the typing on each element but not on the blanks *)"], "3D input", AspectRatioFixed->True], Cell[TextData[ "ClearAll[Grp=C4];\nInheritRules[Grp=C4,\n=09=09=09 \ {Assoc=C4,Assoc=C9->Grp=C9},\n=09=09=09 {Id=C4,Id=C9->Grp=C9},\n=09=09=09 \ {Inv=C4,Inv=C9->Grp=C9}];"], "3D input", AspectRatioFixed->True], Cell[TextData[ "(* Or we could inherit off the rules of =A0Grp=C9 and remove the typi=\nng*)\ \n(* information from the blanks only. *)"], "3D input", AspectRatioFixed->True], Cell[TextData[ "ClearAll[Grp=C4];\nInheritRules[Grp=C4,\n=09=09=09 \ {=A0Grp=C9,(b:Blanks)[=A0Grp=C9]->b[],\n=09=09=09 =09 =A0Grp=C9 -> Grp=C9,\n\ =09=09=09=09 =A0Grp=C4->Grp=C4},StrictInheritance->False]"], "3D input", AspectRatioFixed->True]}, Open]], Cell[TextData["A look at the semi typed group"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "(* If we have entered the latter version of Grp=C4 then *)"], "3D input", AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["?Grp=C4"], "3D input", AspectRatioFixed->True], Cell[TextData[ "Global`Grp=C4\n\nGrp=C4[a___, Grp=C4[b___], c___] :=3D Grp=C4[a, b, c]\n=20\n\ Grp=C4[a_] :=3D a\n=20\nGrp=C4[a___, Grp=C9[e], c___] :=3D Grp=C4[a, c]\n=20\n\ Grp=C4[a___, Grp=C9[b_], Grp=C9[(b_)^(-1)], c___] :=3D Grp=C4[a, Grp=\n\ =C9[e], c]\n=20\nGrp=C4[a___, Grp=C9[(b_)^(-1)], Grp=C9[b_], c___] :=3D \ Grp=C4[a, Grp=\n=C9[e], c]"], "3D print", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[TextData[ "(* Note actually the rules have changed a bit since one of them is *)\n(* \ actually an UpValue. Lets do this again with Verbose on. *)=\n=20"], "3D input", AspectRatioFixed->True]}, Open]], Cell[TextData["A few simple Calculations=20"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["Grp=C4 @@ Grp=C9 /@ {x,y,z,x}"], "3D input", AspectRatioFixed->True], Cell[OutputFormData[ "\<\ Grp=C4[Grp=C9[x], Grp=C9[y], Grp=C9[z], Grp=C9[x]]\ \>", "\<\ Grp=C4[Grp=C9[x], Grp=C9[y], Grp=C9[z], Grp=C9[x]]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["Grp=C4 @@ Grp=C9 /@ {x,y,z,y,(y)^(-1),k}"], "3D input", AspectRatioFixed->True], Cell[OutputFormData[ "\<\ Grp=C4[Grp=C9[x], Grp=C9[y], Grp=C9[z], Grp=C9[k]]\ \>", "\<\ Grp=C4[Grp=C9[x], Grp=C9[y], Grp=C9[z], Grp=C9[k]]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["Grp=C4 @@ Grp=C9 /@ {x,(x)^(-1)}"], "3D input", AspectRatioFixed->True], Cell[OutputFormData["\<\ Grp=C9[e]\ \>", "\<\ Grp=C9[e]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData["E. A strictly untyped Commutative Group"], "3D subsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData["Commutative group"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "ClearAll[CommGrp=C4];\n\n(* To get a commutative group we simply *)\n\ InheritRules[CommGrp=C4,{Grp=C4, Grp=C9[a_]->a}];\n\n(* and then add \ commutativity *)\nInheritRules[CommGrp=C4,{Comm=C4, Comm=C9[a_]->a}];"], "3D input", AspectRatioFixed->True]}, Open]], Cell[TextData["A look at the inherited Rules"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["?CommGrp=C4"], "3D input", AspectRatioFixed->True], Cell[TextData[ "Global`CommGrp=C4\n\nCommGrp=C4[a___, CommGrp=C4[b___], c___] :=3D \ CommGrp=C4[a, b, c]\n=20\nCommGrp=C4[a_] :=3D a\n=20\nCommGrp=C4[a___, e, \ c___] :=3D CommGrp=C4[a, c]\n=20\nCommGrp=C4[a___, b_, (b_)^(-1), c___] :=3D \ CommGrp=C4[a, e, c]\n=20\nCommGrp=C4[a___, (b_)^(-1), b_, c___] :=3D \ CommGrp=C4[a, e, c]\n=20\nCommGrp=C4[a___, b_, c_, d___] :=3D CommGrp=C4[a, \ c, b, d] /; !Ordere=\ndQ[{b, c}]"], "3D print", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[TextData["A few simple Calculations=20"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["CommGrp=C4 @@ {x,y,x}"], "3D input", AspectRatioFixed->True], Cell[OutputFormData["\<\ CommGrp=C4[x, x, y]\ \>", "\<\ CommGrp=C4[x, x, y]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["CommGrp=C4 @@ {x,z,y,y^(-1),y}"], "3D input", AspectRatioFixed->True], Cell[OutputFormData["\<\ CommGrp=C4[x, y, z]\ \>", "\<\ CommGrp=C4[x, y, z]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["CommGrp=C4 @@ {x,z,y,t,y^(-1),1/t,y}"], "3D input", AspectRatioFixed->True], Cell[OutputFormData["\<\ CommGrp=C4[x, y, z]\ \>", "\<\ CommGrp=C4[x, y, z]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData["F. A semi-typed Commutative Group"], "3D subsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData["Commutative group"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "ClearAll[CommGrp=C4];\n\n(* To get a commutative group we simply *)\n\ InheritRules[CommGrp=C4,{Grp=C4, Grp=C9->CommGrp=C9}];\n\n(* and then add \ commutativity *)\nInheritRules[CommGrp=C4,{Comm=C4, Comm=C9->CommGrp=C9}];"], "3D input", AspectRatioFixed->True]}, Open]], Cell[TextData["A look at the inherited Rules"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["?CommGrp=C4"], "3D input", AspectRatioFixed->True], Cell[TextData[ "Global`CommGrp=C4\n\nCommGrp=C4[a___, CommGrp=C4[b___], c___] :=3D \ CommGrp=C4[a, b, c]\n=20\nCommGrp=C4[a_] :=3D a\n=20\nCommGrp=C4[a___, \ CommGrp=C9[e], c___] :=3D CommGrp=C4[a, c]\n=20\nCommGrp=C4[a___, \ CommGrp=C9[b_], CommGrp=C9[(b_)^(-1)], c___] :=3D Co=\nmmGrp=C4[a, \ CommGrp=C9[e], c]\n=20\nCommGrp=C4[a___, CommGrp=C9[(b_)^(-1)], \ CommGrp=C9[b_], c___] :=3D Co=\nmmGrp=C4[a, CommGrp=C9[e], c]\n=20\n\ CommGrp=C4[a___, CommGrp=C9[b_], CommGrp=C9[c_], d___] :=3D=20\n \ CommGrp=C4[a, CommGrp=C9[c], CommGrp=C9[b], d] /; !OrderedQ[{b, c}]"], "3D print", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[TextData["A few simple Calculations=20"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["CommGrp=C4 @@ CommGrp=C9 /@ {x,y,x}"], "3D input", AspectRatioFixed->True], Cell[OutputFormData[ "\<\ CommGrp=C4[CommGrp=C9[x], CommGrp=C9[x], CommGrp=C9[y]]\ \>", "\<\ CommGrp=C4[CommGrp=C9[x], CommGrp=C9[x], CommGrp=C9[y]]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["CommGrp=C4 @@ CommGrp=C9 /@ {x,z,y,y^(-1),y}"], "3D input", AspectRatioFixed->True], Cell[OutputFormData[ "\<\ CommGrp=C4[CommGrp=C9[x], CommGrp=C9[y], CommGrp=C9[z]]\ \>", "\<\ CommGrp=C4[CommGrp=C9[x], CommGrp=C9[y], CommGrp=C9[z]]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData[ "CommGrp=C4 @@ CommGrp=C9 /@ {x,z,y,t,y^(-1),1/t,y}"], "3D input", AspectRatioFixed->True], Cell[OutputFormData[ "\<\ CommGrp=C4[CommGrp=C9[x], CommGrp=C9[y], CommGrp=C9[z]]\ \>", "\<\ CommGrp=C4[CommGrp=C9[x], CommGrp=C9[y], CommGrp=C9[z]]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData["G. A strictly untyped Ring"], "3D subsection", Evaluatable->False, AspectRatioFixed->True, FontFamily->"=3Dtimes"], Cell[TextData[ "A strictly untyped Ring from semi-typed structures"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "(* To obtain a Ring we simply inherit the properties of the group par=\nt *)\ \n(* to the ring add, and then the monoid part to the ring multiply. We=\n *)\ \n(* then have to change a few things like e -> 0 etc. To complete the =\n *)\ \n(* ring we must add the rule for distributivity. *)\n\n(* Note now since we \ are inheriting to multiple children we have to d=\no *)\n(* the inheritance \ for each child separately. *)\n\n(* Note the reason we are inheriting to \ multiple children is that the=\n *)\n(* rules for the ring structure are no \ longer solely associated with =\n *)\n(* Rng=C9 (which previously was common \ to the rules of both RngAdd an=\nd *)\n(* RngMult) but now there is no \ longer any common tie or link) so we =\n *)\n(* have to perform the inherit \ to both childs separately.*)"], "3D input", AspectRatioFixed->True], Cell[TextData["ClearAll[RngAdd=C4,RngMult=C4];"], "3D input", AspectRatioFixed->True], Cell[TextData[ "(* So inherit the commutative group properties *)\n\ InheritRules[RngAdd=C4,{CommGrp=C4, Power[x_,-1]->-x, e->0, CommGrp=\n\ =C9[a_]->a}]"], "3D input", AspectRatioFixed->True], Cell[TextData[ "(* Inherit the monoid properties *)\n\ InheritRules[RngMult=C4,{Assoc=C4,Assoc=C9[a_]->a}]"], "3D input", AspectRatioFixed->True], Cell[TextData[ "(* Add the rule for distributivity. the Literal is there to stop *)\n(* \ RngAdd=C4[b___] evaluating to b___ *)\n\ RngMult=C4[a___,Literal[RngAdd=C4[b___]],c___]:=3D RngAdd=C4 @@ Map[R=\n\ ngMult=C4[a,#,c]&,{b}]"], "3D input", AspectRatioFixed->True]}, Open]], Cell[TextData["A look at the inherited Rules."], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData["A few simple Calculations=20"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["RngAdd=C4[x,y,z,-z,-y,z]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData["\<\ RngAdd=C4[x, -y, y, -z, z, z]\ \>", "\<\ RngAdd=C4[x, -y, y, -z, z, z]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["RngMult=C4[x,-x]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData["\<\ RngMult=C4[x, -x]\ \>", "\<\ RngMult=C4[x, -x]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["RngMult=C4[x,RngAdd=C4[-z,x],RngAdd=C4[x,y,-z],z]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData[ "\<\ RngAdd=C4[RngMult=C4[x, x, x, z], RngMult=C4[x, x, y, z], RngMult= =C4[x, x, -z, z],=20 =20 RngMult=C4[x, -z, x, z], RngMult=C4[x, -z, y, z], RngMult=C4[x, -z,= -z, z]]\ \>", "\<\ RngAdd=C4[RngMult=C4[x, x, x, z], RngMult=C4[x, x, y, z], RngMult= =C4[x, x, -z, z],=20 =20 RngMult=C4[x, -z, x, z], RngMult=C4[x, -z, y, z], RngMult=C4[x, -z,= -z, z]]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["RngAdd=C4[x,RngAdd=C4[-z,x],RngAdd=C4[x,y,-z],z]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData["\<\ RngAdd=C4[x, x, x, y, -z, -z, z]\ \>", "\<\ RngAdd=C4[x, x, x, y, -z, -z, z]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData["G. A semi-typed Ring"], "3D subsection", Evaluatable->False, AspectRatioFixed->True, FontFamily->"=3Dtimes"], Cell[TextData[ "An semi-typed Ring from semi-typed structures"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "(* To obtain a Ring we simply inherit the properties of the group par=\nt *)\ \n(* to the ring add, and then the monoid part to the ring multiply. We=\n *)\ \n(* then have to change a few things like e -> 0 etc. To complete the =\n *)\ \n(* ring we must add the rule for distributivity. *)\n\n(* Note now since we \ are inheriting to multiple children we have to d=\no *)\n(* the inheritance \ for each child separately. *)\n\n(* Note the reason we are inheriting to \ multiple children is that the=\n *)\n(* rules for the ring structure are no \ longer solely associated with =\n *)\n(* Rng=C9 (which previously was common \ to the rules of both RngAdd an=\nd *)\n(* RngMult) but now there is no \ longer any common tie or link) so we =\n *)\n(* have to perform the inherit \ to both childs separately.*)"], "3D input", AspectRatioFixed->True], Cell[TextData["ClearAll[RngAdd=C4,RngMult=C4];"], "3D input", AspectRatioFixed->True], Cell[TextData[ "(* So inherit the commutative group properties *)\n\ InheritRules[RngAdd=C4,{CommGrp=C4,CommGrp=C9->Rng=C9,e->0,Power[x_,-=\n\ 1]->-x}]"], "3D input", AspectRatioFixed->True], Cell[TextData[ "(* Inherit the monoid properties *)\n\ InheritRules[RngMult=C4,{Assoc=C4,Assoc=C9->Rng=C9}]"], "3D input", AspectRatioFixed->True], Cell[TextData[ "(* Add the rule for distributivity. the Literal is there to stop *)\n(* \ RngAdd=C4[b___] evaluating to b___ *)\n\ RngMult=C4[a___,Literal[RngAdd=C4[b___]],c___]:=3D RngAdd=C4 @@ Map[R=\n\ ngMult=C4[a,#,c]&,{b}]"], "3D input", AspectRatioFixed->True]}, Open]], Cell[TextData["A look at the inherited Rules."], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["?RngAdd=C4\n\n?RngMult=C4"], "3D input", AspectRatioFixed->True], Cell[TextData[ "Global`RngAdd=C4\n\nRngAdd=C4[a___, RngAdd=C4[b___], c___] :=3D RngAdd=C4[a, \ b, c]\n=20\nRngAdd=C4[a_] :=3D a\n=20\nRngAdd=C4[a___, Rng=C9[0], c___] :=3D \ RngAdd=C4[a, c]\n=20\nRngAdd=C4[a___, Rng=C9[b_], Rng=C9[-(b_)], c___] :=3D \ RngAdd=C4[a, Rn=\ng=C9[0], c]\n=20\nRngAdd=C4[a___, Rng=C9[-(b_)], \ Rng=C9[b_], c___] :=3D RngAdd=C4[a, Rn=\ng=C9[0], c]\n=20\nRngAdd=C4[a___, \ Rng=C9[b_], Rng=C9[c_], d___] :=3D=20\n RngAdd=C4[a, Rng=C9[c], Rng=C9[b], \ d] /; !OrderedQ[{b, c}]\nGlobal`RngMult=C4\n\nRngMult=C4[a___, \ RngMult=C4[b___], c___] :=3D RngMult=C4[a, b, c]\n=20\nRngMult=C4[a_] :=3D a\n\ =20\nRngMult=C4[a___, RngAdd=C4[b___], c___] :=3D Apply[RngAdd=C4, (RngMul=\n\ t=C4[a, #1, c] & ) /@ {b}]"], "3D print", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[TextData["A few simple Calculations=20"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "X=3DRng=C9[x];Y=3DRng=C9[y];Z=3DRng=C9[z];XInv=3DRng=C9[-x];YInv=3DRn=\n\ g=C9[-y];ZInv=3DRng=C9[-z];\n\nFormat[Rng=C9[a_]]:=3Da"], "3D input", AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["RngAdd=C4[X,Y,Z,ZInv,YInv,Z]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData["\<\ RngAdd=C4[Rng=C9[x], Rng=C9[z]]\ \>", "\<\ RngAdd=C4[x, z]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["RngMult=C4[X,XInv]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData["\<\ RngMult=C4[Rng=C9[x], Rng=C9[-x]]\ \>", "\<\ RngMult=C4[x, -x]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData[ "RngMult=C4[X,RngAdd=C4[ZInv,X],RngAdd=C4[X,Y,ZInv],Z]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData[ "\<\ RngAdd=C4[RngMult=C4[Rng=C9[x], Rng=C9[x], Rng=C9[x], Rng=C9[z]],= =20 =20 RngMult=C4[Rng=C9[x], Rng=C9[x], Rng=C9[y], Rng=C9[z]],=20 =20 RngMult=C4[Rng=C9[x], Rng=C9[x], Rng=C9[-z], Rng=C9[z]],=20 =20 RngMult=C4[Rng=C9[x], Rng=C9[-z], Rng=C9[x], Rng=C9[z]],=20 =20 RngMult=C4[Rng=C9[x], Rng=C9[-z], Rng=C9[y], Rng=C9[z]],=20 =20 RngMult=C4[Rng=C9[x], Rng=C9[-z], Rng=C9[-z], Rng=C9[z]]]\ \>", "\<\ RngAdd=C4[RngMult=C4[x, x, x, z], RngMult=C4[x, x, y, z], RngMult= =C4[x, x, -z, z],=20 =20 RngMult=C4[x, -z, x, z], RngMult=C4[x, -z, y, z], RngMult=C4[x, -z,= -z, z]]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData[ "RngAdd=C4[X,RngAdd=C4[ZInv,X],RngAdd=C4[X,Y,ZInv],Z]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData[ "\<\ RngAdd=C4[Rng=C9[x], Rng=C9[x], Rng=C9[x], Rng=C9[y], Rng=C9[-z]]\ \>", "\<\ RngAdd=C4[x, x, x, y, -z]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[TextData[ "An semi-typed Ring from head typed structures"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "(* To give another example we will do the inheritance from the head =\n *)\n\ (* typed structures. Note InheritRules will automatically delete any =\n *)\n\ (* rules that are not applicable or well formed. =\n *)\n\ \n(* Note again since we are inheriting to multiple children we have to=\n \ *)\n(* do the inheritance for each child separately. *)\n\n(* Note we are \ inheriting to multiple children since the rule of a th=\ne*)\n(* ring are no \ longer to do Rng=C9 (which was common to the rules of =\n *)\n(* both \ RngAdd and Rng Mult) but now there is no longer any common =\n *)\n(* tie \ or link) so we have to inherit both rules separately.*)"], "3D input", AspectRatioFixed->True], Cell[TextData[ "(* Clear the Previous Rules just defined above *)\n\ ClearAll[RngAdd=C4,RngMult=C4];"], "3D input", AspectRatioFixed->True], Cell[TextData[ "(* Now inherit the addition. *)\nInheritRules[RngAdd=C4,\n\ =09=09=09{=A0Rng=C9,=A0RngAdd=C4->RngAdd=C4,\n=09=09=09=09 \ =A0RngMult=C4->RngMult=C4,\n=09=09=09=09 (b:Blanks)[=A0Rng=C9]->b[]\n\ =09=09=09=09 =A0Rng=C9->Rng=C9},StrictInheritance->False]"], "3D input", AspectRatioFixed->True], Cell[TextData[ "(* Now very similarly inherit the multiplication. *)\n\ InheritRules[RngMult=C4,\n=09=09=09{=A0Rng=C9,=A0RngAdd=C4->RngAdd=C4,\n\ =09=09=09=09 =A0RngMult=C4->RngMult=C4,\n=09=09=09=09 \ (b:Blanks)[=A0Rng=C9]->b[]\n=09=09=09=09 \ =A0Rng=C9->Rng=C9},StrictInheritance->False]"], "3D input", AspectRatioFixed->True], Cell[TextData[ "(* the rule for distributivity is of course just a one of the Rules =\n *)\n\ (* for =A0Rng=C9 *)"], "3D input", AspectRatioFixed->True]}, Open]], Cell[TextData[ "A look at the alternatively inherited Rules."], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["?RngAdd=C4\n\n?RngMult=C4"], "3D input", AspectRatioFixed->True], Cell[TextData[ "Global`RngAdd=C4\n\nRngAdd=C4[a___, RngAdd=C4[b___], c___] :=3D RngAdd=C4[a, \ b, c]\n=20\nRngAdd=C4[a_] :=3D a\n=20\nRngAdd=C4[a___, Rng=C9[0], c___] :=3D \ RngAdd=C4[a, c]\n=20\nRngAdd=C4[a___, Rng=C9[b_], Rng=C9[-(b_)], c___] :=3D \ RngAdd=C4[a, Rn=\ng=C9[0], c]\n=20\nRngAdd=C4[a___, Rng=C9[-(b_)], \ Rng=C9[b_], c___] :=3D RngAdd=C4[a, Rn=\ng=C9[0], c]\n=20\nRngAdd=C4[a___, \ Rng=C9[b_], Rng=C9[c_], d___] :=3D=20\n RngAdd=C4[a, Rng=C9[c], Rng=C9[b], \ d] /; !OrderedQ[{b, c}]\nGlobal`RngMult=C4\n\nRngMult=C4[a___, \ RngMult=C4[b___], c___] :=3D RngMult=C4[a, b, c]\n=20\nRngMult=C4[a_] :=3D a\n\ =20\nRngMult=C4[a___, RngAdd=C4[b___], c___] :=3D Apply[RngAdd=C4, (RngMul=\n\ t=C4[a, #1, c] & ) /@ {b}]"], "3D print", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData[ "H. A semi-typed Ring with identity (check rules)."], "3D subsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData["IdRng"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "(* Note again since we are inheriting from multiple parents to multip=\nle*)\ \n(* children we have to do the inheritance for each child separately. =\n \ *)\nClearAll[IdRngAdd=C4,IdRngMult=C4]"], "3D input", AspectRatioFixed->True], Cell[TextData[ "(* inherit RngAdd=C4 *)\n\ InheritRules[IdRngAdd=C4,{RngAdd=C4,Rng=C9->IdRng=C9}]"], "3D input", AspectRatioFixed->True], Cell[TextData[ "(* Inherit the monoid properties *)\n\ InheritRules[IdRngMult=C4,{RngMult=C4,Rng=C9->IdRng=C9}]"], "3D input", AspectRatioFixed->True], Cell[TextData[ "(* Look up case 0*1 is 0 and this has to take precedence. *)\n(* any other \ rules I am missing ?. *)\n\n(* add the rule for multiplication by additive \ identity *)\nIdRngMult=C4[a___,IdRng=C9[0],b___]:=3DIdRng=C9[0]\n\n(* Now \ inherit the rule for the ring multiplicative identity *)\n\ InheritRules[IdRngMult=C4,{Id=C4,Id=C9->IdRng=C9,e->1}]"], "3D input", AspectRatioFixed->True]}, Open]], Cell[TextData["A look at the inherited Rules"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["?IdRngAdd=C4\n\n?IdRngMult=C4"], "3D input", AspectRatioFixed->True], Cell[TextData[ "Global`IdRngAdd=C4\n\nIdRngAdd=C4[a___, IdRngAdd=C4[b___], c___] :=3D \ IdRngAdd=C4[a, b, c]\n=20\nIdRngAdd=C4[a_] :=3D a\n=20\nIdRngAdd=C4[a___, \ IdRng=C9[0], c___] :=3D IdRngAdd=C4[a, c]\n=20\nIdRngAdd=C4[a___, \ IdRng=C9[b_], IdRng=C9[-(b_)], c___] :=3D IdRngAdd=\n=C4[a, IdRng=C9[0], c]\n\ =20\nIdRngAdd=C4[a___, IdRng=C9[-(b_)], IdRng=C9[b_], c___] :=3D IdRngAdd=\n\ =C4[a, IdRng=C9[0], c]\n=20\nIdRngAdd=C4[a___, IdRng=C9[b_], IdRng=C9[c_], \ d___] :=3D=20\n IdRngAdd=C4[a, IdRng=C9[c], IdRng=C9[b], d] /; !OrderedQ[{b, \ c}]\nGlobal`IdRngMult=C4\n\nIdRngMult=C4[a___, IdRngMult=C4[b___], c___] :=3D \ IdRngMult=C4[a, b, =\nc]\n=20\nIdRngMult=C4[a_] :=3D a\n=20\n\ IdRngMult=C4[a___, RngAdd=C4[b___], c___] :=3D=20\n Apply[RngAdd=C4, \ (IdRngMult=C4[a, #1, c] & ) /@ {b}]\n=20\nIdRngMult=C4[a___, IdRng=C9[0], \ b___] :=3D IdRng=C9[0]\n=20\nIdRngMult=C4[a___, IdRng=C9[1], c___] :=3D \ IdRngMult=C4[a, c]"], "3D print", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[TextData["A few simple Calculations=20"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "X=3DIdRng=C9[x];Y=3DIdRng=C9[y];Z=3DIdRng=C9[z];XInv=3DIdRng=C9[-x];Y=\n\ Inv=3DIdRng=C9[-y];\nZInv=3DIdRng=C9[-z];IdMult=3DIdRng=C9[1];\n\n\ Format[Rng=C9[a_]]:=3Da"], "3D input", AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["IdRngAdd=C4[X,Y,Z,IdMult,ZInv,YInv,Z]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData[ "\<\ IdRngAdd=C4[IdRng=C9[1], IdRng=C9[x], IdRng=C9[z]]\ \>", "\<\ IdRngAdd=C4[IdRng=C9[1], IdRng=C9[x], IdRng=C9[z]]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["IdRngMult=C4[X,XInv]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData["\<\ IdRngMult=C4[IdRng=C9[x], IdRng=C9[-x]]\ \>", "\<\ IdRngMult=C4[IdRng=C9[x], IdRng=C9[-x]]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["IdRngAdd=C4[X,XInv]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData["\<\ IdRng=C9[0]\ \>", "\<\ IdRng=C9[0]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData[ "IdRngMult=C4[X,IdRngAdd=C4[ZInv,X],IdRngAdd=C4[X,Y,ZInv],Z]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData[ "\<\ IdRngMult=C4[IdRng=C9[x], IdRngAdd=C4[IdRng=C9[x], IdRng=C9[-z]],= =20 =20 IdRngAdd=C4[IdRng=C9[x], IdRng=C9[y], IdRng=C9[-z]], IdRng=C9[z]]\ \>", "\<\ IdRngMult=C4[IdRng=C9[x], IdRngAdd=C4[IdRng=C9[x], IdRng=C9[-z]],= =20 =20 IdRngAdd=C4[IdRng=C9[x], IdRng=C9[y], IdRng=C9[-z]], IdRng=C9[z]]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData[ "IdRngAdd=C4[X,IdRngAdd=C4[ZInv,X],IdRngAdd=C4[X,Y,ZInv],Z]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData[ "\<\ IdRngAdd=C4[IdRng=C9[x], IdRng=C9[x], IdRng=C9[x], IdRng=C9[y], IdRng= =C9[-z]]\ \>", "\<\ IdRngAdd=C4[IdRng=C9[x], IdRng=C9[x], IdRng=C9[x], IdRng=C9[y], IdRng= =C9[-z]]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData["5. A Simple System of Exports"], "3D section", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["A. Outline"], "3D subsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "(* In general we might want to inherit from multiple parents to a *=\n)\n\ (* single child (as mentioned above). We can automate this process *=\n)\n(* \ quite easily. I have called this method \"a system of exports\". *=\n)\n(* \ This is an example of a very simple system of structuring Rules. *=\n)\n(* At \ its core it uses the Inheritance of Rewrite rules, but it adds*=\n)\n(* a \ little more structure. Note the way we have defined this *=\n)\n(* \ structure is in no way unique. We could have defined it in many *=\n)\n(* \ different ways. *)"], "3D input", AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["B. A step by step guide"], "3D subsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "(* The basic and simplistic idea is that a structure say a ring will*=\n)\n\ (* have certain symbols that it will \"export\" or \"show\" or \"use as *=\n\ )\n(* interface\". In the case of ring these might be \"RngAdd=C4,RngMult=\n\ =C4,*)\n(* Rng=C9,0,-, and possible a boolean function TypeRingQ\". *)"], "3D input", AspectRatioFixed->True], Cell[TextData[ "(* So lets enter the exports for a Rng *)\n\ Exports[Rng]:=3D{RngAdd=C4,RngMult=C4,Rng=C9,Minus,TypeRngQ}"], "3D input", AspectRatioFixed->True], Cell[TextData[ "(* To then inherit this parent structure to a similar child *=\n)\n\ (* structure, we must first create the exports of the child. Then we*=\n)\n(* \ must calculate what replacements we are going to have in each =\n*)\n(* \ separate InheritRules call we will make. Then we must actually =\n*)\n(* \ inherit the rules for each symbol in the exports of the child. *=\n)\n(* \ Lets step through this process for a Rng and a CommRng. *)=20"], "3D input", AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData[ "(* We use a utility to take a symbol and replace part of the name of*=\n)\n\ (* that symbol by another symbol. *)\n\ NameReplace[name_,from_Symbol->to_Symbol]:=3D=20\n=09(ToExpression @ \ StringReplace[ToString @ name,Rule @@ ToString /@ =\n{from,to}]);\n=09\n(* \ e.g. *)\nNameReplace[RngAdd=C4,Rng->CommRng]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData["\<\ CommRngAdd=C4\ \>", "\<\ CommRngAdd=C4\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData[ "(* So *)\nExports[CommRng] =3D NameReplace[#,Rng->CommRng]& /@ \ Exports[Rng]"], "3D input", AspectRatioFixed->True], Cell[TextData[ "General::spell1: Possible spelling error: new symbol name \"CommRngAdd=\n=C4\ \"\n is similar to existing symbol \"CommRngAdd\"."], "3D message", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "General::spell1: Possible spelling error: new symbol name \"CommRng=\n=C9\"\n\ is similar to existing symbol \"CommRng\"."], "3D message", Evaluatable->False, AspectRatioFixed->True], Cell[OutputFormData[ "\<\ {CommRngAdd=C4, CommRngMult=C4, CommRng=C9, Minus, TypeCommRngQ}\ \>", "\<\ {CommRngAdd=C4, CommRngMult=C4, CommRng=C9, Minus, TypeCommRngQ}\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData[ "(* Then we must calculate the replacements *)\nreplacements =3D \ MapThread[Rule,{Exports[Rng],Exports[CommRng]}]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData[ "\<\ {RngAdd=C4 -> CommRngAdd=C4, RngMult=C4 -> CommRngMult=C4, Rng=C9 -> = CommRng=C9, Minus -> Minus,=20 =20 TypeRngQ -> TypeCommRngQ}\ \>", "\<\ {RngAdd=C4 -> CommRngAdd=C4, RngMult=C4 -> CommRngMult=C4, Rng=C9 -> = CommRng=C9, Minus -> Minus,=20 =20 TypeRngQ -> TypeCommRngQ}\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData[ "(* Then we must do the inheritance for each of CommRngAdd=C4 , =\n *)\n\ (* CommRngMult=C4, CommRng=C9, ... *)\n\ Short[(InhRules[#[[2]],{#[[1]],replacements},StrictInheritance->False=\n]&)\n\ =09=09=09=09=09/@ replacements, 5]\n"], "3D input", AspectRatioFixed->True], Cell[OutputFormData["\<\ Short[\"<<>>\"]\ \>", "\<\ {InhRules[CommRngAdd=C4, {RngAdd=C4, {RngAdd=C4 -> CommRngAdd=C4, Rng= Mult=C4 -> CommRngMult=C4,=20 =20 Rng=C9 -> CommRng=C9, Minus -> Minus, TypeRngQ -> TypeCommRngQ}}= ,=20 =20 StrictInheritance -> False], <<3>>,=20 =20 InhRules[TypeCommRngQ, {TypeRngQ,=20 =20 {RngAdd=C4 -> CommRngAdd=C4, RngMult=C4 -> CommRngMult=C4, Rng= =C9 -> CommRng=C9,=20 =20 Minus -> Minus, TypeRngQ -> TypeCommRngQ}}, StrictInheritance ->= False]}\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData[ "C. A 3 line implementation of InheritExportStructure"], "3D subsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "(* So Lets put this all together. *=\n)\n\ (* 1. The first line just calculates the exports of the child. *=\n)\n(* \ 2. The second line just calculates the replacements of =\n*)\n(* \ parent export -> child export. *=\n)\n(* 3. \ The third line just does the inheritance for each exported *=\n)\n(* \ symbol of the child. *)\n=20\n\ InheritExportStructure[childE_,parentE_]:=3DBlock[{replacements},\n\ =09Exports[childE]=3DNameReplace[#,parentE->childE]& /@ Exports[paren=\ntE];\n\ =09replacements =3D MapThread[Rule,{Exports[parentE],Exports[childE]}=\n];\n\ =09InheritRules[#[[2]],Prepend[replacements,#[[1]]],StrictInheritance=\n\ ->False]& /@=20\nreplacements;];"], "3D input", AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["D. Example: Ring -> Commutative Ring"], "3D subsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData["Commutative Rng"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData["ClearAll[CommRngAdd=C4,CommRngMult=C4,CommRng=C9]"], "3D input", AspectRatioFixed->True], Cell[TextData[ "(* again *)\nExports[Rng]:=3D{RngAdd=C4,RngMult=C4,Rng=C9,TypeRngQ}"], "3D input", AspectRatioFixed->True], Cell[TextData["InheritExportStructure[CommRng,Rng]"], "3D input", AspectRatioFixed->True], Cell[TextData[ "(* and then add commutativity of multiplication *)\n\ InheritRules[RngMult=C4,{Comm=C4, Comm=C9[a_]->CommRng=C9[a]}];\n"], "3D input", AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["Its Rules"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["?CommRngAdd=C4\n\n?CommRngMult=C4\n\n?CommRng=C9"], "3D input", AspectRatioFixed->True], Cell[TextData[ "Global`CommRngAdd=C4\n\nCommRngAdd=C4[a___, CommRngAdd=C4[b___], c___] :=3D \ CommRngAdd=C4[a, =\nb, c]\n=20\nCommRngAdd=C4[a_] :=3D a\n=20\n\ CommRngAdd=C4[a___, CommRng=C9[0], c___] :=3D CommRngAdd=C4[a, c]\n=20\n\ CommRngAdd=C4[a___, CommRng=C9[b_], CommRng=C9[-(b_)], c___] :=3D=\n=20\n \ CommRngAdd=C4[a, CommRng=C9[0], c]\n=20\nCommRngAdd=C4[a___, \ CommRng=C9[-(b_)], CommRng=C9[b_], c___] :=3D=\n=20\n CommRngAdd=C4[a, \ CommRng=C9[0], c]\n=20\nCommRngAdd=C4[a___, CommRng=C9[b_], CommRng=C9[c_], \ d___] :=3D=20\n CommRngAdd=C4[a, CommRng=C9[c], CommRng=C9[b], d] /; \ !OrderedQ[{b, =\nc}]\nGlobal`CommRngMult=C4\n\nCommRngMult=C4[a___, \ CommRngMult=C4[b___], c___] :=3D CommRngMult=\n=C4[a, b, c]\n=20\n\ CommRngMult=C4[a_] :=3D a\n=20\nCommRngMult=C4[a___, CommRngAdd=C4[b___], \ c___] :=3D=20\n Apply[CommRngAdd=C4, (CommRngMult=C4[a, #1, c] & ) /@ {b}]\n\ =20\nCommRngMult=C4[a___, CommRng=C9[b_], CommRng=C9[c_], d___] :=3D=20\n \ CommRngMult=C4[a, CommRng=C9[c], CommRng=C9[b], d] /; !OrderedQ[{b,=\n c}]\n\ Global`CommRng=C9"], "3D print", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData["6. Proper Types"], "3D section", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["A. Properly typed Ring"], "3D subsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["Properly Typed Ring From Head Typed Ring."], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "(* I will inherit off of the head Typed Structure =A0Rng=C9 . =\n \ *)\n(* For abbreviation I will prefix symbols by the letter T to indicate=\n \ *)\n(* proper typing. We define the boolean function TypeRngQ to be true =\n \ *)\n(* if it operates on an element of type Rng. eg *)"], "3D input", AspectRatioFixed->True], Cell[TextData[ "ClearAll[TypeRngQ];\nTypeRngQ[( Literal[TRngMult=C4[___]] | TRngMult=C4 | \ Literal[TRngAdd=\n=C4[___]] |\n=09=09=09=09=09TRngAdd=C4 | \ Literal[TRng=C9[___]] | TRng=C9 )]:=3DTru=\ne;\nTypeRngQ[___]:=3DFalse;"], "3D input", AspectRatioFixed->True], Cell[TextData[ "(* Also just Note that\n\n(pat:Pattern)[symb_Symbol,(b:Blanks)[=A0Rng=C9]]:>\ \n=09=09=09=09 =09=09=09PatternTest[pat[symb,b[]],TypeRngQ],\n=09=09=09=09 \ (b:Blanks)[=A0Rng=C9]->PatternTest[b[],TypeRngQ]\n=09=09=09=09 =20\nmay \ look kind of complex but it just takes things like a__=A0Rng=C9 t=\no \ a__?TypeRngQ *)"], "3D input", AspectRatioFixed->True], Cell[TextData[ "\n(* Now inherit the addition. *)\nInheritRules[TRngAdd=C4,\n\ =09=09=09{=A0Rng=C9,=A0RngAdd=C4->TRngAdd=C4,\n=09=09=09=09 \ =A0RngMult=C4->TRngMult=C4,\n=09=09=09=09 \ (pat:Pattern)[symb_Symbol,(b:Blanks)[=A0Rng=C9]]:>\n=09=09=09=09 \ =09=09=09PatternTest[pat[symb,b[]],TypeRngQ],\n=09=09=09=09 \ (b:Blanks)[=A0Rng=C9]->PatternTest[b[],TypeRngQ],\n=09=09=09=09 \ =A0Rng=C9->TRng=C9},StrictInheritance->False]"], "3D input", AspectRatioFixed->True], Cell[TextData[ "(* Now very similarly inherit the multiplication. *)\n\ InheritRules[TRngMult=C4,\n=09=09=09{=A0Rng=C9,=A0RngAdd=C4->TRngAdd=C4,\n\ =09=09=09=09 =A0RngMult=C4->TRngMult=C4,\n=09=09=09=09 \ (pat:Pattern)[symb_Symbol,(b:Blanks)[=A0Rng=C9]]:>\n=09=09=09=09 \ =09=09=09PatternTest[pat[symb,b[]],TypeRngQ],\n=09=09=09=09 \ (b:Blanks)[=A0Rng=C9]->PatternTest[b[],TypeRngQ],\n=09=09=09=09 \ =A0Rng=C9->TRng=C9},StrictInheritance->False]"], "3D input", AspectRatioFixed->True]}, Open]], Cell[TextData["A look at the rules"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["?TRngAdd=C4\n\n?TRngMult=C4\n\n?TypeRngQ"], "3D input", AspectRatioFixed->True], Cell[TextData[ "Global`TRngAdd=C4\n\nTRngAdd=C4[(a___)?TypeRngQ, \ TRngAdd=C4[(b___)?TypeRngQ], (c___)?TypeR=\nngQ] :=3D=20\n TRngAdd=C4[a, b, \ c]\n=20\nTRngMult=C4[(a___)?TypeRngQ, TRngAdd=C4[(b___)?TypeRngQ], \ (c___)?Type=\nRngQ] ^:=3D=20\n Apply[TRngAdd=C4, (TRngMult=C4[a, #1, c] & ) \ /@ {b}]\n=20\nTRngAdd=C4[(a_)?TypeRngQ] :=3D a\n=20\n\ TRngAdd=C4[(a___)?TypeRngQ, TRng=C9[0], (c___)?TypeRngQ] :=3D TRngAdd=\n\ =C4[a, c]\n=20\nTRngAdd=C4[(a___)?TypeRngQ, TRng=C9[b_], TRng=C9[-(b_)], \ (c___)?TypeR=\nngQ] :=3D=20\n TRngAdd=C4[a, TRng=C9[0], c]\n=20\n\ TRngAdd=C4[(a___)?TypeRngQ, TRng=C9[-(b_)], TRng=C9[b_], (c___)?TypeR=\nngQ] \ :=3D=20\n TRngAdd=C4[a, TRng=C9[0], c]\n=20\nTRngAdd=C4[(a___)?TypeRngQ, \ TRng=C9[b_], TRng=C9[c_], (d___)?TypeRngQ=\n] :=3D=20\n TRngAdd=C4[a, \ TRng=C9[c], TRng=C9[b], d] /; !OrderedQ[{b, c}]\nGlobal`TRngMult=C4\n\n\ TRngMult=C4[(a___)?TypeRngQ, TRngMult=C4[(b___)?TypeRngQ], (c___)?Typ=\n\ eRngQ] :=3D=20\n TRngMult=C4[a, b, c]\n=20\nTRngMult=C4[(a_)?TypeRngQ] :=3D \ a\n=20\nTRngMult=C4[(a___)?TypeRngQ, TRngAdd=C4[(b___)?TypeRngQ], \ (c___)?Type=\nRngQ] :=3D=20\n Apply[TRngAdd=C4, (TRngMult=C4[a, #1, c] & ) \ /@ {b}]\nGlobal`TypeRngQ\n\nTypeRngQ[RngMult=C4[___] | RngMult=C4 | \ RngAdd=C4[___] | RngAdd=C4 | =\nRng=C9[___] | Rng=C9] :=3D=20\n True\n=20\n\ TypeRngQ[___] :=3D False"], "3D print", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[TextData["A few simple Calculations=20"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "X=3DTRng=C9[x];Y=3DTRng=C9[y];Z=3DTRng=C9[z];XInv=3DTRng=C9[-x];YInv=\n\ =3DTRng=C9[-y];ZInv=3DTRng=C9[-z];\n\nFormat[TRng=C9[a_]]:=3Da"], "3D input", AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["TRngAdd=C4[X,Y,Z,ZInv,YInv,Z]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData["\<\ TRngAdd=C4[TRng=C9[x], TRng=C9[z]]\ \>", "\<\ TRngAdd=C4[x, z]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData["TRngMult=C4[X,XInv]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData["\<\ TRngMult=C4[TRng=C9[x], TRng=C9[-x]]\ \>", "\<\ TRngMult=C4[x, -x]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData[ "TRngMult=C4[X,TRngAdd=C4[ZInv,X],TRngAdd=C4[X,Y,ZInv],Z]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData[ "\<\ TRngAdd=C4[TRngMult=C4[TRng=C9[x], TRng=C9[x], TRng=C9[x], TRng=C9[z]= ],=20 =20 TRngMult=C4[TRng=C9[x], TRng=C9[x], TRng=C9[y], TRng=C9[z]],=20 =20 TRngMult=C4[TRng=C9[x], TRng=C9[x], TRng=C9[-z], TRng=C9[z]],=20 =20 TRngMult=C4[TRng=C9[x], TRng=C9[-z], TRng=C9[x], TRng=C9[z]],=20 =20 TRngMult=C4[TRng=C9[x], TRng=C9[-z], TRng=C9[y], TRng=C9[z]],=20 =20 TRngMult=C4[TRng=C9[x], TRng=C9[-z], TRng=C9[-z], TRng=C9[z]]]\ \>", "\<\ TRngAdd=C4[TRngMult=C4[x, x, x, z], TRngMult=C4[x, x, y, z], TRngMult= =C4[x, x, -z, z],=20 =20 TRngMult=C4[x, -z, x, z], TRngMult=C4[x, -z, y, z], TRngMult=C4[x, = -z, -z, z]]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[CellGroupData[{Cell[TextData[ "TRngAdd=C4[X,TRngAdd=C4[ZInv,X],TRngAdd=C4[X,Y,ZInv],Z]"], "3D input", AspectRatioFixed->True], Cell[OutputFormData[ "\<\ TRngAdd=C4[TRng=C9[x], TRng=C9[x], TRng=C9[x], TRng=C9[y], TRng=C9[-z= ]]\ \>", "\<\ TRngAdd=C4[x, x, x, y, -z]\ \>"], "3D output", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[TextData["Properly Typed Ring From semi-typed Ring."], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "(* This calls to InheritRules are exactly the same as before except t=\nhat \ *)\n(* (b:Blanks)[=A0Rng=C9] in the lines\n\n\ =09=09(pat:Pattern)[symb_Symbol,(b:Blanks)[=A0Rng=C9]]:>\n=09=09=09=09 \ =09=09PatternTest[pat[symb,b[]],TypeRngQ],\n\ =09=09(b:Blanks)[=A0Rng=C9]->PatternTest[b[],TypeRngQ]\n=09=09\nShould be \ replaced by (b:Blanks)[] as in\n\n\ =09=09(pat:Pattern)[symb_Symbol,(b:Blanks)[]]:>\n=09=09=09=09 \ =09=09PatternTest[pat[symb,b[]],TypeRngQ],\n\ =09=09(b:Blanks)[]->PatternTest[b[],TypeRngQ]\n=09=09\nThis is because we are \ inheriting from the semi-typed structures. I'l=\nl leave *)\n(* it to you to \ copy the above and paste this in. Give it a go. *)\n(* also change the parent \ =A0Rng=C9 to RngAdd=C4 and RngMult=C4 in th=\ne first and *)\n(* second \ call respectively. *)=20"], "3D input", AspectRatioFixed->True]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData["B. Properly typed Group"], "3D subsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "Properly typed group from the head typed group"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData[ "ClearAll[TypeGrpQ];\nTypeGrpQ[( Literal[TGrp=C4[___]] | TGrp=C4 | \ Literal[TGrp=C9[___]] | =\nTGrp=C9 )]:=3DTrue;\nTypeGrpQ[___]:=3DFalse;"], "3D input", AspectRatioFixed->True], Cell[TextData[ "General::spell: Possible spelling error: new symbol name \"TGrp=C4\"\n \ is similar to existing symbols {=A0Grp=C4, Grp=C4}."], "3D message", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "General::spell: Possible spelling error: new symbol name \"TGrp=C9\"\n \ is similar to existing symbols {=A0Grp=C9, Grp=C9, TGrp=C4}."], "3D message", Evaluatable->False, AspectRatioFixed->True]}, Open]], Cell[TextData[ "InheritRules[TGrp=C4,\n=09=09=09{=A0Grp=C9,=A0Grp=C4->TGrp=C4,\n=09=09=09=09 \ (pat:Pattern)[symb_Symbol,(b:Blanks)[=A0Grp=C9]]:>\n=09=09=09=09 \ =09=09=09PatternTest[pat[symb,b[]],TypeGrpQ],\n=09=09=09=09 \ (b:Blanks)[=A0Rng=C9]->PatternTest[b[],TypeGrpQ],\n=09=09=09=09 \ =A0Grp=C9->TGrp=C9},StrictInheritance->False]"], "3D input", AspectRatioFixed->True]}, Open]], Cell[TextData["A look at the rules"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["?TGrp=C4\n\n?TypeGrpQ"], "3D input", AspectRatioFixed->True], Cell[TextData[ "Global`TGrp=C4\n\nTGrp=C4[(a___)?TypeGrpQ, TGrp=C4[(b___)?TypeGrpQ], \ (c___)?TypeGrpQ] :=\n=3D TGrp=C4[a, b, c]\n=20\nTGrp=C4[(a_)?TypeGrpQ] :=3D a\ \n=20\nTGrp=C4[(a___)?TypeGrpQ, TGrp=C9[e], (c___)?TypeGrpQ] :=3D TGrp=C4[a,=\ \n c]\n=20\nTGrp=C4[(a___)?TypeGrpQ, TGrp=C9[(b_)?TypeGrpQ], \ TGrp=C9[(b_)?TypeGrp=\nQ^(-1)],=20\n (c___)?TypeGrpQ] :=3D TGrp=C4[a, \ TGrp=C9[e], c]\n=20\nTGrp=C4[(a___)?TypeGrpQ, TGrp=C9[(b_)?TypeGrpQ^(-1)], \ TGrp=C9[(b_)?Ty=\npeGrpQ],=20\n (c___)?TypeGrpQ] :=3D TGrp=C4[a, \ TGrp=C9[e], c]\nGlobal`TypeGrpQ\n\nTypeGrpQ[TGrp=C4[___] | TGrp=C4 | \ TGrp=C9[___] | TGrp=C9] :=3D True\n=20\nTypeGrpQ[___] :=3D False"], "3D print",\ Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]], Cell[TextData[ "Properly typed group from the semi-typed group"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "ClearAll[TGrp=C4];\nInheritRules[TGrp=C4,\n=09=09=09{Grp=C4,Grp=C4->TGrp=C4,\ \n=09=09=09=09 (pat:Pattern)[symb_Symbol,(b:Blanks)[]]:>\n=09=09=09=09 \ =09=09=09PatternTest[pat[symb,b[]],TypeGrpQ],\n=09=09=09=09 \ (b:Blanks)[]->PatternTest[b[],TypeGrpQ],\n=09=09=09=09 \ Grp=C9->TGrp=C9},StrictInheritance->False]"], "3D input", AspectRatioFixed->True]}, Open]]}, Open]], Cell[CellGroupData[{Cell[TextData[ "C. Properly typed Ring -> Properly typed Commutative Ring Through Exp=\n\ orts."], "3D subsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData["TCommRng"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[TextData[ "ClearAll[TCommRngAdd=C4,TCommRngMult=C4,TypeCommRngQ];"], "3D input", AspectRatioFixed->True], Cell[TextData[ "(* By now this should be trivial. *)\n\n\ Exports[Rng]:=3D{TRngAdd=C4,TRngMult=C4,TRng=C9,TypeRngQ};\n\n(* Now do the \ inheritance as before. *)\n\nInheritExportStructure[CommRng,Rng]"], "3D input",\ AspectRatioFixed->True]}, Open]], Cell[TextData["A look at the Rules"], "3D subsubsection", Evaluatable->False, AspectRatioFixed->True], Cell[CellGroupData[{Cell[TextData[ "?TCommRngAdd=C4\n\n?TCommRngMult=C4\n\n?TypeCommRngQ\n"], "3D input", AspectRatioFixed->True], Cell[TextData[ "Global`TCommRngAdd=C4\n\nTCommRngAdd=C4[(a___)?TypeCommRngQ, \ TCommRngAdd=C4[(b___)?TypeCommRng=\nQ],=20\n (c___)?TypeCommRngQ] :=3D \ TCommRngAdd=C4[a, b, c]\n=20\nTCommRngMult=C4[(a___)?TypeCommRngQ, \ TCommRngAdd=C4[(b___)?TypeCommRn=\ngQ],=20\n (c___)?TypeCommRngQ] ^:=3D \ Apply[TCommRngAdd=C4, (TCommRngMult=\n=C4[a, #1, c] & ) /@ {b}]\n=20\n\ TCommRngAdd=C4[(a_)?TypeCommRngQ] :=3D a\n=20\n\ TCommRngAdd=C4[(a___)?TypeCommRngQ, TCommRng=C9[0], (c___)?TypeCommRn=\ngQ] \ :=3D=20\n TCommRngAdd=C4[a, c]\n=20\nTCommRngAdd=C4[(a___)?TypeCommRngQ, \ TCommRng=C9[b_], TCommRng=C9[-(b_=\n)],=20\n (c___)?TypeCommRngQ] :=3D \ TCommRngAdd=C4[a, TCommRng=C9[0], c]\n=20\n\ TCommRngAdd=C4[(a___)?TypeCommRngQ, TCommRng=C9[-(b_)], TCommRng=C9[b=\n\ _],=20\n (c___)?TypeCommRngQ] :=3D TCommRngAdd=C4[a, TCommRng=C9[0], c]\n\ =20\nTCommRngAdd=C4[(a___)?TypeCommRngQ, TCommRng=C9[b_], TCommRng=C9[c_],=\n\ =20\n (d___)?TypeCommRngQ] :=3D=20\n TCommRngAdd=C4[a, TCommRng=C9[c], \ TCommRng=C9[b], d] /; !OrderedQ[{=\nb, c}]\nGlobal`TCommRngMult=C4\n\n\ TCommRngMult=C4[(a___)?TypeCommRngQ, TCommRngMult=C4[(b___)?TypeCommR=\n\ ngQ],=20\n (c___)?TypeCommRngQ] :=3D TCommRngMult=C4[a, b, c]\n=20\n\ TCommRngMult=C4[(a_)?TypeCommRngQ] :=3D a\n=20\n\ TCommRngMult=C4[(a___)?TypeCommRngQ, TCommRngAdd=C4[(b___)?TypeCommRn=\n\ gQ],=20\n (c___)?TypeCommRngQ] :=3D Apply[TCommRngAdd=C4, \ (TCommRngMult=C4[a=\n, #1, c] & ) /@ {b}]\nGlobal`TypeCommRngQ\n\n\ TypeCommRngQ[TCommRngMult=C4[___] | TCommRngMult=C4 | TCommRngAdd=\n=C4[___] \ |=20\n TCommRngAdd=C4 | TCommRng=C9[___] | TCommRng=C9] :=3D True\n=20\n\ TypeCommRngQ[___] :=3D False"], "3D print", Evaluatable->False, AspectRatioFixed->True]}, Open]]}, Open]]}, Open]] }, FrontEndVersion->"Macintosh 3.0", ScreenRectangle->{{0, 640}, {0, 460}}, WindowToolbars->{}, CellGrouping->Manual, WindowSize->{520, 365}, WindowMargins->{{20, Automatic}, {Automatic, 16}}, PrivateNotebookOptions->{"ColorPalette"->{RGBColor, -1}}, ShowCellLabel->True, ShowCellTags->False, RenderingOptions->{"ObjectDithering"->True, "RasterDithering"->False}, MacintoshSystemPageSetup->"\<\ AVU/IFiQKFD000000V7E<09QgO0000000OZ:d096/NP0AP1Y06`0I@1^0642HMD` 0V7N40000001nXZ`0TJaj000000000000000009QeC0000000000000000000000 00000000000000000000000000000000\>" ] (*********************************************************************** Cached data follows. If you edit this Notebook file directly, not using Mathematica, you must remove the line containing CacheID at the top of the file. The cache data will then be recreated when you save this file from within Mathematica. ***********************************************************************) (*CellTagsOutline CellTagsIndex->{} *) (*CellTagsIndex CellTagsIndex->{} *) (*NotebookFileOutline Notebook[{ Cell[1711, 51, 289, 5, 70, "3D input"], Cell[CellGroupData[{ Cell[2023, 58, 107, 2, 70, "3D section", Evaluatable->False], Cell[2133, 62, 437, 7, 70, "3D input"], Cell[2573, 71, 112, 2, 70, "3D input", InitializationCell->True], Cell[CellGroupData[{ Cell[2708, 75, 101, 2, 70, "3D subsection", Evaluatable->False], Cell[2812, 79, 46, 1, 70, "3D input"] }, Closed]], Cell[CellGroupData[{ Cell[2890, 82, 106, 2, 70, "3D subsection", Evaluatable->False], Cell[2999, 86, 1308, 29, 70, "3D input"] }, Closed]], Cell[CellGroupData[{ Cell[4339, 117, 118, 2, 70, "3D subsection", Evaluatable->False], Cell[4460, 121, 123, 2, 70, "3D subsubsection", Evaluatable->False], Cell[4586, 125, 454, 7, 70, "3D input"] }, Closed]], Cell[5052, 134, 120, 2, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[5195, 138, 365, 6, 70, "3D input"], Cell[5563, 146, 198, 4, 70, "3D message", Evaluatable->False] }, Open ]] }, Closed]], Cell[CellGroupData[{ Cell[5811, 152, 126, 3, 70, "3D section", Evaluatable->False], Cell[5940, 157, 85, 1, 70, "3D input"], Cell[6028, 160, 184, 8, 70, "3D input"], Cell[CellGroupData[{ Cell[6235, 170, 58, 1, 70, "3D input"], Cell[6296, 173, 149, 4, 70, "3D print", Evaluatable->False] }, Open ]], Cell[6457, 179, 86, 1, 70, "3D input"], Cell[CellGroupData[{ Cell[6566, 182, 58, 1, 70, "3D input"], Cell[6627, 185, 149, 4, 70, "3D print", Evaluatable->False] }, Open ]], Cell[6788, 191, 108, 2, 70, "3D input"], Cell[CellGroupData[{ Cell[6919, 195, 58, 1, 70, "3D input"], Cell[6980, 198, 177, 4, 70, "3D print", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[7189, 204, 69, 1, 70, "3D input"], Cell[7261, 207, 629, 10, 70, "3D print", Evaluatable->False] }, Open ]] }, Closed]], Cell[CellGroupData[{ Cell[7931, 219, 114, 2, 70, "3D section", Evaluatable->False], Cell[CellGroupData[{ Cell[8068, 223, 98, 2, 70, "3D subsection", Evaluatable->False, InitializationCell->True], Cell[8169, 227, 1500, 22, 70, "3D input"] }, Closed]], Cell[CellGroupData[{ Cell[9701, 251, 116, 2, 70, "3D subsection", Evaluatable->False], Cell[9820, 255, 1693, 40, 70, "3D input"] }, Closed]], Cell[CellGroupData[{ Cell[11545, 297, 121, 3, 70, "3D subsection", Evaluatable->False, InitializationCell->True], Cell[CellGroupData[{ Cell[11689, 302, 136, 3, 70, "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[CellGroupData[{ Cell[11848, 307, 334, 6, 70, "3D input", InitializationCell->True], Cell[12185, 315, 212, 4, 70, "3D message", Evaluatable->False] }, Open ]] }, Closed]], Cell[CellGroupData[{ Cell[12438, 321, 135, 3, 70, "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[CellGroupData[{ Cell[12596, 326, 252, 5, 70, "3D input", InitializationCell->True], Cell[12851, 333, 203, 4, 70, "3D message", Evaluatable->False] }, Open ]] }, Closed]], Cell[CellGroupData[{ Cell[13095, 339, 137, 3, 70, "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[CellGroupData[{ Cell[13255, 344, 693, 11, 70, "3D input", InitializationCell->True], Cell[13951, 357, 216, 4, 70, "3D message", Evaluatable->False] }, Open ]] }, Closed]], Cell[14188, 363, 115, 2, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[14326, 367, 70, 1, 70, "3D input"], Cell[14399, 370, 400, 7, 70, "3D print", Evaluatable->False] }, Open ]] }, Closed]], Cell[CellGroupData[{ Cell[14840, 379, 122, 2, 70, "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[CellGroupData[{ Cell[14985, 383, 349, 6, 70, "3D input", InitializationCell->True], Cell[15337, 391, 208, 4, 70, "3D message", Evaluatable->False] }, Open ]] }, Closed]], Cell[CellGroupData[{ Cell[15586, 397, 119, 2, 70, "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[CellGroupData[{ Cell[15728, 401, 223, 4, 70, "3D input"], Cell[15954, 407, 210, 4, 70, "3D message", Evaluatable->False] }, Open ]] }, Closed]], Cell[CellGroupData[{ Cell[16205, 413, 92, 2, 70, "3D subsection", Evaluatable->False], Cell[CellGroupData[{ Cell[16320, 417, 93, 2, 70, "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[16416, 421, 254, 5, 70, "3D input", InitializationCell->True], Cell[CellGroupData[{ Cell[16693, 428, 274, 6, 70, "3D input", InitializationCell->True], Cell[16970, 436, 208, 4, 70, "3D message", Evaluatable->False] }, Open ]] }, Closed]], Cell[CellGroupData[{ Cell[17219, 442, 117, 2, 70, "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[CellGroupData[{ Cell[17359, 446, 94, 2, 70, "3D input", InitializationCell->True], Cell[17456, 450, 612, 11, 70, "3D print", Evaluatable->False, InitializationCell->True] }, Open ]], Cell[18080, 463, 114, 2, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[18217, 467, 94, 1, 70, "3D input"], Cell[18314, 470, 240, 9, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[18586, 481, 103, 1, 70, "3D input"], Cell[18692, 484, 209, 8, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[18933, 494, 97, 1, 70, "3D input"], Cell[19033, 497, 130, 7, 70, "3D output", Evaluatable->False] }, Open ]] }, Closed]], Cell[CellGroupData[{ Cell[19204, 506, 105, 2, 70, "3D subsection", Evaluatable->False], Cell[19312, 510, 103, 2, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[19438, 514, 381, 7, 70, "3D input"], Cell[19822, 523, 216, 4, 70, "3D message", Evaluatable->False] }, Open ]] }, Closed]], Cell[20059, 529, 115, 2, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[20197, 533, 70, 1, 70, "3D input"], Cell[20270, 536, 917, 14, 70, "3D print", Evaluatable->False] }, Open ]] }, Closed]], Cell[21208, 552, 114, 2, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[21345, 556, 125, 3, 70, "3D input"], Cell[21473, 561, 243, 9, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[21748, 572, 166, 3, 70, "3D input"], Cell[21917, 577, 243, 9, 70, "3D output", Evaluatable->False] }, Open ]] }, Closed]], Cell[CellGroupData[{ Cell[22201, 588, 118, 3, 70, "3D subsection", Evaluatable->False], Cell[22322, 593, 90, 2, 70, "3D subsubsection", Evaluatable->False], Cell[22415, 597, 719, 11, 70, "3D input"] }, Closed]], Cell[23146, 610, 115, 2, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[23284, 614, 66, 1, 70, "3D input"], Cell[23353, 617, 1106, 16, 70, "3D print", Evaluatable->False] }, Open ]], Cell[24480, 635, 114, 2, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[24617, 639, 209, 4, 70, "3D input"], Cell[24829, 645, 195, 4, 70, "3D message", Evaluatable->False], Cell[25027, 651, 199, 4, 70, "3D message", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[25258, 657, 87, 1, 70, "3D input"], Cell[25348, 660, 164, 7, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[25544, 669, 76, 1, 70, "3D input"], Cell[25623, 672, 118, 6, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[25773, 680, 77, 1, 70, "3D input"], Cell[25853, 683, 168, 7, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[26053, 692, 97, 1, 70, "3D input"], Cell[26153, 695, 391, 13, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[26594, 710, 120, 2, 70, "3D section", Evaluatable->False], Cell[CellGroupData[{ Cell[26737, 714, 94, 2, 70, "3D subsection", Evaluatable->False], Cell[26834, 718, 2886, 69, 70, "3D input"] }, Closed]], Cell[CellGroupData[{ Cell[29752, 789, 95, 2, 70, "3D subsection", Evaluatable->False], Cell[29850, 793, 1974, 26, 70, "3D input"] }, Closed]] }, Closed]], Cell[CellGroupData[{ Cell[31865, 821, 116, 2, 70, "3D section", Evaluatable->False], Cell[CellGroupData[{ Cell[32004, 825, 117, 2, 70, "3D subsection", Evaluatable->False], Cell[32124, 829, 175, 3, 70, "3D input"] }, Closed]], Cell[CellGroupData[{ Cell[32331, 834, 151, 3, 70, "3D subsection", Evaluatable->False, InitializationCell->True], Cell[CellGroupData[{ Cell[32505, 839, 141, 3, 70, "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[32649, 844, 1203, 38, 70, "3D input", InitializationCell->True], Cell[CellGroupData[{ Cell[33875, 884, 65, 1, 70, "3D input"], Cell[33943, 887, 185, 4, 70, "3D print", Evaluatable->False] }, Open ]] }, Closed]], Cell[CellGroupData[{ Cell[34169, 893, 149, 4, 70, "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[34321, 899, 125, 2, 70, "3D input", InitializationCell->True] }, Closed]], Cell[CellGroupData[{ Cell[34478, 903, 151, 4, 70, "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[34632, 909, 219, 5, 70, "3D input", InitializationCell->True], Cell[34854, 916, 93, 1, 70, "3D input"], Cell[34950, 919, 310, 6, 70, "3D input", InitializationCell->True] }, Closed]], Cell[CellGroupData[{ Cell[35292, 927, 122, 2, 70, "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[35417, 931, 238, 5, 70, "3D input", InitializationCell->True] }, Closed]], Cell[CellGroupData[{ Cell[35687, 938, 119, 2, 70, "3D subsubsection", Evaluatable->False, InitializationCell->True], Cell[35809, 942, 179, 4, 70, "3D input"] }, Closed]] }, Closed]], Cell[CellGroupData[{ Cell[36029, 948, 135, 3, 70, "3D subsection", Evaluatable->False], Cell[36167, 953, 93, 2, 70, "3D subsubsection", Evaluatable->False], Cell[36263, 957, 666, 10, 70, "3D input"] }, Closed]], Cell[36941, 969, 110, 2, 70, "3D subsubsection", Evaluatable->False], Cell[37054, 973, 150, 3, 70, "3D input"], Cell[37207, 978, 208, 4, 70, "3D input"], Cell[37418, 984, 294, 5, 70, "3D input"], Cell[37715, 991, 247, 4, 70, "3D input"] }, Closed]], Cell[37974, 997, 113, 2, 70, "3D subsubsection", Evaluatable->False], Cell[38090, 1001, 115, 2, 70, "3D input"], Cell[CellGroupData[{ Cell[38228, 1005, 63, 1, 70, "3D input"], Cell[38294, 1008, 347, 6, 70, "3D print", Evaluatable->False] }, Open ]], Cell[38653, 1016, 379, 6, 70, "3D input"], Cell[39044, 1024, 130, 3, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[39197, 1029, 260, 5, 70, "3D input"], Cell[39460, 1036, 976, 14, 70, "3D print", Evaluatable->False] }, Open ]], Cell[40448, 1052, 237, 4, 70, "3D input"], Cell[40697, 1058, 114, 2, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[40834, 1062, 75, 1, 70, "3D input"], Cell[40912, 1065, 142, 7, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[41086, 1074, 86, 1, 70, "3D input"], Cell[41175, 1077, 142, 7, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[41349, 1086, 78, 1, 70, "3D input"], Cell[41430, 1089, 107, 6, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[41578, 1097, 129, 3, 70, "3D subsection", Evaluatable->False], Cell[41710, 1102, 103, 1, 70, "3D input"], Cell[41816, 1105, 102, 2, 70, "3D subsubsection", Evaluatable->False], Cell[41921, 1109, 128, 3, 70, "3D input"], Cell[42052, 1114, 211, 4, 70, "3D input"], Cell[42266, 1120, 176, 3, 70, "3D input"], Cell[42445, 1125, 249, 4, 70, "3D input"] }, Closed]], Cell[42706, 1131, 116, 2, 70, "3D subsubsection", Evaluatable->False], Cell[42825, 1135, 115, 2, 70, "3D input"], Cell[CellGroupData[{ Cell[42963, 1139, 63, 1, 70, "3D input"], Cell[43029, 1142, 411, 7, 70, "3D print", Evaluatable->False] }, Open ]], Cell[43452, 1151, 208, 4, 70, "3D input"], Cell[43672, 1157, 114, 2, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[43809, 1161, 85, 1, 70, "3D input"], Cell[43897, 1164, 207, 8, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[44136, 1174, 96, 1, 70, "3D input"], Cell[44235, 1177, 207, 8, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[44474, 1187, 88, 1, 70, "3D input"], Cell[44565, 1190, 123, 6, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[44729, 1198, 122, 2, 70, "3D subsection", Evaluatable->False], Cell[44854, 1202, 103, 2, 70, "3D subsubsection", Evaluatable->False], Cell[44960, 1206, 271, 5, 70, "3D input"] }, Closed]], Cell[45243, 1213, 115, 2, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[45381, 1217, 67, 1, 70, "3D input"], Cell[45451, 1220, 484, 8, 70, "3D print", Evaluatable->False] }, Open ]], Cell[45956, 1230, 114, 2, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[46093, 1234, 77, 1, 70, "3D input"], Cell[46173, 1237, 144, 7, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[46349, 1246, 87, 1, 70, "3D input"], Cell[46439, 1249, 144, 7, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[46615, 1258, 93, 1, 70, "3D input"], Cell[46711, 1261, 144, 7, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[46896, 1270, 116, 2, 70, "3D subsection", Evaluatable->False], Cell[47015, 1274, 103, 2, 70, "3D subsubsection", Evaluatable->False], Cell[47121, 1278, 281, 5, 70, "3D input"] }, Closed]], Cell[47414, 1285, 115, 2, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[47552, 1289, 67, 1, 70, "3D input"], Cell[47622, 1292, 632, 11, 70, "3D print", Evaluatable->False] }, Open ]], Cell[48275, 1305, 114, 2, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[48412, 1309, 91, 1, 70, "3D input"], Cell[48506, 1312, 220, 9, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[48758, 1323, 100, 1, 70, "3D input"], Cell[48861, 1326, 220, 9, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[49113, 1337, 107, 2, 70, "3D input"], Cell[49223, 1341, 220, 9, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[49484, 1352, 135, 3, 70, "3D subsection", Evaluatable->False], Cell[49622, 1357, 137, 3, 70, "3D subsubsection", Evaluatable->False], Cell[49762, 1362, 864, 12, 70, "3D input"], Cell[50629, 1376, 87, 1, 70, "3D input"], Cell[50719, 1379, 194, 4, 70, "3D input"], Cell[50916, 1385, 147, 3, 70, "3D input"], Cell[51066, 1390, 268, 5, 70, "3D input"] }, Closed]], Cell[51346, 1397, 116, 2, 70, "3D subsubsection", Evaluatable->False], Cell[51465, 1401, 114, 2, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[51602, 1405, 80, 1, 70, "3D input"], Cell[51685, 1408, 164, 7, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[51881, 1417, 72, 1, 70, "3D input"], Cell[51956, 1420, 140, 7, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[52128, 1429, 105, 1, 70, "3D input"], Cell[52236, 1432, 449, 16, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[52717, 1450, 104, 1, 70, "3D input"], Cell[52824, 1453, 170, 7, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[53035, 1462, 129, 3, 70, "3D subsection", Evaluatable->False], Cell[53167, 1467, 132, 3, 70, "3D subsubsection", Evaluatable->False], Cell[53302, 1472, 864, 12, 70, "3D input"], Cell[54169, 1486, 87, 1, 70, "3D input"], Cell[54259, 1489, 192, 4, 70, "3D input"], Cell[54454, 1495, 148, 3, 70, "3D input"], Cell[54605, 1500, 268, 5, 70, "3D input"] }, Closed]], Cell[54885, 1507, 116, 2, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[55024, 1511, 81, 1, 70, "3D input"], Cell[55108, 1514, 789, 12, 70, "3D print", Evaluatable->False] }, Open ]], Cell[55918, 1528, 114, 2, 70, "3D subsubsection", Evaluatable->False], Cell[56035, 1532, 185, 3, 70, "3D input"], Cell[CellGroupData[{ Cell[56243, 1537, 84, 1, 70, "3D input"], Cell[56330, 1540, 152, 7, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[56514, 1549, 74, 1, 70, "3D input"], Cell[56591, 1552, 156, 7, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[56779, 1561, 110, 2, 70, "3D input"], Cell[56892, 1565, 675, 23, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[57599, 1590, 109, 2, 70, "3D input"], Cell[57711, 1594, 197, 8, 70, "3D output", Evaluatable->False] }, Open ]], Cell[57920, 1604, 132, 3, 70, "3D subsubsection", Evaluatable->False], Cell[58055, 1609, 735, 10, 70, "3D input"], Cell[58793, 1621, 141, 3, 70, "3D input"], Cell[58937, 1626, 312, 5, 70, "3D input"], Cell[59252, 1633, 336, 6, 70, "3D input"], Cell[59591, 1641, 155, 3, 70, "3D input"], Cell[59758, 1646, 131, 3, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[59912, 1651, 81, 1, 70, "3D input"], Cell[59996, 1654, 789, 12, 70, "3D print", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[60826, 1668, 133, 3, 70, "3D subsection", Evaluatable->False], Cell[60962, 1673, 91, 2, 70, "3D subsubsection", Evaluatable->False], Cell[61056, 1677, 251, 4, 70, "3D input"], Cell[61310, 1683, 138, 3, 70, "3D input"], Cell[61451, 1688, 152, 3, 70, "3D input"], Cell[61606, 1693, 402, 6, 70, "3D input"] }, Closed]], Cell[62020, 1701, 115, 2, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[62158, 1705, 85, 1, 70, "3D input"], Cell[62246, 1708, 992, 15, 70, "3D print", Evaluatable->False] }, Closed]], Cell[63259, 1725, 114, 2, 70, "3D subsubsection", Evaluatable->False], Cell[63376, 1729, 222, 4, 70, "3D input"], Cell[CellGroupData[{ Cell[63621, 1735, 93, 1, 70, "3D input"], Cell[63717, 1738, 207, 8, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[63956, 1748, 76, 1, 70, "3D input"], Cell[64035, 1751, 184, 7, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[64251, 1760, 75, 1, 70, "3D input"], Cell[64329, 1763, 127, 6, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[64488, 1771, 116, 2, 70, "3D input"], Cell[64607, 1775, 394, 15, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[65033, 1792, 115, 2, 70, "3D input"], Cell[65151, 1796, 265, 10, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[65466, 1808, 109, 2, 70, "3D section", Evaluatable->False], Cell[CellGroupData[{ Cell[65598, 1812, 93, 2, 70, "3D subsection", Evaluatable->False], Cell[65694, 1816, 619, 9, 70, "3D input"] }, Closed]], Cell[CellGroupData[{ Cell[66345, 1827, 106, 2, 70, "3D subsection", Evaluatable->False], Cell[66454, 1831, 364, 6, 70, "3D input"], Cell[66821, 1839, 162, 3, 70, "3D input"], Cell[66986, 1844, 508, 7, 70, "3D input"], Cell[CellGroupData[{ Cell[67517, 1853, 366, 6, 70, "3D input"], Cell[67886, 1861, 132, 7, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[68050, 1870, 134, 3, 70, "3D input"], Cell[68187, 1875, 213, 4, 70, "3D message", Evaluatable->False], Cell[68403, 1881, 207, 4, 70, "3D message", Evaluatable->False], Cell[68613, 1887, 238, 9, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[68883, 1898, 170, 3, 70, "3D input"], Cell[69056, 1903, 373, 14, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[69461, 1919, 292, 5, 70, "3D input"], Cell[69756, 1926, 568, 21, 70, "3D output", Evaluatable->False] }, Closed]], Cell[CellGroupData[{ Cell[70356, 1949, 136, 3, 70, "3D subsection", Evaluatable->False], Cell[70495, 1954, 816, 12, 70, "3D input"] }, Closed]], Cell[CellGroupData[{ Cell[71343, 1968, 119, 2, 70, "3D subsection", Evaluatable->False], Cell[71465, 1972, 101, 2, 70, "3D subsubsection", Evaluatable->False], Cell[71569, 1976, 105, 1, 70, "3D input"], Cell[71677, 1979, 127, 3, 70, "3D input"], Cell[71807, 1984, 91, 1, 70, "3D input"], Cell[71901, 1987, 179, 4, 70, "3D input"] }, Closed]], Cell[CellGroupData[{ Cell[72112, 1993, 95, 2, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[72230, 1997, 104, 1, 70, "3D input"], Cell[72337, 2000, 1125, 17, 70, "3D print", Evaluatable->False] }, Open ]] }, Open ]] }, Closed]], Cell[CellGroupData[{ Cell[73512, 2019, 95, 2, 70, "3D section", Evaluatable->False], Cell[CellGroupData[{ Cell[73630, 2023, 105, 2, 70, "3D subsection", Evaluatable->False], Cell[CellGroupData[{ Cell[73758, 2027, 127, 2, 70, "3D subsubsection", Evaluatable->False], Cell[73888, 2031, 348, 5, 70, "3D input"], Cell[74239, 2038, 269, 5, 70, "3D input"], Cell[74511, 2045, 378, 6, 70, "3D input"], Cell[74892, 2053, 476, 8, 70, "3D input"], Cell[75371, 2063, 496, 8, 70, "3D input"] }, Open ]], Cell[75879, 2073, 105, 2, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[76007, 2077, 96, 1, 70, "3D input"], Cell[76106, 2080, 1401, 21, 70, "3D print", Evaluatable->False] }, Open ]] }, Open ]], Cell[77528, 2103, 114, 2, 70, "3D subsubsection", Evaluatable->False], Cell[77645, 2107, 192, 3, 70, "3D input"], Cell[CellGroupData[{ Cell[77860, 2112, 85, 1, 70, "3D input"], Cell[77948, 2115, 156, 7, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[78136, 2124, 75, 1, 70, "3D input"], Cell[78214, 2127, 160, 7, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[78406, 2136, 113, 2, 70, "3D input"], Cell[78522, 2140, 713, 23, 70, "3D output", Evaluatable->False] }, Open ]], Cell[CellGroupData[{ Cell[79267, 2165, 112, 2, 70, "3D input"], Cell[79382, 2169, 205, 8, 70, "3D output", Evaluatable->False] }, Open ]], Cell[79599, 2179, 127, 2, 70, "3D subsubsection", Evaluatable->False], Cell[79729, 2183, 868, 14, 70, "3D input"] }, Closed]] }, Closed]], Cell[CellGroupData[{ Cell[80638, 2199, 106, 2, 70, "3D subsection", Evaluatable->False], Cell[80747, 2203, 133, 3, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[80903, 2208, 199, 4, 70, "3D input"], Cell[81105, 2214, 209, 4, 70, "3D message", Evaluatable->False], Cell[81317, 2220, 218, 4, 70, "3D message", Evaluatable->False] }, Open ]], Cell[81547, 2226, 384, 6, 70, "3D input"] }, Open ]], Cell[81943, 2234, 105, 2, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[82071, 2238, 77, 1, 70, "3D input"], Cell[82151, 2241, 728, 12, 70, "3D print", Evaluatable->False] }, Open ]], Cell[82900, 2255, 133, 3, 70, "3D subsubsection", Evaluatable->False], Cell[83036, 2260, 377, 6, 70, "3D input"], Cell[CellGroupData[{ Cell[83454, 2268, 163, 4, 70, "3D subsection", Evaluatable->False], Cell[CellGroupData[{ Cell[83640, 2274, 94, 2, 70, "3D subsubsection", Evaluatable->False], Cell[83737, 2278, 111, 2, 70, "3D input"], Cell[83851, 2282, 243, 5, 70, "3D input"] }, Open ]], Cell[84106, 2289, 105, 2, 70, "3D subsubsection", Evaluatable->False], Cell[CellGroupData[{ Cell[84234, 2293, 111, 2, 70, "3D input"], Cell[84348, 2297, 1719, 26, 70, "3D print", Evaluatable->False] }, Closed]] }, Closed]] } ] *) (*********************************************************************** End of Mathematica Notebook file. ***********************************************************************)