kingdon 0.1.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (41) hide show
  1. kingdon-0.1.0/AUTHORS.rst +13 -0
  2. kingdon-0.1.0/CONTRIBUTING.rst +128 -0
  3. kingdon-0.1.0/HISTORY.rst +8 -0
  4. kingdon-0.1.0/LICENSE +22 -0
  5. kingdon-0.1.0/MANIFEST.in +11 -0
  6. kingdon-0.1.0/PKG-INFO +227 -0
  7. kingdon-0.1.0/README.rst +196 -0
  8. kingdon-0.1.0/docs/Makefile +20 -0
  9. kingdon-0.1.0/docs/_static/graph_triangle.png +0 -0
  10. kingdon-0.1.0/docs/authors.rst +1 -0
  11. kingdon-0.1.0/docs/conf.py +183 -0
  12. kingdon-0.1.0/docs/contributing.rst +1 -0
  13. kingdon-0.1.0/docs/examples/index.rst +32 -0
  14. kingdon-0.1.0/docs/history.rst +1 -0
  15. kingdon-0.1.0/docs/index.rst +22 -0
  16. kingdon-0.1.0/docs/installation.rst +51 -0
  17. kingdon-0.1.0/docs/make.bat +36 -0
  18. kingdon-0.1.0/docs/module_docs.rst +38 -0
  19. kingdon-0.1.0/docs/readme.rst +196 -0
  20. kingdon-0.1.0/docs/usage.rst +333 -0
  21. kingdon-0.1.0/docs/workings.rst +4 -0
  22. kingdon-0.1.0/kingdon/__init__.py +10 -0
  23. kingdon-0.1.0/kingdon/algebra.py +479 -0
  24. kingdon-0.1.0/kingdon/codegen.py +847 -0
  25. kingdon-0.1.0/kingdon/matrixreps.py +79 -0
  26. kingdon-0.1.0/kingdon/multivector.py +477 -0
  27. kingdon-0.1.0/kingdon/multivector_json.py +17 -0
  28. kingdon-0.1.0/kingdon/operator_dict.py +173 -0
  29. kingdon-0.1.0/kingdon/taperecorder.py +139 -0
  30. kingdon-0.1.0/kingdon.egg-info/PKG-INFO +227 -0
  31. kingdon-0.1.0/kingdon.egg-info/SOURCES.txt +40 -0
  32. kingdon-0.1.0/kingdon.egg-info/dependency_links.txt +1 -0
  33. kingdon-0.1.0/kingdon.egg-info/not-zip-safe +1 -0
  34. kingdon-0.1.0/kingdon.egg-info/requires.txt +4 -0
  35. kingdon-0.1.0/kingdon.egg-info/top_level.txt +1 -0
  36. kingdon-0.1.0/setup.cfg +26 -0
  37. kingdon-0.1.0/setup.py +44 -0
  38. kingdon-0.1.0/tests/__init__.py +1 -0
  39. kingdon-0.1.0/tests/performance_check.py +106 -0
  40. kingdon-0.1.0/tests/test_kingdon.py +749 -0
  41. kingdon-0.1.0/tests/test_operator_dict.py +25 -0
@@ -0,0 +1,13 @@
1
+ =======
2
+ Credits
3
+ =======
4
+
5
+ Development Lead
6
+ ----------------
7
+
8
+ * Martin Roelfs <martinroelfs@yahoo.com>
9
+
10
+ Contributors
11
+ ------------
12
+
13
+ None yet. Why not be the first?
@@ -0,0 +1,128 @@
1
+ .. highlight:: shell
2
+
3
+ ============
4
+ Contributing
5
+ ============
6
+
7
+ Contributions are welcome, and they are greatly appreciated! Every little bit
8
+ helps, and credit will always be given.
9
+
10
+ You can contribute in many ways:
11
+
12
+ Types of Contributions
13
+ ----------------------
14
+
15
+ Report Bugs
16
+ ~~~~~~~~~~~
17
+
18
+ Report bugs at https://github.com/tbuli/kingdon/issues.
19
+
20
+ If you are reporting a bug, please include:
21
+
22
+ * Your operating system name and version.
23
+ * Any details about your local setup that might be helpful in troubleshooting.
24
+ * Detailed steps to reproduce the bug.
25
+
26
+ Fix Bugs
27
+ ~~~~~~~~
28
+
29
+ Look through the GitHub issues for bugs. Anything tagged with "bug" and "help
30
+ wanted" is open to whoever wants to implement it.
31
+
32
+ Implement Features
33
+ ~~~~~~~~~~~~~~~~~~
34
+
35
+ Look through the GitHub issues for features. Anything tagged with "enhancement"
36
+ and "help wanted" is open to whoever wants to implement it.
37
+
38
+ Write Documentation
39
+ ~~~~~~~~~~~~~~~~~~~
40
+
41
+ Kingdon could always use more documentation, whether as part of the
42
+ official Kingdon docs, in docstrings, or even on the web in blog posts,
43
+ articles, and such.
44
+
45
+ Submit Feedback
46
+ ~~~~~~~~~~~~~~~
47
+
48
+ The best way to send feedback is to file an issue at https://github.com/tbuli/kingdon/issues.
49
+
50
+ If you are proposing a feature:
51
+
52
+ * Explain in detail how it would work.
53
+ * Keep the scope as narrow as possible, to make it easier to implement.
54
+ * Remember that this is a volunteer-driven project, and that contributions
55
+ are welcome :)
56
+
57
+ Get Started!
58
+ ------------
59
+
60
+ Ready to contribute? Here's how to set up `kingdon` for local development.
61
+
62
+ 1. Fork the `kingdon` repo on GitHub.
63
+ 2. Clone your fork locally::
64
+
65
+ $ git clone git@github.com:your_name_here/kingdon.git
66
+
67
+ 3. Install your local copy into a virtualenv. Assuming you have virtualenvwrapper installed, this is how you set up your fork for local development::
68
+
69
+ $ mkvirtualenv kingdon
70
+ $ cd kingdon/
71
+ $ python setup.py develop
72
+
73
+ 4. Create a branch for local development::
74
+
75
+ $ git checkout -b name-of-your-bugfix-or-feature
76
+
77
+ Now you can make your changes locally.
78
+
79
+ 5. When you're done making changes, check that your changes pass flake8 and the
80
+ tests, including testing other Python versions with tox::
81
+
82
+ $ flake8 kingdon tests
83
+ $ python setup.py test or pytest
84
+ $ tox
85
+
86
+ To get flake8 and tox, just pip install them into your virtualenv.
87
+
88
+ 6. Commit your changes and push your branch to GitHub::
89
+
90
+ $ git add .
91
+ $ git commit -m "Your detailed description of your changes."
92
+ $ git push origin name-of-your-bugfix-or-feature
93
+
94
+ 7. Submit a pull request through the GitHub website.
95
+
96
+ Pull Request Guidelines
97
+ -----------------------
98
+
99
+ Before you submit a pull request, check that it meets these guidelines:
100
+
101
+ 1. The pull request should include tests.
102
+ 2. If the pull request adds functionality, the docs should be updated. Put
103
+ your new functionality into a function with a docstring, and add the
104
+ feature to the list in README.rst.
105
+ 3. The pull request should work for Python 3.8, 3.9, and 3.10, and for PyPy. Check
106
+ https://travis-ci.com/tbuli/kingdon/pull_requests
107
+ and make sure that the tests pass for all supported Python versions.
108
+
109
+ Tips
110
+ ----
111
+
112
+ To run a subset of tests::
113
+
114
+ $ pytest tests.test_kingdon
115
+
116
+
117
+ Deploying
118
+ ---------
119
+
120
+ A reminder for the maintainers on how to deploy.
121
+ Make sure all your changes are committed (including an entry in HISTORY.rst).
122
+ Then run::
123
+
124
+ $ bump2version patch # possible: major / minor / patch
125
+ $ git push
126
+ $ git push --tags
127
+
128
+ Travis will then deploy to PyPI if tests pass.
@@ -0,0 +1,8 @@
1
+ =======
2
+ History
3
+ =======
4
+
5
+ 0.1.0 (2023-08-12)
6
+ ------------------
7
+
8
+ * First release on PyPI.
kingdon-0.1.0/LICENSE ADDED
@@ -0,0 +1,22 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2022, Martin Roelfs
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
22
+
@@ -0,0 +1,11 @@
1
+ include AUTHORS.rst
2
+ include CONTRIBUTING.rst
3
+ include HISTORY.rst
4
+ include LICENSE
5
+ include README.rst
6
+
7
+ recursive-include tests *
8
+ recursive-exclude * __pycache__
9
+ recursive-exclude * *.py[co]
10
+
11
+ recursive-include docs *.rst conf.py Makefile make.bat *.jpg *.png *.gif
kingdon-0.1.0/PKG-INFO ADDED
@@ -0,0 +1,227 @@
1
+ Metadata-Version: 2.1
2
+ Name: kingdon
3
+ Version: 0.1.0
4
+ Summary: Pythonic Geometric Algebra Package
5
+ Home-page: https://github.com/tbuli/kingdon
6
+ Author: Martin Roelfs
7
+ Author-email: martinroelfs@yahoo.com
8
+ License: MIT license
9
+ Keywords: kingdon
10
+ Classifier: Development Status :: 2 - Pre-Alpha
11
+ Classifier: Intended Audience :: Developers
12
+ Classifier: License :: OSI Approved :: MIT License
13
+ Classifier: Natural Language :: English
14
+ Classifier: Programming Language :: Python :: 3
15
+ Classifier: Programming Language :: Python :: 3.8
16
+ Classifier: Programming Language :: Python :: 3.9
17
+ Classifier: Programming Language :: Python :: 3.10
18
+ Requires-Python: >=3.8
19
+ License-File: LICENSE
20
+ License-File: AUTHORS.rst
21
+
22
+ =======
23
+ Kingdon
24
+ =======
25
+
26
+
27
+ .. image:: https://img.shields.io/pypi/v/kingdon.svg
28
+ :target: https://pypi.python.org/pypi/kingdon
29
+
30
+ .. image:: https://img.shields.io/travis/tbuli/kingdon.svg
31
+ :target: https://travis-ci.com/tbuli/kingdon
32
+
33
+ .. image:: https://readthedocs.org/projects/kingdon/badge/?version=latest
34
+ :target: https://kingdon.readthedocs.io/en/latest/?version=latest
35
+ :alt: Documentation Status
36
+
37
+ .. image:: https://coveralls.io/repos/github/tBuLi/kingdon/badge.svg?branch=master
38
+ :target: https://coveralls.io/github/tBuLi/kingdon?branch=master
39
+
40
+
41
+
42
+ Pythonic Geometric Algebra Package
43
+
44
+
45
+ * Free software: MIT license
46
+ * Documentation: https://kingdon.readthedocs.io.
47
+
48
+
49
+ Features
50
+ --------
51
+
52
+ Kingdon is a Geometric Algebra (GA) library which combines a Pythonic API with
53
+ symbolic simplification and just-in-time compilation to achieve high-performance in a single package.
54
+ It support both symbolic and numerical GA computations.
55
+ Moreover, :code:`kingdon` uses :code:`ganja.js` for visualization in notebooks,
56
+ making it an extremely well rounded GA package.
57
+
58
+ In bullet points:
59
+
60
+ - Symbolically optimized.
61
+ - Leverage sparseness of input.
62
+ - :code:`numba` enabled for numerical computations.
63
+ - :code:`sympy` support for symbolic computations.
64
+ - :code:`ganja.js` enabled graphics in jupyter notebooks.
65
+ - Automatic broadcasting, such that transformations can be applied to e.g. point-clouds.
66
+
67
+ Code Example
68
+ ------------
69
+ In order to demonstrate the power of :code:`Kingdon`, let us first consider the common use-case of the
70
+ commutator product between a bivector and vector.
71
+
72
+ In order to create an algebra, use :code:`Algebra`. When calling :code:`Algebra` we must provide the signature of the
73
+ algebra, in this case we shall go for 3DPGA, which is the algebra :math:`\mathbb{R}_{3,0,1}`.
74
+ There are a number of ways to make elements of the algebra. It can be convenient to work with the basis blades directly.
75
+ We can add them to the local namespace by calling :code:`locals().update(alg.blades)`:
76
+
77
+ .. code-block:: python
78
+
79
+ >>> from kingdon import Algebra
80
+ >>> alg = Algebra(3, 0, 1)
81
+ >>> locals().update(alg.blades)
82
+ >>> b = 2 * e12
83
+ >>> v = 3 * e1
84
+ >>> b.cp(v)
85
+ (-6) * e2
86
+
87
+ This example shows that only the :code:`e2` coefficient is calculated, despite the fact that there are
88
+ 6 bivector and 4 vector coefficients in 3DPGA. But by exploiting the sparseness of the input and by performing symbolic
89
+ optimization, :code:`kingdon` knows that in this case only :code:`e2` can be non-zero.
90
+
91
+ Symbolic usage
92
+ --------------
93
+ If only a name is provided for a multivector, :code:`kingdon` will automatically populate all
94
+ relevant fields with symbols. This allows us to easily perform symbolic computations.
95
+
96
+ .. code-block:: python
97
+
98
+ >>> from kingdon import Algebra
99
+ >>> alg = Algebra(3, 0, 1)
100
+ >>> b = alg.bivector(name='b')
101
+ >>> b
102
+ (b12) * e12 + (b13) * e13 + (b23) * e23 + (b14) * e14 + (b24) * e24 + (b34) * e34
103
+ >>> v = alg.vector(name='v')
104
+ >>> v
105
+ (v1) * e1 + (v2) * e2 + (v3) * e3 + (v4) * e4
106
+ >>> b.cp(v)
107
+ (-b12*v1 + b23*v3) * e2 + (b12*v2 + b13*v3) * e1 + (-b13*v1 - b23*v2) * e3 + (-b14*v1 - b24*v2 - b34*v3) * e4
108
+
109
+ It is also possible to define some coefficients to be symbolic by inputting a string, while others can be numeric::
110
+
111
+ >>> from kingdon import Algebra, symbols
112
+ >>> alg = Algebra(3, 0, 1)
113
+ >>> b = alg.bivector(e12='b12', e34=3)
114
+ >>> b
115
+ (b12) * e12 + (3) * e34
116
+ >>> v = alg.vector(e1=1, e3=1)
117
+ >>> v
118
+ (1) * e1 + (1) * e3
119
+ >>> w = b.cp(v)
120
+ >>> w
121
+ (-b12) * e2 + (-3) * e4
122
+
123
+
124
+ A :code:`kingdon` MultiVector with symbols is callable. So in order to evaluate :code:`w` from the previous example,
125
+ for a specific value of :code:`b12`, simply call :code:`w`::
126
+
127
+ >>> w(b12=10)
128
+ (-10) * e2 + (-3) * e4
129
+
130
+
131
+ Overview of Operators
132
+ =====================
133
+ .. list-table:: Operators
134
+ :widths: 50 25 25 25
135
+ :header-rows: 1
136
+
137
+ * - Operation
138
+ - Expression
139
+ - Infix
140
+ - Inline
141
+ * - Geometric product
142
+ - $ab$
143
+ - :code:`a*b`
144
+ - :code:`a.gp(b)`
145
+ * - Inner
146
+ - $a \\cdot b$
147
+ - :code:`a|b`
148
+ - :code:`a.ip(b)`
149
+ * - Scalar product
150
+ - $\\langle a \\cdot b \\rangle_0$
151
+ -
152
+ - :code:`a.sp(b)`
153
+ * - Left-contraction
154
+ - $a \\rfloor b$
155
+ -
156
+ - :code:`a.lc(b)`
157
+ * - Right-contraction
158
+ - $a \\lfloor b$
159
+ -
160
+ - :code:`a.rc(b)`
161
+ * - Outer (Exterior)
162
+ - $a \\wedge b$
163
+ - :code:`a ^ b`
164
+ - :code:`a.op(b)`
165
+ * - Regressive
166
+ - $a \\vee b$
167
+ - :code:`a & b`
168
+ - :code:`a.rp(b)`
169
+ * - Conjugate :code:`b` by :code:`a`
170
+ - $a b \\widetilde{a}$
171
+ - :code:`a >> b`
172
+ - :code:`a.sw(b)`
173
+ * - Project :code:`a` onto :code:`b`
174
+ - $(a \\cdot b) \\widetilde{b}$
175
+ - :code:`a @ b`
176
+ - :code:`a.proj(b)`
177
+ * - Commutator of :code:`a` and :code:`b`
178
+ - $a \\times b = \\tfrac{1}{2} [a, b]$
179
+ -
180
+ - :code:`a.cp(b)`
181
+ * - Anti-commutator of :code:`a` and :code:`b`
182
+ - $\\tfrac{1}{2} \\{a, b\\}$
183
+ -
184
+ - :code:`a.acp(b)`
185
+ * - Sum of :code:`a` and :code:`b`
186
+ - :math:`a + b`
187
+ - :code:`a + b`
188
+ - :code:`a.add(b)`
189
+ * - Difference of :code:`a` and :code:`b`
190
+ - :math:`a - b`
191
+ - :code:`a - b`
192
+ - :code:`a.sub(b)`
193
+ * - Reverse of :code:`a`
194
+ - :math:`\\widetilde{a}`
195
+ - :code:`~a`
196
+ - :code:`a.reverse()`
197
+ * - Squared norm of :code:`a`
198
+ - :math:`a \\widetilde{a}`
199
+ -
200
+ - :code:`a.normsq()`
201
+ * - Norm of :code:`a`
202
+ - :math:`\\sqrt{a \\widetilde{a}}`
203
+ -
204
+ - :code:`a.norm()`
205
+ * - Normalize :code:`a`
206
+ - :math:`a / \\sqrt{a \\widetilde{a}}`
207
+ -
208
+ - :code:`a.normalized()`
209
+ * - Square root of :code:`a`
210
+ - :math:`\\sqrt{a}`
211
+ -
212
+ - :code:`a.sqrt()`
213
+
214
+ Credits
215
+ -------
216
+
217
+ This package was inspired by GAmphetamine.js.
218
+
219
+
220
+ =======
221
+ History
222
+ =======
223
+
224
+ 0.1.0 (2023-08-12)
225
+ ------------------
226
+
227
+ * First release on PyPI.
@@ -0,0 +1,196 @@
1
+ =======
2
+ Kingdon
3
+ =======
4
+
5
+
6
+ .. image:: https://img.shields.io/pypi/v/kingdon.svg
7
+ :target: https://pypi.python.org/pypi/kingdon
8
+
9
+ .. image:: https://img.shields.io/travis/tbuli/kingdon.svg
10
+ :target: https://travis-ci.com/tbuli/kingdon
11
+
12
+ .. image:: https://readthedocs.org/projects/kingdon/badge/?version=latest
13
+ :target: https://kingdon.readthedocs.io/en/latest/?version=latest
14
+ :alt: Documentation Status
15
+
16
+ .. image:: https://coveralls.io/repos/github/tBuLi/kingdon/badge.svg?branch=master
17
+ :target: https://coveralls.io/github/tBuLi/kingdon?branch=master
18
+
19
+
20
+
21
+ Pythonic Geometric Algebra Package
22
+
23
+
24
+ * Free software: MIT license
25
+ * Documentation: https://kingdon.readthedocs.io.
26
+
27
+
28
+ Features
29
+ --------
30
+
31
+ Kingdon is a Geometric Algebra (GA) library which combines a Pythonic API with
32
+ symbolic simplification and just-in-time compilation to achieve high-performance in a single package.
33
+ It support both symbolic and numerical GA computations.
34
+ Moreover, :code:`kingdon` uses :code:`ganja.js` for visualization in notebooks,
35
+ making it an extremely well rounded GA package.
36
+
37
+ In bullet points:
38
+
39
+ - Symbolically optimized.
40
+ - Leverage sparseness of input.
41
+ - :code:`numba` enabled for numerical computations.
42
+ - :code:`sympy` support for symbolic computations.
43
+ - :code:`ganja.js` enabled graphics in jupyter notebooks.
44
+ - Automatic broadcasting, such that transformations can be applied to e.g. point-clouds.
45
+
46
+ Code Example
47
+ ------------
48
+ In order to demonstrate the power of :code:`Kingdon`, let us first consider the common use-case of the
49
+ commutator product between a bivector and vector.
50
+
51
+ In order to create an algebra, use :code:`Algebra`. When calling :code:`Algebra` we must provide the signature of the
52
+ algebra, in this case we shall go for 3DPGA, which is the algebra :math:`\mathbb{R}_{3,0,1}`.
53
+ There are a number of ways to make elements of the algebra. It can be convenient to work with the basis blades directly.
54
+ We can add them to the local namespace by calling :code:`locals().update(alg.blades)`:
55
+
56
+ .. code-block:: python
57
+
58
+ >>> from kingdon import Algebra
59
+ >>> alg = Algebra(3, 0, 1)
60
+ >>> locals().update(alg.blades)
61
+ >>> b = 2 * e12
62
+ >>> v = 3 * e1
63
+ >>> b.cp(v)
64
+ (-6) * e2
65
+
66
+ This example shows that only the :code:`e2` coefficient is calculated, despite the fact that there are
67
+ 6 bivector and 4 vector coefficients in 3DPGA. But by exploiting the sparseness of the input and by performing symbolic
68
+ optimization, :code:`kingdon` knows that in this case only :code:`e2` can be non-zero.
69
+
70
+ Symbolic usage
71
+ --------------
72
+ If only a name is provided for a multivector, :code:`kingdon` will automatically populate all
73
+ relevant fields with symbols. This allows us to easily perform symbolic computations.
74
+
75
+ .. code-block:: python
76
+
77
+ >>> from kingdon import Algebra
78
+ >>> alg = Algebra(3, 0, 1)
79
+ >>> b = alg.bivector(name='b')
80
+ >>> b
81
+ (b12) * e12 + (b13) * e13 + (b23) * e23 + (b14) * e14 + (b24) * e24 + (b34) * e34
82
+ >>> v = alg.vector(name='v')
83
+ >>> v
84
+ (v1) * e1 + (v2) * e2 + (v3) * e3 + (v4) * e4
85
+ >>> b.cp(v)
86
+ (-b12*v1 + b23*v3) * e2 + (b12*v2 + b13*v3) * e1 + (-b13*v1 - b23*v2) * e3 + (-b14*v1 - b24*v2 - b34*v3) * e4
87
+
88
+ It is also possible to define some coefficients to be symbolic by inputting a string, while others can be numeric::
89
+
90
+ >>> from kingdon import Algebra, symbols
91
+ >>> alg = Algebra(3, 0, 1)
92
+ >>> b = alg.bivector(e12='b12', e34=3)
93
+ >>> b
94
+ (b12) * e12 + (3) * e34
95
+ >>> v = alg.vector(e1=1, e3=1)
96
+ >>> v
97
+ (1) * e1 + (1) * e3
98
+ >>> w = b.cp(v)
99
+ >>> w
100
+ (-b12) * e2 + (-3) * e4
101
+
102
+
103
+ A :code:`kingdon` MultiVector with symbols is callable. So in order to evaluate :code:`w` from the previous example,
104
+ for a specific value of :code:`b12`, simply call :code:`w`::
105
+
106
+ >>> w(b12=10)
107
+ (-10) * e2 + (-3) * e4
108
+
109
+
110
+ Overview of Operators
111
+ =====================
112
+ .. list-table:: Operators
113
+ :widths: 50 25 25 25
114
+ :header-rows: 1
115
+
116
+ * - Operation
117
+ - Expression
118
+ - Infix
119
+ - Inline
120
+ * - Geometric product
121
+ - $ab$
122
+ - :code:`a*b`
123
+ - :code:`a.gp(b)`
124
+ * - Inner
125
+ - $a \\cdot b$
126
+ - :code:`a|b`
127
+ - :code:`a.ip(b)`
128
+ * - Scalar product
129
+ - $\\langle a \\cdot b \\rangle_0$
130
+ -
131
+ - :code:`a.sp(b)`
132
+ * - Left-contraction
133
+ - $a \\rfloor b$
134
+ -
135
+ - :code:`a.lc(b)`
136
+ * - Right-contraction
137
+ - $a \\lfloor b$
138
+ -
139
+ - :code:`a.rc(b)`
140
+ * - Outer (Exterior)
141
+ - $a \\wedge b$
142
+ - :code:`a ^ b`
143
+ - :code:`a.op(b)`
144
+ * - Regressive
145
+ - $a \\vee b$
146
+ - :code:`a & b`
147
+ - :code:`a.rp(b)`
148
+ * - Conjugate :code:`b` by :code:`a`
149
+ - $a b \\widetilde{a}$
150
+ - :code:`a >> b`
151
+ - :code:`a.sw(b)`
152
+ * - Project :code:`a` onto :code:`b`
153
+ - $(a \\cdot b) \\widetilde{b}$
154
+ - :code:`a @ b`
155
+ - :code:`a.proj(b)`
156
+ * - Commutator of :code:`a` and :code:`b`
157
+ - $a \\times b = \\tfrac{1}{2} [a, b]$
158
+ -
159
+ - :code:`a.cp(b)`
160
+ * - Anti-commutator of :code:`a` and :code:`b`
161
+ - $\\tfrac{1}{2} \\{a, b\\}$
162
+ -
163
+ - :code:`a.acp(b)`
164
+ * - Sum of :code:`a` and :code:`b`
165
+ - :math:`a + b`
166
+ - :code:`a + b`
167
+ - :code:`a.add(b)`
168
+ * - Difference of :code:`a` and :code:`b`
169
+ - :math:`a - b`
170
+ - :code:`a - b`
171
+ - :code:`a.sub(b)`
172
+ * - Reverse of :code:`a`
173
+ - :math:`\\widetilde{a}`
174
+ - :code:`~a`
175
+ - :code:`a.reverse()`
176
+ * - Squared norm of :code:`a`
177
+ - :math:`a \\widetilde{a}`
178
+ -
179
+ - :code:`a.normsq()`
180
+ * - Norm of :code:`a`
181
+ - :math:`\\sqrt{a \\widetilde{a}}`
182
+ -
183
+ - :code:`a.norm()`
184
+ * - Normalize :code:`a`
185
+ - :math:`a / \\sqrt{a \\widetilde{a}}`
186
+ -
187
+ - :code:`a.normalized()`
188
+ * - Square root of :code:`a`
189
+ - :math:`\\sqrt{a}`
190
+ -
191
+ - :code:`a.sqrt()`
192
+
193
+ Credits
194
+ -------
195
+
196
+ This package was inspired by GAmphetamine.js.
@@ -0,0 +1,20 @@
1
+ # Minimal makefile for Sphinx documentation
2
+ #
3
+
4
+ # You can set these variables from the command line.
5
+ SPHINXOPTS =
6
+ SPHINXBUILD = python -msphinx
7
+ SPHINXPROJ = kingdon
8
+ SOURCEDIR = .
9
+ BUILDDIR = _build
10
+
11
+ # Put it first so that "make" without argument is like "make help".
12
+ help:
13
+ @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
14
+
15
+ .PHONY: help Makefile
16
+
17
+ # Catch-all target: route all unknown targets to Sphinx using the new
18
+ # "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
19
+ %: Makefile
20
+ @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
@@ -0,0 +1 @@
1
+ .. include:: ../AUTHORS.rst