From 392858574744fae69b7510a18c53836762256ca7 Mon Sep 17 00:00:00 2001 From: Gerd Heber Date: Fri, 12 Feb 2016 21:33:35 -0500 Subject: [PATCH] First draft of Chapter 1 as Jupyter notebook. --- examples/Chapter1.ipynb | 932 ++++++++++++++++++++-------------------- 1 file changed, 457 insertions(+), 475 deletions(-) diff --git a/examples/Chapter1.ipynb b/examples/Chapter1.ipynb index 0d0d181..441db96 100644 --- a/examples/Chapter1.ipynb +++ b/examples/Chapter1.ipynb @@ -117,7 +117,7 @@ "2. $k=-1$. If $(C_p,d_p)=(C'_p,d'_p)$ and $f_p=d_p$, then $f$ is the *differential* of the chain complex $(C_p,d_p)$ and, in fact, this differential is implemented in the ${\\tt Kenzo}$ program as a morphism of degree $-1$.\n", "3. $k=+1$. In this case, $f$ is usually a *homotopy operator*, that is, some relation $$d'_{p+1}\\circ f_p+f_{p-1}\\circ d_p=g_p-g'_p$$ is satisfied for two (ordinary) chain complex morphisms $g$ and $g'$.\n", "\n", - "For technical reasons, these three types of morphisms have been implemented in the $\\texttt{Kenzo}$ program\n", + "For technical reasons, these three types of morphisms have been implemented in the `Kenzo` program\n", "in a unique type.\n", "\n", "\n", @@ -137,7 +137,7 @@ "data": { "image/png": "iVBORw0KGgoAAAANSUhEUgAAAj0AAAD5CAYAAADMd4SKAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAACh1SURBVHhe7d0LkFZlHcfxB8UL4zXNdIwIgUlNnbyPl10kdVzM+wyjLFqhKQZYluGik5YllUs2XlJINKGpWHSYvOdCyiQgGmrmJTVjsVHSNK+paSoSv2fPf3n27Hn3Avteznm+n5m3c3tfzXfPe87/PM/vPGfAmrUcAABAwW2UTAEAAAqNogcAAESBogcAAESBogcAAESBogcAAESBogcAAESBogcAAESBogcAAESBogcAAESBogcAAESBogcAAESBogcAAESBogcAAESBogcAAESBogcAAESBogcAAESBogcAAESBogcAAESBogcAAESBogcAAESBoicSS5cudQMGDOh4jR49OtnS2bx58/z2SZMmJW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8Xco2J99wIAB7lOf+pS76667XGtrqzv//PP9+n333ddde+217qCDDvLLAFCLPvzwQ/fYY4+5v/zlL52mb7/9tt++9957uwsuuMB3X2n6xhtv+OOfWnfC4x8FTxwoeiKkWzhvvPFGP3/GGWd0atLVldHkyZPdn//8Z7/805/+1E2ZMsXPA0C1vfzyyx2FjRU5Tz31VLK1q/POO88df/zxyZJzL730kmtsbPTzK1eupEsrMhQ9kTr99NP9dPbs2X6api6un//8537+xBNPdNdcc4379Kc/7ZcBoBreeecd19zc7I9H1h3fnf3228/97Gc/S5bWGTVqlJ9y+osPQeYIPfHEE37sCr00n+Xqq692N910k38uza233ur22Wcfd/PNNydbAaDyttxyS3fppZe6Rx55xF155ZXuiCOOSLZ0pRzPqaeemiwB7Sh6IqT+6+eff96/NF/KySef7JuO1dLz73//251yyinu3HPPTbYCQHUMGzbMH4vuueeeTl1XoaOPPtpnE4EQRU9kNPhWWOhovrsBudSldcstt/hsj6gFSE3Gyv4AQLU88MAD/lh0++23J2vWUbGjogdIo+iJjIqcpUuXJkvOz3fX2mMUZtZBRgcThZwPPvhgd/nllydbAaBydOw55JBD/LFojz32cJdcckmyxfnhN770pS/57i0gjaInMlkFTm+KHtHt6+pL/8Y3vuGXdXv7SSed5P75z3/6ZQAoJx1rdMyxoTV0F5aG1lDm0KjgOfLII5MloDOKnoiUatVJt/70hJAzgErTMUZj7uiYs9122/lA89lnn+23bb311m6rrbbyt5/TrYXuUPRERMVNVn4nnfPpjWqGnOfNm+cHFbPXpEmTki2dTZ8+3W/XNKSxOXrzeQC1QUNo6Bjz6quv+ju2Zs2a5err65Ot7YOsamRltQLttttuyVqgK4qeSPR0p5a26T19UY2Qs1qkbGAxM3PmzC6FzejRo93UqVOTpc6GDx+ezLXL+jyA6rOwso0Zpguriy++2Lcypx144IEl7+QCDEVPJMIxebbddls/FZu3sXvWRyVDznPnzvXTlpYWP7DYkiVL/HL4/11XfQsWLOhS3IhaiWTixIn+8/rnyPr+twMoj3RYWRcnask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c5YVBZV9paZ9QFphYhAACKhKIHAABEgUwPAACIAkUPAACIAkUPAACIAkUPAACIAkUPAACIAkUPAACIAkUPAACIAkUPAACIAkUPAACIAkUPAACIAkUPAACIAkUPAACIAkUPAACIAkUPAACIAkUPAACIAkUPAACIAkUPAACIAkUPAACIAkUPAACIAkUPAACIAkUPAACIAkUPAACIAkUPAACIgHP/B7khz1wG257bAAAAAElFTkSuQmCC", "text/plain": [ - "#" + "#" ] }, "execution_count": 4, @@ -183,14 +183,14 @@ "```\n", "A number of macros, functions and methods have been defined on usual sets (symbols, numbers, lists, etc.) taking their value in the set `[:less, :equal, :greater]`. Of course, the user may define its own function for a particular case. There exists functions to compare various couples of usual items:\n", "\n", - "> *Function* `(f-cmpr n1 n2)`\n", - ">> Return `:less`, `:equal`, `:greater`, according to the result of the canonical comparison of both integers `n1` and `n2`.\n", + "`(f-cmpr n1 n2)` *[Function]* \n", + "> Return `:less`, `:equal`, `:greater`, according to the result of the canonical comparison of both integers `n1` and `n2`.\n", "\n", - "> *Function* `(s-cmpr symbol1 symbol2)`\n", - ">> Return `:less`, `:equal`, `:greater`, according to the result of the lisp comparison functions on the strings `(symbol-name symbol1)` and `(symbol-name symbol2)`\n", + "`(s-cmpr symbol1 symbol2)` *[Function]* \n", + "> Return `:less`, `:equal`, `:greater`, according to the result of the lisp comparison functions on the strings `(symbol-name symbol1)` and `(symbol-name symbol2)`\n", "\n", - "> *Function* `(l-cmpr list1 list2)`\n", - ">> Return `:less`, `:equal`, `:greater`, according to the lexicographical ordering of the two lists `list1`\n", + "`(l-cmpr list1 list2)` *[Function]* \n", + "> Return `:less`, `:equal`, `:greater`, according to the lexicographical ordering of the two lists `list1`\n", "and `list2` representing legal generators in this implementation.\n", "\n", "#### Examples" @@ -292,51 +292,51 @@ "\n", "The software provides a set of functions, methods, and macros to create or modify combinations.\n", "\n", - "> *Macro* `(term-cmbn dgr cf gnr)`\n", - ">> Construct the combination of degree `dgr` with unique term `cf * gnr`.\n", + "`(term-cmbn dgr cf gnr)` *[Macro]* \n", + "> Construct the combination of degree `dgr` with unique term `cf * gnr`.\n", "\n", - "> *Function* `(cmbn dgr cf1 gnr1 cf2 gnr2 ... cfn gnrn)`\n", - ">> Construct a combination of degree `dgr`, sum of the terms $cf_i * gnr_i$. The sequence of pairs $\\lbrace cf_i\\ gnr_i\\rbrace$ has an undefinite length and may be void. In this case, the combination is a null combination of degree `dgr`. \n", + "`(cmbn dgr cf1 gnr1 cf2 gnr2 ... cfn gnrn)` *[Function]* \n", + "> Construct a combination of degree `dgr`, sum of the terms $cf_i * gnr_i$. The sequence of pairs $\\lbrace cf_i\\ gnr_i\\rbrace$ has an undefinite length and may be void. In this case, the combination is a null combination of degree `dgr`. \n", "\n", - "> *Function* `(cmbn-p object)`\n", - ">> Test is `object` is a legal combination.\n", + "`(cmbn-p object)` *[Function]* \n", + "> Test is `object` is a legal combination.\n", "\n", - "> *Macro* `(cmbn-degr cmbn)\n", - ">> Get the degree (an integer) of the combination `cmbn`.\n", + "`(cmbn-degr cmbn)` *[Macro]* \n", + "> Get the degree (an integer) of the combination `cmbn`.\n", "\n", - "> *Macro* `(cmbn-list cmbn)`\n", - ">> Get the list of the terms of the combination `cmbn`. Beware: a term is not a `Kenzo` object. One may select the coefficient (an integer) or the generator - a `Kenzo` object - respectively by the macros `cffc` and `gnrt`.\n", + "`(cmbn-list cmbn)` *[Macro]* \n", + "> Get the list of the terms of the combination `cmbn`. Beware: a term is not a `Kenzo` object. One may select the coefficient (an integer) or the generator - a `Kenzo` object - respectively by the macros `cffc` and `gnrt`.\n", "\n", - "> *Function* `(zero-cmbn dgr)`\n", - ">> Create an instance of a null combination in the degree `dgr`.\n", + "`(zero-cmbn dgr)` *[Function]* \n", + "> Create an instance of a null combination in the degree `dgr`.\n", "\n", - "> *Function* `(zero-pure-dffr cmbn)`\n", - ">> Create a null combination of degree $degr(cmbn) - 1$.\n", + "`(zero-pure-dffr cmbn)` *[Function]* \n", + "> Create a null combination of degree $degr(cmbn) - 1$.\n", "\n", - "> *Macro* `(cmbn-zero-p cmbn)`\n", - ">> Test if `cmbn` is a null combination in any degree.\n", + "`(cmbn-zero-p cmbn)` *[Macro]* \n", + "> Test if `cmbn` is a null combination in any degree.\n", "\n", - "> *Macro* `(cmbn-non-zero-p cmbn)`\n", - ">> Test if `cmbn` is a non-null combination in any degree.\n", + "`(cmbn-non-zero-p cmbn)` *[Macro]* \n", + "> Test if `cmbn` is a non-null combination in any degree.\n", "\n", - "> *Function* `(cmbn-opps cmbn)`\n", - ">> Create a combination opposite to `cmbn`.\n", + "`(cmbn-opps cmbn)` *[Function]*\n", + "> Create a combination opposite to `cmbn`.\n", "\n", - "> *Function* `(n-cmbn n cmbn)`\n", - ">> Create a combination multiple of `cmbn` by the factor `n`.\n", + "`(n-cmbn n cmbn)` *[Function]* \n", + "> Create a combination multiple of `cmbn` by the factor `n`.\n", "\n", - "> *Function* `(2cmbn-add cmpr cmbn1 cmbn2)`\n", - ">> Create a combination, sum of both combinations `cmbn1` and `cmbn2`. The first argument, `cmpr`, must be a function or macro relevant to compare the generators of the involved combinations, in order to return an ordered combination.\n", + "`(2cmbn-add cmpr cmbn1 cmbn2)` *[Function]*\n", + "> Create a combination, sum of both combinations `cmbn1` and `cmbn2`. The first argument, `cmpr`, must be a function or macro relevant to compare the generators of the involved combinations, in order to return an ordered combination.\n", "\n", - "> *Function* `(ncmbn-add cmpr cmbn1 cmbn2 ... cmbnk)`\n", - ">> Create a combination, sum of the indefinite number of combinations $cmbn_i$. As to the first argument, `cmpr`, see the function `2cmbn-add`.\n", + "`(ncmbn-add cmpr cmbn1 cmbn2 ... cmbnk)` *[Function]* \n", + "> Create a combination, sum of the indefinite number of combinations $cmbn_i$. As to the first argument, `cmpr`, see the function `2cmbn-add`.\n", "\n", - "> *Function* `(2n-2cmbn cmpr n1 cmbn1 n2 cmbn2)`\n", - ">> Build the combination `n1 * cmbn1 + n2 * cmbn2`. Both integers `n1` and `n2` must be\n", + "`(2n-2cmbn cmpr n1 cmbn1 n2 cmbn2)` *[Function]* \n", + "> Build the combination `n1 * cmbn1 + n2 * cmbn2`. Both integers `n1` and `n2` must be\n", "non null. As to the first argument, `cmpr`, see the function `2cmbn-add`.\n", "\n", - "> *Function* `(2cmbn-sbtr cmpr cmbn1 cmbn2)`\n", - ">> Create a combination, difference of `cmbn1` and `cmbn2`. As to the first argument, `cmpr`, see the function `2cmbn-add`.\n", + "`(2cmbn-sbtr cmpr cmbn1 cmbn2)` *[Function]* \n", + "> Create a combination, difference of `cmbn1` and `cmbn2`. As to the first argument, `cmpr`, see the function `2cmbn-add`.\n", "\n", "#### Examples" ] @@ -725,7 +725,7 @@ { "data": { "text/plain": [ - "#" + "#" ] }, "execution_count": 21, @@ -792,7 +792,7 @@ { "data": { "text/plain": [ - "#" + "#" ] }, "execution_count": 23, @@ -910,23 +910,23 @@ "\n", "### Simple functions handling chain complexes\n", "\n", - "> *Function* `(cat-init)`\n", - ">> Clear among others, the list `*chcm-list*`, list of user created chain complexes and reset the global counter to 1. The existing objects and in particular here the chain complexes, are not destroyed but they will not enter any more in account during the search process for duplicated objects. This remark is general for the other types of objects saved in specific lists. \n", + "`(cat-init)` *[Function]*\n", + "> Clear among others, the list `*chcm-list*`, list of user created chain complexes and reset the global counter to 1. The existing objects and in particular here the chain complexes, are not destroyed but they will not enter any more in account during the search process for duplicated objects. This remark is general for the other types of objects saved in specific lists. \n", "\n", - "> *Functions* `(chcm n)`\n", - ">> Return from the list `*chcm-list*` the chain complex instance whose the Kenzo identification is `n`; if it does not exist, return `NIL`.\n", + "`(chcm n)` *[Function]*\n", + "> Return from the list `*chcm-list*` the chain complex instance whose the Kenzo identification is `n`; if it does not exist, return `NIL`.\n", "\n", - "> *Macro* `(cmpr object item1 item2)`\n", - ">> Apply the comparison function associated to the chain complex `object` to the two generators `item1` and `item2`.\n", + "`(cmpr object item1 item2)` *[Macro]*\n", + "> Apply the comparison function associated to the chain complex `object` to the two generators `item1` and `item2`.\n", "\n", - "> *Macro* `(basis object n :dgnr)\n", - ">> With only one argument (`object`), get the function attached to the slot `basis` of the chain complex object. With two arguments, get the distinguished basis of the group of degree `n` in the chain complex `object`. If the chain complex is locally effective, this function returns an error because, in some degrees, the corresponding set of generators is probably infinite. With a third argument, the keyword `:dgnr`, get also the *degenerate* elements of the basis in degree `n`.\n", + "`(basis object n :dgnr)` *[Macro]*\n", + "> With only one argument (`object`), get the function attached to the slot `basis` of the chain complex object. With two arguments, get the distinguished basis of the group of degree `n` in the chain complex `object`. If the chain complex is locally effective, this function returns an error because, in some degrees, the corresponding set of generators is probably infinite. With a third argument, the keyword `:dgnr`, get also the *degenerate* elements of the basis in degree `n`.\n", "\n", - "> *Macro* `(dffr chcm &rest)`\n", - ">> Versatile macro to apply the differential morphism of the chain complex `chcm` either to a combination or a generator with a degree, respectively `(dffr chcm cmbn)` or `(dffr chcm degr gnrt)`. The macro `?`, described later, may be used for the same purpose.\n", + "`(dffr chcm &rest)` *[Macro]* \n", + "> Versatile macro to apply the differential morphism of the chain complex `chcm` either to a combination or a generator with a degree, respectively `(dffr chcm cmbn)` or `(dffr chcm degr gnrt)`. The macro `?`, described later, may be used for the same purpose.\n", "\n", - "> *Function* `(z-chcm)`\n", - ">> Build the unit chain complex (see hereafter).\n", + "`(z-chcm)` *[Function]* \n", + "> Build the unit chain complex (see hereafter).\n", "\n", "#### Examples\n", "\n", @@ -1238,18 +1238,10 @@ "collapsed": false }, "outputs": [ - { - "name": "stderr", - "output_type": "stream", - "text": [ - "REDEFINITION-WITH-DEFUN: \n", - " #\n" - ] - }, { "data": { "text/plain": [ - "CIRCLE" + "MY-CIRCLE" ] }, "execution_count": 38, @@ -1258,7 +1250,7 @@ } ], "source": [ - "(defun CIRCLE ()\n", + "(defun MY-CIRCLE ()\n", " (the chain-complex\n", " (build-chcm\n", " :cmpr #'(lambda (gnrt1 gnrt2)\n", @@ -1278,7 +1270,79 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "## Morphisms" + "## Morphisms\n", + "\n", + "Algebraic Topology uses morphisms between chain complexes and the differential homomorphism may be considered as a particular case of morphism. A morphism is implemented in the system as an instance of the class `MORPHISM`, whose definition is:\n", + "\n", + "```lisp\n", + "(DEFCLASS MORPHISM ()\n", + " ;; SOuRCe\n", + " ((sorc :type chain-complex :initarg :sorc :reader sorc)\n", + " ;; TaRGeT\n", + " (trgt :type chain-complex :initarg :trgt :reader trgt)\n", + " ;; DEGRee\n", + " (degr :type fixnum :initarg :degr :reader degr)\n", + " ;; INTeRnal\n", + " (intr :type intr-mrph :initarg :intr :reader intr)\n", + " ;; STRaTegy\n", + " (strt :type strt :initarg :strt :reader strt)\n", + " ;; CaLl NuMber\n", + " (???-clnm :type fixnum :initform 0 :accessor ???-clnm)\n", + " (?-clnm :type fixnum :initform 0 :accessor ?-clnm)\n", + " ;; ReSuLTS\n", + " (rslts :type simple-vector :reader rslts)\n", + " ;; IDentification NuMber\n", + " (idnm :type fixnum :initform (incf *idnm-counter*) :reader idnm)\n", + " ;; ORiGiN\n", + " (orgn :type list :initarg :orgn :reader orgn)))\n", + "```\n", + "\n", + "This class has 10 slots:\n", + "\n", + "1. `sorc`, an object of the class `CHAIN-COMPLEX`, namely the *source* chain complex of this morphism.\n", + "2. `trgt`, an object of the class `CHAIN-COMPLEX`, namely the *target* chain complex of this morphism.\n", + "3. `degr`, an integer, the degree of the morphism. A morphism is supposed to associate to any element of degree $k$ of the source chain complex, an element of degree $k + degr$ of the target chain complex. For instance, the differential homomorphism is of degree -1.\n", + "4. `intr`, a **pure lisp function** implementing the mathematical algorithm of the morphism and taking in account the strategy (`strt`).\n", + "5. `strt`, one of the two symbols `:gnrt`, `:cmbn`. What has already been said about the strategy of the differential morphism is generalized to any morphism: according to the value of the argument, `:gnrt` or `:cmbn`, the lisp function attached to the keyword just above, works respectively with 2 arguments (a degree and a generator) or only one (a combination) and must return a combination, image of the generator or the combination argument. \n", + "6. `???-clnm`, an integer updated by the system for statistics (number of times the morphism has been called on combinations - Internal use)\n", + "7. `?-clnm`, analogous to the previous field, but for generators.\n", + "8. `rslts`, an array of dimension `*maxdim*` reserved by the system to save computed results in order to avoid re-computing, for instance, the differential of the same generator. - Internal use.\n", + "9. `idnm`, an integer, number plate for this object. This is generated by the system.\n", + "10. `orgn`, a relevant comment list.\n", + "\n", + "The accessors of the slots are the functions whose name appears after the specifier `:reader` or after the specifier `:accessor` in the class definition. A printing method has been associated to the class `MORPHISM` and the external representation of an instance is a string like `[Kn Morphism (degree d): Kp -> Kq]` or `Kn Cohomology-Class (degree d)]` when the chain complex target is the unit $\\mathbb{Z}$. In this string, `n` is the number plate of the `Kenzo` object, `d` is the degree of the morphism, `Kp` is the `Kenzo` object source of the morphism and `Kq` the target. In all the examples of this manual, the last part of the string will not be necessarily printed." + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "### The function `build-mprh`\n", + "\n", + "To facilitate the construction of instances of the class `MORPHISM` and to free the user to call the standard constructor `make-instance`, the software provides the function `build-mrph`\n", + "\n", + "```lisp\n", + "build-mrph :sorc sorc :trgt trgt :degr degr :intr intr :strt strt :orgn orgn\n", + "```\n", + "\n", + "defined with keyword parameters. The returned value is an instance of the class `MORPHISM`. The keyword arguments of `build-mrph` are:\n", + "\n", + "- *sorc*, the source object, a `CHAIN-COMPLEX` type object.\n", + "- *trgt*, the target object, a `CHAIN-COMPLEX` type object.\n", + "- *degr*, the degree of the morphism, an integer.\n", + "- *intr*, the pure lisp function defining the effective mapping.\n", + "- *strt*, the strategy, i.e. `:gnrt` or `:cmbn`.\n", + "- *orgn*, a relevant comment list.\n", + "\n", + "After a call to `build-mrph`, the morphism instance is added to a list of previously constructed ones (`*mrph-list*`).\n", + "\n", + "#### The differential homomorphism in a chain complex instance\n", + "\n", + "In a chain complex instance, the differential homomorphism is defined as a morphism with identical source and target, and degree -1. The user must know that the function `build-chcm` calls internally the function `build-mrph` and passes it the keyword argument `pure-dffr`. The function `build-mrph` builds the morphism instance which will be then inserted into the slot `:dffr` of the chain complex instance to be constructed.\n", + "\n", + "##### Example\n", + "\n", + "Let us define respectively a *zero--morphism* of degree -1 and an *identity-morphism* (degree 0) between the *unit chain complex* `ZCC` and itself." ] }, { @@ -1287,139 +1351,6 @@ "metadata": { "collapsed": false }, - "outputs": [ - { - "data": { - "text/plain": [ - "\"----------------------------------------------------------------[class-doc]\n", - "MORPHISM\n", - "Slots: (sorc trgt degr intr strt ???-clnm ?-clnm rslts idnm orgn)\n", - "Intances of this class represent morphisms between chain complexes, and the\n", - "differential homomorphism of a chain complex is treated as a morphism of\n", - "degree -1. The class has 10 slots:\n", - "\n", - "1. SORC, an object of type CHAIN-COMPLEX, the source chain complex of this\n", - " morphism. Its reader function is SORC.\n", - "\n", - "2. TRGT, an object of type CHAIN-COMPLEX, the target chain complex of this\n", - " morphism. Its reader function is TRGT.\n", - "\n", - "3. DEGR, an integer, the degree of the morphism. Its reader function is DEGR.\n", - "\n", - "4. INTR, a Lisp INTeRnal function implementing the morphism, taking account\n", - " of the strategy STRT. Its reader function is INTR.\n", - "\n", - "5. STRT, a symbol, one of :GNRT or :CMBN. Its reader function is STRT.\n", - "\n", - " If this slot is :GNRT, the implementation of INTR is a function:\n", - " (function (degr gnrt) cmbn)\n", - " and for any call of this function, the result is stored in the slot\n", - " RSLTS to avoid later a possibly long recalculation for the same\n", - " argument.\n", - "\n", - " If this slot is :CMBN, the implementation of INTR is a function:\n", - " (function (cmbn) cmbn)\n", - " and the RSLTS slot is not used. Think for example to an identity or\n", - " null function, where storing a result is wasted time.\n", - "\n", - "6. ???-CLNM, an integer updated by the system for internal statistics. Its\n", - " reader function is ???-CLNM.\n", - "\n", - "7. ?-CLNM, another integer maintained by the system for internal pusposes. Its\n", - " reader function is ?-CLNM.\n", - "\n", - "8. RSLTS, an array of length +MAXIMAL-DIMENSION+ reserved by the system for\n", - " caching intermediate results. Its reader function is RSLTS.\n", - "\n", - "9. IDNM, an integer, a system-generated identifier for this object. Its reader\n", - " function is IDNM.\n", - "\n", - "10. ORGN, a list which is the copy of a Lisp statement, in principle the\n", - " statement which was at the origin of the creation of this Kenzo object.\n", - " A caching process, using this slot, prevents the creation of multiple\n", - " copies of the same mathematical object, which is important for efficiency.\n", - " It is used also for debugging and analyzing the program.\n", - "-----------------------------------------------------------------------------\"" - ] - }, - "execution_count": 39, - "metadata": {}, - "output_type": "execute_result" - } - ], - "source": [ - "(documentation 'morphism 'type)" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "### The function $\\texttt{build-mprh}$" - ] - }, - { - "cell_type": "code", - "execution_count": 40, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "data": { - "text/plain": [ - "\"--------------------------------------------------------------[function-doc]\n", - "BUILD-MRPH\n", - "Args: (&key sorc trgt degr intr strt orgn)\n", - "Returns an instance of the class MORPHISM. The keyword arguments are as\n", - "follows:\n", - "\n", - ":SORC SORC, the source object, a CHAIN-COMPLEX type object\n", - "\n", - ":TRGT TRGT, the target object, a CHAIN-COMPLEX type object\n", - "\n", - ":DEGR DEGR, the degree of the morphism, an integer\n", - "\n", - ":INTR INTR, the Lisp function defining the effective mapping\n", - "\n", - ":STRT STRT, one of the keywords :GNRT or :CMBN, defining the mapping strategy\n", - " of the differential homomorphism, either by generator or by\n", - " combination. The default is :GNRT\n", - "\n", - ":ORGN ORGN, a list which is the copy of a Lisp statement, in principle the\n", - " statement which was at the origin of the creation of this Kenzo\n", - " object. A caching process, using this slot, prevents the creation\n", - " of multiple copies of the same mathematical object, which is\n", - " important for efficiency. It is used also for debugging and\n", - " analyzing the program.\n", - "\n", - "Use this function instead of creating instances via the standard constructor\n", - "MAKE-INSTANCE.\n", - "------------------------------------------------------------------------------\"" - ] - }, - "execution_count": 40, - "metadata": {}, - "output_type": "execute_result" - } - ], - "source": [ - "(documentation 'build-mrph 'function)" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "#### The differential homomorphism in a chain complex instance" - ] - }, - { - "cell_type": "code", - "execution_count": 41, - "metadata": { - "collapsed": false - }, "outputs": [ { "name": "stdout", @@ -1435,7 +1366,7 @@ "NIL" ] }, - "execution_count": 41, + "execution_count": 39, "metadata": {}, "output_type": "execute_result" } @@ -1446,7 +1377,7 @@ }, { "cell_type": "code", - "execution_count": 42, + "execution_count": 40, "metadata": { "collapsed": false }, @@ -1457,7 +1388,7 @@ "[K1 Chain-Complex]" ] }, - "execution_count": 42, + "execution_count": 40, "metadata": {}, "output_type": "execute_result" } @@ -1468,7 +1399,7 @@ }, { "cell_type": "code", - "execution_count": 43, + "execution_count": 41, "metadata": { "collapsed": false }, @@ -1479,7 +1410,7 @@ "[K3 Cohomology-Class on K1 of degree 1]" ] }, - "execution_count": 43, + "execution_count": 41, "metadata": {}, "output_type": "execute_result" } @@ -1496,7 +1427,7 @@ }, { "cell_type": "code", - "execution_count": 44, + "execution_count": 42, "metadata": { "collapsed": false }, @@ -1507,7 +1438,7 @@ "[K4 Cohomology-Class on K1 of degree 0]" ] }, - "execution_count": 44, + "execution_count": 42, "metadata": {}, "output_type": "execute_result" } @@ -1525,14 +1456,88 @@ "cell_type": "markdown", "metadata": {}, "source": [ + "On the first morphism, we see that the `:intr` keyword argument is a lisp function taking any combination of degree `p` of the unit chain complex and generating a null combination of degree `p-1` of the same chain complex. The second morphism uses the lisp function `identity`.\n", + "\n", "### Applying morphisms\n", "\n", - "### Functions defining morphisms" + "To apply an already constructed morphism on a generator, one uses the function `gnrt-?`, the usage of which is described hereafter. On a similar way, to apply a morphism on a combination, one uses the function `cmbn-?`. It is very important to note that these functions can be used with the underlying morphism, **whatever strategy had been decided\n", + "at creation time by the user for the morphism mapping**. In other words, a morphism defined with the strategy `:gnrt` (resp. `:cmbn`) may be applied to a combination (resp. generator). These functions are mainly used inside the software. For a practical usage, one may use the versatile macro `?`.\n", + "\n", + "`(gnrt-? mrph degr gnrt)` *[Function]*\n", + "> Apply the morphism `mrph` on the generator `gnrt` of degree `degr`.\n", + "\n", + "`(cmbn-? mrph cmbn)` *[Function]*\n", + "> Apply the morphism `mrph` on the combination `cmbn`.\n", + "\n", + "`(? &rest args)` *[Macro]*\n", + "> Versatile macro for applying a morphism in both cases above, i.e. indifferently as `(? mrph degr gnrt)` or `(? mrph cmbn)`. If the first argument is a chain complex object, as in `(? chcm degr gnrt)` or in `(? chcm cmbn)`, then the differential morphism of the chain complex `chcm` is applied to the arguments.\n", + "\n", + "### Functions defining morphisms\n", + "\n", + "The following functions are useful to work on morphisms, particularly to define new morphisms from already defined ones.\n", + "\n", + "`(cat-init)` *[Function]*\n", + "> Clear in particular `*mrph-list*`, the list of user created morphisms and reset the global counter to 1.\n", + "\n", + "`(mrph n)` *[Function]*\n", + "> Retrieve in the list `*mrph-list*` the morphism instance whose identification is `n`. If it does not exist, return `NIL`. \n", + "\n", + "`(zero-mrph chcm1 &optional (chcm2 chcm1) (degr 0))` *[Function]*\n", + "> Construct the null morphism between the chain complexes `chcm1` and `chcm2` of degree `degr`. The parameters `chcm2` and `degr` are optional and if omitted the default values (respectively `chcm1` and 0) are taken.\n", + "\n", + "`(idnt-mrph chcm)` *[Function]*\n", + "> Construct the identity morphism (degree 0) between the chain complex `chcm` and itself.\n", + "\n", + "`(opps mrph)` *[Function]*\n", + "> Construct the opposite morphism of `mrph`, i.e. $-1 \\times mrp$; such a function, as well as the following ones, installs the right source and target.\n", + "\n", + "`(cmps mrph1 mrph2 &optional strt)` *[Method]*\n", + "> Construct the composite of the morphisms, i.e. $mrph_1 \\circ\\, mrph_2$. Of course, the target of $mrph_2$ must be the same as the source of $mrph_1$, otherwise the system signals an error. The new instance inherits its source slot from $mrph_2$ and its target slot from $mrph_1$. This function optimizes the compositions in which appear zero morphisms or identity morphisms. Unless the user gives explicitly the strategy (`strt`), the resulting strategy is determined by the respective strategy of the two morphisms.\n", + "\n", + "`(cmps chcm1 chcm2 &optional strt)` *[Method]*\n", + "Construct the composite of the differential of the chain complexes `chcm1` and `chcm2`, i.e. $d_1 \\circ d_2$.\n", + "\n", + "`(cmps chcm1 mrph2 &optional strt)` *[Method]*\n", + "> Construct the composite of the differential of the chain complex `chcm1` and the morphism `mrph2`, i.e. $d_1 \\circ mrph_2$.\n", + "\n", + "`(cmps mrph1 chcm2 &optional strt)` *[Method]*\n", + "> Construct the composite of the morphism `mrph1` and the differential of the chain complex `chcm2`, i.e. $mrph_1 \\circ d_2$.\n", + "\n", + "`(i-cmps mrph1 mrph2 ... mrphk)` *[Macro]*\n", + "> Construct the composite of the morphisms, i.e. $mrph_1 \\circ\\, mrph2 \\circ\\, \\cdots\\, \\circ\\, mrph_k$. Of course, the target of $mrph_i$ must be the same as the source of $mrph_{i-1}$, otherwise the system signals an error. The new instance inherits its source slot from $mrph_k$ and its target slot from $mrph_1$. This function optimizes the compositions in which appear zero morphisms or identity morphisms.\n", + "\n", + "`(add mrph1 mrph2 &optional strt)` *[Method]*\n", + "> Construct a morphism, sum of the morphisms $mrph_1$ and $mrph_2$. The result of the mapping of the morphism sum is the sum of the results of the mappings of the morphisms. The respective definitions of the morphisms $mrph_1$ and $mrph_2$ must be coherent, in particular they must have the same source, target and degree. The user may impose its strategy, otherwise it is defined in the program according to the respective strategy of the arguments.\n", + "\n", + "`(i-add mrph1 mrph2 ... mrphk)` *[Macro]*\n", + "> Construct a morphism, sum of the morphism $mrph_1$, $mrph_2$, $\\ldots$, $mrph_k$. The result of the mapping of the morphism sum is the sum of the results of the mappings of the $mrph_i$. The respective definitions of $mrph_i$ must be coherent, in particular they must have the same source, target and degree. The macro `i-add` has an undefinite number of arguments. With one argument, the macro returns that argument.\n", + "\n", + "`(sbtr mrph1 mrph2 &optional strt)` *[Method]*\n", + "> Construct a morphism, difference of the morphisms $mrph_1$ and $mrph_2$. The conditions of validity are similar to those of the method `add`.\n", + "\n", + "`(i-sbtr mrph1 mrph2 ... mrphk)` *[Macro]*\n", + "> Construct a morphism, difference of the morphisms $mrph_1$, $mrph_2$, $\\ldots$, $mrph_k$, in the sense $mrph_1 - mrph_2 - \\cdots - mrph_k$. The conditions of validity are similar to those of the method `add` for the morphisms. The macro `i-sbtr` must have at least 2 arguments.\n", + "\n", + "`(change-sorc-trgt mrph &key sorc trgt)` *[Function]*\n", + "> Build from the morphism `mrph` a new morphism inheriting from `mrph` the slots `:degr` (degree), `:intr` (mapping) and `:strt` (strategy). The source and target slots of this new morphism are given by the key parameters `sorc` and `trgt`. If any key parameter is omitted, the corresponding slot is inherited from `mrph` (default value).\n", + "\n", + "`(dstr-change-sorc-trgt mrph &key sorc trgt)` *[Function]*\n", + "> Modify **destructively** the morphism `mrph`. The source and target slots of the first argument are replaced respectively by the key parameters `sorc` and `trgt`.\n", + "\n", + "`(add chcm perturbation &optional strt)` *[Method]*\n", + "> Create from the chain complex `chcm` a new chain complex inheriting from `chcm` the slots `cmpr` and `basis`. The boundary morphism attached to this new chain complex is the sum of the boundary morphism $d$ of `chcm` (slot `dffr`) and a perturbation morphism $\\delta$ represented by the `MORPHISM` instance `perturbation`. Of course, the new boundary operator must verify $(d+\\delta)\\circ (d+\\delta)=0$. The user will note that this method does not create a morphism but a chain complex.\n", + "\n", + "#### Examples\n", + "\n", + "In the following examples, we first construct a chain complex instance `ccn` where the groups $C_p$ are freely generated by numerical basis taken formally. These basis are sets of 10 numbers or *decades* produced by the fonction `" + "#" ] }, - "execution_count": 45, + "execution_count": 43, "metadata": {}, "output_type": "execute_result" } @@ -1557,7 +1562,7 @@ }, { "cell_type": "code", - "execution_count": 46, + "execution_count": 44, "metadata": { "collapsed": false }, @@ -1568,7 +1573,7 @@ "[K5 Chain-Complex]" ] }, - "execution_count": 46, + "execution_count": 44, "metadata": {}, "output_type": "execute_result" } @@ -1584,7 +1589,7 @@ }, { "cell_type": "code", - "execution_count": 47, + "execution_count": 45, "metadata": { "collapsed": false }, @@ -1595,7 +1600,7 @@ "[K7 Morphism (degree 1): K5 -> K5]" ] }, - "execution_count": 47, + "execution_count": 45, "metadata": {}, "output_type": "execute_result" } @@ -1609,7 +1614,7 @@ }, { "cell_type": "code", - "execution_count": 48, + "execution_count": 46, "metadata": { "collapsed": false }, @@ -1620,7 +1625,7 @@ "[K8 Morphism (degree -1): K5 -> K5]" ] }, - "execution_count": 48, + "execution_count": 46, "metadata": {}, "output_type": "execute_result" } @@ -1634,7 +1639,7 @@ }, { "cell_type": "code", - "execution_count": 49, + "execution_count": 47, "metadata": { "collapsed": false }, @@ -1648,7 +1653,7 @@ "------------------------------------------------------------------------------\n" ] }, - "execution_count": 49, + "execution_count": 47, "metadata": {}, "output_type": "execute_result" } @@ -1659,7 +1664,7 @@ }, { "cell_type": "code", - "execution_count": 50, + "execution_count": 48, "metadata": { "collapsed": false }, @@ -1672,18 +1677,18 @@ "------------------------------------------------------------------------------\n" ] }, - "execution_count": 50, + "execution_count": 48, "metadata": {}, "output_type": "execute_result" } ], "source": [ - "(? ccn *)" + "(? ccn *) ;(* means the result of the previous command)" ] }, { "cell_type": "code", - "execution_count": 51, + "execution_count": 49, "metadata": { "collapsed": false }, @@ -1699,7 +1704,7 @@ "------------------------------------------------------------------------------\n" ] }, - "execution_count": 51, + "execution_count": 49, "metadata": {}, "output_type": "execute_result" } @@ -1710,7 +1715,7 @@ }, { "cell_type": "code", - "execution_count": 52, + "execution_count": 50, "metadata": { "collapsed": false }, @@ -1725,7 +1730,7 @@ "------------------------------------------------------------------------------\n" ] }, - "execution_count": 52, + "execution_count": 50, "metadata": {}, "output_type": "execute_result" } @@ -1736,7 +1741,7 @@ }, { "cell_type": "code", - "execution_count": 53, + "execution_count": 51, "metadata": { "collapsed": false }, @@ -1749,7 +1754,7 @@ "------------------------------------------------------------------------------\n" ] }, - "execution_count": 53, + "execution_count": 51, "metadata": {}, "output_type": "execute_result" } @@ -1758,9 +1763,16 @@ "(? ccn *)" ] }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "Then, let us test the morphisms on generators and combinations." + ] + }, { "cell_type": "code", - "execution_count": 54, + "execution_count": 52, "metadata": { "collapsed": false }, @@ -1774,7 +1786,7 @@ "------------------------------------------------------------------------------\n" ] }, - "execution_count": 54, + "execution_count": 52, "metadata": {}, "output_type": "execute_result" } @@ -1785,7 +1797,7 @@ }, { "cell_type": "code", - "execution_count": 55, + "execution_count": 53, "metadata": { "collapsed": false }, @@ -1799,7 +1811,7 @@ "------------------------------------------------------------------------------\n" ] }, - "execution_count": 55, + "execution_count": 53, "metadata": {}, "output_type": "execute_result" } @@ -1808,9 +1820,17 @@ "(? lower-shift 5 51)" ] }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "We may iterate the mapping upon the previous result (symbol \\*). Note that now, though `lower-shift` has been constructed with \n", + "the strategy `:gnrt`, its works also on a combination." + ] + }, { "cell_type": "code", - "execution_count": 56, + "execution_count": 54, "metadata": { "collapsed": false }, @@ -1824,13 +1844,77 @@ "------------------------------------------------------------------------------\n" ] }, + "execution_count": 54, + "metadata": {}, + "output_type": "execute_result" + } + ], + "source": [ + "(? lower-shift *)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "Let us construct new morphisms from `upper-shift` and `lower-shift`. The tests are made upon the degree 1 combination $1*10 + 2*11 + 3*12 +4*13$." + ] + }, + { + "cell_type": "code", + "execution_count": 55, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "data": { + "text/plain": [ + "\n", + "----------------------------------------------------------------------{CMBN 1}\n", + "<1 * 10>\n", + "<2 * 11>\n", + "<3 * 12>\n", + "<4 * 13>\n", + "------------------------------------------------------------------------------\n" + ] + }, + "execution_count": 55, + "metadata": {}, + "output_type": "execute_result" + } + ], + "source": [ + "(def comb1 (cmbn 1 1 10 2 11 3 12 4 13))" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "The composition of the two morphisms must be an identity operation. The degree of `identity?` is in the `degr` slot of the morphism object instance and may be read by the function `degr`:" + ] + }, + { + "cell_type": "code", + "execution_count": 56, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "data": { + "text/plain": [ + "[K9 Morphism (degree 0): K5 -> K5]" + ] + }, "execution_count": 56, "metadata": {}, "output_type": "execute_result" } ], "source": [ - "(? lower-shift (? lower-shift 5 51))" + "(def identity? (cmps upper-shift lower-shift))" ] }, { @@ -1843,13 +1927,7 @@ { "data": { "text/plain": [ - "\n", - "----------------------------------------------------------------------{CMBN 1}\n", - "<1 * 10>\n", - "<2 * 11>\n", - "<3 * 12>\n", - "<4 * 13>\n", - "------------------------------------------------------------------------------\n" + "0" ] }, "execution_count": 57, @@ -1858,7 +1936,14 @@ } ], "source": [ - "(def comb1 (cmbn 1 1 10 2 11 3 12 4 13))" + "(degr identity?)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "We see now that `identity?` applied on `comb1` returns a combination mathematically equal to `comb1`. No simple lisp comparison can prove this, nevertheless, their mathematical difference is the null combination, as shown by a call to the function `2cmbn-sbtr` applied to two combinations. Note that the function `2cmbn-sbtr` needs the comparison function of the chain complex `ccn`." ] }, { @@ -1871,7 +1956,13 @@ { "data": { "text/plain": [ - "[K9 Morphism (degree 0): K5 -> K5]" + "\n", + "----------------------------------------------------------------------{CMBN 1}\n", + "<1 * 10>\n", + "<2 * 11>\n", + "<3 * 12>\n", + "<4 * 13>\n", + "------------------------------------------------------------------------------\n" ] }, "execution_count": 58, @@ -1880,7 +1971,7 @@ } ], "source": [ - "(def identity? (cmps upper-shift lower-shift))" + "(? identity? comb1)" ] }, { @@ -1893,7 +1984,9 @@ { "data": { "text/plain": [ - "0" + "\n", + "----------------------------------------------------------------------{CMBN 1}\n", + "------------------------------------------------------------------------------\n" ] }, "execution_count": 59, @@ -1902,7 +1995,14 @@ } ], "source": [ - "(degr identity?)" + "(2cmbn-sbtr (cmpr ccn) comb1 *)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "We may compose `upper-shift` with itself:" ] }, { @@ -1915,13 +2015,7 @@ { "data": { "text/plain": [ - "\n", - "----------------------------------------------------------------------{CMBN 1}\n", - "<1 * 10>\n", - "<2 * 11>\n", - "<3 * 12>\n", - "<4 * 13>\n", - "------------------------------------------------------------------------------\n" + "[K10 Morphism (degree 2): K5 -> K5]" ] }, "execution_count": 60, @@ -1930,7 +2024,7 @@ } ], "source": [ - "(? identity? comb1)" + "(def upper-shift2 (cmps upper-shift upper-shift))" ] }, { @@ -1939,52 +2033,6 @@ "metadata": { "collapsed": false }, - "outputs": [ - { - "data": { - "text/plain": [ - "\n", - "----------------------------------------------------------------------{CMBN 1}\n", - "------------------------------------------------------------------------------\n" - ] - }, - "execution_count": 61, - "metadata": {}, - "output_type": "execute_result" - } - ], - "source": [ - "(2cmbn-sbtr (cmpr ccn) comb1 *)" - ] - }, - { - "cell_type": "code", - "execution_count": 62, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "data": { - "text/plain": [ - "[K10 Morphism (degree 2): K5 -> K5]" - ] - }, - "execution_count": 62, - "metadata": {}, - "output_type": "execute_result" - } - ], - "source": [ - "(def upper-shift2 (cmps upper-shift upper-shift))" - ] - }, - { - "cell_type": "code", - "execution_count": 63, - "metadata": { - "collapsed": false - }, "outputs": [ { "data": { @@ -1992,7 +2040,7 @@ "2" ] }, - "execution_count": 63, + "execution_count": 61, "metadata": {}, "output_type": "execute_result" } @@ -2003,7 +2051,7 @@ }, { "cell_type": "code", - "execution_count": 64, + "execution_count": 62, "metadata": { "collapsed": false }, @@ -2020,7 +2068,7 @@ "------------------------------------------------------------------------------\n" ] }, - "execution_count": 64, + "execution_count": 62, "metadata": {}, "output_type": "execute_result" } @@ -2029,9 +2077,16 @@ "(? upper-shift2 comb1)" ] }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "Adding `upper-shift` with itself gives a very different result:" + ] + }, { "cell_type": "code", - "execution_count": 65, + "execution_count": 63, "metadata": { "collapsed": false }, @@ -2042,7 +2097,7 @@ "[K11 Morphism (degree 1): K5 -> K5]" ] }, - "execution_count": 65, + "execution_count": 63, "metadata": {}, "output_type": "execute_result" } @@ -2053,7 +2108,7 @@ }, { "cell_type": "code", - "execution_count": 66, + "execution_count": 64, "metadata": { "collapsed": false }, @@ -2064,7 +2119,7 @@ "1" ] }, - "execution_count": 66, + "execution_count": 64, "metadata": {}, "output_type": "execute_result" } @@ -2075,7 +2130,7 @@ }, { "cell_type": "code", - "execution_count": 67, + "execution_count": 65, "metadata": { "collapsed": false }, @@ -2092,7 +2147,7 @@ "------------------------------------------------------------------------------\n" ] }, - "execution_count": 67, + "execution_count": 65, "metadata": {}, "output_type": "execute_result" } @@ -2101,6 +2156,57 @@ "(? twice-up-shift comb1)" ] }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "Let us compose `upper-shift` and the differential in both ways. Recall that the differential is a morphism structure, and may be obtained from the `dffr` slot of the chain complex `ccn` by the reader accessor function `dffr1`. This morphism has been built by `build-chcm` from the lisp function `ccn-boundary`. One can see that the operators do not commute." + ] + }, + { + "cell_type": "code", + "execution_count": 66, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "data": { + "text/plain": [ + "[K12 Morphism (degree 0): K5 -> K5]" + ] + }, + "execution_count": 66, + "metadata": {}, + "output_type": "execute_result" + } + ], + "source": [ + "(def up-d (cmps upper-shift (dffr1 ccn)))" + ] + }, + { + "cell_type": "code", + "execution_count": 67, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "data": { + "text/plain": [ + "[K13 Morphism (degree 0): K5 -> K5]" + ] + }, + "execution_count": 67, + "metadata": {}, + "output_type": "execute_result" + } + ], + "source": [ + "(def d-up (cmps (dffr1 ccn) upper-shift))" + ] + }, { "cell_type": "code", "execution_count": 68, @@ -2111,7 +2217,10 @@ { "data": { "text/plain": [ - "[K12 Morphism (degree 0): K5 -> K5]" + "\n", + "----------------------------------------------------------------------{CMBN 1}\n", + "<1 * 11>\n", + "------------------------------------------------------------------------------\n" ] }, "execution_count": 68, @@ -2120,7 +2229,7 @@ } ], "source": [ - "(def up-d (cmps upper-shift (dffr1 ccn)))" + "(? up-d 1 11)" ] }, { @@ -2133,7 +2242,9 @@ { "data": { "text/plain": [ - "[K13 Morphism (degree 0): K5 -> K5]" + "\n", + "----------------------------------------------------------------------{CMBN 1}\n", + "------------------------------------------------------------------------------\n" ] }, "execution_count": 69, @@ -2142,7 +2253,7 @@ } ], "source": [ - "(def d-up (cmps (dffr1 ccn) upper-shift))" + "(? d-up 1 11)" ] }, { @@ -2157,7 +2268,12 @@ "text/plain": [ "\n", "----------------------------------------------------------------------{CMBN 1}\n", - "<1 * 11>\n", + "<1 * 10>\n", + "<2 * 11>\n", + "<3 * 12>\n", + "<4 * 13>\n", + "<5 * 14>\n", + "<6 * 15>\n", "------------------------------------------------------------------------------\n" ] }, @@ -2167,7 +2283,7 @@ } ], "source": [ - "(? up-d 1 11)" + "(def comb3 (cmbn 1 1 10 2 11 3 12 4 13 5 14 6 15))" ] }, { @@ -2182,6 +2298,9 @@ "text/plain": [ "\n", "----------------------------------------------------------------------{CMBN 1}\n", + "<2 * 11>\n", + "<4 * 13>\n", + "<6 * 15>\n", "------------------------------------------------------------------------------\n" ] }, @@ -2191,7 +2310,7 @@ } ], "source": [ - "(? d-up 1 11)" + "(? up-d comb3)" ] }, { @@ -2207,11 +2326,8 @@ "\n", "----------------------------------------------------------------------{CMBN 1}\n", "<1 * 10>\n", - "<2 * 11>\n", "<3 * 12>\n", - "<4 * 13>\n", "<5 * 14>\n", - "<6 * 15>\n", "------------------------------------------------------------------------------\n" ] }, @@ -2220,60 +2336,6 @@ "output_type": "execute_result" } ], - "source": [ - "(def comb3 (cmbn 1 1 10 2 11 3 12 4 13 5 14 6 15))" - ] - }, - { - "cell_type": "code", - "execution_count": 73, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "data": { - "text/plain": [ - "\n", - "----------------------------------------------------------------------{CMBN 1}\n", - "<2 * 11>\n", - "<4 * 13>\n", - "<6 * 15>\n", - "------------------------------------------------------------------------------\n" - ] - }, - "execution_count": 73, - "metadata": {}, - "output_type": "execute_result" - } - ], - "source": [ - "(? up-d comb3)" - ] - }, - { - "cell_type": "code", - "execution_count": 74, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "data": { - "text/plain": [ - "\n", - "----------------------------------------------------------------------{CMBN 1}\n", - "<1 * 10>\n", - "<3 * 12>\n", - "<5 * 14>\n", - "------------------------------------------------------------------------------\n" - ] - }, - "execution_count": 74, - "metadata": {}, - "output_type": "execute_result" - } - ], "source": [ "(? d-up comb3)" ] @@ -2288,38 +2350,21 @@ "coalgebras, algebras, simplicial morphism, etc, each having its specific list. But, in fact the numbering is independent\n", "of the type of the object and is incremented each time an object is created. Three general functions are at the disposal of the user to get information about the `n`-th `Kenzo` object: `K`, `KD`, and `KD2`. They may be useful for debugging purpose.\n", "\n", - "#### Function `K`" + "`(k n)` *[Function]*\n", + "> Get the `n`-th `Kenzo` object.\n", + "\n", + "`(kd n)` *[Function]*\n", + "> Give the type of the `Kenzo` objet number `n` and print the comment list (slot `:orgn`) of the object.\n", + "\n", + "`(kd2 n)` *[Function]*\n", + "> Give the type of the `Kenzo` objet number `n`, print the comment list (slot `:orgn`) of the object and recursively, give the same kind of informations about all the `Kenzo` objects of the same type in relation with this `n`-th object. Return the list of numbers of all those objects. See in the following example, the case of composition of morphisms.\n", + "\n", + "#### Examples" ] }, { "cell_type": "code", - "execution_count": 75, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "data": { - "text/plain": [ - "\"--------------------------------------------------------------[function-doc]\n", - "K\n", - "Args: (idnm)\n", - "Returns the IDNM-th Kenzo object.\n", - "------------------------------------------------------------------------------\"" - ] - }, - "execution_count": 75, - "metadata": {}, - "output_type": "execute_result" - } - ], - "source": [ - "(documentation 'k 'function)" - ] - }, - { - "cell_type": "code", - "execution_count": 76, + "execution_count": 73, "metadata": { "collapsed": false }, @@ -2330,7 +2375,7 @@ "[K1 Chain-Complex]" ] }, - "execution_count": 76, + "execution_count": 73, "metadata": {}, "output_type": "execute_result" } @@ -2348,34 +2393,7 @@ }, { "cell_type": "code", - "execution_count": 77, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "data": { - "text/plain": [ - "\"--------------------------------------------------------------[function-doc]\n", - "KD\n", - "Args: (idnm)\n", - "Return the type of Kenzo object number IDNM and print the comment list\n", - "(SLOT :ORGN) of the object.\n", - "------------------------------------------------------------------------------\"" - ] - }, - "execution_count": 77, - "metadata": {}, - "output_type": "execute_result" - } - ], - "source": [ - "(documentation 'kd 'function)" - ] - }, - { - "cell_type": "code", - "execution_count": 78, + "execution_count": 74, "metadata": { "collapsed": false }, @@ -2396,7 +2414,7 @@ "NIL" ] }, - "execution_count": 78, + "execution_count": 74, "metadata": {}, "output_type": "execute_result" } @@ -2407,7 +2425,7 @@ }, { "cell_type": "code", - "execution_count": 79, + "execution_count": 75, "metadata": { "collapsed": false }, @@ -2418,7 +2436,7 @@ "[K3 Cohomology-Class on K1 of degree 1]" ] }, - "execution_count": 79, + "execution_count": 75, "metadata": {}, "output_type": "execute_result" } @@ -2429,7 +2447,7 @@ }, { "cell_type": "code", - "execution_count": 80, + "execution_count": 76, "metadata": { "collapsed": false }, @@ -2450,7 +2468,7 @@ "NIL" ] }, - "execution_count": 80, + "execution_count": 76, "metadata": {}, "output_type": "execute_result" } @@ -2461,7 +2479,7 @@ }, { "cell_type": "code", - "execution_count": 81, + "execution_count": 77, "metadata": { "collapsed": false }, @@ -2482,7 +2500,7 @@ "NIL" ] }, - "execution_count": 81, + "execution_count": 77, "metadata": {}, "output_type": "execute_result" } @@ -2493,7 +2511,7 @@ }, { "cell_type": "code", - "execution_count": 82, + "execution_count": 78, "metadata": { "collapsed": false }, @@ -2514,7 +2532,7 @@ "NIL" ] }, - "execution_count": 82, + "execution_count": 78, "metadata": {}, "output_type": "execute_result" } @@ -2525,7 +2543,7 @@ }, { "cell_type": "code", - "execution_count": 83, + "execution_count": 79, "metadata": { "collapsed": false }, @@ -2546,7 +2564,7 @@ "NIL" ] }, - "execution_count": 83, + "execution_count": 79, "metadata": {}, "output_type": "execute_result" } @@ -2555,45 +2573,9 @@ "(kd 9)" ] }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "#### Function `KD2`" - ] - }, { "cell_type": "code", - "execution_count": 84, - "metadata": { - "collapsed": false - }, - "outputs": [ - { - "data": { - "text/plain": [ - "\"--------------------------------------------------------------[function-doc]\n", - "KD2\n", - "Args: (idnm)\n", - "Return the type of Kenzo object number IDNM, print the comment list\n", - "(SLOT :ORGN) of the object and, recursively, return the same information\n", - "for all Kenzo objects of the same type in relation with this object. Return\n", - "the list of object numbers.\n", - "------------------------------------------------------------------------------\"" - ] - }, - "execution_count": 84, - "metadata": {}, - "output_type": "execute_result" - } - ], - "source": [ - "(documentation 'kd2 'function)" - ] - }, - { - "cell_type": "code", - "execution_count": 85, + "execution_count": 80, "metadata": { "collapsed": false }, @@ -2622,7 +2604,7 @@ "(9 8 7)" ] }, - "execution_count": 85, + "execution_count": 80, "metadata": {}, "output_type": "execute_result" }