glucat  0.8.2
PyClical_nocython.cpp
Go to the documentation of this file.
1 /* Generated by Cython 0.23.4 */
2 
3 /* BEGIN: Cython Metadata
4 {
5  "distutils": {
6  "depends": [
7  "PyClical.h"
8  ],
9  "extra_compile_args": [
10  "-I.",
11  "-I..",
12  "-I/home/leopardi/src/boost-numeric-bindings/numeric_bindings",
13  "-fno-strict-aliasing",
14  "-Wno-unused",
15  "-Wall",
16  "-std=c++11",
17  "-g",
18  "-O3",
19  "-march=native",
20  "-finline-limit=4000",
21  "--param",
22  "inline-unit-growth=200",
23  "-funroll-loops",
24  "-fvariable-expansion-in-unroller",
25  "-DNDEBUG",
26  "-DHAVE_BITS_WORDSIZE_H",
27  "-D_GLUCAT_USE_STD_UNORDERED_MAP",
28  "-D_GLUCAT_USE_QD",
29  "-D_GLUCAT_USE_EIGENVALUES",
30  "-D_GLUCAT_USE_BINDINGS",
31  "-D_GLUCAT_USE_DENSE_MATRICES",
32  "-D_GLUCAT_CHECK_ISNAN",
33  "-Wno-unused-local-typedefs",
34  "-Wno-misleading-indentation",
35  "-fno-check-new",
36  "-fexceptions"
37  ],
38  "extra_link_args": [
39  "-lqd",
40  "-llapack",
41  "-lblas"
42  ],
43  "include_dirs": [
44  ".",
45  ".."
46  ],
47  "language": "c++"
48  }
49 }
50 END: Cython Metadata */
51 
52 #define PY_SSIZE_T_CLEAN
53 #include "Python.h"
54 #ifndef Py_PYTHON_H
55  #error Python headers needed to compile C extensions, please install development version of Python.
56 #elif PY_VERSION_HEX < 0x02060000 || (0x03000000 <= PY_VERSION_HEX && PY_VERSION_HEX < 0x03020000)
57  #error Cython requires Python 2.6+ or Python 3.2+.
58 #else
59 #define CYTHON_ABI "0_23_4"
60 #include <stddef.h>
61 #ifndef offsetof
62 #define offsetof(type, member) ( (size_t) & ((type*)0) -> member )
63 #endif
64 #if !defined(WIN32) && !defined(MS_WINDOWS)
65  #ifndef __stdcall
66  #define __stdcall
67  #endif
68  #ifndef __cdecl
69  #define __cdecl
70  #endif
71  #ifndef __fastcall
72  #define __fastcall
73  #endif
74 #endif
75 #ifndef DL_IMPORT
76  #define DL_IMPORT(t) t
77 #endif
78 #ifndef DL_EXPORT
79  #define DL_EXPORT(t) t
80 #endif
81 #ifndef PY_LONG_LONG
82  #define PY_LONG_LONG LONG_LONG
83 #endif
84 #ifndef Py_HUGE_VAL
85  #define Py_HUGE_VAL HUGE_VAL
86 #endif
87 #ifdef PYPY_VERSION
88 #define CYTHON_COMPILING_IN_PYPY 1
89 #define CYTHON_COMPILING_IN_CPYTHON 0
90 #else
91 #define CYTHON_COMPILING_IN_PYPY 0
92 #define CYTHON_COMPILING_IN_CPYTHON 1
93 #endif
94 #if !defined(CYTHON_USE_PYLONG_INTERNALS) && CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x02070000
95 #define CYTHON_USE_PYLONG_INTERNALS 1
96 #endif
97 #if CYTHON_COMPILING_IN_PYPY && PY_VERSION_HEX < 0x02070600 && !defined(Py_OptimizeFlag)
98 #define Py_OptimizeFlag 0
99 #endif
100 #define __PYX_BUILD_PY_SSIZE_T "n"
101 #define CYTHON_FORMAT_SSIZE_T "z"
102 #if PY_MAJOR_VERSION < 3
103  #define __Pyx_BUILTIN_MODULE_NAME "__builtin__"
104  #define __Pyx_PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)\
105  PyCode_New(a+k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)
106  #define __Pyx_DefaultClassType PyClass_Type
107 #else
108  #define __Pyx_BUILTIN_MODULE_NAME "builtins"
109  #define __Pyx_PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)\
110  PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)
111  #define __Pyx_DefaultClassType PyType_Type
112 #endif
113 #ifndef Py_TPFLAGS_CHECKTYPES
114  #define Py_TPFLAGS_CHECKTYPES 0
115 #endif
116 #ifndef Py_TPFLAGS_HAVE_INDEX
117  #define Py_TPFLAGS_HAVE_INDEX 0
118 #endif
119 #ifndef Py_TPFLAGS_HAVE_NEWBUFFER
120  #define Py_TPFLAGS_HAVE_NEWBUFFER 0
121 #endif
122 #ifndef Py_TPFLAGS_HAVE_FINALIZE
123  #define Py_TPFLAGS_HAVE_FINALIZE 0
124 #endif
125 #if PY_VERSION_HEX > 0x03030000 && defined(PyUnicode_KIND)
126  #define CYTHON_PEP393_ENABLED 1
127  #define __Pyx_PyUnicode_READY(op) (likely(PyUnicode_IS_READY(op)) ?\
128  0 : _PyUnicode_Ready((PyObject *)(op)))
129  #define __Pyx_PyUnicode_GET_LENGTH(u) PyUnicode_GET_LENGTH(u)
130  #define __Pyx_PyUnicode_READ_CHAR(u, i) PyUnicode_READ_CHAR(u, i)
131  #define __Pyx_PyUnicode_KIND(u) PyUnicode_KIND(u)
132  #define __Pyx_PyUnicode_DATA(u) PyUnicode_DATA(u)
133  #define __Pyx_PyUnicode_READ(k, d, i) PyUnicode_READ(k, d, i)
134 #else
135  #define CYTHON_PEP393_ENABLED 0
136  #define __Pyx_PyUnicode_READY(op) (0)
137  #define __Pyx_PyUnicode_GET_LENGTH(u) PyUnicode_GET_SIZE(u)
138  #define __Pyx_PyUnicode_READ_CHAR(u, i) ((Py_UCS4)(PyUnicode_AS_UNICODE(u)[i]))
139  #define __Pyx_PyUnicode_KIND(u) (sizeof(Py_UNICODE))
140  #define __Pyx_PyUnicode_DATA(u) ((void*)PyUnicode_AS_UNICODE(u))
141  #define __Pyx_PyUnicode_READ(k, d, i) ((void)(k), (Py_UCS4)(((Py_UNICODE*)d)[i]))
142 #endif
143 #if CYTHON_COMPILING_IN_PYPY
144  #define __Pyx_PyUnicode_Concat(a, b) PyNumber_Add(a, b)
145  #define __Pyx_PyUnicode_ConcatSafe(a, b) PyNumber_Add(a, b)
146 #else
147  #define __Pyx_PyUnicode_Concat(a, b) PyUnicode_Concat(a, b)
148  #define __Pyx_PyUnicode_ConcatSafe(a, b) ((unlikely((a) == Py_None) || unlikely((b) == Py_None)) ?\
149  PyNumber_Add(a, b) : __Pyx_PyUnicode_Concat(a, b))
150 #endif
151 #if CYTHON_COMPILING_IN_PYPY && !defined(PyUnicode_Contains)
152  #define PyUnicode_Contains(u, s) PySequence_Contains(u, s)
153 #endif
154 #define __Pyx_PyString_FormatSafe(a, b) ((unlikely((a) == Py_None)) ? PyNumber_Remainder(a, b) : __Pyx_PyString_Format(a, b))
155 #define __Pyx_PyUnicode_FormatSafe(a, b) ((unlikely((a) == Py_None)) ? PyNumber_Remainder(a, b) : PyUnicode_Format(a, b))
156 #if PY_MAJOR_VERSION >= 3
157  #define __Pyx_PyString_Format(a, b) PyUnicode_Format(a, b)
158 #else
159  #define __Pyx_PyString_Format(a, b) PyString_Format(a, b)
160 #endif
161 #if PY_MAJOR_VERSION >= 3
162  #define PyBaseString_Type PyUnicode_Type
163  #define PyStringObject PyUnicodeObject
164  #define PyString_Type PyUnicode_Type
165  #define PyString_Check PyUnicode_Check
166  #define PyString_CheckExact PyUnicode_CheckExact
167 #endif
168 #if PY_MAJOR_VERSION >= 3
169  #define __Pyx_PyBaseString_Check(obj) PyUnicode_Check(obj)
170  #define __Pyx_PyBaseString_CheckExact(obj) PyUnicode_CheckExact(obj)
171 #else
172  #define __Pyx_PyBaseString_Check(obj) (PyString_Check(obj) || PyUnicode_Check(obj))
173  #define __Pyx_PyBaseString_CheckExact(obj) (PyString_CheckExact(obj) || PyUnicode_CheckExact(obj))
174 #endif
175 #ifndef PySet_CheckExact
176  #define PySet_CheckExact(obj) (Py_TYPE(obj) == &PySet_Type)
177 #endif
178 #define __Pyx_TypeCheck(obj, type) PyObject_TypeCheck(obj, (PyTypeObject *)type)
179 #if PY_MAJOR_VERSION >= 3
180  #define PyIntObject PyLongObject
181  #define PyInt_Type PyLong_Type
182  #define PyInt_Check(op) PyLong_Check(op)
183  #define PyInt_CheckExact(op) PyLong_CheckExact(op)
184  #define PyInt_FromString PyLong_FromString
185  #define PyInt_FromUnicode PyLong_FromUnicode
186  #define PyInt_FromLong PyLong_FromLong
187  #define PyInt_FromSize_t PyLong_FromSize_t
188  #define PyInt_FromSsize_t PyLong_FromSsize_t
189  #define PyInt_AsLong PyLong_AsLong
190  #define PyInt_AS_LONG PyLong_AS_LONG
191  #define PyInt_AsSsize_t PyLong_AsSsize_t
192  #define PyInt_AsUnsignedLongMask PyLong_AsUnsignedLongMask
193  #define PyInt_AsUnsignedLongLongMask PyLong_AsUnsignedLongLongMask
194  #define PyNumber_Int PyNumber_Long
195 #endif
196 #if PY_MAJOR_VERSION >= 3
197  #define PyBoolObject PyLongObject
198 #endif
199 #if PY_MAJOR_VERSION >= 3 && CYTHON_COMPILING_IN_PYPY
200  #ifndef PyUnicode_InternFromString
201  #define PyUnicode_InternFromString(s) PyUnicode_FromString(s)
202  #endif
203 #endif
204 #if PY_VERSION_HEX < 0x030200A4
205  typedef long Py_hash_t;
206  #define __Pyx_PyInt_FromHash_t PyInt_FromLong
207  #define __Pyx_PyInt_AsHash_t PyInt_AsLong
208 #else
209  #define __Pyx_PyInt_FromHash_t PyInt_FromSsize_t
210  #define __Pyx_PyInt_AsHash_t PyInt_AsSsize_t
211 #endif
212 #if PY_MAJOR_VERSION >= 3
213  #define __Pyx_PyMethod_New(func, self, klass) ((self) ? PyMethod_New(func, self) : PyInstanceMethod_New(func))
214 #else
215  #define __Pyx_PyMethod_New(func, self, klass) PyMethod_New(func, self, klass)
216 #endif
217 #if PY_VERSION_HEX >= 0x030500B1
218 #define __Pyx_PyAsyncMethodsStruct PyAsyncMethods
219 #define __Pyx_PyType_AsAsync(obj) (Py_TYPE(obj)->tp_as_async)
220 #elif CYTHON_COMPILING_IN_CPYTHON && PY_MAJOR_VERSION >= 3
221 typedef struct {
222  unaryfunc am_await;
223  unaryfunc am_aiter;
224  unaryfunc am_anext;
225 } __Pyx_PyAsyncMethodsStruct;
226 #define __Pyx_PyType_AsAsync(obj) ((__Pyx_PyAsyncMethodsStruct*) (Py_TYPE(obj)->tp_reserved))
227 #else
228 #define __Pyx_PyType_AsAsync(obj) NULL
229 #endif
230 #ifndef CYTHON_RESTRICT
231  #if defined(__GNUC__)
232  #define CYTHON_RESTRICT __restrict__
233  #elif defined(_MSC_VER) && _MSC_VER >= 1400
234  #define CYTHON_RESTRICT __restrict
235  #elif defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
236  #define CYTHON_RESTRICT restrict
237  #else
238  #define CYTHON_RESTRICT
239  #endif
240 #endif
241 #define __Pyx_void_to_None(void_result) ((void)(void_result), Py_INCREF(Py_None), Py_None)
242 
243 #ifndef __cplusplus
244  #error "Cython files generated with the C++ option must be compiled with a C++ compiler."
245 #endif
246 #ifndef CYTHON_INLINE
247  #define CYTHON_INLINE inline
248 #endif
249 template<typename T>
250 void __Pyx_call_destructor(T& x) {
251  x.~T();
252 }
253 template<typename T>
254 class __Pyx_FakeReference {
255  public:
256  __Pyx_FakeReference() : ptr(NULL) { }
257  __Pyx_FakeReference(const T& ref) : ptr(const_cast<T*>(&ref)) { }
258  T *operator->() { return ptr; }
259  operator T&() { return *ptr; }
260  private:
261  T *ptr;
262 };
263 
264 #if defined(WIN32) || defined(MS_WINDOWS)
265  #define _USE_MATH_DEFINES
266 #endif
267 #include <math.h>
268 #ifdef NAN
269 #define __PYX_NAN() ((float) NAN)
270 #else
271 static CYTHON_INLINE float __PYX_NAN() {
272  float value;
273  memset(&value, 0xFF, sizeof(value));
274  return value;
275 }
276 #endif
277 
278 
279 #if PY_MAJOR_VERSION >= 3
280  #define __Pyx_PyNumber_Divide(x,y) PyNumber_TrueDivide(x,y)
281  #define __Pyx_PyNumber_InPlaceDivide(x,y) PyNumber_InPlaceTrueDivide(x,y)
282 #else
283  #define __Pyx_PyNumber_Divide(x,y) PyNumber_Divide(x,y)
284  #define __Pyx_PyNumber_InPlaceDivide(x,y) PyNumber_InPlaceDivide(x,y)
285 #endif
286 
287 #ifndef __PYX_EXTERN_C
288  #ifdef __cplusplus
289  #define __PYX_EXTERN_C extern "C"
290  #else
291  #define __PYX_EXTERN_C extern
292  #endif
293 #endif
294 
295 #define __PYX_HAVE__PyClical
296 #define __PYX_HAVE_API__PyClical
297 #include <vector>
298 #include "ios"
299 #include "new"
300 #include "stdexcept"
301 #include "typeinfo"
302 #include "PyClical.h"
303 #ifdef _OPENMP
304 #include <omp.h>
305 #endif /* _OPENMP */
306 
307 #ifdef PYREX_WITHOUT_ASSERTIONS
308 #define CYTHON_WITHOUT_ASSERTIONS
309 #endif
310 
311 #ifndef CYTHON_UNUSED
312 # if defined(__GNUC__)
313 # if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
314 # define CYTHON_UNUSED __attribute__ ((__unused__))
315 # else
316 # define CYTHON_UNUSED
317 # endif
318 # elif defined(__ICC) || (defined(__INTEL_COMPILER) && !defined(_MSC_VER))
319 # define CYTHON_UNUSED __attribute__ ((__unused__))
320 # else
321 # define CYTHON_UNUSED
322 # endif
323 #endif
324 #ifndef CYTHON_NCP_UNUSED
325 # if CYTHON_COMPILING_IN_CPYTHON
326 # define CYTHON_NCP_UNUSED
327 # else
328 # define CYTHON_NCP_UNUSED CYTHON_UNUSED
329 # endif
330 #endif
331 typedef struct {PyObject **p; char *s; const Py_ssize_t n; const char* encoding;
332  const char is_unicode; const char is_str; const char intern; } __Pyx_StringTabEntry;
333 
334 #define __PYX_DEFAULT_STRING_ENCODING_IS_ASCII 0
335 #define __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT 0
336 #define __PYX_DEFAULT_STRING_ENCODING ""
337 #define __Pyx_PyObject_FromString __Pyx_PyBytes_FromString
338 #define __Pyx_PyObject_FromStringAndSize __Pyx_PyBytes_FromStringAndSize
339 #define __Pyx_uchar_cast(c) ((unsigned char)c)
340 #define __Pyx_long_cast(x) ((long)x)
341 #define __Pyx_fits_Py_ssize_t(v, type, is_signed) (\
342  (sizeof(type) < sizeof(Py_ssize_t)) ||\
343  (sizeof(type) > sizeof(Py_ssize_t) &&\
344  likely(v < (type)PY_SSIZE_T_MAX ||\
345  v == (type)PY_SSIZE_T_MAX) &&\
346  (!is_signed || likely(v > (type)PY_SSIZE_T_MIN ||\
347  v == (type)PY_SSIZE_T_MIN))) ||\
348  (sizeof(type) == sizeof(Py_ssize_t) &&\
349  (is_signed || likely(v < (type)PY_SSIZE_T_MAX ||\
350  v == (type)PY_SSIZE_T_MAX))) )
351 #if defined (__cplusplus) && __cplusplus >= 201103L
352  #include <cstdlib>
353  #define __Pyx_sst_abs(value) std::abs(value)
354 #elif SIZEOF_INT >= SIZEOF_SIZE_T
355  #define __Pyx_sst_abs(value) abs(value)
356 #elif SIZEOF_LONG >= SIZEOF_SIZE_T
357  #define __Pyx_sst_abs(value) labs(value)
358 #elif defined (_MSC_VER) && defined (_M_X64)
359  #define __Pyx_sst_abs(value) _abs64(value)
360 #elif defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
361  #define __Pyx_sst_abs(value) llabs(value)
362 #elif defined (__GNUC__)
363  #define __Pyx_sst_abs(value) __builtin_llabs(value)
364 #else
365  #define __Pyx_sst_abs(value) ((value<0) ? -value : value)
366 #endif
367 static CYTHON_INLINE char* __Pyx_PyObject_AsString(PyObject*);
368 static CYTHON_INLINE char* __Pyx_PyObject_AsStringAndSize(PyObject*, Py_ssize_t* length);
369 #define __Pyx_PyByteArray_FromString(s) PyByteArray_FromStringAndSize((const char*)s, strlen((const char*)s))
370 #define __Pyx_PyByteArray_FromStringAndSize(s, l) PyByteArray_FromStringAndSize((const char*)s, l)
371 #define __Pyx_PyBytes_FromString PyBytes_FromString
372 #define __Pyx_PyBytes_FromStringAndSize PyBytes_FromStringAndSize
373 static CYTHON_INLINE PyObject* __Pyx_PyUnicode_FromString(const char*);
374 #if PY_MAJOR_VERSION < 3
375  #define __Pyx_PyStr_FromString __Pyx_PyBytes_FromString
376  #define __Pyx_PyStr_FromStringAndSize __Pyx_PyBytes_FromStringAndSize
377 #else
378  #define __Pyx_PyStr_FromString __Pyx_PyUnicode_FromString
379  #define __Pyx_PyStr_FromStringAndSize __Pyx_PyUnicode_FromStringAndSize
380 #endif
381 #define __Pyx_PyObject_AsSString(s) ((signed char*) __Pyx_PyObject_AsString(s))
382 #define __Pyx_PyObject_AsUString(s) ((unsigned char*) __Pyx_PyObject_AsString(s))
383 #define __Pyx_PyObject_FromCString(s) __Pyx_PyObject_FromString((const char*)s)
384 #define __Pyx_PyBytes_FromCString(s) __Pyx_PyBytes_FromString((const char*)s)
385 #define __Pyx_PyByteArray_FromCString(s) __Pyx_PyByteArray_FromString((const char*)s)
386 #define __Pyx_PyStr_FromCString(s) __Pyx_PyStr_FromString((const char*)s)
387 #define __Pyx_PyUnicode_FromCString(s) __Pyx_PyUnicode_FromString((const char*)s)
388 #if PY_MAJOR_VERSION < 3
389 static CYTHON_INLINE size_t __Pyx_Py_UNICODE_strlen(const Py_UNICODE *u)
390 {
391  const Py_UNICODE *u_end = u;
392  while (*u_end++) ;
393  return (size_t)(u_end - u - 1);
394 }
395 #else
396 #define __Pyx_Py_UNICODE_strlen Py_UNICODE_strlen
397 #endif
398 #define __Pyx_PyUnicode_FromUnicode(u) PyUnicode_FromUnicode(u, __Pyx_Py_UNICODE_strlen(u))
399 #define __Pyx_PyUnicode_FromUnicodeAndLength PyUnicode_FromUnicode
400 #define __Pyx_PyUnicode_AsUnicode PyUnicode_AsUnicode
401 #define __Pyx_NewRef(obj) (Py_INCREF(obj), obj)
402 #define __Pyx_Owned_Py_None(b) __Pyx_NewRef(Py_None)
403 #define __Pyx_PyBool_FromLong(b) ((b) ? __Pyx_NewRef(Py_True) : __Pyx_NewRef(Py_False))
404 static CYTHON_INLINE int __Pyx_PyObject_IsTrue(PyObject*);
405 static CYTHON_INLINE PyObject* __Pyx_PyNumber_Int(PyObject* x);
406 static CYTHON_INLINE Py_ssize_t __Pyx_PyIndex_AsSsize_t(PyObject*);
407 static CYTHON_INLINE PyObject * __Pyx_PyInt_FromSize_t(size_t);
408 #if CYTHON_COMPILING_IN_CPYTHON
409 #define __pyx_PyFloat_AsDouble(x) (PyFloat_CheckExact(x) ? PyFloat_AS_DOUBLE(x) : PyFloat_AsDouble(x))
410 #else
411 #define __pyx_PyFloat_AsDouble(x) PyFloat_AsDouble(x)
412 #endif
413 #define __pyx_PyFloat_AsFloat(x) ((float) __pyx_PyFloat_AsDouble(x))
414 #if PY_MAJOR_VERSION < 3 && __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
415 static int __Pyx_sys_getdefaultencoding_not_ascii;
416 static int __Pyx_init_sys_getdefaultencoding_params(void) {
417  PyObject* sys;
418  PyObject* default_encoding = NULL;
419  PyObject* ascii_chars_u = NULL;
420  PyObject* ascii_chars_b = NULL;
421  const char* default_encoding_c;
422  sys = PyImport_ImportModule("sys");
423  if (!sys) goto bad;
424  default_encoding = PyObject_CallMethod(sys, (char*) "getdefaultencoding", NULL);
425  Py_DECREF(sys);
426  if (!default_encoding) goto bad;
427  default_encoding_c = PyBytes_AsString(default_encoding);
428  if (!default_encoding_c) goto bad;
429  if (strcmp(default_encoding_c, "ascii") == 0) {
430  __Pyx_sys_getdefaultencoding_not_ascii = 0;
431  } else {
432  char ascii_chars[128];
433  int c;
434  for (c = 0; c < 128; c++) {
435  ascii_chars[c] = c;
436  }
437  __Pyx_sys_getdefaultencoding_not_ascii = 1;
438  ascii_chars_u = PyUnicode_DecodeASCII(ascii_chars, 128, NULL);
439  if (!ascii_chars_u) goto bad;
440  ascii_chars_b = PyUnicode_AsEncodedString(ascii_chars_u, default_encoding_c, NULL);
441  if (!ascii_chars_b || !PyBytes_Check(ascii_chars_b) || memcmp(ascii_chars, PyBytes_AS_STRING(ascii_chars_b), 128) != 0) {
442  PyErr_Format(
443  PyExc_ValueError,
444  "This module compiled with c_string_encoding=ascii, but default encoding '%.200s' is not a superset of ascii.",
445  default_encoding_c);
446  goto bad;
447  }
448  Py_DECREF(ascii_chars_u);
449  Py_DECREF(ascii_chars_b);
450  }
451  Py_DECREF(default_encoding);
452  return 0;
453 bad:
454  Py_XDECREF(default_encoding);
455  Py_XDECREF(ascii_chars_u);
456  Py_XDECREF(ascii_chars_b);
457  return -1;
458 }
459 #endif
460 #if __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT && PY_MAJOR_VERSION >= 3
461 #define __Pyx_PyUnicode_FromStringAndSize(c_str, size) PyUnicode_DecodeUTF8(c_str, size, NULL)
462 #else
463 #define __Pyx_PyUnicode_FromStringAndSize(c_str, size) PyUnicode_Decode(c_str, size, __PYX_DEFAULT_STRING_ENCODING, NULL)
464 #if __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT
465 static char* __PYX_DEFAULT_STRING_ENCODING;
466 static int __Pyx_init_sys_getdefaultencoding_params(void) {
467  PyObject* sys;
468  PyObject* default_encoding = NULL;
469  char* default_encoding_c;
470  sys = PyImport_ImportModule("sys");
471  if (!sys) goto bad;
472  default_encoding = PyObject_CallMethod(sys, (char*) (const char*) "getdefaultencoding", NULL);
473  Py_DECREF(sys);
474  if (!default_encoding) goto bad;
475  default_encoding_c = PyBytes_AsString(default_encoding);
476  if (!default_encoding_c) goto bad;
477  __PYX_DEFAULT_STRING_ENCODING = (char*) malloc(strlen(default_encoding_c));
478  if (!__PYX_DEFAULT_STRING_ENCODING) goto bad;
479  strcpy(__PYX_DEFAULT_STRING_ENCODING, default_encoding_c);
480  Py_DECREF(default_encoding);
481  return 0;
482 bad:
483  Py_XDECREF(default_encoding);
484  return -1;
485 }
486 #endif
487 #endif
488 
489 
490 /* Test for GCC > 2.95 */
491 #if defined(__GNUC__) && (__GNUC__ > 2 || (__GNUC__ == 2 && (__GNUC_MINOR__ > 95)))
492  #define likely(x) __builtin_expect(!!(x), 1)
493  #define unlikely(x) __builtin_expect(!!(x), 0)
494 #else /* !__GNUC__ or GCC < 2.95 */
495  #define likely(x) (x)
496  #define unlikely(x) (x)
497 #endif /* __GNUC__ */
498 
499 static PyObject *__pyx_m;
500 static PyObject *__pyx_d;
501 static PyObject *__pyx_b;
502 static PyObject *__pyx_empty_tuple;
503 static PyObject *__pyx_empty_bytes;
504 static int __pyx_lineno;
505 static int __pyx_clineno = 0;
506 static const char * __pyx_cfilenm= __FILE__;
507 static const char *__pyx_filename;
508 
509 
510 static const char *__pyx_f[] = {
511  "PyClical.pyx",
512 };
513 
514 /*--- Type declarations ---*/
515 struct __pyx_obj_8PyClical_index_set;
516 struct __pyx_obj_8PyClical_clifford;
517 struct __pyx_obj_8PyClical___pyx_scope_struct____iter__;
518 struct __pyx_opt_args_8PyClical_sqrt;
519 struct __pyx_opt_args_8PyClical_log;
520 struct __pyx_opt_args_8PyClical_cos;
521 struct __pyx_opt_args_8PyClical_acos;
522 struct __pyx_opt_args_8PyClical_acosh;
523 struct __pyx_opt_args_8PyClical_sin;
524 struct __pyx_opt_args_8PyClical_asin;
525 struct __pyx_opt_args_8PyClical_asinh;
526 struct __pyx_opt_args_8PyClical_tan;
527 struct __pyx_opt_args_8PyClical_atan;
528 struct __pyx_opt_args_8PyClical_atanh;
529 struct __pyx_opt_args_8PyClical_random_clifford;
530 
531 /* "PyClical.pyx":1542
532  * return clifford().wrap( glucat.complexifier(toClifford(obj)) )
533  *
534  * cpdef inline sqrt(obj, i = None): # <<<<<<<<<<<<<<
535  * """
536  * Square root of multivector with optional complexifier.
537  */
538 struct __pyx_opt_args_8PyClical_sqrt {
539  int __pyx_n;
540  PyObject *i;
541 };
542 
543 /* "PyClical.pyx":1579
544  * return clifford().wrap( glucat.exp(toClifford(obj)) )
545  *
546  * cpdef inline log(obj,i = None): # <<<<<<<<<<<<<<
547  * """
548  * Natural logarithm of multivector with optional complexifier.
549  */
550 struct __pyx_opt_args_8PyClical_log {
551  int __pyx_n;
552  PyObject *i;
553 };
554 
555 /* "PyClical.pyx":1602
556  * return clifford().wrap( glucat.log(toClifford(obj)) )
557  *
558  * cpdef inline cos(obj,i = None): # <<<<<<<<<<<<<<
559  * """
560  * Cosine of multivector with optional complexifier.
561  */
562 struct __pyx_opt_args_8PyClical_cos {
563  int __pyx_n;
564  PyObject *i;
565 };
566 
567 /* "PyClical.pyx":1619
568  * return clifford().wrap( glucat.cos(toClifford(obj)) )
569  *
570  * cpdef inline acos(obj,i = None): # <<<<<<<<<<<<<<
571  * """
572  * Inverse cosine of multivector with optional complexifier.
573  */
574 struct __pyx_opt_args_8PyClical_acos {
575  int __pyx_n;
576  PyObject *i;
577 };
578 
579 /* "PyClical.pyx":1656
580  * return clifford().wrap( glucat.cosh(toClifford(obj)) )
581  *
582  * cpdef inline acosh(obj,i = None): # <<<<<<<<<<<<<<
583  * """
584  * Inverse hyperbolic cosine of multivector with optional complexifier.
585  */
586 struct __pyx_opt_args_8PyClical_acosh {
587  int __pyx_n;
588  PyObject *i;
589 };
590 
591 /* "PyClical.pyx":1679
592  * return clifford().wrap( glucat.acosh(toClifford(obj)) )
593  *
594  * cpdef inline sin(obj,i = None): # <<<<<<<<<<<<<<
595  * """
596  * Sine of multivector with optional complexifier.
597  */
598 struct __pyx_opt_args_8PyClical_sin {
599  int __pyx_n;
600  PyObject *i;
601 };
602 
603 /* "PyClical.pyx":1698
604  * return clifford().wrap( glucat.sin(toClifford(obj)) )
605  *
606  * cpdef inline asin(obj,i = None): # <<<<<<<<<<<<<<
607  * """
608  * Inverse sine of multivector with optional complexifier.
609  */
610 struct __pyx_opt_args_8PyClical_asin {
611  int __pyx_n;
612  PyObject *i;
613 };
614 
615 /* "PyClical.pyx":1733
616  * return clifford().wrap( glucat.sinh(toClifford(obj)) )
617  *
618  * cpdef inline asinh(obj,i = None): # <<<<<<<<<<<<<<
619  * """
620  * Inverse hyperbolic sine of multivector with optional complexifier.
621  */
622 struct __pyx_opt_args_8PyClical_asinh {
623  int __pyx_n;
624  PyObject *i;
625 };
626 
627 /* "PyClical.pyx":1752
628  * return clifford().wrap( glucat.asinh(toClifford(obj)) )
629  *
630  * cpdef inline tan(obj,i = None): # <<<<<<<<<<<<<<
631  * """
632  * Tangent of multivector with optional complexifier.
633  */
634 struct __pyx_opt_args_8PyClical_tan {
635  int __pyx_n;
636  PyObject *i;
637 };
638 
639 /* "PyClical.pyx":1769
640  * return clifford().wrap( glucat.tan(toClifford(obj)) )
641  *
642  * cpdef inline atan(obj,i = None): # <<<<<<<<<<<<<<
643  * """
644  * Inverse tangent of multivector with optional complexifier.
645  */
646 struct __pyx_opt_args_8PyClical_atan {
647  int __pyx_n;
648  PyObject *i;
649 };
650 
651 /* "PyClical.pyx":1798
652  * return clifford().wrap( glucat.tanh(toClifford(obj)) )
653  *
654  * cpdef inline atanh(obj,i = None): # <<<<<<<<<<<<<<
655  * """
656  * Inverse hyperbolic tangent of multivector with optional complexifier.
657  */
658 struct __pyx_opt_args_8PyClical_atanh {
659  int __pyx_n;
660  PyObject *i;
661 };
662 
663 /* "PyClical.pyx":1815
664  * return clifford().wrap( glucat.atanh(toClifford(obj)) )
665  *
666  * cpdef inline random_clifford(index_set ixt, fill = 1.0): # <<<<<<<<<<<<<<
667  * """
668  * Random multivector within a frame.
669  */
670 struct __pyx_opt_args_8PyClical_random_clifford {
671  int __pyx_n;
672  PyObject *fill;
673 };
674 
675 /* "PyClical.pyx":37
676  *
677  * # Forward reference
678  * cdef class index_set # <<<<<<<<<<<<<<
679  *
680  * cdef inline IndexSet toIndexSet(obj):
681  */
682 struct __pyx_obj_8PyClical_index_set {
683  PyObject_HEAD
684  struct __pyx_vtabstruct_8PyClical_index_set *__pyx_vtab;
685  IndexSet *instance;
686 };
687 
688 
689 /* "PyClical.pyx":530
690  *
691  * # Forward reference.
692  * cdef class clifford # <<<<<<<<<<<<<<
693  *
694  * cdef inline Clifford toClifford(obj):
695  */
696 struct __pyx_obj_8PyClical_clifford {
697  PyObject_HEAD
698  struct __pyx_vtabstruct_8PyClical_clifford *__pyx_vtab;
699  Clifford *instance;
700 };
701 
702 
703 /* "PyClical.pyx":227
704  * return self.instance.getitem(idx)
705  *
706  * def __iter__(self): # <<<<<<<<<<<<<<
707  * """
708  * Iterate over the indices of an index_set.
709  */
710 struct __pyx_obj_8PyClical___pyx_scope_struct____iter__ {
711  PyObject_HEAD
712  PyObject *__pyx_v_idx;
713  struct __pyx_obj_8PyClical_index_set *__pyx_v_self;
714  PyObject *__pyx_t_0;
715  Py_ssize_t __pyx_t_1;
716  PyObject *(*__pyx_t_2)(PyObject *);
717 };
718 
719 
720 
721 /* "PyClical.pyx":45
722  * return index_set(obj).instance[0]
723  *
724  * cdef class index_set: # <<<<<<<<<<<<<<
725  * """
726  * Python class index_set wraps C++ class IndexSet.
727  */
728 
729 struct __pyx_vtabstruct_8PyClical_index_set {
730  PyObject *(*wrap)(struct __pyx_obj_8PyClical_index_set *, IndexSet);
731  IndexSet (*unwrap)(struct __pyx_obj_8PyClical_index_set *);
732  PyObject *(*copy)(struct __pyx_obj_8PyClical_index_set *, int __pyx_skip_dispatch);
733 };
734 static struct __pyx_vtabstruct_8PyClical_index_set *__pyx_vtabptr_8PyClical_index_set;
735 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_9index_set_wrap(struct __pyx_obj_8PyClical_index_set *, IndexSet);
736 static CYTHON_INLINE IndexSet __pyx_f_8PyClical_9index_set_unwrap(struct __pyx_obj_8PyClical_index_set *);
737 
738 
739 /* "PyClical.pyx":535
740  * return clifford(obj).instance[0]
741  *
742  * cdef class clifford: # <<<<<<<<<<<<<<
743  * """
744  * Python class clifford wraps C++ class Clifford.
745  */
746 
747 struct __pyx_vtabstruct_8PyClical_clifford {
748  PyObject *(*wrap)(struct __pyx_obj_8PyClical_clifford *, Clifford);
749  Clifford (*unwrap)(struct __pyx_obj_8PyClical_clifford *);
750  PyObject *(*copy)(struct __pyx_obj_8PyClical_clifford *, int __pyx_skip_dispatch);
751 };
752 static struct __pyx_vtabstruct_8PyClical_clifford *__pyx_vtabptr_8PyClical_clifford;
753 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_8clifford_wrap(struct __pyx_obj_8PyClical_clifford *, Clifford);
754 static CYTHON_INLINE Clifford __pyx_f_8PyClical_8clifford_unwrap(struct __pyx_obj_8PyClical_clifford *);
755 
756 /* --- Runtime support code (head) --- */
757 #ifndef CYTHON_REFNANNY
758  #define CYTHON_REFNANNY 0
759 #endif
760 #if CYTHON_REFNANNY
761  typedef struct {
762  void (*INCREF)(void*, PyObject*, int);
763  void (*DECREF)(void*, PyObject*, int);
764  void (*GOTREF)(void*, PyObject*, int);
765  void (*GIVEREF)(void*, PyObject*, int);
766  void* (*SetupContext)(const char*, int, const char*);
767  void (*FinishContext)(void**);
768  } __Pyx_RefNannyAPIStruct;
769  static __Pyx_RefNannyAPIStruct *__Pyx_RefNanny = NULL;
770  static __Pyx_RefNannyAPIStruct *__Pyx_RefNannyImportAPI(const char *modname);
771  #define __Pyx_RefNannyDeclarations void *__pyx_refnanny = NULL;
772 #ifdef WITH_THREAD
773  #define __Pyx_RefNannySetupContext(name, acquire_gil)\
774  if (acquire_gil) {\
775  PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure();\
776  __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__);\
777  PyGILState_Release(__pyx_gilstate_save);\
778  } else {\
779  __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__);\
780  }
781 #else
782  #define __Pyx_RefNannySetupContext(name, acquire_gil)\
783  __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__)
784 #endif
785  #define __Pyx_RefNannyFinishContext()\
786  __Pyx_RefNanny->FinishContext(&__pyx_refnanny)
787  #define __Pyx_INCREF(r) __Pyx_RefNanny->INCREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
788  #define __Pyx_DECREF(r) __Pyx_RefNanny->DECREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
789  #define __Pyx_GOTREF(r) __Pyx_RefNanny->GOTREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
790  #define __Pyx_GIVEREF(r) __Pyx_RefNanny->GIVEREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
791  #define __Pyx_XINCREF(r) do { if((r) != NULL) {__Pyx_INCREF(r); }} while(0)
792  #define __Pyx_XDECREF(r) do { if((r) != NULL) {__Pyx_DECREF(r); }} while(0)
793  #define __Pyx_XGOTREF(r) do { if((r) != NULL) {__Pyx_GOTREF(r); }} while(0)
794  #define __Pyx_XGIVEREF(r) do { if((r) != NULL) {__Pyx_GIVEREF(r);}} while(0)
795 #else
796  #define __Pyx_RefNannyDeclarations
797  #define __Pyx_RefNannySetupContext(name, acquire_gil)
798  #define __Pyx_RefNannyFinishContext()
799  #define __Pyx_INCREF(r) Py_INCREF(r)
800  #define __Pyx_DECREF(r) Py_DECREF(r)
801  #define __Pyx_GOTREF(r)
802  #define __Pyx_GIVEREF(r)
803  #define __Pyx_XINCREF(r) Py_XINCREF(r)
804  #define __Pyx_XDECREF(r) Py_XDECREF(r)
805  #define __Pyx_XGOTREF(r)
806  #define __Pyx_XGIVEREF(r)
807 #endif
808 #define __Pyx_XDECREF_SET(r, v) do {\
809  PyObject *tmp = (PyObject *) r;\
810  r = v; __Pyx_XDECREF(tmp);\
811  } while (0)
812 #define __Pyx_DECREF_SET(r, v) do {\
813  PyObject *tmp = (PyObject *) r;\
814  r = v; __Pyx_DECREF(tmp);\
815  } while (0)
816 #define __Pyx_CLEAR(r) do { PyObject* tmp = ((PyObject*)(r)); r = NULL; __Pyx_DECREF(tmp);} while(0)
817 #define __Pyx_XCLEAR(r) do { if((r) != NULL) {PyObject* tmp = ((PyObject*)(r)); r = NULL; __Pyx_DECREF(tmp);}} while(0)
818 
819 #if CYTHON_COMPILING_IN_CPYTHON
820 static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStr(PyObject* obj, PyObject* attr_name) {
821  PyTypeObject* tp = Py_TYPE(obj);
822  if (likely(tp->tp_getattro))
823  return tp->tp_getattro(obj, attr_name);
824 #if PY_MAJOR_VERSION < 3
825  if (likely(tp->tp_getattr))
826  return tp->tp_getattr(obj, PyString_AS_STRING(attr_name));
827 #endif
828  return PyObject_GetAttr(obj, attr_name);
829 }
830 #else
831 #define __Pyx_PyObject_GetAttrStr(o,n) PyObject_GetAttr(o,n)
832 #endif
833 
834 static PyObject *__Pyx_GetBuiltinName(PyObject *name);
835 
836 #if CYTHON_COMPILING_IN_CPYTHON
837 static CYTHON_INLINE PyObject* __Pyx_PyObject_Call(PyObject *func, PyObject *arg, PyObject *kw);
838 #else
839 #define __Pyx_PyObject_Call(func, arg, kw) PyObject_Call(func, arg, kw)
840 #endif
841 
842 static CYTHON_INLINE void __Pyx_ErrRestore(PyObject *type, PyObject *value, PyObject *tb);
843 static CYTHON_INLINE void __Pyx_ErrFetch(PyObject **type, PyObject **value, PyObject **tb);
844 
845 static void __Pyx_WriteUnraisable(const char *name, int clineno,
846  int lineno, const char *filename,
847  int full_traceback, int nogil);
848 
849 #if CYTHON_COMPILING_IN_CPYTHON
850 static CYTHON_INLINE PyObject* __Pyx_PyObject_CallMethO(PyObject *func, PyObject *arg);
851 #endif
852 
853 static CYTHON_INLINE PyObject* __Pyx_PyObject_CallOneArg(PyObject *func, PyObject *arg);
854 
855 #if CYTHON_COMPILING_IN_CPYTHON
856 static CYTHON_INLINE PyObject* __Pyx_PyObject_CallNoArg(PyObject *func);
857 #else
858 #define __Pyx_PyObject_CallNoArg(func) __Pyx_PyObject_Call(func, __pyx_empty_tuple, NULL)
859 #endif
860 
861 static void __Pyx_RaiseDoubleKeywordsError(const char* func_name, PyObject* kw_name);
862 
863 static int __Pyx_ParseOptionalKeywords(PyObject *kwds, PyObject **argnames[],\
864  PyObject *kwds2, PyObject *values[], Py_ssize_t num_pos_args,\
865  const char* function_name);
866 
867 static void __Pyx_RaiseArgtupleInvalid(const char* func_name, int exact,
868  Py_ssize_t num_min, Py_ssize_t num_max, Py_ssize_t num_found);
869 
870 static CYTHON_INLINE PyObject *__Pyx_GetModuleGlobalName(PyObject *name);
871 
872 static CYTHON_INLINE void __Pyx_ExceptionSave(PyObject **type, PyObject **value, PyObject **tb);
873 static void __Pyx_ExceptionReset(PyObject *type, PyObject *value, PyObject *tb);
874 
875 static int __Pyx_GetException(PyObject **type, PyObject **value, PyObject **tb);
876 
877 static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb, PyObject *cause);
878 
879 #if CYTHON_COMPILING_IN_CPYTHON
880 static PyObject* __Pyx_PyInt_AddObjC(PyObject *op1, PyObject *op2, long intval, int inplace);
881 #else
882 #define __Pyx_PyInt_AddObjC(op1, op2, intval, inplace)\
883  (inplace ? PyNumber_InPlaceAdd(op1, op2) : PyNumber_Add(op1, op2))
884 #endif
885 
886 static CYTHON_INLINE int __Pyx_PySequence_ContainsTF(PyObject* item, PyObject* seq, int eq) {
887  int result = PySequence_Contains(seq, item);
888  return unlikely(result < 0) ? result : (result == (eq == Py_EQ));
889 }
890 
891 #define __Pyx_SetItemInt(o, i, v, type, is_signed, to_py_func, is_list, wraparound, boundscheck)\
892  (__Pyx_fits_Py_ssize_t(i, type, is_signed) ?\
893  __Pyx_SetItemInt_Fast(o, (Py_ssize_t)i, v, is_list, wraparound, boundscheck) :\
894  (is_list ? (PyErr_SetString(PyExc_IndexError, "list assignment index out of range"), -1) :\
895  __Pyx_SetItemInt_Generic(o, to_py_func(i), v)))
896 static CYTHON_INLINE int __Pyx_SetItemInt_Generic(PyObject *o, PyObject *j, PyObject *v);
897 static CYTHON_INLINE int __Pyx_SetItemInt_Fast(PyObject *o, Py_ssize_t i, PyObject *v,
898  int is_list, int wraparound, int boundscheck);
899 
900 static CYTHON_INLINE int __Pyx_ArgTypeTest(PyObject *obj, PyTypeObject *type, int none_allowed,
901  const char *name, int exact);
902 
903 static PyObject *__Pyx_Import(PyObject *name, PyObject *from_list, int level);
904 
905 #include <string.h>
906 
907 static int __Pyx_SetVtable(PyObject *dict, void *vtable);
908 
909 #if CYTHON_COMPILING_IN_CPYTHON
910 static PyObject* __Pyx_PyFloat_DivideObjC(PyObject *op1, PyObject *op2, double floatval, int inplace);
911 #else
912 #define __Pyx_PyFloat_DivideObjC(op1, op2, floatval, inplace)\
913  ((inplace ? __Pyx_PyNumber_InPlaceDivide(op1, op2) : __Pyx_PyNumber_Divide(op1, op2)))
914  #endif
915 
916 static CYTHON_INLINE int __Pyx_PyBytes_Equals(PyObject* s1, PyObject* s2, int equals);
917 
918 static CYTHON_INLINE int __Pyx_PyUnicode_Equals(PyObject* s1, PyObject* s2, int equals);
919 
920 #if PY_MAJOR_VERSION >= 3
921 #define __Pyx_PyString_Equals __Pyx_PyUnicode_Equals
922 #else
923 #define __Pyx_PyString_Equals __Pyx_PyBytes_Equals
924 #endif
925 
926 typedef struct {
927  int code_line;
928  PyCodeObject* code_object;
929 } __Pyx_CodeObjectCacheEntry;
930 struct __Pyx_CodeObjectCache {
931  int count;
932  int max_count;
933  __Pyx_CodeObjectCacheEntry* entries;
934 };
935 static struct __Pyx_CodeObjectCache __pyx_code_cache = {0,0,NULL};
936 static int __pyx_bisect_code_objects(__Pyx_CodeObjectCacheEntry* entries, int count, int code_line);
937 static PyCodeObject *__pyx_find_code_object(int code_line);
938 static void __pyx_insert_code_object(int code_line, PyCodeObject* code_object);
939 
940 static void __Pyx_AddTraceback(const char *funcname, int c_line,
941  int py_line, const char *filename);
942 
943 static CYTHON_INLINE int __Pyx_PyInt_As_int(PyObject *);
944 
945 #ifndef __Pyx_CppExn2PyErr
946 #include <new>
947 #include <typeinfo>
948 #include <stdexcept>
949 #include <ios>
950 static void __Pyx_CppExn2PyErr() {
951  try {
952  if (PyErr_Occurred())
953  ; // let the latest Python exn pass through and ignore the current one
954  else
955  throw;
956  } catch (const std::bad_alloc& exn) {
957  PyErr_SetString(PyExc_MemoryError, exn.what());
958  } catch (const std::bad_cast& exn) {
959  PyErr_SetString(PyExc_TypeError, exn.what());
960  } catch (const std::domain_error& exn) {
961  PyErr_SetString(PyExc_ValueError, exn.what());
962  } catch (const std::invalid_argument& exn) {
963  PyErr_SetString(PyExc_ValueError, exn.what());
964  } catch (const std::ios_base::failure& exn) {
965  PyErr_SetString(PyExc_IOError, exn.what());
966  } catch (const std::out_of_range& exn) {
967  PyErr_SetString(PyExc_IndexError, exn.what());
968  } catch (const std::overflow_error& exn) {
969  PyErr_SetString(PyExc_OverflowError, exn.what());
970  } catch (const std::range_error& exn) {
971  PyErr_SetString(PyExc_ArithmeticError, exn.what());
972  } catch (const std::underflow_error& exn) {
973  PyErr_SetString(PyExc_ArithmeticError, exn.what());
974  } catch (const std::exception& exn) {
975  PyErr_SetString(PyExc_RuntimeError, exn.what());
976  }
977  catch (...)
978  {
979  PyErr_SetString(PyExc_RuntimeError, "Unknown exception");
980  }
981 }
982 #endif
983 
984 static CYTHON_INLINE PyObject* __Pyx_PyInt_From_int(int value);
985 
986 static CYTHON_INLINE PyObject* __Pyx_PyInt_From_long(long value);
987 
988 static CYTHON_INLINE long __Pyx_PyInt_As_long(PyObject *);
989 
990 static PyTypeObject* __Pyx_FetchCommonType(PyTypeObject* type);
991 
992 static CYTHON_INLINE void __Pyx_ExceptionSwap(PyObject **type, PyObject **value, PyObject **tb);
993 
994 static PyObject* __Pyx_PyObject_CallMethod1(PyObject* obj, PyObject* method_name, PyObject* arg);
995 
996 typedef PyObject *(*__pyx_coroutine_body_t)(PyObject *, PyObject *);
997 typedef struct {
998  PyObject_HEAD
999  __pyx_coroutine_body_t body;
1000  PyObject *closure;
1001  PyObject *exc_type;
1002  PyObject *exc_value;
1003  PyObject *exc_traceback;
1004  PyObject *gi_weakreflist;
1005  PyObject *classobj;
1006  PyObject *yieldfrom;
1007  PyObject *gi_name;
1008  PyObject *gi_qualname;
1009  int resume_label;
1010  char is_running;
1011 } __pyx_CoroutineObject;
1012 static __pyx_CoroutineObject *__Pyx__Coroutine_New(PyTypeObject *type, __pyx_coroutine_body_t body,
1013  PyObject *closure, PyObject *name, PyObject *qualname);
1014 static int __Pyx_Coroutine_clear(PyObject *self);
1015 #if 1 || PY_VERSION_HEX < 0x030300B0
1016 static int __Pyx_PyGen_FetchStopIterationValue(PyObject **pvalue);
1017 #else
1018 #define __Pyx_PyGen_FetchStopIterationValue(pvalue) PyGen_FetchStopIterationValue(pvalue)
1019 #endif
1020 
1021 static PyObject* __Pyx_Coroutine_patch_module(PyObject* module, const char* py_code);
1022 
1023 static int __Pyx_patch_abc(void);
1024 
1025 #define __Pyx_Generator_USED
1026 static PyTypeObject *__pyx_GeneratorType = 0;
1027 #define __Pyx_Generator_CheckExact(obj) (Py_TYPE(obj) == __pyx_GeneratorType)
1028 #define __Pyx_Generator_New(body, closure, name, qualname)\
1029  __Pyx__Coroutine_New(__pyx_GeneratorType, body, closure, name, qualname)
1030 static PyObject *__Pyx_Generator_Next(PyObject *self);
1031 static int __pyx_Generator_init(void);
1032 
1033 static int __Pyx_check_binary_version(void);
1034 
1035 static int __Pyx_InitStrings(__Pyx_StringTabEntry *t);
1036 
1037 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_9index_set_wrap(struct __pyx_obj_8PyClical_index_set *__pyx_v_self, IndexSet __pyx_v_other); /* proto*/
1038 static CYTHON_INLINE IndexSet __pyx_f_8PyClical_9index_set_unwrap(struct __pyx_obj_8PyClical_index_set *__pyx_v_self); /* proto*/
1039 static PyObject *__pyx_f_8PyClical_9index_set_copy(struct __pyx_obj_8PyClical_index_set *__pyx_v_self, int __pyx_skip_dispatch); /* proto*/
1040 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_8clifford_wrap(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, Clifford __pyx_v_other); /* proto*/
1041 static CYTHON_INLINE Clifford __pyx_f_8PyClical_8clifford_unwrap(struct __pyx_obj_8PyClical_clifford *__pyx_v_self); /* proto*/
1042 static PyObject *__pyx_f_8PyClical_8clifford_copy(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, int __pyx_skip_dispatch); /* proto*/
1043 
1044 /* Module declarations from 'libcpp.vector' */
1045 
1046 /* Module declarations from 'glucat' */
1047 
1048 /* Module declarations from 'PyClical' */
1049 static PyTypeObject *__pyx_ptype_8PyClical_index_set = 0;
1050 static PyTypeObject *__pyx_ptype_8PyClical_clifford = 0;
1051 static PyTypeObject *__pyx_ptype_8PyClical___pyx_scope_struct____iter__ = 0;
1052 static CYTHON_INLINE IndexSet __pyx_f_8PyClical_toIndexSet(PyObject *); /*proto*/
1053 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_compare(PyObject *, PyObject *, int __pyx_skip_dispatch); /*proto*/
1054 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_min_neg(PyObject *, int __pyx_skip_dispatch); /*proto*/
1055 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_max_pos(PyObject *, int __pyx_skip_dispatch); /*proto*/
1056 static CYTHON_INLINE std::vector<scalar_t> __pyx_f_8PyClical_list_to_vector(PyObject *); /*proto*/
1057 static CYTHON_INLINE Clifford __pyx_f_8PyClical_toClifford(PyObject *); /*proto*/
1058 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_inv(PyObject *, int __pyx_skip_dispatch); /*proto*/
1059 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_scalar(PyObject *, int __pyx_skip_dispatch); /*proto*/
1060 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_real(PyObject *, int __pyx_skip_dispatch); /*proto*/
1061 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_imag(PyObject *, int __pyx_skip_dispatch); /*proto*/
1062 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_pure(PyObject *, int __pyx_skip_dispatch); /*proto*/
1063 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_even(PyObject *, int __pyx_skip_dispatch); /*proto*/
1064 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_odd(PyObject *, int __pyx_skip_dispatch); /*proto*/
1065 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_involute(PyObject *, int __pyx_skip_dispatch); /*proto*/
1066 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_reverse(PyObject *, int __pyx_skip_dispatch); /*proto*/
1067 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_conj(PyObject *, int __pyx_skip_dispatch); /*proto*/
1068 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_quad(PyObject *, int __pyx_skip_dispatch); /*proto*/
1069 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_norm(PyObject *, int __pyx_skip_dispatch); /*proto*/
1070 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_abs(PyObject *, int __pyx_skip_dispatch); /*proto*/
1071 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_max_abs(PyObject *, int __pyx_skip_dispatch); /*proto*/
1072 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_pow(PyObject *, PyObject *, int __pyx_skip_dispatch); /*proto*/
1073 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_outer_pow(PyObject *, PyObject *, int __pyx_skip_dispatch); /*proto*/
1074 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_complexifier(PyObject *, int __pyx_skip_dispatch); /*proto*/
1075 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_sqrt(PyObject *, int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_sqrt *__pyx_optional_args); /*proto*/
1076 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_exp(PyObject *, int __pyx_skip_dispatch); /*proto*/
1077 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_log(PyObject *, int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_log *__pyx_optional_args); /*proto*/
1078 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_cos(PyObject *, int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_cos *__pyx_optional_args); /*proto*/
1079 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_acos(PyObject *, int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_acos *__pyx_optional_args); /*proto*/
1080 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_cosh(PyObject *, int __pyx_skip_dispatch); /*proto*/
1081 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_acosh(PyObject *, int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_acosh *__pyx_optional_args); /*proto*/
1082 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_sin(PyObject *, int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_sin *__pyx_optional_args); /*proto*/
1083 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_asin(PyObject *, int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_asin *__pyx_optional_args); /*proto*/
1084 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_sinh(PyObject *, int __pyx_skip_dispatch); /*proto*/
1085 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_asinh(PyObject *, int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_asinh *__pyx_optional_args); /*proto*/
1086 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_tan(PyObject *, int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_tan *__pyx_optional_args); /*proto*/
1087 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_atan(PyObject *, int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_atan *__pyx_optional_args); /*proto*/
1088 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_tanh(PyObject *, int __pyx_skip_dispatch); /*proto*/
1089 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_atanh(PyObject *, int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_atanh *__pyx_optional_args); /*proto*/
1090 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_random_clifford(struct __pyx_obj_8PyClical_index_set *, int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_random_clifford *__pyx_optional_args); /*proto*/
1091 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_cga3(PyObject *, int __pyx_skip_dispatch); /*proto*/
1092 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_cga3std(PyObject *, int __pyx_skip_dispatch); /*proto*/
1093 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_agc3(PyObject *, int __pyx_skip_dispatch); /*proto*/
1094 #define __Pyx_MODULE_NAME "PyClical"
1095 int __pyx_module_is_main_PyClical = 0;
1096 
1097 /* Implementation of 'PyClical' */
1098 static PyObject *__pyx_builtin_IndexError;
1099 static PyObject *__pyx_builtin_RuntimeError;
1100 static PyObject *__pyx_builtin_TypeError;
1101 static PyObject *__pyx_builtin_ValueError;
1102 static PyObject *__pyx_builtin_NotImplemented;
1103 static PyObject *__pyx_builtin_range;
1104 static PyObject *__pyx_builtin_xrange;
1105 static char __pyx_k_[] = ".";
1106 static char __pyx_k_e[] = "e";
1107 static char __pyx_k_i[] = "i";
1108 static char __pyx_k_m[] = "m";
1109 static char __pyx_k_p[] = "p";
1110 static char __pyx_k_q[] = "q";
1111 static char __pyx_k__2[] = " ";
1112 static char __pyx_k__3[] = ":";
1113 static char __pyx_k__4[] = "\n\t";
1114 static char __pyx_k__5[] = " (";
1115 static char __pyx_k__6[] = ", ";
1116 static char __pyx_k__7[] = ").";
1117 static char __pyx_k_cl[] = "cl";
1118 static char __pyx_k_pi[] = "pi";
1119 static char __pyx_k_cos[] = "cos";
1120 static char __pyx_k_exp[] = "exp";
1121 static char __pyx_k_frm[] = "frm";
1122 static char __pyx_k_inv[] = "inv";
1123 static char __pyx_k_ist[] = "ist";
1124 static char __pyx_k_ixt[] = "ixt";
1125 static char __pyx_k_lhs[] = "lhs";
1126 static char __pyx_k_log[] = "log";
1127 static char __pyx_k_max[] = "max";
1128 static char __pyx_k_min[] = "min";
1129 static char __pyx_k_obj[] = "obj";
1130 static char __pyx_k_odd[] = "odd";
1131 static char __pyx_k_pow[] = "pow";
1132 static char __pyx_k_rhs[] = "rhs";
1133 static char __pyx_k_sin[] = "sin";
1134 static char __pyx_k_tan[] = "tan";
1135 static char __pyx_k_tau[] = "tau";
1136 static char __pyx_k_Real[] = "Real";
1137 static char __pyx_k_acos[] = "acos";
1138 static char __pyx_k_args[] = "args";
1139 static char __pyx_k_asin[] = "asin";
1140 static char __pyx_k_atan[] = "atan";
1141 static char __pyx_k_conj[] = "conj";
1142 static char __pyx_k_copy[] = "copy";
1143 static char __pyx_k_cosh[] = "cosh";
1144 static char __pyx_k_even[] = "even";
1145 static char __pyx_k_fill[] = "fill";
1146 static char __pyx_k_from[] = " from ";
1147 static char __pyx_k_iter[] = "__iter__";
1148 static char __pyx_k_main[] = "__main__";
1149 static char __pyx_k_math[] = "math";
1150 static char __pyx_k_name[] = "__name__";
1151 static char __pyx_k_norm[] = "norm";
1152 static char __pyx_k_pure[] = "pure";
1153 static char __pyx_k_quad[] = "quad";
1154 static char __pyx_k_send[] = "send";
1155 static char __pyx_k_sinh[] = "sinh";
1156 static char __pyx_k_sqrt[] = "sqrt";
1157 static char __pyx_k_tanh[] = "tanh";
1158 static char __pyx_k_test[] = "_test";
1159 static char __pyx_k_0_8_2[] = "0.8.2";
1160 static char __pyx_k_acosh[] = "acosh";
1161 static char __pyx_k_asinh[] = "asinh";
1162 static char __pyx_k_atanh[] = "atanh";
1163 static char __pyx_k_close[] = "close";
1164 static char __pyx_k_grade[] = "grade";
1165 static char __pyx_k_istpq[] = "istpq";
1166 static char __pyx_k_nbar3[] = "nbar3";
1167 static char __pyx_k_ninf3[] = "ninf3";
1168 static char __pyx_k_other[] = "other";
1169 static char __pyx_k_range[] = "range";
1170 static char __pyx_k_throw[] = "throw";
1171 static char __pyx_k_using[] = " using (";
1172 static char __pyx_k_value[] = " value ";
1173 static char __pyx_k_import[] = "__import__";
1174 static char __pyx_k_scalar[] = "scalar";
1175 static char __pyx_k_test_2[] = "__test__";
1176 static char __pyx_k_xrange[] = "xrange";
1177 static char __pyx_k_doctest[] = "doctest";
1178 static char __pyx_k_invalid[] = " invalid ";
1179 static char __pyx_k_numbers[] = "numbers";
1180 static char __pyx_k_reverse[] = "reverse";
1181 static char __pyx_k_testmod[] = "testmod";
1182 static char __pyx_k_version[] = "__version__";
1183 static char __pyx_k_Integral[] = "Integral";
1184 static char __pyx_k_PyClical[] = "PyClical";
1185 static char __pyx_k_Sequence[] = "Sequence";
1186 static char __pyx_k_as_frame[] = " as frame:\n\t";
1187 static char __pyx_k_involute[] = "involute";
1188 static char __pyx_k_to_frame[] = " to frame ";
1189 static char __pyx_k_TypeError[] = "TypeError";
1190 static char __pyx_k_outer_pow[] = "outer_pow";
1191 static char __pyx_k_IndexError[] = "IndexError";
1192 static char __pyx_k_ValueError[] = "ValueError";
1193 static char __pyx_k_pyx_vtable[] = "__pyx_vtable__";
1194 static char __pyx_k_collections[] = "collections";
1195 static char __pyx_k_e_line_1887[] = "e (line 1887)";
1196 static char __pyx_k_RuntimeError[] = "RuntimeError";
1197 static char __pyx_k_abs_line_1473[] = "abs (line 1473)";
1198 static char __pyx_k_cos_line_1602[] = "cos (line 1602)";
1199 static char __pyx_k_exp_line_1565[] = "exp (line 1565)";
1200 static char __pyx_k_inv_line_1329[] = "inv (line 1329)";
1201 static char __pyx_k_log_line_1579[] = "log (line 1579)";
1202 static char __pyx_k_odd_line_1397[] = "odd (line 1397)";
1203 static char __pyx_k_pow_line_1494[] = "pow (line 1494)";
1204 static char __pyx_k_sin_line_1679[] = "sin (line 1679)";
1205 static char __pyx_k_tan_line_1752[] = "tan (line 1752)";
1206 static char __pyx_k_using_invalid[] = " using invalid ";
1207 static char __pyx_k_Cannot_reframe[] = "Cannot reframe";
1208 static char __pyx_k_NotImplemented[] = "NotImplemented";
1209 static char __pyx_k_Not_applicable[] = "Not applicable.";
1210 static char __pyx_k_acos_line_1619[] = "acos (line 1619)";
1211 static char __pyx_k_agc3_line_1844[] = "agc3 (line 1844)";
1212 static char __pyx_k_asin_line_1698[] = "asin (line 1698)";
1213 static char __pyx_k_atan_line_1769[] = "atan (line 1769)";
1214 static char __pyx_k_cga3_line_1824[] = "cga3 (line 1824)";
1215 static char __pyx_k_conj_line_1436[] = "conj (line 1436)";
1216 static char __pyx_k_cosh_line_1640[] = "cosh (line 1640)";
1217 static char __pyx_k_even_line_1388[] = "even (line 1388)";
1218 static char __pyx_k_imag_line_1366[] = "imag (line 1366)";
1219 static char __pyx_k_invalid_string[] = " invalid string ";
1220 static char __pyx_k_norm_line_1462[] = "norm (line 1462)";
1221 static char __pyx_k_pure_line_1377[] = "pure (line 1377)";
1222 static char __pyx_k_quad_line_1451[] = "quad (line 1451)";
1223 static char __pyx_k_real_line_1355[] = "real (line 1355)";
1224 static char __pyx_k_sinh_line_1719[] = "sinh (line 1719)";
1225 static char __pyx_k_sqrt_line_1542[] = "sqrt (line 1542)";
1226 static char __pyx_k_tanh_line_1786[] = "tanh (line 1786)";
1227 static char __pyx_k_acosh_line_1656[] = "acosh (line 1656)";
1228 static char __pyx_k_asinh_line_1733[] = "asinh (line 1733)";
1229 static char __pyx_k_atanh_line_1798[] = "atanh (line 1798)";
1230 static char __pyx_k_istpq_line_1900[] = "istpq (line 1900)";
1231 static char __pyx_k_compare_line_490[] = "compare (line 490)";
1232 static char __pyx_k_index_set___iter[] = "index_set.__iter__";
1233 static char __pyx_k_max_pos_line_511[] = "max_pos (line 511)";
1234 static char __pyx_k_min_neg_line_502[] = "min_neg (line 502)";
1235 static char __pyx_k_scalar_line_1344[] = "scalar (line 1344)";
1236 static char __pyx_k_cga3std_line_1833[] = "cga3std (line 1833)";
1237 static char __pyx_k_max_abs_line_1482[] = "max_abs (line 1482)";
1238 static char __pyx_k_reverse_line_1421[] = "reverse (line 1421)";
1239 static char __pyx_k_involute_line_1406[] = "involute (line 1406)";
1240 static char __pyx_k_outer_pow_line_1518[] = "outer_pow (line 1518)";
1241 static char __pyx_k_clifford_inv_line_925[] = "clifford.inv (line 925)";
1242 static char __pyx_k_clifford_pow_line_979[] = "clifford.pow (line 979)";
1243 static char __pyx_k_clifford_abs_line_1174[] = "clifford.abs (line 1174)";
1244 static char __pyx_k_clifford_copy_line_554[] = "clifford.copy (line 554)";
1245 static char __pyx_k_clifford_odd_line_1069[] = "clifford.odd (line 1069)";
1246 static char __pyx_k_complexifier_line_1527[] = "complexifier (line 1527)";
1247 static char __pyx_k_index_set_copy_line_64[] = "index_set.copy (line 64)";
1248 static char __pyx_k_index_set_max_line_349[] = "index_set.max (line 349)";
1249 static char __pyx_k_index_set_min_line_340[] = "index_set.min (line 340)";
1250 static char __pyx_k_clifford_conj_line_1137[] = "clifford.conj (line 1137)";
1251 static char __pyx_k_clifford_even_line_1060[] = "clifford.even (line 1060)";
1252 static char __pyx_k_clifford_norm_line_1163[] = "clifford.norm (line 1163)";
1253 static char __pyx_k_clifford_pure_line_1049[] = "clifford.pure (line 1049)";
1254 static char __pyx_k_clifford_quad_line_1152[] = "clifford.quad (line 1152)";
1255 static char __pyx_k_Unary_print_clifford_1_1[] = "\n Unary -.\n\n >>> print -clifford(\"{1}\")\n -{1}\n ";
1256 static char __pyx_k_clifford___or___line_938[] = "clifford.__or__ (line 938)";
1257 static char __pyx_k_clifford_frame_line_1214[] = "clifford.frame (line 1214)";
1258 static char __pyx_k_clifford_hidden_doctests[] = "clifford_hidden_doctests";
1259 static char __pyx_k_clifford_isnan_line_1205[] = "clifford.isnan (line 1205)";
1260 static char __pyx_k_index_set_count_line_313[] = "index_set.count (line 313)";
1261 static char __pyx_k_clifford___add___line_739[] = "clifford.__add__ (line 739)";
1262 static char __pyx_k_clifford___and___line_835[] = "clifford.__and__ (line 835)";
1263 static char __pyx_k_clifford___div___line_895[] = "clifford.__div__ (line 895)";
1264 static char __pyx_k_clifford___ior___line_949[] = "clifford.__ior__ (line 949)";
1265 static char __pyx_k_clifford___mod___line_805[] = "clifford.__mod__ (line 805)";
1266 static char __pyx_k_clifford___mul___line_779[] = "clifford.__mul__ (line 779)";
1267 static char __pyx_k_clifford___neg___line_721[] = "clifford.__neg__ (line 721)";
1268 static char __pyx_k_clifford___pos___line_730[] = "clifford.__pos__ (line 730)";
1269 static char __pyx_k_clifford___pow___line_960[] = "clifford.__pow__ (line 960)";
1270 static char __pyx_k_clifford___sub___line_759[] = "clifford.__sub__ (line 759)";
1271 static char __pyx_k_clifford___xor___line_865[] = "clifford.__xor__ (line 865)";
1272 static char __pyx_k_clifford_reframe_line_648[] = "clifford.reframe (line 648)";
1273 static char __pyx_k_clifford_scalar_line_1038[] = "clifford.scalar (line 1038)";
1274 static char __pyx_k_index_set___or___line_291[] = "index_set.__or__ (line 291)";
1275 static char __pyx_k_index_set_hidden_doctests[] = "index_set_hidden_doctests";
1276 static char __pyx_k_random_clifford_line_1815[] = "random_clifford (line 1815)";
1277 static char __pyx_k_Cannot_take_vector_part_of[] = "Cannot take vector part of ";
1278 static char __pyx_k_Unary_print_clifford_1_1_2[] = "\n Unary +.\n\n >>> print +clifford(\"{1}\")\n {1}\n ";
1279 static char __pyx_k_clifford___iadd___line_750[] = "clifford.__iadd__ (line 750)";
1280 static char __pyx_k_clifford___iand___line_850[] = "clifford.__iand__ (line 850)";
1281 static char __pyx_k_clifford___idiv___line_910[] = "clifford.__idiv__ (line 910)";
1282 static char __pyx_k_clifford___imod___line_820[] = "clifford.__imod__ (line 820)";
1283 static char __pyx_k_clifford___imul___line_792[] = "clifford.__imul__ (line 792)";
1284 static char __pyx_k_clifford___isub___line_770[] = "clifford.__isub__ (line 770)";
1285 static char __pyx_k_clifford___iter___line_637[] = "clifford.__iter__ (line 637)";
1286 static char __pyx_k_clifford___ixor___line_880[] = "clifford.__ixor__ (line 880)";
1287 static char __pyx_k_clifford___str___line_1234[] = "clifford.__str__ (line 1234)";
1288 static char __pyx_k_clifford_max_abs_line_1183[] = "clifford.max_abs (line 1183)";
1289 static char __pyx_k_clifford_reverse_line_1122[] = "clifford.reverse (line 1122)";
1290 static char __pyx_k_index_set___and___line_269[] = "index_set.__and__ (line 269)";
1291 static char __pyx_k_index_set___ior___line_302[] = "index_set.__ior__ (line 302)";
1292 static char __pyx_k_index_set___str___line_393[] = "index_set.__str__ (line 393)";
1293 static char __pyx_k_index_set___xor___line_247[] = "index_set.__xor__ (line 247)";
1294 static char __pyx_k_clifford___call___line_1019[] = "clifford.__call__ (line 1019)";
1295 static char __pyx_k_clifford___repr___line_1225[] = "clifford.__repr__ (line 1225)";
1296 static char __pyx_k_clifford_involute_line_1106[] = "clifford.involute (line 1106)";
1297 static char __pyx_k_index_set___iand___line_280[] = "index_set.__iand__ (line 280)";
1298 static char __pyx_k_index_set___iter___line_227[] = "index_set.__iter__ (line 227)";
1299 static char __pyx_k_index_set___ixor___line_258[] = "index_set.__ixor__ (line 258)";
1300 static char __pyx_k_index_set___repr___line_382[] = "index_set.__repr__ (line 382)";
1301 static char __pyx_k_clifford_outer_pow_line_1003[] = "clifford.outer_pow (line 1003)";
1302 static char __pyx_k_clifford_truncated_line_1194[] = "clifford.truncated (line 1194)";
1303 static char __pyx_k_index_set_count_neg_line_322[] = "index_set.count_neg (line 322)";
1304 static char __pyx_k_index_set_count_pos_line_331[] = "index_set.count_pos (line 331)";
1305 static char __pyx_k_clifford___getitem___line_706[] = "clifford.__getitem__ (line 706)";
1306 static char __pyx_k_index_set___invert___line_238[] = "index_set.__invert__ (line 238)";
1307 static char __pyx_k_Abbreviation_for_index_set_q_p[] = "\n Abbreviation for index_set({-q,...p}).\n\n >>> print istpq(2,3)\n {-3,-2,-1,1,2}\n ";
1308 static char __pyx_k_Conjugation_reverse_o_involute[] = "\n Conjugation, reverse o involute == involute o reverse.\n\n >>> print (clifford(\"{1}\")).conj()\n -{1}\n >>> print (clifford(\"{2}\") * clifford(\"{1}\")).conj()\n {1,2}\n >>> print (clifford(\"{1}\") * clifford(\"{2}\")).conj()\n -{1,2}\n >>> print clifford(\"1+{1}+{1,2}\").conj()\n 1-{1}-{1,2}\n ";
1309 static char __pyx_k_Geometric_product_x_clifford_2[] = "\n Geometric product.\n\n >>> x = clifford(2); x *= clifford(\"{2}\"); print x\n 2{2}\n >>> x = clifford(\"{1}\"); x *= clifford(\"{2}\"); print x\n {1,2}\n >>> x = clifford(\"{1}\"); x *= clifford(\"{1,2}\"); print x\n {2}\n ";
1310 static char __pyx_k_Geometric_sum_print_clifford_1[] = "\n Geometric sum.\n\n >>> print clifford(1) + clifford(\"{2}\")\n 1+{2}\n >>> print clifford(\"{1}\") + clifford(\"{2}\")\n {1}+{2}\n ";
1311 static char __pyx_k_Hyperbolic_sine_of_multivector[] = "\n Hyperbolic sine of multivector.\n\n >>> x=clifford(\"{1,2}\") * pi/2; print sinh(x)\n {1,2}\n >>> x=clifford(\"{1,2}\") * pi/6; print sinh(x)\n 0.5{1,2}\n ";
1312 static char __pyx_k_Inner_product_print_clifford_1[] = "\n Inner product.\n\n >>> print clifford(\"{1}\") & clifford(\"{2}\")\n 0\n >>> print clifford(2) & clifford(\"{2}\")\n 0\n >>> print clifford(\"{1}\") & clifford(\"{1}\")\n 1\n >>> print clifford(\"{1}\") & clifford(\"{1,2}\")\n {2}\n ";
1313 static char __pyx_k_Inverse_tangent_of_multivector[] = "\n Inverse tangent of multivector with optional complexifier.\n\n >>> s=index_set({1,2,3}); x=clifford(\"{1}\"); print tan(atan(x,s),s)\n {1}\n >>> x=clifford(\"{1}\"); print tan(atan(x))\n {1}\n ";
1314 static char __pyx_k_Iterate_over_the_indices_of_an[] = "\n Iterate over the indices of an index_set.\n\n >>> for i in index_set({-3,4,7}): print i,\n -3 4 7\n ";
1315 static char __pyx_k_Maximum_member_index_set_1_1_2[] = "\n Maximum member.\n\n >>> index_set({-1,1,2}).max()\n 2\n ";
1316 static char __pyx_k_Maximum_positive_index_or_0_if[] = "\n Maximum positive index, or 0 if none.\n\n >>> max_pos(index_set({1,2}))\n 2\n ";
1317 static char __pyx_k_Minimum_member_index_set_1_1_2[] = "\n Minimum member.\n\n >>> index_set({-1,1,2}).min()\n -1\n ";
1318 static char __pyx_k_Minimum_negative_index_or_0_if[] = "\n Minimum negative index, or 0 if none.\n\n >>> min_neg(index_set({1,2}))\n 0\n ";
1319 static char __pyx_k_Odd_part_of_multivector_sum_of[] = "\n Odd part of multivector, sum of odd grade terms.\n\n >>> print clifford(\"1+{1}+{1,2}\").odd()\n {1}\n ";
1320 static char __pyx_k_Outer_product_power_x_clifford[] = "\n Outer product power.\n\n >>> x=clifford(\"2+{1}\"); print x.outer_pow(0)\n 1\n >>> x=clifford(\"2+{1}\"); print x.outer_pow(1)\n 2+{1}\n >>> x=clifford(\"2+{1}\"); print x.outer_pow(2)\n 4+4{1}\n >>> print clifford(\"1+{1}+{1,2}\").outer_pow(3)\n 1+3{1}+3{1,2}\n\n ";
1321 static char __pyx_k_Outer_product_print_clifford_1[] = "\n Outer product.\n\n >>> print clifford(\"{1}\") ^ clifford(\"{2}\")\n {1,2}\n >>> print clifford(2) ^ clifford(\"{2}\")\n 2{2}\n >>> print clifford(\"{1}\") ^ clifford(\"{1}\")\n 0\n >>> print clifford(\"{1}\") ^ clifford(\"{1,2}\")\n 0\n ";
1322 static char __pyx_k_Power_self_to_the_m_x_clifford[] = "\n Power: self to the m.\n\n >>> x=clifford(\"{1}\"); print x ** 2\n 1\n >>> x=clifford(\"2\"); print x ** 2\n 4\n >>> x=clifford(\"2+{1}\"); print x ** 0\n 1\n >>> x=clifford(\"2+{1}\"); print x ** 1\n 2+{1}\n >>> x=clifford(\"2+{1}\"); print x ** 2\n 5+4{1}\n >>> i=clifford(\"{1,2}\");print exp(pi/2) * (i ** i)\n 1\n ";
1323 static char __pyx_k_Pure_part_print_clifford_1_1_1[] = "\n Pure part.\n\n >>> print clifford(\"1+{1}+{1,2}\").pure()\n {1}+{1,2}\n >>> print clifford(\"{1,2}\").pure()\n {1,2}\n ";
1324 static char __pyx_k_Quadratic_form_rev_x_x_0_print[] = "\n Quadratic form == (rev(x)*x)(0).\n\n >>> print clifford(\"1+{1}+{1,2}\").quad()\n 3.0\n >>> print clifford(\"1+{-1}+{1,2}+{1,2,3}\").quad()\n 2.0\n ";
1325 static char __pyx_k_Set_complement_not_print_index[] = "\n Set complement: not.\n\n >>> print ~index_set({-16,-15,-14,-13,-12,-11,-10,-9,-8,-7,-6,-5,-4,-3,-2,-1,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16})\n {-32,-31,-30,-29,-28,-27,-26,-25,-24,-23,-22,-21,-20,-19,-18,-17,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32}\n ";
1326 static char __pyx_k_Set_union_or_print_index_set_1[] = "\n Set union: or.\n\n >>> print index_set({1}) | index_set({2})\n {1,2}\n >>> print index_set({1,2}) | index_set({2})\n {1,2}\n ";
1327 static char __pyx_k_Transform_left_hand_side_using[] = "\n Transform left hand side, using right hand side as a transformation.\n\n >>> x=clifford(\"{1,2}\") * pi/2; y=clifford(\"{1}\"); print y|x\n -{1}\n >>> x=clifford(\"{1,2}\") * pi/2; y=clifford(\"{1}\"); print y|exp(x)\n -{1}\n ";
1328 static char __pyx_k_clifford_vector_part_line_1078[] = "clifford.vector_part (line 1078)";
1329 static char __pyx_k_index_set___getitem___line_189[] = "index_set.__getitem__ (line 189)";
1330 static char __pyx_k_index_set___setitem___line_177[] = "index_set.__setitem__ (line 177)";
1331 static char __pyx_k_lexicographic_compare_eg_3_4_5[] = "\n \"lexicographic compare\" eg. {3,4,5} is less than {3,7,8};\n -1 if a<b, +1 if a>b, 0 if a==b.\n\n >>> compare(index_set({1,2}),index_set({-1,3}))\n -1\n >>> compare(index_set({-1,4}),index_set({-1,3}))\n 1\n ";
1332 static char __pyx_k_Abbreviation_for_clifford_index[] = "\n Abbreviation for clifford(index_set(obj)).\n\n >>> print e(1)\n {1}\n >>> print e(-1)\n {-1}\n >>> print e(0)\n 1\n ";
1333 static char __pyx_k_Absolute_value_of_multivector_m[] = "\n Absolute value of multivector: multivector 2-norm.\n\n >>> abs(clifford(\"1+{-1}+{1,2}+{1,2,3}\"))\n 2.0\n ";
1334 static char __pyx_k_Absolute_value_square_root_of_n[] = "\n Absolute value: square root of norm.\n\n >>> clifford(\"1+{-1}+{1,2}+{1,2,3}\").abs()\n 2.0\n ";
1335 static char __pyx_k_Cardinality_Number_of_indices_i[] = "\n Cardinality: Number of indices included in set.\n\n >>> index_set({-1,1,2}).count()\n 3\n ";
1336 static char __pyx_k_Check_if_a_multivector_contains[] = "\n Check if a multivector contains any IEEE NaN values.\n\n >>> clifford().isnan()\n False\n ";
1337 static char __pyx_k_Contraction_print_clifford_1_cl[] = "\n Contraction.\n\n >>> print clifford(\"{1}\") % clifford(\"{2}\")\n 0\n >>> print clifford(2) % clifford(\"{2}\")\n 2{2}\n >>> print clifford(\"{1}\") % clifford(\"{1}\")\n 1\n >>> print clifford(\"{1}\") % clifford(\"{1,2}\")\n {2}\n ";
1338 static char __pyx_k_Contraction_x_clifford_1_x_clif[] = "\n Contraction.\n\n >>> x = clifford(\"{1}\"); x %= clifford(\"{2}\"); print x\n 0\n >>> x = clifford(2); x %= clifford(\"{2}\"); print x\n 2{2}\n >>> x = clifford(\"{1}\"); x %= clifford(\"{1}\"); print x\n 1\n >>> x = clifford(\"{1}\"); x %= clifford(\"{1,2}\"); print x\n {2}\n ";
1339 static char __pyx_k_Convert_CGA3_null_vector_to_Euc[] = "\n Convert CGA3 null vector to Euclidean 3D vector using Doran and Lasenby definition.\n\n >>> x=clifford(\"2{1}+9{2}+{3}\"); print agc3(cga3(x))\n 2{1}+9{2}+{3}\n >>> x=clifford(\"2{1}+9{2}+{3}\"); print agc3(cga3(x))-x\n 0\n ";
1340 static char __pyx_k_Convert_CGA3_null_vector_to_sta[] = "\n Convert CGA3 null vector to standard conformal null vector using Doran and Lasenby definition.\n\n >>> x=clifford(\"2{1}+9{2}+{3}\"); print cga3std(cga3(x))\n 87{-1}+4{1}+18{2}+2{3}+85{4}\n >>> x=clifford(\"2{1}+9{2}+{3}\"); print cga3std(cga3(x))-cga3(x)\n 0\n ";
1341 static char __pyx_k_Convert_Euclidean_3D_multivecto[] = "\n Convert Euclidean 3D multivector to Conformal Geometric Algebra using Doran and Lasenby definition.\n\n >>> x=clifford(\"2{1}+9{2}+{3}\"); print cga3(x)\n 87{-1}+4{1}+18{2}+2{3}+85{4}\n ";
1342 static char __pyx_k_Copy_this_clifford_object_x_cli[] = "\n Copy this clifford object.\n\n >>> x=clifford(\"1{2}\"); y=x.copy(); print y\n {2}\n ";
1343 static char __pyx_k_Copy_this_index_set_object_s_in[] = "\n Copy this index_set object.\n\n >>> s=index_set(1); t=s.copy(); print t\n {1}\n ";
1344 static char __pyx_k_Cosine_of_multivector_with_opti[] = "\n Cosine of multivector with optional complexifier.\n\n >>> x=clifford(\"{1,2}\"); print cos(acos(x),\"{1,2,3}\")\n {1,2}\n >>> x=clifford(\"{1,2}\"); print cos(acos(x))\n {1,2}\n ";
1345 static char __pyx_k_Even_part_of_multivector_sum_of[] = "\n Even part of multivector, sum of even grade terms.\n\n >>> print clifford(\"1+{1}+{1,2}\").even()\n 1+{1,2}\n ";
1346 static char __pyx_k_Exponential_of_multivector_x_cl[] = "\n Exponential of multivector.\n\n >>> x=clifford(\"{1,2}\") * pi/4; print exp(x)\n 0.7071+0.7071{1,2}\n >>> x=clifford(\"{1,2}\") * pi/2; print exp(x)\n {1,2}\n ";
1347 static char __pyx_k_Geometric_difference_print_clif[] = "\n Geometric difference.\n\n >>> print clifford(1) - clifford(\"{2}\")\n 1-{2}\n >>> print clifford(\"{1}\") - clifford(\"{2}\")\n {1}-{2}\n ";
1348 static char __pyx_k_Geometric_difference_x_clifford[] = "\n Geometric difference.\n\n >>> x = clifford(1); x -= clifford(\"{2}\"); print x\n 1-{2}\n ";
1349 static char __pyx_k_Geometric_multiplicative_invers[] = "\n Geometric multiplicative inverse.\n\n >>> x = clifford(\"{1}\"); print x.inv()\n {1}\n >>> x = clifford(2); print x.inv()\n 0.5\n >>> x = clifford(\"{1,2}\"); print x.inv()\n -{1,2}\n ";
1350 static char __pyx_k_Geometric_product_print_cliffor[] = "\n Geometric product.\n\n >>> print clifford(\"{1}\") * clifford(\"{2}\")\n {1,2}\n >>> print clifford(2) * clifford(\"{2}\")\n 2{2}\n >>> print clifford(\"{1}\") * clifford(\"{1,2}\")\n {2}\n ";
1351 static char __pyx_k_Geometric_quotient_print_cliffo[] = "\n Geometric quotient.\n\n >>> print clifford(\"{1}\") / clifford(\"{2}\")\n {1,2}\n >>> print clifford(2) / clifford(\"{2}\")\n 2{2}\n >>> print clifford(\"{1}\") / clifford(\"{1}\")\n 1\n >>> print clifford(\"{1}\") / clifford(\"{1,2}\")\n -{2}\n ";
1352 static char __pyx_k_Geometric_quotient_x_clifford_1[] = "\n Geometric quotient.\n\n >>> x = clifford(\"{1}\"); x /= clifford(\"{2}\"); print x\n {1,2}\n >>> x = clifford(2); x /= clifford(\"{2}\"); print x\n 2{2}\n >>> x = clifford(\"{1}\"); x /= clifford(\"{1}\"); print x\n 1\n >>> x = clifford(\"{1}\"); x /= clifford(\"{1,2}\"); print x\n -{2}\n ";
1353 static char __pyx_k_Geometric_sum_x_clifford_1_x_cl[] = "\n Geometric sum.\n\n >>> x = clifford(1); x += clifford(\"{2}\"); print x\n 1+{2}\n ";
1354 static char __pyx_k_Get_the_value_of_an_index_set_o[] = "\n Get the value of an index_set object at an index.\n\n >>> index_set({1})[1]\n True\n >>> index_set({1})[2]\n False\n >>> index_set({2})[-1]\n False\n >>> index_set({2})[1]\n False\n >>> index_set({2})[2]\n True\n >>> index_set({2})[33]\n False\n ";
1355 static char __pyx_k_Hyperbolic_cosine_of_multivecto[] = "\n Hyperbolic cosine of multivector.\n\n >>> x=clifford(\"{1,2}\") * pi; print cosh(x)\n -1\n >>> x=clifford(\"{1,2,3}\"); print cosh(acosh(x))\n {1,2,3}\n >>> x=clifford(\"{1,2}\"); print cosh(acosh(x))\n {1,2}\n ";
1356 static char __pyx_k_Hyperbolic_tangent_of_multivect[] = "\n Hyperbolic tangent of multivector.\n\n >>> x=clifford(\"{1,2}\") * pi/4; print tanh(x)\n {1,2}\n ";
1357 static char __pyx_k_Imaginary_part_deprecated_alway[] = "\n Imaginary part: deprecated (always 0).\n\n >>> imag(clifford(\"1+{1}+{1,2}\"))\n 0.0\n >>> imag(clifford(\"{1,2}\"))\n 0.0\n ";
1358 static char __pyx_k_Inner_product_x_clifford_1_x_cl[] = "\n Inner product.\n\n >>> x = clifford(\"{1}\"); x &= clifford(\"{2}\"); print x\n 0\n >>> x = clifford(2); x &= clifford(\"{2}\"); print x\n 0\n >>> x = clifford(\"{1}\"); x &= clifford(\"{1}\"); print x\n 1\n >>> x = clifford(\"{1}\"); x &= clifford(\"{1,2}\"); print x\n {2}\n ";
1359 static char __pyx_k_Integer_power_of_multivector_ob[] = "\n Integer power of multivector: obj to the m.\n\n >>> x=clifford(\"{1}\"); print pow(x,2)\n 1\n >>> x=clifford(\"2\"); print pow(x,2)\n 4\n >>> x=clifford(\"2+{1}\"); print pow(x,0)\n 1\n >>> x=clifford(\"2+{1}\"); print pow(x,1)\n 2+{1}\n >>> x=clifford(\"2+{1}\"); print pow(x,2)\n 5+4{1}\n >>> print pow(clifford(\"1+{1}+{1,2}\"),3)\n 1+3{1}+3{1,2}\n >>> i=clifford(\"{1,2}\");print exp(pi/2) * pow(i, i)\n 1\n ";
1360 static char __pyx_k_Inverse_cosine_of_multivector_w[] = "\n Inverse cosine of multivector with optional complexifier.\n\n >>> x=clifford(\"{1,2}\"); print cos(acos(x),\"{1,2,3}\")\n {1,2}\n >>> x=clifford(\"{1,2}\"); print cos(acos(x),\"{-1,1,2,3,4}\")\n {1,2}\n >>> print acos(0) / pi\n 0.5\n >>> x=clifford(\"{1,2}\"); print cos(acos(x))\n {1,2}\n ";
1361 static char __pyx_k_Inverse_hyperbolic_cosine_of_mu[] = "\n Inverse hyperbolic cosine of multivector with optional complexifier.\n\n >>> print acosh(0,\"{-2,-1,1}\")\n 1.571{-2,-1,1}\n >>> x=clifford(\"{1,2,3}\"); print cosh(acosh(x,\"{-1,1,2,3,4}\"))\n {1,2,3}\n >>> print acosh(0)\n 1.571{-1}\n >>> x=clifford(\"{1,2,3}\"); print cosh(acosh(x))\n {1,2,3}\n >>> x=clifford(\"{1,2}\"); print cosh(acosh(x))\n {1,2}\n ";
1362 static char __pyx_k_Inverse_hyperbolic_sine_of_mult[] = "\n Inverse hyperbolic sine of multivector with optional complexifier.\n\n >>> x=clifford(\"{1,2}\"); print asinh(x,\"{1,2,3}\") * 2/pi\n {1,2}\n >>> x=clifford(\"{1,2}\"); print asinh(x) * 2/pi\n {1,2}\n >>> x=clifford(\"{1,2}\") / 2; print asinh(x) * 6/pi\n {1,2}\n ";
1363 static char __pyx_k_Inverse_hyperbolic_tangent_of_m[] = "\n Inverse hyperbolic tangent of multivector with optional complexifier.\n\n >>> s=index_set({1,2,3}); x=clifford(\"{1,2}\"); print tanh(atanh(x,s))\n {1,2}\n >>> x=clifford(\"{1,2}\"); print tanh(atanh(x))\n {1,2}\n ";
1364 static char __pyx_k_Inverse_sine_of_multivector_wit[] = "\n Inverse sine of multivector with optional complexifier.\n\n >>> s=\"{-1}\"; x=clifford(s); print asin(sin(x,s),s)\n {-1}\n >>> s=\"{-1}\"; x=clifford(s); print asin(sin(x,s),\"{-2,-1,1}\")\n {-1}\n >>> print asin(1) / pi\n 0.5\n >>> x=clifford(\"{1,2,3}\"); print asin(sin(x))\n {1,2,3}\n ";
1365 static char __pyx_k_Main_involution_each_i_is_repla[] = "\n Main involution, each {i} is replaced by -{i} in each term,\n eg. clifford(\"{1}\") -> -clifford(\"{1}\").\n\n >>> print clifford(\"{1}\").involute()\n -{1}\n >>> print (clifford(\"{2}\") * clifford(\"{1}\")).involute()\n -{1,2}\n >>> print (clifford(\"{1}\") * clifford(\"{2}\")).involute()\n {1,2}\n >>> print clifford(\"1+{1}+{1,2}\").involute()\n 1-{1}+{1,2}\n ";
1366 static char __pyx_k_Maximum_absolute_value_of_coord[] = "\n Maximum absolute value of coordinates multivector: multivector infinity-norm.\n\n >>> max_abs(clifford(\"1+{-1}+{1,2}+{1,2,3}\"))\n 1.0\n >>> max_abs(clifford(\"3+2{1}+{1,2}\"))\n 3.0\n\n ";
1367 static char __pyx_k_Maximum_of_absolute_values_of_c[] = "\n Maximum of absolute values of components of multivector: multivector infinity norm.\n\n >>> clifford(\"1+{-1}+{1,2}+{1,2,3}\").max_abs()\n 1.0\n >>> clifford(\"3+2{1}+{1,2}\").max_abs()\n 3.0\n ";
1368 static char __pyx_k_Natural_logarithm_of_multivecto[] = "\n Natural logarithm of multivector with optional complexifier.\n\n >>> x=clifford(\"{-1}\"); print (log(x,\"{-1}\") * 2/pi)\n {-1}\n >>> x=clifford(\"{1,2}\"); print (log(x,\"{1,2,3}\") * 2/pi)\n {1,2}\n >>> x=clifford(\"{1,2}\"); print (log(x) * 2/pi)\n {1,2}\n >>> x=clifford(\"{1,2}\"); print (log(x,\"{1,2}\") * 2/pi)\n Traceback (most recent call last):\n ...\n RuntimeError: check_complex(val, i): i is not a valid complexifier for val\n ";
1369 static char __pyx_k_Norm_sum_of_squares_of_coordina[] = "\n Norm == sum of squares of coordinates.\n\n >>> clifford(\"1+{1}+{1,2}\").norm()\n 3.0\n >>> clifford(\"1+{-1}+{1,2}+{1,2,3}\").norm()\n 4.0\n ";
1370 static char __pyx_k_Not_applicable_for_a_in_cliffor[] = "\n Not applicable.\n\n >>> for a in clifford(index_set({-3,4,7})): print a,\n Traceback (most recent call last):\n ...\n TypeError: Not applicable.\n ";
1371 static char __pyx_k_Number_of_negative_indices_incl[] = "\n Number of negative indices included in set.\n\n >>> index_set({-1,1,2}).count_neg()\n 1\n ";
1372 static char __pyx_k_Number_of_positive_indices_incl[] = "\n Number of positive indices included in set.\n\n >>> index_set({-1,1,2}).count_pos()\n 2\n ";
1373 static char __pyx_k_Outer_product_power_of_multivec[] = "\n Outer product power of multivector.\n\n >>> print outer_pow(clifford(\"1+{1}+{1,2}\"),3)\n 1+3{1}+3{1,2}\n ";
1374 static char __pyx_k_Outer_product_x_clifford_1_x_cl[] = "\n Outer product.\n\n >>> x = clifford(\"{1}\"); x ^= clifford(\"{2}\"); print x\n {1,2}\n >>> x = clifford(2); x ^= clifford(\"{2}\"); print x\n 2{2}\n >>> x = clifford(\"{1}\"); x ^= clifford(\"{1}\"); print x\n 0\n >>> x = clifford(\"{1}\"); x ^= clifford(\"{1,2}\"); print x\n 0\n ";
1375 static char __pyx_k_Pure_grade_vector_part_print_cl[] = "\n Pure grade-vector part.\n\n >>> print clifford(\"{1}\")(1)\n {1}\n >>> print clifford(\"{1}\")(0)\n 0\n >>> print clifford(\"1+{1}+{1,2}\")(0)\n 1\n >>> print clifford(\"1+{1}+{1,2}\")(1)\n {1}\n >>> print clifford(\"1+{1}+{1,2}\")(2)\n {1,2}\n >>> print clifford(\"1+{1}+{1,2}\")(3)\n 0\n ";
1376 static char __pyx_k_Pure_part_print_pure_clifford_1[] = "\n Pure part\n\n >>> print pure(clifford(\"1+{1}+{1,2}\"))\n {1}+{1,2}\n >>> print pure(clifford(\"{1,2}\"))\n {1,2}\n ";
1377 static char __pyx_k_Put_self_into_a_larger_frame_co[] = "\n Put self into a larger frame, containing the union of self.frame() and index set ixt.\n This can be used to make multiplication faster, by multiplying within a common frame.\n\n >>> clifford(\"2+3{1}\").reframe(index_set({1,2,3}))\n clifford(\"2+3{1}\")\n >>> s=index_set({1,2,3});t=index_set({-3,-2,-1});x=random_clifford(s); x.reframe(t).frame() == (s|t);\n True\n ";
1378 static char __pyx_k_Random_multivector_within_a_fra[] = "\n Random multivector within a frame.\n\n >>> print random_clifford(index_set({-3,-1,2})).frame()\n {-3,-1,2}\n ";
1379 static char __pyx_k_Real_part_synonym_for_scalar_pa[] = "\n Real part: synonym for scalar part.\n\n >>> real(clifford(\"1+{1}+{1,2}\"))\n 1.0\n >>> real(clifford(\"{1,2}\"))\n 0.0\n ";
1380 static char __pyx_k_Remove_all_terms_of_self_with_r[] = "\n Remove all terms of self with relative size smaller than limit.\n\n >>> clifford(\"1e8+{1}+1e-8{1,2}\").truncated(1.0e-6)\n clifford(\"100000000\")\n >>> clifford(\"1e4+{1}+1e-4{1,2}\").truncated(1.0e-6)\n clifford(\"10000+{1}\")\n ";
1381 static char __pyx_k_Reversion_eg_1_2_2_1_print_reve[] = "\n Reversion, eg. {1}*{2} -> {2}*{1}\n\n >>> print reverse(clifford(\"{1}\"))\n {1}\n >>> print reverse(clifford(\"{2}\") * clifford(\"{1}\"))\n {1,2}\n >>> print reverse(clifford(\"{1}\") * clifford(\"{2}\"))\n -{1,2}\n >>> print reverse(clifford(\"1+{1}+{1,2}\"))\n 1+{1}-{1,2}\n ";
1382 static char __pyx_k_Reversion_eg_clifford_1_cliffor[] = "\n Reversion, eg. clifford(\"{1}\")*clifford(\"{2}\") -> clifford(\"{2}\")*clifford(\"{1}\").\n\n >>> print clifford(\"{1}\").reverse()\n {1}\n >>> print (clifford(\"{2}\") * clifford(\"{1}\")).reverse()\n {1,2}\n >>> print (clifford(\"{1}\") * clifford(\"{2}\")).reverse()\n -{1,2}\n >>> print clifford(\"1+{1}+{1,2}\").reverse()\n 1+{1}-{1,2}\n ";
1383 static char __pyx_k_Scalar_part_clifford_1_1_1_2_sc[] = "\n Scalar part.\n\n >>> clifford(\"1+{1}+{1,2}\").scalar()\n 1.0\n >>> clifford(\"{1,2}\").scalar()\n 0.0\n ";
1384 static char __pyx_k_Scalar_part_scalar_clifford_1_1[] = "\n Scalar part.\n\n >>> scalar(clifford(\"1+{1}+{1,2}\"))\n 1.0\n >>> scalar(clifford(\"{1,2}\"))\n 0.0\n ";
1385 static char __pyx_k_Set_intersection_and_print_inde[] = "\n Set intersection: and.\n\n >>> print index_set({1}) & index_set({2})\n {}\n >>> print index_set({1,2}) & index_set({2})\n {2}\n ";
1386 static char __pyx_k_Set_intersection_and_x_index_se[] = "\n Set intersection: and.\n\n >>> x = index_set({1}); x &= index_set({2}); print x\n {}\n >>> x = index_set({1,2}); x &= index_set({2}); print x\n {2}\n ";
1387 static char __pyx_k_Set_the_value_of_an_index_set_o[] = "\n Set the value of an index_set object at index idx to value val.\n\n >>> s=index_set({1}); s[2] = True; print s\n {1,2}\n >>> s=index_set({1,2}); s[1] = False; print s\n {2}\n ";
1388 static char __pyx_k_Set_union_or_x_index_set_1_x_in[] = "\n Set union: or.\n\n >>> x = index_set({1}); x |= index_set({2}); print x\n {1,2}\n >>> x = index_set({1,2}); x |= index_set({2}); print x\n {1,2}\n ";
1389 static char __pyx_k_Sign_of_geometric_product_of_tw[] = "\n Sign of geometric product of two Clifford basis elements.\n\n >>> s = index_set({1,2}); t=index_set({-1}); s.sign_of_mult(t)\n 1\n ";
1390 static char __pyx_k_Sign_of_geometric_square_of_a_C[] = "\n Sign of geometric square of a Clifford basis element.\n\n >>> s = index_set({1,2}); s.sign_of_square()\n -1\n ";
1391 static char __pyx_k_Sine_of_multivector_with_option[] = "\n Sine of multivector with optional complexifier.\n\n >>> s=\"{-1}\"; x=clifford(s); print asin(sin(x,s),s)\n {-1}\n >>> s=\"{-1}\"; x=clifford(s); print asin(sin(x,s),\"{-2,-1,1}\")\n {-1}\n >>> x=clifford(\"{1,2,3}\"); print asin(sin(x))\n {1,2,3}\n ";
1392 static char __pyx_k_Square_root_of_1_which_commutes[] = "\n Square root of -1 which commutes with all members of the frame of the given multivector.\n\n >>> print complexifier(clifford(index_set({1})))\n {1,2,3}\n >>> print complexifier(clifford(index_set({-1})))\n {-1}\n >>> print complexifier(index_set({1}))\n {1,2,3}\n >>> print complexifier(index_set({-1}))\n {-1}\n ";
1393 static char __pyx_k_Square_root_of_multivector_with[] = "\n Square root of multivector with optional complexifier.\n\n >>> print sqrt(-1)\n {-1}\n >>> print sqrt(clifford(\"2{-1}\"))\n 1+{-1}\n >>> j=sqrt(-1,complexifier(index_set({1}))); print j; print j*j\n {1,2,3}\n -1\n >>> j=sqrt(-1,\"{1,2,3}\"); print j; print j*j\n {1,2,3}\n -1\n ";
1394 static char __pyx_k_Subalgebra_generated_by_all_gen[] = "\n Subalgebra generated by all generators of terms of given multivector.\n\n >>> print clifford(\"1+3{-1}+2{1,2}+4{-2,7}\").frame()\n {-2,-1,1,2,7}\n >>> s=clifford(\"1+3{-1}+2{1,2}+4{-2,7}\").frame(); type(s)\n <type 'PyClical.index_set'>\n ";
1395 static char __pyx_k_Subscripting_map_from_index_set[] = "\n Subscripting: map from index set to scalar coordinate.\n\n >>> clifford(\"{1}\")[index_set(1)]\n 1.0\n >>> clifford(\"{1}\")[index_set({1})]\n 1.0\n >>> clifford(\"{1}\")[index_set({1,2})]\n 0.0\n >>> clifford(\"2{1,2}\")[index_set({1,2})]\n 2.0\n ";
1396 static char __pyx_k_Symmetric_set_difference_exclus[] = "\n Symmetric set difference: exclusive or.\n\n >>> print index_set({1}) ^ index_set({2})\n {1,2}\n >>> print index_set({1,2}) ^ index_set({2})\n {1}\n ";
1397 static char __pyx_k_Tangent_of_multivector_with_opt[] = "\n Tangent of multivector with optional complexifier.\n\n >>> x=clifford(\"{1,2}\"); print tan(x,\"{1,2,3}\")\n 0.7616{1,2}\n >>> x=clifford(\"{1,2}\"); print tan(x)\n 0.7616{1,2}\n ";
1398 static char __pyx_k_Tests_for_functions_that_Doctes[] = "\n Tests for functions that Doctest cannot see.\n\n For index_set.__cinit__: Construct index_set.\n\n >>> print index_set(1)\n {1}\n >>> print index_set({1,2})\n {1,2}\n >>> print index_set(index_set({1,2}))\n {1,2}\n >>> print index_set({1,2})\n {1,2}\n >>> print index_set({1,2,1})\n {1,2}\n >>> print index_set({1,2,1})\n {1,2}\n >>> print index_set(\"\")\n {}\n >>> print index_set(\"{\")\n Traceback (most recent call last):\n ...\n ValueError: Cannot initialize index_set object from invalid string '{'.\n >>> print index_set(\"{1\")\n Traceback (most recent call last):\n ...\n ValueError: Cannot initialize index_set object from invalid string '{1'.\n >>> print index_set(\"{1,2,100}\")\n Traceback (most recent call last):\n ...\n ValueError: Cannot initialize index_set object from invalid string '{1,2,100}'.\n >>> print index_set({1,2,100})\n Traceback (most recent call last):\n ...\n IndexError: Cannot initialize index_set object from invalid set([1, 2, 100]).\n >>> print index_set([1,2])\n Traceback (most recent call last):\n ...\n TypeError: Cannot initialize index_set object from <type 'list'>.\n\n For index_set.__richcmp__: Compare two objects of class index_set.\n\n >>> index_set(1) == index_set({1})\n True\n >>> index_set({1}) != index_set({1})\n False\n >>> index_set({1}) != index_set({2})\n True\n >>> index_set({1}) == index_set({2})\n False\n >>> index_set({1}) < index_set({2})\n True\n >>> index_set({1}) <= index_set({2})\n True\n >>> index_set({1}) > index_set({2})\n False\n >>> index_set({1}) >= index_set({2})\n False\n >>> None == index_set({1,2})\n False\n >>> None != index_set({1,2})\n True\n >>> None < index_set({1,2})\n False\n >>> None <= index_set({1,2})\n False\n >>> None > index_set({1,2})\n False\n >>> None >= index_set({1,2})\n False\n >>> index_se""t({1,2}) == None\n False\n >>> index_set({1,2}) != None\n True\n >>> index_set({1,2}) < None\n False\n >>> index_set({1,2}) <= None\n False\n >>> index_set({1,2}) > None\n False\n >>> index_set({1,2}) >= None\n False\n ";
1399  static char __pyx_k_The_informal_string_representat[] = "\n The \342\200\234informal\342\200\235 string representation of self.\n\n >>> index_set({1,2}).__str__()\n '{1,2}'\n >>> str(index_set({1,2}))\n '{1,2}'\n ";
1400  static char __pyx_k_The_official_string_representat[] = "\n The \342\200\234official\342\200\235 string representation of self.\n\n >>> index_set({1,2}).__repr__()\n 'index_set({1,2})'\n >>> repr(index_set({1,2}))\n 'index_set({1,2})'\n ";
1401  static char __pyx_k_This_comparison_operator_is_not[] = "This comparison operator is not implemented for ";
1402  static char __pyx_k_Vector_part_of_multivector_as_a[] = "\n Vector part of multivector, as a Python list, with respect to frm.\n\n >>> print clifford(\"1+2{1}+3{2}+4{1,2}\").vector_part()\n [2.0, 3.0]\n >>> print clifford(\"1+2{1}+3{2}+4{1,2}\").vector_part(index_set({-1,1,2}))\n [0.0, 2.0, 3.0]\n ";
1403  static char __pyx_k_home_leopardi_sync_src_glucat_g[] = "/home/leopardi/sync/src/glucat/git/dist/glucat-git/pyclical/PyClical.pyx";
1404  static char __pyx_k_index_set_sign_of_mult_line_364[] = "index_set.sign_of_mult (line 364)";
1405  static char __pyx_k_norm_sum_of_squares_of_coordina[] = "\n norm == sum of squares of coordinates.\n\n >>> norm(clifford(\"1+{1}+{1,2}\"))\n 3.0\n >>> norm(clifford(\"1+{-1}+{1,2}+{1,2,3}\"))\n 4.0\n ";
1406  static char __pyx_k_Cannot_initialize_clifford_objec[] = "Cannot initialize clifford object from";
1407  static char __pyx_k_Cannot_initialize_index_set_obje[] = "Cannot initialize index_set object from";
1408  static char __pyx_k_Conjugation_reverse_o_involute_2[] = "\n Conjugation, reverse o involute == involute o reverse.\n\n >>> print conj(clifford(\"{1}\"))\n -{1}\n >>> print conj(clifford(\"{2}\") * clifford(\"{1}\"))\n {1,2}\n >>> print conj(clifford(\"{1}\") * clifford(\"{2}\"))\n -{1,2}\n >>> print conj(clifford(\"1+{1}+{1,2}\"))\n 1-{1}-{1,2}\n ";
1409  static char __pyx_k_Odd_part_of_multivector_sum_of_2[] = "\n Odd part of multivector, sum of odd grade terms.\n\n >>> print odd(clifford(\"1+{1}+{1,2}\"))\n {1}\n ";
1410  static char __pyx_k_Power_self_to_the_m_x_clifford_2[] = "\n Power: self to the m.\n\n >>> x=clifford(\"{1}\"); print x.pow(2)\n 1\n >>> x=clifford(\"2\"); print x.pow(2)\n 4\n >>> x=clifford(\"2+{1}\"); print x.pow(0)\n 1\n >>> x=clifford(\"2+{1}\"); print x.pow(1)\n 2+{1}\n >>> x=clifford(\"2+{1}\"); print x.pow(2)\n 5+4{1}\n >>> print clifford(\"1+{1}+{1,2}\").pow(3)\n 1+3{1}+3{1,2}\n >>> i=clifford(\"{1,2}\");print exp(pi/2) * i.pow(i)\n 1\n ";
1411  static char __pyx_k_Quadratic_form_rev_x_x_0_print_2[] = "\n Quadratic form == (rev(x)*x)(0).\n\n >>> print quad(clifford(\"1+{1}+{1,2}\"))\n 3.0\n >>> print quad(clifford(\"1+{-1}+{1,2}+{1,2,3}\"))\n 2.0\n ";
1412  static char __pyx_k_Transform_left_hand_side_using_2[] = "\n Transform left hand side, using right hand side as a transformation.\n\n >>> x=clifford(\"{1,2}\") * pi/2; y=clifford(\"{1}\"); y|=x; print y\n -{1}\n >>> x=clifford(\"{1,2}\") * pi/2; y=clifford(\"{1}\"); y|=exp(x); print y\n -{1}\n ";
1413  static char __pyx_k_clifford_hidden_doctests_line_12[] = "clifford_hidden_doctests (line 1243)";
1414  static char __pyx_k_index_set_hidden_doctests_line_4[] = "index_set_hidden_doctests (line 404)";
1415  static char __pyx_k_index_set_sign_of_square_line_37[] = "index_set.sign_of_square (line 373)";
1416  static char __pyx_k_Even_part_of_multivector_sum_of_2[] = "\n Even part of multivector, sum of even grade terms.\n\n >>> print even(clifford(\"1+{1}+{1,2}\"))\n 1+{1,2}\n ";
1417  static char __pyx_k_Geometric_multiplicative_invers_2[] = "\n Geometric multiplicative inverse.\n\n >>> print inv(clifford(\"{1}\"))\n {1}\n >>> print inv(clifford(\"{-1}\"))\n -{-1}\n >>> print inv(clifford(\"{-2,-1}\"))\n -{-2,-1}\n >>> print inv(clifford(\"{-1}+{1}\"))\n nan\n ";
1418  static char __pyx_k_Main_involution_each_i_is_repla_2[] = "\n Main involution, each {i} is replaced by -{i} in each term, eg. {1}*{2} -> (-{2})*(-{1})\n\n >>> print involute(clifford(\"{1}\"))\n -{1}\n >>> print involute(clifford(\"{2}\") * clifford(\"{1}\"))\n -{1,2}\n >>> print involute(clifford(\"{1}\") * clifford(\"{2}\"))\n {1,2}\n >>> print involute(clifford(\"1+{1}+{1,2}\"))\n 1-{1}+{1,2}\n ";
1419  static char __pyx_k_Symmetric_set_difference_exclus_2[] = "\n Symmetric set difference: exclusive or.\n\n >>> x = index_set({1}); x ^= index_set({2}); print x\n {1,2}\n >>> x = index_set({1,2}); x ^= index_set({2}); print x\n {1}\n ";
1420  static char __pyx_k_Tests_for_functions_that_Doctes_2[] = "\n Tests for functions that Doctest cannot see.\n\n For clifford.__cinit__: Construct an object of type clifford.\n\n >>> print clifford(2)\n 2\n >>> print clifford(2L)\n 2\n >>> print clifford(2.0)\n 2\n >>> print clifford(1.0e-1)\n 0.1\n >>> print clifford(\"2\")\n 2\n >>> print clifford(\"2{1,2,3}\")\n 2{1,2,3}\n >>> print clifford(clifford(\"2{1,2,3}\"))\n 2{1,2,3}\n >>> print clifford(\"-{1}\")\n -{1}\n >>> print clifford(2,index_set({1,2}))\n 2{1,2}\n >>> print clifford([2,3],index_set({1,2}))\n 2{1}+3{2}\n >>> print clifford([1,2])\n Traceback (most recent call last):\n ...\n TypeError: Cannot initialize clifford object from <type 'list'>.\n >>> print clifford(None)\n Traceback (most recent call last):\n ...\n TypeError: Cannot initialize clifford object from <type 'NoneType'>.\n >>> print clifford(None,[1,2])\n Traceback (most recent call last):\n ...\n TypeError: Cannot initialize clifford object from (<type 'NoneType'>, <type 'list'>).\n >>> print clifford([1,2],[1,2])\n Traceback (most recent call last):\n ...\n TypeError: Cannot initialize clifford object from (<type 'list'>, <type 'list'>).\n >>> print clifford(\"\")\n Traceback (most recent call last):\n ...\n ValueError: Cannot initialize clifford object from invalid string ''.\n >>> print clifford(\"{\")\n Traceback (most recent call last):\n ...\n ValueError: Cannot initialize clifford object from invalid string '{'.\n >>> print clifford(\"{1\")\n Traceback (most recent call last):\n ...\n ValueError: Cannot initialize clifford object from invalid string '{1'.\n >>> print clifford(\"+\")\n Traceback (most recent call last):\n ...\n ValueError: Cannot initialize clifford object from invalid string '+'.\n >>> print clifford(\"-\")\n Traceback (most recent call last):\n ...\n ValueError: Cannot initialize clifford"" object from invalid string '-'.\n >>> print clifford(\"{1}+\")\n Traceback (most recent call last):\n ...\n ValueError: Cannot initialize clifford object from invalid string '{1}+'.\n\n For clifford.__richcmp__: Compare objects of type clifford.\n\n >>> clifford(\"{1}\") == clifford(\"1{1}\")\n True\n >>> clifford(\"{1}\") != clifford(\"1.0{1}\")\n False\n >>> clifford(\"{1}\") != clifford(\"1.0\")\n True\n >>> clifford(\"{1,2}\") == None\n False\n >>> clifford(\"{1,2}\") != None\n True\n >>> None == clifford(\"{1,2}\")\n False\n >>> None != clifford(\"{1,2}\")\n True\n ";
1421  static char __pyx_k_The_informal_string_representat_2[] = "\n The \342\200\234informal\342\200\235 string representation of self.\n\n >>> clifford(\"1+3{-1}+2{1,2}+4{-2,7}\").__str__()\n '1+3{-1}+2{1,2}+4{-2,7}'\n ";
1422  static char __pyx_k_The_official_string_representat_2[] = "\n The \342\200\234official\342\200\235 string representation of self.\n\n >>> clifford(\"1+3{-1}+2{1,2}+4{-2,7}\").__repr__()\n 'clifford(\"1+3{-1}+2{1,2}+4{-2,7}\")'\n ";
1423  static PyObject *__pyx_kp_s_;
1424  static PyObject *__pyx_kp_s_0_8_2;
1425  static PyObject *__pyx_kp_u_Abbreviation_for_clifford_index;
1426  static PyObject *__pyx_kp_u_Abbreviation_for_index_set_q_p;
1427  static PyObject *__pyx_kp_u_Absolute_value_of_multivector_m;
1428  static PyObject *__pyx_kp_u_Absolute_value_square_root_of_n;
1429  static PyObject *__pyx_kp_s_Cannot_initialize_clifford_objec;
1430  static PyObject *__pyx_kp_s_Cannot_initialize_index_set_obje;
1431  static PyObject *__pyx_kp_s_Cannot_reframe;
1432  static PyObject *__pyx_kp_s_Cannot_take_vector_part_of;
1433  static PyObject *__pyx_kp_u_Cardinality_Number_of_indices_i;
1434  static PyObject *__pyx_kp_u_Check_if_a_multivector_contains;
1435  static PyObject *__pyx_kp_u_Conjugation_reverse_o_involute;
1436  static PyObject *__pyx_kp_u_Conjugation_reverse_o_involute_2;
1437  static PyObject *__pyx_kp_u_Contraction_print_clifford_1_cl;
1438  static PyObject *__pyx_kp_u_Contraction_x_clifford_1_x_clif;
1439  static PyObject *__pyx_kp_u_Convert_CGA3_null_vector_to_Euc;
1440  static PyObject *__pyx_kp_u_Convert_CGA3_null_vector_to_sta;
1441  static PyObject *__pyx_kp_u_Convert_Euclidean_3D_multivecto;
1442  static PyObject *__pyx_kp_u_Copy_this_clifford_object_x_cli;
1443  static PyObject *__pyx_kp_u_Copy_this_index_set_object_s_in;
1444  static PyObject *__pyx_kp_u_Cosine_of_multivector_with_opti;
1445  static PyObject *__pyx_kp_u_Even_part_of_multivector_sum_of;
1446  static PyObject *__pyx_kp_u_Even_part_of_multivector_sum_of_2;
1447  static PyObject *__pyx_kp_u_Exponential_of_multivector_x_cl;
1448  static PyObject *__pyx_kp_u_Geometric_difference_print_clif;
1449  static PyObject *__pyx_kp_u_Geometric_difference_x_clifford;
1450  static PyObject *__pyx_kp_u_Geometric_multiplicative_invers;
1451  static PyObject *__pyx_kp_u_Geometric_multiplicative_invers_2;
1452  static PyObject *__pyx_kp_u_Geometric_product_print_cliffor;
1453  static PyObject *__pyx_kp_u_Geometric_product_x_clifford_2;
1454  static PyObject *__pyx_kp_u_Geometric_quotient_print_cliffo;
1455  static PyObject *__pyx_kp_u_Geometric_quotient_x_clifford_1;
1456  static PyObject *__pyx_kp_u_Geometric_sum_print_clifford_1;
1457  static PyObject *__pyx_kp_u_Geometric_sum_x_clifford_1_x_cl;
1458  static PyObject *__pyx_kp_u_Get_the_value_of_an_index_set_o;
1459  static PyObject *__pyx_kp_u_Hyperbolic_cosine_of_multivecto;
1460  static PyObject *__pyx_kp_u_Hyperbolic_sine_of_multivector;
1461  static PyObject *__pyx_kp_u_Hyperbolic_tangent_of_multivect;
1462  static PyObject *__pyx_kp_u_Imaginary_part_deprecated_alway;
1463  static PyObject *__pyx_n_s_IndexError;
1464  static PyObject *__pyx_kp_u_Inner_product_print_clifford_1;
1465  static PyObject *__pyx_kp_u_Inner_product_x_clifford_1_x_cl;
1466  static PyObject *__pyx_kp_u_Integer_power_of_multivector_ob;
1467  static PyObject *__pyx_n_s_Integral;
1468  static PyObject *__pyx_kp_u_Inverse_cosine_of_multivector_w;
1469  static PyObject *__pyx_kp_u_Inverse_hyperbolic_cosine_of_mu;
1470  static PyObject *__pyx_kp_u_Inverse_hyperbolic_sine_of_mult;
1471  static PyObject *__pyx_kp_u_Inverse_hyperbolic_tangent_of_m;
1472  static PyObject *__pyx_kp_u_Inverse_sine_of_multivector_wit;
1473  static PyObject *__pyx_kp_u_Inverse_tangent_of_multivector;
1474  static PyObject *__pyx_kp_u_Iterate_over_the_indices_of_an;
1475  static PyObject *__pyx_kp_u_Main_involution_each_i_is_repla;
1476  static PyObject *__pyx_kp_u_Main_involution_each_i_is_repla_2;
1477  static PyObject *__pyx_kp_u_Maximum_absolute_value_of_coord;
1478  static PyObject *__pyx_kp_u_Maximum_member_index_set_1_1_2;
1479  static PyObject *__pyx_kp_u_Maximum_of_absolute_values_of_c;
1480  static PyObject *__pyx_kp_u_Maximum_positive_index_or_0_if;
1481  static PyObject *__pyx_kp_u_Minimum_member_index_set_1_1_2;
1482  static PyObject *__pyx_kp_u_Minimum_negative_index_or_0_if;
1483  static PyObject *__pyx_kp_u_Natural_logarithm_of_multivecto;
1484  static PyObject *__pyx_kp_u_Norm_sum_of_squares_of_coordina;
1485  static PyObject *__pyx_n_s_NotImplemented;
1486  static PyObject *__pyx_kp_s_Not_applicable;
1487  static PyObject *__pyx_kp_u_Not_applicable_for_a_in_cliffor;
1488  static PyObject *__pyx_kp_u_Number_of_negative_indices_incl;
1489  static PyObject *__pyx_kp_u_Number_of_positive_indices_incl;
1490  static PyObject *__pyx_kp_u_Odd_part_of_multivector_sum_of;
1491  static PyObject *__pyx_kp_u_Odd_part_of_multivector_sum_of_2;
1492  static PyObject *__pyx_kp_u_Outer_product_power_of_multivec;
1493  static PyObject *__pyx_kp_u_Outer_product_power_x_clifford;
1494  static PyObject *__pyx_kp_u_Outer_product_print_clifford_1;
1495  static PyObject *__pyx_kp_u_Outer_product_x_clifford_1_x_cl;
1496  static PyObject *__pyx_kp_u_Power_self_to_the_m_x_clifford;
1497  static PyObject *__pyx_kp_u_Power_self_to_the_m_x_clifford_2;
1498  static PyObject *__pyx_kp_u_Pure_grade_vector_part_print_cl;
1499  static PyObject *__pyx_kp_u_Pure_part_print_clifford_1_1_1;
1500  static PyObject *__pyx_kp_u_Pure_part_print_pure_clifford_1;
1501  static PyObject *__pyx_kp_u_Put_self_into_a_larger_frame_co;
1502  static PyObject *__pyx_n_s_PyClical;
1503  static PyObject *__pyx_kp_u_Quadratic_form_rev_x_x_0_print;
1504  static PyObject *__pyx_kp_u_Quadratic_form_rev_x_x_0_print_2;
1505  static PyObject *__pyx_kp_u_Random_multivector_within_a_fra;
1506  static PyObject *__pyx_n_s_Real;
1507  static PyObject *__pyx_kp_u_Real_part_synonym_for_scalar_pa;
1508  static PyObject *__pyx_kp_u_Remove_all_terms_of_self_with_r;
1509  static PyObject *__pyx_kp_u_Reversion_eg_1_2_2_1_print_reve;
1510  static PyObject *__pyx_kp_u_Reversion_eg_clifford_1_cliffor;
1511  static PyObject *__pyx_n_s_RuntimeError;
1512  static PyObject *__pyx_kp_u_Scalar_part_clifford_1_1_1_2_sc;
1513  static PyObject *__pyx_kp_u_Scalar_part_scalar_clifford_1_1;
1514  static PyObject *__pyx_n_s_Sequence;
1515  static PyObject *__pyx_kp_u_Set_complement_not_print_index;
1516  static PyObject *__pyx_kp_u_Set_intersection_and_print_inde;
1517  static PyObject *__pyx_kp_u_Set_intersection_and_x_index_se;
1518  static PyObject *__pyx_kp_u_Set_the_value_of_an_index_set_o;
1519  static PyObject *__pyx_kp_u_Set_union_or_print_index_set_1;
1520  static PyObject *__pyx_kp_u_Set_union_or_x_index_set_1_x_in;
1521  static PyObject *__pyx_kp_u_Sign_of_geometric_product_of_tw;
1522  static PyObject *__pyx_kp_u_Sign_of_geometric_square_of_a_C;
1523  static PyObject *__pyx_kp_u_Sine_of_multivector_with_option;
1524  static PyObject *__pyx_kp_u_Square_root_of_1_which_commutes;
1525  static PyObject *__pyx_kp_u_Square_root_of_multivector_with;
1526  static PyObject *__pyx_kp_u_Subalgebra_generated_by_all_gen;
1527  static PyObject *__pyx_kp_u_Subscripting_map_from_index_set;
1528  static PyObject *__pyx_kp_u_Symmetric_set_difference_exclus;
1529  static PyObject *__pyx_kp_u_Symmetric_set_difference_exclus_2;
1530  static PyObject *__pyx_kp_u_Tangent_of_multivector_with_opt;
1531  static PyObject *__pyx_kp_u_Tests_for_functions_that_Doctes;
1532  static PyObject *__pyx_kp_u_Tests_for_functions_that_Doctes_2;
1533  static PyObject *__pyx_kp_u_The_informal_string_representat;
1534  static PyObject *__pyx_kp_u_The_informal_string_representat_2;
1535  static PyObject *__pyx_kp_u_The_official_string_representat;
1536  static PyObject *__pyx_kp_u_The_official_string_representat_2;
1537  static PyObject *__pyx_kp_s_This_comparison_operator_is_not;
1538  static PyObject *__pyx_kp_u_Transform_left_hand_side_using;
1539  static PyObject *__pyx_kp_u_Transform_left_hand_side_using_2;
1540  static PyObject *__pyx_n_s_TypeError;
1541  static PyObject *__pyx_kp_u_Unary_print_clifford_1_1;
1542  static PyObject *__pyx_kp_u_Unary_print_clifford_1_1_2;
1543  static PyObject *__pyx_n_s_ValueError;
1544  static PyObject *__pyx_kp_u_Vector_part_of_multivector_as_a;
1545  static PyObject *__pyx_kp_s__2;
1546  static PyObject *__pyx_kp_s__3;
1547  static PyObject *__pyx_kp_s__4;
1548  static PyObject *__pyx_kp_s__5;
1549  static PyObject *__pyx_kp_s__6;
1550  static PyObject *__pyx_kp_s__7;
1551  static PyObject *__pyx_kp_u_abs_line_1473;
1552  static PyObject *__pyx_n_s_acos;
1553  static PyObject *__pyx_kp_u_acos_line_1619;
1554  static PyObject *__pyx_n_s_acosh;
1555  static PyObject *__pyx_kp_u_acosh_line_1656;
1556  static PyObject *__pyx_kp_u_agc3_line_1844;
1557  static PyObject *__pyx_n_s_args;
1558  static PyObject *__pyx_kp_s_as_frame;
1559  static PyObject *__pyx_n_s_asin;
1560  static PyObject *__pyx_kp_u_asin_line_1698;
1561  static PyObject *__pyx_n_s_asinh;
1562  static PyObject *__pyx_kp_u_asinh_line_1733;
1563  static PyObject *__pyx_n_s_atan;
1564  static PyObject *__pyx_kp_u_atan_line_1769;
1565  static PyObject *__pyx_n_s_atanh;
1566  static PyObject *__pyx_kp_u_atanh_line_1798;
1567  static PyObject *__pyx_kp_u_cga3_line_1824;
1568  static PyObject *__pyx_kp_u_cga3std_line_1833;
1569  static PyObject *__pyx_n_s_cl;
1570  static PyObject *__pyx_kp_u_clifford___add___line_739;
1571  static PyObject *__pyx_kp_u_clifford___and___line_835;
1572  static PyObject *__pyx_kp_u_clifford___call___line_1019;
1573  static PyObject *__pyx_kp_u_clifford___div___line_895;
1574  static PyObject *__pyx_kp_u_clifford___getitem___line_706;
1575  static PyObject *__pyx_kp_u_clifford___iadd___line_750;
1576  static PyObject *__pyx_kp_u_clifford___iand___line_850;
1577  static PyObject *__pyx_kp_u_clifford___idiv___line_910;
1578  static PyObject *__pyx_kp_u_clifford___imod___line_820;
1579  static PyObject *__pyx_kp_u_clifford___imul___line_792;
1580  static PyObject *__pyx_kp_u_clifford___ior___line_949;
1581  static PyObject *__pyx_kp_u_clifford___isub___line_770;
1582  static PyObject *__pyx_kp_u_clifford___iter___line_637;
1583  static PyObject *__pyx_kp_u_clifford___ixor___line_880;
1584  static PyObject *__pyx_kp_u_clifford___mod___line_805;
1585  static PyObject *__pyx_kp_u_clifford___mul___line_779;
1586  static PyObject *__pyx_kp_u_clifford___neg___line_721;
1587  static PyObject *__pyx_kp_u_clifford___or___line_938;
1588  static PyObject *__pyx_kp_u_clifford___pos___line_730;
1589  static PyObject *__pyx_kp_u_clifford___pow___line_960;
1590  static PyObject *__pyx_kp_u_clifford___repr___line_1225;
1591  static PyObject *__pyx_kp_u_clifford___str___line_1234;
1592  static PyObject *__pyx_kp_u_clifford___sub___line_759;
1593  static PyObject *__pyx_kp_u_clifford___xor___line_865;
1594  static PyObject *__pyx_kp_u_clifford_abs_line_1174;
1595  static PyObject *__pyx_kp_u_clifford_conj_line_1137;
1596  static PyObject *__pyx_kp_u_clifford_copy_line_554;
1597  static PyObject *__pyx_kp_u_clifford_even_line_1060;
1598  static PyObject *__pyx_kp_u_clifford_frame_line_1214;
1599  static PyObject *__pyx_n_s_clifford_hidden_doctests;
1600  static PyObject *__pyx_kp_u_clifford_hidden_doctests_line_12;
1601  static PyObject *__pyx_kp_u_clifford_inv_line_925;
1602  static PyObject *__pyx_kp_u_clifford_involute_line_1106;
1603  static PyObject *__pyx_kp_u_clifford_isnan_line_1205;
1604  static PyObject *__pyx_kp_u_clifford_max_abs_line_1183;
1605  static PyObject *__pyx_kp_u_clifford_norm_line_1163;
1606  static PyObject *__pyx_kp_u_clifford_odd_line_1069;
1607  static PyObject *__pyx_kp_u_clifford_outer_pow_line_1003;
1608  static PyObject *__pyx_kp_u_clifford_pow_line_979;
1609  static PyObject *__pyx_kp_u_clifford_pure_line_1049;
1610  static PyObject *__pyx_kp_u_clifford_quad_line_1152;
1611  static PyObject *__pyx_kp_u_clifford_reframe_line_648;
1612  static PyObject *__pyx_kp_u_clifford_reverse_line_1122;
1613  static PyObject *__pyx_kp_u_clifford_scalar_line_1038;
1614  static PyObject *__pyx_kp_u_clifford_truncated_line_1194;
1615  static PyObject *__pyx_kp_u_clifford_vector_part_line_1078;
1616  static PyObject *__pyx_n_s_close;
1617  static PyObject *__pyx_n_s_collections;
1618  static PyObject *__pyx_kp_u_compare_line_490;
1619  static PyObject *__pyx_kp_u_complexifier_line_1527;
1620  static PyObject *__pyx_n_s_conj;
1621  static PyObject *__pyx_kp_u_conj_line_1436;
1622  static PyObject *__pyx_n_s_copy;
1623  static PyObject *__pyx_n_s_cos;
1624  static PyObject *__pyx_kp_u_cos_line_1602;
1625  static PyObject *__pyx_n_s_cosh;
1626  static PyObject *__pyx_kp_u_cosh_line_1640;
1627  static PyObject *__pyx_n_s_doctest;
1628  static PyObject *__pyx_n_s_e;
1629  static PyObject *__pyx_kp_u_e_line_1887;
1630  static PyObject *__pyx_n_s_even;
1631  static PyObject *__pyx_kp_u_even_line_1388;
1632  static PyObject *__pyx_n_s_exp;
1633  static PyObject *__pyx_kp_u_exp_line_1565;
1634  static PyObject *__pyx_n_s_fill;
1635  static PyObject *__pyx_n_s_frm;
1636  static PyObject *__pyx_kp_s_from;
1637  static PyObject *__pyx_n_s_grade;
1638  static PyObject *__pyx_kp_s_home_leopardi_sync_src_glucat_g;
1639  static PyObject *__pyx_n_s_i;
1640  static PyObject *__pyx_kp_u_imag_line_1366;
1641  static PyObject *__pyx_n_s_import;
1642  static PyObject *__pyx_kp_u_index_set___and___line_269;
1643  static PyObject *__pyx_kp_u_index_set___getitem___line_189;
1644  static PyObject *__pyx_kp_u_index_set___iand___line_280;
1645  static PyObject *__pyx_kp_u_index_set___invert___line_238;
1646  static PyObject *__pyx_kp_u_index_set___ior___line_302;
1647  static PyObject *__pyx_n_s_index_set___iter;
1648  static PyObject *__pyx_kp_u_index_set___iter___line_227;
1649  static PyObject *__pyx_kp_u_index_set___ixor___line_258;
1650  static PyObject *__pyx_kp_u_index_set___or___line_291;
1651  static PyObject *__pyx_kp_u_index_set___repr___line_382;
1652  static PyObject *__pyx_kp_u_index_set___setitem___line_177;
1653  static PyObject *__pyx_kp_u_index_set___str___line_393;
1654  static PyObject *__pyx_kp_u_index_set___xor___line_247;
1655  static PyObject *__pyx_kp_u_index_set_copy_line_64;
1656  static PyObject *__pyx_kp_u_index_set_count_line_313;
1657  static PyObject *__pyx_kp_u_index_set_count_neg_line_322;
1658  static PyObject *__pyx_kp_u_index_set_count_pos_line_331;
1659  static PyObject *__pyx_n_s_index_set_hidden_doctests;
1660  static PyObject *__pyx_kp_u_index_set_hidden_doctests_line_4;
1661  static PyObject *__pyx_kp_u_index_set_max_line_349;
1662  static PyObject *__pyx_kp_u_index_set_min_line_340;
1663  static PyObject *__pyx_kp_u_index_set_sign_of_mult_line_364;
1664  static PyObject *__pyx_kp_u_index_set_sign_of_square_line_37;
1665  static PyObject *__pyx_n_s_inv;
1666  static PyObject *__pyx_kp_u_inv_line_1329;
1667  static PyObject *__pyx_kp_s_invalid;
1668  static PyObject *__pyx_kp_s_invalid_string;
1669  static PyObject *__pyx_n_s_involute;
1670  static PyObject *__pyx_kp_u_involute_line_1406;
1671  static PyObject *__pyx_n_s_ist;
1672  static PyObject *__pyx_n_s_istpq;
1673  static PyObject *__pyx_kp_u_istpq_line_1900;
1674  static PyObject *__pyx_n_s_iter;
1675  static PyObject *__pyx_n_s_ixt;
1676  static PyObject *__pyx_kp_u_lexicographic_compare_eg_3_4_5;
1677  static PyObject *__pyx_n_s_lhs;
1678  static PyObject *__pyx_n_s_log;
1679  static PyObject *__pyx_kp_u_log_line_1579;
1680  static PyObject *__pyx_n_s_m;
1681  static PyObject *__pyx_n_s_main;
1682  static PyObject *__pyx_n_s_math;
1683  static PyObject *__pyx_n_s_max;
1684  static PyObject *__pyx_kp_u_max_abs_line_1482;
1685  static PyObject *__pyx_kp_u_max_pos_line_511;
1686  static PyObject *__pyx_n_s_min;
1687  static PyObject *__pyx_kp_u_min_neg_line_502;
1688  static PyObject *__pyx_n_s_name;
1689  static PyObject *__pyx_n_s_nbar3;
1690  static PyObject *__pyx_n_s_ninf3;
1691  static PyObject *__pyx_n_s_norm;
1692  static PyObject *__pyx_kp_u_norm_line_1462;
1693  static PyObject *__pyx_kp_u_norm_sum_of_squares_of_coordina;
1694  static PyObject *__pyx_n_s_numbers;
1695  static PyObject *__pyx_n_s_obj;
1696  static PyObject *__pyx_n_s_odd;
1697  static PyObject *__pyx_kp_u_odd_line_1397;
1698  static PyObject *__pyx_n_s_other;
1699  static PyObject *__pyx_n_s_outer_pow;
1700  static PyObject *__pyx_kp_u_outer_pow_line_1518;
1701  static PyObject *__pyx_n_s_p;
1702  static PyObject *__pyx_n_s_pi;
1703  static PyObject *__pyx_n_s_pow;
1704  static PyObject *__pyx_kp_u_pow_line_1494;
1705  static PyObject *__pyx_n_s_pure;
1706  static PyObject *__pyx_kp_u_pure_line_1377;
1707  static PyObject *__pyx_n_s_pyx_vtable;
1708  static PyObject *__pyx_n_s_q;
1709  static PyObject *__pyx_n_s_quad;
1710  static PyObject *__pyx_kp_u_quad_line_1451;
1711  static PyObject *__pyx_kp_u_random_clifford_line_1815;
1712  static PyObject *__pyx_n_s_range;
1713  static PyObject *__pyx_kp_u_real_line_1355;
1714  static PyObject *__pyx_n_s_reverse;
1715  static PyObject *__pyx_kp_u_reverse_line_1421;
1716  static PyObject *__pyx_n_s_rhs;
1717  static PyObject *__pyx_n_s_scalar;
1718  static PyObject *__pyx_kp_u_scalar_line_1344;
1719  static PyObject *__pyx_n_s_send;
1720  static PyObject *__pyx_n_s_sin;
1721  static PyObject *__pyx_kp_u_sin_line_1679;
1722  static PyObject *__pyx_n_s_sinh;
1723  static PyObject *__pyx_kp_u_sinh_line_1719;
1724  static PyObject *__pyx_n_s_sqrt;
1725  static PyObject *__pyx_kp_u_sqrt_line_1542;
1726  static PyObject *__pyx_n_s_tan;
1727  static PyObject *__pyx_kp_u_tan_line_1752;
1728  static PyObject *__pyx_n_s_tanh;
1729  static PyObject *__pyx_kp_u_tanh_line_1786;
1730  static PyObject *__pyx_n_s_tau;
1731  static PyObject *__pyx_n_s_test;
1732  static PyObject *__pyx_n_s_test_2;
1733  static PyObject *__pyx_n_s_testmod;
1734  static PyObject *__pyx_n_s_throw;
1735  static PyObject *__pyx_kp_s_to_frame;
1736  static PyObject *__pyx_kp_s_using;
1737  static PyObject *__pyx_kp_s_using_invalid;
1738  static PyObject *__pyx_kp_s_value;
1739  static PyObject *__pyx_n_s_version;
1740  static PyObject *__pyx_n_s_xrange;
1741 static PyObject *__pyx_pf_8PyClical_9index_set_copy(struct __pyx_obj_8PyClical_index_set *__pyx_v_self); /* proto */
1742 static int __pyx_pf_8PyClical_9index_set_2__cinit__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self, PyObject *__pyx_v_other); /* proto */
1743 static void __pyx_pf_8PyClical_9index_set_4__dealloc__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self); /* proto */
1744 static PyObject *__pyx_pf_8PyClical_9index_set_6__richcmp__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs, int __pyx_v_op); /* proto */
1745 static int __pyx_pf_8PyClical_9index_set_8__setitem__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self, PyObject *__pyx_v_idx, PyObject *__pyx_v_val); /* proto */
1746 static PyObject *__pyx_pf_8PyClical_9index_set_10__getitem__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self, PyObject *__pyx_v_idx); /* proto */
1747 static int __pyx_pf_8PyClical_9index_set_12__contains__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self, PyObject *__pyx_v_idx); /* proto */
1748 static PyObject *__pyx_pf_8PyClical_9index_set_14__iter__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self); /* proto */
1749 static PyObject *__pyx_pf_8PyClical_9index_set_17__invert__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self); /* proto */
1750 static PyObject *__pyx_pf_8PyClical_9index_set_19__xor__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs); /* proto */
1751 static PyObject *__pyx_pf_8PyClical_9index_set_21__ixor__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self, PyObject *__pyx_v_rhs); /* proto */
1752 static PyObject *__pyx_pf_8PyClical_9index_set_23__and__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs); /* proto */
1753 static PyObject *__pyx_pf_8PyClical_9index_set_25__iand__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self, PyObject *__pyx_v_rhs); /* proto */
1754 static PyObject *__pyx_pf_8PyClical_9index_set_27__or__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs); /* proto */
1755 static PyObject *__pyx_pf_8PyClical_9index_set_29__ior__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self, PyObject *__pyx_v_rhs); /* proto */
1756 static PyObject *__pyx_pf_8PyClical_9index_set_31count(struct __pyx_obj_8PyClical_index_set *__pyx_v_self); /* proto */
1757 static PyObject *__pyx_pf_8PyClical_9index_set_33count_neg(struct __pyx_obj_8PyClical_index_set *__pyx_v_self); /* proto */
1758 static PyObject *__pyx_pf_8PyClical_9index_set_35count_pos(struct __pyx_obj_8PyClical_index_set *__pyx_v_self); /* proto */
1759 static PyObject *__pyx_pf_8PyClical_9index_set_37min(struct __pyx_obj_8PyClical_index_set *__pyx_v_self); /* proto */
1760 static PyObject *__pyx_pf_8PyClical_9index_set_39max(struct __pyx_obj_8PyClical_index_set *__pyx_v_self); /* proto */
1761 static PyObject *__pyx_pf_8PyClical_9index_set_41hash_fn(struct __pyx_obj_8PyClical_index_set *__pyx_v_self); /* proto */
1762 static PyObject *__pyx_pf_8PyClical_9index_set_43sign_of_mult(struct __pyx_obj_8PyClical_index_set *__pyx_v_self, PyObject *__pyx_v_rhs); /* proto */
1763 static PyObject *__pyx_pf_8PyClical_9index_set_45sign_of_square(struct __pyx_obj_8PyClical_index_set *__pyx_v_self); /* proto */
1764 static PyObject *__pyx_pf_8PyClical_9index_set_47__repr__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self); /* proto */
1765 static PyObject *__pyx_pf_8PyClical_9index_set_49__str__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self); /* proto */
1766 static PyObject *__pyx_pf_8PyClical_index_set_hidden_doctests(CYTHON_UNUSED PyObject *__pyx_self); /* proto */
1767 static PyObject *__pyx_pf_8PyClical_2compare(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs); /* proto */
1768 static PyObject *__pyx_pf_8PyClical_4min_neg(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1769 static PyObject *__pyx_pf_8PyClical_6max_pos(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1770 static PyObject *__pyx_pf_8PyClical_8clifford_copy(struct __pyx_obj_8PyClical_clifford *__pyx_v_self); /* proto */
1771 static int __pyx_pf_8PyClical_8clifford_2__cinit__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_other, PyObject *__pyx_v_ixt); /* proto */
1772 static void __pyx_pf_8PyClical_8clifford_4__dealloc__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self); /* proto */
1773 static int __pyx_pf_8PyClical_8clifford_6__contains__(CYTHON_UNUSED struct __pyx_obj_8PyClical_clifford *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_x); /* proto */
1774 static PyObject *__pyx_pf_8PyClical_8clifford_8__iter__(CYTHON_UNUSED struct __pyx_obj_8PyClical_clifford *__pyx_v_self); /* proto */
1775 static PyObject *__pyx_pf_8PyClical_8clifford_10reframe(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_ixt); /* proto */
1776 static PyObject *__pyx_pf_8PyClical_8clifford_12__richcmp__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs, int __pyx_v_op); /* proto */
1777 static PyObject *__pyx_pf_8PyClical_8clifford_14__getitem__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_ixt); /* proto */
1778 static PyObject *__pyx_pf_8PyClical_8clifford_16__neg__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self); /* proto */
1779 static PyObject *__pyx_pf_8PyClical_8clifford_18__pos__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self); /* proto */
1780 static PyObject *__pyx_pf_8PyClical_8clifford_20__add__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs); /* proto */
1781 static PyObject *__pyx_pf_8PyClical_8clifford_22__iadd__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_rhs); /* proto */
1782 static PyObject *__pyx_pf_8PyClical_8clifford_24__sub__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs); /* proto */
1783 static PyObject *__pyx_pf_8PyClical_8clifford_26__isub__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_rhs); /* proto */
1784 static PyObject *__pyx_pf_8PyClical_8clifford_28__mul__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs); /* proto */
1785 static PyObject *__pyx_pf_8PyClical_8clifford_30__imul__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_rhs); /* proto */
1786 static PyObject *__pyx_pf_8PyClical_8clifford_32__mod__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs); /* proto */
1787 static PyObject *__pyx_pf_8PyClical_8clifford_34__imod__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_rhs); /* proto */
1788 static PyObject *__pyx_pf_8PyClical_8clifford_36__and__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs); /* proto */
1789 static PyObject *__pyx_pf_8PyClical_8clifford_38__iand__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_rhs); /* proto */
1790 static PyObject *__pyx_pf_8PyClical_8clifford_40__xor__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs); /* proto */
1791 static PyObject *__pyx_pf_8PyClical_8clifford_42__ixor__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_rhs); /* proto */
1792 #if PY_MAJOR_VERSION < 3 || CYTHON_COMPILING_IN_PYPY
1793 static PyObject *__pyx_pf_8PyClical_8clifford_44__div__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs); /* proto */
1794 #endif
1795 #if PY_MAJOR_VERSION < 3 || CYTHON_COMPILING_IN_PYPY
1796 static PyObject *__pyx_pf_8PyClical_8clifford_46__idiv__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_rhs); /* proto */
1797 #endif
1798 static PyObject *__pyx_pf_8PyClical_8clifford_48inv(struct __pyx_obj_8PyClical_clifford *__pyx_v_self); /* proto */
1799 static PyObject *__pyx_pf_8PyClical_8clifford_50__or__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs); /* proto */
1800 static PyObject *__pyx_pf_8PyClical_8clifford_52__ior__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_rhs); /* proto */
1801 static PyObject *__pyx_pf_8PyClical_8clifford_54__pow__(PyObject *__pyx_v_self, PyObject *__pyx_v_m, CYTHON_UNUSED PyObject *__pyx_v_dummy); /* proto */
1802 static PyObject *__pyx_pf_8PyClical_8clifford_56pow(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_m); /* proto */
1803 static PyObject *__pyx_pf_8PyClical_8clifford_58outer_pow(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_m); /* proto */
1804 static PyObject *__pyx_pf_8PyClical_8clifford_60__call__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_grade); /* proto */
1805 static PyObject *__pyx_pf_8PyClical_8clifford_62scalar(struct __pyx_obj_8PyClical_clifford *__pyx_v_self); /* proto */
1806 static PyObject *__pyx_pf_8PyClical_8clifford_64pure(struct __pyx_obj_8PyClical_clifford *__pyx_v_self); /* proto */
1807 static PyObject *__pyx_pf_8PyClical_8clifford_66even(struct __pyx_obj_8PyClical_clifford *__pyx_v_self); /* proto */
1808 static PyObject *__pyx_pf_8PyClical_8clifford_68odd(struct __pyx_obj_8PyClical_clifford *__pyx_v_self); /* proto */
1809 static PyObject *__pyx_pf_8PyClical_8clifford_70vector_part(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_frm); /* proto */
1810 static PyObject *__pyx_pf_8PyClical_8clifford_72involute(struct __pyx_obj_8PyClical_clifford *__pyx_v_self); /* proto */
1811 static PyObject *__pyx_pf_8PyClical_8clifford_74reverse(struct __pyx_obj_8PyClical_clifford *__pyx_v_self); /* proto */
1812 static PyObject *__pyx_pf_8PyClical_8clifford_76conj(struct __pyx_obj_8PyClical_clifford *__pyx_v_self); /* proto */
1813 static PyObject *__pyx_pf_8PyClical_8clifford_78quad(struct __pyx_obj_8PyClical_clifford *__pyx_v_self); /* proto */
1814 static PyObject *__pyx_pf_8PyClical_8clifford_80norm(struct __pyx_obj_8PyClical_clifford *__pyx_v_self); /* proto */
1815 static PyObject *__pyx_pf_8PyClical_8clifford_82abs(struct __pyx_obj_8PyClical_clifford *__pyx_v_self); /* proto */
1816 static PyObject *__pyx_pf_8PyClical_8clifford_84max_abs(struct __pyx_obj_8PyClical_clifford *__pyx_v_self); /* proto */
1817 static PyObject *__pyx_pf_8PyClical_8clifford_86truncated(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_limit); /* proto */
1818 static PyObject *__pyx_pf_8PyClical_8clifford_88isnan(struct __pyx_obj_8PyClical_clifford *__pyx_v_self); /* proto */
1819 static PyObject *__pyx_pf_8PyClical_8clifford_90frame(struct __pyx_obj_8PyClical_clifford *__pyx_v_self); /* proto */
1820 static PyObject *__pyx_pf_8PyClical_8clifford_92__repr__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self); /* proto */
1821 static PyObject *__pyx_pf_8PyClical_8clifford_94__str__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self); /* proto */
1822 static PyObject *__pyx_pf_8PyClical_8clifford_hidden_doctests(CYTHON_UNUSED PyObject *__pyx_self); /* proto */
1823 static PyObject *__pyx_pf_8PyClical_10inv(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1824 static PyObject *__pyx_pf_8PyClical_12scalar(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1825 static PyObject *__pyx_pf_8PyClical_14real(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1826 static PyObject *__pyx_pf_8PyClical_16imag(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1827 static PyObject *__pyx_pf_8PyClical_18pure(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1828 static PyObject *__pyx_pf_8PyClical_20even(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1829 static PyObject *__pyx_pf_8PyClical_22odd(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1830 static PyObject *__pyx_pf_8PyClical_24involute(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1831 static PyObject *__pyx_pf_8PyClical_26reverse(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1832 static PyObject *__pyx_pf_8PyClical_28conj(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1833 static PyObject *__pyx_pf_8PyClical_30quad(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1834 static PyObject *__pyx_pf_8PyClical_32norm(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1835 static PyObject *__pyx_pf_8PyClical_34abs(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1836 static PyObject *__pyx_pf_8PyClical_36max_abs(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1837 static PyObject *__pyx_pf_8PyClical_38pow(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_m); /* proto */
1838 static PyObject *__pyx_pf_8PyClical_40outer_pow(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_m); /* proto */
1839 static PyObject *__pyx_pf_8PyClical_42complexifier(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1840 static PyObject *__pyx_pf_8PyClical_44sqrt(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_i); /* proto */
1841 static PyObject *__pyx_pf_8PyClical_46exp(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1842 static PyObject *__pyx_pf_8PyClical_48log(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_i); /* proto */
1843 static PyObject *__pyx_pf_8PyClical_50cos(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_i); /* proto */
1844 static PyObject *__pyx_pf_8PyClical_52acos(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_i); /* proto */
1845 static PyObject *__pyx_pf_8PyClical_54cosh(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1846 static PyObject *__pyx_pf_8PyClical_56acosh(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_i); /* proto */
1847 static PyObject *__pyx_pf_8PyClical_58sin(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_i); /* proto */
1848 static PyObject *__pyx_pf_8PyClical_60asin(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_i); /* proto */
1849 static PyObject *__pyx_pf_8PyClical_62sinh(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1850 static PyObject *__pyx_pf_8PyClical_64asinh(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_i); /* proto */
1851 static PyObject *__pyx_pf_8PyClical_66tan(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_i); /* proto */
1852 static PyObject *__pyx_pf_8PyClical_68atan(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_i); /* proto */
1853 static PyObject *__pyx_pf_8PyClical_70tanh(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1854 static PyObject *__pyx_pf_8PyClical_72atanh(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_i); /* proto */
1855 static PyObject *__pyx_pf_8PyClical_74random_clifford(CYTHON_UNUSED PyObject *__pyx_self, struct __pyx_obj_8PyClical_index_set *__pyx_v_ixt, PyObject *__pyx_v_fill); /* proto */
1856 static PyObject *__pyx_pf_8PyClical_76cga3(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1857 static PyObject *__pyx_pf_8PyClical_78cga3std(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1858 static PyObject *__pyx_pf_8PyClical_80agc3(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1859 static PyObject *__pyx_pf_8PyClical_82e(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj); /* proto */
1860 static PyObject *__pyx_pf_8PyClical_84istpq(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_p, PyObject *__pyx_v_q); /* proto */
1861 static PyObject *__pyx_pf_8PyClical_86_test(CYTHON_UNUSED PyObject *__pyx_self); /* proto */
1862 static PyObject *__pyx_tp_new_8PyClical_index_set(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/
1863 static PyObject *__pyx_tp_new_8PyClical_clifford(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/
1864 static PyObject *__pyx_tp_new_8PyClical___pyx_scope_struct____iter__(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/
1865 static PyObject *__pyx_float_0_0;
1866 static PyObject *__pyx_float_1_0;
1867 static PyObject *__pyx_float_2_0;
1868 static PyObject *__pyx_float_8_0;
1869 static PyObject *__pyx_int_0;
1870 static PyObject *__pyx_int_1;
1871 static PyObject *__pyx_int_4;
1872 static PyObject *__pyx_int_neg_1;
1873 static PyObject *__pyx_tuple__8;
1874 static PyObject *__pyx_tuple__9;
1875 static PyObject *__pyx_tuple__12;
1876 static PyObject *__pyx_tuple__13;
1877 static PyObject *__pyx_tuple__15;
1878 static PyObject *__pyx_tuple__17;
1879 static PyObject *__pyx_tuple__18;
1880 static PyObject *__pyx_tuple__19;
1881 static PyObject *__pyx_tuple__20;
1882 static PyObject *__pyx_tuple__21;
1883 static PyObject *__pyx_codeobj__10;
1884 static PyObject *__pyx_codeobj__11;
1885 static PyObject *__pyx_codeobj__14;
1886 static PyObject *__pyx_codeobj__16;
1887 static PyObject *__pyx_codeobj__22;
1888 
1889 /* "PyClical.pyx":39
1890  * cdef class index_set
1891  *
1892  * cdef inline IndexSet toIndexSet(obj): # <<<<<<<<<<<<<<
1893  * """
1894  * Return the C++ IndexSet instance wrapped by index_set(obj).
1895  */
1896 
1897 static CYTHON_INLINE IndexSet __pyx_f_8PyClical_toIndexSet(PyObject *__pyx_v_obj) {
1898  IndexSet __pyx_r;
1899  __Pyx_RefNannyDeclarations
1900  PyObject *__pyx_t_1 = NULL;
1901  PyObject *__pyx_t_2 = NULL;
1902  int __pyx_lineno = 0;
1903  const char *__pyx_filename = NULL;
1904  int __pyx_clineno = 0;
1905  __Pyx_RefNannySetupContext("toIndexSet", 0);
1906 
1907  /* "PyClical.pyx":43
1908  * Return the C++ IndexSet instance wrapped by index_set(obj).
1909  * """
1910  * return index_set(obj).instance[0] # <<<<<<<<<<<<<<
1911  *
1912  * cdef class index_set:
1913  */
1914  __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 43; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
1915  __Pyx_GOTREF(__pyx_t_1);
1916  __Pyx_INCREF(__pyx_v_obj);
1917  __Pyx_GIVEREF(__pyx_v_obj);
1918  PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_obj);
1919  __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_index_set), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 43; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
1920  __Pyx_GOTREF(__pyx_t_2);
1921  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
1922  __pyx_r = (((struct __pyx_obj_8PyClical_index_set *)__pyx_t_2)->instance[0]);
1923  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
1924  goto __pyx_L0;
1925 
1926  /* "PyClical.pyx":39
1927  * cdef class index_set
1928  *
1929  * cdef inline IndexSet toIndexSet(obj): # <<<<<<<<<<<<<<
1930  * """
1931  * Return the C++ IndexSet instance wrapped by index_set(obj).
1932  */
1933 
1934  /* function exit code */
1935  __pyx_L1_error:;
1936  __Pyx_XDECREF(__pyx_t_1);
1937  __Pyx_XDECREF(__pyx_t_2);
1938  __Pyx_WriteUnraisable("PyClical.toIndexSet", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0);
1939  __pyx_L0:;
1940  __Pyx_RefNannyFinishContext();
1941  return __pyx_r;
1942 }
1943 
1944 /* "PyClical.pyx":51
1945  * cdef IndexSet *instance # Wrapped instance of C++ class IndexSet.
1946  *
1947  * cdef inline wrap(index_set self, IndexSet other): # <<<<<<<<<<<<<<
1948  * """
1949  * Wrap an instance of the C++ class IndexSet.
1950  */
1951 
1952 static CYTHON_INLINE PyObject *__pyx_f_8PyClical_9index_set_wrap(struct __pyx_obj_8PyClical_index_set *__pyx_v_self, IndexSet __pyx_v_other) {
1953  PyObject *__pyx_r = NULL;
1954  __Pyx_RefNannyDeclarations
1955  __Pyx_RefNannySetupContext("wrap", 0);
1956 
1957  /* "PyClical.pyx":55
1958  * Wrap an instance of the C++ class IndexSet.
1959  * """
1960  * self.instance[0] = other # <<<<<<<<<<<<<<
1961  * return self
1962  *
1963  */
1964  (__pyx_v_self->instance[0]) = __pyx_v_other;
1965 
1966  /* "PyClical.pyx":56
1967  * """
1968  * self.instance[0] = other
1969  * return self # <<<<<<<<<<<<<<
1970  *
1971  * cdef inline IndexSet unwrap(index_set self):
1972  */
1973  __Pyx_XDECREF(__pyx_r);
1974  __Pyx_INCREF(((PyObject *)__pyx_v_self));
1975  __pyx_r = ((PyObject *)__pyx_v_self);
1976  goto __pyx_L0;
1977 
1978  /* "PyClical.pyx":51
1979  * cdef IndexSet *instance # Wrapped instance of C++ class IndexSet.
1980  *
1981  * cdef inline wrap(index_set self, IndexSet other): # <<<<<<<<<<<<<<
1982  * """
1983  * Wrap an instance of the C++ class IndexSet.
1984  */
1985 
1986  /* function exit code */
1987  __pyx_L0:;
1988  __Pyx_XGIVEREF(__pyx_r);
1989  __Pyx_RefNannyFinishContext();
1990  return __pyx_r;
1991 }
1992 
1993 /* "PyClical.pyx":58
1994  * return self
1995  *
1996  * cdef inline IndexSet unwrap(index_set self): # <<<<<<<<<<<<<<
1997  * """
1998  * Return the wrapped C++ IndexSet instance.
1999  */
2000 
2001 static CYTHON_INLINE IndexSet __pyx_f_8PyClical_9index_set_unwrap(struct __pyx_obj_8PyClical_index_set *__pyx_v_self) {
2002  IndexSet __pyx_r;
2003  __Pyx_RefNannyDeclarations
2004  __Pyx_RefNannySetupContext("unwrap", 0);
2005 
2006  /* "PyClical.pyx":62
2007  * Return the wrapped C++ IndexSet instance.
2008  * """
2009  * return self.instance[0] # <<<<<<<<<<<<<<
2010  *
2011  * cpdef copy(index_set self):
2012  */
2013  __pyx_r = (__pyx_v_self->instance[0]);
2014  goto __pyx_L0;
2015 
2016  /* "PyClical.pyx":58
2017  * return self
2018  *
2019  * cdef inline IndexSet unwrap(index_set self): # <<<<<<<<<<<<<<
2020  * """
2021  * Return the wrapped C++ IndexSet instance.
2022  */
2023 
2024  /* function exit code */
2025  __pyx_L0:;
2026  __Pyx_RefNannyFinishContext();
2027  return __pyx_r;
2028 }
2029 
2030 /* "PyClical.pyx":64
2031  * return self.instance[0]
2032  *
2033  * cpdef copy(index_set self): # <<<<<<<<<<<<<<
2034  * """
2035  * Copy this index_set object.
2036  */
2037 
2038 static PyObject *__pyx_pw_8PyClical_9index_set_1copy(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
2039 static PyObject *__pyx_f_8PyClical_9index_set_copy(struct __pyx_obj_8PyClical_index_set *__pyx_v_self, int __pyx_skip_dispatch) {
2040  PyObject *__pyx_r = NULL;
2041  __Pyx_RefNannyDeclarations
2042  PyObject *__pyx_t_1 = NULL;
2043  PyObject *__pyx_t_2 = NULL;
2044  PyObject *__pyx_t_3 = NULL;
2045  PyObject *__pyx_t_4 = NULL;
2046  int __pyx_lineno = 0;
2047  const char *__pyx_filename = NULL;
2048  int __pyx_clineno = 0;
2049  __Pyx_RefNannySetupContext("copy", 0);
2050  /* Check if called by wrapper */
2051  if (unlikely(__pyx_skip_dispatch)) ;
2052  /* Check if overridden in Python */
2053  else if (unlikely(Py_TYPE(((PyObject *)__pyx_v_self))->tp_dictoffset != 0)) {
2054  __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_copy); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 64; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
2055  __Pyx_GOTREF(__pyx_t_1);
2056  if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)__pyx_pw_8PyClical_9index_set_1copy)) {
2057  __Pyx_XDECREF(__pyx_r);
2058  __Pyx_INCREF(__pyx_t_1);
2059  __pyx_t_3 = __pyx_t_1; __pyx_t_4 = NULL;
2060  if (CYTHON_COMPILING_IN_CPYTHON && unlikely(PyMethod_Check(__pyx_t_3))) {
2061  __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
2062  if (likely(__pyx_t_4)) {
2063  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
2064  __Pyx_INCREF(__pyx_t_4);
2065  __Pyx_INCREF(function);
2066  __Pyx_DECREF_SET(__pyx_t_3, function);
2067  }
2068  }
2069  if (__pyx_t_4) {
2070  __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 64; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
2071  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
2072  } else {
2073  __pyx_t_2 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 64; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
2074  }
2075  __Pyx_GOTREF(__pyx_t_2);
2076  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
2077  __pyx_r = __pyx_t_2;
2078  __pyx_t_2 = 0;
2079  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
2080  goto __pyx_L0;
2081  }
2082  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
2083  }
2084 
2085  /* "PyClical.pyx":71
2086  * {1}
2087  * """
2088  * return index_set(self) # <<<<<<<<<<<<<<
2089  *
2090  * def __cinit__(self, other = 0):
2091  */
2092  __Pyx_XDECREF(__pyx_r);
2093  __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 71; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
2094  __Pyx_GOTREF(__pyx_t_1);
2095  __Pyx_INCREF(((PyObject *)__pyx_v_self));
2096  __Pyx_GIVEREF(((PyObject *)__pyx_v_self));
2097  PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self));
2098  __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_index_set), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 71; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
2099  __Pyx_GOTREF(__pyx_t_2);
2100  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
2101  __pyx_r = __pyx_t_2;
2102  __pyx_t_2 = 0;
2103  goto __pyx_L0;
2104 
2105  /* "PyClical.pyx":64
2106  * return self.instance[0]
2107  *
2108  * cpdef copy(index_set self): # <<<<<<<<<<<<<<
2109  * """
2110  * Copy this index_set object.
2111  */
2112 
2113  /* function exit code */
2114  __pyx_L1_error:;
2115  __Pyx_XDECREF(__pyx_t_1);
2116  __Pyx_XDECREF(__pyx_t_2);
2117  __Pyx_XDECREF(__pyx_t_3);
2118  __Pyx_XDECREF(__pyx_t_4);
2119  __Pyx_AddTraceback("PyClical.index_set.copy", __pyx_clineno, __pyx_lineno, __pyx_filename);
2120  __pyx_r = 0;
2121  __pyx_L0:;
2122  __Pyx_XGIVEREF(__pyx_r);
2123  __Pyx_RefNannyFinishContext();
2124  return __pyx_r;
2125 }
2126 
2127 /* Python wrapper */
2128 static PyObject *__pyx_pw_8PyClical_9index_set_1copy(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
2129 static char __pyx_doc_8PyClical_9index_set_copy[] = "\n Copy this index_set object.\n\n >>> s=index_set(1); t=s.copy(); print t\n {1}\n ";
2130 static PyObject *__pyx_pw_8PyClical_9index_set_1copy(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
2131  PyObject *__pyx_r = 0;
2132  __Pyx_RefNannyDeclarations
2133  __Pyx_RefNannySetupContext("copy (wrapper)", 0);
2134  __pyx_r = __pyx_pf_8PyClical_9index_set_copy(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_self));
2135 
2136  /* function exit code */
2137  __Pyx_RefNannyFinishContext();
2138  return __pyx_r;
2139 }
2140 
2141 static PyObject *__pyx_pf_8PyClical_9index_set_copy(struct __pyx_obj_8PyClical_index_set *__pyx_v_self) {
2142  PyObject *__pyx_r = NULL;
2143  __Pyx_RefNannyDeclarations
2144  PyObject *__pyx_t_1 = NULL;
2145  int __pyx_lineno = 0;
2146  const char *__pyx_filename = NULL;
2147  int __pyx_clineno = 0;
2148  __Pyx_RefNannySetupContext("copy", 0);
2149  __Pyx_XDECREF(__pyx_r);
2150  __pyx_t_1 = __pyx_f_8PyClical_9index_set_copy(__pyx_v_self, 1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 64; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
2151  __Pyx_GOTREF(__pyx_t_1);
2152  __pyx_r = __pyx_t_1;
2153  __pyx_t_1 = 0;
2154  goto __pyx_L0;
2155 
2156  /* function exit code */
2157  __pyx_L1_error:;
2158  __Pyx_XDECREF(__pyx_t_1);
2159  __Pyx_AddTraceback("PyClical.index_set.copy", __pyx_clineno, __pyx_lineno, __pyx_filename);
2160  __pyx_r = NULL;
2161  __pyx_L0:;
2162  __Pyx_XGIVEREF(__pyx_r);
2163  __Pyx_RefNannyFinishContext();
2164  return __pyx_r;
2165 }
2166 
2167 /* "PyClical.pyx":73
2168  * return index_set(self)
2169  *
2170  * def __cinit__(self, other = 0): # <<<<<<<<<<<<<<
2171  * """
2172  * Construct an object of type index_set.
2173  */
2174 
2175 /* Python wrapper */
2176 static int __pyx_pw_8PyClical_9index_set_3__cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
2177 static int __pyx_pw_8PyClical_9index_set_3__cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
2178  PyObject *__pyx_v_other = 0;
2179  int __pyx_lineno = 0;
2180  const char *__pyx_filename = NULL;
2181  int __pyx_clineno = 0;
2182  int __pyx_r;
2183  __Pyx_RefNannyDeclarations
2184  __Pyx_RefNannySetupContext("__cinit__ (wrapper)", 0);
2185  {
2186  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_other,0};
2187  PyObject* values[1] = {0};
2188  values[0] = ((PyObject *)__pyx_int_0);
2189  if (unlikely(__pyx_kwds)) {
2190  Py_ssize_t kw_args;
2191  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
2192  switch (pos_args) {
2193  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
2194  case 0: break;
2195  default: goto __pyx_L5_argtuple_error;
2196  }
2197  kw_args = PyDict_Size(__pyx_kwds);
2198  switch (pos_args) {
2199  case 0:
2200  if (kw_args > 0) {
2201  PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_other);
2202  if (value) { values[0] = value; kw_args--; }
2203  }
2204  }
2205  if (unlikely(kw_args > 0)) {
2206  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 73; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
2207  }
2208  } else {
2209  switch (PyTuple_GET_SIZE(__pyx_args)) {
2210  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
2211  case 0: break;
2212  default: goto __pyx_L5_argtuple_error;
2213  }
2214  }
2215  __pyx_v_other = values[0];
2216  }
2217  goto __pyx_L4_argument_unpacking_done;
2218  __pyx_L5_argtuple_error:;
2219  __Pyx_RaiseArgtupleInvalid("__cinit__", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 73; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
2220  __pyx_L3_error:;
2221  __Pyx_AddTraceback("PyClical.index_set.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
2222  __Pyx_RefNannyFinishContext();
2223  return -1;
2224  __pyx_L4_argument_unpacking_done:;
2225  __pyx_r = __pyx_pf_8PyClical_9index_set_2__cinit__(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_self), __pyx_v_other);
2226 
2227  /* function exit code */
2228  __Pyx_RefNannyFinishContext();
2229  return __pyx_r;
2230 }
2231 
2232 static int __pyx_pf_8PyClical_9index_set_2__cinit__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self, PyObject *__pyx_v_other) {
2233  PyObject *__pyx_v_error_msg_prefix = NULL;
2234  PyObject *__pyx_v_idx = NULL;
2235  int __pyx_r;
2236  __Pyx_RefNannyDeclarations
2237  int __pyx_t_1;
2238  int __pyx_t_2;
2239  IndexSet *__pyx_t_3;
2240  PyObject *__pyx_t_4 = NULL;
2241  PyObject *__pyx_t_5 = NULL;
2242  int __pyx_t_6;
2243  int __pyx_t_7;
2244  PyObject *__pyx_t_8 = NULL;
2245  PyObject *__pyx_t_9 = NULL;
2246  PyObject *__pyx_t_10 = NULL;
2247  Py_ssize_t __pyx_t_11;
2248  PyObject *(*__pyx_t_12)(PyObject *);
2249  PyObject *__pyx_t_13 = NULL;
2250  PyObject *__pyx_t_14 = NULL;
2251  PyObject *__pyx_t_15 = NULL;
2252  PyObject *__pyx_t_16 = NULL;
2253  char *__pyx_t_17;
2254  int __pyx_lineno = 0;
2255  const char *__pyx_filename = NULL;
2256  int __pyx_clineno = 0;
2257  __Pyx_RefNannySetupContext("__cinit__", 0);
2258 
2259  /* "PyClical.pyx":92
2260  * {}
2261  * """
2262  * error_msg_prefix = "Cannot initialize index_set object from" # <<<<<<<<<<<<<<
2263  * if isinstance(other, index_set):
2264  * self.instance = new IndexSet((<index_set>other).unwrap())
2265  */
2266  __Pyx_INCREF(__pyx_kp_s_Cannot_initialize_index_set_obje);
2267  __pyx_v_error_msg_prefix = __pyx_kp_s_Cannot_initialize_index_set_obje;
2268 
2269  /* "PyClical.pyx":93
2270  * """
2271  * error_msg_prefix = "Cannot initialize index_set object from"
2272  * if isinstance(other, index_set): # <<<<<<<<<<<<<<
2273  * self.instance = new IndexSet((<index_set>other).unwrap())
2274  * elif isinstance(other, numbers.Integral):
2275  */
2276  __pyx_t_1 = __Pyx_TypeCheck(__pyx_v_other, __pyx_ptype_8PyClical_index_set);
2277  __pyx_t_2 = (__pyx_t_1 != 0);
2278  if (__pyx_t_2) {
2279 
2280  /* "PyClical.pyx":94
2281  * error_msg_prefix = "Cannot initialize index_set object from"
2282  * if isinstance(other, index_set):
2283  * self.instance = new IndexSet((<index_set>other).unwrap()) # <<<<<<<<<<<<<<
2284  * elif isinstance(other, numbers.Integral):
2285  * self.instance = new IndexSet(<int>other)
2286  */
2287  try {
2288  __pyx_t_3 = new IndexSet(__pyx_f_8PyClical_9index_set_unwrap(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_other)));
2289  } catch(...) {
2290  __Pyx_CppExn2PyErr();
2291  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 94; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
2292  }
2293  __pyx_v_self->instance = __pyx_t_3;
2294 
2295  /* "PyClical.pyx":93
2296  * """
2297  * error_msg_prefix = "Cannot initialize index_set object from"
2298  * if isinstance(other, index_set): # <<<<<<<<<<<<<<
2299  * self.instance = new IndexSet((<index_set>other).unwrap())
2300  * elif isinstance(other, numbers.Integral):
2301  */
2302  goto __pyx_L3;
2303  }
2304 
2305  /* "PyClical.pyx":95
2306  * if isinstance(other, index_set):
2307  * self.instance = new IndexSet((<index_set>other).unwrap())
2308  * elif isinstance(other, numbers.Integral): # <<<<<<<<<<<<<<
2309  * self.instance = new IndexSet(<int>other)
2310  * elif isinstance(other, (set, frozenset)):
2311  */
2312  __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_numbers); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 95; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
2313  __Pyx_GOTREF(__pyx_t_4);
2314  __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_Integral); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 95; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
2315  __Pyx_GOTREF(__pyx_t_5);
2316  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
2317  __pyx_t_2 = PyObject_IsInstance(__pyx_v_other, __pyx_t_5); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 95; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
2318  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
2319  __pyx_t_1 = (__pyx_t_2 != 0);
2320  if (__pyx_t_1) {
2321 
2322  /* "PyClical.pyx":96
2323  * self.instance = new IndexSet((<index_set>other).unwrap())
2324  * elif isinstance(other, numbers.Integral):
2325  * self.instance = new IndexSet(<int>other) # <<<<<<<<<<<<<<
2326  * elif isinstance(other, (set, frozenset)):
2327  * try:
2328  */
2329  __pyx_t_6 = __Pyx_PyInt_As_int(__pyx_v_other); if (unlikely((__pyx_t_6 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 96; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
2330  try {
2331  __pyx_t_3 = new IndexSet(((int)__pyx_t_6));
2332  } catch(...) {
2333  __Pyx_CppExn2PyErr();
2334  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 96; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
2335  }
2336  __pyx_v_self->instance = __pyx_t_3;
2337 
2338  /* "PyClical.pyx":95
2339  * if isinstance(other, index_set):
2340  * self.instance = new IndexSet((<index_set>other).unwrap())
2341  * elif isinstance(other, numbers.Integral): # <<<<<<<<<<<<<<
2342  * self.instance = new IndexSet(<int>other)
2343  * elif isinstance(other, (set, frozenset)):
2344  */
2345  goto __pyx_L3;
2346  }
2347 
2348  /* "PyClical.pyx":97
2349  * elif isinstance(other, numbers.Integral):
2350  * self.instance = new IndexSet(<int>other)
2351  * elif isinstance(other, (set, frozenset)): # <<<<<<<<<<<<<<
2352  * try:
2353  * self.instance = new IndexSet()
2354  */
2355  __pyx_t_2 = PySet_Check(__pyx_v_other);
2356  __pyx_t_7 = (__pyx_t_2 != 0);
2357  if (!__pyx_t_7) {
2358  } else {
2359  __pyx_t_1 = __pyx_t_7;
2360  goto __pyx_L4_bool_binop_done;
2361  }
2362  __pyx_t_7 = PyFrozenSet_Check(__pyx_v_other);
2363  __pyx_t_2 = (__pyx_t_7 != 0);
2364  __pyx_t_1 = __pyx_t_2;
2365  __pyx_L4_bool_binop_done:;
2366  __pyx_t_2 = (__pyx_t_1 != 0);
2367  if (__pyx_t_2) {
2368 
2369  /* "PyClical.pyx":98
2370  * self.instance = new IndexSet(<int>other)
2371  * elif isinstance(other, (set, frozenset)):
2372  * try: # <<<<<<<<<<<<<<
2373  * self.instance = new IndexSet()
2374  * for idx in other:
2375  */
2376  {
2377  __Pyx_ExceptionSave(&__pyx_t_8, &__pyx_t_9, &__pyx_t_10);
2378  __Pyx_XGOTREF(__pyx_t_8);
2379  __Pyx_XGOTREF(__pyx_t_9);
2380  __Pyx_XGOTREF(__pyx_t_10);
2381  /*try:*/ {
2382 
2383  /* "PyClical.pyx":99
2384  * elif isinstance(other, (set, frozenset)):
2385  * try:
2386  * self.instance = new IndexSet() # <<<<<<<<<<<<<<
2387  * for idx in other:
2388  * self[idx] = True
2389  */
2390  __pyx_v_self->instance = new IndexSet();
2391 
2392  /* "PyClical.pyx":100
2393  * try:
2394  * self.instance = new IndexSet()
2395  * for idx in other: # <<<<<<<<<<<<<<
2396  * self[idx] = True
2397  * except IndexError:
2398  */
2399  if (likely(PyList_CheckExact(__pyx_v_other)) || PyTuple_CheckExact(__pyx_v_other)) {
2400  __pyx_t_5 = __pyx_v_other; __Pyx_INCREF(__pyx_t_5); __pyx_t_11 = 0;
2401  __pyx_t_12 = NULL;
2402  } else {
2403  __pyx_t_11 = -1; __pyx_t_5 = PyObject_GetIter(__pyx_v_other); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 100; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
2404  __Pyx_GOTREF(__pyx_t_5);
2405  __pyx_t_12 = Py_TYPE(__pyx_t_5)->tp_iternext; if (unlikely(!__pyx_t_12)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 100; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
2406  }
2407  for (;;) {
2408  if (likely(!__pyx_t_12)) {
2409  if (likely(PyList_CheckExact(__pyx_t_5))) {
2410  if (__pyx_t_11 >= PyList_GET_SIZE(__pyx_t_5)) break;
2411  #if CYTHON_COMPILING_IN_CPYTHON
2412  __pyx_t_4 = PyList_GET_ITEM(__pyx_t_5, __pyx_t_11); __Pyx_INCREF(__pyx_t_4); __pyx_t_11++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 100; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
2413  #else
2414  __pyx_t_4 = PySequence_ITEM(__pyx_t_5, __pyx_t_11); __pyx_t_11++; if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 100; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
2415  __Pyx_GOTREF(__pyx_t_4);
2416  #endif
2417  } else {
2418  if (__pyx_t_11 >= PyTuple_GET_SIZE(__pyx_t_5)) break;
2419  #if CYTHON_COMPILING_IN_CPYTHON
2420  __pyx_t_4 = PyTuple_GET_ITEM(__pyx_t_5, __pyx_t_11); __Pyx_INCREF(__pyx_t_4); __pyx_t_11++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 100; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
2421  #else
2422  __pyx_t_4 = PySequence_ITEM(__pyx_t_5, __pyx_t_11); __pyx_t_11++; if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 100; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
2423  __Pyx_GOTREF(__pyx_t_4);
2424  #endif
2425  }
2426  } else {
2427  __pyx_t_4 = __pyx_t_12(__pyx_t_5);
2428  if (unlikely(!__pyx_t_4)) {
2429  PyObject* exc_type = PyErr_Occurred();
2430  if (exc_type) {
2431  if (likely(exc_type == PyExc_StopIteration || PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
2432  else {__pyx_filename = __pyx_f[0]; __pyx_lineno = 100; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
2433  }
2434  break;
2435  }
2436  __Pyx_GOTREF(__pyx_t_4);
2437  }
2438  __Pyx_XDECREF_SET(__pyx_v_idx, __pyx_t_4);
2439  __pyx_t_4 = 0;
2440 
2441  /* "PyClical.pyx":101
2442  * self.instance = new IndexSet()
2443  * for idx in other:
2444  * self[idx] = True # <<<<<<<<<<<<<<
2445  * except IndexError:
2446  * raise IndexError(error_msg_prefix + " invalid " + repr(other) + ".")
2447  */
2448  if (unlikely(PyObject_SetItem(((PyObject *)__pyx_v_self), __pyx_v_idx, Py_True) < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 101; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
2449 
2450  /* "PyClical.pyx":100
2451  * try:
2452  * self.instance = new IndexSet()
2453  * for idx in other: # <<<<<<<<<<<<<<
2454  * self[idx] = True
2455  * except IndexError:
2456  */
2457  }
2458  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
2459 
2460  /* "PyClical.pyx":98
2461  * self.instance = new IndexSet(<int>other)
2462  * elif isinstance(other, (set, frozenset)):
2463  * try: # <<<<<<<<<<<<<<
2464  * self.instance = new IndexSet()
2465  * for idx in other:
2466  */
2467  }
2468  __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
2469  __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
2470  __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0;
2471  goto __pyx_L13_try_end;
2472  __pyx_L6_error:;
2473  __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
2474  __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
2475 
2476  /* "PyClical.pyx":102
2477  * for idx in other:
2478  * self[idx] = True
2479  * except IndexError: # <<<<<<<<<<<<<<
2480  * raise IndexError(error_msg_prefix + " invalid " + repr(other) + ".")
2481  * except (RuntimeError, TypeError):
2482  */
2483  __pyx_t_6 = PyErr_ExceptionMatches(__pyx_builtin_IndexError);
2484  if (__pyx_t_6) {
2485  __Pyx_AddTraceback("PyClical.index_set.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
2486  if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_4, &__pyx_t_13) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 102; __pyx_clineno = __LINE__; goto __pyx_L8_except_error;}
2487  __Pyx_GOTREF(__pyx_t_5);
2488  __Pyx_GOTREF(__pyx_t_4);
2489  __Pyx_GOTREF(__pyx_t_13);
2490 
2491  /* "PyClical.pyx":103
2492  * self[idx] = True
2493  * except IndexError:
2494  * raise IndexError(error_msg_prefix + " invalid " + repr(other) + ".") # <<<<<<<<<<<<<<
2495  * except (RuntimeError, TypeError):
2496  * raise ValueError(error_msg_prefix + " invalid " + repr(other) + ".")
2497  */
2498  __pyx_t_14 = PyNumber_Add(__pyx_v_error_msg_prefix, __pyx_kp_s_invalid); if (unlikely(!__pyx_t_14)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 103; __pyx_clineno = __LINE__; goto __pyx_L8_except_error;}
2499  __Pyx_GOTREF(__pyx_t_14);
2500  __pyx_t_15 = PyObject_Repr(__pyx_v_other); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 103; __pyx_clineno = __LINE__; goto __pyx_L8_except_error;}
2501  __Pyx_GOTREF(__pyx_t_15);
2502  __pyx_t_16 = PyNumber_Add(__pyx_t_14, __pyx_t_15); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 103; __pyx_clineno = __LINE__; goto __pyx_L8_except_error;}
2503  __Pyx_GOTREF(__pyx_t_16);
2504  __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0;
2505  __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0;
2506  __pyx_t_15 = PyNumber_Add(__pyx_t_16, __pyx_kp_s_); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 103; __pyx_clineno = __LINE__; goto __pyx_L8_except_error;}
2507  __Pyx_GOTREF(__pyx_t_15);
2508  __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
2509  __pyx_t_16 = PyTuple_New(1); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 103; __pyx_clineno = __LINE__; goto __pyx_L8_except_error;}
2510  __Pyx_GOTREF(__pyx_t_16);
2511  __Pyx_GIVEREF(__pyx_t_15);
2512  PyTuple_SET_ITEM(__pyx_t_16, 0, __pyx_t_15);
2513  __pyx_t_15 = 0;
2514  __pyx_t_15 = __Pyx_PyObject_Call(__pyx_builtin_IndexError, __pyx_t_16, NULL); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 103; __pyx_clineno = __LINE__; goto __pyx_L8_except_error;}
2515  __Pyx_GOTREF(__pyx_t_15);
2516  __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
2517  __Pyx_Raise(__pyx_t_15, 0, 0, 0);
2518  __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0;
2519  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 103; __pyx_clineno = __LINE__; goto __pyx_L8_except_error;}
2520  }
2521 
2522  /* "PyClical.pyx":104
2523  * except IndexError:
2524  * raise IndexError(error_msg_prefix + " invalid " + repr(other) + ".")
2525  * except (RuntimeError, TypeError): # <<<<<<<<<<<<<<
2526  * raise ValueError(error_msg_prefix + " invalid " + repr(other) + ".")
2527  * elif isinstance(other, str):
2528  */
2529  __pyx_t_6 = PyErr_ExceptionMatches(__pyx_builtin_RuntimeError) || PyErr_ExceptionMatches(__pyx_builtin_TypeError);
2530  if (__pyx_t_6) {
2531  __Pyx_AddTraceback("PyClical.index_set.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
2532  if (__Pyx_GetException(&__pyx_t_13, &__pyx_t_4, &__pyx_t_5) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 104; __pyx_clineno = __LINE__; goto __pyx_L8_except_error;}
2533  __Pyx_GOTREF(__pyx_t_13);
2534  __Pyx_GOTREF(__pyx_t_4);
2535  __Pyx_GOTREF(__pyx_t_5);
2536 
2537  /* "PyClical.pyx":105
2538  * raise IndexError(error_msg_prefix + " invalid " + repr(other) + ".")
2539  * except (RuntimeError, TypeError):
2540  * raise ValueError(error_msg_prefix + " invalid " + repr(other) + ".") # <<<<<<<<<<<<<<
2541  * elif isinstance(other, str):
2542  * try:
2543  */
2544  __pyx_t_15 = PyNumber_Add(__pyx_v_error_msg_prefix, __pyx_kp_s_invalid); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 105; __pyx_clineno = __LINE__; goto __pyx_L8_except_error;}
2545  __Pyx_GOTREF(__pyx_t_15);
2546  __pyx_t_16 = PyObject_Repr(__pyx_v_other); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 105; __pyx_clineno = __LINE__; goto __pyx_L8_except_error;}
2547  __Pyx_GOTREF(__pyx_t_16);
2548  __pyx_t_14 = PyNumber_Add(__pyx_t_15, __pyx_t_16); if (unlikely(!__pyx_t_14)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 105; __pyx_clineno = __LINE__; goto __pyx_L8_except_error;}
2549  __Pyx_GOTREF(__pyx_t_14);
2550  __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0;
2551  __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
2552  __pyx_t_16 = PyNumber_Add(__pyx_t_14, __pyx_kp_s_); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 105; __pyx_clineno = __LINE__; goto __pyx_L8_except_error;}
2553  __Pyx_GOTREF(__pyx_t_16);
2554  __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0;
2555  __pyx_t_14 = PyTuple_New(1); if (unlikely(!__pyx_t_14)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 105; __pyx_clineno = __LINE__; goto __pyx_L8_except_error;}
2556  __Pyx_GOTREF(__pyx_t_14);
2557  __Pyx_GIVEREF(__pyx_t_16);
2558  PyTuple_SET_ITEM(__pyx_t_14, 0, __pyx_t_16);
2559  __pyx_t_16 = 0;
2560  __pyx_t_16 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_t_14, NULL); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 105; __pyx_clineno = __LINE__; goto __pyx_L8_except_error;}
2561  __Pyx_GOTREF(__pyx_t_16);
2562  __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0;
2563  __Pyx_Raise(__pyx_t_16, 0, 0, 0);
2564  __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
2565  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 105; __pyx_clineno = __LINE__; goto __pyx_L8_except_error;}
2566  }
2567  goto __pyx_L8_except_error;
2568  __pyx_L8_except_error:;
2569 
2570  /* "PyClical.pyx":98
2571  * self.instance = new IndexSet(<int>other)
2572  * elif isinstance(other, (set, frozenset)):
2573  * try: # <<<<<<<<<<<<<<
2574  * self.instance = new IndexSet()
2575  * for idx in other:
2576  */
2577  __Pyx_XGIVEREF(__pyx_t_8);
2578  __Pyx_XGIVEREF(__pyx_t_9);
2579  __Pyx_XGIVEREF(__pyx_t_10);
2580  __Pyx_ExceptionReset(__pyx_t_8, __pyx_t_9, __pyx_t_10);
2581  goto __pyx_L1_error;
2582  __pyx_L13_try_end:;
2583  }
2584 
2585  /* "PyClical.pyx":97
2586  * elif isinstance(other, numbers.Integral):
2587  * self.instance = new IndexSet(<int>other)
2588  * elif isinstance(other, (set, frozenset)): # <<<<<<<<<<<<<<
2589  * try:
2590  * self.instance = new IndexSet()
2591  */
2592  goto __pyx_L3;
2593  }
2594 
2595  /* "PyClical.pyx":106
2596  * except (RuntimeError, TypeError):
2597  * raise ValueError(error_msg_prefix + " invalid " + repr(other) + ".")
2598  * elif isinstance(other, str): # <<<<<<<<<<<<<<
2599  * try:
2600  * self.instance = new IndexSet(<char *>other)
2601  */
2602  __pyx_t_2 = PyString_Check(__pyx_v_other);
2603  __pyx_t_1 = (__pyx_t_2 != 0);
2604  if (__pyx_t_1) {
2605 
2606  /* "PyClical.pyx":107
2607  * raise ValueError(error_msg_prefix + " invalid " + repr(other) + ".")
2608  * elif isinstance(other, str):
2609  * try: # <<<<<<<<<<<<<<
2610  * self.instance = new IndexSet(<char *>other)
2611  * except RuntimeError:
2612  */
2613  {
2614  __Pyx_ExceptionSave(&__pyx_t_10, &__pyx_t_9, &__pyx_t_8);
2615  __Pyx_XGOTREF(__pyx_t_10);
2616  __Pyx_XGOTREF(__pyx_t_9);
2617  __Pyx_XGOTREF(__pyx_t_8);
2618  /*try:*/ {
2619 
2620  /* "PyClical.pyx":108
2621  * elif isinstance(other, str):
2622  * try:
2623  * self.instance = new IndexSet(<char *>other) # <<<<<<<<<<<<<<
2624  * except RuntimeError:
2625  * raise ValueError(error_msg_prefix + " invalid string " + repr(other) + ".")
2626  */
2627  __pyx_t_17 = __Pyx_PyObject_AsString(__pyx_v_other); if (unlikely((!__pyx_t_17) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 108; __pyx_clineno = __LINE__; goto __pyx_L20_error;}
2628  try {
2629  __pyx_t_3 = new IndexSet(((char *)__pyx_t_17));
2630  } catch(...) {
2631  __Pyx_CppExn2PyErr();
2632  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 108; __pyx_clineno = __LINE__; goto __pyx_L20_error;}
2633  }
2634  __pyx_v_self->instance = __pyx_t_3;
2635 
2636  /* "PyClical.pyx":107
2637  * raise ValueError(error_msg_prefix + " invalid " + repr(other) + ".")
2638  * elif isinstance(other, str):
2639  * try: # <<<<<<<<<<<<<<
2640  * self.instance = new IndexSet(<char *>other)
2641  * except RuntimeError:
2642  */
2643  }
2644  __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0;
2645  __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
2646  __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
2647  goto __pyx_L27_try_end;
2648  __pyx_L20_error:;
2649  __Pyx_XDECREF(__pyx_t_15); __pyx_t_15 = 0;
2650  __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0;
2651  __Pyx_XDECREF(__pyx_t_16); __pyx_t_16 = 0;
2652  __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0;
2653  __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
2654  __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
2655 
2656  /* "PyClical.pyx":109
2657  * try:
2658  * self.instance = new IndexSet(<char *>other)
2659  * except RuntimeError: # <<<<<<<<<<<<<<
2660  * raise ValueError(error_msg_prefix + " invalid string " + repr(other) + ".")
2661  * else:
2662  */
2663  __pyx_t_6 = PyErr_ExceptionMatches(__pyx_builtin_RuntimeError);
2664  if (__pyx_t_6) {
2665  __Pyx_AddTraceback("PyClical.index_set.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
2666  if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_4, &__pyx_t_13) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 109; __pyx_clineno = __LINE__; goto __pyx_L22_except_error;}
2667  __Pyx_GOTREF(__pyx_t_5);
2668  __Pyx_GOTREF(__pyx_t_4);
2669  __Pyx_GOTREF(__pyx_t_13);
2670 
2671  /* "PyClical.pyx":110
2672  * self.instance = new IndexSet(<char *>other)
2673  * except RuntimeError:
2674  * raise ValueError(error_msg_prefix + " invalid string " + repr(other) + ".") # <<<<<<<<<<<<<<
2675  * else:
2676  * raise TypeError(error_msg_prefix + " " + str(type(other)) + ".")
2677  */
2678  __pyx_t_16 = PyNumber_Add(__pyx_v_error_msg_prefix, __pyx_kp_s_invalid_string); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 110; __pyx_clineno = __LINE__; goto __pyx_L22_except_error;}
2679  __Pyx_GOTREF(__pyx_t_16);
2680  __pyx_t_14 = PyObject_Repr(__pyx_v_other); if (unlikely(!__pyx_t_14)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 110; __pyx_clineno = __LINE__; goto __pyx_L22_except_error;}
2681  __Pyx_GOTREF(__pyx_t_14);
2682  __pyx_t_15 = PyNumber_Add(__pyx_t_16, __pyx_t_14); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 110; __pyx_clineno = __LINE__; goto __pyx_L22_except_error;}
2683  __Pyx_GOTREF(__pyx_t_15);
2684  __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
2685  __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0;
2686  __pyx_t_14 = PyNumber_Add(__pyx_t_15, __pyx_kp_s_); if (unlikely(!__pyx_t_14)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 110; __pyx_clineno = __LINE__; goto __pyx_L22_except_error;}
2687  __Pyx_GOTREF(__pyx_t_14);
2688  __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0;
2689  __pyx_t_15 = PyTuple_New(1); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 110; __pyx_clineno = __LINE__; goto __pyx_L22_except_error;}
2690  __Pyx_GOTREF(__pyx_t_15);
2691  __Pyx_GIVEREF(__pyx_t_14);
2692  PyTuple_SET_ITEM(__pyx_t_15, 0, __pyx_t_14);
2693  __pyx_t_14 = 0;
2694  __pyx_t_14 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_t_15, NULL); if (unlikely(!__pyx_t_14)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 110; __pyx_clineno = __LINE__; goto __pyx_L22_except_error;}
2695  __Pyx_GOTREF(__pyx_t_14);
2696  __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0;
2697  __Pyx_Raise(__pyx_t_14, 0, 0, 0);
2698  __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0;
2699  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 110; __pyx_clineno = __LINE__; goto __pyx_L22_except_error;}
2700  }
2701  goto __pyx_L22_except_error;
2702  __pyx_L22_except_error:;
2703 
2704  /* "PyClical.pyx":107
2705  * raise ValueError(error_msg_prefix + " invalid " + repr(other) + ".")
2706  * elif isinstance(other, str):
2707  * try: # <<<<<<<<<<<<<<
2708  * self.instance = new IndexSet(<char *>other)
2709  * except RuntimeError:
2710  */
2711  __Pyx_XGIVEREF(__pyx_t_10);
2712  __Pyx_XGIVEREF(__pyx_t_9);
2713  __Pyx_XGIVEREF(__pyx_t_8);
2714  __Pyx_ExceptionReset(__pyx_t_10, __pyx_t_9, __pyx_t_8);
2715  goto __pyx_L1_error;
2716  __pyx_L27_try_end:;
2717  }
2718 
2719  /* "PyClical.pyx":106
2720  * except (RuntimeError, TypeError):
2721  * raise ValueError(error_msg_prefix + " invalid " + repr(other) + ".")
2722  * elif isinstance(other, str): # <<<<<<<<<<<<<<
2723  * try:
2724  * self.instance = new IndexSet(<char *>other)
2725  */
2726  goto __pyx_L3;
2727  }
2728 
2729  /* "PyClical.pyx":112
2730  * raise ValueError(error_msg_prefix + " invalid string " + repr(other) + ".")
2731  * else:
2732  * raise TypeError(error_msg_prefix + " " + str(type(other)) + ".") # <<<<<<<<<<<<<<
2733  *
2734  * def __dealloc__(self):
2735  */
2736  /*else*/ {
2737  __pyx_t_13 = PyNumber_Add(__pyx_v_error_msg_prefix, __pyx_kp_s__2); if (unlikely(!__pyx_t_13)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 112; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
2738  __Pyx_GOTREF(__pyx_t_13);
2739  __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 112; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
2740  __Pyx_GOTREF(__pyx_t_4);
2741  __Pyx_INCREF(((PyObject *)Py_TYPE(__pyx_v_other)));
2742  __Pyx_GIVEREF(((PyObject *)Py_TYPE(__pyx_v_other)));
2743  PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)Py_TYPE(__pyx_v_other)));
2744  __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)(&PyString_Type)), __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 112; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
2745  __Pyx_GOTREF(__pyx_t_5);
2746  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
2747  __pyx_t_4 = PyNumber_Add(__pyx_t_13, __pyx_t_5); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 112; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
2748  __Pyx_GOTREF(__pyx_t_4);
2749  __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
2750  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
2751  __pyx_t_5 = PyNumber_Add(__pyx_t_4, __pyx_kp_s_); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 112; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
2752  __Pyx_GOTREF(__pyx_t_5);
2753  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
2754  __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 112; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
2755  __Pyx_GOTREF(__pyx_t_4);
2756  __Pyx_GIVEREF(__pyx_t_5);
2757  PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_5);
2758  __pyx_t_5 = 0;
2759  __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 112; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
2760  __Pyx_GOTREF(__pyx_t_5);
2761  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
2762  __Pyx_Raise(__pyx_t_5, 0, 0, 0);
2763  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
2764  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 112; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
2765  }
2766  __pyx_L3:;
2767 
2768  /* "PyClical.pyx":73
2769  * return index_set(self)
2770  *
2771  * def __cinit__(self, other = 0): # <<<<<<<<<<<<<<
2772  * """
2773  * Construct an object of type index_set.
2774  */
2775 
2776  /* function exit code */
2777  __pyx_r = 0;
2778  goto __pyx_L0;
2779  __pyx_L1_error:;
2780  __Pyx_XDECREF(__pyx_t_4);
2781  __Pyx_XDECREF(__pyx_t_5);
2782  __Pyx_XDECREF(__pyx_t_13);
2783  __Pyx_XDECREF(__pyx_t_14);
2784  __Pyx_XDECREF(__pyx_t_15);
2785  __Pyx_XDECREF(__pyx_t_16);
2786  __Pyx_AddTraceback("PyClical.index_set.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
2787  __pyx_r = -1;
2788  __pyx_L0:;
2789  __Pyx_XDECREF(__pyx_v_error_msg_prefix);
2790  __Pyx_XDECREF(__pyx_v_idx);
2791  __Pyx_RefNannyFinishContext();
2792  return __pyx_r;
2793 }
2794 
2795 /* "PyClical.pyx":114
2796  * raise TypeError(error_msg_prefix + " " + str(type(other)) + ".")
2797  *
2798  * def __dealloc__(self): # <<<<<<<<<<<<<<
2799  * """
2800  * Clean up by deallocating the instance of C++ class IndexSet.
2801  */
2802 
2803 /* Python wrapper */
2804 static void __pyx_pw_8PyClical_9index_set_5__dealloc__(PyObject *__pyx_v_self); /*proto*/
2805 static void __pyx_pw_8PyClical_9index_set_5__dealloc__(PyObject *__pyx_v_self) {
2806  __Pyx_RefNannyDeclarations
2807  __Pyx_RefNannySetupContext("__dealloc__ (wrapper)", 0);
2808  __pyx_pf_8PyClical_9index_set_4__dealloc__(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_self));
2809 
2810  /* function exit code */
2811  __Pyx_RefNannyFinishContext();
2812 }
2813 
2814 static void __pyx_pf_8PyClical_9index_set_4__dealloc__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self) {
2815  __Pyx_RefNannyDeclarations
2816  __Pyx_RefNannySetupContext("__dealloc__", 0);
2817 
2818  /* "PyClical.pyx":118
2819  * Clean up by deallocating the instance of C++ class IndexSet.
2820  * """
2821  * del self.instance # <<<<<<<<<<<<<<
2822  *
2823  * def __richcmp__(lhs, rhs, int op):
2824  */
2825  delete __pyx_v_self->instance;
2826 
2827  /* "PyClical.pyx":114
2828  * raise TypeError(error_msg_prefix + " " + str(type(other)) + ".")
2829  *
2830  * def __dealloc__(self): # <<<<<<<<<<<<<<
2831  * """
2832  * Clean up by deallocating the instance of C++ class IndexSet.
2833  */
2834 
2835  /* function exit code */
2836  __Pyx_RefNannyFinishContext();
2837 }
2838 
2839 /* "PyClical.pyx":120
2840  * del self.instance
2841  *
2842  * def __richcmp__(lhs, rhs, int op): # <<<<<<<<<<<<<<
2843  * """
2844  * Compare two objects of class index_set.
2845  */
2846 
2847 /* Python wrapper */
2848 static PyObject *__pyx_pw_8PyClical_9index_set_7__richcmp__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs, int __pyx_v_op); /*proto*/
2849 static PyObject *__pyx_pw_8PyClical_9index_set_7__richcmp__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs, int __pyx_v_op) {
2850  PyObject *__pyx_r = 0;
2851  __Pyx_RefNannyDeclarations
2852  __Pyx_RefNannySetupContext("__richcmp__ (wrapper)", 0);
2853  __pyx_r = __pyx_pf_8PyClical_9index_set_6__richcmp__(((PyObject *)__pyx_v_lhs), ((PyObject *)__pyx_v_rhs), ((int)__pyx_v_op));
2854 
2855  /* function exit code */
2856  __Pyx_RefNannyFinishContext();
2857  return __pyx_r;
2858 }
2859 
2860 static PyObject *__pyx_pf_8PyClical_9index_set_6__richcmp__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs, int __pyx_v_op) {
2861  PyObject *__pyx_v_eq = NULL;
2862  PyObject *__pyx_v_lt = NULL;
2863  PyObject *__pyx_r = NULL;
2864  __Pyx_RefNannyDeclarations
2865  int __pyx_t_1;
2866  int __pyx_t_2;
2867  int __pyx_t_3;
2868  PyObject *__pyx_t_4 = NULL;
2869  int __pyx_lineno = 0;
2870  const char *__pyx_filename = NULL;
2871  int __pyx_clineno = 0;
2872  __Pyx_RefNannySetupContext("__richcmp__", 0);
2873 
2874  /* "PyClical.pyx":141
2875  * False
2876  * """
2877  * if (lhs is None) or (rhs is None): # <<<<<<<<<<<<<<
2878  * eq = bool(lhs is rhs)
2879  * if op == 2: # ==
2880  */
2881  __pyx_t_2 = (__pyx_v_lhs == Py_None);
2882  __pyx_t_3 = (__pyx_t_2 != 0);
2883  if (!__pyx_t_3) {
2884  } else {
2885  __pyx_t_1 = __pyx_t_3;
2886  goto __pyx_L4_bool_binop_done;
2887  }
2888  __pyx_t_3 = (__pyx_v_rhs == Py_None);
2889  __pyx_t_2 = (__pyx_t_3 != 0);
2890  __pyx_t_1 = __pyx_t_2;
2891  __pyx_L4_bool_binop_done:;
2892  if (__pyx_t_1) {
2893 
2894  /* "PyClical.pyx":142
2895  * """
2896  * if (lhs is None) or (rhs is None):
2897  * eq = bool(lhs is rhs) # <<<<<<<<<<<<<<
2898  * if op == 2: # ==
2899  * return eq
2900  */
2901  __pyx_t_1 = (__pyx_v_lhs == __pyx_v_rhs);
2902  __pyx_t_4 = __Pyx_PyBool_FromLong((!(!__pyx_t_1))); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
2903  __Pyx_GOTREF(__pyx_t_4);
2904  __pyx_v_eq = __pyx_t_4;
2905  __pyx_t_4 = 0;
2906 
2907  /* "PyClical.pyx":143
2908  * if (lhs is None) or (rhs is None):
2909  * eq = bool(lhs is rhs)
2910  * if op == 2: # == # <<<<<<<<<<<<<<
2911  * return eq
2912  * elif op == 3: # !=
2913  */
2914  switch (__pyx_v_op) {
2915  case 2:
2916 
2917  /* "PyClical.pyx":144
2918  * eq = bool(lhs is rhs)
2919  * if op == 2: # ==
2920  * return eq # <<<<<<<<<<<<<<
2921  * elif op == 3: # !=
2922  * return not eq
2923  */
2924  __Pyx_XDECREF(__pyx_r);
2925  __Pyx_INCREF(__pyx_v_eq);
2926  __pyx_r = __pyx_v_eq;
2927  goto __pyx_L0;
2928 
2929  /* "PyClical.pyx":143
2930  * if (lhs is None) or (rhs is None):
2931  * eq = bool(lhs is rhs)
2932  * if op == 2: # == # <<<<<<<<<<<<<<
2933  * return eq
2934  * elif op == 3: # !=
2935  */
2936  break;
2937 
2938  /* "PyClical.pyx":145
2939  * if op == 2: # ==
2940  * return eq
2941  * elif op == 3: # != # <<<<<<<<<<<<<<
2942  * return not eq
2943  * else:
2944  */
2945  case 3:
2946 
2947  /* "PyClical.pyx":146
2948  * return eq
2949  * elif op == 3: # !=
2950  * return not eq # <<<<<<<<<<<<<<
2951  * else:
2952  * if op == 0: # <
2953  */
2954  __Pyx_XDECREF(__pyx_r);
2955  __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_eq); if (unlikely(__pyx_t_1 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 146; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
2956  __pyx_t_4 = __Pyx_PyBool_FromLong((!__pyx_t_1)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 146; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
2957  __Pyx_GOTREF(__pyx_t_4);
2958  __pyx_r = __pyx_t_4;
2959  __pyx_t_4 = 0;
2960  goto __pyx_L0;
2961 
2962  /* "PyClical.pyx":145
2963  * if op == 2: # ==
2964  * return eq
2965  * elif op == 3: # != # <<<<<<<<<<<<<<
2966  * return not eq
2967  * else:
2968  */
2969  break;
2970  default:
2971 
2972  /* "PyClical.pyx":148
2973  * return not eq
2974  * else:
2975  * if op == 0: # < # <<<<<<<<<<<<<<
2976  * return False
2977  * elif op == 1: # <=
2978  */
2979  __pyx_t_1 = ((__pyx_v_op == 0) != 0);
2980  if (__pyx_t_1) {
2981 
2982  /* "PyClical.pyx":149
2983  * else:
2984  * if op == 0: # <
2985  * return False # <<<<<<<<<<<<<<
2986  * elif op == 1: # <=
2987  * return eq
2988  */
2989  __Pyx_XDECREF(__pyx_r);
2990  __Pyx_INCREF(Py_False);
2991  __pyx_r = Py_False;
2992  goto __pyx_L0;
2993 
2994  /* "PyClical.pyx":148
2995  * return not eq
2996  * else:
2997  * if op == 0: # < # <<<<<<<<<<<<<<
2998  * return False
2999  * elif op == 1: # <=
3000  */
3001  }
3002 
3003  /* "PyClical.pyx":150
3004  * if op == 0: # <
3005  * return False
3006  * elif op == 1: # <= # <<<<<<<<<<<<<<
3007  * return eq
3008  * elif op == 4: # >
3009  */
3010  __pyx_t_1 = ((__pyx_v_op == 1) != 0);
3011  if (__pyx_t_1) {
3012 
3013  /* "PyClical.pyx":151
3014  * return False
3015  * elif op == 1: # <=
3016  * return eq # <<<<<<<<<<<<<<
3017  * elif op == 4: # >
3018  * return False
3019  */
3020  __Pyx_XDECREF(__pyx_r);
3021  __Pyx_INCREF(__pyx_v_eq);
3022  __pyx_r = __pyx_v_eq;
3023  goto __pyx_L0;
3024 
3025  /* "PyClical.pyx":150
3026  * if op == 0: # <
3027  * return False
3028  * elif op == 1: # <= # <<<<<<<<<<<<<<
3029  * return eq
3030  * elif op == 4: # >
3031  */
3032  }
3033 
3034  /* "PyClical.pyx":152
3035  * elif op == 1: # <=
3036  * return eq
3037  * elif op == 4: # > # <<<<<<<<<<<<<<
3038  * return False
3039  * elif op == 5: # >=
3040  */
3041  __pyx_t_1 = ((__pyx_v_op == 4) != 0);
3042  if (__pyx_t_1) {
3043 
3044  /* "PyClical.pyx":153
3045  * return eq
3046  * elif op == 4: # >
3047  * return False # <<<<<<<<<<<<<<
3048  * elif op == 5: # >=
3049  * return eq
3050  */
3051  __Pyx_XDECREF(__pyx_r);
3052  __Pyx_INCREF(Py_False);
3053  __pyx_r = Py_False;
3054  goto __pyx_L0;
3055 
3056  /* "PyClical.pyx":152
3057  * elif op == 1: # <=
3058  * return eq
3059  * elif op == 4: # > # <<<<<<<<<<<<<<
3060  * return False
3061  * elif op == 5: # >=
3062  */
3063  }
3064 
3065  /* "PyClical.pyx":154
3066  * elif op == 4: # >
3067  * return False
3068  * elif op == 5: # >= # <<<<<<<<<<<<<<
3069  * return eq
3070  * else:
3071  */
3072  __pyx_t_1 = ((__pyx_v_op == 5) != 0);
3073  if (__pyx_t_1) {
3074 
3075  /* "PyClical.pyx":155
3076  * return False
3077  * elif op == 5: # >=
3078  * return eq # <<<<<<<<<<<<<<
3079  * else:
3080  * return NotImplemented
3081  */
3082  __Pyx_XDECREF(__pyx_r);
3083  __Pyx_INCREF(__pyx_v_eq);
3084  __pyx_r = __pyx_v_eq;
3085  goto __pyx_L0;
3086 
3087  /* "PyClical.pyx":154
3088  * elif op == 4: # >
3089  * return False
3090  * elif op == 5: # >= # <<<<<<<<<<<<<<
3091  * return eq
3092  * else:
3093  */
3094  }
3095 
3096  /* "PyClical.pyx":157
3097  * return eq
3098  * else:
3099  * return NotImplemented # <<<<<<<<<<<<<<
3100  * else:
3101  * eq = bool( toIndexSet(lhs) == toIndexSet(rhs) )
3102  */
3103  /*else*/ {
3104  __Pyx_XDECREF(__pyx_r);
3105  __Pyx_INCREF(__pyx_builtin_NotImplemented);
3106  __pyx_r = __pyx_builtin_NotImplemented;
3107  goto __pyx_L0;
3108  }
3109  break;
3110  }
3111 
3112  /* "PyClical.pyx":141
3113  * False
3114  * """
3115  * if (lhs is None) or (rhs is None): # <<<<<<<<<<<<<<
3116  * eq = bool(lhs is rhs)
3117  * if op == 2: # ==
3118  */
3119  }
3120 
3121  /* "PyClical.pyx":159
3122  * return NotImplemented
3123  * else:
3124  * eq = bool( toIndexSet(lhs) == toIndexSet(rhs) ) # <<<<<<<<<<<<<<
3125  * if op == 2: # ==
3126  * return eq
3127  */
3128  /*else*/ {
3129  __pyx_t_1 = (__pyx_f_8PyClical_toIndexSet(__pyx_v_lhs) == __pyx_f_8PyClical_toIndexSet(__pyx_v_rhs));
3130  __pyx_t_4 = __Pyx_PyBool_FromLong((!(!__pyx_t_1))); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 159; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3131  __Pyx_GOTREF(__pyx_t_4);
3132  __pyx_v_eq = __pyx_t_4;
3133  __pyx_t_4 = 0;
3134 
3135  /* "PyClical.pyx":160
3136  * else:
3137  * eq = bool( toIndexSet(lhs) == toIndexSet(rhs) )
3138  * if op == 2: # == # <<<<<<<<<<<<<<
3139  * return eq
3140  * elif op == 3: # !=
3141  */
3142  switch (__pyx_v_op) {
3143  case 2:
3144 
3145  /* "PyClical.pyx":161
3146  * eq = bool( toIndexSet(lhs) == toIndexSet(rhs) )
3147  * if op == 2: # ==
3148  * return eq # <<<<<<<<<<<<<<
3149  * elif op == 3: # !=
3150  * return not eq
3151  */
3152  __Pyx_XDECREF(__pyx_r);
3153  __Pyx_INCREF(__pyx_v_eq);
3154  __pyx_r = __pyx_v_eq;
3155  goto __pyx_L0;
3156 
3157  /* "PyClical.pyx":160
3158  * else:
3159  * eq = bool( toIndexSet(lhs) == toIndexSet(rhs) )
3160  * if op == 2: # == # <<<<<<<<<<<<<<
3161  * return eq
3162  * elif op == 3: # !=
3163  */
3164  break;
3165 
3166  /* "PyClical.pyx":162
3167  * if op == 2: # ==
3168  * return eq
3169  * elif op == 3: # != # <<<<<<<<<<<<<<
3170  * return not eq
3171  * else:
3172  */
3173  case 3:
3174 
3175  /* "PyClical.pyx":163
3176  * return eq
3177  * elif op == 3: # !=
3178  * return not eq # <<<<<<<<<<<<<<
3179  * else:
3180  * lt = bool( toIndexSet(lhs) < toIndexSet(rhs) )
3181  */
3182  __Pyx_XDECREF(__pyx_r);
3183  __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_eq); if (unlikely(__pyx_t_1 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 163; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3184  __pyx_t_4 = __Pyx_PyBool_FromLong((!__pyx_t_1)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 163; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3185  __Pyx_GOTREF(__pyx_t_4);
3186  __pyx_r = __pyx_t_4;
3187  __pyx_t_4 = 0;
3188  goto __pyx_L0;
3189 
3190  /* "PyClical.pyx":162
3191  * if op == 2: # ==
3192  * return eq
3193  * elif op == 3: # != # <<<<<<<<<<<<<<
3194  * return not eq
3195  * else:
3196  */
3197  break;
3198  default:
3199 
3200  /* "PyClical.pyx":165
3201  * return not eq
3202  * else:
3203  * lt = bool( toIndexSet(lhs) < toIndexSet(rhs) ) # <<<<<<<<<<<<<<
3204  * if op == 0: # <
3205  * return lt
3206  */
3207  __pyx_t_1 = (__pyx_f_8PyClical_toIndexSet(__pyx_v_lhs) < __pyx_f_8PyClical_toIndexSet(__pyx_v_rhs));
3208  __pyx_t_4 = __Pyx_PyBool_FromLong((!(!__pyx_t_1))); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 165; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3209  __Pyx_GOTREF(__pyx_t_4);
3210  __pyx_v_lt = __pyx_t_4;
3211  __pyx_t_4 = 0;
3212 
3213  /* "PyClical.pyx":166
3214  * else:
3215  * lt = bool( toIndexSet(lhs) < toIndexSet(rhs) )
3216  * if op == 0: # < # <<<<<<<<<<<<<<
3217  * return lt
3218  * elif op == 1: # <=
3219  */
3220  __pyx_t_1 = ((__pyx_v_op == 0) != 0);
3221  if (__pyx_t_1) {
3222 
3223  /* "PyClical.pyx":167
3224  * lt = bool( toIndexSet(lhs) < toIndexSet(rhs) )
3225  * if op == 0: # <
3226  * return lt # <<<<<<<<<<<<<<
3227  * elif op == 1: # <=
3228  * return lt or eq
3229  */
3230  __Pyx_XDECREF(__pyx_r);
3231  __Pyx_INCREF(__pyx_v_lt);
3232  __pyx_r = __pyx_v_lt;
3233  goto __pyx_L0;
3234 
3235  /* "PyClical.pyx":166
3236  * else:
3237  * lt = bool( toIndexSet(lhs) < toIndexSet(rhs) )
3238  * if op == 0: # < # <<<<<<<<<<<<<<
3239  * return lt
3240  * elif op == 1: # <=
3241  */
3242  }
3243 
3244  /* "PyClical.pyx":168
3245  * if op == 0: # <
3246  * return lt
3247  * elif op == 1: # <= # <<<<<<<<<<<<<<
3248  * return lt or eq
3249  * elif op == 4: # >
3250  */
3251  __pyx_t_1 = ((__pyx_v_op == 1) != 0);
3252  if (__pyx_t_1) {
3253 
3254  /* "PyClical.pyx":169
3255  * return lt
3256  * elif op == 1: # <=
3257  * return lt or eq # <<<<<<<<<<<<<<
3258  * elif op == 4: # >
3259  * return not (lt or eq)
3260  */
3261  __Pyx_XDECREF(__pyx_r);
3262  __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_lt); if (unlikely(__pyx_t_1 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 169; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3263  if (!__pyx_t_1) {
3264  } else {
3265  __Pyx_INCREF(__pyx_v_lt);
3266  __pyx_t_4 = __pyx_v_lt;
3267  goto __pyx_L8_bool_binop_done;
3268  }
3269  __Pyx_INCREF(__pyx_v_eq);
3270  __pyx_t_4 = __pyx_v_eq;
3271  __pyx_L8_bool_binop_done:;
3272  __pyx_r = __pyx_t_4;
3273  __pyx_t_4 = 0;
3274  goto __pyx_L0;
3275 
3276  /* "PyClical.pyx":168
3277  * if op == 0: # <
3278  * return lt
3279  * elif op == 1: # <= # <<<<<<<<<<<<<<
3280  * return lt or eq
3281  * elif op == 4: # >
3282  */
3283  }
3284 
3285  /* "PyClical.pyx":170
3286  * elif op == 1: # <=
3287  * return lt or eq
3288  * elif op == 4: # > # <<<<<<<<<<<<<<
3289  * return not (lt or eq)
3290  * elif op == 5: # >=
3291  */
3292  __pyx_t_1 = ((__pyx_v_op == 4) != 0);
3293  if (__pyx_t_1) {
3294 
3295  /* "PyClical.pyx":171
3296  * return lt or eq
3297  * elif op == 4: # >
3298  * return not (lt or eq) # <<<<<<<<<<<<<<
3299  * elif op == 5: # >=
3300  * return not lt
3301  */
3302  __Pyx_XDECREF(__pyx_r);
3303  __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_v_lt); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 171; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3304  if (!__pyx_t_2) {
3305  } else {
3306  __pyx_t_1 = __pyx_t_2;
3307  goto __pyx_L10_bool_binop_done;
3308  }
3309  __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_v_eq); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 171; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3310  __pyx_t_1 = __pyx_t_2;
3311  __pyx_L10_bool_binop_done:;
3312  __pyx_t_4 = __Pyx_PyBool_FromLong((!__pyx_t_1)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 171; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3313  __Pyx_GOTREF(__pyx_t_4);
3314  __pyx_r = __pyx_t_4;
3315  __pyx_t_4 = 0;
3316  goto __pyx_L0;
3317 
3318  /* "PyClical.pyx":170
3319  * elif op == 1: # <=
3320  * return lt or eq
3321  * elif op == 4: # > # <<<<<<<<<<<<<<
3322  * return not (lt or eq)
3323  * elif op == 5: # >=
3324  */
3325  }
3326 
3327  /* "PyClical.pyx":172
3328  * elif op == 4: # >
3329  * return not (lt or eq)
3330  * elif op == 5: # >= # <<<<<<<<<<<<<<
3331  * return not lt
3332  * else:
3333  */
3334  __pyx_t_1 = ((__pyx_v_op == 5) != 0);
3335  if (__pyx_t_1) {
3336 
3337  /* "PyClical.pyx":173
3338  * return not (lt or eq)
3339  * elif op == 5: # >=
3340  * return not lt # <<<<<<<<<<<<<<
3341  * else:
3342  * return NotImplemented
3343  */
3344  __Pyx_XDECREF(__pyx_r);
3345  __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_lt); if (unlikely(__pyx_t_1 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 173; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3346  __pyx_t_4 = __Pyx_PyBool_FromLong((!__pyx_t_1)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 173; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3347  __Pyx_GOTREF(__pyx_t_4);
3348  __pyx_r = __pyx_t_4;
3349  __pyx_t_4 = 0;
3350  goto __pyx_L0;
3351 
3352  /* "PyClical.pyx":172
3353  * elif op == 4: # >
3354  * return not (lt or eq)
3355  * elif op == 5: # >= # <<<<<<<<<<<<<<
3356  * return not lt
3357  * else:
3358  */
3359  }
3360 
3361  /* "PyClical.pyx":175
3362  * return not lt
3363  * else:
3364  * return NotImplemented # <<<<<<<<<<<<<<
3365  *
3366  * def __setitem__(self, idx, val):
3367  */
3368  /*else*/ {
3369  __Pyx_XDECREF(__pyx_r);
3370  __Pyx_INCREF(__pyx_builtin_NotImplemented);
3371  __pyx_r = __pyx_builtin_NotImplemented;
3372  goto __pyx_L0;
3373  }
3374  break;
3375  }
3376  }
3377 
3378  /* "PyClical.pyx":120
3379  * del self.instance
3380  *
3381  * def __richcmp__(lhs, rhs, int op): # <<<<<<<<<<<<<<
3382  * """
3383  * Compare two objects of class index_set.
3384  */
3385 
3386  /* function exit code */
3387  __pyx_L1_error:;
3388  __Pyx_XDECREF(__pyx_t_4);
3389  __Pyx_AddTraceback("PyClical.index_set.__richcmp__", __pyx_clineno, __pyx_lineno, __pyx_filename);
3390  __pyx_r = NULL;
3391  __pyx_L0:;
3392  __Pyx_XDECREF(__pyx_v_eq);
3393  __Pyx_XDECREF(__pyx_v_lt);
3394  __Pyx_XGIVEREF(__pyx_r);
3395  __Pyx_RefNannyFinishContext();
3396  return __pyx_r;
3397 }
3398 
3399 /* "PyClical.pyx":177
3400  * return NotImplemented
3401  *
3402  * def __setitem__(self, idx, val): # <<<<<<<<<<<<<<
3403  * """
3404  * Set the value of an index_set object at index idx to value val.
3405  */
3406 
3407 /* Python wrapper */
3408 static int __pyx_pw_8PyClical_9index_set_9__setitem__(PyObject *__pyx_v_self, PyObject *__pyx_v_idx, PyObject *__pyx_v_val); /*proto*/
3409 static char __pyx_doc_8PyClical_9index_set_8__setitem__[] = "\n Set the value of an index_set object at index idx to value val.\n\n >>> s=index_set({1}); s[2] = True; print s\n {1,2}\n >>> s=index_set({1,2}); s[1] = False; print s\n {2}\n ";
3410 #if CYTHON_COMPILING_IN_CPYTHON
3411 struct wrapperbase __pyx_wrapperbase_8PyClical_9index_set_8__setitem__;
3412 #endif
3413 static int __pyx_pw_8PyClical_9index_set_9__setitem__(PyObject *__pyx_v_self, PyObject *__pyx_v_idx, PyObject *__pyx_v_val) {
3414  int __pyx_r;
3415  __Pyx_RefNannyDeclarations
3416  __Pyx_RefNannySetupContext("__setitem__ (wrapper)", 0);
3417  __pyx_r = __pyx_pf_8PyClical_9index_set_8__setitem__(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_self), ((PyObject *)__pyx_v_idx), ((PyObject *)__pyx_v_val));
3418 
3419  /* function exit code */
3420  __Pyx_RefNannyFinishContext();
3421  return __pyx_r;
3422 }
3423 
3424 static int __pyx_pf_8PyClical_9index_set_8__setitem__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self, PyObject *__pyx_v_idx, PyObject *__pyx_v_val) {
3425  int __pyx_r;
3426  __Pyx_RefNannyDeclarations
3427  int __pyx_t_1;
3428  int __pyx_t_2;
3429  int __pyx_lineno = 0;
3430  const char *__pyx_filename = NULL;
3431  int __pyx_clineno = 0;
3432  __Pyx_RefNannySetupContext("__setitem__", 0);
3433 
3434  /* "PyClical.pyx":186
3435  * {2}
3436  * """
3437  * self.instance.set(idx, val) # <<<<<<<<<<<<<<
3438  * return
3439  *
3440  */
3441  __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_idx); if (unlikely((__pyx_t_1 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 186; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3442  __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_v_val); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 186; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3443  try {
3444  __pyx_v_self->instance->set(__pyx_t_1, __pyx_t_2);
3445  } catch(...) {
3446  __Pyx_CppExn2PyErr();
3447  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 186; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3448  }
3449 
3450  /* "PyClical.pyx":187
3451  * """
3452  * self.instance.set(idx, val)
3453  * return # <<<<<<<<<<<<<<
3454  *
3455  * def __getitem__(self, idx):
3456  */
3457  __pyx_r = 0;
3458  goto __pyx_L0;
3459 
3460  /* "PyClical.pyx":177
3461  * return NotImplemented
3462  *
3463  * def __setitem__(self, idx, val): # <<<<<<<<<<<<<<
3464  * """
3465  * Set the value of an index_set object at index idx to value val.
3466  */
3467 
3468  /* function exit code */
3469  __pyx_L1_error:;
3470  __Pyx_AddTraceback("PyClical.index_set.__setitem__", __pyx_clineno, __pyx_lineno, __pyx_filename);
3471  __pyx_r = -1;
3472  __pyx_L0:;
3473  __Pyx_RefNannyFinishContext();
3474  return __pyx_r;
3475 }
3476 
3477 /* "PyClical.pyx":189
3478  * return
3479  *
3480  * def __getitem__(self, idx): # <<<<<<<<<<<<<<
3481  * """
3482  * Get the value of an index_set object at an index.
3483  */
3484 
3485 /* Python wrapper */
3486 static PyObject *__pyx_pw_8PyClical_9index_set_11__getitem__(PyObject *__pyx_v_self, PyObject *__pyx_v_idx); /*proto*/
3487 static char __pyx_doc_8PyClical_9index_set_10__getitem__[] = "\n Get the value of an index_set object at an index.\n\n >>> index_set({1})[1]\n True\n >>> index_set({1})[2]\n False\n >>> index_set({2})[-1]\n False\n >>> index_set({2})[1]\n False\n >>> index_set({2})[2]\n True\n >>> index_set({2})[33]\n False\n ";
3488 #if CYTHON_COMPILING_IN_CPYTHON
3489 struct wrapperbase __pyx_wrapperbase_8PyClical_9index_set_10__getitem__;
3490 #endif
3491 static PyObject *__pyx_pw_8PyClical_9index_set_11__getitem__(PyObject *__pyx_v_self, PyObject *__pyx_v_idx) {
3492  PyObject *__pyx_r = 0;
3493  __Pyx_RefNannyDeclarations
3494  __Pyx_RefNannySetupContext("__getitem__ (wrapper)", 0);
3495  __pyx_r = __pyx_pf_8PyClical_9index_set_10__getitem__(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_self), ((PyObject *)__pyx_v_idx));
3496 
3497  /* function exit code */
3498  __Pyx_RefNannyFinishContext();
3499  return __pyx_r;
3500 }
3501 
3502 static PyObject *__pyx_pf_8PyClical_9index_set_10__getitem__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self, PyObject *__pyx_v_idx) {
3503  PyObject *__pyx_r = NULL;
3504  __Pyx_RefNannyDeclarations
3505  int __pyx_t_1;
3506  PyObject *__pyx_t_2 = NULL;
3507  int __pyx_lineno = 0;
3508  const char *__pyx_filename = NULL;
3509  int __pyx_clineno = 0;
3510  __Pyx_RefNannySetupContext("__getitem__", 0);
3511 
3512  /* "PyClical.pyx":206
3513  * False
3514  * """
3515  * return self.instance.getitem(idx) # <<<<<<<<<<<<<<
3516  *
3517  * def __contains__(self, idx):
3518  */
3519  __Pyx_XDECREF(__pyx_r);
3520  __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_idx); if (unlikely((__pyx_t_1 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 206; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3521  __pyx_t_2 = __Pyx_PyBool_FromLong(__pyx_v_self->instance->operator[](__pyx_t_1)); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 206; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3522  __Pyx_GOTREF(__pyx_t_2);
3523  __pyx_r = __pyx_t_2;
3524  __pyx_t_2 = 0;
3525  goto __pyx_L0;
3526 
3527  /* "PyClical.pyx":189
3528  * return
3529  *
3530  * def __getitem__(self, idx): # <<<<<<<<<<<<<<
3531  * """
3532  * Get the value of an index_set object at an index.
3533  */
3534 
3535  /* function exit code */
3536  __pyx_L1_error:;
3537  __Pyx_XDECREF(__pyx_t_2);
3538  __Pyx_AddTraceback("PyClical.index_set.__getitem__", __pyx_clineno, __pyx_lineno, __pyx_filename);
3539  __pyx_r = NULL;
3540  __pyx_L0:;
3541  __Pyx_XGIVEREF(__pyx_r);
3542  __Pyx_RefNannyFinishContext();
3543  return __pyx_r;
3544 }
3545 
3546 /* "PyClical.pyx":208
3547  * return self.instance.getitem(idx)
3548  *
3549  * def __contains__(self, idx): # <<<<<<<<<<<<<<
3550  * """
3551  * Check that an index_set object contains the index idx: idx in self.
3552  */
3553 
3554 /* Python wrapper */
3555 static int __pyx_pw_8PyClical_9index_set_13__contains__(PyObject *__pyx_v_self, PyObject *__pyx_v_idx); /*proto*/
3556 static char __pyx_doc_8PyClical_9index_set_12__contains__[] = "\n Check that an index_set object contains the index idx: idx in self.\n\n >>> 1 in index_set({1})\n True\n >>> 2 in index_set({1})\n False\n >>> -1 in index_set({2})\n False\n >>> 1 in index_set({2})\n False\n >>> 2 in index_set({2})\n True\n >>> 33 in index_set({2})\n False\n ";
3557 #if CYTHON_COMPILING_IN_CPYTHON
3558 struct wrapperbase __pyx_wrapperbase_8PyClical_9index_set_12__contains__;
3559 #endif
3560 static int __pyx_pw_8PyClical_9index_set_13__contains__(PyObject *__pyx_v_self, PyObject *__pyx_v_idx) {
3561  int __pyx_r;
3562  __Pyx_RefNannyDeclarations
3563  __Pyx_RefNannySetupContext("__contains__ (wrapper)", 0);
3564  __pyx_r = __pyx_pf_8PyClical_9index_set_12__contains__(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_self), ((PyObject *)__pyx_v_idx));
3565 
3566  /* function exit code */
3567  __Pyx_RefNannyFinishContext();
3568  return __pyx_r;
3569 }
3570 
3571 static int __pyx_pf_8PyClical_9index_set_12__contains__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self, PyObject *__pyx_v_idx) {
3572  int __pyx_r;
3573  __Pyx_RefNannyDeclarations
3574  int __pyx_t_1;
3575  int __pyx_lineno = 0;
3576  const char *__pyx_filename = NULL;
3577  int __pyx_clineno = 0;
3578  __Pyx_RefNannySetupContext("__contains__", 0);
3579 
3580  /* "PyClical.pyx":225
3581  * False
3582  * """
3583  * return self.instance.getitem(idx) # <<<<<<<<<<<<<<
3584  *
3585  * def __iter__(self):
3586  */
3587  __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_idx); if (unlikely((__pyx_t_1 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 225; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3588  __pyx_r = __pyx_v_self->instance->operator[](__pyx_t_1);
3589  goto __pyx_L0;
3590 
3591  /* "PyClical.pyx":208
3592  * return self.instance.getitem(idx)
3593  *
3594  * def __contains__(self, idx): # <<<<<<<<<<<<<<
3595  * """
3596  * Check that an index_set object contains the index idx: idx in self.
3597  */
3598 
3599  /* function exit code */
3600  __pyx_L1_error:;
3601  __Pyx_AddTraceback("PyClical.index_set.__contains__", __pyx_clineno, __pyx_lineno, __pyx_filename);
3602  __pyx_r = -1;
3603  __pyx_L0:;
3604  __Pyx_RefNannyFinishContext();
3605  return __pyx_r;
3606 }
3607 static PyObject *__pyx_gb_8PyClical_9index_set_16generator(__pyx_CoroutineObject *__pyx_generator, PyObject *__pyx_sent_value); /* proto */
3608 
3609 /* "PyClical.pyx":227
3610  * return self.instance.getitem(idx)
3611  *
3612  * def __iter__(self): # <<<<<<<<<<<<<<
3613  * """
3614  * Iterate over the indices of an index_set.
3615  */
3616 
3617 /* Python wrapper */
3618 static PyObject *__pyx_pw_8PyClical_9index_set_15__iter__(PyObject *__pyx_v_self); /*proto*/
3619 static char __pyx_doc_8PyClical_9index_set_14__iter__[] = "\n Iterate over the indices of an index_set.\n\n >>> for i in index_set({-3,4,7}): print i,\n -3 4 7\n ";
3620 #if CYTHON_COMPILING_IN_CPYTHON
3621 struct wrapperbase __pyx_wrapperbase_8PyClical_9index_set_14__iter__;
3622 #endif
3623 static PyObject *__pyx_pw_8PyClical_9index_set_15__iter__(PyObject *__pyx_v_self) {
3624  PyObject *__pyx_r = 0;
3625  __Pyx_RefNannyDeclarations
3626  __Pyx_RefNannySetupContext("__iter__ (wrapper)", 0);
3627  __pyx_r = __pyx_pf_8PyClical_9index_set_14__iter__(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_self));
3628 
3629  /* function exit code */
3630  __Pyx_RefNannyFinishContext();
3631  return __pyx_r;
3632 }
3633 
3634 static PyObject *__pyx_pf_8PyClical_9index_set_14__iter__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self) {
3635  struct __pyx_obj_8PyClical___pyx_scope_struct____iter__ *__pyx_cur_scope;
3636  PyObject *__pyx_r = NULL;
3637  __Pyx_RefNannyDeclarations
3638  int __pyx_lineno = 0;
3639  const char *__pyx_filename = NULL;
3640  int __pyx_clineno = 0;
3641  __Pyx_RefNannySetupContext("__iter__", 0);
3642  __pyx_cur_scope = (struct __pyx_obj_8PyClical___pyx_scope_struct____iter__ *)__pyx_tp_new_8PyClical___pyx_scope_struct____iter__(__pyx_ptype_8PyClical___pyx_scope_struct____iter__, __pyx_empty_tuple, NULL);
3643  if (unlikely(!__pyx_cur_scope)) {
3644  __Pyx_RefNannyFinishContext();
3645  return NULL;
3646  }
3647  __Pyx_GOTREF(__pyx_cur_scope);
3648  __pyx_cur_scope->__pyx_v_self = __pyx_v_self;
3649  __Pyx_INCREF((PyObject *)__pyx_cur_scope->__pyx_v_self);
3650  __Pyx_GIVEREF((PyObject *)__pyx_cur_scope->__pyx_v_self);
3651  {
3652  __pyx_CoroutineObject *gen = __Pyx_Generator_New((__pyx_coroutine_body_t) __pyx_gb_8PyClical_9index_set_16generator, (PyObject *) __pyx_cur_scope, __pyx_n_s_iter, __pyx_n_s_index_set___iter); if (unlikely(!gen)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3653  __Pyx_DECREF(__pyx_cur_scope);
3654  __Pyx_RefNannyFinishContext();
3655  return (PyObject *) gen;
3656  }
3657 
3658  /* function exit code */
3659  __pyx_L1_error:;
3660  __Pyx_AddTraceback("PyClical.index_set.__iter__", __pyx_clineno, __pyx_lineno, __pyx_filename);
3661  __pyx_r = NULL;
3662  __Pyx_DECREF(((PyObject *)__pyx_cur_scope));
3663  __Pyx_XGIVEREF(__pyx_r);
3664  __Pyx_RefNannyFinishContext();
3665  return __pyx_r;
3666 }
3667 
3668 static PyObject *__pyx_gb_8PyClical_9index_set_16generator(__pyx_CoroutineObject *__pyx_generator, PyObject *__pyx_sent_value) /* generator body */
3669 {
3670  struct __pyx_obj_8PyClical___pyx_scope_struct____iter__ *__pyx_cur_scope = ((struct __pyx_obj_8PyClical___pyx_scope_struct____iter__ *)__pyx_generator->closure);
3671  PyObject *__pyx_r = NULL;
3672  PyObject *__pyx_t_1 = NULL;
3673  PyObject *__pyx_t_2 = NULL;
3674  PyObject *__pyx_t_3 = NULL;
3675  PyObject *__pyx_t_4 = NULL;
3676  Py_ssize_t __pyx_t_5;
3677  PyObject *(*__pyx_t_6)(PyObject *);
3678  int __pyx_t_7;
3679  int __pyx_t_8;
3680  int __pyx_lineno = 0;
3681  const char *__pyx_filename = NULL;
3682  int __pyx_clineno = 0;
3683  __Pyx_RefNannyDeclarations
3684  __Pyx_RefNannySetupContext("None", 0);
3685  switch (__pyx_generator->resume_label) {
3686  case 0: goto __pyx_L3_first_run;
3687  case 1: goto __pyx_L7_resume_from_yield;
3688  default: /* CPython raises the right error here */
3689  __Pyx_RefNannyFinishContext();
3690  return NULL;
3691  }
3692  __pyx_L3_first_run:;
3693  if (unlikely(!__pyx_sent_value)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3694 
3695  /* "PyClical.pyx":234
3696  * -3 4 7
3697  * """
3698  * for idx in range(self.min(), self.max()+1): # <<<<<<<<<<<<<<
3699  * if idx in self:
3700  * yield idx
3701  */
3702  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_cur_scope->__pyx_v_self), __pyx_n_s_min); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 234; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3703  __Pyx_GOTREF(__pyx_t_2);
3704  __pyx_t_3 = NULL;
3705  if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_2))) {
3706  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
3707  if (likely(__pyx_t_3)) {
3708  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
3709  __Pyx_INCREF(__pyx_t_3);
3710  __Pyx_INCREF(function);
3711  __Pyx_DECREF_SET(__pyx_t_2, function);
3712  }
3713  }
3714  if (__pyx_t_3) {
3715  __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 234; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3716  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3717  } else {
3718  __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 234; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3719  }
3720  __Pyx_GOTREF(__pyx_t_1);
3721  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
3722  __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_cur_scope->__pyx_v_self), __pyx_n_s_max); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 234; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3723  __Pyx_GOTREF(__pyx_t_3);
3724  __pyx_t_4 = NULL;
3725  if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_3))) {
3726  __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
3727  if (likely(__pyx_t_4)) {
3728  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
3729  __Pyx_INCREF(__pyx_t_4);
3730  __Pyx_INCREF(function);
3731  __Pyx_DECREF_SET(__pyx_t_3, function);
3732  }
3733  }
3734  if (__pyx_t_4) {
3735  __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 234; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3736  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
3737  } else {
3738  __pyx_t_2 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 234; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3739  }
3740  __Pyx_GOTREF(__pyx_t_2);
3741  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3742  __pyx_t_3 = __Pyx_PyInt_AddObjC(__pyx_t_2, __pyx_int_1, 1, 0); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 234; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3743  __Pyx_GOTREF(__pyx_t_3);
3744  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
3745  __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 234; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3746  __Pyx_GOTREF(__pyx_t_2);
3747  __Pyx_GIVEREF(__pyx_t_1);
3748  PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1);
3749  __Pyx_GIVEREF(__pyx_t_3);
3750  PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_3);
3751  __pyx_t_1 = 0;
3752  __pyx_t_3 = 0;
3753  __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_range, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 234; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3754  __Pyx_GOTREF(__pyx_t_3);
3755  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
3756  if (likely(PyList_CheckExact(__pyx_t_3)) || PyTuple_CheckExact(__pyx_t_3)) {
3757  __pyx_t_2 = __pyx_t_3; __Pyx_INCREF(__pyx_t_2); __pyx_t_5 = 0;
3758  __pyx_t_6 = NULL;
3759  } else {
3760  __pyx_t_5 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 234; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3761  __Pyx_GOTREF(__pyx_t_2);
3762  __pyx_t_6 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 234; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3763  }
3764  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3765  for (;;) {
3766  if (likely(!__pyx_t_6)) {
3767  if (likely(PyList_CheckExact(__pyx_t_2))) {
3768  if (__pyx_t_5 >= PyList_GET_SIZE(__pyx_t_2)) break;
3769  #if CYTHON_COMPILING_IN_CPYTHON
3770  __pyx_t_3 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_5); __Pyx_INCREF(__pyx_t_3); __pyx_t_5++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 234; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3771  #else
3772  __pyx_t_3 = PySequence_ITEM(__pyx_t_2, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 234; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3773  __Pyx_GOTREF(__pyx_t_3);
3774  #endif
3775  } else {
3776  if (__pyx_t_5 >= PyTuple_GET_SIZE(__pyx_t_2)) break;
3777  #if CYTHON_COMPILING_IN_CPYTHON
3778  __pyx_t_3 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_5); __Pyx_INCREF(__pyx_t_3); __pyx_t_5++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 234; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3779  #else
3780  __pyx_t_3 = PySequence_ITEM(__pyx_t_2, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 234; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3781  __Pyx_GOTREF(__pyx_t_3);
3782  #endif
3783  }
3784  } else {
3785  __pyx_t_3 = __pyx_t_6(__pyx_t_2);
3786  if (unlikely(!__pyx_t_3)) {
3787  PyObject* exc_type = PyErr_Occurred();
3788  if (exc_type) {
3789  if (likely(exc_type == PyExc_StopIteration || PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
3790  else {__pyx_filename = __pyx_f[0]; __pyx_lineno = 234; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3791  }
3792  break;
3793  }
3794  __Pyx_GOTREF(__pyx_t_3);
3795  }
3796  __Pyx_XGOTREF(__pyx_cur_scope->__pyx_v_idx);
3797  __Pyx_XDECREF_SET(__pyx_cur_scope->__pyx_v_idx, __pyx_t_3);
3798  __Pyx_GIVEREF(__pyx_t_3);
3799  __pyx_t_3 = 0;
3800 
3801  /* "PyClical.pyx":235
3802  * """
3803  * for idx in range(self.min(), self.max()+1):
3804  * if idx in self: # <<<<<<<<<<<<<<
3805  * yield idx
3806  *
3807  */
3808  __pyx_t_7 = (__Pyx_PySequence_ContainsTF(__pyx_cur_scope->__pyx_v_idx, ((PyObject *)__pyx_cur_scope->__pyx_v_self), Py_EQ)); if (unlikely(__pyx_t_7 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 235; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3809  __pyx_t_8 = (__pyx_t_7 != 0);
3810  if (__pyx_t_8) {
3811 
3812  /* "PyClical.pyx":236
3813  * for idx in range(self.min(), self.max()+1):
3814  * if idx in self:
3815  * yield idx # <<<<<<<<<<<<<<
3816  *
3817  * def __invert__(self):
3818  */
3819  __Pyx_INCREF(__pyx_cur_scope->__pyx_v_idx);
3820  __pyx_r = __pyx_cur_scope->__pyx_v_idx;
3821  __Pyx_XGIVEREF(__pyx_t_2);
3822  __pyx_cur_scope->__pyx_t_0 = __pyx_t_2;
3823  __pyx_cur_scope->__pyx_t_1 = __pyx_t_5;
3824  __pyx_cur_scope->__pyx_t_2 = __pyx_t_6;
3825  __Pyx_XGIVEREF(__pyx_r);
3826  __Pyx_RefNannyFinishContext();
3827  /* return from generator, yielding value */
3828  __pyx_generator->resume_label = 1;
3829  return __pyx_r;
3830  __pyx_L7_resume_from_yield:;
3831  __pyx_t_2 = __pyx_cur_scope->__pyx_t_0;
3832  __pyx_cur_scope->__pyx_t_0 = 0;
3833  __Pyx_XGOTREF(__pyx_t_2);
3834  __pyx_t_5 = __pyx_cur_scope->__pyx_t_1;
3835  __pyx_t_6 = __pyx_cur_scope->__pyx_t_2;
3836  if (unlikely(!__pyx_sent_value)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 236; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3837 
3838  /* "PyClical.pyx":235
3839  * """
3840  * for idx in range(self.min(), self.max()+1):
3841  * if idx in self: # <<<<<<<<<<<<<<
3842  * yield idx
3843  *
3844  */
3845  }
3846 
3847  /* "PyClical.pyx":234
3848  * -3 4 7
3849  * """
3850  * for idx in range(self.min(), self.max()+1): # <<<<<<<<<<<<<<
3851  * if idx in self:
3852  * yield idx
3853  */
3854  }
3855  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
3856 
3857  /* "PyClical.pyx":227
3858  * return self.instance.getitem(idx)
3859  *
3860  * def __iter__(self): # <<<<<<<<<<<<<<
3861  * """
3862  * Iterate over the indices of an index_set.
3863  */
3864 
3865  /* function exit code */
3866  PyErr_SetNone(PyExc_StopIteration);
3867  goto __pyx_L0;
3868  __pyx_L1_error:;
3869  __Pyx_XDECREF(__pyx_t_1);
3870  __Pyx_XDECREF(__pyx_t_2);
3871  __Pyx_XDECREF(__pyx_t_3);
3872  __Pyx_XDECREF(__pyx_t_4);
3873  __Pyx_AddTraceback("__iter__", __pyx_clineno, __pyx_lineno, __pyx_filename);
3874  __pyx_L0:;
3875  __Pyx_XDECREF(__pyx_r); __pyx_r = 0;
3876  __pyx_generator->resume_label = -1;
3877  __Pyx_Coroutine_clear((PyObject*)__pyx_generator);
3878  __Pyx_RefNannyFinishContext();
3879  return __pyx_r;
3880 }
3881 
3882 /* "PyClical.pyx":238
3883  * yield idx
3884  *
3885  * def __invert__(self): # <<<<<<<<<<<<<<
3886  * """
3887  * Set complement: not.
3888  */
3889 
3890 /* Python wrapper */
3891 static PyObject *__pyx_pw_8PyClical_9index_set_18__invert__(PyObject *__pyx_v_self); /*proto*/
3892 static char __pyx_doc_8PyClical_9index_set_17__invert__[] = "\n Set complement: not.\n\n >>> print ~index_set({-16,-15,-14,-13,-12,-11,-10,-9,-8,-7,-6,-5,-4,-3,-2,-1,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16})\n {-32,-31,-30,-29,-28,-27,-26,-25,-24,-23,-22,-21,-20,-19,-18,-17,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32}\n ";
3893 #if CYTHON_COMPILING_IN_CPYTHON
3894 struct wrapperbase __pyx_wrapperbase_8PyClical_9index_set_17__invert__;
3895 #endif
3896 static PyObject *__pyx_pw_8PyClical_9index_set_18__invert__(PyObject *__pyx_v_self) {
3897  PyObject *__pyx_r = 0;
3898  __Pyx_RefNannyDeclarations
3899  __Pyx_RefNannySetupContext("__invert__ (wrapper)", 0);
3900  __pyx_r = __pyx_pf_8PyClical_9index_set_17__invert__(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_self));
3901 
3902  /* function exit code */
3903  __Pyx_RefNannyFinishContext();
3904  return __pyx_r;
3905 }
3906 
3907 static PyObject *__pyx_pf_8PyClical_9index_set_17__invert__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self) {
3908  PyObject *__pyx_r = NULL;
3909  __Pyx_RefNannyDeclarations
3910  PyObject *__pyx_t_1 = NULL;
3911  PyObject *__pyx_t_2 = NULL;
3912  int __pyx_lineno = 0;
3913  const char *__pyx_filename = NULL;
3914  int __pyx_clineno = 0;
3915  __Pyx_RefNannySetupContext("__invert__", 0);
3916 
3917  /* "PyClical.pyx":245
3918  * {-32,-31,-30,-29,-28,-27,-26,-25,-24,-23,-22,-21,-20,-19,-18,-17,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32}
3919  * """
3920  * return index_set().wrap( self.instance.invert() ) # <<<<<<<<<<<<<<
3921  *
3922  * def __xor__(lhs, rhs):
3923  */
3924  __Pyx_XDECREF(__pyx_r);
3925  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_index_set), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 245; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3926  __Pyx_GOTREF(__pyx_t_1);
3927  __pyx_t_2 = __pyx_f_8PyClical_9index_set_wrap(((struct __pyx_obj_8PyClical_index_set *)__pyx_t_1), __pyx_v_self->instance->operator~()); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 245; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3928  __Pyx_GOTREF(__pyx_t_2);
3929  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
3930  __pyx_r = __pyx_t_2;
3931  __pyx_t_2 = 0;
3932  goto __pyx_L0;
3933 
3934  /* "PyClical.pyx":238
3935  * yield idx
3936  *
3937  * def __invert__(self): # <<<<<<<<<<<<<<
3938  * """
3939  * Set complement: not.
3940  */
3941 
3942  /* function exit code */
3943  __pyx_L1_error:;
3944  __Pyx_XDECREF(__pyx_t_1);
3945  __Pyx_XDECREF(__pyx_t_2);
3946  __Pyx_AddTraceback("PyClical.index_set.__invert__", __pyx_clineno, __pyx_lineno, __pyx_filename);
3947  __pyx_r = NULL;
3948  __pyx_L0:;
3949  __Pyx_XGIVEREF(__pyx_r);
3950  __Pyx_RefNannyFinishContext();
3951  return __pyx_r;
3952 }
3953 
3954 /* "PyClical.pyx":247
3955  * return index_set().wrap( self.instance.invert() )
3956  *
3957  * def __xor__(lhs, rhs): # <<<<<<<<<<<<<<
3958  * """
3959  * Symmetric set difference: exclusive or.
3960  */
3961 
3962 /* Python wrapper */
3963 static PyObject *__pyx_pw_8PyClical_9index_set_20__xor__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs); /*proto*/
3964 static char __pyx_doc_8PyClical_9index_set_19__xor__[] = "\n Symmetric set difference: exclusive or.\n\n >>> print index_set({1}) ^ index_set({2})\n {1,2}\n >>> print index_set({1,2}) ^ index_set({2})\n {1}\n ";
3965 #if CYTHON_COMPILING_IN_CPYTHON
3966 struct wrapperbase __pyx_wrapperbase_8PyClical_9index_set_19__xor__;
3967 #endif
3968 static PyObject *__pyx_pw_8PyClical_9index_set_20__xor__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs) {
3969  PyObject *__pyx_r = 0;
3970  __Pyx_RefNannyDeclarations
3971  __Pyx_RefNannySetupContext("__xor__ (wrapper)", 0);
3972  __pyx_r = __pyx_pf_8PyClical_9index_set_19__xor__(((PyObject *)__pyx_v_lhs), ((PyObject *)__pyx_v_rhs));
3973 
3974  /* function exit code */
3975  __Pyx_RefNannyFinishContext();
3976  return __pyx_r;
3977 }
3978 
3979 static PyObject *__pyx_pf_8PyClical_9index_set_19__xor__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs) {
3980  PyObject *__pyx_r = NULL;
3981  __Pyx_RefNannyDeclarations
3982  PyObject *__pyx_t_1 = NULL;
3983  PyObject *__pyx_t_2 = NULL;
3984  int __pyx_lineno = 0;
3985  const char *__pyx_filename = NULL;
3986  int __pyx_clineno = 0;
3987  __Pyx_RefNannySetupContext("__xor__", 0);
3988 
3989  /* "PyClical.pyx":256
3990  * {1}
3991  * """
3992  * return index_set().wrap( toIndexSet(lhs) ^ toIndexSet(rhs) ) # <<<<<<<<<<<<<<
3993  *
3994  * def __ixor__(self, rhs):
3995  */
3996  __Pyx_XDECREF(__pyx_r);
3997  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_index_set), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 256; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
3998  __Pyx_GOTREF(__pyx_t_1);
3999  __pyx_t_2 = __pyx_f_8PyClical_9index_set_wrap(((struct __pyx_obj_8PyClical_index_set *)__pyx_t_1), (__pyx_f_8PyClical_toIndexSet(__pyx_v_lhs) ^ __pyx_f_8PyClical_toIndexSet(__pyx_v_rhs))); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 256; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
4000  __Pyx_GOTREF(__pyx_t_2);
4001  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
4002  __pyx_r = __pyx_t_2;
4003  __pyx_t_2 = 0;
4004  goto __pyx_L0;
4005 
4006  /* "PyClical.pyx":247
4007  * return index_set().wrap( self.instance.invert() )
4008  *
4009  * def __xor__(lhs, rhs): # <<<<<<<<<<<<<<
4010  * """
4011  * Symmetric set difference: exclusive or.
4012  */
4013 
4014  /* function exit code */
4015  __pyx_L1_error:;
4016  __Pyx_XDECREF(__pyx_t_1);
4017  __Pyx_XDECREF(__pyx_t_2);
4018  __Pyx_AddTraceback("PyClical.index_set.__xor__", __pyx_clineno, __pyx_lineno, __pyx_filename);
4019  __pyx_r = NULL;
4020  __pyx_L0:;
4021  __Pyx_XGIVEREF(__pyx_r);
4022  __Pyx_RefNannyFinishContext();
4023  return __pyx_r;
4024 }
4025 
4026 /* "PyClical.pyx":258
4027  * return index_set().wrap( toIndexSet(lhs) ^ toIndexSet(rhs) )
4028  *
4029  * def __ixor__(self, rhs): # <<<<<<<<<<<<<<
4030  * """
4031  * Symmetric set difference: exclusive or.
4032  */
4033 
4034 /* Python wrapper */
4035 static PyObject *__pyx_pw_8PyClical_9index_set_22__ixor__(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs); /*proto*/
4036 static char __pyx_doc_8PyClical_9index_set_21__ixor__[] = "\n Symmetric set difference: exclusive or.\n\n >>> x = index_set({1}); x ^= index_set({2}); print x\n {1,2}\n >>> x = index_set({1,2}); x ^= index_set({2}); print x\n {1}\n ";
4037 #if CYTHON_COMPILING_IN_CPYTHON
4038 struct wrapperbase __pyx_wrapperbase_8PyClical_9index_set_21__ixor__;
4039 #endif
4040 static PyObject *__pyx_pw_8PyClical_9index_set_22__ixor__(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs) {
4041  PyObject *__pyx_r = 0;
4042  __Pyx_RefNannyDeclarations
4043  __Pyx_RefNannySetupContext("__ixor__ (wrapper)", 0);
4044  __pyx_r = __pyx_pf_8PyClical_9index_set_21__ixor__(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_self), ((PyObject *)__pyx_v_rhs));
4045 
4046  /* function exit code */
4047  __Pyx_RefNannyFinishContext();
4048  return __pyx_r;
4049 }
4050 
4051 static PyObject *__pyx_pf_8PyClical_9index_set_21__ixor__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self, PyObject *__pyx_v_rhs) {
4052  PyObject *__pyx_r = NULL;
4053  __Pyx_RefNannyDeclarations
4054  PyObject *__pyx_t_1 = NULL;
4055  int __pyx_lineno = 0;
4056  const char *__pyx_filename = NULL;
4057  int __pyx_clineno = 0;
4058  __Pyx_RefNannySetupContext("__ixor__", 0);
4059 
4060  /* "PyClical.pyx":267
4061  * {1}
4062  * """
4063  * return self.wrap( self.unwrap() ^ toIndexSet(rhs) ) # <<<<<<<<<<<<<<
4064  *
4065  * def __and__(lhs, rhs):
4066  */
4067  __Pyx_XDECREF(__pyx_r);
4068  __pyx_t_1 = __pyx_f_8PyClical_9index_set_wrap(__pyx_v_self, (__pyx_f_8PyClical_9index_set_unwrap(__pyx_v_self) ^ __pyx_f_8PyClical_toIndexSet(__pyx_v_rhs))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 267; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
4069  __Pyx_GOTREF(__pyx_t_1);
4070  __pyx_r = __pyx_t_1;
4071  __pyx_t_1 = 0;
4072  goto __pyx_L0;
4073 
4074  /* "PyClical.pyx":258
4075  * return index_set().wrap( toIndexSet(lhs) ^ toIndexSet(rhs) )
4076  *
4077  * def __ixor__(self, rhs): # <<<<<<<<<<<<<<
4078  * """
4079  * Symmetric set difference: exclusive or.
4080  */
4081 
4082  /* function exit code */
4083  __pyx_L1_error:;
4084  __Pyx_XDECREF(__pyx_t_1);
4085  __Pyx_AddTraceback("PyClical.index_set.__ixor__", __pyx_clineno, __pyx_lineno, __pyx_filename);
4086  __pyx_r = NULL;
4087  __pyx_L0:;
4088  __Pyx_XGIVEREF(__pyx_r);
4089  __Pyx_RefNannyFinishContext();
4090  return __pyx_r;
4091 }
4092 
4093 /* "PyClical.pyx":269
4094  * return self.wrap( self.unwrap() ^ toIndexSet(rhs) )
4095  *
4096  * def __and__(lhs, rhs): # <<<<<<<<<<<<<<
4097  * """
4098  * Set intersection: and.
4099  */
4100 
4101 /* Python wrapper */
4102 static PyObject *__pyx_pw_8PyClical_9index_set_24__and__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs); /*proto*/
4103 static char __pyx_doc_8PyClical_9index_set_23__and__[] = "\n Set intersection: and.\n\n >>> print index_set({1}) & index_set({2})\n {}\n >>> print index_set({1,2}) & index_set({2})\n {2}\n ";
4104 #if CYTHON_COMPILING_IN_CPYTHON
4105 struct wrapperbase __pyx_wrapperbase_8PyClical_9index_set_23__and__;
4106 #endif
4107 static PyObject *__pyx_pw_8PyClical_9index_set_24__and__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs) {
4108  PyObject *__pyx_r = 0;
4109  __Pyx_RefNannyDeclarations
4110  __Pyx_RefNannySetupContext("__and__ (wrapper)", 0);
4111  __pyx_r = __pyx_pf_8PyClical_9index_set_23__and__(((PyObject *)__pyx_v_lhs), ((PyObject *)__pyx_v_rhs));
4112 
4113  /* function exit code */
4114  __Pyx_RefNannyFinishContext();
4115  return __pyx_r;
4116 }
4117 
4118 static PyObject *__pyx_pf_8PyClical_9index_set_23__and__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs) {
4119  PyObject *__pyx_r = NULL;
4120  __Pyx_RefNannyDeclarations
4121  PyObject *__pyx_t_1 = NULL;
4122  PyObject *__pyx_t_2 = NULL;
4123  int __pyx_lineno = 0;
4124  const char *__pyx_filename = NULL;
4125  int __pyx_clineno = 0;
4126  __Pyx_RefNannySetupContext("__and__", 0);
4127 
4128  /* "PyClical.pyx":278
4129  * {2}
4130  * """
4131  * return index_set().wrap( toIndexSet(lhs) & toIndexSet(rhs) ) # <<<<<<<<<<<<<<
4132  *
4133  * def __iand__(self, rhs):
4134  */
4135  __Pyx_XDECREF(__pyx_r);
4136  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_index_set), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 278; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
4137  __Pyx_GOTREF(__pyx_t_1);
4138  __pyx_t_2 = __pyx_f_8PyClical_9index_set_wrap(((struct __pyx_obj_8PyClical_index_set *)__pyx_t_1), (__pyx_f_8PyClical_toIndexSet(__pyx_v_lhs) & __pyx_f_8PyClical_toIndexSet(__pyx_v_rhs))); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 278; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
4139  __Pyx_GOTREF(__pyx_t_2);
4140  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
4141  __pyx_r = __pyx_t_2;
4142  __pyx_t_2 = 0;
4143  goto __pyx_L0;
4144 
4145  /* "PyClical.pyx":269
4146  * return self.wrap( self.unwrap() ^ toIndexSet(rhs) )
4147  *
4148  * def __and__(lhs, rhs): # <<<<<<<<<<<<<<
4149  * """
4150  * Set intersection: and.
4151  */
4152 
4153  /* function exit code */
4154  __pyx_L1_error:;
4155  __Pyx_XDECREF(__pyx_t_1);
4156  __Pyx_XDECREF(__pyx_t_2);
4157  __Pyx_AddTraceback("PyClical.index_set.__and__", __pyx_clineno, __pyx_lineno, __pyx_filename);
4158  __pyx_r = NULL;
4159  __pyx_L0:;
4160  __Pyx_XGIVEREF(__pyx_r);
4161  __Pyx_RefNannyFinishContext();
4162  return __pyx_r;
4163 }
4164 
4165 /* "PyClical.pyx":280
4166  * return index_set().wrap( toIndexSet(lhs) & toIndexSet(rhs) )
4167  *
4168  * def __iand__(self, rhs): # <<<<<<<<<<<<<<
4169  * """
4170  * Set intersection: and.
4171  */
4172 
4173 /* Python wrapper */
4174 static PyObject *__pyx_pw_8PyClical_9index_set_26__iand__(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs); /*proto*/
4175 static char __pyx_doc_8PyClical_9index_set_25__iand__[] = "\n Set intersection: and.\n\n >>> x = index_set({1}); x &= index_set({2}); print x\n {}\n >>> x = index_set({1,2}); x &= index_set({2}); print x\n {2}\n ";
4176 #if CYTHON_COMPILING_IN_CPYTHON
4177 struct wrapperbase __pyx_wrapperbase_8PyClical_9index_set_25__iand__;
4178 #endif
4179 static PyObject *__pyx_pw_8PyClical_9index_set_26__iand__(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs) {
4180  PyObject *__pyx_r = 0;
4181  __Pyx_RefNannyDeclarations
4182  __Pyx_RefNannySetupContext("__iand__ (wrapper)", 0);
4183  __pyx_r = __pyx_pf_8PyClical_9index_set_25__iand__(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_self), ((PyObject *)__pyx_v_rhs));
4184 
4185  /* function exit code */
4186  __Pyx_RefNannyFinishContext();
4187  return __pyx_r;
4188 }
4189 
4190 static PyObject *__pyx_pf_8PyClical_9index_set_25__iand__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self, PyObject *__pyx_v_rhs) {
4191  PyObject *__pyx_r = NULL;
4192  __Pyx_RefNannyDeclarations
4193  PyObject *__pyx_t_1 = NULL;
4194  int __pyx_lineno = 0;
4195  const char *__pyx_filename = NULL;
4196  int __pyx_clineno = 0;
4197  __Pyx_RefNannySetupContext("__iand__", 0);
4198 
4199  /* "PyClical.pyx":289
4200  * {2}
4201  * """
4202  * return self.wrap( self.unwrap() & toIndexSet(rhs) ) # <<<<<<<<<<<<<<
4203  *
4204  * def __or__(lhs, rhs):
4205  */
4206  __Pyx_XDECREF(__pyx_r);
4207  __pyx_t_1 = __pyx_f_8PyClical_9index_set_wrap(__pyx_v_self, (__pyx_f_8PyClical_9index_set_unwrap(__pyx_v_self) & __pyx_f_8PyClical_toIndexSet(__pyx_v_rhs))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 289; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
4208  __Pyx_GOTREF(__pyx_t_1);
4209  __pyx_r = __pyx_t_1;
4210  __pyx_t_1 = 0;
4211  goto __pyx_L0;
4212 
4213  /* "PyClical.pyx":280
4214  * return index_set().wrap( toIndexSet(lhs) & toIndexSet(rhs) )
4215  *
4216  * def __iand__(self, rhs): # <<<<<<<<<<<<<<
4217  * """
4218  * Set intersection: and.
4219  */
4220 
4221  /* function exit code */
4222  __pyx_L1_error:;
4223  __Pyx_XDECREF(__pyx_t_1);
4224  __Pyx_AddTraceback("PyClical.index_set.__iand__", __pyx_clineno, __pyx_lineno, __pyx_filename);
4225  __pyx_r = NULL;
4226  __pyx_L0:;
4227  __Pyx_XGIVEREF(__pyx_r);
4228  __Pyx_RefNannyFinishContext();
4229  return __pyx_r;
4230 }
4231 
4232 /* "PyClical.pyx":291
4233  * return self.wrap( self.unwrap() & toIndexSet(rhs) )
4234  *
4235  * def __or__(lhs, rhs): # <<<<<<<<<<<<<<
4236  * """
4237  * Set union: or.
4238  */
4239 
4240 /* Python wrapper */
4241 static PyObject *__pyx_pw_8PyClical_9index_set_28__or__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs); /*proto*/
4242 static char __pyx_doc_8PyClical_9index_set_27__or__[] = "\n Set union: or.\n\n >>> print index_set({1}) | index_set({2})\n {1,2}\n >>> print index_set({1,2}) | index_set({2})\n {1,2}\n ";
4243 #if CYTHON_COMPILING_IN_CPYTHON
4244 struct wrapperbase __pyx_wrapperbase_8PyClical_9index_set_27__or__;
4245 #endif
4246 static PyObject *__pyx_pw_8PyClical_9index_set_28__or__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs) {
4247  PyObject *__pyx_r = 0;
4248  __Pyx_RefNannyDeclarations
4249  __Pyx_RefNannySetupContext("__or__ (wrapper)", 0);
4250  __pyx_r = __pyx_pf_8PyClical_9index_set_27__or__(((PyObject *)__pyx_v_lhs), ((PyObject *)__pyx_v_rhs));
4251 
4252  /* function exit code */
4253  __Pyx_RefNannyFinishContext();
4254  return __pyx_r;
4255 }
4256 
4257 static PyObject *__pyx_pf_8PyClical_9index_set_27__or__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs) {
4258  PyObject *__pyx_r = NULL;
4259  __Pyx_RefNannyDeclarations
4260  PyObject *__pyx_t_1 = NULL;
4261  PyObject *__pyx_t_2 = NULL;
4262  int __pyx_lineno = 0;
4263  const char *__pyx_filename = NULL;
4264  int __pyx_clineno = 0;
4265  __Pyx_RefNannySetupContext("__or__", 0);
4266 
4267  /* "PyClical.pyx":300
4268  * {1,2}
4269  * """
4270  * return index_set().wrap( toIndexSet(lhs) | toIndexSet(rhs) ) # <<<<<<<<<<<<<<
4271  *
4272  * def __ior__(self, rhs):
4273  */
4274  __Pyx_XDECREF(__pyx_r);
4275  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_index_set), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 300; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
4276  __Pyx_GOTREF(__pyx_t_1);
4277  __pyx_t_2 = __pyx_f_8PyClical_9index_set_wrap(((struct __pyx_obj_8PyClical_index_set *)__pyx_t_1), (__pyx_f_8PyClical_toIndexSet(__pyx_v_lhs) | __pyx_f_8PyClical_toIndexSet(__pyx_v_rhs))); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 300; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
4278  __Pyx_GOTREF(__pyx_t_2);
4279  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
4280  __pyx_r = __pyx_t_2;
4281  __pyx_t_2 = 0;
4282  goto __pyx_L0;
4283 
4284  /* "PyClical.pyx":291
4285  * return self.wrap( self.unwrap() & toIndexSet(rhs) )
4286  *
4287  * def __or__(lhs, rhs): # <<<<<<<<<<<<<<
4288  * """
4289  * Set union: or.
4290  */
4291 
4292  /* function exit code */
4293  __pyx_L1_error:;
4294  __Pyx_XDECREF(__pyx_t_1);
4295  __Pyx_XDECREF(__pyx_t_2);
4296  __Pyx_AddTraceback("PyClical.index_set.__or__", __pyx_clineno, __pyx_lineno, __pyx_filename);
4297  __pyx_r = NULL;
4298  __pyx_L0:;
4299  __Pyx_XGIVEREF(__pyx_r);
4300  __Pyx_RefNannyFinishContext();
4301  return __pyx_r;
4302 }
4303 
4304 /* "PyClical.pyx":302
4305  * return index_set().wrap( toIndexSet(lhs) | toIndexSet(rhs) )
4306  *
4307  * def __ior__(self, rhs): # <<<<<<<<<<<<<<
4308  * """
4309  * Set union: or.
4310  */
4311 
4312 /* Python wrapper */
4313 static PyObject *__pyx_pw_8PyClical_9index_set_30__ior__(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs); /*proto*/
4314 static char __pyx_doc_8PyClical_9index_set_29__ior__[] = "\n Set union: or.\n\n >>> x = index_set({1}); x |= index_set({2}); print x\n {1,2}\n >>> x = index_set({1,2}); x |= index_set({2}); print x\n {1,2}\n ";
4315 #if CYTHON_COMPILING_IN_CPYTHON
4316 struct wrapperbase __pyx_wrapperbase_8PyClical_9index_set_29__ior__;
4317 #endif
4318 static PyObject *__pyx_pw_8PyClical_9index_set_30__ior__(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs) {
4319  PyObject *__pyx_r = 0;
4320  __Pyx_RefNannyDeclarations
4321  __Pyx_RefNannySetupContext("__ior__ (wrapper)", 0);
4322  __pyx_r = __pyx_pf_8PyClical_9index_set_29__ior__(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_self), ((PyObject *)__pyx_v_rhs));
4323 
4324  /* function exit code */
4325  __Pyx_RefNannyFinishContext();
4326  return __pyx_r;
4327 }
4328 
4329 static PyObject *__pyx_pf_8PyClical_9index_set_29__ior__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self, PyObject *__pyx_v_rhs) {
4330  PyObject *__pyx_r = NULL;
4331  __Pyx_RefNannyDeclarations
4332  PyObject *__pyx_t_1 = NULL;
4333  int __pyx_lineno = 0;
4334  const char *__pyx_filename = NULL;
4335  int __pyx_clineno = 0;
4336  __Pyx_RefNannySetupContext("__ior__", 0);
4337 
4338  /* "PyClical.pyx":311
4339  * {1,2}
4340  * """
4341  * return self.wrap( self.unwrap() | toIndexSet(rhs) ) # <<<<<<<<<<<<<<
4342  *
4343  * def count(self):
4344  */
4345  __Pyx_XDECREF(__pyx_r);
4346  __pyx_t_1 = __pyx_f_8PyClical_9index_set_wrap(__pyx_v_self, (__pyx_f_8PyClical_9index_set_unwrap(__pyx_v_self) | __pyx_f_8PyClical_toIndexSet(__pyx_v_rhs))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 311; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
4347  __Pyx_GOTREF(__pyx_t_1);
4348  __pyx_r = __pyx_t_1;
4349  __pyx_t_1 = 0;
4350  goto __pyx_L0;
4351 
4352  /* "PyClical.pyx":302
4353  * return index_set().wrap( toIndexSet(lhs) | toIndexSet(rhs) )
4354  *
4355  * def __ior__(self, rhs): # <<<<<<<<<<<<<<
4356  * """
4357  * Set union: or.
4358  */
4359 
4360  /* function exit code */
4361  __pyx_L1_error:;
4362  __Pyx_XDECREF(__pyx_t_1);
4363  __Pyx_AddTraceback("PyClical.index_set.__ior__", __pyx_clineno, __pyx_lineno, __pyx_filename);
4364  __pyx_r = NULL;
4365  __pyx_L0:;
4366  __Pyx_XGIVEREF(__pyx_r);
4367  __Pyx_RefNannyFinishContext();
4368  return __pyx_r;
4369 }
4370 
4371 /* "PyClical.pyx":313
4372  * return self.wrap( self.unwrap() | toIndexSet(rhs) )
4373  *
4374  * def count(self): # <<<<<<<<<<<<<<
4375  * """
4376  * Cardinality: Number of indices included in set.
4377  */
4378 
4379 /* Python wrapper */
4380 static PyObject *__pyx_pw_8PyClical_9index_set_32count(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
4381 static char __pyx_doc_8PyClical_9index_set_31count[] = "\n Cardinality: Number of indices included in set.\n\n >>> index_set({-1,1,2}).count()\n 3\n ";
4382 static PyObject *__pyx_pw_8PyClical_9index_set_32count(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
4383  PyObject *__pyx_r = 0;
4384  __Pyx_RefNannyDeclarations
4385  __Pyx_RefNannySetupContext("count (wrapper)", 0);
4386  __pyx_r = __pyx_pf_8PyClical_9index_set_31count(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_self));
4387 
4388  /* function exit code */
4389  __Pyx_RefNannyFinishContext();
4390  return __pyx_r;
4391 }
4392 
4393 static PyObject *__pyx_pf_8PyClical_9index_set_31count(struct __pyx_obj_8PyClical_index_set *__pyx_v_self) {
4394  PyObject *__pyx_r = NULL;
4395  __Pyx_RefNannyDeclarations
4396  PyObject *__pyx_t_1 = NULL;
4397  int __pyx_lineno = 0;
4398  const char *__pyx_filename = NULL;
4399  int __pyx_clineno = 0;
4400  __Pyx_RefNannySetupContext("count", 0);
4401 
4402  /* "PyClical.pyx":320
4403  * 3
4404  * """
4405  * return self.instance.count() # <<<<<<<<<<<<<<
4406  *
4407  * def count_neg(self):
4408  */
4409  __Pyx_XDECREF(__pyx_r);
4410  __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->instance->count()); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 320; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
4411  __Pyx_GOTREF(__pyx_t_1);
4412  __pyx_r = __pyx_t_1;
4413  __pyx_t_1 = 0;
4414  goto __pyx_L0;
4415 
4416  /* "PyClical.pyx":313
4417  * return self.wrap( self.unwrap() | toIndexSet(rhs) )
4418  *
4419  * def count(self): # <<<<<<<<<<<<<<
4420  * """
4421  * Cardinality: Number of indices included in set.
4422  */
4423 
4424  /* function exit code */
4425  __pyx_L1_error:;
4426  __Pyx_XDECREF(__pyx_t_1);
4427  __Pyx_AddTraceback("PyClical.index_set.count", __pyx_clineno, __pyx_lineno, __pyx_filename);
4428  __pyx_r = NULL;
4429  __pyx_L0:;
4430  __Pyx_XGIVEREF(__pyx_r);
4431  __Pyx_RefNannyFinishContext();
4432  return __pyx_r;
4433 }
4434 
4435 /* "PyClical.pyx":322
4436  * return self.instance.count()
4437  *
4438  * def count_neg(self): # <<<<<<<<<<<<<<
4439  * """
4440  * Number of negative indices included in set.
4441  */
4442 
4443 /* Python wrapper */
4444 static PyObject *__pyx_pw_8PyClical_9index_set_34count_neg(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
4445 static char __pyx_doc_8PyClical_9index_set_33count_neg[] = "\n Number of negative indices included in set.\n\n >>> index_set({-1,1,2}).count_neg()\n 1\n ";
4446 static PyObject *__pyx_pw_8PyClical_9index_set_34count_neg(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
4447  PyObject *__pyx_r = 0;
4448  __Pyx_RefNannyDeclarations
4449  __Pyx_RefNannySetupContext("count_neg (wrapper)", 0);
4450  __pyx_r = __pyx_pf_8PyClical_9index_set_33count_neg(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_self));
4451 
4452  /* function exit code */
4453  __Pyx_RefNannyFinishContext();
4454  return __pyx_r;
4455 }
4456 
4457 static PyObject *__pyx_pf_8PyClical_9index_set_33count_neg(struct __pyx_obj_8PyClical_index_set *__pyx_v_self) {
4458  PyObject *__pyx_r = NULL;
4459  __Pyx_RefNannyDeclarations
4460  PyObject *__pyx_t_1 = NULL;
4461  int __pyx_lineno = 0;
4462  const char *__pyx_filename = NULL;
4463  int __pyx_clineno = 0;
4464  __Pyx_RefNannySetupContext("count_neg", 0);
4465 
4466  /* "PyClical.pyx":329
4467  * 1
4468  * """
4469  * return self.instance.count_neg() # <<<<<<<<<<<<<<
4470  *
4471  * def count_pos(self):
4472  */
4473  __Pyx_XDECREF(__pyx_r);
4474  __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->instance->count_neg()); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 329; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
4475  __Pyx_GOTREF(__pyx_t_1);
4476  __pyx_r = __pyx_t_1;
4477  __pyx_t_1 = 0;
4478  goto __pyx_L0;
4479 
4480  /* "PyClical.pyx":322
4481  * return self.instance.count()
4482  *
4483  * def count_neg(self): # <<<<<<<<<<<<<<
4484  * """
4485  * Number of negative indices included in set.
4486  */
4487 
4488  /* function exit code */
4489  __pyx_L1_error:;
4490  __Pyx_XDECREF(__pyx_t_1);
4491  __Pyx_AddTraceback("PyClical.index_set.count_neg", __pyx_clineno, __pyx_lineno, __pyx_filename);
4492  __pyx_r = NULL;
4493  __pyx_L0:;
4494  __Pyx_XGIVEREF(__pyx_r);
4495  __Pyx_RefNannyFinishContext();
4496  return __pyx_r;
4497 }
4498 
4499 /* "PyClical.pyx":331
4500  * return self.instance.count_neg()
4501  *
4502  * def count_pos(self): # <<<<<<<<<<<<<<
4503  * """
4504  * Number of positive indices included in set.
4505  */
4506 
4507 /* Python wrapper */
4508 static PyObject *__pyx_pw_8PyClical_9index_set_36count_pos(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
4509 static char __pyx_doc_8PyClical_9index_set_35count_pos[] = "\n Number of positive indices included in set.\n\n >>> index_set({-1,1,2}).count_pos()\n 2\n ";
4510 static PyObject *__pyx_pw_8PyClical_9index_set_36count_pos(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
4511  PyObject *__pyx_r = 0;
4512  __Pyx_RefNannyDeclarations
4513  __Pyx_RefNannySetupContext("count_pos (wrapper)", 0);
4514  __pyx_r = __pyx_pf_8PyClical_9index_set_35count_pos(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_self));
4515 
4516  /* function exit code */
4517  __Pyx_RefNannyFinishContext();
4518  return __pyx_r;
4519 }
4520 
4521 static PyObject *__pyx_pf_8PyClical_9index_set_35count_pos(struct __pyx_obj_8PyClical_index_set *__pyx_v_self) {
4522  PyObject *__pyx_r = NULL;
4523  __Pyx_RefNannyDeclarations
4524  PyObject *__pyx_t_1 = NULL;
4525  int __pyx_lineno = 0;
4526  const char *__pyx_filename = NULL;
4527  int __pyx_clineno = 0;
4528  __Pyx_RefNannySetupContext("count_pos", 0);
4529 
4530  /* "PyClical.pyx":338
4531  * 2
4532  * """
4533  * return self.instance.count_pos() # <<<<<<<<<<<<<<
4534  *
4535  * def min(self):
4536  */
4537  __Pyx_XDECREF(__pyx_r);
4538  __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->instance->count_pos()); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 338; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
4539  __Pyx_GOTREF(__pyx_t_1);
4540  __pyx_r = __pyx_t_1;
4541  __pyx_t_1 = 0;
4542  goto __pyx_L0;
4543 
4544  /* "PyClical.pyx":331
4545  * return self.instance.count_neg()
4546  *
4547  * def count_pos(self): # <<<<<<<<<<<<<<
4548  * """
4549  * Number of positive indices included in set.
4550  */
4551 
4552  /* function exit code */
4553  __pyx_L1_error:;
4554  __Pyx_XDECREF(__pyx_t_1);
4555  __Pyx_AddTraceback("PyClical.index_set.count_pos", __pyx_clineno, __pyx_lineno, __pyx_filename);
4556  __pyx_r = NULL;
4557  __pyx_L0:;
4558  __Pyx_XGIVEREF(__pyx_r);
4559  __Pyx_RefNannyFinishContext();
4560  return __pyx_r;
4561 }
4562 
4563 /* "PyClical.pyx":340
4564  * return self.instance.count_pos()
4565  *
4566  * def min(self): # <<<<<<<<<<<<<<
4567  * """
4568  * Minimum member.
4569  */
4570 
4571 /* Python wrapper */
4572 static PyObject *__pyx_pw_8PyClical_9index_set_38min(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
4573 static char __pyx_doc_8PyClical_9index_set_37min[] = "\n Minimum member.\n\n >>> index_set({-1,1,2}).min()\n -1\n ";
4574 static PyObject *__pyx_pw_8PyClical_9index_set_38min(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
4575  PyObject *__pyx_r = 0;
4576  __Pyx_RefNannyDeclarations
4577  __Pyx_RefNannySetupContext("min (wrapper)", 0);
4578  __pyx_r = __pyx_pf_8PyClical_9index_set_37min(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_self));
4579 
4580  /* function exit code */
4581  __Pyx_RefNannyFinishContext();
4582  return __pyx_r;
4583 }
4584 
4585 static PyObject *__pyx_pf_8PyClical_9index_set_37min(struct __pyx_obj_8PyClical_index_set *__pyx_v_self) {
4586  PyObject *__pyx_r = NULL;
4587  __Pyx_RefNannyDeclarations
4588  PyObject *__pyx_t_1 = NULL;
4589  int __pyx_lineno = 0;
4590  const char *__pyx_filename = NULL;
4591  int __pyx_clineno = 0;
4592  __Pyx_RefNannySetupContext("min", 0);
4593 
4594  /* "PyClical.pyx":347
4595  * -1
4596  * """
4597  * return self.instance.min() # <<<<<<<<<<<<<<
4598  *
4599  * def max(self):
4600  */
4601  __Pyx_XDECREF(__pyx_r);
4602  __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->instance->min()); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 347; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
4603  __Pyx_GOTREF(__pyx_t_1);
4604  __pyx_r = __pyx_t_1;
4605  __pyx_t_1 = 0;
4606  goto __pyx_L0;
4607 
4608  /* "PyClical.pyx":340
4609  * return self.instance.count_pos()
4610  *
4611  * def min(self): # <<<<<<<<<<<<<<
4612  * """
4613  * Minimum member.
4614  */
4615 
4616  /* function exit code */
4617  __pyx_L1_error:;
4618  __Pyx_XDECREF(__pyx_t_1);
4619  __Pyx_AddTraceback("PyClical.index_set.min", __pyx_clineno, __pyx_lineno, __pyx_filename);
4620  __pyx_r = NULL;
4621  __pyx_L0:;
4622  __Pyx_XGIVEREF(__pyx_r);
4623  __Pyx_RefNannyFinishContext();
4624  return __pyx_r;
4625 }
4626 
4627 /* "PyClical.pyx":349
4628  * return self.instance.min()
4629  *
4630  * def max(self): # <<<<<<<<<<<<<<
4631  * """
4632  * Maximum member.
4633  */
4634 
4635 /* Python wrapper */
4636 static PyObject *__pyx_pw_8PyClical_9index_set_40max(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
4637 static char __pyx_doc_8PyClical_9index_set_39max[] = "\n Maximum member.\n\n >>> index_set({-1,1,2}).max()\n 2\n ";
4638 static PyObject *__pyx_pw_8PyClical_9index_set_40max(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
4639  PyObject *__pyx_r = 0;
4640  __Pyx_RefNannyDeclarations
4641  __Pyx_RefNannySetupContext("max (wrapper)", 0);
4642  __pyx_r = __pyx_pf_8PyClical_9index_set_39max(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_self));
4643 
4644  /* function exit code */
4645  __Pyx_RefNannyFinishContext();
4646  return __pyx_r;
4647 }
4648 
4649 static PyObject *__pyx_pf_8PyClical_9index_set_39max(struct __pyx_obj_8PyClical_index_set *__pyx_v_self) {
4650  PyObject *__pyx_r = NULL;
4651  __Pyx_RefNannyDeclarations
4652  PyObject *__pyx_t_1 = NULL;
4653  int __pyx_lineno = 0;
4654  const char *__pyx_filename = NULL;
4655  int __pyx_clineno = 0;
4656  __Pyx_RefNannySetupContext("max", 0);
4657 
4658  /* "PyClical.pyx":356
4659  * 2
4660  * """
4661  * return self.instance.max() # <<<<<<<<<<<<<<
4662  *
4663  * def hash_fn(self):
4664  */
4665  __Pyx_XDECREF(__pyx_r);
4666  __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->instance->max()); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 356; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
4667  __Pyx_GOTREF(__pyx_t_1);
4668  __pyx_r = __pyx_t_1;
4669  __pyx_t_1 = 0;
4670  goto __pyx_L0;
4671 
4672  /* "PyClical.pyx":349
4673  * return self.instance.min()
4674  *
4675  * def max(self): # <<<<<<<<<<<<<<
4676  * """
4677  * Maximum member.
4678  */
4679 
4680  /* function exit code */
4681  __pyx_L1_error:;
4682  __Pyx_XDECREF(__pyx_t_1);
4683  __Pyx_AddTraceback("PyClical.index_set.max", __pyx_clineno, __pyx_lineno, __pyx_filename);
4684  __pyx_r = NULL;
4685  __pyx_L0:;
4686  __Pyx_XGIVEREF(__pyx_r);
4687  __Pyx_RefNannyFinishContext();
4688  return __pyx_r;
4689 }
4690 
4691 /* "PyClical.pyx":358
4692  * return self.instance.max()
4693  *
4694  * def hash_fn(self): # <<<<<<<<<<<<<<
4695  * """
4696  * Hash function.
4697  */
4698 
4699 /* Python wrapper */
4700 static PyObject *__pyx_pw_8PyClical_9index_set_42hash_fn(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
4701 static char __pyx_doc_8PyClical_9index_set_41hash_fn[] = "\n Hash function.\n ";
4702 static PyObject *__pyx_pw_8PyClical_9index_set_42hash_fn(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
4703  PyObject *__pyx_r = 0;
4704  __Pyx_RefNannyDeclarations
4705  __Pyx_RefNannySetupContext("hash_fn (wrapper)", 0);
4706  __pyx_r = __pyx_pf_8PyClical_9index_set_41hash_fn(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_self));
4707 
4708  /* function exit code */
4709  __Pyx_RefNannyFinishContext();
4710  return __pyx_r;
4711 }
4712 
4713 static PyObject *__pyx_pf_8PyClical_9index_set_41hash_fn(struct __pyx_obj_8PyClical_index_set *__pyx_v_self) {
4714  PyObject *__pyx_r = NULL;
4715  __Pyx_RefNannyDeclarations
4716  PyObject *__pyx_t_1 = NULL;
4717  int __pyx_lineno = 0;
4718  const char *__pyx_filename = NULL;
4719  int __pyx_clineno = 0;
4720  __Pyx_RefNannySetupContext("hash_fn", 0);
4721 
4722  /* "PyClical.pyx":362
4723  * Hash function.
4724  * """
4725  * return self.instance.hash_fn() # <<<<<<<<<<<<<<
4726  *
4727  * def sign_of_mult(self, rhs):
4728  */
4729  __Pyx_XDECREF(__pyx_r);
4730  __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->instance->hash_fn()); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 362; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
4731  __Pyx_GOTREF(__pyx_t_1);
4732  __pyx_r = __pyx_t_1;
4733  __pyx_t_1 = 0;
4734  goto __pyx_L0;
4735 
4736  /* "PyClical.pyx":358
4737  * return self.instance.max()
4738  *
4739  * def hash_fn(self): # <<<<<<<<<<<<<<
4740  * """
4741  * Hash function.
4742  */
4743 
4744  /* function exit code */
4745  __pyx_L1_error:;
4746  __Pyx_XDECREF(__pyx_t_1);
4747  __Pyx_AddTraceback("PyClical.index_set.hash_fn", __pyx_clineno, __pyx_lineno, __pyx_filename);
4748  __pyx_r = NULL;
4749  __pyx_L0:;
4750  __Pyx_XGIVEREF(__pyx_r);
4751  __Pyx_RefNannyFinishContext();
4752  return __pyx_r;
4753 }
4754 
4755 /* "PyClical.pyx":364
4756  * return self.instance.hash_fn()
4757  *
4758  * def sign_of_mult(self, rhs): # <<<<<<<<<<<<<<
4759  * """
4760  * Sign of geometric product of two Clifford basis elements.
4761  */
4762 
4763 /* Python wrapper */
4764 static PyObject *__pyx_pw_8PyClical_9index_set_44sign_of_mult(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs); /*proto*/
4765 static char __pyx_doc_8PyClical_9index_set_43sign_of_mult[] = "\n Sign of geometric product of two Clifford basis elements.\n\n >>> s = index_set({1,2}); t=index_set({-1}); s.sign_of_mult(t)\n 1\n ";
4766 static PyObject *__pyx_pw_8PyClical_9index_set_44sign_of_mult(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs) {
4767  PyObject *__pyx_r = 0;
4768  __Pyx_RefNannyDeclarations
4769  __Pyx_RefNannySetupContext("sign_of_mult (wrapper)", 0);
4770  __pyx_r = __pyx_pf_8PyClical_9index_set_43sign_of_mult(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_self), ((PyObject *)__pyx_v_rhs));
4771 
4772  /* function exit code */
4773  __Pyx_RefNannyFinishContext();
4774  return __pyx_r;
4775 }
4776 
4777 static PyObject *__pyx_pf_8PyClical_9index_set_43sign_of_mult(struct __pyx_obj_8PyClical_index_set *__pyx_v_self, PyObject *__pyx_v_rhs) {
4778  PyObject *__pyx_r = NULL;
4779  __Pyx_RefNannyDeclarations
4780  PyObject *__pyx_t_1 = NULL;
4781  int __pyx_lineno = 0;
4782  const char *__pyx_filename = NULL;
4783  int __pyx_clineno = 0;
4784  __Pyx_RefNannySetupContext("sign_of_mult", 0);
4785 
4786  /* "PyClical.pyx":371
4787  * 1
4788  * """
4789  * return self.instance.sign_of_mult(toIndexSet(rhs)) # <<<<<<<<<<<<<<
4790  *
4791  * def sign_of_square(self):
4792  */
4793  __Pyx_XDECREF(__pyx_r);
4794  __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->instance->sign_of_mult(__pyx_f_8PyClical_toIndexSet(__pyx_v_rhs))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 371; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
4795  __Pyx_GOTREF(__pyx_t_1);
4796  __pyx_r = __pyx_t_1;
4797  __pyx_t_1 = 0;
4798  goto __pyx_L0;
4799 
4800  /* "PyClical.pyx":364
4801  * return self.instance.hash_fn()
4802  *
4803  * def sign_of_mult(self, rhs): # <<<<<<<<<<<<<<
4804  * """
4805  * Sign of geometric product of two Clifford basis elements.
4806  */
4807 
4808  /* function exit code */
4809  __pyx_L1_error:;
4810  __Pyx_XDECREF(__pyx_t_1);
4811  __Pyx_AddTraceback("PyClical.index_set.sign_of_mult", __pyx_clineno, __pyx_lineno, __pyx_filename);
4812  __pyx_r = NULL;
4813  __pyx_L0:;
4814  __Pyx_XGIVEREF(__pyx_r);
4815  __Pyx_RefNannyFinishContext();
4816  return __pyx_r;
4817 }
4818 
4819 /* "PyClical.pyx":373
4820  * return self.instance.sign_of_mult(toIndexSet(rhs))
4821  *
4822  * def sign_of_square(self): # <<<<<<<<<<<<<<
4823  * """
4824  * Sign of geometric square of a Clifford basis element.
4825  */
4826 
4827 /* Python wrapper */
4828 static PyObject *__pyx_pw_8PyClical_9index_set_46sign_of_square(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
4829 static char __pyx_doc_8PyClical_9index_set_45sign_of_square[] = "\n Sign of geometric square of a Clifford basis element.\n\n >>> s = index_set({1,2}); s.sign_of_square()\n -1\n ";
4830 static PyObject *__pyx_pw_8PyClical_9index_set_46sign_of_square(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
4831  PyObject *__pyx_r = 0;
4832  __Pyx_RefNannyDeclarations
4833  __Pyx_RefNannySetupContext("sign_of_square (wrapper)", 0);
4834  __pyx_r = __pyx_pf_8PyClical_9index_set_45sign_of_square(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_self));
4835 
4836  /* function exit code */
4837  __Pyx_RefNannyFinishContext();
4838  return __pyx_r;
4839 }
4840 
4841 static PyObject *__pyx_pf_8PyClical_9index_set_45sign_of_square(struct __pyx_obj_8PyClical_index_set *__pyx_v_self) {
4842  PyObject *__pyx_r = NULL;
4843  __Pyx_RefNannyDeclarations
4844  PyObject *__pyx_t_1 = NULL;
4845  int __pyx_lineno = 0;
4846  const char *__pyx_filename = NULL;
4847  int __pyx_clineno = 0;
4848  __Pyx_RefNannySetupContext("sign_of_square", 0);
4849 
4850  /* "PyClical.pyx":380
4851  * -1
4852  * """
4853  * return self.instance.sign_of_square() # <<<<<<<<<<<<<<
4854  *
4855  * def __repr__(self):
4856  */
4857  __Pyx_XDECREF(__pyx_r);
4858  __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->instance->sign_of_square()); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 380; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
4859  __Pyx_GOTREF(__pyx_t_1);
4860  __pyx_r = __pyx_t_1;
4861  __pyx_t_1 = 0;
4862  goto __pyx_L0;
4863 
4864  /* "PyClical.pyx":373
4865  * return self.instance.sign_of_mult(toIndexSet(rhs))
4866  *
4867  * def sign_of_square(self): # <<<<<<<<<<<<<<
4868  * """
4869  * Sign of geometric square of a Clifford basis element.
4870  */
4871 
4872  /* function exit code */
4873  __pyx_L1_error:;
4874  __Pyx_XDECREF(__pyx_t_1);
4875  __Pyx_AddTraceback("PyClical.index_set.sign_of_square", __pyx_clineno, __pyx_lineno, __pyx_filename);
4876  __pyx_r = NULL;
4877  __pyx_L0:;
4878  __Pyx_XGIVEREF(__pyx_r);
4879  __Pyx_RefNannyFinishContext();
4880  return __pyx_r;
4881 }
4882 
4883 /* "PyClical.pyx":382
4884  * return self.instance.sign_of_square()
4885  *
4886  * def __repr__(self): # <<<<<<<<<<<<<<
4887  * """
4888  * The official string representation of self.
4889  */
4890 
4891 /* Python wrapper */
4892 static PyObject *__pyx_pw_8PyClical_9index_set_48__repr__(PyObject *__pyx_v_self); /*proto*/
4893 static char __pyx_doc_8PyClical_9index_set_47__repr__[] = "\n The \342\200\234official\342\200\235 string representation of self.\n\n >>> index_set({1,2}).__repr__()\n 'index_set({1,2})'\n >>> repr(index_set({1,2}))\n 'index_set({1,2})'\n ";
4894 #if CYTHON_COMPILING_IN_CPYTHON
4895 struct wrapperbase __pyx_wrapperbase_8PyClical_9index_set_47__repr__;
4896 #endif
4897 static PyObject *__pyx_pw_8PyClical_9index_set_48__repr__(PyObject *__pyx_v_self) {
4898  PyObject *__pyx_r = 0;
4899  __Pyx_RefNannyDeclarations
4900  __Pyx_RefNannySetupContext("__repr__ (wrapper)", 0);
4901  __pyx_r = __pyx_pf_8PyClical_9index_set_47__repr__(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_self));
4902 
4903  /* function exit code */
4904  __Pyx_RefNannyFinishContext();
4905  return __pyx_r;
4906 }
4907 
4908 static PyObject *__pyx_pf_8PyClical_9index_set_47__repr__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self) {
4909  PyObject *__pyx_r = NULL;
4910  __Pyx_RefNannyDeclarations
4911  PyObject *__pyx_t_1 = NULL;
4912  int __pyx_lineno = 0;
4913  const char *__pyx_filename = NULL;
4914  int __pyx_clineno = 0;
4915  __Pyx_RefNannySetupContext("__repr__", 0);
4916 
4917  /* "PyClical.pyx":391
4918  * 'index_set({1,2})'
4919  * """
4920  * return index_set_to_repr( self.unwrap() ).c_str() # <<<<<<<<<<<<<<
4921  *
4922  * def __str__(self):
4923  */
4924  __Pyx_XDECREF(__pyx_r);
4925  __pyx_t_1 = __Pyx_PyBytes_FromString(index_set_to_repr(__pyx_f_8PyClical_9index_set_unwrap(__pyx_v_self)).c_str()); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 391; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
4926  __Pyx_GOTREF(__pyx_t_1);
4927  __pyx_r = __pyx_t_1;
4928  __pyx_t_1 = 0;
4929  goto __pyx_L0;
4930 
4931  /* "PyClical.pyx":382
4932  * return self.instance.sign_of_square()
4933  *
4934  * def __repr__(self): # <<<<<<<<<<<<<<
4935  * """
4936  * The official string representation of self.
4937  */
4938 
4939  /* function exit code */
4940  __pyx_L1_error:;
4941  __Pyx_XDECREF(__pyx_t_1);
4942  __Pyx_AddTraceback("PyClical.index_set.__repr__", __pyx_clineno, __pyx_lineno, __pyx_filename);
4943  __pyx_r = NULL;
4944  __pyx_L0:;
4945  __Pyx_XGIVEREF(__pyx_r);
4946  __Pyx_RefNannyFinishContext();
4947  return __pyx_r;
4948 }
4949 
4950 /* "PyClical.pyx":393
4951  * return index_set_to_repr( self.unwrap() ).c_str()
4952  *
4953  * def __str__(self): # <<<<<<<<<<<<<<
4954  * """
4955  * The informal string representation of self.
4956  */
4957 
4958 /* Python wrapper */
4959 static PyObject *__pyx_pw_8PyClical_9index_set_50__str__(PyObject *__pyx_v_self); /*proto*/
4960 static char __pyx_doc_8PyClical_9index_set_49__str__[] = "\n The \342\200\234informal\342\200\235 string representation of self.\n\n >>> index_set({1,2}).__str__()\n '{1,2}'\n >>> str(index_set({1,2}))\n '{1,2}'\n ";
4961 #if CYTHON_COMPILING_IN_CPYTHON
4962 struct wrapperbase __pyx_wrapperbase_8PyClical_9index_set_49__str__;
4963 #endif
4964 static PyObject *__pyx_pw_8PyClical_9index_set_50__str__(PyObject *__pyx_v_self) {
4965  PyObject *__pyx_r = 0;
4966  __Pyx_RefNannyDeclarations
4967  __Pyx_RefNannySetupContext("__str__ (wrapper)", 0);
4968  __pyx_r = __pyx_pf_8PyClical_9index_set_49__str__(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_self));
4969 
4970  /* function exit code */
4971  __Pyx_RefNannyFinishContext();
4972  return __pyx_r;
4973 }
4974 
4975 static PyObject *__pyx_pf_8PyClical_9index_set_49__str__(struct __pyx_obj_8PyClical_index_set *__pyx_v_self) {
4976  PyObject *__pyx_r = NULL;
4977  __Pyx_RefNannyDeclarations
4978  PyObject *__pyx_t_1 = NULL;
4979  int __pyx_lineno = 0;
4980  const char *__pyx_filename = NULL;
4981  int __pyx_clineno = 0;
4982  __Pyx_RefNannySetupContext("__str__", 0);
4983 
4984  /* "PyClical.pyx":402
4985  * '{1,2}'
4986  * """
4987  * return index_set_to_str( self.unwrap() ).c_str() # <<<<<<<<<<<<<<
4988  *
4989  * def index_set_hidden_doctests():
4990  */
4991  __Pyx_XDECREF(__pyx_r);
4992  __pyx_t_1 = __Pyx_PyBytes_FromString(index_set_to_str(__pyx_f_8PyClical_9index_set_unwrap(__pyx_v_self)).c_str()); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 402; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
4993  __Pyx_GOTREF(__pyx_t_1);
4994  __pyx_r = __pyx_t_1;
4995  __pyx_t_1 = 0;
4996  goto __pyx_L0;
4997 
4998  /* "PyClical.pyx":393
4999  * return index_set_to_repr( self.unwrap() ).c_str()
5000  *
5001  * def __str__(self): # <<<<<<<<<<<<<<
5002  * """
5003  * The informal string representation of self.
5004  */
5005 
5006  /* function exit code */
5007  __pyx_L1_error:;
5008  __Pyx_XDECREF(__pyx_t_1);
5009  __Pyx_AddTraceback("PyClical.index_set.__str__", __pyx_clineno, __pyx_lineno, __pyx_filename);
5010  __pyx_r = NULL;
5011  __pyx_L0:;
5012  __Pyx_XGIVEREF(__pyx_r);
5013  __Pyx_RefNannyFinishContext();
5014  return __pyx_r;
5015 }
5016 
5017 /* "PyClical.pyx":404
5018  * return index_set_to_str( self.unwrap() ).c_str()
5019  *
5020  * def index_set_hidden_doctests(): # <<<<<<<<<<<<<<
5021  * """
5022  * Tests for functions that Doctest cannot see.
5023  */
5024 
5025 /* Python wrapper */
5026 static PyObject *__pyx_pw_8PyClical_1index_set_hidden_doctests(PyObject *__pyx_self, CYTHON_UNUSED PyObject *unused); /*proto*/
5027 static char __pyx_doc_8PyClical_index_set_hidden_doctests[] = "\n Tests for functions that Doctest cannot see.\n\n For index_set.__cinit__: Construct index_set.\n\n >>> print index_set(1)\n {1}\n >>> print index_set({1,2})\n {1,2}\n >>> print index_set(index_set({1,2}))\n {1,2}\n >>> print index_set({1,2})\n {1,2}\n >>> print index_set({1,2,1})\n {1,2}\n >>> print index_set({1,2,1})\n {1,2}\n >>> print index_set(\"\")\n {}\n >>> print index_set(\"{\")\n Traceback (most recent call last):\n ...\n ValueError: Cannot initialize index_set object from invalid string '{'.\n >>> print index_set(\"{1\")\n Traceback (most recent call last):\n ...\n ValueError: Cannot initialize index_set object from invalid string '{1'.\n >>> print index_set(\"{1,2,100}\")\n Traceback (most recent call last):\n ...\n ValueError: Cannot initialize index_set object from invalid string '{1,2,100}'.\n >>> print index_set({1,2,100})\n Traceback (most recent call last):\n ...\n IndexError: Cannot initialize index_set object from invalid set([1, 2, 100]).\n >>> print index_set([1,2])\n Traceback (most recent call last):\n ...\n TypeError: Cannot initialize index_set object from <type 'list'>.\n\n For index_set.__richcmp__: Compare two objects of class index_set.\n\n >>> index_set(1) == index_set({1})\n True\n >>> index_set({1}) != index_set({1})\n False\n >>> index_set({1}) != index_set({2})\n True\n >>> index_set({1}) == index_set({2})\n False\n >>> index_set({1}) < index_set({2})\n True\n >>> index_set({1}) <= index_set({2})\n True\n >>> index_set({1}) > index_set({2})\n False\n >>> index_set({1}) >= index_set({2})\n False\n >>> None == index_set({1,2})\n False\n >>> None != index_set({1,2})\n True\n >>> None < index_set({1,2})\n False\n >>> None <= index_set({1,2})\n False\n >>> None > index_set({1,2})\n False\n >>> None >= index_set({1,2})\n False\n >>> index_se""t({1,2}) == None\n False\n >>> index_set({1,2}) != None\n True\n >>> index_set({1,2}) < None\n False\n >>> index_set({1,2}) <= None\n False\n >>> index_set({1,2}) > None\n False\n >>> index_set({1,2}) >= None\n False\n ";
5028  static PyMethodDef __pyx_mdef_8PyClical_1index_set_hidden_doctests = {"index_set_hidden_doctests", (PyCFunction)__pyx_pw_8PyClical_1index_set_hidden_doctests, METH_NOARGS, __pyx_doc_8PyClical_index_set_hidden_doctests};
5029  static PyObject *__pyx_pw_8PyClical_1index_set_hidden_doctests(PyObject *__pyx_self, CYTHON_UNUSED PyObject *unused) {
5030  PyObject *__pyx_r = 0;
5031  __Pyx_RefNannyDeclarations
5032  __Pyx_RefNannySetupContext("index_set_hidden_doctests (wrapper)", 0);
5033  __pyx_r = __pyx_pf_8PyClical_index_set_hidden_doctests(__pyx_self);
5034 
5035  /* function exit code */
5036  __Pyx_RefNannyFinishContext();
5037  return __pyx_r;
5038  }
5039 
5040  static PyObject *__pyx_pf_8PyClical_index_set_hidden_doctests(CYTHON_UNUSED PyObject *__pyx_self) {
5041  PyObject *__pyx_r = NULL;
5042  __Pyx_RefNannyDeclarations
5043  __Pyx_RefNannySetupContext("index_set_hidden_doctests", 0);
5044 
5045  /* "PyClical.pyx":488
5046  * False
5047  * """
5048  * return # <<<<<<<<<<<<<<
5049  *
5050  * cpdef inline compare(lhs,rhs):
5051  */
5052  __Pyx_XDECREF(__pyx_r);
5053  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
5054  goto __pyx_L0;
5055 
5056  /* "PyClical.pyx":404
5057  * return index_set_to_str( self.unwrap() ).c_str()
5058  *
5059  * def index_set_hidden_doctests(): # <<<<<<<<<<<<<<
5060  * """
5061  * Tests for functions that Doctest cannot see.
5062  */
5063 
5064  /* function exit code */
5065  __pyx_L0:;
5066  __Pyx_XGIVEREF(__pyx_r);
5067  __Pyx_RefNannyFinishContext();
5068  return __pyx_r;
5069  }
5070 
5071  /* "PyClical.pyx":490
5072  * return
5073  *
5074  * cpdef inline compare(lhs,rhs): # <<<<<<<<<<<<<<
5075  * """
5076  * "lexicographic compare" eg. {3,4,5} is less than {3,7,8};
5077  */
5078 
5079  static PyObject *__pyx_pw_8PyClical_3compare(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
5080  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_compare(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs, CYTHON_UNUSED int __pyx_skip_dispatch) {
5081  PyObject *__pyx_r = NULL;
5082  __Pyx_RefNannyDeclarations
5083  PyObject *__pyx_t_1 = NULL;
5084  int __pyx_lineno = 0;
5085  const char *__pyx_filename = NULL;
5086  int __pyx_clineno = 0;
5087  __Pyx_RefNannySetupContext("compare", 0);
5088 
5089  /* "PyClical.pyx":500
5090  * 1
5091  * """
5092  * return glucat.compare( toIndexSet(lhs), toIndexSet(rhs) ) # <<<<<<<<<<<<<<
5093  *
5094  * cpdef inline min_neg(obj):
5095  */
5096  __Pyx_XDECREF(__pyx_r);
5097  __pyx_t_1 = __Pyx_PyInt_From_int(compare(__pyx_f_8PyClical_toIndexSet(__pyx_v_lhs), __pyx_f_8PyClical_toIndexSet(__pyx_v_rhs))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 500; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
5098  __Pyx_GOTREF(__pyx_t_1);
5099  __pyx_r = __pyx_t_1;
5100  __pyx_t_1 = 0;
5101  goto __pyx_L0;
5102 
5103  /* "PyClical.pyx":490
5104  * return
5105  *
5106  * cpdef inline compare(lhs,rhs): # <<<<<<<<<<<<<<
5107  * """
5108  * "lexicographic compare" eg. {3,4,5} is less than {3,7,8};
5109  */
5110 
5111  /* function exit code */
5112  __pyx_L1_error:;
5113  __Pyx_XDECREF(__pyx_t_1);
5114  __Pyx_AddTraceback("PyClical.compare", __pyx_clineno, __pyx_lineno, __pyx_filename);
5115  __pyx_r = 0;
5116  __pyx_L0:;
5117  __Pyx_XGIVEREF(__pyx_r);
5118  __Pyx_RefNannyFinishContext();
5119  return __pyx_r;
5120  }
5121 
5122  /* Python wrapper */
5123  static PyObject *__pyx_pw_8PyClical_3compare(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
5124  static char __pyx_doc_8PyClical_2compare[] = "\n \"lexicographic compare\" eg. {3,4,5} is less than {3,7,8};\n -1 if a<b, +1 if a>b, 0 if a==b.\n\n >>> compare(index_set({1,2}),index_set({-1,3}))\n -1\n >>> compare(index_set({-1,4}),index_set({-1,3}))\n 1\n ";
5125  static PyObject *__pyx_pw_8PyClical_3compare(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
5126  PyObject *__pyx_v_lhs = 0;
5127  PyObject *__pyx_v_rhs = 0;
5128  int __pyx_lineno = 0;
5129  const char *__pyx_filename = NULL;
5130  int __pyx_clineno = 0;
5131  PyObject *__pyx_r = 0;
5132  __Pyx_RefNannyDeclarations
5133  __Pyx_RefNannySetupContext("compare (wrapper)", 0);
5134  {
5135  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_lhs,&__pyx_n_s_rhs,0};
5136  PyObject* values[2] = {0,0};
5137  if (unlikely(__pyx_kwds)) {
5138  Py_ssize_t kw_args;
5139  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
5140  switch (pos_args) {
5141  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5142  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5143  case 0: break;
5144  default: goto __pyx_L5_argtuple_error;
5145  }
5146  kw_args = PyDict_Size(__pyx_kwds);
5147  switch (pos_args) {
5148  case 0:
5149  if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_lhs)) != 0)) kw_args--;
5150  else goto __pyx_L5_argtuple_error;
5151  case 1:
5152  if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_rhs)) != 0)) kw_args--;
5153  else {
5154  __Pyx_RaiseArgtupleInvalid("compare", 1, 2, 2, 1); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 490; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
5155  }
5156  }
5157  if (unlikely(kw_args > 0)) {
5158  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "compare") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 490; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
5159  }
5160  } else if (PyTuple_GET_SIZE(__pyx_args) != 2) {
5161  goto __pyx_L5_argtuple_error;
5162  } else {
5163  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5164  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5165  }
5166  __pyx_v_lhs = values[0];
5167  __pyx_v_rhs = values[1];
5168  }
5169  goto __pyx_L4_argument_unpacking_done;
5170  __pyx_L5_argtuple_error:;
5171  __Pyx_RaiseArgtupleInvalid("compare", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 490; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
5172  __pyx_L3_error:;
5173  __Pyx_AddTraceback("PyClical.compare", __pyx_clineno, __pyx_lineno, __pyx_filename);
5174  __Pyx_RefNannyFinishContext();
5175  return NULL;
5176  __pyx_L4_argument_unpacking_done:;
5177  __pyx_r = __pyx_pf_8PyClical_2compare(__pyx_self, __pyx_v_lhs, __pyx_v_rhs);
5178 
5179  /* function exit code */
5180  __Pyx_RefNannyFinishContext();
5181  return __pyx_r;
5182  }
5183 
5184  static PyObject *__pyx_pf_8PyClical_2compare(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs) {
5185  PyObject *__pyx_r = NULL;
5186  __Pyx_RefNannyDeclarations
5187  PyObject *__pyx_t_1 = NULL;
5188  int __pyx_lineno = 0;
5189  const char *__pyx_filename = NULL;
5190  int __pyx_clineno = 0;
5191  __Pyx_RefNannySetupContext("compare", 0);
5192  __Pyx_XDECREF(__pyx_r);
5193  __pyx_t_1 = __pyx_f_8PyClical_compare(__pyx_v_lhs, __pyx_v_rhs, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 490; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
5194  __Pyx_GOTREF(__pyx_t_1);
5195  __pyx_r = __pyx_t_1;
5196  __pyx_t_1 = 0;
5197  goto __pyx_L0;
5198 
5199  /* function exit code */
5200  __pyx_L1_error:;
5201  __Pyx_XDECREF(__pyx_t_1);
5202  __Pyx_AddTraceback("PyClical.compare", __pyx_clineno, __pyx_lineno, __pyx_filename);
5203  __pyx_r = NULL;
5204  __pyx_L0:;
5205  __Pyx_XGIVEREF(__pyx_r);
5206  __Pyx_RefNannyFinishContext();
5207  return __pyx_r;
5208  }
5209 
5210  /* "PyClical.pyx":502
5211  * return glucat.compare( toIndexSet(lhs), toIndexSet(rhs) )
5212  *
5213  * cpdef inline min_neg(obj): # <<<<<<<<<<<<<<
5214  * """
5215  * Minimum negative index, or 0 if none.
5216  */
5217 
5218  static PyObject *__pyx_pw_8PyClical_5min_neg(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
5219  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_min_neg(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
5220  PyObject *__pyx_r = NULL;
5221  __Pyx_RefNannyDeclarations
5222  PyObject *__pyx_t_1 = NULL;
5223  int __pyx_lineno = 0;
5224  const char *__pyx_filename = NULL;
5225  int __pyx_clineno = 0;
5226  __Pyx_RefNannySetupContext("min_neg", 0);
5227 
5228  /* "PyClical.pyx":509
5229  * 0
5230  * """
5231  * return glucat.min_neg( toIndexSet(obj) ) # <<<<<<<<<<<<<<
5232  *
5233  * cpdef inline max_pos(obj):
5234  */
5235  __Pyx_XDECREF(__pyx_r);
5236  __pyx_t_1 = __Pyx_PyInt_From_int(min_neg(__pyx_f_8PyClical_toIndexSet(__pyx_v_obj))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 509; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
5237  __Pyx_GOTREF(__pyx_t_1);
5238  __pyx_r = __pyx_t_1;
5239  __pyx_t_1 = 0;
5240  goto __pyx_L0;
5241 
5242  /* "PyClical.pyx":502
5243  * return glucat.compare( toIndexSet(lhs), toIndexSet(rhs) )
5244  *
5245  * cpdef inline min_neg(obj): # <<<<<<<<<<<<<<
5246  * """
5247  * Minimum negative index, or 0 if none.
5248  */
5249 
5250  /* function exit code */
5251  __pyx_L1_error:;
5252  __Pyx_XDECREF(__pyx_t_1);
5253  __Pyx_AddTraceback("PyClical.min_neg", __pyx_clineno, __pyx_lineno, __pyx_filename);
5254  __pyx_r = 0;
5255  __pyx_L0:;
5256  __Pyx_XGIVEREF(__pyx_r);
5257  __Pyx_RefNannyFinishContext();
5258  return __pyx_r;
5259  }
5260 
5261  /* Python wrapper */
5262  static PyObject *__pyx_pw_8PyClical_5min_neg(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
5263  static char __pyx_doc_8PyClical_4min_neg[] = "\n Minimum negative index, or 0 if none.\n\n >>> min_neg(index_set({1,2}))\n 0\n ";
5264  static PyObject *__pyx_pw_8PyClical_5min_neg(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
5265  PyObject *__pyx_r = 0;
5266  __Pyx_RefNannyDeclarations
5267  __Pyx_RefNannySetupContext("min_neg (wrapper)", 0);
5268  __pyx_r = __pyx_pf_8PyClical_4min_neg(__pyx_self, ((PyObject *)__pyx_v_obj));
5269 
5270  /* function exit code */
5271  __Pyx_RefNannyFinishContext();
5272  return __pyx_r;
5273  }
5274 
5275  static PyObject *__pyx_pf_8PyClical_4min_neg(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
5276  PyObject *__pyx_r = NULL;
5277  __Pyx_RefNannyDeclarations
5278  PyObject *__pyx_t_1 = NULL;
5279  int __pyx_lineno = 0;
5280  const char *__pyx_filename = NULL;
5281  int __pyx_clineno = 0;
5282  __Pyx_RefNannySetupContext("min_neg", 0);
5283  __Pyx_XDECREF(__pyx_r);
5284  __pyx_t_1 = __pyx_f_8PyClical_min_neg(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 502; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
5285  __Pyx_GOTREF(__pyx_t_1);
5286  __pyx_r = __pyx_t_1;
5287  __pyx_t_1 = 0;
5288  goto __pyx_L0;
5289 
5290  /* function exit code */
5291  __pyx_L1_error:;
5292  __Pyx_XDECREF(__pyx_t_1);
5293  __Pyx_AddTraceback("PyClical.min_neg", __pyx_clineno, __pyx_lineno, __pyx_filename);
5294  __pyx_r = NULL;
5295  __pyx_L0:;
5296  __Pyx_XGIVEREF(__pyx_r);
5297  __Pyx_RefNannyFinishContext();
5298  return __pyx_r;
5299  }
5300 
5301  /* "PyClical.pyx":511
5302  * return glucat.min_neg( toIndexSet(obj) )
5303  *
5304  * cpdef inline max_pos(obj): # <<<<<<<<<<<<<<
5305  * """
5306  * Maximum positive index, or 0 if none.
5307  */
5308 
5309  static PyObject *__pyx_pw_8PyClical_7max_pos(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
5310  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_max_pos(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
5311  PyObject *__pyx_r = NULL;
5312  __Pyx_RefNannyDeclarations
5313  PyObject *__pyx_t_1 = NULL;
5314  int __pyx_lineno = 0;
5315  const char *__pyx_filename = NULL;
5316  int __pyx_clineno = 0;
5317  __Pyx_RefNannySetupContext("max_pos", 0);
5318 
5319  /* "PyClical.pyx":518
5320  * 2
5321  * """
5322  * return glucat.max_pos( toIndexSet(obj) ) # <<<<<<<<<<<<<<
5323  *
5324  * cdef inline vector[scalar_t] list_to_vector(lst):
5325  */
5326  __Pyx_XDECREF(__pyx_r);
5327  __pyx_t_1 = __Pyx_PyInt_From_int(max_pos(__pyx_f_8PyClical_toIndexSet(__pyx_v_obj))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 518; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
5328  __Pyx_GOTREF(__pyx_t_1);
5329  __pyx_r = __pyx_t_1;
5330  __pyx_t_1 = 0;
5331  goto __pyx_L0;
5332 
5333  /* "PyClical.pyx":511
5334  * return glucat.min_neg( toIndexSet(obj) )
5335  *
5336  * cpdef inline max_pos(obj): # <<<<<<<<<<<<<<
5337  * """
5338  * Maximum positive index, or 0 if none.
5339  */
5340 
5341  /* function exit code */
5342  __pyx_L1_error:;
5343  __Pyx_XDECREF(__pyx_t_1);
5344  __Pyx_AddTraceback("PyClical.max_pos", __pyx_clineno, __pyx_lineno, __pyx_filename);
5345  __pyx_r = 0;
5346  __pyx_L0:;
5347  __Pyx_XGIVEREF(__pyx_r);
5348  __Pyx_RefNannyFinishContext();
5349  return __pyx_r;
5350  }
5351 
5352  /* Python wrapper */
5353  static PyObject *__pyx_pw_8PyClical_7max_pos(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
5354  static char __pyx_doc_8PyClical_6max_pos[] = "\n Maximum positive index, or 0 if none.\n\n >>> max_pos(index_set({1,2}))\n 2\n ";
5355  static PyObject *__pyx_pw_8PyClical_7max_pos(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
5356  PyObject *__pyx_r = 0;
5357  __Pyx_RefNannyDeclarations
5358  __Pyx_RefNannySetupContext("max_pos (wrapper)", 0);
5359  __pyx_r = __pyx_pf_8PyClical_6max_pos(__pyx_self, ((PyObject *)__pyx_v_obj));
5360 
5361  /* function exit code */
5362  __Pyx_RefNannyFinishContext();
5363  return __pyx_r;
5364  }
5365 
5366  static PyObject *__pyx_pf_8PyClical_6max_pos(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
5367  PyObject *__pyx_r = NULL;
5368  __Pyx_RefNannyDeclarations
5369  PyObject *__pyx_t_1 = NULL;
5370  int __pyx_lineno = 0;
5371  const char *__pyx_filename = NULL;
5372  int __pyx_clineno = 0;
5373  __Pyx_RefNannySetupContext("max_pos", 0);
5374  __Pyx_XDECREF(__pyx_r);
5375  __pyx_t_1 = __pyx_f_8PyClical_max_pos(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 511; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
5376  __Pyx_GOTREF(__pyx_t_1);
5377  __pyx_r = __pyx_t_1;
5378  __pyx_t_1 = 0;
5379  goto __pyx_L0;
5380 
5381  /* function exit code */
5382  __pyx_L1_error:;
5383  __Pyx_XDECREF(__pyx_t_1);
5384  __Pyx_AddTraceback("PyClical.max_pos", __pyx_clineno, __pyx_lineno, __pyx_filename);
5385  __pyx_r = NULL;
5386  __pyx_L0:;
5387  __Pyx_XGIVEREF(__pyx_r);
5388  __Pyx_RefNannyFinishContext();
5389  return __pyx_r;
5390  }
5391 
5392  /* "PyClical.pyx":520
5393  * return glucat.max_pos( toIndexSet(obj) )
5394  *
5395  * cdef inline vector[scalar_t] list_to_vector(lst): # <<<<<<<<<<<<<<
5396  * """
5397  * Create a C++ std:vector[scalar_t] from an iterable Python object.
5398  */
5399 
5400  static CYTHON_INLINE std::vector<scalar_t> __pyx_f_8PyClical_list_to_vector(PyObject *__pyx_v_lst) {
5401  std::vector<scalar_t> __pyx_v_v;
5402  PyObject *__pyx_v_s = NULL;
5403  std::vector<scalar_t> __pyx_r;
5404  __Pyx_RefNannyDeclarations
5405  PyObject *__pyx_t_1 = NULL;
5406  Py_ssize_t __pyx_t_2;
5407  PyObject *(*__pyx_t_3)(PyObject *);
5408  PyObject *__pyx_t_4 = NULL;
5409  scalar_t __pyx_t_5;
5410  int __pyx_lineno = 0;
5411  const char *__pyx_filename = NULL;
5412  int __pyx_clineno = 0;
5413  __Pyx_RefNannySetupContext("list_to_vector", 0);
5414 
5415  /* "PyClical.pyx":525
5416  * """
5417  * cdef vector[scalar_t] v
5418  * for s in lst: # <<<<<<<<<<<<<<
5419  * v.push_back(<scalar_t>s)
5420  * return v
5421  */
5422  if (likely(PyList_CheckExact(__pyx_v_lst)) || PyTuple_CheckExact(__pyx_v_lst)) {
5423  __pyx_t_1 = __pyx_v_lst; __Pyx_INCREF(__pyx_t_1); __pyx_t_2 = 0;
5424  __pyx_t_3 = NULL;
5425  } else {
5426  __pyx_t_2 = -1; __pyx_t_1 = PyObject_GetIter(__pyx_v_lst); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 525; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
5427  __Pyx_GOTREF(__pyx_t_1);
5428  __pyx_t_3 = Py_TYPE(__pyx_t_1)->tp_iternext; if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 525; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
5429  }
5430  for (;;) {
5431  if (likely(!__pyx_t_3)) {
5432  if (likely(PyList_CheckExact(__pyx_t_1))) {
5433  if (__pyx_t_2 >= PyList_GET_SIZE(__pyx_t_1)) break;
5434  #if CYTHON_COMPILING_IN_CPYTHON
5435  __pyx_t_4 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_4); __pyx_t_2++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 525; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
5436  #else
5437  __pyx_t_4 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 525; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
5438  __Pyx_GOTREF(__pyx_t_4);
5439  #endif
5440  } else {
5441  if (__pyx_t_2 >= PyTuple_GET_SIZE(__pyx_t_1)) break;
5442  #if CYTHON_COMPILING_IN_CPYTHON
5443  __pyx_t_4 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_4); __pyx_t_2++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 525; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
5444  #else
5445  __pyx_t_4 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 525; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
5446  __Pyx_GOTREF(__pyx_t_4);
5447  #endif
5448  }
5449  } else {
5450  __pyx_t_4 = __pyx_t_3(__pyx_t_1);
5451  if (unlikely(!__pyx_t_4)) {
5452  PyObject* exc_type = PyErr_Occurred();
5453  if (exc_type) {
5454  if (likely(exc_type == PyExc_StopIteration || PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
5455  else {__pyx_filename = __pyx_f[0]; __pyx_lineno = 525; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
5456  }
5457  break;
5458  }
5459  __Pyx_GOTREF(__pyx_t_4);
5460  }
5461  __Pyx_XDECREF_SET(__pyx_v_s, __pyx_t_4);
5462  __pyx_t_4 = 0;
5463 
5464  /* "PyClical.pyx":526
5465  * cdef vector[scalar_t] v
5466  * for s in lst:
5467  * v.push_back(<scalar_t>s) # <<<<<<<<<<<<<<
5468  * return v
5469  *
5470  */
5471  __pyx_t_5 = __pyx_PyFloat_AsDouble(__pyx_v_s); if (unlikely((__pyx_t_5 == (scalar_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 526; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
5472  try {
5473  __pyx_v_v.push_back(((scalar_t)__pyx_t_5));
5474  } catch(...) {
5475  __Pyx_CppExn2PyErr();
5476  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 526; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
5477  }
5478 
5479  /* "PyClical.pyx":525
5480  * """
5481  * cdef vector[scalar_t] v
5482  * for s in lst: # <<<<<<<<<<<<<<
5483  * v.push_back(<scalar_t>s)
5484  * return v
5485  */
5486  }
5487  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
5488 
5489  /* "PyClical.pyx":527
5490  * for s in lst:
5491  * v.push_back(<scalar_t>s)
5492  * return v # <<<<<<<<<<<<<<
5493  *
5494  * # Forward reference.
5495  */
5496  __pyx_r = __pyx_v_v;
5497  goto __pyx_L0;
5498 
5499  /* "PyClical.pyx":520
5500  * return glucat.max_pos( toIndexSet(obj) )
5501  *
5502  * cdef inline vector[scalar_t] list_to_vector(lst): # <<<<<<<<<<<<<<
5503  * """
5504  * Create a C++ std:vector[scalar_t] from an iterable Python object.
5505  */
5506 
5507  /* function exit code */
5508  __pyx_L1_error:;
5509  __Pyx_XDECREF(__pyx_t_1);
5510  __Pyx_XDECREF(__pyx_t_4);
5511  __Pyx_WriteUnraisable("PyClical.list_to_vector", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0);
5512  __pyx_L0:;
5513  __Pyx_XDECREF(__pyx_v_s);
5514  __Pyx_RefNannyFinishContext();
5515  return __pyx_r;
5516  }
5517 
5518  /* "PyClical.pyx":532
5519  * cdef class clifford
5520  *
5521  * cdef inline Clifford toClifford(obj): # <<<<<<<<<<<<<<
5522  * return clifford(obj).instance[0]
5523  *
5524  */
5525 
5526  static CYTHON_INLINE Clifford __pyx_f_8PyClical_toClifford(PyObject *__pyx_v_obj) {
5527  Clifford __pyx_r;
5528  __Pyx_RefNannyDeclarations
5529  PyObject *__pyx_t_1 = NULL;
5530  PyObject *__pyx_t_2 = NULL;
5531  int __pyx_lineno = 0;
5532  const char *__pyx_filename = NULL;
5533  int __pyx_clineno = 0;
5534  __Pyx_RefNannySetupContext("toClifford", 0);
5535 
5536  /* "PyClical.pyx":533
5537  *
5538  * cdef inline Clifford toClifford(obj):
5539  * return clifford(obj).instance[0] # <<<<<<<<<<<<<<
5540  *
5541  * cdef class clifford:
5542  */
5543  __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 533; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
5544  __Pyx_GOTREF(__pyx_t_1);
5545  __Pyx_INCREF(__pyx_v_obj);
5546  __Pyx_GIVEREF(__pyx_v_obj);
5547  PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_obj);
5548  __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 533; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
5549  __Pyx_GOTREF(__pyx_t_2);
5550  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
5551  __pyx_r = (((struct __pyx_obj_8PyClical_clifford *)__pyx_t_2)->instance[0]);
5552  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
5553  goto __pyx_L0;
5554 
5555  /* "PyClical.pyx":532
5556  * cdef class clifford
5557  *
5558  * cdef inline Clifford toClifford(obj): # <<<<<<<<<<<<<<
5559  * return clifford(obj).instance[0]
5560  *
5561  */
5562 
5563  /* function exit code */
5564  __pyx_L1_error:;
5565  __Pyx_XDECREF(__pyx_t_1);
5566  __Pyx_XDECREF(__pyx_t_2);
5567  __Pyx_WriteUnraisable("PyClical.toClifford", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0);
5568  __pyx_L0:;
5569  __Pyx_RefNannyFinishContext();
5570  return __pyx_r;
5571  }
5572 
5573  /* "PyClical.pyx":541
5574  * cdef Clifford *instance # Wrapped instance of C++ class Clifford.
5575  *
5576  * cdef inline wrap(clifford self, Clifford other): # <<<<<<<<<<<<<<
5577  * """
5578  * Wrap an instance of the C++ class Clifford.
5579  */
5580 
5581  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_8clifford_wrap(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, Clifford __pyx_v_other) {
5582  PyObject *__pyx_r = NULL;
5583  __Pyx_RefNannyDeclarations
5584  __Pyx_RefNannySetupContext("wrap", 0);
5585 
5586  /* "PyClical.pyx":545
5587  * Wrap an instance of the C++ class Clifford.
5588  * """
5589  * self.instance[0] = other # <<<<<<<<<<<<<<
5590  * return self
5591  *
5592  */
5593  (__pyx_v_self->instance[0]) = __pyx_v_other;
5594 
5595  /* "PyClical.pyx":546
5596  * """
5597  * self.instance[0] = other
5598  * return self # <<<<<<<<<<<<<<
5599  *
5600  * cdef inline Clifford unwrap(clifford self):
5601  */
5602  __Pyx_XDECREF(__pyx_r);
5603  __Pyx_INCREF(((PyObject *)__pyx_v_self));
5604  __pyx_r = ((PyObject *)__pyx_v_self);
5605  goto __pyx_L0;
5606 
5607  /* "PyClical.pyx":541
5608  * cdef Clifford *instance # Wrapped instance of C++ class Clifford.
5609  *
5610  * cdef inline wrap(clifford self, Clifford other): # <<<<<<<<<<<<<<
5611  * """
5612  * Wrap an instance of the C++ class Clifford.
5613  */
5614 
5615  /* function exit code */
5616  __pyx_L0:;
5617  __Pyx_XGIVEREF(__pyx_r);
5618  __Pyx_RefNannyFinishContext();
5619  return __pyx_r;
5620  }
5621 
5622  /* "PyClical.pyx":548
5623  * return self
5624  *
5625  * cdef inline Clifford unwrap(clifford self): # <<<<<<<<<<<<<<
5626  * """
5627  * Return the wrapped C++ Clifford instance.
5628  */
5629 
5630  static CYTHON_INLINE Clifford __pyx_f_8PyClical_8clifford_unwrap(struct __pyx_obj_8PyClical_clifford *__pyx_v_self) {
5631  Clifford __pyx_r;
5632  __Pyx_RefNannyDeclarations
5633  __Pyx_RefNannySetupContext("unwrap", 0);
5634 
5635  /* "PyClical.pyx":552
5636  * Return the wrapped C++ Clifford instance.
5637  * """
5638  * return self.instance[0] # <<<<<<<<<<<<<<
5639  *
5640  * cpdef copy(clifford self):
5641  */
5642  __pyx_r = (__pyx_v_self->instance[0]);
5643  goto __pyx_L0;
5644 
5645  /* "PyClical.pyx":548
5646  * return self
5647  *
5648  * cdef inline Clifford unwrap(clifford self): # <<<<<<<<<<<<<<
5649  * """
5650  * Return the wrapped C++ Clifford instance.
5651  */
5652 
5653  /* function exit code */
5654  __pyx_L0:;
5655  __Pyx_RefNannyFinishContext();
5656  return __pyx_r;
5657  }
5658 
5659  /* "PyClical.pyx":554
5660  * return self.instance[0]
5661  *
5662  * cpdef copy(clifford self): # <<<<<<<<<<<<<<
5663  * """
5664  * Copy this clifford object.
5665  */
5666 
5667  static PyObject *__pyx_pw_8PyClical_8clifford_1copy(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
5668  static PyObject *__pyx_f_8PyClical_8clifford_copy(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, int __pyx_skip_dispatch) {
5669  PyObject *__pyx_r = NULL;
5670  __Pyx_RefNannyDeclarations
5671  PyObject *__pyx_t_1 = NULL;
5672  PyObject *__pyx_t_2 = NULL;
5673  PyObject *__pyx_t_3 = NULL;
5674  PyObject *__pyx_t_4 = NULL;
5675  int __pyx_lineno = 0;
5676  const char *__pyx_filename = NULL;
5677  int __pyx_clineno = 0;
5678  __Pyx_RefNannySetupContext("copy", 0);
5679  /* Check if called by wrapper */
5680  if (unlikely(__pyx_skip_dispatch)) ;
5681  /* Check if overridden in Python */
5682  else if (unlikely(Py_TYPE(((PyObject *)__pyx_v_self))->tp_dictoffset != 0)) {
5683  __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_copy); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 554; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
5684  __Pyx_GOTREF(__pyx_t_1);
5685  if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)__pyx_pw_8PyClical_8clifford_1copy)) {
5686  __Pyx_XDECREF(__pyx_r);
5687  __Pyx_INCREF(__pyx_t_1);
5688  __pyx_t_3 = __pyx_t_1; __pyx_t_4 = NULL;
5689  if (CYTHON_COMPILING_IN_CPYTHON && unlikely(PyMethod_Check(__pyx_t_3))) {
5690  __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
5691  if (likely(__pyx_t_4)) {
5692  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
5693  __Pyx_INCREF(__pyx_t_4);
5694  __Pyx_INCREF(function);
5695  __Pyx_DECREF_SET(__pyx_t_3, function);
5696  }
5697  }
5698  if (__pyx_t_4) {
5699  __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 554; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
5700  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
5701  } else {
5702  __pyx_t_2 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 554; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
5703  }
5704  __Pyx_GOTREF(__pyx_t_2);
5705  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
5706  __pyx_r = __pyx_t_2;
5707  __pyx_t_2 = 0;
5708  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
5709  goto __pyx_L0;
5710  }
5711  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
5712  }
5713 
5714  /* "PyClical.pyx":561
5715  * {2}
5716  * """
5717  * return clifford(self) # <<<<<<<<<<<<<<
5718  *
5719  * def __cinit__(self, other = 0, ixt = None):
5720  */
5721  __Pyx_XDECREF(__pyx_r);
5722  __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 561; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
5723  __Pyx_GOTREF(__pyx_t_1);
5724  __Pyx_INCREF(((PyObject *)__pyx_v_self));
5725  __Pyx_GIVEREF(((PyObject *)__pyx_v_self));
5726  PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self));
5727  __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 561; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
5728  __Pyx_GOTREF(__pyx_t_2);
5729  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
5730  __pyx_r = __pyx_t_2;
5731  __pyx_t_2 = 0;
5732  goto __pyx_L0;
5733 
5734  /* "PyClical.pyx":554
5735  * return self.instance[0]
5736  *
5737  * cpdef copy(clifford self): # <<<<<<<<<<<<<<
5738  * """
5739  * Copy this clifford object.
5740  */
5741 
5742  /* function exit code */
5743  __pyx_L1_error:;
5744  __Pyx_XDECREF(__pyx_t_1);
5745  __Pyx_XDECREF(__pyx_t_2);
5746  __Pyx_XDECREF(__pyx_t_3);
5747  __Pyx_XDECREF(__pyx_t_4);
5748  __Pyx_AddTraceback("PyClical.clifford.copy", __pyx_clineno, __pyx_lineno, __pyx_filename);
5749  __pyx_r = 0;
5750  __pyx_L0:;
5751  __Pyx_XGIVEREF(__pyx_r);
5752  __Pyx_RefNannyFinishContext();
5753  return __pyx_r;
5754  }
5755 
5756  /* Python wrapper */
5757  static PyObject *__pyx_pw_8PyClical_8clifford_1copy(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
5758  static char __pyx_doc_8PyClical_8clifford_copy[] = "\n Copy this clifford object.\n\n >>> x=clifford(\"1{2}\"); y=x.copy(); print y\n {2}\n ";
5759  static PyObject *__pyx_pw_8PyClical_8clifford_1copy(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
5760  PyObject *__pyx_r = 0;
5761  __Pyx_RefNannyDeclarations
5762  __Pyx_RefNannySetupContext("copy (wrapper)", 0);
5763  __pyx_r = __pyx_pf_8PyClical_8clifford_copy(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self));
5764 
5765  /* function exit code */
5766  __Pyx_RefNannyFinishContext();
5767  return __pyx_r;
5768  }
5769 
5770  static PyObject *__pyx_pf_8PyClical_8clifford_copy(struct __pyx_obj_8PyClical_clifford *__pyx_v_self) {
5771  PyObject *__pyx_r = NULL;
5772  __Pyx_RefNannyDeclarations
5773  PyObject *__pyx_t_1 = NULL;
5774  int __pyx_lineno = 0;
5775  const char *__pyx_filename = NULL;
5776  int __pyx_clineno = 0;
5777  __Pyx_RefNannySetupContext("copy", 0);
5778  __Pyx_XDECREF(__pyx_r);
5779  __pyx_t_1 = __pyx_f_8PyClical_8clifford_copy(__pyx_v_self, 1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 554; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
5780  __Pyx_GOTREF(__pyx_t_1);
5781  __pyx_r = __pyx_t_1;
5782  __pyx_t_1 = 0;
5783  goto __pyx_L0;
5784 
5785  /* function exit code */
5786  __pyx_L1_error:;
5787  __Pyx_XDECREF(__pyx_t_1);
5788  __Pyx_AddTraceback("PyClical.clifford.copy", __pyx_clineno, __pyx_lineno, __pyx_filename);
5789  __pyx_r = NULL;
5790  __pyx_L0:;
5791  __Pyx_XGIVEREF(__pyx_r);
5792  __Pyx_RefNannyFinishContext();
5793  return __pyx_r;
5794  }
5795 
5796  /* "PyClical.pyx":563
5797  * return clifford(self)
5798  *
5799  * def __cinit__(self, other = 0, ixt = None): # <<<<<<<<<<<<<<
5800  * """
5801  * Construct an object of type clifford.
5802  */
5803 
5804  /* Python wrapper */
5805  static int __pyx_pw_8PyClical_8clifford_3__cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
5806  static int __pyx_pw_8PyClical_8clifford_3__cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
5807  PyObject *__pyx_v_other = 0;
5808  PyObject *__pyx_v_ixt = 0;
5809  int __pyx_lineno = 0;
5810  const char *__pyx_filename = NULL;
5811  int __pyx_clineno = 0;
5812  int __pyx_r;
5813  __Pyx_RefNannyDeclarations
5814  __Pyx_RefNannySetupContext("__cinit__ (wrapper)", 0);
5815  {
5816  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_other,&__pyx_n_s_ixt,0};
5817  PyObject* values[2] = {0,0};
5818  values[0] = ((PyObject *)__pyx_int_0);
5819  values[1] = ((PyObject *)Py_None);
5820  if (unlikely(__pyx_kwds)) {
5821  Py_ssize_t kw_args;
5822  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
5823  switch (pos_args) {
5824  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5825  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5826  case 0: break;
5827  default: goto __pyx_L5_argtuple_error;
5828  }
5829  kw_args = PyDict_Size(__pyx_kwds);
5830  switch (pos_args) {
5831  case 0:
5832  if (kw_args > 0) {
5833  PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_other);
5834  if (value) { values[0] = value; kw_args--; }
5835  }
5836  case 1:
5837  if (kw_args > 0) {
5838  PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ixt);
5839  if (value) { values[1] = value; kw_args--; }
5840  }
5841  }
5842  if (unlikely(kw_args > 0)) {
5843  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 563; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
5844  }
5845  } else {
5846  switch (PyTuple_GET_SIZE(__pyx_args)) {
5847  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5848  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5849  case 0: break;
5850  default: goto __pyx_L5_argtuple_error;
5851  }
5852  }
5853  __pyx_v_other = values[0];
5854  __pyx_v_ixt = values[1];
5855  }
5856  goto __pyx_L4_argument_unpacking_done;
5857  __pyx_L5_argtuple_error:;
5858  __Pyx_RaiseArgtupleInvalid("__cinit__", 0, 0, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 563; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
5859  __pyx_L3_error:;
5860  __Pyx_AddTraceback("PyClical.clifford.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
5861  __Pyx_RefNannyFinishContext();
5862  return -1;
5863  __pyx_L4_argument_unpacking_done:;
5864  __pyx_r = __pyx_pf_8PyClical_8clifford_2__cinit__(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self), __pyx_v_other, __pyx_v_ixt);
5865 
5866  /* function exit code */
5867  __Pyx_RefNannyFinishContext();
5868  return __pyx_r;
5869  }
5870 
5871  static int __pyx_pf_8PyClical_8clifford_2__cinit__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_other, PyObject *__pyx_v_ixt) {
5872  PyObject *__pyx_v_error_msg_prefix = NULL;
5873  PyObject *__pyx_v_err = NULL;
5874  int __pyx_r;
5875  __Pyx_RefNannyDeclarations
5876  int __pyx_t_1;
5877  int __pyx_t_2;
5878  PyObject *__pyx_t_3 = NULL;
5879  PyObject *__pyx_t_4 = NULL;
5880  PyObject *__pyx_t_5 = NULL;
5881  Clifford *__pyx_t_6;
5882  PyObject *__pyx_t_7 = NULL;
5883  PyObject *__pyx_t_8 = NULL;
5884  scalar_t __pyx_t_9;
5885  PyObject *__pyx_t_10 = NULL;
5886  PyObject *__pyx_t_11 = NULL;
5887  PyObject *__pyx_t_12 = NULL;
5888  char *__pyx_t_13;
5889  int __pyx_t_14;
5890  PyObject *__pyx_t_15 = NULL;
5891  PyObject *__pyx_t_16 = NULL;
5892  PyObject *__pyx_t_17 = NULL;
5893  PyObject *__pyx_t_18 = NULL;
5894  int __pyx_lineno = 0;
5895  const char *__pyx_filename = NULL;
5896  int __pyx_clineno = 0;
5897  __Pyx_RefNannySetupContext("__cinit__", 0);
5898 
5899  /* "PyClical.pyx":588
5900  * 2{1}+3{2}
5901  * """
5902  * error_msg_prefix = "Cannot initialize clifford object from" # <<<<<<<<<<<<<<
5903  * if ixt is None:
5904  * try:
5905  */
5906  __Pyx_INCREF(__pyx_kp_s_Cannot_initialize_clifford_objec);
5907  __pyx_v_error_msg_prefix = __pyx_kp_s_Cannot_initialize_clifford_objec;
5908 
5909  /* "PyClical.pyx":589
5910  * """
5911  * error_msg_prefix = "Cannot initialize clifford object from"
5912  * if ixt is None: # <<<<<<<<<<<<<<
5913  * try:
5914  * if isinstance(other, clifford):
5915  */
5916  __pyx_t_1 = (__pyx_v_ixt == Py_None);
5917  __pyx_t_2 = (__pyx_t_1 != 0);
5918  if (__pyx_t_2) {
5919 
5920  /* "PyClical.pyx":590
5921  * error_msg_prefix = "Cannot initialize clifford object from"
5922  * if ixt is None:
5923  * try: # <<<<<<<<<<<<<<
5924  * if isinstance(other, clifford):
5925  * self.instance = new Clifford((<clifford>other).unwrap())
5926  */
5927  {
5928  __Pyx_ExceptionSave(&__pyx_t_3, &__pyx_t_4, &__pyx_t_5);
5929  __Pyx_XGOTREF(__pyx_t_3);
5930  __Pyx_XGOTREF(__pyx_t_4);
5931  __Pyx_XGOTREF(__pyx_t_5);
5932  /*try:*/ {
5933 
5934  /* "PyClical.pyx":591
5935  * if ixt is None:
5936  * try:
5937  * if isinstance(other, clifford): # <<<<<<<<<<<<<<
5938  * self.instance = new Clifford((<clifford>other).unwrap())
5939  * elif isinstance(other, index_set):
5940  */
5941  __pyx_t_2 = __Pyx_TypeCheck(__pyx_v_other, __pyx_ptype_8PyClical_clifford);
5942  __pyx_t_1 = (__pyx_t_2 != 0);
5943  if (__pyx_t_1) {
5944 
5945  /* "PyClical.pyx":592
5946  * try:
5947  * if isinstance(other, clifford):
5948  * self.instance = new Clifford((<clifford>other).unwrap()) # <<<<<<<<<<<<<<
5949  * elif isinstance(other, index_set):
5950  * self.instance = new Clifford((<index_set>other).unwrap(), <scalar_t>1.0)
5951  */
5952  try {
5953  __pyx_t_6 = new Clifford(__pyx_f_8PyClical_8clifford_unwrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_other)));
5954  } catch(...) {
5955  __Pyx_CppExn2PyErr();
5956  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 592; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
5957  }
5958  __pyx_v_self->instance = __pyx_t_6;
5959 
5960  /* "PyClical.pyx":591
5961  * if ixt is None:
5962  * try:
5963  * if isinstance(other, clifford): # <<<<<<<<<<<<<<
5964  * self.instance = new Clifford((<clifford>other).unwrap())
5965  * elif isinstance(other, index_set):
5966  */
5967  goto __pyx_L12;
5968  }
5969 
5970  /* "PyClical.pyx":593
5971  * if isinstance(other, clifford):
5972  * self.instance = new Clifford((<clifford>other).unwrap())
5973  * elif isinstance(other, index_set): # <<<<<<<<<<<<<<
5974  * self.instance = new Clifford((<index_set>other).unwrap(), <scalar_t>1.0)
5975  * elif isinstance(other, numbers.Real):
5976  */
5977  __pyx_t_1 = __Pyx_TypeCheck(__pyx_v_other, __pyx_ptype_8PyClical_index_set);
5978  __pyx_t_2 = (__pyx_t_1 != 0);
5979  if (__pyx_t_2) {
5980 
5981  /* "PyClical.pyx":594
5982  * self.instance = new Clifford((<clifford>other).unwrap())
5983  * elif isinstance(other, index_set):
5984  * self.instance = new Clifford((<index_set>other).unwrap(), <scalar_t>1.0) # <<<<<<<<<<<<<<
5985  * elif isinstance(other, numbers.Real):
5986  * self.instance = new Clifford(<scalar_t>other)
5987  */
5988  try {
5989  __pyx_t_6 = new Clifford(__pyx_f_8PyClical_9index_set_unwrap(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_other)), ((scalar_t)1.0));
5990  } catch(...) {
5991  __Pyx_CppExn2PyErr();
5992  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 594; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
5993  }
5994  __pyx_v_self->instance = __pyx_t_6;
5995 
5996  /* "PyClical.pyx":593
5997  * if isinstance(other, clifford):
5998  * self.instance = new Clifford((<clifford>other).unwrap())
5999  * elif isinstance(other, index_set): # <<<<<<<<<<<<<<
6000  * self.instance = new Clifford((<index_set>other).unwrap(), <scalar_t>1.0)
6001  * elif isinstance(other, numbers.Real):
6002  */
6003  goto __pyx_L12;
6004  }
6005 
6006  /* "PyClical.pyx":595
6007  * elif isinstance(other, index_set):
6008  * self.instance = new Clifford((<index_set>other).unwrap(), <scalar_t>1.0)
6009  * elif isinstance(other, numbers.Real): # <<<<<<<<<<<<<<
6010  * self.instance = new Clifford(<scalar_t>other)
6011  * elif isinstance(other, str):
6012  */
6013  __pyx_t_7 = __Pyx_GetModuleGlobalName(__pyx_n_s_numbers); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 595; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
6014  __Pyx_GOTREF(__pyx_t_7);
6015  __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_Real); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 595; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
6016  __Pyx_GOTREF(__pyx_t_8);
6017  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
6018  __pyx_t_2 = PyObject_IsInstance(__pyx_v_other, __pyx_t_8); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 595; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
6019  __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
6020  __pyx_t_1 = (__pyx_t_2 != 0);
6021  if (__pyx_t_1) {
6022 
6023  /* "PyClical.pyx":596
6024  * self.instance = new Clifford((<index_set>other).unwrap(), <scalar_t>1.0)
6025  * elif isinstance(other, numbers.Real):
6026  * self.instance = new Clifford(<scalar_t>other) # <<<<<<<<<<<<<<
6027  * elif isinstance(other, str):
6028  * try:
6029  */
6030  __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_v_other); if (unlikely((__pyx_t_9 == (scalar_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 596; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
6031  try {
6032  __pyx_t_6 = new Clifford(((scalar_t)__pyx_t_9));
6033  } catch(...) {
6034  __Pyx_CppExn2PyErr();
6035  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 596; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
6036  }
6037  __pyx_v_self->instance = __pyx_t_6;
6038 
6039  /* "PyClical.pyx":595
6040  * elif isinstance(other, index_set):
6041  * self.instance = new Clifford((<index_set>other).unwrap(), <scalar_t>1.0)
6042  * elif isinstance(other, numbers.Real): # <<<<<<<<<<<<<<
6043  * self.instance = new Clifford(<scalar_t>other)
6044  * elif isinstance(other, str):
6045  */
6046  goto __pyx_L12;
6047  }
6048 
6049  /* "PyClical.pyx":597
6050  * elif isinstance(other, numbers.Real):
6051  * self.instance = new Clifford(<scalar_t>other)
6052  * elif isinstance(other, str): # <<<<<<<<<<<<<<
6053  * try:
6054  * self.instance = new Clifford(<char *>other)
6055  */
6056  __pyx_t_1 = PyString_Check(__pyx_v_other);
6057  __pyx_t_2 = (__pyx_t_1 != 0);
6058  if (__pyx_t_2) {
6059 
6060  /* "PyClical.pyx":598
6061  * self.instance = new Clifford(<scalar_t>other)
6062  * elif isinstance(other, str):
6063  * try: # <<<<<<<<<<<<<<
6064  * self.instance = new Clifford(<char *>other)
6065  * except RuntimeError:
6066  */
6067  {
6068  __Pyx_ExceptionSave(&__pyx_t_10, &__pyx_t_11, &__pyx_t_12);
6069  __Pyx_XGOTREF(__pyx_t_10);
6070  __Pyx_XGOTREF(__pyx_t_11);
6071  __Pyx_XGOTREF(__pyx_t_12);
6072  /*try:*/ {
6073 
6074  /* "PyClical.pyx":599
6075  * elif isinstance(other, str):
6076  * try:
6077  * self.instance = new Clifford(<char *>other) # <<<<<<<<<<<<<<
6078  * except RuntimeError:
6079  * raise ValueError(error_msg_prefix + " invalid string " + repr(other) + ".")
6080  */
6081  __pyx_t_13 = __Pyx_PyObject_AsString(__pyx_v_other); if (unlikely((!__pyx_t_13) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 599; __pyx_clineno = __LINE__; goto __pyx_L13_error;}
6082  try {
6083  __pyx_t_6 = new Clifford(((char *)__pyx_t_13));
6084  } catch(...) {
6085  __Pyx_CppExn2PyErr();
6086  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 599; __pyx_clineno = __LINE__; goto __pyx_L13_error;}
6087  }
6088  __pyx_v_self->instance = __pyx_t_6;
6089 
6090  /* "PyClical.pyx":598
6091  * self.instance = new Clifford(<scalar_t>other)
6092  * elif isinstance(other, str):
6093  * try: # <<<<<<<<<<<<<<
6094  * self.instance = new Clifford(<char *>other)
6095  * except RuntimeError:
6096  */
6097  }
6098  __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0;
6099  __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0;
6100  __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0;
6101  goto __pyx_L20_try_end;
6102  __pyx_L13_error:;
6103  __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
6104  __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
6105 
6106  /* "PyClical.pyx":600
6107  * try:
6108  * self.instance = new Clifford(<char *>other)
6109  * except RuntimeError: # <<<<<<<<<<<<<<
6110  * raise ValueError(error_msg_prefix + " invalid string " + repr(other) + ".")
6111  * else:
6112  */
6113  __pyx_t_14 = PyErr_ExceptionMatches(__pyx_builtin_RuntimeError);
6114  if (__pyx_t_14) {
6115  __Pyx_AddTraceback("PyClical.clifford.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6116  if (__Pyx_GetException(&__pyx_t_8, &__pyx_t_7, &__pyx_t_15) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 600; __pyx_clineno = __LINE__; goto __pyx_L15_except_error;}
6117  __Pyx_GOTREF(__pyx_t_8);
6118  __Pyx_GOTREF(__pyx_t_7);
6119  __Pyx_GOTREF(__pyx_t_15);
6120 
6121  /* "PyClical.pyx":601
6122  * self.instance = new Clifford(<char *>other)
6123  * except RuntimeError:
6124  * raise ValueError(error_msg_prefix + " invalid string " + repr(other) + ".") # <<<<<<<<<<<<<<
6125  * else:
6126  * raise TypeError(error_msg_prefix + " " + str(type(other)) + ".")
6127  */
6128  __pyx_t_16 = PyNumber_Add(__pyx_v_error_msg_prefix, __pyx_kp_s_invalid_string); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 601; __pyx_clineno = __LINE__; goto __pyx_L15_except_error;}
6129  __Pyx_GOTREF(__pyx_t_16);
6130  __pyx_t_17 = PyObject_Repr(__pyx_v_other); if (unlikely(!__pyx_t_17)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 601; __pyx_clineno = __LINE__; goto __pyx_L15_except_error;}
6131  __Pyx_GOTREF(__pyx_t_17);
6132  __pyx_t_18 = PyNumber_Add(__pyx_t_16, __pyx_t_17); if (unlikely(!__pyx_t_18)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 601; __pyx_clineno = __LINE__; goto __pyx_L15_except_error;}
6133  __Pyx_GOTREF(__pyx_t_18);
6134  __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
6135  __Pyx_DECREF(__pyx_t_17); __pyx_t_17 = 0;
6136  __pyx_t_17 = PyNumber_Add(__pyx_t_18, __pyx_kp_s_); if (unlikely(!__pyx_t_17)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 601; __pyx_clineno = __LINE__; goto __pyx_L15_except_error;}
6137  __Pyx_GOTREF(__pyx_t_17);
6138  __Pyx_DECREF(__pyx_t_18); __pyx_t_18 = 0;
6139  __pyx_t_18 = PyTuple_New(1); if (unlikely(!__pyx_t_18)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 601; __pyx_clineno = __LINE__; goto __pyx_L15_except_error;}
6140  __Pyx_GOTREF(__pyx_t_18);
6141  __Pyx_GIVEREF(__pyx_t_17);
6142  PyTuple_SET_ITEM(__pyx_t_18, 0, __pyx_t_17);
6143  __pyx_t_17 = 0;
6144  __pyx_t_17 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_t_18, NULL); if (unlikely(!__pyx_t_17)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 601; __pyx_clineno = __LINE__; goto __pyx_L15_except_error;}
6145  __Pyx_GOTREF(__pyx_t_17);
6146  __Pyx_DECREF(__pyx_t_18); __pyx_t_18 = 0;
6147  __Pyx_Raise(__pyx_t_17, 0, 0, 0);
6148  __Pyx_DECREF(__pyx_t_17); __pyx_t_17 = 0;
6149  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 601; __pyx_clineno = __LINE__; goto __pyx_L15_except_error;}
6150  }
6151  goto __pyx_L15_except_error;
6152  __pyx_L15_except_error:;
6153 
6154  /* "PyClical.pyx":598
6155  * self.instance = new Clifford(<scalar_t>other)
6156  * elif isinstance(other, str):
6157  * try: # <<<<<<<<<<<<<<
6158  * self.instance = new Clifford(<char *>other)
6159  * except RuntimeError:
6160  */
6161  __Pyx_XGIVEREF(__pyx_t_10);
6162  __Pyx_XGIVEREF(__pyx_t_11);
6163  __Pyx_XGIVEREF(__pyx_t_12);
6164  __Pyx_ExceptionReset(__pyx_t_10, __pyx_t_11, __pyx_t_12);
6165  goto __pyx_L4_error;
6166  __pyx_L20_try_end:;
6167  }
6168 
6169  /* "PyClical.pyx":597
6170  * elif isinstance(other, numbers.Real):
6171  * self.instance = new Clifford(<scalar_t>other)
6172  * elif isinstance(other, str): # <<<<<<<<<<<<<<
6173  * try:
6174  * self.instance = new Clifford(<char *>other)
6175  */
6176  goto __pyx_L12;
6177  }
6178 
6179  /* "PyClical.pyx":603
6180  * raise ValueError(error_msg_prefix + " invalid string " + repr(other) + ".")
6181  * else:
6182  * raise TypeError(error_msg_prefix + " " + str(type(other)) + ".") # <<<<<<<<<<<<<<
6183  * except RuntimeError as err:
6184  * raise ValueError(error_msg_prefix + " " + str(type(other))
6185  */
6186  /*else*/ {
6187  __pyx_t_15 = PyNumber_Add(__pyx_v_error_msg_prefix, __pyx_kp_s__2); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 603; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
6188  __Pyx_GOTREF(__pyx_t_15);
6189  __pyx_t_7 = PyTuple_New(1); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 603; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
6190  __Pyx_GOTREF(__pyx_t_7);
6191  __Pyx_INCREF(((PyObject *)Py_TYPE(__pyx_v_other)));
6192  __Pyx_GIVEREF(((PyObject *)Py_TYPE(__pyx_v_other)));
6193  PyTuple_SET_ITEM(__pyx_t_7, 0, ((PyObject *)Py_TYPE(__pyx_v_other)));
6194  __pyx_t_8 = __Pyx_PyObject_Call(((PyObject *)(&PyString_Type)), __pyx_t_7, NULL); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 603; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
6195  __Pyx_GOTREF(__pyx_t_8);
6196  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
6197  __pyx_t_7 = PyNumber_Add(__pyx_t_15, __pyx_t_8); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 603; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
6198  __Pyx_GOTREF(__pyx_t_7);
6199  __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0;
6200  __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
6201  __pyx_t_8 = PyNumber_Add(__pyx_t_7, __pyx_kp_s_); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 603; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
6202  __Pyx_GOTREF(__pyx_t_8);
6203  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
6204  __pyx_t_7 = PyTuple_New(1); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 603; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
6205  __Pyx_GOTREF(__pyx_t_7);
6206  __Pyx_GIVEREF(__pyx_t_8);
6207  PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_8);
6208  __pyx_t_8 = 0;
6209  __pyx_t_8 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_t_7, NULL); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 603; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
6210  __Pyx_GOTREF(__pyx_t_8);
6211  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
6212  __Pyx_Raise(__pyx_t_8, 0, 0, 0);
6213  __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
6214  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 603; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
6215  }
6216  __pyx_L12:;
6217 
6218  /* "PyClical.pyx":590
6219  * error_msg_prefix = "Cannot initialize clifford object from"
6220  * if ixt is None:
6221  * try: # <<<<<<<<<<<<<<
6222  * if isinstance(other, clifford):
6223  * self.instance = new Clifford((<clifford>other).unwrap())
6224  */
6225  }
6226  __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
6227  __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
6228  __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
6229  goto __pyx_L11_try_end;
6230  __pyx_L4_error:;
6231  __Pyx_XDECREF(__pyx_t_16); __pyx_t_16 = 0;
6232  __Pyx_XDECREF(__pyx_t_18); __pyx_t_18 = 0;
6233  __Pyx_XDECREF(__pyx_t_17); __pyx_t_17 = 0;
6234  __Pyx_XDECREF(__pyx_t_15); __pyx_t_15 = 0;
6235  __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
6236  __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
6237 
6238  /* "PyClical.pyx":604
6239  * else:
6240  * raise TypeError(error_msg_prefix + " " + str(type(other)) + ".")
6241  * except RuntimeError as err: # <<<<<<<<<<<<<<
6242  * raise ValueError(error_msg_prefix + " " + str(type(other))
6243  * + " value " + repr(other) + ":"
6244  */
6245  __pyx_t_14 = PyErr_ExceptionMatches(__pyx_builtin_RuntimeError);
6246  if (__pyx_t_14) {
6247  __Pyx_AddTraceback("PyClical.clifford.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6248  if (__Pyx_GetException(&__pyx_t_8, &__pyx_t_7, &__pyx_t_15) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 604; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6249  __Pyx_GOTREF(__pyx_t_8);
6250  __Pyx_GOTREF(__pyx_t_7);
6251  __Pyx_GOTREF(__pyx_t_15);
6252  __Pyx_INCREF(__pyx_t_7);
6253  __pyx_v_err = __pyx_t_7;
6254 
6255  /* "PyClical.pyx":605
6256  * raise TypeError(error_msg_prefix + " " + str(type(other)) + ".")
6257  * except RuntimeError as err:
6258  * raise ValueError(error_msg_prefix + " " + str(type(other)) # <<<<<<<<<<<<<<
6259  * + " value " + repr(other) + ":"
6260  * + "\n\t" + str(err))
6261  */
6262  __pyx_t_17 = PyNumber_Add(__pyx_v_error_msg_prefix, __pyx_kp_s__2); if (unlikely(!__pyx_t_17)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 605; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6263  __Pyx_GOTREF(__pyx_t_17);
6264  __pyx_t_18 = PyTuple_New(1); if (unlikely(!__pyx_t_18)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 605; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6265  __Pyx_GOTREF(__pyx_t_18);
6266  __Pyx_INCREF(((PyObject *)Py_TYPE(__pyx_v_other)));
6267  __Pyx_GIVEREF(((PyObject *)Py_TYPE(__pyx_v_other)));
6268  PyTuple_SET_ITEM(__pyx_t_18, 0, ((PyObject *)Py_TYPE(__pyx_v_other)));
6269  __pyx_t_16 = __Pyx_PyObject_Call(((PyObject *)(&PyString_Type)), __pyx_t_18, NULL); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 605; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6270  __Pyx_GOTREF(__pyx_t_16);
6271  __Pyx_DECREF(__pyx_t_18); __pyx_t_18 = 0;
6272  __pyx_t_18 = PyNumber_Add(__pyx_t_17, __pyx_t_16); if (unlikely(!__pyx_t_18)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 605; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6273  __Pyx_GOTREF(__pyx_t_18);
6274  __Pyx_DECREF(__pyx_t_17); __pyx_t_17 = 0;
6275  __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
6276 
6277  /* "PyClical.pyx":606
6278  * except RuntimeError as err:
6279  * raise ValueError(error_msg_prefix + " " + str(type(other))
6280  * + " value " + repr(other) + ":" # <<<<<<<<<<<<<<
6281  * + "\n\t" + str(err))
6282  * elif isinstance(ixt, index_set):
6283  */
6284  __pyx_t_16 = PyNumber_Add(__pyx_t_18, __pyx_kp_s_value); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 606; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6285  __Pyx_GOTREF(__pyx_t_16);
6286  __Pyx_DECREF(__pyx_t_18); __pyx_t_18 = 0;
6287  __pyx_t_18 = PyObject_Repr(__pyx_v_other); if (unlikely(!__pyx_t_18)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 606; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6288  __Pyx_GOTREF(__pyx_t_18);
6289  __pyx_t_17 = PyNumber_Add(__pyx_t_16, __pyx_t_18); if (unlikely(!__pyx_t_17)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 606; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6290  __Pyx_GOTREF(__pyx_t_17);
6291  __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
6292  __Pyx_DECREF(__pyx_t_18); __pyx_t_18 = 0;
6293  __pyx_t_18 = PyNumber_Add(__pyx_t_17, __pyx_kp_s__3); if (unlikely(!__pyx_t_18)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 606; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6294  __Pyx_GOTREF(__pyx_t_18);
6295  __Pyx_DECREF(__pyx_t_17); __pyx_t_17 = 0;
6296 
6297  /* "PyClical.pyx":607
6298  * raise ValueError(error_msg_prefix + " " + str(type(other))
6299  * + " value " + repr(other) + ":"
6300  * + "\n\t" + str(err)) # <<<<<<<<<<<<<<
6301  * elif isinstance(ixt, index_set):
6302  * if isinstance(other, numbers.Real):
6303  */
6304  __pyx_t_17 = PyNumber_Add(__pyx_t_18, __pyx_kp_s__4); if (unlikely(!__pyx_t_17)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 607; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6305  __Pyx_GOTREF(__pyx_t_17);
6306  __Pyx_DECREF(__pyx_t_18); __pyx_t_18 = 0;
6307  __pyx_t_18 = PyTuple_New(1); if (unlikely(!__pyx_t_18)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 607; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6308  __Pyx_GOTREF(__pyx_t_18);
6309  __Pyx_INCREF(__pyx_v_err);
6310  __Pyx_GIVEREF(__pyx_v_err);
6311  PyTuple_SET_ITEM(__pyx_t_18, 0, __pyx_v_err);
6312  __pyx_t_16 = __Pyx_PyObject_Call(((PyObject *)(&PyString_Type)), __pyx_t_18, NULL); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 607; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6313  __Pyx_GOTREF(__pyx_t_16);
6314  __Pyx_DECREF(__pyx_t_18); __pyx_t_18 = 0;
6315  __pyx_t_18 = PyNumber_Add(__pyx_t_17, __pyx_t_16); if (unlikely(!__pyx_t_18)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 607; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6316  __Pyx_GOTREF(__pyx_t_18);
6317  __Pyx_DECREF(__pyx_t_17); __pyx_t_17 = 0;
6318  __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
6319 
6320  /* "PyClical.pyx":605
6321  * raise TypeError(error_msg_prefix + " " + str(type(other)) + ".")
6322  * except RuntimeError as err:
6323  * raise ValueError(error_msg_prefix + " " + str(type(other)) # <<<<<<<<<<<<<<
6324  * + " value " + repr(other) + ":"
6325  * + "\n\t" + str(err))
6326  */
6327  __pyx_t_16 = PyTuple_New(1); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 605; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6328  __Pyx_GOTREF(__pyx_t_16);
6329  __Pyx_GIVEREF(__pyx_t_18);
6330  PyTuple_SET_ITEM(__pyx_t_16, 0, __pyx_t_18);
6331  __pyx_t_18 = 0;
6332  __pyx_t_18 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_t_16, NULL); if (unlikely(!__pyx_t_18)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 605; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6333  __Pyx_GOTREF(__pyx_t_18);
6334  __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
6335  __Pyx_Raise(__pyx_t_18, 0, 0, 0);
6336  __Pyx_DECREF(__pyx_t_18); __pyx_t_18 = 0;
6337  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 605; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6338  }
6339  goto __pyx_L6_except_error;
6340  __pyx_L6_except_error:;
6341 
6342  /* "PyClical.pyx":590
6343  * error_msg_prefix = "Cannot initialize clifford object from"
6344  * if ixt is None:
6345  * try: # <<<<<<<<<<<<<<
6346  * if isinstance(other, clifford):
6347  * self.instance = new Clifford((<clifford>other).unwrap())
6348  */
6349  __Pyx_XGIVEREF(__pyx_t_3);
6350  __Pyx_XGIVEREF(__pyx_t_4);
6351  __Pyx_XGIVEREF(__pyx_t_5);
6352  __Pyx_ExceptionReset(__pyx_t_3, __pyx_t_4, __pyx_t_5);
6353  goto __pyx_L1_error;
6354  __pyx_L11_try_end:;
6355  }
6356 
6357  /* "PyClical.pyx":589
6358  * """
6359  * error_msg_prefix = "Cannot initialize clifford object from"
6360  * if ixt is None: # <<<<<<<<<<<<<<
6361  * try:
6362  * if isinstance(other, clifford):
6363  */
6364  goto __pyx_L3;
6365  }
6366 
6367  /* "PyClical.pyx":608
6368  * + " value " + repr(other) + ":"
6369  * + "\n\t" + str(err))
6370  * elif isinstance(ixt, index_set): # <<<<<<<<<<<<<<
6371  * if isinstance(other, numbers.Real):
6372  * self.instance = new Clifford((<index_set>ixt).unwrap(), <scalar_t>other)
6373  */
6374  __pyx_t_2 = __Pyx_TypeCheck(__pyx_v_ixt, __pyx_ptype_8PyClical_index_set);
6375  __pyx_t_1 = (__pyx_t_2 != 0);
6376  if (__pyx_t_1) {
6377 
6378  /* "PyClical.pyx":609
6379  * + "\n\t" + str(err))
6380  * elif isinstance(ixt, index_set):
6381  * if isinstance(other, numbers.Real): # <<<<<<<<<<<<<<
6382  * self.instance = new Clifford((<index_set>ixt).unwrap(), <scalar_t>other)
6383  * elif isinstance(other, collections.Sequence):
6384  */
6385  __pyx_t_15 = __Pyx_GetModuleGlobalName(__pyx_n_s_numbers); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 609; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6386  __Pyx_GOTREF(__pyx_t_15);
6387  __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_15, __pyx_n_s_Real); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 609; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6388  __Pyx_GOTREF(__pyx_t_7);
6389  __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0;
6390  __pyx_t_1 = PyObject_IsInstance(__pyx_v_other, __pyx_t_7); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 609; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6391  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
6392  __pyx_t_2 = (__pyx_t_1 != 0);
6393  if (__pyx_t_2) {
6394 
6395  /* "PyClical.pyx":610
6396  * elif isinstance(ixt, index_set):
6397  * if isinstance(other, numbers.Real):
6398  * self.instance = new Clifford((<index_set>ixt).unwrap(), <scalar_t>other) # <<<<<<<<<<<<<<
6399  * elif isinstance(other, collections.Sequence):
6400  * self.instance = new Clifford(list_to_vector(other), (<index_set>ixt).unwrap())
6401  */
6402  __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_v_other); if (unlikely((__pyx_t_9 == (scalar_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 610; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6403  try {
6404  __pyx_t_6 = new Clifford(__pyx_f_8PyClical_9index_set_unwrap(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_ixt)), ((scalar_t)__pyx_t_9));
6405  } catch(...) {
6406  __Pyx_CppExn2PyErr();
6407  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 610; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6408  }
6409  __pyx_v_self->instance = __pyx_t_6;
6410 
6411  /* "PyClical.pyx":609
6412  * + "\n\t" + str(err))
6413  * elif isinstance(ixt, index_set):
6414  * if isinstance(other, numbers.Real): # <<<<<<<<<<<<<<
6415  * self.instance = new Clifford((<index_set>ixt).unwrap(), <scalar_t>other)
6416  * elif isinstance(other, collections.Sequence):
6417  */
6418  goto __pyx_L25;
6419  }
6420 
6421  /* "PyClical.pyx":611
6422  * if isinstance(other, numbers.Real):
6423  * self.instance = new Clifford((<index_set>ixt).unwrap(), <scalar_t>other)
6424  * elif isinstance(other, collections.Sequence): # <<<<<<<<<<<<<<
6425  * self.instance = new Clifford(list_to_vector(other), (<index_set>ixt).unwrap())
6426  * else:
6427  */
6428  __pyx_t_7 = __Pyx_GetModuleGlobalName(__pyx_n_s_collections); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 611; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6429  __Pyx_GOTREF(__pyx_t_7);
6430  __pyx_t_15 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_Sequence); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 611; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6431  __Pyx_GOTREF(__pyx_t_15);
6432  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
6433  __pyx_t_2 = PyObject_IsInstance(__pyx_v_other, __pyx_t_15); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 611; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6434  __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0;
6435  __pyx_t_1 = (__pyx_t_2 != 0);
6436  if (__pyx_t_1) {
6437 
6438  /* "PyClical.pyx":612
6439  * self.instance = new Clifford((<index_set>ixt).unwrap(), <scalar_t>other)
6440  * elif isinstance(other, collections.Sequence):
6441  * self.instance = new Clifford(list_to_vector(other), (<index_set>ixt).unwrap()) # <<<<<<<<<<<<<<
6442  * else:
6443  * raise TypeError(error_msg_prefix + " (" + str(type(other))
6444  */
6445  try {
6446  __pyx_t_6 = new Clifford(__pyx_f_8PyClical_list_to_vector(__pyx_v_other), __pyx_f_8PyClical_9index_set_unwrap(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_ixt)));
6447  } catch(...) {
6448  __Pyx_CppExn2PyErr();
6449  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 612; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6450  }
6451  __pyx_v_self->instance = __pyx_t_6;
6452 
6453  /* "PyClical.pyx":611
6454  * if isinstance(other, numbers.Real):
6455  * self.instance = new Clifford((<index_set>ixt).unwrap(), <scalar_t>other)
6456  * elif isinstance(other, collections.Sequence): # <<<<<<<<<<<<<<
6457  * self.instance = new Clifford(list_to_vector(other), (<index_set>ixt).unwrap())
6458  * else:
6459  */
6460  goto __pyx_L25;
6461  }
6462 
6463  /* "PyClical.pyx":614
6464  * self.instance = new Clifford(list_to_vector(other), (<index_set>ixt).unwrap())
6465  * else:
6466  * raise TypeError(error_msg_prefix + " (" + str(type(other)) # <<<<<<<<<<<<<<
6467  * + ", " + repr(ixt) + ").")
6468  * else:
6469  */
6470  /*else*/ {
6471  __pyx_t_15 = PyNumber_Add(__pyx_v_error_msg_prefix, __pyx_kp_s__5); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 614; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6472  __Pyx_GOTREF(__pyx_t_15);
6473  __pyx_t_7 = PyTuple_New(1); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 614; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6474  __Pyx_GOTREF(__pyx_t_7);
6475  __Pyx_INCREF(((PyObject *)Py_TYPE(__pyx_v_other)));
6476  __Pyx_GIVEREF(((PyObject *)Py_TYPE(__pyx_v_other)));
6477  PyTuple_SET_ITEM(__pyx_t_7, 0, ((PyObject *)Py_TYPE(__pyx_v_other)));
6478  __pyx_t_8 = __Pyx_PyObject_Call(((PyObject *)(&PyString_Type)), __pyx_t_7, NULL); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 614; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6479  __Pyx_GOTREF(__pyx_t_8);
6480  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
6481  __pyx_t_7 = PyNumber_Add(__pyx_t_15, __pyx_t_8); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 614; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6482  __Pyx_GOTREF(__pyx_t_7);
6483  __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0;
6484  __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
6485 
6486  /* "PyClical.pyx":615
6487  * else:
6488  * raise TypeError(error_msg_prefix + " (" + str(type(other))
6489  * + ", " + repr(ixt) + ").") # <<<<<<<<<<<<<<
6490  * else:
6491  * raise TypeError(error_msg_prefix + " (" + str(type(other))
6492  */
6493  __pyx_t_8 = PyNumber_Add(__pyx_t_7, __pyx_kp_s__6); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 615; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6494  __Pyx_GOTREF(__pyx_t_8);
6495  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
6496  __pyx_t_7 = PyObject_Repr(__pyx_v_ixt); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 615; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6497  __Pyx_GOTREF(__pyx_t_7);
6498  __pyx_t_15 = PyNumber_Add(__pyx_t_8, __pyx_t_7); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 615; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6499  __Pyx_GOTREF(__pyx_t_15);
6500  __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
6501  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
6502  __pyx_t_7 = PyNumber_Add(__pyx_t_15, __pyx_kp_s__7); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 615; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6503  __Pyx_GOTREF(__pyx_t_7);
6504  __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0;
6505 
6506  /* "PyClical.pyx":614
6507  * self.instance = new Clifford(list_to_vector(other), (<index_set>ixt).unwrap())
6508  * else:
6509  * raise TypeError(error_msg_prefix + " (" + str(type(other)) # <<<<<<<<<<<<<<
6510  * + ", " + repr(ixt) + ").")
6511  * else:
6512  */
6513  __pyx_t_15 = PyTuple_New(1); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 614; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6514  __Pyx_GOTREF(__pyx_t_15);
6515  __Pyx_GIVEREF(__pyx_t_7);
6516  PyTuple_SET_ITEM(__pyx_t_15, 0, __pyx_t_7);
6517  __pyx_t_7 = 0;
6518  __pyx_t_7 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_t_15, NULL); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 614; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6519  __Pyx_GOTREF(__pyx_t_7);
6520  __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0;
6521  __Pyx_Raise(__pyx_t_7, 0, 0, 0);
6522  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
6523  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 614; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6524  }
6525  __pyx_L25:;
6526 
6527  /* "PyClical.pyx":608
6528  * + " value " + repr(other) + ":"
6529  * + "\n\t" + str(err))
6530  * elif isinstance(ixt, index_set): # <<<<<<<<<<<<<<
6531  * if isinstance(other, numbers.Real):
6532  * self.instance = new Clifford((<index_set>ixt).unwrap(), <scalar_t>other)
6533  */
6534  goto __pyx_L3;
6535  }
6536 
6537  /* "PyClical.pyx":617
6538  * + ", " + repr(ixt) + ").")
6539  * else:
6540  * raise TypeError(error_msg_prefix + " (" + str(type(other)) # <<<<<<<<<<<<<<
6541  * + ", " + str(type(ixt)) + ").")
6542  *
6543  */
6544  /*else*/ {
6545  __pyx_t_7 = PyNumber_Add(__pyx_v_error_msg_prefix, __pyx_kp_s__5); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 617; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6546  __Pyx_GOTREF(__pyx_t_7);
6547  __pyx_t_15 = PyTuple_New(1); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 617; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6548  __Pyx_GOTREF(__pyx_t_15);
6549  __Pyx_INCREF(((PyObject *)Py_TYPE(__pyx_v_other)));
6550  __Pyx_GIVEREF(((PyObject *)Py_TYPE(__pyx_v_other)));
6551  PyTuple_SET_ITEM(__pyx_t_15, 0, ((PyObject *)Py_TYPE(__pyx_v_other)));
6552  __pyx_t_8 = __Pyx_PyObject_Call(((PyObject *)(&PyString_Type)), __pyx_t_15, NULL); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 617; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6553  __Pyx_GOTREF(__pyx_t_8);
6554  __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0;
6555  __pyx_t_15 = PyNumber_Add(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 617; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6556  __Pyx_GOTREF(__pyx_t_15);
6557  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
6558  __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
6559 
6560  /* "PyClical.pyx":618
6561  * else:
6562  * raise TypeError(error_msg_prefix + " (" + str(type(other))
6563  * + ", " + str(type(ixt)) + ").") # <<<<<<<<<<<<<<
6564  *
6565  * def __dealloc__(self):
6566  */
6567  __pyx_t_8 = PyNumber_Add(__pyx_t_15, __pyx_kp_s__6); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 618; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6568  __Pyx_GOTREF(__pyx_t_8);
6569  __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0;
6570  __pyx_t_15 = PyTuple_New(1); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 618; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6571  __Pyx_GOTREF(__pyx_t_15);
6572  __Pyx_INCREF(((PyObject *)Py_TYPE(__pyx_v_ixt)));
6573  __Pyx_GIVEREF(((PyObject *)Py_TYPE(__pyx_v_ixt)));
6574  PyTuple_SET_ITEM(__pyx_t_15, 0, ((PyObject *)Py_TYPE(__pyx_v_ixt)));
6575  __pyx_t_7 = __Pyx_PyObject_Call(((PyObject *)(&PyString_Type)), __pyx_t_15, NULL); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 618; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6576  __Pyx_GOTREF(__pyx_t_7);
6577  __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0;
6578  __pyx_t_15 = PyNumber_Add(__pyx_t_8, __pyx_t_7); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 618; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6579  __Pyx_GOTREF(__pyx_t_15);
6580  __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
6581  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
6582  __pyx_t_7 = PyNumber_Add(__pyx_t_15, __pyx_kp_s__7); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 618; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6583  __Pyx_GOTREF(__pyx_t_7);
6584  __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0;
6585 
6586  /* "PyClical.pyx":617
6587  * + ", " + repr(ixt) + ").")
6588  * else:
6589  * raise TypeError(error_msg_prefix + " (" + str(type(other)) # <<<<<<<<<<<<<<
6590  * + ", " + str(type(ixt)) + ").")
6591  *
6592  */
6593  __pyx_t_15 = PyTuple_New(1); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 617; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6594  __Pyx_GOTREF(__pyx_t_15);
6595  __Pyx_GIVEREF(__pyx_t_7);
6596  PyTuple_SET_ITEM(__pyx_t_15, 0, __pyx_t_7);
6597  __pyx_t_7 = 0;
6598  __pyx_t_7 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_t_15, NULL); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 617; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6599  __Pyx_GOTREF(__pyx_t_7);
6600  __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0;
6601  __Pyx_Raise(__pyx_t_7, 0, 0, 0);
6602  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
6603  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 617; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6604  }
6605  __pyx_L3:;
6606 
6607  /* "PyClical.pyx":563
6608  * return clifford(self)
6609  *
6610  * def __cinit__(self, other = 0, ixt = None): # <<<<<<<<<<<<<<
6611  * """
6612  * Construct an object of type clifford.
6613  */
6614 
6615  /* function exit code */
6616  __pyx_r = 0;
6617  goto __pyx_L0;
6618  __pyx_L1_error:;
6619  __Pyx_XDECREF(__pyx_t_7);
6620  __Pyx_XDECREF(__pyx_t_8);
6621  __Pyx_XDECREF(__pyx_t_15);
6622  __Pyx_XDECREF(__pyx_t_16);
6623  __Pyx_XDECREF(__pyx_t_17);
6624  __Pyx_XDECREF(__pyx_t_18);
6625  __Pyx_AddTraceback("PyClical.clifford.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6626  __pyx_r = -1;
6627  __pyx_L0:;
6628  __Pyx_XDECREF(__pyx_v_error_msg_prefix);
6629  __Pyx_XDECREF(__pyx_v_err);
6630  __Pyx_RefNannyFinishContext();
6631  return __pyx_r;
6632  }
6633 
6634  /* "PyClical.pyx":620
6635  * + ", " + str(type(ixt)) + ").")
6636  *
6637  * def __dealloc__(self): # <<<<<<<<<<<<<<
6638  * """
6639  * Clean up by deallocating the instance of C++ class Clifford.
6640  */
6641 
6642  /* Python wrapper */
6643  static void __pyx_pw_8PyClical_8clifford_5__dealloc__(PyObject *__pyx_v_self); /*proto*/
6644  static void __pyx_pw_8PyClical_8clifford_5__dealloc__(PyObject *__pyx_v_self) {
6645  __Pyx_RefNannyDeclarations
6646  __Pyx_RefNannySetupContext("__dealloc__ (wrapper)", 0);
6647  __pyx_pf_8PyClical_8clifford_4__dealloc__(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self));
6648 
6649  /* function exit code */
6650  __Pyx_RefNannyFinishContext();
6651  }
6652 
6653  static void __pyx_pf_8PyClical_8clifford_4__dealloc__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self) {
6654  __Pyx_RefNannyDeclarations
6655  __Pyx_RefNannySetupContext("__dealloc__", 0);
6656 
6657  /* "PyClical.pyx":624
6658  * Clean up by deallocating the instance of C++ class Clifford.
6659  * """
6660  * del self.instance # <<<<<<<<<<<<<<
6661  *
6662  * def __contains__(self, x):
6663  */
6664  delete __pyx_v_self->instance;
6665 
6666  /* "PyClical.pyx":620
6667  * + ", " + str(type(ixt)) + ").")
6668  *
6669  * def __dealloc__(self): # <<<<<<<<<<<<<<
6670  * """
6671  * Clean up by deallocating the instance of C++ class Clifford.
6672  */
6673 
6674  /* function exit code */
6675  __Pyx_RefNannyFinishContext();
6676  }
6677 
6678  /* "PyClical.pyx":626
6679  * del self.instance
6680  *
6681  * def __contains__(self, x): # <<<<<<<<<<<<<<
6682  * """
6683  * Not applicable.
6684  */
6685 
6686  /* Python wrapper */
6687  static int __pyx_pw_8PyClical_8clifford_7__contains__(PyObject *__pyx_v_self, PyObject *__pyx_v_x); /*proto*/
6688  static char __pyx_doc_8PyClical_8clifford_6__contains__[] = "\n Not applicable.\n\n >>> x=clifford(index_set({-3,4,7})); -3 in x\n Traceback (most recent call last):\n ...\n TypeError: Not applicable.\n ";
6689  #if CYTHON_COMPILING_IN_CPYTHON
6690  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_6__contains__;
6691  #endif
6692  static int __pyx_pw_8PyClical_8clifford_7__contains__(PyObject *__pyx_v_self, PyObject *__pyx_v_x) {
6693  int __pyx_r;
6694  __Pyx_RefNannyDeclarations
6695  __Pyx_RefNannySetupContext("__contains__ (wrapper)", 0);
6696  __pyx_r = __pyx_pf_8PyClical_8clifford_6__contains__(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self), ((PyObject *)__pyx_v_x));
6697 
6698  /* function exit code */
6699  __Pyx_RefNannyFinishContext();
6700  return __pyx_r;
6701  }
6702 
6703  static int __pyx_pf_8PyClical_8clifford_6__contains__(CYTHON_UNUSED struct __pyx_obj_8PyClical_clifford *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_x) {
6704  int __pyx_r;
6705  __Pyx_RefNannyDeclarations
6706  PyObject *__pyx_t_1 = NULL;
6707  int __pyx_lineno = 0;
6708  const char *__pyx_filename = NULL;
6709  int __pyx_clineno = 0;
6710  __Pyx_RefNannySetupContext("__contains__", 0);
6711 
6712  /* "PyClical.pyx":635
6713  * TypeError: Not applicable.
6714  * """
6715  * raise TypeError("Not applicable.") # <<<<<<<<<<<<<<
6716  *
6717  * def __iter__(self):
6718  */
6719  __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__8, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 635; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6720  __Pyx_GOTREF(__pyx_t_1);
6721  __Pyx_Raise(__pyx_t_1, 0, 0, 0);
6722  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
6723  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 635; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6724 
6725  /* "PyClical.pyx":626
6726  * del self.instance
6727  *
6728  * def __contains__(self, x): # <<<<<<<<<<<<<<
6729  * """
6730  * Not applicable.
6731  */
6732 
6733  /* function exit code */
6734  __pyx_L1_error:;
6735  __Pyx_XDECREF(__pyx_t_1);
6736  __Pyx_AddTraceback("PyClical.clifford.__contains__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6737  __pyx_r = -1;
6738  __Pyx_RefNannyFinishContext();
6739  return __pyx_r;
6740  }
6741 
6742  /* "PyClical.pyx":637
6743  * raise TypeError("Not applicable.")
6744  *
6745  * def __iter__(self): # <<<<<<<<<<<<<<
6746  * """
6747  * Not applicable.
6748  */
6749 
6750  /* Python wrapper */
6751  static PyObject *__pyx_pw_8PyClical_8clifford_9__iter__(PyObject *__pyx_v_self); /*proto*/
6752  static char __pyx_doc_8PyClical_8clifford_8__iter__[] = "\n Not applicable.\n\n >>> for a in clifford(index_set({-3,4,7})): print a,\n Traceback (most recent call last):\n ...\n TypeError: Not applicable.\n ";
6753  #if CYTHON_COMPILING_IN_CPYTHON
6754  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_8__iter__;
6755  #endif
6756  static PyObject *__pyx_pw_8PyClical_8clifford_9__iter__(PyObject *__pyx_v_self) {
6757  PyObject *__pyx_r = 0;
6758  __Pyx_RefNannyDeclarations
6759  __Pyx_RefNannySetupContext("__iter__ (wrapper)", 0);
6760  __pyx_r = __pyx_pf_8PyClical_8clifford_8__iter__(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self));
6761 
6762  /* function exit code */
6763  __Pyx_RefNannyFinishContext();
6764  return __pyx_r;
6765  }
6766 
6767  static PyObject *__pyx_pf_8PyClical_8clifford_8__iter__(CYTHON_UNUSED struct __pyx_obj_8PyClical_clifford *__pyx_v_self) {
6768  PyObject *__pyx_r = NULL;
6769  __Pyx_RefNannyDeclarations
6770  PyObject *__pyx_t_1 = NULL;
6771  int __pyx_lineno = 0;
6772  const char *__pyx_filename = NULL;
6773  int __pyx_clineno = 0;
6774  __Pyx_RefNannySetupContext("__iter__", 0);
6775 
6776  /* "PyClical.pyx":646
6777  * TypeError: Not applicable.
6778  * """
6779  * raise TypeError("Not applicable.") # <<<<<<<<<<<<<<
6780  *
6781  * def reframe(self, ixt):
6782  */
6783  __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__9, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 646; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6784  __Pyx_GOTREF(__pyx_t_1);
6785  __Pyx_Raise(__pyx_t_1, 0, 0, 0);
6786  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
6787  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 646; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
6788 
6789  /* "PyClical.pyx":637
6790  * raise TypeError("Not applicable.")
6791  *
6792  * def __iter__(self): # <<<<<<<<<<<<<<
6793  * """
6794  * Not applicable.
6795  */
6796 
6797  /* function exit code */
6798  __pyx_L1_error:;
6799  __Pyx_XDECREF(__pyx_t_1);
6800  __Pyx_AddTraceback("PyClical.clifford.__iter__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6801  __pyx_r = NULL;
6802  __Pyx_XGIVEREF(__pyx_r);
6803  __Pyx_RefNannyFinishContext();
6804  return __pyx_r;
6805  }
6806 
6807  /* "PyClical.pyx":648
6808  * raise TypeError("Not applicable.")
6809  *
6810  * def reframe(self, ixt): # <<<<<<<<<<<<<<
6811  * """
6812  * Put self into a larger frame, containing the union of self.frame() and index set ixt.
6813  */
6814 
6815  /* Python wrapper */
6816  static PyObject *__pyx_pw_8PyClical_8clifford_11reframe(PyObject *__pyx_v_self, PyObject *__pyx_v_ixt); /*proto*/
6817  static char __pyx_doc_8PyClical_8clifford_10reframe[] = "\n Put self into a larger frame, containing the union of self.frame() and index set ixt.\n This can be used to make multiplication faster, by multiplying within a common frame.\n\n >>> clifford(\"2+3{1}\").reframe(index_set({1,2,3}))\n clifford(\"2+3{1}\")\n >>> s=index_set({1,2,3});t=index_set({-3,-2,-1});x=random_clifford(s); x.reframe(t).frame() == (s|t);\n True\n ";
6818  static PyObject *__pyx_pw_8PyClical_8clifford_11reframe(PyObject *__pyx_v_self, PyObject *__pyx_v_ixt) {
6819  PyObject *__pyx_r = 0;
6820  __Pyx_RefNannyDeclarations
6821  __Pyx_RefNannySetupContext("reframe (wrapper)", 0);
6822  __pyx_r = __pyx_pf_8PyClical_8clifford_10reframe(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self), ((PyObject *)__pyx_v_ixt));
6823 
6824  /* function exit code */
6825  __Pyx_RefNannyFinishContext();
6826  return __pyx_r;
6827  }
6828 
6829  static PyObject *__pyx_pf_8PyClical_8clifford_10reframe(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_ixt) {
6830  PyObject *__pyx_v_error_msg_prefix = NULL;
6831  struct __pyx_obj_8PyClical_clifford *__pyx_v_result = NULL;
6832  PyObject *__pyx_v_err = NULL;
6833  PyObject *__pyx_r = NULL;
6834  __Pyx_RefNannyDeclarations
6835  int __pyx_t_1;
6836  int __pyx_t_2;
6837  PyObject *__pyx_t_3 = NULL;
6838  PyObject *__pyx_t_4 = NULL;
6839  PyObject *__pyx_t_5 = NULL;
6840  PyObject *__pyx_t_6 = NULL;
6841  Clifford *__pyx_t_7;
6842  int __pyx_t_8;
6843  PyObject *__pyx_t_9 = NULL;
6844  PyObject *__pyx_t_10 = NULL;
6845  PyObject *__pyx_t_11 = NULL;
6846  PyObject *__pyx_t_12 = NULL;
6847  PyObject *__pyx_t_13 = NULL;
6848  int __pyx_lineno = 0;
6849  const char *__pyx_filename = NULL;
6850  int __pyx_clineno = 0;
6851  __Pyx_RefNannySetupContext("reframe", 0);
6852 
6853  /* "PyClical.pyx":658
6854  * True
6855  * """
6856  * error_msg_prefix = "Cannot reframe" # <<<<<<<<<<<<<<
6857  * if isinstance(ixt, index_set):
6858  * try:
6859  */
6860  __Pyx_INCREF(__pyx_kp_s_Cannot_reframe);
6861  __pyx_v_error_msg_prefix = __pyx_kp_s_Cannot_reframe;
6862 
6863  /* "PyClical.pyx":659
6864  * """
6865  * error_msg_prefix = "Cannot reframe"
6866  * if isinstance(ixt, index_set): # <<<<<<<<<<<<<<
6867  * try:
6868  * result = clifford()
6869  */
6870  __pyx_t_1 = __Pyx_TypeCheck(__pyx_v_ixt, __pyx_ptype_8PyClical_index_set);
6871  __pyx_t_2 = (__pyx_t_1 != 0);
6872  if (__pyx_t_2) {
6873 
6874  /* "PyClical.pyx":660
6875  * error_msg_prefix = "Cannot reframe"
6876  * if isinstance(ixt, index_set):
6877  * try: # <<<<<<<<<<<<<<
6878  * result = clifford()
6879  * result.instance = new Clifford(self.unwrap(), (<index_set>ixt).unwrap())
6880  */
6881  {
6882  __Pyx_ExceptionSave(&__pyx_t_3, &__pyx_t_4, &__pyx_t_5);
6883  __Pyx_XGOTREF(__pyx_t_3);
6884  __Pyx_XGOTREF(__pyx_t_4);
6885  __Pyx_XGOTREF(__pyx_t_5);
6886  /*try:*/ {
6887 
6888  /* "PyClical.pyx":661
6889  * if isinstance(ixt, index_set):
6890  * try:
6891  * result = clifford() # <<<<<<<<<<<<<<
6892  * result.instance = new Clifford(self.unwrap(), (<index_set>ixt).unwrap())
6893  * except RuntimeError as err:
6894  */
6895  __pyx_t_6 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 661; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
6896  __Pyx_GOTREF(__pyx_t_6);
6897  __pyx_v_result = ((struct __pyx_obj_8PyClical_clifford *)__pyx_t_6);
6898  __pyx_t_6 = 0;
6899 
6900  /* "PyClical.pyx":662
6901  * try:
6902  * result = clifford()
6903  * result.instance = new Clifford(self.unwrap(), (<index_set>ixt).unwrap()) # <<<<<<<<<<<<<<
6904  * except RuntimeError as err:
6905  * raise ValueError(error_msg_prefix + " from " + str(self) + " to frame "
6906  */
6907  try {
6908  __pyx_t_7 = new Clifford(__pyx_f_8PyClical_8clifford_unwrap(__pyx_v_self), __pyx_f_8PyClical_9index_set_unwrap(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_ixt)));
6909  } catch(...) {
6910  __Pyx_CppExn2PyErr();
6911  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 662; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
6912  }
6913  __pyx_v_result->instance = __pyx_t_7;
6914 
6915  /* "PyClical.pyx":660
6916  * error_msg_prefix = "Cannot reframe"
6917  * if isinstance(ixt, index_set):
6918  * try: # <<<<<<<<<<<<<<
6919  * result = clifford()
6920  * result.instance = new Clifford(self.unwrap(), (<index_set>ixt).unwrap())
6921  */
6922  }
6923  __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
6924  __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
6925  __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
6926  goto __pyx_L11_try_end;
6927  __pyx_L4_error:;
6928  __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
6929 
6930  /* "PyClical.pyx":663
6931  * result = clifford()
6932  * result.instance = new Clifford(self.unwrap(), (<index_set>ixt).unwrap())
6933  * except RuntimeError as err: # <<<<<<<<<<<<<<
6934  * raise ValueError(error_msg_prefix + " from " + str(self) + " to frame "
6935  * + str(ixt) + ":"
6936  */
6937  __pyx_t_8 = PyErr_ExceptionMatches(__pyx_builtin_RuntimeError);
6938  if (__pyx_t_8) {
6939  __Pyx_AddTraceback("PyClical.clifford.reframe", __pyx_clineno, __pyx_lineno, __pyx_filename);
6940  if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_9, &__pyx_t_10) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 663; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6941  __Pyx_GOTREF(__pyx_t_6);
6942  __Pyx_GOTREF(__pyx_t_9);
6943  __Pyx_GOTREF(__pyx_t_10);
6944  __Pyx_INCREF(__pyx_t_9);
6945  __pyx_v_err = __pyx_t_9;
6946 
6947  /* "PyClical.pyx":664
6948  * result.instance = new Clifford(self.unwrap(), (<index_set>ixt).unwrap())
6949  * except RuntimeError as err:
6950  * raise ValueError(error_msg_prefix + " from " + str(self) + " to frame " # <<<<<<<<<<<<<<
6951  * + str(ixt) + ":"
6952  * + "\n\t" + str(err))
6953  */
6954  __pyx_t_11 = PyNumber_Add(__pyx_v_error_msg_prefix, __pyx_kp_s_from); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 664; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6955  __Pyx_GOTREF(__pyx_t_11);
6956  __pyx_t_12 = PyTuple_New(1); if (unlikely(!__pyx_t_12)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 664; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6957  __Pyx_GOTREF(__pyx_t_12);
6958  __Pyx_INCREF(((PyObject *)__pyx_v_self));
6959  __Pyx_GIVEREF(((PyObject *)__pyx_v_self));
6960  PyTuple_SET_ITEM(__pyx_t_12, 0, ((PyObject *)__pyx_v_self));
6961  __pyx_t_13 = __Pyx_PyObject_Call(((PyObject *)(&PyString_Type)), __pyx_t_12, NULL); if (unlikely(!__pyx_t_13)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 664; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6962  __Pyx_GOTREF(__pyx_t_13);
6963  __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0;
6964  __pyx_t_12 = PyNumber_Add(__pyx_t_11, __pyx_t_13); if (unlikely(!__pyx_t_12)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 664; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6965  __Pyx_GOTREF(__pyx_t_12);
6966  __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
6967  __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
6968  __pyx_t_13 = PyNumber_Add(__pyx_t_12, __pyx_kp_s_to_frame); if (unlikely(!__pyx_t_13)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 664; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6969  __Pyx_GOTREF(__pyx_t_13);
6970  __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0;
6971 
6972  /* "PyClical.pyx":665
6973  * except RuntimeError as err:
6974  * raise ValueError(error_msg_prefix + " from " + str(self) + " to frame "
6975  * + str(ixt) + ":" # <<<<<<<<<<<<<<
6976  * + "\n\t" + str(err))
6977  * else:
6978  */
6979  __pyx_t_12 = PyTuple_New(1); if (unlikely(!__pyx_t_12)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 665; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6980  __Pyx_GOTREF(__pyx_t_12);
6981  __Pyx_INCREF(__pyx_v_ixt);
6982  __Pyx_GIVEREF(__pyx_v_ixt);
6983  PyTuple_SET_ITEM(__pyx_t_12, 0, __pyx_v_ixt);
6984  __pyx_t_11 = __Pyx_PyObject_Call(((PyObject *)(&PyString_Type)), __pyx_t_12, NULL); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 665; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6985  __Pyx_GOTREF(__pyx_t_11);
6986  __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0;
6987  __pyx_t_12 = PyNumber_Add(__pyx_t_13, __pyx_t_11); if (unlikely(!__pyx_t_12)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 665; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6988  __Pyx_GOTREF(__pyx_t_12);
6989  __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
6990  __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
6991  __pyx_t_11 = PyNumber_Add(__pyx_t_12, __pyx_kp_s__3); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 665; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
6992  __Pyx_GOTREF(__pyx_t_11);
6993  __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0;
6994 
6995  /* "PyClical.pyx":666
6996  * raise ValueError(error_msg_prefix + " from " + str(self) + " to frame "
6997  * + str(ixt) + ":"
6998  * + "\n\t" + str(err)) # <<<<<<<<<<<<<<
6999  * else:
7000  * raise TypeError(error_msg_prefix + " using (" + str(type(ixt)) + ").")
7001  */
7002  __pyx_t_12 = PyNumber_Add(__pyx_t_11, __pyx_kp_s__4); if (unlikely(!__pyx_t_12)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 666; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
7003  __Pyx_GOTREF(__pyx_t_12);
7004  __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
7005  __pyx_t_11 = PyTuple_New(1); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 666; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
7006  __Pyx_GOTREF(__pyx_t_11);
7007  __Pyx_INCREF(__pyx_v_err);
7008  __Pyx_GIVEREF(__pyx_v_err);
7009  PyTuple_SET_ITEM(__pyx_t_11, 0, __pyx_v_err);
7010  __pyx_t_13 = __Pyx_PyObject_Call(((PyObject *)(&PyString_Type)), __pyx_t_11, NULL); if (unlikely(!__pyx_t_13)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 666; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
7011  __Pyx_GOTREF(__pyx_t_13);
7012  __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
7013  __pyx_t_11 = PyNumber_Add(__pyx_t_12, __pyx_t_13); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 666; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
7014  __Pyx_GOTREF(__pyx_t_11);
7015  __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0;
7016  __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
7017 
7018  /* "PyClical.pyx":664
7019  * result.instance = new Clifford(self.unwrap(), (<index_set>ixt).unwrap())
7020  * except RuntimeError as err:
7021  * raise ValueError(error_msg_prefix + " from " + str(self) + " to frame " # <<<<<<<<<<<<<<
7022  * + str(ixt) + ":"
7023  * + "\n\t" + str(err))
7024  */
7025  __pyx_t_13 = PyTuple_New(1); if (unlikely(!__pyx_t_13)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 664; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
7026  __Pyx_GOTREF(__pyx_t_13);
7027  __Pyx_GIVEREF(__pyx_t_11);
7028  PyTuple_SET_ITEM(__pyx_t_13, 0, __pyx_t_11);
7029  __pyx_t_11 = 0;
7030  __pyx_t_11 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_t_13, NULL); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 664; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
7031  __Pyx_GOTREF(__pyx_t_11);
7032  __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
7033  __Pyx_Raise(__pyx_t_11, 0, 0, 0);
7034  __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
7035  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 664; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
7036  }
7037  goto __pyx_L6_except_error;
7038  __pyx_L6_except_error:;
7039 
7040  /* "PyClical.pyx":660
7041  * error_msg_prefix = "Cannot reframe"
7042  * if isinstance(ixt, index_set):
7043  * try: # <<<<<<<<<<<<<<
7044  * result = clifford()
7045  * result.instance = new Clifford(self.unwrap(), (<index_set>ixt).unwrap())
7046  */
7047  __Pyx_XGIVEREF(__pyx_t_3);
7048  __Pyx_XGIVEREF(__pyx_t_4);
7049  __Pyx_XGIVEREF(__pyx_t_5);
7050  __Pyx_ExceptionReset(__pyx_t_3, __pyx_t_4, __pyx_t_5);
7051  goto __pyx_L1_error;
7052  __pyx_L11_try_end:;
7053  }
7054 
7055  /* "PyClical.pyx":659
7056  * """
7057  * error_msg_prefix = "Cannot reframe"
7058  * if isinstance(ixt, index_set): # <<<<<<<<<<<<<<
7059  * try:
7060  * result = clifford()
7061  */
7062  goto __pyx_L3;
7063  }
7064 
7065  /* "PyClical.pyx":668
7066  * + "\n\t" + str(err))
7067  * else:
7068  * raise TypeError(error_msg_prefix + " using (" + str(type(ixt)) + ").") # <<<<<<<<<<<<<<
7069  * return result
7070  *
7071  */
7072  /*else*/ {
7073  __pyx_t_10 = PyNumber_Add(__pyx_v_error_msg_prefix, __pyx_kp_s_using); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 668; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7074  __Pyx_GOTREF(__pyx_t_10);
7075  __pyx_t_9 = PyTuple_New(1); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 668; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7076  __Pyx_GOTREF(__pyx_t_9);
7077  __Pyx_INCREF(((PyObject *)Py_TYPE(__pyx_v_ixt)));
7078  __Pyx_GIVEREF(((PyObject *)Py_TYPE(__pyx_v_ixt)));
7079  PyTuple_SET_ITEM(__pyx_t_9, 0, ((PyObject *)Py_TYPE(__pyx_v_ixt)));
7080  __pyx_t_6 = __Pyx_PyObject_Call(((PyObject *)(&PyString_Type)), __pyx_t_9, NULL); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 668; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7081  __Pyx_GOTREF(__pyx_t_6);
7082  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
7083  __pyx_t_9 = PyNumber_Add(__pyx_t_10, __pyx_t_6); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 668; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7084  __Pyx_GOTREF(__pyx_t_9);
7085  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
7086  __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
7087  __pyx_t_6 = PyNumber_Add(__pyx_t_9, __pyx_kp_s__7); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 668; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7088  __Pyx_GOTREF(__pyx_t_6);
7089  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
7090  __pyx_t_9 = PyTuple_New(1); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 668; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7091  __Pyx_GOTREF(__pyx_t_9);
7092  __Pyx_GIVEREF(__pyx_t_6);
7093  PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_6);
7094  __pyx_t_6 = 0;
7095  __pyx_t_6 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_t_9, NULL); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 668; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7096  __Pyx_GOTREF(__pyx_t_6);
7097  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
7098  __Pyx_Raise(__pyx_t_6, 0, 0, 0);
7099  __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
7100  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 668; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7101  }
7102  __pyx_L3:;
7103 
7104  /* "PyClical.pyx":669
7105  * else:
7106  * raise TypeError(error_msg_prefix + " using (" + str(type(ixt)) + ").")
7107  * return result # <<<<<<<<<<<<<<
7108  *
7109  * def __richcmp__(lhs, rhs, int op):
7110  */
7111  __Pyx_XDECREF(__pyx_r);
7112  __Pyx_INCREF(((PyObject *)__pyx_v_result));
7113  __pyx_r = ((PyObject *)__pyx_v_result);
7114  goto __pyx_L0;
7115 
7116  /* "PyClical.pyx":648
7117  * raise TypeError("Not applicable.")
7118  *
7119  * def reframe(self, ixt): # <<<<<<<<<<<<<<
7120  * """
7121  * Put self into a larger frame, containing the union of self.frame() and index set ixt.
7122  */
7123 
7124  /* function exit code */
7125  __pyx_L1_error:;
7126  __Pyx_XDECREF(__pyx_t_6);
7127  __Pyx_XDECREF(__pyx_t_9);
7128  __Pyx_XDECREF(__pyx_t_10);
7129  __Pyx_XDECREF(__pyx_t_11);
7130  __Pyx_XDECREF(__pyx_t_12);
7131  __Pyx_XDECREF(__pyx_t_13);
7132  __Pyx_AddTraceback("PyClical.clifford.reframe", __pyx_clineno, __pyx_lineno, __pyx_filename);
7133  __pyx_r = NULL;
7134  __pyx_L0:;
7135  __Pyx_XDECREF(__pyx_v_error_msg_prefix);
7136  __Pyx_XDECREF((PyObject *)__pyx_v_result);
7137  __Pyx_XDECREF(__pyx_v_err);
7138  __Pyx_XGIVEREF(__pyx_r);
7139  __Pyx_RefNannyFinishContext();
7140  return __pyx_r;
7141  }
7142 
7143  /* "PyClical.pyx":671
7144  * return result
7145  *
7146  * def __richcmp__(lhs, rhs, int op): # <<<<<<<<<<<<<<
7147  * """
7148  * Compare objects of type clifford.
7149  */
7150 
7151  /* Python wrapper */
7152  static PyObject *__pyx_pw_8PyClical_8clifford_13__richcmp__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs, int __pyx_v_op); /*proto*/
7153  static PyObject *__pyx_pw_8PyClical_8clifford_13__richcmp__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs, int __pyx_v_op) {
7154  PyObject *__pyx_r = 0;
7155  __Pyx_RefNannyDeclarations
7156  __Pyx_RefNannySetupContext("__richcmp__ (wrapper)", 0);
7157  __pyx_r = __pyx_pf_8PyClical_8clifford_12__richcmp__(((PyObject *)__pyx_v_lhs), ((PyObject *)__pyx_v_rhs), ((int)__pyx_v_op));
7158 
7159  /* function exit code */
7160  __Pyx_RefNannyFinishContext();
7161  return __pyx_r;
7162  }
7163 
7164  static PyObject *__pyx_pf_8PyClical_8clifford_12__richcmp__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs, int __pyx_v_op) {
7165  PyObject *__pyx_r = NULL;
7166  __Pyx_RefNannyDeclarations
7167  int __pyx_t_1;
7168  int __pyx_t_2;
7169  int __pyx_t_3;
7170  PyObject *__pyx_t_4 = NULL;
7171  PyObject *__pyx_t_5 = NULL;
7172  PyObject *__pyx_t_6 = NULL;
7173  int __pyx_lineno = 0;
7174  const char *__pyx_filename = NULL;
7175  int __pyx_clineno = 0;
7176  __Pyx_RefNannySetupContext("__richcmp__", 0);
7177 
7178  /* "PyClical.pyx":690
7179  * True
7180  * """
7181  * if op == 2: # == # <<<<<<<<<<<<<<
7182  * if (lhs is None) or (rhs is None):
7183  * return bool(lhs is rhs)
7184  */
7185  __pyx_t_1 = ((__pyx_v_op == 2) != 0);
7186  if (__pyx_t_1) {
7187 
7188  /* "PyClical.pyx":691
7189  * """
7190  * if op == 2: # ==
7191  * if (lhs is None) or (rhs is None): # <<<<<<<<<<<<<<
7192  * return bool(lhs is rhs)
7193  * else:
7194  */
7195  __pyx_t_2 = (__pyx_v_lhs == Py_None);
7196  __pyx_t_3 = (__pyx_t_2 != 0);
7197  if (!__pyx_t_3) {
7198  } else {
7199  __pyx_t_1 = __pyx_t_3;
7200  goto __pyx_L5_bool_binop_done;
7201  }
7202  __pyx_t_3 = (__pyx_v_rhs == Py_None);
7203  __pyx_t_2 = (__pyx_t_3 != 0);
7204  __pyx_t_1 = __pyx_t_2;
7205  __pyx_L5_bool_binop_done:;
7206  if (__pyx_t_1) {
7207 
7208  /* "PyClical.pyx":692
7209  * if op == 2: # ==
7210  * if (lhs is None) or (rhs is None):
7211  * return bool(lhs is rhs) # <<<<<<<<<<<<<<
7212  * else:
7213  * return bool( toClifford(lhs) == toClifford(rhs) )
7214  */
7215  __Pyx_XDECREF(__pyx_r);
7216  __pyx_t_1 = (__pyx_v_lhs == __pyx_v_rhs);
7217  __pyx_t_4 = __Pyx_PyBool_FromLong((!(!__pyx_t_1))); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 692; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7218  __Pyx_GOTREF(__pyx_t_4);
7219  __pyx_r = __pyx_t_4;
7220  __pyx_t_4 = 0;
7221  goto __pyx_L0;
7222 
7223  /* "PyClical.pyx":691
7224  * """
7225  * if op == 2: # ==
7226  * if (lhs is None) or (rhs is None): # <<<<<<<<<<<<<<
7227  * return bool(lhs is rhs)
7228  * else:
7229  */
7230  }
7231 
7232  /* "PyClical.pyx":694
7233  * return bool(lhs is rhs)
7234  * else:
7235  * return bool( toClifford(lhs) == toClifford(rhs) ) # <<<<<<<<<<<<<<
7236  * elif op == 3: # !=
7237  * if (lhs is None) or (rhs is None):
7238  */
7239  /*else*/ {
7240  __Pyx_XDECREF(__pyx_r);
7241  __pyx_t_1 = (__pyx_f_8PyClical_toClifford(__pyx_v_lhs) == __pyx_f_8PyClical_toClifford(__pyx_v_rhs));
7242  __pyx_t_4 = __Pyx_PyBool_FromLong((!(!__pyx_t_1))); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 694; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7243  __Pyx_GOTREF(__pyx_t_4);
7244  __pyx_r = __pyx_t_4;
7245  __pyx_t_4 = 0;
7246  goto __pyx_L0;
7247  }
7248 
7249  /* "PyClical.pyx":690
7250  * True
7251  * """
7252  * if op == 2: # == # <<<<<<<<<<<<<<
7253  * if (lhs is None) or (rhs is None):
7254  * return bool(lhs is rhs)
7255  */
7256  }
7257 
7258  /* "PyClical.pyx":695
7259  * else:
7260  * return bool( toClifford(lhs) == toClifford(rhs) )
7261  * elif op == 3: # != # <<<<<<<<<<<<<<
7262  * if (lhs is None) or (rhs is None):
7263  * return not bool(lhs is rhs)
7264  */
7265  __pyx_t_1 = ((__pyx_v_op == 3) != 0);
7266  if (__pyx_t_1) {
7267 
7268  /* "PyClical.pyx":696
7269  * return bool( toClifford(lhs) == toClifford(rhs) )
7270  * elif op == 3: # !=
7271  * if (lhs is None) or (rhs is None): # <<<<<<<<<<<<<<
7272  * return not bool(lhs is rhs)
7273  * else:
7274  */
7275  __pyx_t_2 = (__pyx_v_lhs == Py_None);
7276  __pyx_t_3 = (__pyx_t_2 != 0);
7277  if (!__pyx_t_3) {
7278  } else {
7279  __pyx_t_1 = __pyx_t_3;
7280  goto __pyx_L8_bool_binop_done;
7281  }
7282  __pyx_t_3 = (__pyx_v_rhs == Py_None);
7283  __pyx_t_2 = (__pyx_t_3 != 0);
7284  __pyx_t_1 = __pyx_t_2;
7285  __pyx_L8_bool_binop_done:;
7286  if (__pyx_t_1) {
7287 
7288  /* "PyClical.pyx":697
7289  * elif op == 3: # !=
7290  * if (lhs is None) or (rhs is None):
7291  * return not bool(lhs is rhs) # <<<<<<<<<<<<<<
7292  * else:
7293  * return bool( toClifford(lhs) != toClifford(rhs) )
7294  */
7295  __Pyx_XDECREF(__pyx_r);
7296  __pyx_t_1 = (__pyx_v_lhs == __pyx_v_rhs);
7297  __pyx_t_4 = __Pyx_PyBool_FromLong((!((!(!__pyx_t_1)) != 0))); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 697; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7298  __Pyx_GOTREF(__pyx_t_4);
7299  __pyx_r = __pyx_t_4;
7300  __pyx_t_4 = 0;
7301  goto __pyx_L0;
7302 
7303  /* "PyClical.pyx":696
7304  * return bool( toClifford(lhs) == toClifford(rhs) )
7305  * elif op == 3: # !=
7306  * if (lhs is None) or (rhs is None): # <<<<<<<<<<<<<<
7307  * return not bool(lhs is rhs)
7308  * else:
7309  */
7310  }
7311 
7312  /* "PyClical.pyx":699
7313  * return not bool(lhs is rhs)
7314  * else:
7315  * return bool( toClifford(lhs) != toClifford(rhs) ) # <<<<<<<<<<<<<<
7316  * elif isinstance(lhs, clifford) or isinstance(rhs, clifford):
7317  * raise TypeError("This comparison operator is not implemented for "
7318  */
7319  /*else*/ {
7320  __Pyx_XDECREF(__pyx_r);
7321  __pyx_t_1 = (__pyx_f_8PyClical_toClifford(__pyx_v_lhs) != __pyx_f_8PyClical_toClifford(__pyx_v_rhs));
7322  __pyx_t_4 = __Pyx_PyBool_FromLong((!(!__pyx_t_1))); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 699; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7323  __Pyx_GOTREF(__pyx_t_4);
7324  __pyx_r = __pyx_t_4;
7325  __pyx_t_4 = 0;
7326  goto __pyx_L0;
7327  }
7328 
7329  /* "PyClical.pyx":695
7330  * else:
7331  * return bool( toClifford(lhs) == toClifford(rhs) )
7332  * elif op == 3: # != # <<<<<<<<<<<<<<
7333  * if (lhs is None) or (rhs is None):
7334  * return not bool(lhs is rhs)
7335  */
7336  }
7337 
7338  /* "PyClical.pyx":700
7339  * else:
7340  * return bool( toClifford(lhs) != toClifford(rhs) )
7341  * elif isinstance(lhs, clifford) or isinstance(rhs, clifford): # <<<<<<<<<<<<<<
7342  * raise TypeError("This comparison operator is not implemented for "
7343  * + str(type(lhs)) + ", " + str(type(rhs)) + ".")
7344  */
7345  __pyx_t_2 = __Pyx_TypeCheck(__pyx_v_lhs, __pyx_ptype_8PyClical_clifford);
7346  __pyx_t_3 = (__pyx_t_2 != 0);
7347  if (!__pyx_t_3) {
7348  } else {
7349  __pyx_t_1 = __pyx_t_3;
7350  goto __pyx_L10_bool_binop_done;
7351  }
7352  __pyx_t_3 = __Pyx_TypeCheck(__pyx_v_rhs, __pyx_ptype_8PyClical_clifford);
7353  __pyx_t_2 = (__pyx_t_3 != 0);
7354  __pyx_t_1 = __pyx_t_2;
7355  __pyx_L10_bool_binop_done:;
7356  if (__pyx_t_1) {
7357 
7358  /* "PyClical.pyx":702
7359  * elif isinstance(lhs, clifford) or isinstance(rhs, clifford):
7360  * raise TypeError("This comparison operator is not implemented for "
7361  * + str(type(lhs)) + ", " + str(type(rhs)) + ".") # <<<<<<<<<<<<<<
7362  * else:
7363  * return NotImplemented
7364  */
7365  __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 702; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7366  __Pyx_GOTREF(__pyx_t_4);
7367  __Pyx_INCREF(((PyObject *)Py_TYPE(__pyx_v_lhs)));
7368  __Pyx_GIVEREF(((PyObject *)Py_TYPE(__pyx_v_lhs)));
7369  PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)Py_TYPE(__pyx_v_lhs)));
7370  __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)(&PyString_Type)), __pyx_t_4, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 702; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7371  __Pyx_GOTREF(__pyx_t_5);
7372  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
7373  __pyx_t_4 = PyNumber_Add(__pyx_kp_s_This_comparison_operator_is_not, __pyx_t_5); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 702; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7374  __Pyx_GOTREF(__pyx_t_4);
7375  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
7376  __pyx_t_5 = PyNumber_Add(__pyx_t_4, __pyx_kp_s__6); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 702; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7377  __Pyx_GOTREF(__pyx_t_5);
7378  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
7379  __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 702; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7380  __Pyx_GOTREF(__pyx_t_4);
7381  __Pyx_INCREF(((PyObject *)Py_TYPE(__pyx_v_rhs)));
7382  __Pyx_GIVEREF(((PyObject *)Py_TYPE(__pyx_v_rhs)));
7383  PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)Py_TYPE(__pyx_v_rhs)));
7384  __pyx_t_6 = __Pyx_PyObject_Call(((PyObject *)(&PyString_Type)), __pyx_t_4, NULL); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 702; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7385  __Pyx_GOTREF(__pyx_t_6);
7386  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
7387  __pyx_t_4 = PyNumber_Add(__pyx_t_5, __pyx_t_6); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 702; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7388  __Pyx_GOTREF(__pyx_t_4);
7389  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
7390  __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
7391  __pyx_t_6 = PyNumber_Add(__pyx_t_4, __pyx_kp_s_); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 702; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7392  __Pyx_GOTREF(__pyx_t_6);
7393  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
7394 
7395  /* "PyClical.pyx":701
7396  * return bool( toClifford(lhs) != toClifford(rhs) )
7397  * elif isinstance(lhs, clifford) or isinstance(rhs, clifford):
7398  * raise TypeError("This comparison operator is not implemented for " # <<<<<<<<<<<<<<
7399  * + str(type(lhs)) + ", " + str(type(rhs)) + ".")
7400  * else:
7401  */
7402  __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 701; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7403  __Pyx_GOTREF(__pyx_t_4);
7404  __Pyx_GIVEREF(__pyx_t_6);
7405  PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6);
7406  __pyx_t_6 = 0;
7407  __pyx_t_6 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_t_4, NULL); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 701; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7408  __Pyx_GOTREF(__pyx_t_6);
7409  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
7410  __Pyx_Raise(__pyx_t_6, 0, 0, 0);
7411  __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
7412  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 701; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7413 
7414  /* "PyClical.pyx":700
7415  * else:
7416  * return bool( toClifford(lhs) != toClifford(rhs) )
7417  * elif isinstance(lhs, clifford) or isinstance(rhs, clifford): # <<<<<<<<<<<<<<
7418  * raise TypeError("This comparison operator is not implemented for "
7419  * + str(type(lhs)) + ", " + str(type(rhs)) + ".")
7420  */
7421  }
7422 
7423  /* "PyClical.pyx":704
7424  * + str(type(lhs)) + ", " + str(type(rhs)) + ".")
7425  * else:
7426  * return NotImplemented # <<<<<<<<<<<<<<
7427  *
7428  * def __getitem__(self, ixt):
7429  */
7430  /*else*/ {
7431  __Pyx_XDECREF(__pyx_r);
7432  __Pyx_INCREF(__pyx_builtin_NotImplemented);
7433  __pyx_r = __pyx_builtin_NotImplemented;
7434  goto __pyx_L0;
7435  }
7436 
7437  /* "PyClical.pyx":671
7438  * return result
7439  *
7440  * def __richcmp__(lhs, rhs, int op): # <<<<<<<<<<<<<<
7441  * """
7442  * Compare objects of type clifford.
7443  */
7444 
7445  /* function exit code */
7446  __pyx_L1_error:;
7447  __Pyx_XDECREF(__pyx_t_4);
7448  __Pyx_XDECREF(__pyx_t_5);
7449  __Pyx_XDECREF(__pyx_t_6);
7450  __Pyx_AddTraceback("PyClical.clifford.__richcmp__", __pyx_clineno, __pyx_lineno, __pyx_filename);
7451  __pyx_r = NULL;
7452  __pyx_L0:;
7453  __Pyx_XGIVEREF(__pyx_r);
7454  __Pyx_RefNannyFinishContext();
7455  return __pyx_r;
7456  }
7457 
7458  /* "PyClical.pyx":706
7459  * return NotImplemented
7460  *
7461  * def __getitem__(self, ixt): # <<<<<<<<<<<<<<
7462  * """
7463  * Subscripting: map from index set to scalar coordinate.
7464  */
7465 
7466  /* Python wrapper */
7467  static PyObject *__pyx_pw_8PyClical_8clifford_15__getitem__(PyObject *__pyx_v_self, PyObject *__pyx_v_ixt); /*proto*/
7468  static char __pyx_doc_8PyClical_8clifford_14__getitem__[] = "\n Subscripting: map from index set to scalar coordinate.\n\n >>> clifford(\"{1}\")[index_set(1)]\n 1.0\n >>> clifford(\"{1}\")[index_set({1})]\n 1.0\n >>> clifford(\"{1}\")[index_set({1,2})]\n 0.0\n >>> clifford(\"2{1,2}\")[index_set({1,2})]\n 2.0\n ";
7469  #if CYTHON_COMPILING_IN_CPYTHON
7470  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_14__getitem__;
7471  #endif
7472  static PyObject *__pyx_pw_8PyClical_8clifford_15__getitem__(PyObject *__pyx_v_self, PyObject *__pyx_v_ixt) {
7473  PyObject *__pyx_r = 0;
7474  __Pyx_RefNannyDeclarations
7475  __Pyx_RefNannySetupContext("__getitem__ (wrapper)", 0);
7476  __pyx_r = __pyx_pf_8PyClical_8clifford_14__getitem__(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self), ((PyObject *)__pyx_v_ixt));
7477 
7478  /* function exit code */
7479  __Pyx_RefNannyFinishContext();
7480  return __pyx_r;
7481  }
7482 
7483  static PyObject *__pyx_pf_8PyClical_8clifford_14__getitem__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_ixt) {
7484  PyObject *__pyx_r = NULL;
7485  __Pyx_RefNannyDeclarations
7486  PyObject *__pyx_t_1 = NULL;
7487  int __pyx_lineno = 0;
7488  const char *__pyx_filename = NULL;
7489  int __pyx_clineno = 0;
7490  __Pyx_RefNannySetupContext("__getitem__", 0);
7491 
7492  /* "PyClical.pyx":719
7493  * 2.0
7494  * """
7495  * return self.instance.getitem(toIndexSet(ixt)) # <<<<<<<<<<<<<<
7496  *
7497  * def __neg__(self):
7498  */
7499  __Pyx_XDECREF(__pyx_r);
7500  __pyx_t_1 = PyFloat_FromDouble(__pyx_v_self->instance->operator[](__pyx_f_8PyClical_toIndexSet(__pyx_v_ixt))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 719; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7501  __Pyx_GOTREF(__pyx_t_1);
7502  __pyx_r = __pyx_t_1;
7503  __pyx_t_1 = 0;
7504  goto __pyx_L0;
7505 
7506  /* "PyClical.pyx":706
7507  * return NotImplemented
7508  *
7509  * def __getitem__(self, ixt): # <<<<<<<<<<<<<<
7510  * """
7511  * Subscripting: map from index set to scalar coordinate.
7512  */
7513 
7514  /* function exit code */
7515  __pyx_L1_error:;
7516  __Pyx_XDECREF(__pyx_t_1);
7517  __Pyx_AddTraceback("PyClical.clifford.__getitem__", __pyx_clineno, __pyx_lineno, __pyx_filename);
7518  __pyx_r = NULL;
7519  __pyx_L0:;
7520  __Pyx_XGIVEREF(__pyx_r);
7521  __Pyx_RefNannyFinishContext();
7522  return __pyx_r;
7523  }
7524 
7525  /* "PyClical.pyx":721
7526  * return self.instance.getitem(toIndexSet(ixt))
7527  *
7528  * def __neg__(self): # <<<<<<<<<<<<<<
7529  * """
7530  * Unary -.
7531  */
7532 
7533  /* Python wrapper */
7534  static PyObject *__pyx_pw_8PyClical_8clifford_17__neg__(PyObject *__pyx_v_self); /*proto*/
7535  static char __pyx_doc_8PyClical_8clifford_16__neg__[] = "\n Unary -.\n\n >>> print -clifford(\"{1}\")\n -{1}\n ";
7536  #if CYTHON_COMPILING_IN_CPYTHON
7537  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_16__neg__;
7538  #endif
7539  static PyObject *__pyx_pw_8PyClical_8clifford_17__neg__(PyObject *__pyx_v_self) {
7540  PyObject *__pyx_r = 0;
7541  __Pyx_RefNannyDeclarations
7542  __Pyx_RefNannySetupContext("__neg__ (wrapper)", 0);
7543  __pyx_r = __pyx_pf_8PyClical_8clifford_16__neg__(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self));
7544 
7545  /* function exit code */
7546  __Pyx_RefNannyFinishContext();
7547  return __pyx_r;
7548  }
7549 
7550  static PyObject *__pyx_pf_8PyClical_8clifford_16__neg__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self) {
7551  PyObject *__pyx_r = NULL;
7552  __Pyx_RefNannyDeclarations
7553  PyObject *__pyx_t_1 = NULL;
7554  PyObject *__pyx_t_2 = NULL;
7555  int __pyx_lineno = 0;
7556  const char *__pyx_filename = NULL;
7557  int __pyx_clineno = 0;
7558  __Pyx_RefNannySetupContext("__neg__", 0);
7559 
7560  /* "PyClical.pyx":728
7561  * -{1}
7562  * """
7563  * return clifford().wrap( self.instance.neg() ) # <<<<<<<<<<<<<<
7564  *
7565  * def __pos__(self):
7566  */
7567  __Pyx_XDECREF(__pyx_r);
7568  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 728; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7569  __Pyx_GOTREF(__pyx_t_1);
7570  __pyx_t_2 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), __pyx_v_self->instance->operator-()); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 728; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7571  __Pyx_GOTREF(__pyx_t_2);
7572  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
7573  __pyx_r = __pyx_t_2;
7574  __pyx_t_2 = 0;
7575  goto __pyx_L0;
7576 
7577  /* "PyClical.pyx":721
7578  * return self.instance.getitem(toIndexSet(ixt))
7579  *
7580  * def __neg__(self): # <<<<<<<<<<<<<<
7581  * """
7582  * Unary -.
7583  */
7584 
7585  /* function exit code */
7586  __pyx_L1_error:;
7587  __Pyx_XDECREF(__pyx_t_1);
7588  __Pyx_XDECREF(__pyx_t_2);
7589  __Pyx_AddTraceback("PyClical.clifford.__neg__", __pyx_clineno, __pyx_lineno, __pyx_filename);
7590  __pyx_r = NULL;
7591  __pyx_L0:;
7592  __Pyx_XGIVEREF(__pyx_r);
7593  __Pyx_RefNannyFinishContext();
7594  return __pyx_r;
7595  }
7596 
7597  /* "PyClical.pyx":730
7598  * return clifford().wrap( self.instance.neg() )
7599  *
7600  * def __pos__(self): # <<<<<<<<<<<<<<
7601  * """
7602  * Unary +.
7603  */
7604 
7605  /* Python wrapper */
7606  static PyObject *__pyx_pw_8PyClical_8clifford_19__pos__(PyObject *__pyx_v_self); /*proto*/
7607  static char __pyx_doc_8PyClical_8clifford_18__pos__[] = "\n Unary +.\n\n >>> print +clifford(\"{1}\")\n {1}\n ";
7608  #if CYTHON_COMPILING_IN_CPYTHON
7609  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_18__pos__;
7610  #endif
7611  static PyObject *__pyx_pw_8PyClical_8clifford_19__pos__(PyObject *__pyx_v_self) {
7612  PyObject *__pyx_r = 0;
7613  __Pyx_RefNannyDeclarations
7614  __Pyx_RefNannySetupContext("__pos__ (wrapper)", 0);
7615  __pyx_r = __pyx_pf_8PyClical_8clifford_18__pos__(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self));
7616 
7617  /* function exit code */
7618  __Pyx_RefNannyFinishContext();
7619  return __pyx_r;
7620  }
7621 
7622  static PyObject *__pyx_pf_8PyClical_8clifford_18__pos__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self) {
7623  PyObject *__pyx_r = NULL;
7624  __Pyx_RefNannyDeclarations
7625  PyObject *__pyx_t_1 = NULL;
7626  PyObject *__pyx_t_2 = NULL;
7627  int __pyx_lineno = 0;
7628  const char *__pyx_filename = NULL;
7629  int __pyx_clineno = 0;
7630  __Pyx_RefNannySetupContext("__pos__", 0);
7631 
7632  /* "PyClical.pyx":737
7633  * {1}
7634  * """
7635  * return clifford(self) # <<<<<<<<<<<<<<
7636  *
7637  * def __add__(lhs, rhs):
7638  */
7639  __Pyx_XDECREF(__pyx_r);
7640  __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 737; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7641  __Pyx_GOTREF(__pyx_t_1);
7642  __Pyx_INCREF(((PyObject *)__pyx_v_self));
7643  __Pyx_GIVEREF(((PyObject *)__pyx_v_self));
7644  PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self));
7645  __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 737; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7646  __Pyx_GOTREF(__pyx_t_2);
7647  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
7648  __pyx_r = __pyx_t_2;
7649  __pyx_t_2 = 0;
7650  goto __pyx_L0;
7651 
7652  /* "PyClical.pyx":730
7653  * return clifford().wrap( self.instance.neg() )
7654  *
7655  * def __pos__(self): # <<<<<<<<<<<<<<
7656  * """
7657  * Unary +.
7658  */
7659 
7660  /* function exit code */
7661  __pyx_L1_error:;
7662  __Pyx_XDECREF(__pyx_t_1);
7663  __Pyx_XDECREF(__pyx_t_2);
7664  __Pyx_AddTraceback("PyClical.clifford.__pos__", __pyx_clineno, __pyx_lineno, __pyx_filename);
7665  __pyx_r = NULL;
7666  __pyx_L0:;
7667  __Pyx_XGIVEREF(__pyx_r);
7668  __Pyx_RefNannyFinishContext();
7669  return __pyx_r;
7670  }
7671 
7672  /* "PyClical.pyx":739
7673  * return clifford(self)
7674  *
7675  * def __add__(lhs, rhs): # <<<<<<<<<<<<<<
7676  * """
7677  * Geometric sum.
7678  */
7679 
7680  /* Python wrapper */
7681  static PyObject *__pyx_pw_8PyClical_8clifford_21__add__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs); /*proto*/
7682  static char __pyx_doc_8PyClical_8clifford_20__add__[] = "\n Geometric sum.\n\n >>> print clifford(1) + clifford(\"{2}\")\n 1+{2}\n >>> print clifford(\"{1}\") + clifford(\"{2}\")\n {1}+{2}\n ";
7683  #if CYTHON_COMPILING_IN_CPYTHON
7684  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_20__add__;
7685  #endif
7686  static PyObject *__pyx_pw_8PyClical_8clifford_21__add__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs) {
7687  PyObject *__pyx_r = 0;
7688  __Pyx_RefNannyDeclarations
7689  __Pyx_RefNannySetupContext("__add__ (wrapper)", 0);
7690  __pyx_r = __pyx_pf_8PyClical_8clifford_20__add__(((PyObject *)__pyx_v_lhs), ((PyObject *)__pyx_v_rhs));
7691 
7692  /* function exit code */
7693  __Pyx_RefNannyFinishContext();
7694  return __pyx_r;
7695  }
7696 
7697  static PyObject *__pyx_pf_8PyClical_8clifford_20__add__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs) {
7698  PyObject *__pyx_r = NULL;
7699  __Pyx_RefNannyDeclarations
7700  PyObject *__pyx_t_1 = NULL;
7701  PyObject *__pyx_t_2 = NULL;
7702  int __pyx_lineno = 0;
7703  const char *__pyx_filename = NULL;
7704  int __pyx_clineno = 0;
7705  __Pyx_RefNannySetupContext("__add__", 0);
7706 
7707  /* "PyClical.pyx":748
7708  * {1}+{2}
7709  * """
7710  * return clifford().wrap( toClifford(lhs) + toClifford(rhs) ) # <<<<<<<<<<<<<<
7711  *
7712  * def __iadd__(self, rhs):
7713  */
7714  __Pyx_XDECREF(__pyx_r);
7715  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 748; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7716  __Pyx_GOTREF(__pyx_t_1);
7717  __pyx_t_2 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), (__pyx_f_8PyClical_toClifford(__pyx_v_lhs) + __pyx_f_8PyClical_toClifford(__pyx_v_rhs))); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 748; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7718  __Pyx_GOTREF(__pyx_t_2);
7719  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
7720  __pyx_r = __pyx_t_2;
7721  __pyx_t_2 = 0;
7722  goto __pyx_L0;
7723 
7724  /* "PyClical.pyx":739
7725  * return clifford(self)
7726  *
7727  * def __add__(lhs, rhs): # <<<<<<<<<<<<<<
7728  * """
7729  * Geometric sum.
7730  */
7731 
7732  /* function exit code */
7733  __pyx_L1_error:;
7734  __Pyx_XDECREF(__pyx_t_1);
7735  __Pyx_XDECREF(__pyx_t_2);
7736  __Pyx_AddTraceback("PyClical.clifford.__add__", __pyx_clineno, __pyx_lineno, __pyx_filename);
7737  __pyx_r = NULL;
7738  __pyx_L0:;
7739  __Pyx_XGIVEREF(__pyx_r);
7740  __Pyx_RefNannyFinishContext();
7741  return __pyx_r;
7742  }
7743 
7744  /* "PyClical.pyx":750
7745  * return clifford().wrap( toClifford(lhs) + toClifford(rhs) )
7746  *
7747  * def __iadd__(self, rhs): # <<<<<<<<<<<<<<
7748  * """
7749  * Geometric sum.
7750  */
7751 
7752  /* Python wrapper */
7753  static PyObject *__pyx_pw_8PyClical_8clifford_23__iadd__(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs); /*proto*/
7754  static char __pyx_doc_8PyClical_8clifford_22__iadd__[] = "\n Geometric sum.\n\n >>> x = clifford(1); x += clifford(\"{2}\"); print x\n 1+{2}\n ";
7755  #if CYTHON_COMPILING_IN_CPYTHON
7756  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_22__iadd__;
7757  #endif
7758  static PyObject *__pyx_pw_8PyClical_8clifford_23__iadd__(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs) {
7759  PyObject *__pyx_r = 0;
7760  __Pyx_RefNannyDeclarations
7761  __Pyx_RefNannySetupContext("__iadd__ (wrapper)", 0);
7762  __pyx_r = __pyx_pf_8PyClical_8clifford_22__iadd__(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self), ((PyObject *)__pyx_v_rhs));
7763 
7764  /* function exit code */
7765  __Pyx_RefNannyFinishContext();
7766  return __pyx_r;
7767  }
7768 
7769  static PyObject *__pyx_pf_8PyClical_8clifford_22__iadd__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_rhs) {
7770  PyObject *__pyx_r = NULL;
7771  __Pyx_RefNannyDeclarations
7772  PyObject *__pyx_t_1 = NULL;
7773  int __pyx_lineno = 0;
7774  const char *__pyx_filename = NULL;
7775  int __pyx_clineno = 0;
7776  __Pyx_RefNannySetupContext("__iadd__", 0);
7777 
7778  /* "PyClical.pyx":757
7779  * 1+{2}
7780  * """
7781  * return self.wrap( self.unwrap() + toClifford(rhs) ) # <<<<<<<<<<<<<<
7782  *
7783  * def __sub__(lhs, rhs):
7784  */
7785  __Pyx_XDECREF(__pyx_r);
7786  __pyx_t_1 = __pyx_f_8PyClical_8clifford_wrap(__pyx_v_self, (__pyx_f_8PyClical_8clifford_unwrap(__pyx_v_self) + __pyx_f_8PyClical_toClifford(__pyx_v_rhs))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 757; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7787  __Pyx_GOTREF(__pyx_t_1);
7788  __pyx_r = __pyx_t_1;
7789  __pyx_t_1 = 0;
7790  goto __pyx_L0;
7791 
7792  /* "PyClical.pyx":750
7793  * return clifford().wrap( toClifford(lhs) + toClifford(rhs) )
7794  *
7795  * def __iadd__(self, rhs): # <<<<<<<<<<<<<<
7796  * """
7797  * Geometric sum.
7798  */
7799 
7800  /* function exit code */
7801  __pyx_L1_error:;
7802  __Pyx_XDECREF(__pyx_t_1);
7803  __Pyx_AddTraceback("PyClical.clifford.__iadd__", __pyx_clineno, __pyx_lineno, __pyx_filename);
7804  __pyx_r = NULL;
7805  __pyx_L0:;
7806  __Pyx_XGIVEREF(__pyx_r);
7807  __Pyx_RefNannyFinishContext();
7808  return __pyx_r;
7809  }
7810 
7811  /* "PyClical.pyx":759
7812  * return self.wrap( self.unwrap() + toClifford(rhs) )
7813  *
7814  * def __sub__(lhs, rhs): # <<<<<<<<<<<<<<
7815  * """
7816  * Geometric difference.
7817  */
7818 
7819  /* Python wrapper */
7820  static PyObject *__pyx_pw_8PyClical_8clifford_25__sub__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs); /*proto*/
7821  static char __pyx_doc_8PyClical_8clifford_24__sub__[] = "\n Geometric difference.\n\n >>> print clifford(1) - clifford(\"{2}\")\n 1-{2}\n >>> print clifford(\"{1}\") - clifford(\"{2}\")\n {1}-{2}\n ";
7822  #if CYTHON_COMPILING_IN_CPYTHON
7823  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_24__sub__;
7824  #endif
7825  static PyObject *__pyx_pw_8PyClical_8clifford_25__sub__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs) {
7826  PyObject *__pyx_r = 0;
7827  __Pyx_RefNannyDeclarations
7828  __Pyx_RefNannySetupContext("__sub__ (wrapper)", 0);
7829  __pyx_r = __pyx_pf_8PyClical_8clifford_24__sub__(((PyObject *)__pyx_v_lhs), ((PyObject *)__pyx_v_rhs));
7830 
7831  /* function exit code */
7832  __Pyx_RefNannyFinishContext();
7833  return __pyx_r;
7834  }
7835 
7836  static PyObject *__pyx_pf_8PyClical_8clifford_24__sub__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs) {
7837  PyObject *__pyx_r = NULL;
7838  __Pyx_RefNannyDeclarations
7839  PyObject *__pyx_t_1 = NULL;
7840  PyObject *__pyx_t_2 = NULL;
7841  int __pyx_lineno = 0;
7842  const char *__pyx_filename = NULL;
7843  int __pyx_clineno = 0;
7844  __Pyx_RefNannySetupContext("__sub__", 0);
7845 
7846  /* "PyClical.pyx":768
7847  * {1}-{2}
7848  * """
7849  * return clifford().wrap( toClifford(lhs) - toClifford(rhs) ) # <<<<<<<<<<<<<<
7850  *
7851  * def __isub__(self, rhs):
7852  */
7853  __Pyx_XDECREF(__pyx_r);
7854  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 768; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7855  __Pyx_GOTREF(__pyx_t_1);
7856  __pyx_t_2 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), (__pyx_f_8PyClical_toClifford(__pyx_v_lhs) - __pyx_f_8PyClical_toClifford(__pyx_v_rhs))); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 768; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7857  __Pyx_GOTREF(__pyx_t_2);
7858  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
7859  __pyx_r = __pyx_t_2;
7860  __pyx_t_2 = 0;
7861  goto __pyx_L0;
7862 
7863  /* "PyClical.pyx":759
7864  * return self.wrap( self.unwrap() + toClifford(rhs) )
7865  *
7866  * def __sub__(lhs, rhs): # <<<<<<<<<<<<<<
7867  * """
7868  * Geometric difference.
7869  */
7870 
7871  /* function exit code */
7872  __pyx_L1_error:;
7873  __Pyx_XDECREF(__pyx_t_1);
7874  __Pyx_XDECREF(__pyx_t_2);
7875  __Pyx_AddTraceback("PyClical.clifford.__sub__", __pyx_clineno, __pyx_lineno, __pyx_filename);
7876  __pyx_r = NULL;
7877  __pyx_L0:;
7878  __Pyx_XGIVEREF(__pyx_r);
7879  __Pyx_RefNannyFinishContext();
7880  return __pyx_r;
7881  }
7882 
7883  /* "PyClical.pyx":770
7884  * return clifford().wrap( toClifford(lhs) - toClifford(rhs) )
7885  *
7886  * def __isub__(self, rhs): # <<<<<<<<<<<<<<
7887  * """
7888  * Geometric difference.
7889  */
7890 
7891  /* Python wrapper */
7892  static PyObject *__pyx_pw_8PyClical_8clifford_27__isub__(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs); /*proto*/
7893  static char __pyx_doc_8PyClical_8clifford_26__isub__[] = "\n Geometric difference.\n\n >>> x = clifford(1); x -= clifford(\"{2}\"); print x\n 1-{2}\n ";
7894  #if CYTHON_COMPILING_IN_CPYTHON
7895  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_26__isub__;
7896  #endif
7897  static PyObject *__pyx_pw_8PyClical_8clifford_27__isub__(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs) {
7898  PyObject *__pyx_r = 0;
7899  __Pyx_RefNannyDeclarations
7900  __Pyx_RefNannySetupContext("__isub__ (wrapper)", 0);
7901  __pyx_r = __pyx_pf_8PyClical_8clifford_26__isub__(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self), ((PyObject *)__pyx_v_rhs));
7902 
7903  /* function exit code */
7904  __Pyx_RefNannyFinishContext();
7905  return __pyx_r;
7906  }
7907 
7908  static PyObject *__pyx_pf_8PyClical_8clifford_26__isub__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_rhs) {
7909  PyObject *__pyx_r = NULL;
7910  __Pyx_RefNannyDeclarations
7911  PyObject *__pyx_t_1 = NULL;
7912  int __pyx_lineno = 0;
7913  const char *__pyx_filename = NULL;
7914  int __pyx_clineno = 0;
7915  __Pyx_RefNannySetupContext("__isub__", 0);
7916 
7917  /* "PyClical.pyx":777
7918  * 1-{2}
7919  * """
7920  * return self.wrap( self.unwrap() - toClifford(rhs) ) # <<<<<<<<<<<<<<
7921  *
7922  * def __mul__(lhs, rhs):
7923  */
7924  __Pyx_XDECREF(__pyx_r);
7925  __pyx_t_1 = __pyx_f_8PyClical_8clifford_wrap(__pyx_v_self, (__pyx_f_8PyClical_8clifford_unwrap(__pyx_v_self) - __pyx_f_8PyClical_toClifford(__pyx_v_rhs))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 777; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7926  __Pyx_GOTREF(__pyx_t_1);
7927  __pyx_r = __pyx_t_1;
7928  __pyx_t_1 = 0;
7929  goto __pyx_L0;
7930 
7931  /* "PyClical.pyx":770
7932  * return clifford().wrap( toClifford(lhs) - toClifford(rhs) )
7933  *
7934  * def __isub__(self, rhs): # <<<<<<<<<<<<<<
7935  * """
7936  * Geometric difference.
7937  */
7938 
7939  /* function exit code */
7940  __pyx_L1_error:;
7941  __Pyx_XDECREF(__pyx_t_1);
7942  __Pyx_AddTraceback("PyClical.clifford.__isub__", __pyx_clineno, __pyx_lineno, __pyx_filename);
7943  __pyx_r = NULL;
7944  __pyx_L0:;
7945  __Pyx_XGIVEREF(__pyx_r);
7946  __Pyx_RefNannyFinishContext();
7947  return __pyx_r;
7948  }
7949 
7950  /* "PyClical.pyx":779
7951  * return self.wrap( self.unwrap() - toClifford(rhs) )
7952  *
7953  * def __mul__(lhs, rhs): # <<<<<<<<<<<<<<
7954  * """
7955  * Geometric product.
7956  */
7957 
7958  /* Python wrapper */
7959  static PyObject *__pyx_pw_8PyClical_8clifford_29__mul__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs); /*proto*/
7960  static char __pyx_doc_8PyClical_8clifford_28__mul__[] = "\n Geometric product.\n\n >>> print clifford(\"{1}\") * clifford(\"{2}\")\n {1,2}\n >>> print clifford(2) * clifford(\"{2}\")\n 2{2}\n >>> print clifford(\"{1}\") * clifford(\"{1,2}\")\n {2}\n ";
7961  #if CYTHON_COMPILING_IN_CPYTHON
7962  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_28__mul__;
7963  #endif
7964  static PyObject *__pyx_pw_8PyClical_8clifford_29__mul__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs) {
7965  PyObject *__pyx_r = 0;
7966  __Pyx_RefNannyDeclarations
7967  __Pyx_RefNannySetupContext("__mul__ (wrapper)", 0);
7968  __pyx_r = __pyx_pf_8PyClical_8clifford_28__mul__(((PyObject *)__pyx_v_lhs), ((PyObject *)__pyx_v_rhs));
7969 
7970  /* function exit code */
7971  __Pyx_RefNannyFinishContext();
7972  return __pyx_r;
7973  }
7974 
7975  static PyObject *__pyx_pf_8PyClical_8clifford_28__mul__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs) {
7976  PyObject *__pyx_r = NULL;
7977  __Pyx_RefNannyDeclarations
7978  PyObject *__pyx_t_1 = NULL;
7979  PyObject *__pyx_t_2 = NULL;
7980  int __pyx_lineno = 0;
7981  const char *__pyx_filename = NULL;
7982  int __pyx_clineno = 0;
7983  __Pyx_RefNannySetupContext("__mul__", 0);
7984 
7985  /* "PyClical.pyx":790
7986  * {2}
7987  * """
7988  * return clifford().wrap( toClifford(lhs) * toClifford(rhs) ) # <<<<<<<<<<<<<<
7989  *
7990  * def __imul__(self, rhs):
7991  */
7992  __Pyx_XDECREF(__pyx_r);
7993  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 790; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7994  __Pyx_GOTREF(__pyx_t_1);
7995  __pyx_t_2 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), (__pyx_f_8PyClical_toClifford(__pyx_v_lhs) * __pyx_f_8PyClical_toClifford(__pyx_v_rhs))); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 790; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
7996  __Pyx_GOTREF(__pyx_t_2);
7997  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
7998  __pyx_r = __pyx_t_2;
7999  __pyx_t_2 = 0;
8000  goto __pyx_L0;
8001 
8002  /* "PyClical.pyx":779
8003  * return self.wrap( self.unwrap() - toClifford(rhs) )
8004  *
8005  * def __mul__(lhs, rhs): # <<<<<<<<<<<<<<
8006  * """
8007  * Geometric product.
8008  */
8009 
8010  /* function exit code */
8011  __pyx_L1_error:;
8012  __Pyx_XDECREF(__pyx_t_1);
8013  __Pyx_XDECREF(__pyx_t_2);
8014  __Pyx_AddTraceback("PyClical.clifford.__mul__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8015  __pyx_r = NULL;
8016  __pyx_L0:;
8017  __Pyx_XGIVEREF(__pyx_r);
8018  __Pyx_RefNannyFinishContext();
8019  return __pyx_r;
8020  }
8021 
8022  /* "PyClical.pyx":792
8023  * return clifford().wrap( toClifford(lhs) * toClifford(rhs) )
8024  *
8025  * def __imul__(self, rhs): # <<<<<<<<<<<<<<
8026  * """
8027  * Geometric product.
8028  */
8029 
8030  /* Python wrapper */
8031  static PyObject *__pyx_pw_8PyClical_8clifford_31__imul__(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs); /*proto*/
8032  static char __pyx_doc_8PyClical_8clifford_30__imul__[] = "\n Geometric product.\n\n >>> x = clifford(2); x *= clifford(\"{2}\"); print x\n 2{2}\n >>> x = clifford(\"{1}\"); x *= clifford(\"{2}\"); print x\n {1,2}\n >>> x = clifford(\"{1}\"); x *= clifford(\"{1,2}\"); print x\n {2}\n ";
8033  #if CYTHON_COMPILING_IN_CPYTHON
8034  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_30__imul__;
8035  #endif
8036  static PyObject *__pyx_pw_8PyClical_8clifford_31__imul__(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs) {
8037  PyObject *__pyx_r = 0;
8038  __Pyx_RefNannyDeclarations
8039  __Pyx_RefNannySetupContext("__imul__ (wrapper)", 0);
8040  __pyx_r = __pyx_pf_8PyClical_8clifford_30__imul__(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self), ((PyObject *)__pyx_v_rhs));
8041 
8042  /* function exit code */
8043  __Pyx_RefNannyFinishContext();
8044  return __pyx_r;
8045  }
8046 
8047  static PyObject *__pyx_pf_8PyClical_8clifford_30__imul__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_rhs) {
8048  PyObject *__pyx_r = NULL;
8049  __Pyx_RefNannyDeclarations
8050  PyObject *__pyx_t_1 = NULL;
8051  int __pyx_lineno = 0;
8052  const char *__pyx_filename = NULL;
8053  int __pyx_clineno = 0;
8054  __Pyx_RefNannySetupContext("__imul__", 0);
8055 
8056  /* "PyClical.pyx":803
8057  * {2}
8058  * """
8059  * return self.wrap( self.unwrap() * toClifford(rhs) ) # <<<<<<<<<<<<<<
8060  *
8061  * def __mod__(lhs, rhs):
8062  */
8063  __Pyx_XDECREF(__pyx_r);
8064  __pyx_t_1 = __pyx_f_8PyClical_8clifford_wrap(__pyx_v_self, (__pyx_f_8PyClical_8clifford_unwrap(__pyx_v_self) * __pyx_f_8PyClical_toClifford(__pyx_v_rhs))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 803; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8065  __Pyx_GOTREF(__pyx_t_1);
8066  __pyx_r = __pyx_t_1;
8067  __pyx_t_1 = 0;
8068  goto __pyx_L0;
8069 
8070  /* "PyClical.pyx":792
8071  * return clifford().wrap( toClifford(lhs) * toClifford(rhs) )
8072  *
8073  * def __imul__(self, rhs): # <<<<<<<<<<<<<<
8074  * """
8075  * Geometric product.
8076  */
8077 
8078  /* function exit code */
8079  __pyx_L1_error:;
8080  __Pyx_XDECREF(__pyx_t_1);
8081  __Pyx_AddTraceback("PyClical.clifford.__imul__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8082  __pyx_r = NULL;
8083  __pyx_L0:;
8084  __Pyx_XGIVEREF(__pyx_r);
8085  __Pyx_RefNannyFinishContext();
8086  return __pyx_r;
8087  }
8088 
8089  /* "PyClical.pyx":805
8090  * return self.wrap( self.unwrap() * toClifford(rhs) )
8091  *
8092  * def __mod__(lhs, rhs): # <<<<<<<<<<<<<<
8093  * """
8094  * Contraction.
8095  */
8096 
8097  /* Python wrapper */
8098  static PyObject *__pyx_pw_8PyClical_8clifford_33__mod__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs); /*proto*/
8099  static char __pyx_doc_8PyClical_8clifford_32__mod__[] = "\n Contraction.\n\n >>> print clifford(\"{1}\") % clifford(\"{2}\")\n 0\n >>> print clifford(2) % clifford(\"{2}\")\n 2{2}\n >>> print clifford(\"{1}\") % clifford(\"{1}\")\n 1\n >>> print clifford(\"{1}\") % clifford(\"{1,2}\")\n {2}\n ";
8100  #if CYTHON_COMPILING_IN_CPYTHON
8101  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_32__mod__;
8102  #endif
8103  static PyObject *__pyx_pw_8PyClical_8clifford_33__mod__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs) {
8104  PyObject *__pyx_r = 0;
8105  __Pyx_RefNannyDeclarations
8106  __Pyx_RefNannySetupContext("__mod__ (wrapper)", 0);
8107  __pyx_r = __pyx_pf_8PyClical_8clifford_32__mod__(((PyObject *)__pyx_v_lhs), ((PyObject *)__pyx_v_rhs));
8108 
8109  /* function exit code */
8110  __Pyx_RefNannyFinishContext();
8111  return __pyx_r;
8112  }
8113 
8114  static PyObject *__pyx_pf_8PyClical_8clifford_32__mod__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs) {
8115  PyObject *__pyx_r = NULL;
8116  __Pyx_RefNannyDeclarations
8117  PyObject *__pyx_t_1 = NULL;
8118  PyObject *__pyx_t_2 = NULL;
8119  int __pyx_lineno = 0;
8120  const char *__pyx_filename = NULL;
8121  int __pyx_clineno = 0;
8122  __Pyx_RefNannySetupContext("__mod__", 0);
8123 
8124  /* "PyClical.pyx":818
8125  * {2}
8126  * """
8127  * return clifford().wrap( toClifford(lhs) % toClifford(rhs) ) # <<<<<<<<<<<<<<
8128  *
8129  * def __imod__(self, rhs):
8130  */
8131  __Pyx_XDECREF(__pyx_r);
8132  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 818; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8133  __Pyx_GOTREF(__pyx_t_1);
8134  __pyx_t_2 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), (__pyx_f_8PyClical_toClifford(__pyx_v_lhs) % __pyx_f_8PyClical_toClifford(__pyx_v_rhs))); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 818; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8135  __Pyx_GOTREF(__pyx_t_2);
8136  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
8137  __pyx_r = __pyx_t_2;
8138  __pyx_t_2 = 0;
8139  goto __pyx_L0;
8140 
8141  /* "PyClical.pyx":805
8142  * return self.wrap( self.unwrap() * toClifford(rhs) )
8143  *
8144  * def __mod__(lhs, rhs): # <<<<<<<<<<<<<<
8145  * """
8146  * Contraction.
8147  */
8148 
8149  /* function exit code */
8150  __pyx_L1_error:;
8151  __Pyx_XDECREF(__pyx_t_1);
8152  __Pyx_XDECREF(__pyx_t_2);
8153  __Pyx_AddTraceback("PyClical.clifford.__mod__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8154  __pyx_r = NULL;
8155  __pyx_L0:;
8156  __Pyx_XGIVEREF(__pyx_r);
8157  __Pyx_RefNannyFinishContext();
8158  return __pyx_r;
8159  }
8160 
8161  /* "PyClical.pyx":820
8162  * return clifford().wrap( toClifford(lhs) % toClifford(rhs) )
8163  *
8164  * def __imod__(self, rhs): # <<<<<<<<<<<<<<
8165  * """
8166  * Contraction.
8167  */
8168 
8169  /* Python wrapper */
8170  static PyObject *__pyx_pw_8PyClical_8clifford_35__imod__(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs); /*proto*/
8171  static char __pyx_doc_8PyClical_8clifford_34__imod__[] = "\n Contraction.\n\n >>> x = clifford(\"{1}\"); x %= clifford(\"{2}\"); print x\n 0\n >>> x = clifford(2); x %= clifford(\"{2}\"); print x\n 2{2}\n >>> x = clifford(\"{1}\"); x %= clifford(\"{1}\"); print x\n 1\n >>> x = clifford(\"{1}\"); x %= clifford(\"{1,2}\"); print x\n {2}\n ";
8172  #if CYTHON_COMPILING_IN_CPYTHON
8173  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_34__imod__;
8174  #endif
8175  static PyObject *__pyx_pw_8PyClical_8clifford_35__imod__(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs) {
8176  PyObject *__pyx_r = 0;
8177  __Pyx_RefNannyDeclarations
8178  __Pyx_RefNannySetupContext("__imod__ (wrapper)", 0);
8179  __pyx_r = __pyx_pf_8PyClical_8clifford_34__imod__(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self), ((PyObject *)__pyx_v_rhs));
8180 
8181  /* function exit code */
8182  __Pyx_RefNannyFinishContext();
8183  return __pyx_r;
8184  }
8185 
8186  static PyObject *__pyx_pf_8PyClical_8clifford_34__imod__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_rhs) {
8187  PyObject *__pyx_r = NULL;
8188  __Pyx_RefNannyDeclarations
8189  PyObject *__pyx_t_1 = NULL;
8190  int __pyx_lineno = 0;
8191  const char *__pyx_filename = NULL;
8192  int __pyx_clineno = 0;
8193  __Pyx_RefNannySetupContext("__imod__", 0);
8194 
8195  /* "PyClical.pyx":833
8196  * {2}
8197  * """
8198  * return self.wrap( self.unwrap() % toClifford(rhs) ) # <<<<<<<<<<<<<<
8199  *
8200  * def __and__(lhs, rhs):
8201  */
8202  __Pyx_XDECREF(__pyx_r);
8203  __pyx_t_1 = __pyx_f_8PyClical_8clifford_wrap(__pyx_v_self, (__pyx_f_8PyClical_8clifford_unwrap(__pyx_v_self) % __pyx_f_8PyClical_toClifford(__pyx_v_rhs))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 833; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8204  __Pyx_GOTREF(__pyx_t_1);
8205  __pyx_r = __pyx_t_1;
8206  __pyx_t_1 = 0;
8207  goto __pyx_L0;
8208 
8209  /* "PyClical.pyx":820
8210  * return clifford().wrap( toClifford(lhs) % toClifford(rhs) )
8211  *
8212  * def __imod__(self, rhs): # <<<<<<<<<<<<<<
8213  * """
8214  * Contraction.
8215  */
8216 
8217  /* function exit code */
8218  __pyx_L1_error:;
8219  __Pyx_XDECREF(__pyx_t_1);
8220  __Pyx_AddTraceback("PyClical.clifford.__imod__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8221  __pyx_r = NULL;
8222  __pyx_L0:;
8223  __Pyx_XGIVEREF(__pyx_r);
8224  __Pyx_RefNannyFinishContext();
8225  return __pyx_r;
8226  }
8227 
8228  /* "PyClical.pyx":835
8229  * return self.wrap( self.unwrap() % toClifford(rhs) )
8230  *
8231  * def __and__(lhs, rhs): # <<<<<<<<<<<<<<
8232  * """
8233  * Inner product.
8234  */
8235 
8236  /* Python wrapper */
8237  static PyObject *__pyx_pw_8PyClical_8clifford_37__and__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs); /*proto*/
8238  static char __pyx_doc_8PyClical_8clifford_36__and__[] = "\n Inner product.\n\n >>> print clifford(\"{1}\") & clifford(\"{2}\")\n 0\n >>> print clifford(2) & clifford(\"{2}\")\n 0\n >>> print clifford(\"{1}\") & clifford(\"{1}\")\n 1\n >>> print clifford(\"{1}\") & clifford(\"{1,2}\")\n {2}\n ";
8239  #if CYTHON_COMPILING_IN_CPYTHON
8240  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_36__and__;
8241  #endif
8242  static PyObject *__pyx_pw_8PyClical_8clifford_37__and__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs) {
8243  PyObject *__pyx_r = 0;
8244  __Pyx_RefNannyDeclarations
8245  __Pyx_RefNannySetupContext("__and__ (wrapper)", 0);
8246  __pyx_r = __pyx_pf_8PyClical_8clifford_36__and__(((PyObject *)__pyx_v_lhs), ((PyObject *)__pyx_v_rhs));
8247 
8248  /* function exit code */
8249  __Pyx_RefNannyFinishContext();
8250  return __pyx_r;
8251  }
8252 
8253  static PyObject *__pyx_pf_8PyClical_8clifford_36__and__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs) {
8254  PyObject *__pyx_r = NULL;
8255  __Pyx_RefNannyDeclarations
8256  PyObject *__pyx_t_1 = NULL;
8257  PyObject *__pyx_t_2 = NULL;
8258  int __pyx_lineno = 0;
8259  const char *__pyx_filename = NULL;
8260  int __pyx_clineno = 0;
8261  __Pyx_RefNannySetupContext("__and__", 0);
8262 
8263  /* "PyClical.pyx":848
8264  * {2}
8265  * """
8266  * return clifford().wrap( toClifford(lhs) & toClifford(rhs) ) # <<<<<<<<<<<<<<
8267  *
8268  * def __iand__(self, rhs):
8269  */
8270  __Pyx_XDECREF(__pyx_r);
8271  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 848; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8272  __Pyx_GOTREF(__pyx_t_1);
8273  __pyx_t_2 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), (__pyx_f_8PyClical_toClifford(__pyx_v_lhs) & __pyx_f_8PyClical_toClifford(__pyx_v_rhs))); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 848; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8274  __Pyx_GOTREF(__pyx_t_2);
8275  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
8276  __pyx_r = __pyx_t_2;
8277  __pyx_t_2 = 0;
8278  goto __pyx_L0;
8279 
8280  /* "PyClical.pyx":835
8281  * return self.wrap( self.unwrap() % toClifford(rhs) )
8282  *
8283  * def __and__(lhs, rhs): # <<<<<<<<<<<<<<
8284  * """
8285  * Inner product.
8286  */
8287 
8288  /* function exit code */
8289  __pyx_L1_error:;
8290  __Pyx_XDECREF(__pyx_t_1);
8291  __Pyx_XDECREF(__pyx_t_2);
8292  __Pyx_AddTraceback("PyClical.clifford.__and__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8293  __pyx_r = NULL;
8294  __pyx_L0:;
8295  __Pyx_XGIVEREF(__pyx_r);
8296  __Pyx_RefNannyFinishContext();
8297  return __pyx_r;
8298  }
8299 
8300  /* "PyClical.pyx":850
8301  * return clifford().wrap( toClifford(lhs) & toClifford(rhs) )
8302  *
8303  * def __iand__(self, rhs): # <<<<<<<<<<<<<<
8304  * """
8305  * Inner product.
8306  */
8307 
8308  /* Python wrapper */
8309  static PyObject *__pyx_pw_8PyClical_8clifford_39__iand__(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs); /*proto*/
8310  static char __pyx_doc_8PyClical_8clifford_38__iand__[] = "\n Inner product.\n\n >>> x = clifford(\"{1}\"); x &= clifford(\"{2}\"); print x\n 0\n >>> x = clifford(2); x &= clifford(\"{2}\"); print x\n 0\n >>> x = clifford(\"{1}\"); x &= clifford(\"{1}\"); print x\n 1\n >>> x = clifford(\"{1}\"); x &= clifford(\"{1,2}\"); print x\n {2}\n ";
8311  #if CYTHON_COMPILING_IN_CPYTHON
8312  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_38__iand__;
8313  #endif
8314  static PyObject *__pyx_pw_8PyClical_8clifford_39__iand__(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs) {
8315  PyObject *__pyx_r = 0;
8316  __Pyx_RefNannyDeclarations
8317  __Pyx_RefNannySetupContext("__iand__ (wrapper)", 0);
8318  __pyx_r = __pyx_pf_8PyClical_8clifford_38__iand__(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self), ((PyObject *)__pyx_v_rhs));
8319 
8320  /* function exit code */
8321  __Pyx_RefNannyFinishContext();
8322  return __pyx_r;
8323  }
8324 
8325  static PyObject *__pyx_pf_8PyClical_8clifford_38__iand__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_rhs) {
8326  PyObject *__pyx_r = NULL;
8327  __Pyx_RefNannyDeclarations
8328  PyObject *__pyx_t_1 = NULL;
8329  int __pyx_lineno = 0;
8330  const char *__pyx_filename = NULL;
8331  int __pyx_clineno = 0;
8332  __Pyx_RefNannySetupContext("__iand__", 0);
8333 
8334  /* "PyClical.pyx":863
8335  * {2}
8336  * """
8337  * return self.wrap( self.unwrap() & toClifford(rhs) ) # <<<<<<<<<<<<<<
8338  *
8339  * def __xor__(lhs, rhs):
8340  */
8341  __Pyx_XDECREF(__pyx_r);
8342  __pyx_t_1 = __pyx_f_8PyClical_8clifford_wrap(__pyx_v_self, (__pyx_f_8PyClical_8clifford_unwrap(__pyx_v_self) & __pyx_f_8PyClical_toClifford(__pyx_v_rhs))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 863; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8343  __Pyx_GOTREF(__pyx_t_1);
8344  __pyx_r = __pyx_t_1;
8345  __pyx_t_1 = 0;
8346  goto __pyx_L0;
8347 
8348  /* "PyClical.pyx":850
8349  * return clifford().wrap( toClifford(lhs) & toClifford(rhs) )
8350  *
8351  * def __iand__(self, rhs): # <<<<<<<<<<<<<<
8352  * """
8353  * Inner product.
8354  */
8355 
8356  /* function exit code */
8357  __pyx_L1_error:;
8358  __Pyx_XDECREF(__pyx_t_1);
8359  __Pyx_AddTraceback("PyClical.clifford.__iand__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8360  __pyx_r = NULL;
8361  __pyx_L0:;
8362  __Pyx_XGIVEREF(__pyx_r);
8363  __Pyx_RefNannyFinishContext();
8364  return __pyx_r;
8365  }
8366 
8367  /* "PyClical.pyx":865
8368  * return self.wrap( self.unwrap() & toClifford(rhs) )
8369  *
8370  * def __xor__(lhs, rhs): # <<<<<<<<<<<<<<
8371  * """
8372  * Outer product.
8373  */
8374 
8375  /* Python wrapper */
8376  static PyObject *__pyx_pw_8PyClical_8clifford_41__xor__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs); /*proto*/
8377  static char __pyx_doc_8PyClical_8clifford_40__xor__[] = "\n Outer product.\n\n >>> print clifford(\"{1}\") ^ clifford(\"{2}\")\n {1,2}\n >>> print clifford(2) ^ clifford(\"{2}\")\n 2{2}\n >>> print clifford(\"{1}\") ^ clifford(\"{1}\")\n 0\n >>> print clifford(\"{1}\") ^ clifford(\"{1,2}\")\n 0\n ";
8378  #if CYTHON_COMPILING_IN_CPYTHON
8379  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_40__xor__;
8380  #endif
8381  static PyObject *__pyx_pw_8PyClical_8clifford_41__xor__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs) {
8382  PyObject *__pyx_r = 0;
8383  __Pyx_RefNannyDeclarations
8384  __Pyx_RefNannySetupContext("__xor__ (wrapper)", 0);
8385  __pyx_r = __pyx_pf_8PyClical_8clifford_40__xor__(((PyObject *)__pyx_v_lhs), ((PyObject *)__pyx_v_rhs));
8386 
8387  /* function exit code */
8388  __Pyx_RefNannyFinishContext();
8389  return __pyx_r;
8390  }
8391 
8392  static PyObject *__pyx_pf_8PyClical_8clifford_40__xor__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs) {
8393  PyObject *__pyx_r = NULL;
8394  __Pyx_RefNannyDeclarations
8395  PyObject *__pyx_t_1 = NULL;
8396  PyObject *__pyx_t_2 = NULL;
8397  int __pyx_lineno = 0;
8398  const char *__pyx_filename = NULL;
8399  int __pyx_clineno = 0;
8400  __Pyx_RefNannySetupContext("__xor__", 0);
8401 
8402  /* "PyClical.pyx":878
8403  * 0
8404  * """
8405  * return clifford().wrap( toClifford(lhs) ^ toClifford(rhs) ) # <<<<<<<<<<<<<<
8406  *
8407  * def __ixor__(self, rhs):
8408  */
8409  __Pyx_XDECREF(__pyx_r);
8410  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 878; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8411  __Pyx_GOTREF(__pyx_t_1);
8412  __pyx_t_2 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), (__pyx_f_8PyClical_toClifford(__pyx_v_lhs) ^ __pyx_f_8PyClical_toClifford(__pyx_v_rhs))); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 878; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8413  __Pyx_GOTREF(__pyx_t_2);
8414  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
8415  __pyx_r = __pyx_t_2;
8416  __pyx_t_2 = 0;
8417  goto __pyx_L0;
8418 
8419  /* "PyClical.pyx":865
8420  * return self.wrap( self.unwrap() & toClifford(rhs) )
8421  *
8422  * def __xor__(lhs, rhs): # <<<<<<<<<<<<<<
8423  * """
8424  * Outer product.
8425  */
8426 
8427  /* function exit code */
8428  __pyx_L1_error:;
8429  __Pyx_XDECREF(__pyx_t_1);
8430  __Pyx_XDECREF(__pyx_t_2);
8431  __Pyx_AddTraceback("PyClical.clifford.__xor__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8432  __pyx_r = NULL;
8433  __pyx_L0:;
8434  __Pyx_XGIVEREF(__pyx_r);
8435  __Pyx_RefNannyFinishContext();
8436  return __pyx_r;
8437  }
8438 
8439  /* "PyClical.pyx":880
8440  * return clifford().wrap( toClifford(lhs) ^ toClifford(rhs) )
8441  *
8442  * def __ixor__(self, rhs): # <<<<<<<<<<<<<<
8443  * """
8444  * Outer product.
8445  */
8446 
8447  /* Python wrapper */
8448  static PyObject *__pyx_pw_8PyClical_8clifford_43__ixor__(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs); /*proto*/
8449  static char __pyx_doc_8PyClical_8clifford_42__ixor__[] = "\n Outer product.\n\n >>> x = clifford(\"{1}\"); x ^= clifford(\"{2}\"); print x\n {1,2}\n >>> x = clifford(2); x ^= clifford(\"{2}\"); print x\n 2{2}\n >>> x = clifford(\"{1}\"); x ^= clifford(\"{1}\"); print x\n 0\n >>> x = clifford(\"{1}\"); x ^= clifford(\"{1,2}\"); print x\n 0\n ";
8450  #if CYTHON_COMPILING_IN_CPYTHON
8451  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_42__ixor__;
8452  #endif
8453  static PyObject *__pyx_pw_8PyClical_8clifford_43__ixor__(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs) {
8454  PyObject *__pyx_r = 0;
8455  __Pyx_RefNannyDeclarations
8456  __Pyx_RefNannySetupContext("__ixor__ (wrapper)", 0);
8457  __pyx_r = __pyx_pf_8PyClical_8clifford_42__ixor__(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self), ((PyObject *)__pyx_v_rhs));
8458 
8459  /* function exit code */
8460  __Pyx_RefNannyFinishContext();
8461  return __pyx_r;
8462  }
8463 
8464  static PyObject *__pyx_pf_8PyClical_8clifford_42__ixor__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_rhs) {
8465  PyObject *__pyx_r = NULL;
8466  __Pyx_RefNannyDeclarations
8467  PyObject *__pyx_t_1 = NULL;
8468  int __pyx_lineno = 0;
8469  const char *__pyx_filename = NULL;
8470  int __pyx_clineno = 0;
8471  __Pyx_RefNannySetupContext("__ixor__", 0);
8472 
8473  /* "PyClical.pyx":893
8474  * 0
8475  * """
8476  * return self.wrap( self.unwrap() ^ toClifford(rhs) ) # <<<<<<<<<<<<<<
8477  *
8478  * def __div__(lhs, rhs):
8479  */
8480  __Pyx_XDECREF(__pyx_r);
8481  __pyx_t_1 = __pyx_f_8PyClical_8clifford_wrap(__pyx_v_self, (__pyx_f_8PyClical_8clifford_unwrap(__pyx_v_self) ^ __pyx_f_8PyClical_toClifford(__pyx_v_rhs))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 893; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8482  __Pyx_GOTREF(__pyx_t_1);
8483  __pyx_r = __pyx_t_1;
8484  __pyx_t_1 = 0;
8485  goto __pyx_L0;
8486 
8487  /* "PyClical.pyx":880
8488  * return clifford().wrap( toClifford(lhs) ^ toClifford(rhs) )
8489  *
8490  * def __ixor__(self, rhs): # <<<<<<<<<<<<<<
8491  * """
8492  * Outer product.
8493  */
8494 
8495  /* function exit code */
8496  __pyx_L1_error:;
8497  __Pyx_XDECREF(__pyx_t_1);
8498  __Pyx_AddTraceback("PyClical.clifford.__ixor__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8499  __pyx_r = NULL;
8500  __pyx_L0:;
8501  __Pyx_XGIVEREF(__pyx_r);
8502  __Pyx_RefNannyFinishContext();
8503  return __pyx_r;
8504  }
8505 
8506  /* "PyClical.pyx":895
8507  * return self.wrap( self.unwrap() ^ toClifford(rhs) )
8508  *
8509  * def __div__(lhs, rhs): # <<<<<<<<<<<<<<
8510  * """
8511  * Geometric quotient.
8512  */
8513 
8514  /* Python wrapper */
8515  #if PY_MAJOR_VERSION < 3 || CYTHON_COMPILING_IN_PYPY
8516  static PyObject *__pyx_pw_8PyClical_8clifford_45__div__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs); /*proto*/
8517  static char __pyx_doc_8PyClical_8clifford_44__div__[] = "\n Geometric quotient.\n\n >>> print clifford(\"{1}\") / clifford(\"{2}\")\n {1,2}\n >>> print clifford(2) / clifford(\"{2}\")\n 2{2}\n >>> print clifford(\"{1}\") / clifford(\"{1}\")\n 1\n >>> print clifford(\"{1}\") / clifford(\"{1,2}\")\n -{2}\n ";
8518  #if CYTHON_COMPILING_IN_CPYTHON
8519  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_44__div__;
8520  #endif
8521  static PyObject *__pyx_pw_8PyClical_8clifford_45__div__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs) {
8522  PyObject *__pyx_r = 0;
8523  __Pyx_RefNannyDeclarations
8524  __Pyx_RefNannySetupContext("__div__ (wrapper)", 0);
8525  __pyx_r = __pyx_pf_8PyClical_8clifford_44__div__(((PyObject *)__pyx_v_lhs), ((PyObject *)__pyx_v_rhs));
8526 
8527  /* function exit code */
8528  __Pyx_RefNannyFinishContext();
8529  return __pyx_r;
8530  }
8531  #endif
8533  #if PY_MAJOR_VERSION < 3 || CYTHON_COMPILING_IN_PYPY
8534  static PyObject *__pyx_pf_8PyClical_8clifford_44__div__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs) {
8535  PyObject *__pyx_r = NULL;
8536  __Pyx_RefNannyDeclarations
8537  PyObject *__pyx_t_1 = NULL;
8538  PyObject *__pyx_t_2 = NULL;
8539  int __pyx_lineno = 0;
8540  const char *__pyx_filename = NULL;
8541  int __pyx_clineno = 0;
8542  __Pyx_RefNannySetupContext("__div__", 0);
8543 
8544  /* "PyClical.pyx":908
8545  * -{2}
8546  * """
8547  * return clifford().wrap( toClifford(lhs) / toClifford(rhs) ) # <<<<<<<<<<<<<<
8548  *
8549  * def __idiv__(self, rhs):
8550  */
8551  __Pyx_XDECREF(__pyx_r);
8552  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 908; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8553  __Pyx_GOTREF(__pyx_t_1);
8554  __pyx_t_2 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), (__pyx_f_8PyClical_toClifford(__pyx_v_lhs) / __pyx_f_8PyClical_toClifford(__pyx_v_rhs))); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 908; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8555  __Pyx_GOTREF(__pyx_t_2);
8556  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
8557  __pyx_r = __pyx_t_2;
8558  __pyx_t_2 = 0;
8559  goto __pyx_L0;
8560 
8561  /* "PyClical.pyx":895
8562  * return self.wrap( self.unwrap() ^ toClifford(rhs) )
8563  *
8564  * def __div__(lhs, rhs): # <<<<<<<<<<<<<<
8565  * """
8566  * Geometric quotient.
8567  */
8568 
8569  /* function exit code */
8570  __pyx_L1_error:;
8571  __Pyx_XDECREF(__pyx_t_1);
8572  __Pyx_XDECREF(__pyx_t_2);
8573  __Pyx_AddTraceback("PyClical.clifford.__div__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8574  __pyx_r = NULL;
8575  __pyx_L0:;
8576  __Pyx_XGIVEREF(__pyx_r);
8577  __Pyx_RefNannyFinishContext();
8578  return __pyx_r;
8579  }
8580  #endif
8582  /* "PyClical.pyx":910
8583  * return clifford().wrap( toClifford(lhs) / toClifford(rhs) )
8584  *
8585  * def __idiv__(self, rhs): # <<<<<<<<<<<<<<
8586  * """
8587  * Geometric quotient.
8588  */
8589 
8590  /* Python wrapper */
8591  #if PY_MAJOR_VERSION < 3 || CYTHON_COMPILING_IN_PYPY
8592  static PyObject *__pyx_pw_8PyClical_8clifford_47__idiv__(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs); /*proto*/
8593  static char __pyx_doc_8PyClical_8clifford_46__idiv__[] = "\n Geometric quotient.\n\n >>> x = clifford(\"{1}\"); x /= clifford(\"{2}\"); print x\n {1,2}\n >>> x = clifford(2); x /= clifford(\"{2}\"); print x\n 2{2}\n >>> x = clifford(\"{1}\"); x /= clifford(\"{1}\"); print x\n 1\n >>> x = clifford(\"{1}\"); x /= clifford(\"{1,2}\"); print x\n -{2}\n ";
8594  #if CYTHON_COMPILING_IN_CPYTHON
8595  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_46__idiv__;
8596  #endif
8597  static PyObject *__pyx_pw_8PyClical_8clifford_47__idiv__(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs) {
8598  PyObject *__pyx_r = 0;
8599  __Pyx_RefNannyDeclarations
8600  __Pyx_RefNannySetupContext("__idiv__ (wrapper)", 0);
8601  __pyx_r = __pyx_pf_8PyClical_8clifford_46__idiv__(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self), ((PyObject *)__pyx_v_rhs));
8602 
8603  /* function exit code */
8604  __Pyx_RefNannyFinishContext();
8605  return __pyx_r;
8606  }
8607  #endif
8609  #if PY_MAJOR_VERSION < 3 || CYTHON_COMPILING_IN_PYPY
8610  static PyObject *__pyx_pf_8PyClical_8clifford_46__idiv__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_rhs) {
8611  PyObject *__pyx_r = NULL;
8612  __Pyx_RefNannyDeclarations
8613  PyObject *__pyx_t_1 = NULL;
8614  int __pyx_lineno = 0;
8615  const char *__pyx_filename = NULL;
8616  int __pyx_clineno = 0;
8617  __Pyx_RefNannySetupContext("__idiv__", 0);
8618 
8619  /* "PyClical.pyx":923
8620  * -{2}
8621  * """
8622  * return self.wrap( self.unwrap() / toClifford(rhs) ) # <<<<<<<<<<<<<<
8623  *
8624  * def inv(self):
8625  */
8626  __Pyx_XDECREF(__pyx_r);
8627  __pyx_t_1 = __pyx_f_8PyClical_8clifford_wrap(__pyx_v_self, (__pyx_f_8PyClical_8clifford_unwrap(__pyx_v_self) / __pyx_f_8PyClical_toClifford(__pyx_v_rhs))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 923; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8628  __Pyx_GOTREF(__pyx_t_1);
8629  __pyx_r = __pyx_t_1;
8630  __pyx_t_1 = 0;
8631  goto __pyx_L0;
8632 
8633  /* "PyClical.pyx":910
8634  * return clifford().wrap( toClifford(lhs) / toClifford(rhs) )
8635  *
8636  * def __idiv__(self, rhs): # <<<<<<<<<<<<<<
8637  * """
8638  * Geometric quotient.
8639  */
8640 
8641  /* function exit code */
8642  __pyx_L1_error:;
8643  __Pyx_XDECREF(__pyx_t_1);
8644  __Pyx_AddTraceback("PyClical.clifford.__idiv__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8645  __pyx_r = NULL;
8646  __pyx_L0:;
8647  __Pyx_XGIVEREF(__pyx_r);
8648  __Pyx_RefNannyFinishContext();
8649  return __pyx_r;
8650  }
8651  #endif
8653  /* "PyClical.pyx":925
8654  * return self.wrap( self.unwrap() / toClifford(rhs) )
8655  *
8656  * def inv(self): # <<<<<<<<<<<<<<
8657  * """
8658  * Geometric multiplicative inverse.
8659  */
8660 
8661  /* Python wrapper */
8662  static PyObject *__pyx_pw_8PyClical_8clifford_49inv(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
8663  static char __pyx_doc_8PyClical_8clifford_48inv[] = "\n Geometric multiplicative inverse.\n\n >>> x = clifford(\"{1}\"); print x.inv()\n {1}\n >>> x = clifford(2); print x.inv()\n 0.5\n >>> x = clifford(\"{1,2}\"); print x.inv()\n -{1,2}\n ";
8664  static PyObject *__pyx_pw_8PyClical_8clifford_49inv(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
8665  PyObject *__pyx_r = 0;
8666  __Pyx_RefNannyDeclarations
8667  __Pyx_RefNannySetupContext("inv (wrapper)", 0);
8668  __pyx_r = __pyx_pf_8PyClical_8clifford_48inv(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self));
8669 
8670  /* function exit code */
8671  __Pyx_RefNannyFinishContext();
8672  return __pyx_r;
8673  }
8674 
8675  static PyObject *__pyx_pf_8PyClical_8clifford_48inv(struct __pyx_obj_8PyClical_clifford *__pyx_v_self) {
8676  PyObject *__pyx_r = NULL;
8677  __Pyx_RefNannyDeclarations
8678  PyObject *__pyx_t_1 = NULL;
8679  PyObject *__pyx_t_2 = NULL;
8680  int __pyx_lineno = 0;
8681  const char *__pyx_filename = NULL;
8682  int __pyx_clineno = 0;
8683  __Pyx_RefNannySetupContext("inv", 0);
8684 
8685  /* "PyClical.pyx":936
8686  * -{1,2}
8687  * """
8688  * return clifford().wrap( self.instance.inv() ) # <<<<<<<<<<<<<<
8689  *
8690  * def __or__(lhs, rhs):
8691  */
8692  __Pyx_XDECREF(__pyx_r);
8693  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 936; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8694  __Pyx_GOTREF(__pyx_t_1);
8695  __pyx_t_2 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), __pyx_v_self->instance->inv()); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 936; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8696  __Pyx_GOTREF(__pyx_t_2);
8697  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
8698  __pyx_r = __pyx_t_2;
8699  __pyx_t_2 = 0;
8700  goto __pyx_L0;
8701 
8702  /* "PyClical.pyx":925
8703  * return self.wrap( self.unwrap() / toClifford(rhs) )
8704  *
8705  * def inv(self): # <<<<<<<<<<<<<<
8706  * """
8707  * Geometric multiplicative inverse.
8708  */
8709 
8710  /* function exit code */
8711  __pyx_L1_error:;
8712  __Pyx_XDECREF(__pyx_t_1);
8713  __Pyx_XDECREF(__pyx_t_2);
8714  __Pyx_AddTraceback("PyClical.clifford.inv", __pyx_clineno, __pyx_lineno, __pyx_filename);
8715  __pyx_r = NULL;
8716  __pyx_L0:;
8717  __Pyx_XGIVEREF(__pyx_r);
8718  __Pyx_RefNannyFinishContext();
8719  return __pyx_r;
8720  }
8721 
8722  /* "PyClical.pyx":938
8723  * return clifford().wrap( self.instance.inv() )
8724  *
8725  * def __or__(lhs, rhs): # <<<<<<<<<<<<<<
8726  * """
8727  * Transform left hand side, using right hand side as a transformation.
8728  */
8729 
8730  /* Python wrapper */
8731  static PyObject *__pyx_pw_8PyClical_8clifford_51__or__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs); /*proto*/
8732  static char __pyx_doc_8PyClical_8clifford_50__or__[] = "\n Transform left hand side, using right hand side as a transformation.\n\n >>> x=clifford(\"{1,2}\") * pi/2; y=clifford(\"{1}\"); print y|x\n -{1}\n >>> x=clifford(\"{1,2}\") * pi/2; y=clifford(\"{1}\"); print y|exp(x)\n -{1}\n ";
8733  #if CYTHON_COMPILING_IN_CPYTHON
8734  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_50__or__;
8735  #endif
8736  static PyObject *__pyx_pw_8PyClical_8clifford_51__or__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs) {
8737  PyObject *__pyx_r = 0;
8738  __Pyx_RefNannyDeclarations
8739  __Pyx_RefNannySetupContext("__or__ (wrapper)", 0);
8740  __pyx_r = __pyx_pf_8PyClical_8clifford_50__or__(((PyObject *)__pyx_v_lhs), ((PyObject *)__pyx_v_rhs));
8741 
8742  /* function exit code */
8743  __Pyx_RefNannyFinishContext();
8744  return __pyx_r;
8745  }
8746 
8747  static PyObject *__pyx_pf_8PyClical_8clifford_50__or__(PyObject *__pyx_v_lhs, PyObject *__pyx_v_rhs) {
8748  PyObject *__pyx_r = NULL;
8749  __Pyx_RefNannyDeclarations
8750  PyObject *__pyx_t_1 = NULL;
8751  PyObject *__pyx_t_2 = NULL;
8752  int __pyx_lineno = 0;
8753  const char *__pyx_filename = NULL;
8754  int __pyx_clineno = 0;
8755  __Pyx_RefNannySetupContext("__or__", 0);
8756 
8757  /* "PyClical.pyx":947
8758  * -{1}
8759  * """
8760  * return clifford().wrap( toClifford(lhs) | toClifford(rhs) ) # <<<<<<<<<<<<<<
8761  *
8762  * def __ior__(self, rhs):
8763  */
8764  __Pyx_XDECREF(__pyx_r);
8765  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 947; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8766  __Pyx_GOTREF(__pyx_t_1);
8767  __pyx_t_2 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), (__pyx_f_8PyClical_toClifford(__pyx_v_lhs) | __pyx_f_8PyClical_toClifford(__pyx_v_rhs))); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 947; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8768  __Pyx_GOTREF(__pyx_t_2);
8769  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
8770  __pyx_r = __pyx_t_2;
8771  __pyx_t_2 = 0;
8772  goto __pyx_L0;
8773 
8774  /* "PyClical.pyx":938
8775  * return clifford().wrap( self.instance.inv() )
8776  *
8777  * def __or__(lhs, rhs): # <<<<<<<<<<<<<<
8778  * """
8779  * Transform left hand side, using right hand side as a transformation.
8780  */
8781 
8782  /* function exit code */
8783  __pyx_L1_error:;
8784  __Pyx_XDECREF(__pyx_t_1);
8785  __Pyx_XDECREF(__pyx_t_2);
8786  __Pyx_AddTraceback("PyClical.clifford.__or__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8787  __pyx_r = NULL;
8788  __pyx_L0:;
8789  __Pyx_XGIVEREF(__pyx_r);
8790  __Pyx_RefNannyFinishContext();
8791  return __pyx_r;
8792  }
8793 
8794  /* "PyClical.pyx":949
8795  * return clifford().wrap( toClifford(lhs) | toClifford(rhs) )
8796  *
8797  * def __ior__(self, rhs): # <<<<<<<<<<<<<<
8798  * """
8799  * Transform left hand side, using right hand side as a transformation.
8800  */
8801 
8802  /* Python wrapper */
8803  static PyObject *__pyx_pw_8PyClical_8clifford_53__ior__(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs); /*proto*/
8804  static char __pyx_doc_8PyClical_8clifford_52__ior__[] = "\n Transform left hand side, using right hand side as a transformation.\n\n >>> x=clifford(\"{1,2}\") * pi/2; y=clifford(\"{1}\"); y|=x; print y\n -{1}\n >>> x=clifford(\"{1,2}\") * pi/2; y=clifford(\"{1}\"); y|=exp(x); print y\n -{1}\n ";
8805  #if CYTHON_COMPILING_IN_CPYTHON
8806  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_52__ior__;
8807  #endif
8808  static PyObject *__pyx_pw_8PyClical_8clifford_53__ior__(PyObject *__pyx_v_self, PyObject *__pyx_v_rhs) {
8809  PyObject *__pyx_r = 0;
8810  __Pyx_RefNannyDeclarations
8811  __Pyx_RefNannySetupContext("__ior__ (wrapper)", 0);
8812  __pyx_r = __pyx_pf_8PyClical_8clifford_52__ior__(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self), ((PyObject *)__pyx_v_rhs));
8813 
8814  /* function exit code */
8815  __Pyx_RefNannyFinishContext();
8816  return __pyx_r;
8817  }
8818 
8819  static PyObject *__pyx_pf_8PyClical_8clifford_52__ior__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_rhs) {
8820  PyObject *__pyx_r = NULL;
8821  __Pyx_RefNannyDeclarations
8822  PyObject *__pyx_t_1 = NULL;
8823  int __pyx_lineno = 0;
8824  const char *__pyx_filename = NULL;
8825  int __pyx_clineno = 0;
8826  __Pyx_RefNannySetupContext("__ior__", 0);
8827 
8828  /* "PyClical.pyx":958
8829  * -{1}
8830  * """
8831  * return self.wrap( self.unwrap() | toClifford(rhs) ) # <<<<<<<<<<<<<<
8832  *
8833  * def __pow__(self, m, dummy):
8834  */
8835  __Pyx_XDECREF(__pyx_r);
8836  __pyx_t_1 = __pyx_f_8PyClical_8clifford_wrap(__pyx_v_self, (__pyx_f_8PyClical_8clifford_unwrap(__pyx_v_self) | __pyx_f_8PyClical_toClifford(__pyx_v_rhs))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 958; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8837  __Pyx_GOTREF(__pyx_t_1);
8838  __pyx_r = __pyx_t_1;
8839  __pyx_t_1 = 0;
8840  goto __pyx_L0;
8841 
8842  /* "PyClical.pyx":949
8843  * return clifford().wrap( toClifford(lhs) | toClifford(rhs) )
8844  *
8845  * def __ior__(self, rhs): # <<<<<<<<<<<<<<
8846  * """
8847  * Transform left hand side, using right hand side as a transformation.
8848  */
8849 
8850  /* function exit code */
8851  __pyx_L1_error:;
8852  __Pyx_XDECREF(__pyx_t_1);
8853  __Pyx_AddTraceback("PyClical.clifford.__ior__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8854  __pyx_r = NULL;
8855  __pyx_L0:;
8856  __Pyx_XGIVEREF(__pyx_r);
8857  __Pyx_RefNannyFinishContext();
8858  return __pyx_r;
8859  }
8860 
8861  /* "PyClical.pyx":960
8862  * return self.wrap( self.unwrap() | toClifford(rhs) )
8863  *
8864  * def __pow__(self, m, dummy): # <<<<<<<<<<<<<<
8865  * """
8866  * Power: self to the m.
8867  */
8868 
8869  /* Python wrapper */
8870  static PyObject *__pyx_pw_8PyClical_8clifford_55__pow__(PyObject *__pyx_v_self, PyObject *__pyx_v_m, PyObject *__pyx_v_dummy); /*proto*/
8871  static char __pyx_doc_8PyClical_8clifford_54__pow__[] = "\n Power: self to the m.\n\n >>> x=clifford(\"{1}\"); print x ** 2\n 1\n >>> x=clifford(\"2\"); print x ** 2\n 4\n >>> x=clifford(\"2+{1}\"); print x ** 0\n 1\n >>> x=clifford(\"2+{1}\"); print x ** 1\n 2+{1}\n >>> x=clifford(\"2+{1}\"); print x ** 2\n 5+4{1}\n >>> i=clifford(\"{1,2}\");print exp(pi/2) * (i ** i)\n 1\n ";
8872  #if CYTHON_COMPILING_IN_CPYTHON
8873  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_54__pow__;
8874  #endif
8875  static PyObject *__pyx_pw_8PyClical_8clifford_55__pow__(PyObject *__pyx_v_self, PyObject *__pyx_v_m, PyObject *__pyx_v_dummy) {
8876  PyObject *__pyx_r = 0;
8877  __Pyx_RefNannyDeclarations
8878  __Pyx_RefNannySetupContext("__pow__ (wrapper)", 0);
8879  __pyx_r = __pyx_pf_8PyClical_8clifford_54__pow__(((PyObject *)__pyx_v_self), ((PyObject *)__pyx_v_m), ((PyObject *)__pyx_v_dummy));
8880 
8881  /* function exit code */
8882  __Pyx_RefNannyFinishContext();
8883  return __pyx_r;
8884  }
8885 
8886  static PyObject *__pyx_pf_8PyClical_8clifford_54__pow__(PyObject *__pyx_v_self, PyObject *__pyx_v_m, CYTHON_UNUSED PyObject *__pyx_v_dummy) {
8887  PyObject *__pyx_r = NULL;
8888  __Pyx_RefNannyDeclarations
8889  PyObject *__pyx_t_1 = NULL;
8890  int __pyx_lineno = 0;
8891  const char *__pyx_filename = NULL;
8892  int __pyx_clineno = 0;
8893  __Pyx_RefNannySetupContext("__pow__", 0);
8894 
8895  /* "PyClical.pyx":977
8896  * 1
8897  * """
8898  * return pow(self, m) # <<<<<<<<<<<<<<
8899  *
8900  * def pow(self, m):
8901  */
8902  __Pyx_XDECREF(__pyx_r);
8903  __pyx_t_1 = __pyx_f_8PyClical_pow(__pyx_v_self, __pyx_v_m, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 977; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8904  __Pyx_GOTREF(__pyx_t_1);
8905  __pyx_r = __pyx_t_1;
8906  __pyx_t_1 = 0;
8907  goto __pyx_L0;
8908 
8909  /* "PyClical.pyx":960
8910  * return self.wrap( self.unwrap() | toClifford(rhs) )
8911  *
8912  * def __pow__(self, m, dummy): # <<<<<<<<<<<<<<
8913  * """
8914  * Power: self to the m.
8915  */
8916 
8917  /* function exit code */
8918  __pyx_L1_error:;
8919  __Pyx_XDECREF(__pyx_t_1);
8920  __Pyx_AddTraceback("PyClical.clifford.__pow__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8921  __pyx_r = NULL;
8922  __pyx_L0:;
8923  __Pyx_XGIVEREF(__pyx_r);
8924  __Pyx_RefNannyFinishContext();
8925  return __pyx_r;
8926  }
8927 
8928  /* "PyClical.pyx":979
8929  * return pow(self, m)
8930  *
8931  * def pow(self, m): # <<<<<<<<<<<<<<
8932  * """
8933  * Power: self to the m.
8934  */
8935 
8936  /* Python wrapper */
8937  static PyObject *__pyx_pw_8PyClical_8clifford_57pow(PyObject *__pyx_v_self, PyObject *__pyx_v_m); /*proto*/
8938  static char __pyx_doc_8PyClical_8clifford_56pow[] = "\n Power: self to the m.\n\n >>> x=clifford(\"{1}\"); print x.pow(2)\n 1\n >>> x=clifford(\"2\"); print x.pow(2)\n 4\n >>> x=clifford(\"2+{1}\"); print x.pow(0)\n 1\n >>> x=clifford(\"2+{1}\"); print x.pow(1)\n 2+{1}\n >>> x=clifford(\"2+{1}\"); print x.pow(2)\n 5+4{1}\n >>> print clifford(\"1+{1}+{1,2}\").pow(3)\n 1+3{1}+3{1,2}\n >>> i=clifford(\"{1,2}\");print exp(pi/2) * i.pow(i)\n 1\n ";
8939  static PyObject *__pyx_pw_8PyClical_8clifford_57pow(PyObject *__pyx_v_self, PyObject *__pyx_v_m) {
8940  PyObject *__pyx_r = 0;
8941  __Pyx_RefNannyDeclarations
8942  __Pyx_RefNannySetupContext("pow (wrapper)", 0);
8943  __pyx_r = __pyx_pf_8PyClical_8clifford_56pow(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self), ((PyObject *)__pyx_v_m));
8944 
8945  /* function exit code */
8946  __Pyx_RefNannyFinishContext();
8947  return __pyx_r;
8948  }
8949 
8950  static PyObject *__pyx_pf_8PyClical_8clifford_56pow(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_m) {
8951  PyObject *__pyx_r = NULL;
8952  __Pyx_RefNannyDeclarations
8953  PyObject *__pyx_t_1 = NULL;
8954  PyObject *__pyx_t_2 = NULL;
8955  int __pyx_t_3;
8956  int __pyx_t_4;
8957  int __pyx_t_5;
8958  int __pyx_lineno = 0;
8959  const char *__pyx_filename = NULL;
8960  int __pyx_clineno = 0;
8961  __Pyx_RefNannySetupContext("pow", 0);
8962 
8963  /* "PyClical.pyx":998
8964  * 1
8965  * """
8966  * if isinstance(m, numbers.Integral): # <<<<<<<<<<<<<<
8967  * return clifford().wrap( self.instance.pow(m) )
8968  * else:
8969  */
8970  __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_numbers); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 998; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8971  __Pyx_GOTREF(__pyx_t_1);
8972  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_Integral); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 998; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8973  __Pyx_GOTREF(__pyx_t_2);
8974  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
8975  __pyx_t_3 = PyObject_IsInstance(__pyx_v_m, __pyx_t_2); if (unlikely(__pyx_t_3 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 998; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8976  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
8977  __pyx_t_4 = (__pyx_t_3 != 0);
8978  if (__pyx_t_4) {
8979 
8980  /* "PyClical.pyx":999
8981  * """
8982  * if isinstance(m, numbers.Integral):
8983  * return clifford().wrap( self.instance.pow(m) ) # <<<<<<<<<<<<<<
8984  * else:
8985  * return exp(m * log(self))
8986  */
8987  __Pyx_XDECREF(__pyx_r);
8988  __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 999; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8989  __Pyx_GOTREF(__pyx_t_2);
8990  __pyx_t_5 = __Pyx_PyInt_As_int(__pyx_v_m); if (unlikely((__pyx_t_5 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 999; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8991  __pyx_t_1 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_2), __pyx_v_self->instance->pow(__pyx_t_5)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 999; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
8992  __Pyx_GOTREF(__pyx_t_1);
8993  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
8994  __pyx_r = __pyx_t_1;
8995  __pyx_t_1 = 0;
8996  goto __pyx_L0;
8997 
8998  /* "PyClical.pyx":998
8999  * 1
9000  * """
9001  * if isinstance(m, numbers.Integral): # <<<<<<<<<<<<<<
9002  * return clifford().wrap( self.instance.pow(m) )
9003  * else:
9004  */
9005  }
9006 
9007  /* "PyClical.pyx":1001
9008  * return clifford().wrap( self.instance.pow(m) )
9009  * else:
9010  * return exp(m * log(self)) # <<<<<<<<<<<<<<
9011  *
9012  * def outer_pow(self, m):
9013  */
9014  /*else*/ {
9015  __Pyx_XDECREF(__pyx_r);
9016  __pyx_t_1 = __pyx_f_8PyClical_log(((PyObject *)__pyx_v_self), 0, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1001; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
9017  __Pyx_GOTREF(__pyx_t_1);
9018  __pyx_t_2 = PyNumber_Multiply(__pyx_v_m, __pyx_t_1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1001; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
9019  __Pyx_GOTREF(__pyx_t_2);
9020  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
9021  __pyx_t_1 = __pyx_f_8PyClical_exp(__pyx_t_2, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1001; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
9022  __Pyx_GOTREF(__pyx_t_1);
9023  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
9024  __pyx_r = __pyx_t_1;
9025  __pyx_t_1 = 0;
9026  goto __pyx_L0;
9027  }
9028 
9029  /* "PyClical.pyx":979
9030  * return pow(self, m)
9031  *
9032  * def pow(self, m): # <<<<<<<<<<<<<<
9033  * """
9034  * Power: self to the m.
9035  */
9036 
9037  /* function exit code */
9038  __pyx_L1_error:;
9039  __Pyx_XDECREF(__pyx_t_1);
9040  __Pyx_XDECREF(__pyx_t_2);
9041  __Pyx_AddTraceback("PyClical.clifford.pow", __pyx_clineno, __pyx_lineno, __pyx_filename);
9042  __pyx_r = NULL;
9043  __pyx_L0:;
9044  __Pyx_XGIVEREF(__pyx_r);
9045  __Pyx_RefNannyFinishContext();
9046  return __pyx_r;
9047  }
9048 
9049  /* "PyClical.pyx":1003
9050  * return exp(m * log(self))
9051  *
9052  * def outer_pow(self, m): # <<<<<<<<<<<<<<
9053  * """
9054  * Outer product power.
9055  */
9056 
9057  /* Python wrapper */
9058  static PyObject *__pyx_pw_8PyClical_8clifford_59outer_pow(PyObject *__pyx_v_self, PyObject *__pyx_v_m); /*proto*/
9059  static char __pyx_doc_8PyClical_8clifford_58outer_pow[] = "\n Outer product power.\n\n >>> x=clifford(\"2+{1}\"); print x.outer_pow(0)\n 1\n >>> x=clifford(\"2+{1}\"); print x.outer_pow(1)\n 2+{1}\n >>> x=clifford(\"2+{1}\"); print x.outer_pow(2)\n 4+4{1}\n >>> print clifford(\"1+{1}+{1,2}\").outer_pow(3)\n 1+3{1}+3{1,2}\n\n ";
9060  static PyObject *__pyx_pw_8PyClical_8clifford_59outer_pow(PyObject *__pyx_v_self, PyObject *__pyx_v_m) {
9061  PyObject *__pyx_r = 0;
9062  __Pyx_RefNannyDeclarations
9063  __Pyx_RefNannySetupContext("outer_pow (wrapper)", 0);
9064  __pyx_r = __pyx_pf_8PyClical_8clifford_58outer_pow(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self), ((PyObject *)__pyx_v_m));
9065 
9066  /* function exit code */
9067  __Pyx_RefNannyFinishContext();
9068  return __pyx_r;
9069  }
9070 
9071  static PyObject *__pyx_pf_8PyClical_8clifford_58outer_pow(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_m) {
9072  PyObject *__pyx_r = NULL;
9073  __Pyx_RefNannyDeclarations
9074  PyObject *__pyx_t_1 = NULL;
9075  int __pyx_t_2;
9076  PyObject *__pyx_t_3 = NULL;
9077  int __pyx_lineno = 0;
9078  const char *__pyx_filename = NULL;
9079  int __pyx_clineno = 0;
9080  __Pyx_RefNannySetupContext("outer_pow", 0);
9081 
9082  /* "PyClical.pyx":1017
9083  *
9084  * """
9085  * return clifford().wrap( self.instance.outer_pow(m) ) # <<<<<<<<<<<<<<
9086  *
9087  * def __call__(self, grade):
9088  */
9089  __Pyx_XDECREF(__pyx_r);
9090  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1017; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
9091  __Pyx_GOTREF(__pyx_t_1);
9092  __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_v_m); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1017; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
9093  __pyx_t_3 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), __pyx_v_self->instance->outer_pow(__pyx_t_2)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1017; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
9094  __Pyx_GOTREF(__pyx_t_3);
9095  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
9096  __pyx_r = __pyx_t_3;
9097  __pyx_t_3 = 0;
9098  goto __pyx_L0;
9099 
9100  /* "PyClical.pyx":1003
9101  * return exp(m * log(self))
9102  *
9103  * def outer_pow(self, m): # <<<<<<<<<<<<<<
9104  * """
9105  * Outer product power.
9106  */
9107 
9108  /* function exit code */
9109  __pyx_L1_error:;
9110  __Pyx_XDECREF(__pyx_t_1);
9111  __Pyx_XDECREF(__pyx_t_3);
9112  __Pyx_AddTraceback("PyClical.clifford.outer_pow", __pyx_clineno, __pyx_lineno, __pyx_filename);
9113  __pyx_r = NULL;
9114  __pyx_L0:;
9115  __Pyx_XGIVEREF(__pyx_r);
9116  __Pyx_RefNannyFinishContext();
9117  return __pyx_r;
9118  }
9119 
9120  /* "PyClical.pyx":1019
9121  * return clifford().wrap( self.instance.outer_pow(m) )
9122  *
9123  * def __call__(self, grade): # <<<<<<<<<<<<<<
9124  * """
9125  * Pure grade-vector part.
9126  */
9127 
9128  /* Python wrapper */
9129  static PyObject *__pyx_pw_8PyClical_8clifford_61__call__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
9130  static char __pyx_doc_8PyClical_8clifford_60__call__[] = "\n Pure grade-vector part.\n\n >>> print clifford(\"{1}\")(1)\n {1}\n >>> print clifford(\"{1}\")(0)\n 0\n >>> print clifford(\"1+{1}+{1,2}\")(0)\n 1\n >>> print clifford(\"1+{1}+{1,2}\")(1)\n {1}\n >>> print clifford(\"1+{1}+{1,2}\")(2)\n {1,2}\n >>> print clifford(\"1+{1}+{1,2}\")(3)\n 0\n ";
9131  #if CYTHON_COMPILING_IN_CPYTHON
9132  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_60__call__;
9133  #endif
9134  static PyObject *__pyx_pw_8PyClical_8clifford_61__call__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
9135  PyObject *__pyx_v_grade = 0;
9136  int __pyx_lineno = 0;
9137  const char *__pyx_filename = NULL;
9138  int __pyx_clineno = 0;
9139  PyObject *__pyx_r = 0;
9140  __Pyx_RefNannyDeclarations
9141  __Pyx_RefNannySetupContext("__call__ (wrapper)", 0);
9142  {
9143  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_grade,0};
9144  PyObject* values[1] = {0};
9145  if (unlikely(__pyx_kwds)) {
9146  Py_ssize_t kw_args;
9147  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
9148  switch (pos_args) {
9149  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
9150  case 0: break;
9151  default: goto __pyx_L5_argtuple_error;
9152  }
9153  kw_args = PyDict_Size(__pyx_kwds);
9154  switch (pos_args) {
9155  case 0:
9156  if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_grade)) != 0)) kw_args--;
9157  else goto __pyx_L5_argtuple_error;
9158  }
9159  if (unlikely(kw_args > 0)) {
9160  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__call__") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1019; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
9161  }
9162  } else if (PyTuple_GET_SIZE(__pyx_args) != 1) {
9163  goto __pyx_L5_argtuple_error;
9164  } else {
9165  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
9166  }
9167  __pyx_v_grade = values[0];
9168  }
9169  goto __pyx_L4_argument_unpacking_done;
9170  __pyx_L5_argtuple_error:;
9171  __Pyx_RaiseArgtupleInvalid("__call__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1019; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
9172  __pyx_L3_error:;
9173  __Pyx_AddTraceback("PyClical.clifford.__call__", __pyx_clineno, __pyx_lineno, __pyx_filename);
9174  __Pyx_RefNannyFinishContext();
9175  return NULL;
9176  __pyx_L4_argument_unpacking_done:;
9177  __pyx_r = __pyx_pf_8PyClical_8clifford_60__call__(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self), __pyx_v_grade);
9178 
9179  /* function exit code */
9180  __Pyx_RefNannyFinishContext();
9181  return __pyx_r;
9182  }
9183 
9184  static PyObject *__pyx_pf_8PyClical_8clifford_60__call__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_grade) {
9185  PyObject *__pyx_r = NULL;
9186  __Pyx_RefNannyDeclarations
9187  PyObject *__pyx_t_1 = NULL;
9188  int __pyx_t_2;
9189  PyObject *__pyx_t_3 = NULL;
9190  int __pyx_lineno = 0;
9191  const char *__pyx_filename = NULL;
9192  int __pyx_clineno = 0;
9193  __Pyx_RefNannySetupContext("__call__", 0);
9194 
9195  /* "PyClical.pyx":1036
9196  * 0
9197  * """
9198  * return clifford().wrap( self.instance.call(grade) ) # <<<<<<<<<<<<<<
9199  *
9200  * def scalar(self):
9201  */
9202  __Pyx_XDECREF(__pyx_r);
9203  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1036; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
9204  __Pyx_GOTREF(__pyx_t_1);
9205  __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_v_grade); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1036; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
9206  __pyx_t_3 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), __pyx_v_self->instance->operator()(__pyx_t_2)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1036; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
9207  __Pyx_GOTREF(__pyx_t_3);
9208  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
9209  __pyx_r = __pyx_t_3;
9210  __pyx_t_3 = 0;
9211  goto __pyx_L0;
9212 
9213  /* "PyClical.pyx":1019
9214  * return clifford().wrap( self.instance.outer_pow(m) )
9215  *
9216  * def __call__(self, grade): # <<<<<<<<<<<<<<
9217  * """
9218  * Pure grade-vector part.
9219  */
9220 
9221  /* function exit code */
9222  __pyx_L1_error:;
9223  __Pyx_XDECREF(__pyx_t_1);
9224  __Pyx_XDECREF(__pyx_t_3);
9225  __Pyx_AddTraceback("PyClical.clifford.__call__", __pyx_clineno, __pyx_lineno, __pyx_filename);
9226  __pyx_r = NULL;
9227  __pyx_L0:;
9228  __Pyx_XGIVEREF(__pyx_r);
9229  __Pyx_RefNannyFinishContext();
9230  return __pyx_r;
9231  }
9232 
9233  /* "PyClical.pyx":1038
9234  * return clifford().wrap( self.instance.call(grade) )
9235  *
9236  * def scalar(self): # <<<<<<<<<<<<<<
9237  * """
9238  * Scalar part.
9239  */
9240 
9241  /* Python wrapper */
9242  static PyObject *__pyx_pw_8PyClical_8clifford_63scalar(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
9243  static char __pyx_doc_8PyClical_8clifford_62scalar[] = "\n Scalar part.\n\n >>> clifford(\"1+{1}+{1,2}\").scalar()\n 1.0\n >>> clifford(\"{1,2}\").scalar()\n 0.0\n ";
9244  static PyObject *__pyx_pw_8PyClical_8clifford_63scalar(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
9245  PyObject *__pyx_r = 0;
9246  __Pyx_RefNannyDeclarations
9247  __Pyx_RefNannySetupContext("scalar (wrapper)", 0);
9248  __pyx_r = __pyx_pf_8PyClical_8clifford_62scalar(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self));
9249 
9250  /* function exit code */
9251  __Pyx_RefNannyFinishContext();
9252  return __pyx_r;
9253  }
9254 
9255  static PyObject *__pyx_pf_8PyClical_8clifford_62scalar(struct __pyx_obj_8PyClical_clifford *__pyx_v_self) {
9256  PyObject *__pyx_r = NULL;
9257  __Pyx_RefNannyDeclarations
9258  PyObject *__pyx_t_1 = NULL;
9259  int __pyx_lineno = 0;
9260  const char *__pyx_filename = NULL;
9261  int __pyx_clineno = 0;
9262  __Pyx_RefNannySetupContext("scalar", 0);
9263 
9264  /* "PyClical.pyx":1047
9265  * 0.0
9266  * """
9267  * return self.instance.scalar() # <<<<<<<<<<<<<<
9268  *
9269  * def pure(self):
9270  */
9271  __Pyx_XDECREF(__pyx_r);
9272  __pyx_t_1 = PyFloat_FromDouble(__pyx_v_self->instance->scalar()); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1047; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
9273  __Pyx_GOTREF(__pyx_t_1);
9274  __pyx_r = __pyx_t_1;
9275  __pyx_t_1 = 0;
9276  goto __pyx_L0;
9277 
9278  /* "PyClical.pyx":1038
9279  * return clifford().wrap( self.instance.call(grade) )
9280  *
9281  * def scalar(self): # <<<<<<<<<<<<<<
9282  * """
9283  * Scalar part.
9284  */
9285 
9286  /* function exit code */
9287  __pyx_L1_error:;
9288  __Pyx_XDECREF(__pyx_t_1);
9289  __Pyx_AddTraceback("PyClical.clifford.scalar", __pyx_clineno, __pyx_lineno, __pyx_filename);
9290  __pyx_r = NULL;
9291  __pyx_L0:;
9292  __Pyx_XGIVEREF(__pyx_r);
9293  __Pyx_RefNannyFinishContext();
9294  return __pyx_r;
9295  }
9296 
9297  /* "PyClical.pyx":1049
9298  * return self.instance.scalar()
9299  *
9300  * def pure(self): # <<<<<<<<<<<<<<
9301  * """
9302  * Pure part.
9303  */
9304 
9305  /* Python wrapper */
9306  static PyObject *__pyx_pw_8PyClical_8clifford_65pure(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
9307  static char __pyx_doc_8PyClical_8clifford_64pure[] = "\n Pure part.\n\n >>> print clifford(\"1+{1}+{1,2}\").pure()\n {1}+{1,2}\n >>> print clifford(\"{1,2}\").pure()\n {1,2}\n ";
9308  static PyObject *__pyx_pw_8PyClical_8clifford_65pure(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
9309  PyObject *__pyx_r = 0;
9310  __Pyx_RefNannyDeclarations
9311  __Pyx_RefNannySetupContext("pure (wrapper)", 0);
9312  __pyx_r = __pyx_pf_8PyClical_8clifford_64pure(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self));
9313 
9314  /* function exit code */
9315  __Pyx_RefNannyFinishContext();
9316  return __pyx_r;
9317  }
9318 
9319  static PyObject *__pyx_pf_8PyClical_8clifford_64pure(struct __pyx_obj_8PyClical_clifford *__pyx_v_self) {
9320  PyObject *__pyx_r = NULL;
9321  __Pyx_RefNannyDeclarations
9322  PyObject *__pyx_t_1 = NULL;
9323  PyObject *__pyx_t_2 = NULL;
9324  int __pyx_lineno = 0;
9325  const char *__pyx_filename = NULL;
9326  int __pyx_clineno = 0;
9327  __Pyx_RefNannySetupContext("pure", 0);
9328 
9329  /* "PyClical.pyx":1058
9330  * {1,2}
9331  * """
9332  * return clifford().wrap( self.instance.pure() ) # <<<<<<<<<<<<<<
9333  *
9334  * def even(self):
9335  */
9336  __Pyx_XDECREF(__pyx_r);
9337  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1058; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
9338  __Pyx_GOTREF(__pyx_t_1);
9339  __pyx_t_2 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), __pyx_v_self->instance->pure()); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1058; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
9340  __Pyx_GOTREF(__pyx_t_2);
9341  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
9342  __pyx_r = __pyx_t_2;
9343  __pyx_t_2 = 0;
9344  goto __pyx_L0;
9345 
9346  /* "PyClical.pyx":1049
9347  * return self.instance.scalar()
9348  *
9349  * def pure(self): # <<<<<<<<<<<<<<
9350  * """
9351  * Pure part.
9352  */
9353 
9354  /* function exit code */
9355  __pyx_L1_error:;
9356  __Pyx_XDECREF(__pyx_t_1);
9357  __Pyx_XDECREF(__pyx_t_2);
9358  __Pyx_AddTraceback("PyClical.clifford.pure", __pyx_clineno, __pyx_lineno, __pyx_filename);
9359  __pyx_r = NULL;
9360  __pyx_L0:;
9361  __Pyx_XGIVEREF(__pyx_r);
9362  __Pyx_RefNannyFinishContext();
9363  return __pyx_r;
9364  }
9365 
9366  /* "PyClical.pyx":1060
9367  * return clifford().wrap( self.instance.pure() )
9368  *
9369  * def even(self): # <<<<<<<<<<<<<<
9370  * """
9371  * Even part of multivector, sum of even grade terms.
9372  */
9373 
9374  /* Python wrapper */
9375  static PyObject *__pyx_pw_8PyClical_8clifford_67even(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
9376  static char __pyx_doc_8PyClical_8clifford_66even[] = "\n Even part of multivector, sum of even grade terms.\n\n >>> print clifford(\"1+{1}+{1,2}\").even()\n 1+{1,2}\n ";
9377  static PyObject *__pyx_pw_8PyClical_8clifford_67even(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
9378  PyObject *__pyx_r = 0;
9379  __Pyx_RefNannyDeclarations
9380  __Pyx_RefNannySetupContext("even (wrapper)", 0);
9381  __pyx_r = __pyx_pf_8PyClical_8clifford_66even(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self));
9382 
9383  /* function exit code */
9384  __Pyx_RefNannyFinishContext();
9385  return __pyx_r;
9386  }
9387 
9388  static PyObject *__pyx_pf_8PyClical_8clifford_66even(struct __pyx_obj_8PyClical_clifford *__pyx_v_self) {
9389  PyObject *__pyx_r = NULL;
9390  __Pyx_RefNannyDeclarations
9391  PyObject *__pyx_t_1 = NULL;
9392  PyObject *__pyx_t_2 = NULL;
9393  int __pyx_lineno = 0;
9394  const char *__pyx_filename = NULL;
9395  int __pyx_clineno = 0;
9396  __Pyx_RefNannySetupContext("even", 0);
9397 
9398  /* "PyClical.pyx":1067
9399  * 1+{1,2}
9400  * """
9401  * return clifford().wrap( self.instance.even() ) # <<<<<<<<<<<<<<
9402  *
9403  * def odd(self):
9404  */
9405  __Pyx_XDECREF(__pyx_r);
9406  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1067; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
9407  __Pyx_GOTREF(__pyx_t_1);
9408  __pyx_t_2 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), __pyx_v_self->instance->even()); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1067; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
9409  __Pyx_GOTREF(__pyx_t_2);
9410  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
9411  __pyx_r = __pyx_t_2;
9412  __pyx_t_2 = 0;
9413  goto __pyx_L0;
9414 
9415  /* "PyClical.pyx":1060
9416  * return clifford().wrap( self.instance.pure() )
9417  *
9418  * def even(self): # <<<<<<<<<<<<<<
9419  * """
9420  * Even part of multivector, sum of even grade terms.
9421  */
9422 
9423  /* function exit code */
9424  __pyx_L1_error:;
9425  __Pyx_XDECREF(__pyx_t_1);
9426  __Pyx_XDECREF(__pyx_t_2);
9427  __Pyx_AddTraceback("PyClical.clifford.even", __pyx_clineno, __pyx_lineno, __pyx_filename);
9428  __pyx_r = NULL;
9429  __pyx_L0:;
9430  __Pyx_XGIVEREF(__pyx_r);
9431  __Pyx_RefNannyFinishContext();
9432  return __pyx_r;
9433  }
9434 
9435  /* "PyClical.pyx":1069
9436  * return clifford().wrap( self.instance.even() )
9437  *
9438  * def odd(self): # <<<<<<<<<<<<<<
9439  * """
9440  * Odd part of multivector, sum of odd grade terms.
9441  */
9442 
9443  /* Python wrapper */
9444  static PyObject *__pyx_pw_8PyClical_8clifford_69odd(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
9445  static char __pyx_doc_8PyClical_8clifford_68odd[] = "\n Odd part of multivector, sum of odd grade terms.\n\n >>> print clifford(\"1+{1}+{1,2}\").odd()\n {1}\n ";
9446  static PyObject *__pyx_pw_8PyClical_8clifford_69odd(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
9447  PyObject *__pyx_r = 0;
9448  __Pyx_RefNannyDeclarations
9449  __Pyx_RefNannySetupContext("odd (wrapper)", 0);
9450  __pyx_r = __pyx_pf_8PyClical_8clifford_68odd(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self));
9451 
9452  /* function exit code */
9453  __Pyx_RefNannyFinishContext();
9454  return __pyx_r;
9455  }
9456 
9457  static PyObject *__pyx_pf_8PyClical_8clifford_68odd(struct __pyx_obj_8PyClical_clifford *__pyx_v_self) {
9458  PyObject *__pyx_r = NULL;
9459  __Pyx_RefNannyDeclarations
9460  PyObject *__pyx_t_1 = NULL;
9461  PyObject *__pyx_t_2 = NULL;
9462  int __pyx_lineno = 0;
9463  const char *__pyx_filename = NULL;
9464  int __pyx_clineno = 0;
9465  __Pyx_RefNannySetupContext("odd", 0);
9466 
9467  /* "PyClical.pyx":1076
9468  * {1}
9469  * """
9470  * return clifford().wrap( self.instance.odd() ) # <<<<<<<<<<<<<<
9471  *
9472  * def vector_part(self, frm = None):
9473  */
9474  __Pyx_XDECREF(__pyx_r);
9475  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1076; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
9476  __Pyx_GOTREF(__pyx_t_1);
9477  __pyx_t_2 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), __pyx_v_self->instance->odd()); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1076; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
9478  __Pyx_GOTREF(__pyx_t_2);
9479  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
9480  __pyx_r = __pyx_t_2;
9481  __pyx_t_2 = 0;
9482  goto __pyx_L0;
9483 
9484  /* "PyClical.pyx":1069
9485  * return clifford().wrap( self.instance.even() )
9486  *
9487  * def odd(self): # <<<<<<<<<<<<<<
9488  * """
9489  * Odd part of multivector, sum of odd grade terms.
9490  */
9491 
9492  /* function exit code */
9493  __pyx_L1_error:;
9494  __Pyx_XDECREF(__pyx_t_1);
9495  __Pyx_XDECREF(__pyx_t_2);
9496  __Pyx_AddTraceback("PyClical.clifford.odd", __pyx_clineno, __pyx_lineno, __pyx_filename);
9497  __pyx_r = NULL;
9498  __pyx_L0:;
9499  __Pyx_XGIVEREF(__pyx_r);
9500  __Pyx_RefNannyFinishContext();
9501  return __pyx_r;
9502  }
9503 
9504  /* "PyClical.pyx":1078
9505  * return clifford().wrap( self.instance.odd() )
9506  *
9507  * def vector_part(self, frm = None): # <<<<<<<<<<<<<<
9508  * """
9509  * Vector part of multivector, as a Python list, with respect to frm.
9510  */
9511 
9512  /* Python wrapper */
9513  static PyObject *__pyx_pw_8PyClical_8clifford_71vector_part(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
9514  static char __pyx_doc_8PyClical_8clifford_70vector_part[] = "\n Vector part of multivector, as a Python list, with respect to frm.\n\n >>> print clifford(\"1+2{1}+3{2}+4{1,2}\").vector_part()\n [2.0, 3.0]\n >>> print clifford(\"1+2{1}+3{2}+4{1,2}\").vector_part(index_set({-1,1,2}))\n [0.0, 2.0, 3.0]\n ";
9515  static PyObject *__pyx_pw_8PyClical_8clifford_71vector_part(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
9516  PyObject *__pyx_v_frm = 0;
9517  int __pyx_lineno = 0;
9518  const char *__pyx_filename = NULL;
9519  int __pyx_clineno = 0;
9520  PyObject *__pyx_r = 0;
9521  __Pyx_RefNannyDeclarations
9522  __Pyx_RefNannySetupContext("vector_part (wrapper)", 0);
9523  {
9524  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_frm,0};
9525  PyObject* values[1] = {0};
9526  values[0] = ((PyObject *)Py_None);
9527  if (unlikely(__pyx_kwds)) {
9528  Py_ssize_t kw_args;
9529  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
9530  switch (pos_args) {
9531  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
9532  case 0: break;
9533  default: goto __pyx_L5_argtuple_error;
9534  }
9535  kw_args = PyDict_Size(__pyx_kwds);
9536  switch (pos_args) {
9537  case 0:
9538  if (kw_args > 0) {
9539  PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_frm);
9540  if (value) { values[0] = value; kw_args--; }
9541  }
9542  }
9543  if (unlikely(kw_args > 0)) {
9544  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "vector_part") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1078; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
9545  }
9546  } else {
9547  switch (PyTuple_GET_SIZE(__pyx_args)) {
9548  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
9549  case 0: break;
9550  default: goto __pyx_L5_argtuple_error;
9551  }
9552  }
9553  __pyx_v_frm = values[0];
9554  }
9555  goto __pyx_L4_argument_unpacking_done;
9556  __pyx_L5_argtuple_error:;
9557  __Pyx_RaiseArgtupleInvalid("vector_part", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1078; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
9558  __pyx_L3_error:;
9559  __Pyx_AddTraceback("PyClical.clifford.vector_part", __pyx_clineno, __pyx_lineno, __pyx_filename);
9560  __Pyx_RefNannyFinishContext();
9561  return NULL;
9562  __pyx_L4_argument_unpacking_done:;
9563  __pyx_r = __pyx_pf_8PyClical_8clifford_70vector_part(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self), __pyx_v_frm);
9564 
9565  /* function exit code */
9566  __Pyx_RefNannyFinishContext();
9567  return __pyx_r;
9568  }
9569 
9570  static PyObject *__pyx_pf_8PyClical_8clifford_70vector_part(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_frm) {
9571  PyObject *__pyx_v_error_msg_prefix = NULL;
9572  std::vector<scalar_t> __pyx_v_vec;
9573  int __pyx_v_n;
9574  int __pyx_v_i;
9575  PyObject *__pyx_v_lst = NULL;
9576  PyObject *__pyx_v_err = NULL;
9577  PyObject *__pyx_r = NULL;
9578  __Pyx_RefNannyDeclarations
9579  PyObject *__pyx_t_1 = NULL;
9580  PyObject *__pyx_t_2 = NULL;
9581  PyObject *__pyx_t_3 = NULL;
9582  int __pyx_t_4;
9583  int __pyx_t_5;
9584  std::vector<scalar_t> __pyx_t_6;
9585  PyObject *__pyx_t_7 = NULL;
9586  int __pyx_t_8;
9587  int __pyx_t_9;
9588  PyObject *__pyx_t_10 = NULL;
9589  PyObject *__pyx_t_11 = NULL;
9590  PyObject *__pyx_t_12 = NULL;
9591  PyObject *__pyx_t_13 = NULL;
9592  PyObject *__pyx_t_14 = NULL;
9593  int __pyx_lineno = 0;
9594  const char *__pyx_filename = NULL;
9595  int __pyx_clineno = 0;
9596  __Pyx_RefNannySetupContext("vector_part", 0);
9597 
9598  /* "PyClical.pyx":1087
9599  * [0.0, 2.0, 3.0]
9600  * """
9601  * error_msg_prefix = "Cannot take vector part of " # <<<<<<<<<<<<<<
9602  * cdef vector[scalar_t] vec
9603  * cdef int n
9604  */
9605  __Pyx_INCREF(__pyx_kp_s_Cannot_take_vector_part_of);
9606  __pyx_v_error_msg_prefix = __pyx_kp_s_Cannot_take_vector_part_of;
9607 
9608  /* "PyClical.pyx":1091
9609  * cdef int n
9610  * cdef int i
9611  * try: # <<<<<<<<<<<<<<
9612  * if frm is None:
9613  * vec = self.instance.vector_part()
9614  */
9615  {
9616  __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3);
9617  __Pyx_XGOTREF(__pyx_t_1);
9618  __Pyx_XGOTREF(__pyx_t_2);
9619  __Pyx_XGOTREF(__pyx_t_3);
9620  /*try:*/ {
9621 
9622  /* "PyClical.pyx":1092
9623  * cdef int i
9624  * try:
9625  * if frm is None: # <<<<<<<<<<<<<<
9626  * vec = self.instance.vector_part()
9627  * else:
9628  */
9629  __pyx_t_4 = (__pyx_v_frm == Py_None);
9630  __pyx_t_5 = (__pyx_t_4 != 0);
9631  if (__pyx_t_5) {
9632 
9633  /* "PyClical.pyx":1093
9634  * try:
9635  * if frm is None:
9636  * vec = self.instance.vector_part() # <<<<<<<<<<<<<<
9637  * else:
9638  * vec = self.instance.vector_part((<index_set>frm).unwrap())
9639  */
9640  __pyx_v_vec = __pyx_v_self->instance->vector_part();
9641 
9642  /* "PyClical.pyx":1092
9643  * cdef int i
9644  * try:
9645  * if frm is None: # <<<<<<<<<<<<<<
9646  * vec = self.instance.vector_part()
9647  * else:
9648  */
9649  goto __pyx_L11;
9650  }
9651 
9652  /* "PyClical.pyx":1095
9653  * vec = self.instance.vector_part()
9654  * else:
9655  * vec = self.instance.vector_part((<index_set>frm).unwrap()) # <<<<<<<<<<<<<<
9656  * n = vec.size()
9657  * lst = [0.0]*n
9658  */
9659  /*else*/ {
9660  try {
9661  __pyx_t_6 = __pyx_v_self->instance->vector_part(__pyx_f_8PyClical_9index_set_unwrap(((struct __pyx_obj_8PyClical_index_set *)__pyx_v_frm)));
9662  } catch(...) {
9663  __Pyx_CppExn2PyErr();
9664  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1095; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
9665  }
9666  __pyx_v_vec = __pyx_t_6;
9667  }
9668  __pyx_L11:;
9669 
9670  /* "PyClical.pyx":1096
9671  * else:
9672  * vec = self.instance.vector_part((<index_set>frm).unwrap())
9673  * n = vec.size() # <<<<<<<<<<<<<<
9674  * lst = [0.0]*n
9675  * for i in xrange(n):
9676  */
9677  __pyx_v_n = __pyx_v_vec.size();
9678 
9679  /* "PyClical.pyx":1097
9680  * vec = self.instance.vector_part((<index_set>frm).unwrap())
9681  * n = vec.size()
9682  * lst = [0.0]*n # <<<<<<<<<<<<<<
9683  * for i in xrange(n):
9684  * lst[i] = vec[i]
9685  */
9686  __pyx_t_7 = PyList_New(1 * ((__pyx_v_n<0) ? 0:__pyx_v_n)); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1097; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
9687  __Pyx_GOTREF(__pyx_t_7);
9688  { Py_ssize_t __pyx_temp;
9689  for (__pyx_temp=0; __pyx_temp < __pyx_v_n; __pyx_temp++) {
9690  __Pyx_INCREF(__pyx_float_0_0);
9691  __Pyx_GIVEREF(__pyx_float_0_0);
9692  PyList_SET_ITEM(__pyx_t_7, __pyx_temp, __pyx_float_0_0);
9693  }
9694  }
9695  __pyx_v_lst = ((PyObject*)__pyx_t_7);
9696  __pyx_t_7 = 0;
9697 
9698  /* "PyClical.pyx":1098
9699  * n = vec.size()
9700  * lst = [0.0]*n
9701  * for i in xrange(n): # <<<<<<<<<<<<<<
9702  * lst[i] = vec[i]
9703  * return lst
9704  */
9705  __pyx_t_8 = __pyx_v_n;
9706  for (__pyx_t_9 = 0; __pyx_t_9 < __pyx_t_8; __pyx_t_9+=1) {
9707  __pyx_v_i = __pyx_t_9;
9708 
9709  /* "PyClical.pyx":1099
9710  * lst = [0.0]*n
9711  * for i in xrange(n):
9712  * lst[i] = vec[i] # <<<<<<<<<<<<<<
9713  * return lst
9714  * except RuntimeError as err:
9715  */
9716  __pyx_t_7 = PyFloat_FromDouble((__pyx_v_vec[__pyx_v_i])); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1099; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
9717  __Pyx_GOTREF(__pyx_t_7);
9718  if (unlikely(__Pyx_SetItemInt(__pyx_v_lst, __pyx_v_i, __pyx_t_7, int, 1, __Pyx_PyInt_From_int, 1, 1, 1) < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1099; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
9719  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
9720  }
9721 
9722  /* "PyClical.pyx":1100
9723  * for i in xrange(n):
9724  * lst[i] = vec[i]
9725  * return lst # <<<<<<<<<<<<<<
9726  * except RuntimeError as err:
9727  * raise ValueError(error_msg_prefix + str(self) + " using invalid "
9728  */
9729  __Pyx_XDECREF(__pyx_r);
9730  __Pyx_INCREF(__pyx_v_lst);
9731  __pyx_r = __pyx_v_lst;
9732  goto __pyx_L7_try_return;
9733 
9734  /* "PyClical.pyx":1091
9735  * cdef int n
9736  * cdef int i
9737  * try: # <<<<<<<<<<<<<<
9738  * if frm is None:
9739  * vec = self.instance.vector_part()
9740  */
9741  }
9742  __pyx_L3_error:;
9743  __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
9744 
9745  /* "PyClical.pyx":1101
9746  * lst[i] = vec[i]
9747  * return lst
9748  * except RuntimeError as err: # <<<<<<<<<<<<<<
9749  * raise ValueError(error_msg_prefix + str(self) + " using invalid "
9750  * + repr(frm) + " as frame:\n\t"
9751  */
9752  __pyx_t_8 = PyErr_ExceptionMatches(__pyx_builtin_RuntimeError);
9753  if (__pyx_t_8) {
9754  __Pyx_AddTraceback("PyClical.clifford.vector_part", __pyx_clineno, __pyx_lineno, __pyx_filename);
9755  if (__Pyx_GetException(&__pyx_t_7, &__pyx_t_10, &__pyx_t_11) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1101; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
9756  __Pyx_GOTREF(__pyx_t_7);
9757  __Pyx_GOTREF(__pyx_t_10);
9758  __Pyx_GOTREF(__pyx_t_11);
9759  __Pyx_INCREF(__pyx_t_10);
9760  __pyx_v_err = __pyx_t_10;
9761 
9762  /* "PyClical.pyx":1102
9763  * return lst
9764  * except RuntimeError as err:
9765  * raise ValueError(error_msg_prefix + str(self) + " using invalid " # <<<<<<<<<<<<<<
9766  * + repr(frm) + " as frame:\n\t"
9767  * + str(err))
9768  */
9769  __pyx_t_12 = PyTuple_New(1); if (unlikely(!__pyx_t_12)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1102; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
9770  __Pyx_GOTREF(__pyx_t_12);
9771  __Pyx_INCREF(((PyObject *)__pyx_v_self));
9772  __Pyx_GIVEREF(((PyObject *)__pyx_v_self));
9773  PyTuple_SET_ITEM(__pyx_t_12, 0, ((PyObject *)__pyx_v_self));
9774  __pyx_t_13 = __Pyx_PyObject_Call(((PyObject *)(&PyString_Type)), __pyx_t_12, NULL); if (unlikely(!__pyx_t_13)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1102; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
9775  __Pyx_GOTREF(__pyx_t_13);
9776  __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0;
9777  __pyx_t_12 = PyNumber_Add(__pyx_v_error_msg_prefix, __pyx_t_13); if (unlikely(!__pyx_t_12)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1102; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
9778  __Pyx_GOTREF(__pyx_t_12);
9779  __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
9780  __pyx_t_13 = PyNumber_Add(__pyx_t_12, __pyx_kp_s_using_invalid); if (unlikely(!__pyx_t_13)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1102; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
9781  __Pyx_GOTREF(__pyx_t_13);
9782  __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0;
9783 
9784  /* "PyClical.pyx":1103
9785  * except RuntimeError as err:
9786  * raise ValueError(error_msg_prefix + str(self) + " using invalid "
9787  * + repr(frm) + " as frame:\n\t" # <<<<<<<<<<<<<<
9788  * + str(err))
9789  *
9790  */
9791  __pyx_t_12 = PyObject_Repr(__pyx_v_frm); if (unlikely(!__pyx_t_12)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1103; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
9792  __Pyx_GOTREF(__pyx_t_12);
9793  __pyx_t_14 = PyNumber_Add(__pyx_t_13, __pyx_t_12); if (unlikely(!__pyx_t_14)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1103; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
9794  __Pyx_GOTREF(__pyx_t_14);
9795  __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
9796  __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0;
9797  __pyx_t_12 = PyNumber_Add(__pyx_t_14, __pyx_kp_s_as_frame); if (unlikely(!__pyx_t_12)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1103; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
9798  __Pyx_GOTREF(__pyx_t_12);
9799  __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0;
9800 
9801  /* "PyClical.pyx":1104
9802  * raise ValueError(error_msg_prefix + str(self) + " using invalid "
9803  * + repr(frm) + " as frame:\n\t"
9804  * + str(err)) # <<<<<<<<<<<<<<
9805  *
9806  * def involute(self):
9807  */
9808  __pyx_t_14 = PyTuple_New(1); if (unlikely(!__pyx_t_14)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1104; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
9809  __Pyx_GOTREF(__pyx_t_14);
9810  __Pyx_INCREF(__pyx_v_err);
9811  __Pyx_GIVEREF(__pyx_v_err);
9812  PyTuple_SET_ITEM(__pyx_t_14, 0, __pyx_v_err);
9813  __pyx_t_13 = __Pyx_PyObject_Call(((PyObject *)(&PyString_Type)), __pyx_t_14, NULL); if (unlikely(!__pyx_t_13)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1104; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
9814  __Pyx_GOTREF(__pyx_t_13);
9815  __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0;
9816  __pyx_t_14 = PyNumber_Add(__pyx_t_12, __pyx_t_13); if (unlikely(!__pyx_t_14)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1104; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
9817  __Pyx_GOTREF(__pyx_t_14);
9818  __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0;
9819  __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
9820 
9821  /* "PyClical.pyx":1102
9822  * return lst
9823  * except RuntimeError as err:
9824  * raise ValueError(error_msg_prefix + str(self) + " using invalid " # <<<<<<<<<<<<<<
9825  * + repr(frm) + " as frame:\n\t"
9826  * + str(err))
9827  */
9828  __pyx_t_13 = PyTuple_New(1); if (unlikely(!__pyx_t_13)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1102; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
9829  __Pyx_GOTREF(__pyx_t_13);
9830  __Pyx_GIVEREF(__pyx_t_14);
9831  PyTuple_SET_ITEM(__pyx_t_13, 0, __pyx_t_14);
9832  __pyx_t_14 = 0;
9833  __pyx_t_14 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_t_13, NULL); if (unlikely(!__pyx_t_14)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1102; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
9834  __Pyx_GOTREF(__pyx_t_14);
9835  __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
9836  __Pyx_Raise(__pyx_t_14, 0, 0, 0);
9837  __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0;
9838  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1102; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
9839  }
9840  goto __pyx_L5_except_error;
9841  __pyx_L5_except_error:;
9842 
9843  /* "PyClical.pyx":1091
9844  * cdef int n
9845  * cdef int i
9846  * try: # <<<<<<<<<<<<<<
9847  * if frm is None:
9848  * vec = self.instance.vector_part()
9849  */
9850  __Pyx_XGIVEREF(__pyx_t_1);
9851  __Pyx_XGIVEREF(__pyx_t_2);
9852  __Pyx_XGIVEREF(__pyx_t_3);
9853  __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
9854  goto __pyx_L1_error;
9855  __pyx_L7_try_return:;
9856  __Pyx_XGIVEREF(__pyx_t_1);
9857  __Pyx_XGIVEREF(__pyx_t_2);
9858  __Pyx_XGIVEREF(__pyx_t_3);
9859  __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
9860  goto __pyx_L0;
9861  }
9862 
9863  /* "PyClical.pyx":1078
9864  * return clifford().wrap( self.instance.odd() )
9865  *
9866  * def vector_part(self, frm = None): # <<<<<<<<<<<<<<
9867  * """
9868  * Vector part of multivector, as a Python list, with respect to frm.
9869  */
9870 
9871  /* function exit code */
9872  __pyx_L1_error:;
9873  __Pyx_XDECREF(__pyx_t_7);
9874  __Pyx_XDECREF(__pyx_t_10);
9875  __Pyx_XDECREF(__pyx_t_11);
9876  __Pyx_XDECREF(__pyx_t_12);
9877  __Pyx_XDECREF(__pyx_t_13);
9878  __Pyx_XDECREF(__pyx_t_14);
9879  __Pyx_AddTraceback("PyClical.clifford.vector_part", __pyx_clineno, __pyx_lineno, __pyx_filename);
9880  __pyx_r = NULL;
9881  __pyx_L0:;
9882  __Pyx_XDECREF(__pyx_v_error_msg_prefix);
9883  __Pyx_XDECREF(__pyx_v_lst);
9884  __Pyx_XDECREF(__pyx_v_err);
9885  __Pyx_XGIVEREF(__pyx_r);
9886  __Pyx_RefNannyFinishContext();
9887  return __pyx_r;
9888  }
9889 
9890  /* "PyClical.pyx":1106
9891  * + str(err))
9892  *
9893  * def involute(self): # <<<<<<<<<<<<<<
9894  * """
9895  * Main involution, each {i} is replaced by -{i} in each term,
9896  */
9897 
9898  /* Python wrapper */
9899  static PyObject *__pyx_pw_8PyClical_8clifford_73involute(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
9900  static char __pyx_doc_8PyClical_8clifford_72involute[] = "\n Main involution, each {i} is replaced by -{i} in each term,\n eg. clifford(\"{1}\") -> -clifford(\"{1}\").\n\n >>> print clifford(\"{1}\").involute()\n -{1}\n >>> print (clifford(\"{2}\") * clifford(\"{1}\")).involute()\n -{1,2}\n >>> print (clifford(\"{1}\") * clifford(\"{2}\")).involute()\n {1,2}\n >>> print clifford(\"1+{1}+{1,2}\").involute()\n 1-{1}+{1,2}\n ";
9901  static PyObject *__pyx_pw_8PyClical_8clifford_73involute(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
9902  PyObject *__pyx_r = 0;
9903  __Pyx_RefNannyDeclarations
9904  __Pyx_RefNannySetupContext("involute (wrapper)", 0);
9905  __pyx_r = __pyx_pf_8PyClical_8clifford_72involute(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self));
9906 
9907  /* function exit code */
9908  __Pyx_RefNannyFinishContext();
9909  return __pyx_r;
9910  }
9911 
9912  static PyObject *__pyx_pf_8PyClical_8clifford_72involute(struct __pyx_obj_8PyClical_clifford *__pyx_v_self) {
9913  PyObject *__pyx_r = NULL;
9914  __Pyx_RefNannyDeclarations
9915  PyObject *__pyx_t_1 = NULL;
9916  PyObject *__pyx_t_2 = NULL;
9917  int __pyx_lineno = 0;
9918  const char *__pyx_filename = NULL;
9919  int __pyx_clineno = 0;
9920  __Pyx_RefNannySetupContext("involute", 0);
9921 
9922  /* "PyClical.pyx":1120
9923  * 1-{1}+{1,2}
9924  * """
9925  * return clifford().wrap( self.instance.involute() ) # <<<<<<<<<<<<<<
9926  *
9927  * def reverse(self):
9928  */
9929  __Pyx_XDECREF(__pyx_r);
9930  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1120; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
9931  __Pyx_GOTREF(__pyx_t_1);
9932  __pyx_t_2 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), __pyx_v_self->instance->involute()); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1120; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
9933  __Pyx_GOTREF(__pyx_t_2);
9934  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
9935  __pyx_r = __pyx_t_2;
9936  __pyx_t_2 = 0;
9937  goto __pyx_L0;
9938 
9939  /* "PyClical.pyx":1106
9940  * + str(err))
9941  *
9942  * def involute(self): # <<<<<<<<<<<<<<
9943  * """
9944  * Main involution, each {i} is replaced by -{i} in each term,
9945  */
9946 
9947  /* function exit code */
9948  __pyx_L1_error:;
9949  __Pyx_XDECREF(__pyx_t_1);
9950  __Pyx_XDECREF(__pyx_t_2);
9951  __Pyx_AddTraceback("PyClical.clifford.involute", __pyx_clineno, __pyx_lineno, __pyx_filename);
9952  __pyx_r = NULL;
9953  __pyx_L0:;
9954  __Pyx_XGIVEREF(__pyx_r);
9955  __Pyx_RefNannyFinishContext();
9956  return __pyx_r;
9957  }
9958 
9959  /* "PyClical.pyx":1122
9960  * return clifford().wrap( self.instance.involute() )
9961  *
9962  * def reverse(self): # <<<<<<<<<<<<<<
9963  * """
9964  * Reversion, eg. clifford("{1}")*clifford("{2}") -> clifford("{2}")*clifford("{1}").
9965  */
9966 
9967  /* Python wrapper */
9968  static PyObject *__pyx_pw_8PyClical_8clifford_75reverse(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
9969  static char __pyx_doc_8PyClical_8clifford_74reverse[] = "\n Reversion, eg. clifford(\"{1}\")*clifford(\"{2}\") -> clifford(\"{2}\")*clifford(\"{1}\").\n\n >>> print clifford(\"{1}\").reverse()\n {1}\n >>> print (clifford(\"{2}\") * clifford(\"{1}\")).reverse()\n {1,2}\n >>> print (clifford(\"{1}\") * clifford(\"{2}\")).reverse()\n -{1,2}\n >>> print clifford(\"1+{1}+{1,2}\").reverse()\n 1+{1}-{1,2}\n ";
9970  static PyObject *__pyx_pw_8PyClical_8clifford_75reverse(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
9971  PyObject *__pyx_r = 0;
9972  __Pyx_RefNannyDeclarations
9973  __Pyx_RefNannySetupContext("reverse (wrapper)", 0);
9974  __pyx_r = __pyx_pf_8PyClical_8clifford_74reverse(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self));
9975 
9976  /* function exit code */
9977  __Pyx_RefNannyFinishContext();
9978  return __pyx_r;
9979  }
9980 
9981  static PyObject *__pyx_pf_8PyClical_8clifford_74reverse(struct __pyx_obj_8PyClical_clifford *__pyx_v_self) {
9982  PyObject *__pyx_r = NULL;
9983  __Pyx_RefNannyDeclarations
9984  PyObject *__pyx_t_1 = NULL;
9985  PyObject *__pyx_t_2 = NULL;
9986  int __pyx_lineno = 0;
9987  const char *__pyx_filename = NULL;
9988  int __pyx_clineno = 0;
9989  __Pyx_RefNannySetupContext("reverse", 0);
9990 
9991  /* "PyClical.pyx":1135
9992  * 1+{1}-{1,2}
9993  * """
9994  * return clifford().wrap( self.instance.reverse() ) # <<<<<<<<<<<<<<
9995  *
9996  * def conj(self):
9997  */
9998  __Pyx_XDECREF(__pyx_r);
9999  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1135; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10000  __Pyx_GOTREF(__pyx_t_1);
10001  __pyx_t_2 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), __pyx_v_self->instance->reverse()); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1135; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10002  __Pyx_GOTREF(__pyx_t_2);
10003  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
10004  __pyx_r = __pyx_t_2;
10005  __pyx_t_2 = 0;
10006  goto __pyx_L0;
10007 
10008  /* "PyClical.pyx":1122
10009  * return clifford().wrap( self.instance.involute() )
10010  *
10011  * def reverse(self): # <<<<<<<<<<<<<<
10012  * """
10013  * Reversion, eg. clifford("{1}")*clifford("{2}") -> clifford("{2}")*clifford("{1}").
10014  */
10015 
10016  /* function exit code */
10017  __pyx_L1_error:;
10018  __Pyx_XDECREF(__pyx_t_1);
10019  __Pyx_XDECREF(__pyx_t_2);
10020  __Pyx_AddTraceback("PyClical.clifford.reverse", __pyx_clineno, __pyx_lineno, __pyx_filename);
10021  __pyx_r = NULL;
10022  __pyx_L0:;
10023  __Pyx_XGIVEREF(__pyx_r);
10024  __Pyx_RefNannyFinishContext();
10025  return __pyx_r;
10026  }
10027 
10028  /* "PyClical.pyx":1137
10029  * return clifford().wrap( self.instance.reverse() )
10030  *
10031  * def conj(self): # <<<<<<<<<<<<<<
10032  * """
10033  * Conjugation, reverse o involute == involute o reverse.
10034  */
10035 
10036  /* Python wrapper */
10037  static PyObject *__pyx_pw_8PyClical_8clifford_77conj(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
10038  static char __pyx_doc_8PyClical_8clifford_76conj[] = "\n Conjugation, reverse o involute == involute o reverse.\n\n >>> print (clifford(\"{1}\")).conj()\n -{1}\n >>> print (clifford(\"{2}\") * clifford(\"{1}\")).conj()\n {1,2}\n >>> print (clifford(\"{1}\") * clifford(\"{2}\")).conj()\n -{1,2}\n >>> print clifford(\"1+{1}+{1,2}\").conj()\n 1-{1}-{1,2}\n ";
10039  static PyObject *__pyx_pw_8PyClical_8clifford_77conj(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
10040  PyObject *__pyx_r = 0;
10041  __Pyx_RefNannyDeclarations
10042  __Pyx_RefNannySetupContext("conj (wrapper)", 0);
10043  __pyx_r = __pyx_pf_8PyClical_8clifford_76conj(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self));
10044 
10045  /* function exit code */
10046  __Pyx_RefNannyFinishContext();
10047  return __pyx_r;
10048  }
10049 
10050  static PyObject *__pyx_pf_8PyClical_8clifford_76conj(struct __pyx_obj_8PyClical_clifford *__pyx_v_self) {
10051  PyObject *__pyx_r = NULL;
10052  __Pyx_RefNannyDeclarations
10053  PyObject *__pyx_t_1 = NULL;
10054  PyObject *__pyx_t_2 = NULL;
10055  int __pyx_lineno = 0;
10056  const char *__pyx_filename = NULL;
10057  int __pyx_clineno = 0;
10058  __Pyx_RefNannySetupContext("conj", 0);
10059 
10060  /* "PyClical.pyx":1150
10061  * 1-{1}-{1,2}
10062  * """
10063  * return clifford().wrap( self.instance.conj() ) # <<<<<<<<<<<<<<
10064  *
10065  * def quad(self):
10066  */
10067  __Pyx_XDECREF(__pyx_r);
10068  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1150; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10069  __Pyx_GOTREF(__pyx_t_1);
10070  __pyx_t_2 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), __pyx_v_self->instance->conj()); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1150; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10071  __Pyx_GOTREF(__pyx_t_2);
10072  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
10073  __pyx_r = __pyx_t_2;
10074  __pyx_t_2 = 0;
10075  goto __pyx_L0;
10076 
10077  /* "PyClical.pyx":1137
10078  * return clifford().wrap( self.instance.reverse() )
10079  *
10080  * def conj(self): # <<<<<<<<<<<<<<
10081  * """
10082  * Conjugation, reverse o involute == involute o reverse.
10083  */
10084 
10085  /* function exit code */
10086  __pyx_L1_error:;
10087  __Pyx_XDECREF(__pyx_t_1);
10088  __Pyx_XDECREF(__pyx_t_2);
10089  __Pyx_AddTraceback("PyClical.clifford.conj", __pyx_clineno, __pyx_lineno, __pyx_filename);
10090  __pyx_r = NULL;
10091  __pyx_L0:;
10092  __Pyx_XGIVEREF(__pyx_r);
10093  __Pyx_RefNannyFinishContext();
10094  return __pyx_r;
10095  }
10096 
10097  /* "PyClical.pyx":1152
10098  * return clifford().wrap( self.instance.conj() )
10099  *
10100  * def quad(self): # <<<<<<<<<<<<<<
10101  * """
10102  * Quadratic form == (rev(x)*x)(0).
10103  */
10104 
10105  /* Python wrapper */
10106  static PyObject *__pyx_pw_8PyClical_8clifford_79quad(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
10107  static char __pyx_doc_8PyClical_8clifford_78quad[] = "\n Quadratic form == (rev(x)*x)(0).\n\n >>> print clifford(\"1+{1}+{1,2}\").quad()\n 3.0\n >>> print clifford(\"1+{-1}+{1,2}+{1,2,3}\").quad()\n 2.0\n ";
10108  static PyObject *__pyx_pw_8PyClical_8clifford_79quad(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
10109  PyObject *__pyx_r = 0;
10110  __Pyx_RefNannyDeclarations
10111  __Pyx_RefNannySetupContext("quad (wrapper)", 0);
10112  __pyx_r = __pyx_pf_8PyClical_8clifford_78quad(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self));
10113 
10114  /* function exit code */
10115  __Pyx_RefNannyFinishContext();
10116  return __pyx_r;
10117  }
10118 
10119  static PyObject *__pyx_pf_8PyClical_8clifford_78quad(struct __pyx_obj_8PyClical_clifford *__pyx_v_self) {
10120  PyObject *__pyx_r = NULL;
10121  __Pyx_RefNannyDeclarations
10122  PyObject *__pyx_t_1 = NULL;
10123  int __pyx_lineno = 0;
10124  const char *__pyx_filename = NULL;
10125  int __pyx_clineno = 0;
10126  __Pyx_RefNannySetupContext("quad", 0);
10127 
10128  /* "PyClical.pyx":1161
10129  * 2.0
10130  * """
10131  * return self.instance.quad() # <<<<<<<<<<<<<<
10132  *
10133  * def norm(self):
10134  */
10135  __Pyx_XDECREF(__pyx_r);
10136  __pyx_t_1 = PyFloat_FromDouble(__pyx_v_self->instance->quad()); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1161; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10137  __Pyx_GOTREF(__pyx_t_1);
10138  __pyx_r = __pyx_t_1;
10139  __pyx_t_1 = 0;
10140  goto __pyx_L0;
10141 
10142  /* "PyClical.pyx":1152
10143  * return clifford().wrap( self.instance.conj() )
10144  *
10145  * def quad(self): # <<<<<<<<<<<<<<
10146  * """
10147  * Quadratic form == (rev(x)*x)(0).
10148  */
10149 
10150  /* function exit code */
10151  __pyx_L1_error:;
10152  __Pyx_XDECREF(__pyx_t_1);
10153  __Pyx_AddTraceback("PyClical.clifford.quad", __pyx_clineno, __pyx_lineno, __pyx_filename);
10154  __pyx_r = NULL;
10155  __pyx_L0:;
10156  __Pyx_XGIVEREF(__pyx_r);
10157  __Pyx_RefNannyFinishContext();
10158  return __pyx_r;
10159  }
10160 
10161  /* "PyClical.pyx":1163
10162  * return self.instance.quad()
10163  *
10164  * def norm(self): # <<<<<<<<<<<<<<
10165  * """
10166  * Norm == sum of squares of coordinates.
10167  */
10168 
10169  /* Python wrapper */
10170  static PyObject *__pyx_pw_8PyClical_8clifford_81norm(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
10171  static char __pyx_doc_8PyClical_8clifford_80norm[] = "\n Norm == sum of squares of coordinates.\n\n >>> clifford(\"1+{1}+{1,2}\").norm()\n 3.0\n >>> clifford(\"1+{-1}+{1,2}+{1,2,3}\").norm()\n 4.0\n ";
10172  static PyObject *__pyx_pw_8PyClical_8clifford_81norm(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
10173  PyObject *__pyx_r = 0;
10174  __Pyx_RefNannyDeclarations
10175  __Pyx_RefNannySetupContext("norm (wrapper)", 0);
10176  __pyx_r = __pyx_pf_8PyClical_8clifford_80norm(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self));
10177 
10178  /* function exit code */
10179  __Pyx_RefNannyFinishContext();
10180  return __pyx_r;
10181  }
10182 
10183  static PyObject *__pyx_pf_8PyClical_8clifford_80norm(struct __pyx_obj_8PyClical_clifford *__pyx_v_self) {
10184  PyObject *__pyx_r = NULL;
10185  __Pyx_RefNannyDeclarations
10186  PyObject *__pyx_t_1 = NULL;
10187  int __pyx_lineno = 0;
10188  const char *__pyx_filename = NULL;
10189  int __pyx_clineno = 0;
10190  __Pyx_RefNannySetupContext("norm", 0);
10191 
10192  /* "PyClical.pyx":1172
10193  * 4.0
10194  * """
10195  * return self.instance.norm() # <<<<<<<<<<<<<<
10196  *
10197  * def abs(self):
10198  */
10199  __Pyx_XDECREF(__pyx_r);
10200  __pyx_t_1 = PyFloat_FromDouble(__pyx_v_self->instance->norm()); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1172; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10201  __Pyx_GOTREF(__pyx_t_1);
10202  __pyx_r = __pyx_t_1;
10203  __pyx_t_1 = 0;
10204  goto __pyx_L0;
10205 
10206  /* "PyClical.pyx":1163
10207  * return self.instance.quad()
10208  *
10209  * def norm(self): # <<<<<<<<<<<<<<
10210  * """
10211  * Norm == sum of squares of coordinates.
10212  */
10213 
10214  /* function exit code */
10215  __pyx_L1_error:;
10216  __Pyx_XDECREF(__pyx_t_1);
10217  __Pyx_AddTraceback("PyClical.clifford.norm", __pyx_clineno, __pyx_lineno, __pyx_filename);
10218  __pyx_r = NULL;
10219  __pyx_L0:;
10220  __Pyx_XGIVEREF(__pyx_r);
10221  __Pyx_RefNannyFinishContext();
10222  return __pyx_r;
10223  }
10224 
10225  /* "PyClical.pyx":1174
10226  * return self.instance.norm()
10227  *
10228  * def abs(self): # <<<<<<<<<<<<<<
10229  * """
10230  * Absolute value: square root of norm.
10231  */
10232 
10233  /* Python wrapper */
10234  static PyObject *__pyx_pw_8PyClical_8clifford_83abs(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
10235  static char __pyx_doc_8PyClical_8clifford_82abs[] = "\n Absolute value: square root of norm.\n\n >>> clifford(\"1+{-1}+{1,2}+{1,2,3}\").abs()\n 2.0\n ";
10236  static PyObject *__pyx_pw_8PyClical_8clifford_83abs(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
10237  PyObject *__pyx_r = 0;
10238  __Pyx_RefNannyDeclarations
10239  __Pyx_RefNannySetupContext("abs (wrapper)", 0);
10240  __pyx_r = __pyx_pf_8PyClical_8clifford_82abs(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self));
10241 
10242  /* function exit code */
10243  __Pyx_RefNannyFinishContext();
10244  return __pyx_r;
10245  }
10246 
10247  static PyObject *__pyx_pf_8PyClical_8clifford_82abs(struct __pyx_obj_8PyClical_clifford *__pyx_v_self) {
10248  PyObject *__pyx_r = NULL;
10249  __Pyx_RefNannyDeclarations
10250  PyObject *__pyx_t_1 = NULL;
10251  int __pyx_lineno = 0;
10252  const char *__pyx_filename = NULL;
10253  int __pyx_clineno = 0;
10254  __Pyx_RefNannySetupContext("abs", 0);
10255 
10256  /* "PyClical.pyx":1181
10257  * 2.0
10258  * """
10259  * return glucat.abs( self.unwrap() ) # <<<<<<<<<<<<<<
10260  *
10261  * def max_abs(self):
10262  */
10263  __Pyx_XDECREF(__pyx_r);
10264  __pyx_t_1 = PyFloat_FromDouble(abs(__pyx_f_8PyClical_8clifford_unwrap(__pyx_v_self))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1181; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10265  __Pyx_GOTREF(__pyx_t_1);
10266  __pyx_r = __pyx_t_1;
10267  __pyx_t_1 = 0;
10268  goto __pyx_L0;
10269 
10270  /* "PyClical.pyx":1174
10271  * return self.instance.norm()
10272  *
10273  * def abs(self): # <<<<<<<<<<<<<<
10274  * """
10275  * Absolute value: square root of norm.
10276  */
10277 
10278  /* function exit code */
10279  __pyx_L1_error:;
10280  __Pyx_XDECREF(__pyx_t_1);
10281  __Pyx_AddTraceback("PyClical.clifford.abs", __pyx_clineno, __pyx_lineno, __pyx_filename);
10282  __pyx_r = NULL;
10283  __pyx_L0:;
10284  __Pyx_XGIVEREF(__pyx_r);
10285  __Pyx_RefNannyFinishContext();
10286  return __pyx_r;
10287  }
10288 
10289  /* "PyClical.pyx":1183
10290  * return glucat.abs( self.unwrap() )
10291  *
10292  * def max_abs(self): # <<<<<<<<<<<<<<
10293  * """
10294  * Maximum of absolute values of components of multivector: multivector infinity norm.
10295  */
10296 
10297  /* Python wrapper */
10298  static PyObject *__pyx_pw_8PyClical_8clifford_85max_abs(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
10299  static char __pyx_doc_8PyClical_8clifford_84max_abs[] = "\n Maximum of absolute values of components of multivector: multivector infinity norm.\n\n >>> clifford(\"1+{-1}+{1,2}+{1,2,3}\").max_abs()\n 1.0\n >>> clifford(\"3+2{1}+{1,2}\").max_abs()\n 3.0\n ";
10300  static PyObject *__pyx_pw_8PyClical_8clifford_85max_abs(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
10301  PyObject *__pyx_r = 0;
10302  __Pyx_RefNannyDeclarations
10303  __Pyx_RefNannySetupContext("max_abs (wrapper)", 0);
10304  __pyx_r = __pyx_pf_8PyClical_8clifford_84max_abs(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self));
10305 
10306  /* function exit code */
10307  __Pyx_RefNannyFinishContext();
10308  return __pyx_r;
10309  }
10310 
10311  static PyObject *__pyx_pf_8PyClical_8clifford_84max_abs(struct __pyx_obj_8PyClical_clifford *__pyx_v_self) {
10312  PyObject *__pyx_r = NULL;
10313  __Pyx_RefNannyDeclarations
10314  PyObject *__pyx_t_1 = NULL;
10315  int __pyx_lineno = 0;
10316  const char *__pyx_filename = NULL;
10317  int __pyx_clineno = 0;
10318  __Pyx_RefNannySetupContext("max_abs", 0);
10319 
10320  /* "PyClical.pyx":1192
10321  * 3.0
10322  * """
10323  * return self.instance.max_abs() # <<<<<<<<<<<<<<
10324  *
10325  * def truncated(self, limit):
10326  */
10327  __Pyx_XDECREF(__pyx_r);
10328  __pyx_t_1 = PyFloat_FromDouble(__pyx_v_self->instance->max_abs()); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1192; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10329  __Pyx_GOTREF(__pyx_t_1);
10330  __pyx_r = __pyx_t_1;
10331  __pyx_t_1 = 0;
10332  goto __pyx_L0;
10333 
10334  /* "PyClical.pyx":1183
10335  * return glucat.abs( self.unwrap() )
10336  *
10337  * def max_abs(self): # <<<<<<<<<<<<<<
10338  * """
10339  * Maximum of absolute values of components of multivector: multivector infinity norm.
10340  */
10341 
10342  /* function exit code */
10343  __pyx_L1_error:;
10344  __Pyx_XDECREF(__pyx_t_1);
10345  __Pyx_AddTraceback("PyClical.clifford.max_abs", __pyx_clineno, __pyx_lineno, __pyx_filename);
10346  __pyx_r = NULL;
10347  __pyx_L0:;
10348  __Pyx_XGIVEREF(__pyx_r);
10349  __Pyx_RefNannyFinishContext();
10350  return __pyx_r;
10351  }
10352 
10353  /* "PyClical.pyx":1194
10354  * return self.instance.max_abs()
10355  *
10356  * def truncated(self, limit): # <<<<<<<<<<<<<<
10357  * """
10358  * Remove all terms of self with relative size smaller than limit.
10359  */
10360 
10361  /* Python wrapper */
10362  static PyObject *__pyx_pw_8PyClical_8clifford_87truncated(PyObject *__pyx_v_self, PyObject *__pyx_v_limit); /*proto*/
10363  static char __pyx_doc_8PyClical_8clifford_86truncated[] = "\n Remove all terms of self with relative size smaller than limit.\n\n >>> clifford(\"1e8+{1}+1e-8{1,2}\").truncated(1.0e-6)\n clifford(\"100000000\")\n >>> clifford(\"1e4+{1}+1e-4{1,2}\").truncated(1.0e-6)\n clifford(\"10000+{1}\")\n ";
10364  static PyObject *__pyx_pw_8PyClical_8clifford_87truncated(PyObject *__pyx_v_self, PyObject *__pyx_v_limit) {
10365  PyObject *__pyx_r = 0;
10366  __Pyx_RefNannyDeclarations
10367  __Pyx_RefNannySetupContext("truncated (wrapper)", 0);
10368  __pyx_r = __pyx_pf_8PyClical_8clifford_86truncated(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self), ((PyObject *)__pyx_v_limit));
10369 
10370  /* function exit code */
10371  __Pyx_RefNannyFinishContext();
10372  return __pyx_r;
10373  }
10374 
10375  static PyObject *__pyx_pf_8PyClical_8clifford_86truncated(struct __pyx_obj_8PyClical_clifford *__pyx_v_self, PyObject *__pyx_v_limit) {
10376  PyObject *__pyx_r = NULL;
10377  __Pyx_RefNannyDeclarations
10378  PyObject *__pyx_t_1 = NULL;
10379  scalar_t __pyx_t_2;
10380  PyObject *__pyx_t_3 = NULL;
10381  int __pyx_lineno = 0;
10382  const char *__pyx_filename = NULL;
10383  int __pyx_clineno = 0;
10384  __Pyx_RefNannySetupContext("truncated", 0);
10385 
10386  /* "PyClical.pyx":1203
10387  * clifford("10000+{1}")
10388  * """
10389  * return clifford().wrap( self.instance.truncated(limit) ) # <<<<<<<<<<<<<<
10390  *
10391  * def isnan(self):
10392  */
10393  __Pyx_XDECREF(__pyx_r);
10394  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10395  __Pyx_GOTREF(__pyx_t_1);
10396  __pyx_t_2 = __pyx_PyFloat_AsDouble(__pyx_v_limit); if (unlikely((__pyx_t_2 == (scalar_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10397  __pyx_t_3 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), __pyx_v_self->instance->truncated(__pyx_t_2)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10398  __Pyx_GOTREF(__pyx_t_3);
10399  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
10400  __pyx_r = __pyx_t_3;
10401  __pyx_t_3 = 0;
10402  goto __pyx_L0;
10403 
10404  /* "PyClical.pyx":1194
10405  * return self.instance.max_abs()
10406  *
10407  * def truncated(self, limit): # <<<<<<<<<<<<<<
10408  * """
10409  * Remove all terms of self with relative size smaller than limit.
10410  */
10411 
10412  /* function exit code */
10413  __pyx_L1_error:;
10414  __Pyx_XDECREF(__pyx_t_1);
10415  __Pyx_XDECREF(__pyx_t_3);
10416  __Pyx_AddTraceback("PyClical.clifford.truncated", __pyx_clineno, __pyx_lineno, __pyx_filename);
10417  __pyx_r = NULL;
10418  __pyx_L0:;
10419  __Pyx_XGIVEREF(__pyx_r);
10420  __Pyx_RefNannyFinishContext();
10421  return __pyx_r;
10422  }
10423 
10424  /* "PyClical.pyx":1205
10425  * return clifford().wrap( self.instance.truncated(limit) )
10426  *
10427  * def isnan(self): # <<<<<<<<<<<<<<
10428  * """
10429  * Check if a multivector contains any IEEE NaN values.
10430  */
10431 
10432  /* Python wrapper */
10433  static PyObject *__pyx_pw_8PyClical_8clifford_89isnan(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
10434  static char __pyx_doc_8PyClical_8clifford_88isnan[] = "\n Check if a multivector contains any IEEE NaN values.\n\n >>> clifford().isnan()\n False\n ";
10435  static PyObject *__pyx_pw_8PyClical_8clifford_89isnan(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
10436  PyObject *__pyx_r = 0;
10437  __Pyx_RefNannyDeclarations
10438  __Pyx_RefNannySetupContext("isnan (wrapper)", 0);
10439  __pyx_r = __pyx_pf_8PyClical_8clifford_88isnan(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self));
10440 
10441  /* function exit code */
10442  __Pyx_RefNannyFinishContext();
10443  return __pyx_r;
10444  }
10445 
10446  static PyObject *__pyx_pf_8PyClical_8clifford_88isnan(struct __pyx_obj_8PyClical_clifford *__pyx_v_self) {
10447  PyObject *__pyx_r = NULL;
10448  __Pyx_RefNannyDeclarations
10449  PyObject *__pyx_t_1 = NULL;
10450  int __pyx_lineno = 0;
10451  const char *__pyx_filename = NULL;
10452  int __pyx_clineno = 0;
10453  __Pyx_RefNannySetupContext("isnan", 0);
10454 
10455  /* "PyClical.pyx":1212
10456  * False
10457  * """
10458  * return self.instance.isnan() # <<<<<<<<<<<<<<
10459  *
10460  * def frame(self):
10461  */
10462  __Pyx_XDECREF(__pyx_r);
10463  __pyx_t_1 = __Pyx_PyBool_FromLong(__pyx_v_self->instance->isnan()); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1212; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10464  __Pyx_GOTREF(__pyx_t_1);
10465  __pyx_r = __pyx_t_1;
10466  __pyx_t_1 = 0;
10467  goto __pyx_L0;
10468 
10469  /* "PyClical.pyx":1205
10470  * return clifford().wrap( self.instance.truncated(limit) )
10471  *
10472  * def isnan(self): # <<<<<<<<<<<<<<
10473  * """
10474  * Check if a multivector contains any IEEE NaN values.
10475  */
10476 
10477  /* function exit code */
10478  __pyx_L1_error:;
10479  __Pyx_XDECREF(__pyx_t_1);
10480  __Pyx_AddTraceback("PyClical.clifford.isnan", __pyx_clineno, __pyx_lineno, __pyx_filename);
10481  __pyx_r = NULL;
10482  __pyx_L0:;
10483  __Pyx_XGIVEREF(__pyx_r);
10484  __Pyx_RefNannyFinishContext();
10485  return __pyx_r;
10486  }
10487 
10488  /* "PyClical.pyx":1214
10489  * return self.instance.isnan()
10490  *
10491  * def frame(self): # <<<<<<<<<<<<<<
10492  * """
10493  * Subalgebra generated by all generators of terms of given multivector.
10494  */
10495 
10496  /* Python wrapper */
10497  static PyObject *__pyx_pw_8PyClical_8clifford_91frame(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
10498  static char __pyx_doc_8PyClical_8clifford_90frame[] = "\n Subalgebra generated by all generators of terms of given multivector.\n\n >>> print clifford(\"1+3{-1}+2{1,2}+4{-2,7}\").frame()\n {-2,-1,1,2,7}\n >>> s=clifford(\"1+3{-1}+2{1,2}+4{-2,7}\").frame(); type(s)\n <type 'PyClical.index_set'>\n ";
10499  static PyObject *__pyx_pw_8PyClical_8clifford_91frame(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
10500  PyObject *__pyx_r = 0;
10501  __Pyx_RefNannyDeclarations
10502  __Pyx_RefNannySetupContext("frame (wrapper)", 0);
10503  __pyx_r = __pyx_pf_8PyClical_8clifford_90frame(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self));
10504 
10505  /* function exit code */
10506  __Pyx_RefNannyFinishContext();
10507  return __pyx_r;
10508  }
10509 
10510  static PyObject *__pyx_pf_8PyClical_8clifford_90frame(struct __pyx_obj_8PyClical_clifford *__pyx_v_self) {
10511  PyObject *__pyx_r = NULL;
10512  __Pyx_RefNannyDeclarations
10513  PyObject *__pyx_t_1 = NULL;
10514  PyObject *__pyx_t_2 = NULL;
10515  int __pyx_lineno = 0;
10516  const char *__pyx_filename = NULL;
10517  int __pyx_clineno = 0;
10518  __Pyx_RefNannySetupContext("frame", 0);
10519 
10520  /* "PyClical.pyx":1223
10521  * <type 'PyClical.index_set'>
10522  * """
10523  * return index_set().wrap( self.instance.frame() ) # <<<<<<<<<<<<<<
10524  *
10525  * def __repr__(self):
10526  */
10527  __Pyx_XDECREF(__pyx_r);
10528  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_index_set), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1223; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10529  __Pyx_GOTREF(__pyx_t_1);
10530  __pyx_t_2 = __pyx_f_8PyClical_9index_set_wrap(((struct __pyx_obj_8PyClical_index_set *)__pyx_t_1), __pyx_v_self->instance->frame()); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1223; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10531  __Pyx_GOTREF(__pyx_t_2);
10532  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
10533  __pyx_r = __pyx_t_2;
10534  __pyx_t_2 = 0;
10535  goto __pyx_L0;
10536 
10537  /* "PyClical.pyx":1214
10538  * return self.instance.isnan()
10539  *
10540  * def frame(self): # <<<<<<<<<<<<<<
10541  * """
10542  * Subalgebra generated by all generators of terms of given multivector.
10543  */
10544 
10545  /* function exit code */
10546  __pyx_L1_error:;
10547  __Pyx_XDECREF(__pyx_t_1);
10548  __Pyx_XDECREF(__pyx_t_2);
10549  __Pyx_AddTraceback("PyClical.clifford.frame", __pyx_clineno, __pyx_lineno, __pyx_filename);
10550  __pyx_r = NULL;
10551  __pyx_L0:;
10552  __Pyx_XGIVEREF(__pyx_r);
10553  __Pyx_RefNannyFinishContext();
10554  return __pyx_r;
10555  }
10556 
10557  /* "PyClical.pyx":1225
10558  * return index_set().wrap( self.instance.frame() )
10559  *
10560  * def __repr__(self): # <<<<<<<<<<<<<<
10561  * """
10562  * The official string representation of self.
10563  */
10564 
10565  /* Python wrapper */
10566  static PyObject *__pyx_pw_8PyClical_8clifford_93__repr__(PyObject *__pyx_v_self); /*proto*/
10567  static char __pyx_doc_8PyClical_8clifford_92__repr__[] = "\n The \342\200\234official\342\200\235 string representation of self.\n\n >>> clifford(\"1+3{-1}+2{1,2}+4{-2,7}\").__repr__()\n 'clifford(\"1+3{-1}+2{1,2}+4{-2,7}\")'\n ";
10568  #if CYTHON_COMPILING_IN_CPYTHON
10569  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_92__repr__;
10570  #endif
10571  static PyObject *__pyx_pw_8PyClical_8clifford_93__repr__(PyObject *__pyx_v_self) {
10572  PyObject *__pyx_r = 0;
10573  __Pyx_RefNannyDeclarations
10574  __Pyx_RefNannySetupContext("__repr__ (wrapper)", 0);
10575  __pyx_r = __pyx_pf_8PyClical_8clifford_92__repr__(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self));
10576 
10577  /* function exit code */
10578  __Pyx_RefNannyFinishContext();
10579  return __pyx_r;
10580  }
10581 
10582  static PyObject *__pyx_pf_8PyClical_8clifford_92__repr__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self) {
10583  PyObject *__pyx_r = NULL;
10584  __Pyx_RefNannyDeclarations
10585  PyObject *__pyx_t_1 = NULL;
10586  int __pyx_lineno = 0;
10587  const char *__pyx_filename = NULL;
10588  int __pyx_clineno = 0;
10589  __Pyx_RefNannySetupContext("__repr__", 0);
10590 
10591  /* "PyClical.pyx":1232
10592  * 'clifford("1+3{-1}+2{1,2}+4{-2,7}")'
10593  * """
10594  * return clifford_to_repr( self.unwrap() ).c_str() # <<<<<<<<<<<<<<
10595  *
10596  * def __str__(self):
10597  */
10598  __Pyx_XDECREF(__pyx_r);
10599  __pyx_t_1 = __Pyx_PyBytes_FromString(clifford_to_repr(__pyx_f_8PyClical_8clifford_unwrap(__pyx_v_self)).c_str()); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1232; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10600  __Pyx_GOTREF(__pyx_t_1);
10601  __pyx_r = __pyx_t_1;
10602  __pyx_t_1 = 0;
10603  goto __pyx_L0;
10604 
10605  /* "PyClical.pyx":1225
10606  * return index_set().wrap( self.instance.frame() )
10607  *
10608  * def __repr__(self): # <<<<<<<<<<<<<<
10609  * """
10610  * The official string representation of self.
10611  */
10612 
10613  /* function exit code */
10614  __pyx_L1_error:;
10615  __Pyx_XDECREF(__pyx_t_1);
10616  __Pyx_AddTraceback("PyClical.clifford.__repr__", __pyx_clineno, __pyx_lineno, __pyx_filename);
10617  __pyx_r = NULL;
10618  __pyx_L0:;
10619  __Pyx_XGIVEREF(__pyx_r);
10620  __Pyx_RefNannyFinishContext();
10621  return __pyx_r;
10622  }
10623 
10624  /* "PyClical.pyx":1234
10625  * return clifford_to_repr( self.unwrap() ).c_str()
10626  *
10627  * def __str__(self): # <<<<<<<<<<<<<<
10628  * """
10629  * The informal string representation of self.
10630  */
10631 
10632  /* Python wrapper */
10633  static PyObject *__pyx_pw_8PyClical_8clifford_95__str__(PyObject *__pyx_v_self); /*proto*/
10634  static char __pyx_doc_8PyClical_8clifford_94__str__[] = "\n The \342\200\234informal\342\200\235 string representation of self.\n\n >>> clifford(\"1+3{-1}+2{1,2}+4{-2,7}\").__str__()\n '1+3{-1}+2{1,2}+4{-2,7}'\n ";
10635  #if CYTHON_COMPILING_IN_CPYTHON
10636  struct wrapperbase __pyx_wrapperbase_8PyClical_8clifford_94__str__;
10637  #endif
10638  static PyObject *__pyx_pw_8PyClical_8clifford_95__str__(PyObject *__pyx_v_self) {
10639  PyObject *__pyx_r = 0;
10640  __Pyx_RefNannyDeclarations
10641  __Pyx_RefNannySetupContext("__str__ (wrapper)", 0);
10642  __pyx_r = __pyx_pf_8PyClical_8clifford_94__str__(((struct __pyx_obj_8PyClical_clifford *)__pyx_v_self));
10643 
10644  /* function exit code */
10645  __Pyx_RefNannyFinishContext();
10646  return __pyx_r;
10647  }
10648 
10649  static PyObject *__pyx_pf_8PyClical_8clifford_94__str__(struct __pyx_obj_8PyClical_clifford *__pyx_v_self) {
10650  PyObject *__pyx_r = NULL;
10651  __Pyx_RefNannyDeclarations
10652  PyObject *__pyx_t_1 = NULL;
10653  int __pyx_lineno = 0;
10654  const char *__pyx_filename = NULL;
10655  int __pyx_clineno = 0;
10656  __Pyx_RefNannySetupContext("__str__", 0);
10657 
10658  /* "PyClical.pyx":1241
10659  * '1+3{-1}+2{1,2}+4{-2,7}'
10660  * """
10661  * return clifford_to_str( self.unwrap() ).c_str() # <<<<<<<<<<<<<<
10662  *
10663  * def clifford_hidden_doctests():
10664  */
10665  __Pyx_XDECREF(__pyx_r);
10666  __pyx_t_1 = __Pyx_PyBytes_FromString(clifford_to_str(__pyx_f_8PyClical_8clifford_unwrap(__pyx_v_self)).c_str()); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1241; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10667  __Pyx_GOTREF(__pyx_t_1);
10668  __pyx_r = __pyx_t_1;
10669  __pyx_t_1 = 0;
10670  goto __pyx_L0;
10671 
10672  /* "PyClical.pyx":1234
10673  * return clifford_to_repr( self.unwrap() ).c_str()
10674  *
10675  * def __str__(self): # <<<<<<<<<<<<<<
10676  * """
10677  * The informal string representation of self.
10678  */
10679 
10680  /* function exit code */
10681  __pyx_L1_error:;
10682  __Pyx_XDECREF(__pyx_t_1);
10683  __Pyx_AddTraceback("PyClical.clifford.__str__", __pyx_clineno, __pyx_lineno, __pyx_filename);
10684  __pyx_r = NULL;
10685  __pyx_L0:;
10686  __Pyx_XGIVEREF(__pyx_r);
10687  __Pyx_RefNannyFinishContext();
10688  return __pyx_r;
10689  }
10690 
10691  /* "PyClical.pyx":1243
10692  * return clifford_to_str( self.unwrap() ).c_str()
10693  *
10694  * def clifford_hidden_doctests(): # <<<<<<<<<<<<<<
10695  * """
10696  * Tests for functions that Doctest cannot see.
10697  */
10698 
10699  /* Python wrapper */
10700  static PyObject *__pyx_pw_8PyClical_9clifford_hidden_doctests(PyObject *__pyx_self, CYTHON_UNUSED PyObject *unused); /*proto*/
10701  static char __pyx_doc_8PyClical_8clifford_hidden_doctests[] = "\n Tests for functions that Doctest cannot see.\n\n For clifford.__cinit__: Construct an object of type clifford.\n\n >>> print clifford(2)\n 2\n >>> print clifford(2L)\n 2\n >>> print clifford(2.0)\n 2\n >>> print clifford(1.0e-1)\n 0.1\n >>> print clifford(\"2\")\n 2\n >>> print clifford(\"2{1,2,3}\")\n 2{1,2,3}\n >>> print clifford(clifford(\"2{1,2,3}\"))\n 2{1,2,3}\n >>> print clifford(\"-{1}\")\n -{1}\n >>> print clifford(2,index_set({1,2}))\n 2{1,2}\n >>> print clifford([2,3],index_set({1,2}))\n 2{1}+3{2}\n >>> print clifford([1,2])\n Traceback (most recent call last):\n ...\n TypeError: Cannot initialize clifford object from <type 'list'>.\n >>> print clifford(None)\n Traceback (most recent call last):\n ...\n TypeError: Cannot initialize clifford object from <type 'NoneType'>.\n >>> print clifford(None,[1,2])\n Traceback (most recent call last):\n ...\n TypeError: Cannot initialize clifford object from (<type 'NoneType'>, <type 'list'>).\n >>> print clifford([1,2],[1,2])\n Traceback (most recent call last):\n ...\n TypeError: Cannot initialize clifford object from (<type 'list'>, <type 'list'>).\n >>> print clifford(\"\")\n Traceback (most recent call last):\n ...\n ValueError: Cannot initialize clifford object from invalid string ''.\n >>> print clifford(\"{\")\n Traceback (most recent call last):\n ...\n ValueError: Cannot initialize clifford object from invalid string '{'.\n >>> print clifford(\"{1\")\n Traceback (most recent call last):\n ...\n ValueError: Cannot initialize clifford object from invalid string '{1'.\n >>> print clifford(\"+\")\n Traceback (most recent call last):\n ...\n ValueError: Cannot initialize clifford object from invalid string '+'.\n >>> print clifford(\"-\")\n Traceback (most recent call last):\n ...\n ValueError: Cannot initialize clifford"" object from invalid string '-'.\n >>> print clifford(\"{1}+\")\n Traceback (most recent call last):\n ...\n ValueError: Cannot initialize clifford object from invalid string '{1}+'.\n\n For clifford.__richcmp__: Compare objects of type clifford.\n\n >>> clifford(\"{1}\") == clifford(\"1{1}\")\n True\n >>> clifford(\"{1}\") != clifford(\"1.0{1}\")\n False\n >>> clifford(\"{1}\") != clifford(\"1.0\")\n True\n >>> clifford(\"{1,2}\") == None\n False\n >>> clifford(\"{1,2}\") != None\n True\n >>> None == clifford(\"{1,2}\")\n False\n >>> None != clifford(\"{1,2}\")\n True\n ";
10702  static PyMethodDef __pyx_mdef_8PyClical_9clifford_hidden_doctests = {"clifford_hidden_doctests", (PyCFunction)__pyx_pw_8PyClical_9clifford_hidden_doctests, METH_NOARGS, __pyx_doc_8PyClical_8clifford_hidden_doctests};
10703  static PyObject *__pyx_pw_8PyClical_9clifford_hidden_doctests(PyObject *__pyx_self, CYTHON_UNUSED PyObject *unused) {
10704  PyObject *__pyx_r = 0;
10705  __Pyx_RefNannyDeclarations
10706  __Pyx_RefNannySetupContext("clifford_hidden_doctests (wrapper)", 0);
10707  __pyx_r = __pyx_pf_8PyClical_8clifford_hidden_doctests(__pyx_self);
10708 
10709  /* function exit code */
10710  __Pyx_RefNannyFinishContext();
10711  return __pyx_r;
10712  }
10713 
10714  static PyObject *__pyx_pf_8PyClical_8clifford_hidden_doctests(CYTHON_UNUSED PyObject *__pyx_self) {
10715  PyObject *__pyx_r = NULL;
10716  __Pyx_RefNannyDeclarations
10717  __Pyx_RefNannySetupContext("clifford_hidden_doctests", 0);
10718 
10719  /* "PyClical.pyx":1327
10720  * True
10721  * """
10722  * return # <<<<<<<<<<<<<<
10723  *
10724  * cpdef inline inv(obj):
10725  */
10726  __Pyx_XDECREF(__pyx_r);
10727  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
10728  goto __pyx_L0;
10729 
10730  /* "PyClical.pyx":1243
10731  * return clifford_to_str( self.unwrap() ).c_str()
10732  *
10733  * def clifford_hidden_doctests(): # <<<<<<<<<<<<<<
10734  * """
10735  * Tests for functions that Doctest cannot see.
10736  */
10737 
10738  /* function exit code */
10739  __pyx_L0:;
10740  __Pyx_XGIVEREF(__pyx_r);
10741  __Pyx_RefNannyFinishContext();
10742  return __pyx_r;
10743  }
10744 
10745  /* "PyClical.pyx":1329
10746  * return
10747  *
10748  * cpdef inline inv(obj): # <<<<<<<<<<<<<<
10749  * """
10750  * Geometric multiplicative inverse.
10751  */
10752 
10753  static PyObject *__pyx_pw_8PyClical_11inv(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
10754  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_inv(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
10755  PyObject *__pyx_r = NULL;
10756  __Pyx_RefNannyDeclarations
10757  PyObject *__pyx_t_1 = NULL;
10758  PyObject *__pyx_t_2 = NULL;
10759  PyObject *__pyx_t_3 = NULL;
10760  int __pyx_lineno = 0;
10761  const char *__pyx_filename = NULL;
10762  int __pyx_clineno = 0;
10763  __Pyx_RefNannySetupContext("inv", 0);
10764 
10765  /* "PyClical.pyx":1342
10766  * nan
10767  * """
10768  * return clifford(obj).inv() # <<<<<<<<<<<<<<
10769  *
10770  * cpdef inline scalar(obj):
10771  */
10772  __Pyx_XDECREF(__pyx_r);
10773  __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1342; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10774  __Pyx_GOTREF(__pyx_t_2);
10775  __Pyx_INCREF(__pyx_v_obj);
10776  __Pyx_GIVEREF(__pyx_v_obj);
10777  PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_obj);
10778  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1342; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10779  __Pyx_GOTREF(__pyx_t_3);
10780  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
10781  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_inv); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1342; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10782  __Pyx_GOTREF(__pyx_t_2);
10783  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
10784  __pyx_t_3 = NULL;
10785  if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_2))) {
10786  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
10787  if (likely(__pyx_t_3)) {
10788  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
10789  __Pyx_INCREF(__pyx_t_3);
10790  __Pyx_INCREF(function);
10791  __Pyx_DECREF_SET(__pyx_t_2, function);
10792  }
10793  }
10794  if (__pyx_t_3) {
10795  __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1342; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10796  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
10797  } else {
10798  __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1342; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10799  }
10800  __Pyx_GOTREF(__pyx_t_1);
10801  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
10802  __pyx_r = __pyx_t_1;
10803  __pyx_t_1 = 0;
10804  goto __pyx_L0;
10805 
10806  /* "PyClical.pyx":1329
10807  * return
10808  *
10809  * cpdef inline inv(obj): # <<<<<<<<<<<<<<
10810  * """
10811  * Geometric multiplicative inverse.
10812  */
10813 
10814  /* function exit code */
10815  __pyx_L1_error:;
10816  __Pyx_XDECREF(__pyx_t_1);
10817  __Pyx_XDECREF(__pyx_t_2);
10818  __Pyx_XDECREF(__pyx_t_3);
10819  __Pyx_AddTraceback("PyClical.inv", __pyx_clineno, __pyx_lineno, __pyx_filename);
10820  __pyx_r = 0;
10821  __pyx_L0:;
10822  __Pyx_XGIVEREF(__pyx_r);
10823  __Pyx_RefNannyFinishContext();
10824  return __pyx_r;
10825  }
10826 
10827  /* Python wrapper */
10828  static PyObject *__pyx_pw_8PyClical_11inv(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
10829  static char __pyx_doc_8PyClical_10inv[] = "\n Geometric multiplicative inverse.\n\n >>> print inv(clifford(\"{1}\"))\n {1}\n >>> print inv(clifford(\"{-1}\"))\n -{-1}\n >>> print inv(clifford(\"{-2,-1}\"))\n -{-2,-1}\n >>> print inv(clifford(\"{-1}+{1}\"))\n nan\n ";
10830  static PyObject *__pyx_pw_8PyClical_11inv(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
10831  PyObject *__pyx_r = 0;
10832  __Pyx_RefNannyDeclarations
10833  __Pyx_RefNannySetupContext("inv (wrapper)", 0);
10834  __pyx_r = __pyx_pf_8PyClical_10inv(__pyx_self, ((PyObject *)__pyx_v_obj));
10835 
10836  /* function exit code */
10837  __Pyx_RefNannyFinishContext();
10838  return __pyx_r;
10839  }
10840 
10841  static PyObject *__pyx_pf_8PyClical_10inv(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
10842  PyObject *__pyx_r = NULL;
10843  __Pyx_RefNannyDeclarations
10844  PyObject *__pyx_t_1 = NULL;
10845  int __pyx_lineno = 0;
10846  const char *__pyx_filename = NULL;
10847  int __pyx_clineno = 0;
10848  __Pyx_RefNannySetupContext("inv", 0);
10849  __Pyx_XDECREF(__pyx_r);
10850  __pyx_t_1 = __pyx_f_8PyClical_inv(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1329; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10851  __Pyx_GOTREF(__pyx_t_1);
10852  __pyx_r = __pyx_t_1;
10853  __pyx_t_1 = 0;
10854  goto __pyx_L0;
10855 
10856  /* function exit code */
10857  __pyx_L1_error:;
10858  __Pyx_XDECREF(__pyx_t_1);
10859  __Pyx_AddTraceback("PyClical.inv", __pyx_clineno, __pyx_lineno, __pyx_filename);
10860  __pyx_r = NULL;
10861  __pyx_L0:;
10862  __Pyx_XGIVEREF(__pyx_r);
10863  __Pyx_RefNannyFinishContext();
10864  return __pyx_r;
10865  }
10866 
10867  /* "PyClical.pyx":1344
10868  * return clifford(obj).inv()
10869  *
10870  * cpdef inline scalar(obj): # <<<<<<<<<<<<<<
10871  * """
10872  * Scalar part.
10873  */
10874 
10875  static PyObject *__pyx_pw_8PyClical_13scalar(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
10876  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_scalar(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
10877  PyObject *__pyx_r = NULL;
10878  __Pyx_RefNannyDeclarations
10879  PyObject *__pyx_t_1 = NULL;
10880  PyObject *__pyx_t_2 = NULL;
10881  PyObject *__pyx_t_3 = NULL;
10882  int __pyx_lineno = 0;
10883  const char *__pyx_filename = NULL;
10884  int __pyx_clineno = 0;
10885  __Pyx_RefNannySetupContext("scalar", 0);
10886 
10887  /* "PyClical.pyx":1353
10888  * 0.0
10889  * """
10890  * return clifford(obj).scalar() # <<<<<<<<<<<<<<
10891  *
10892  * cpdef inline real(obj):
10893  */
10894  __Pyx_XDECREF(__pyx_r);
10895  __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1353; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10896  __Pyx_GOTREF(__pyx_t_2);
10897  __Pyx_INCREF(__pyx_v_obj);
10898  __Pyx_GIVEREF(__pyx_v_obj);
10899  PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_obj);
10900  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1353; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10901  __Pyx_GOTREF(__pyx_t_3);
10902  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
10903  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_scalar); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1353; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10904  __Pyx_GOTREF(__pyx_t_2);
10905  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
10906  __pyx_t_3 = NULL;
10907  if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_2))) {
10908  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
10909  if (likely(__pyx_t_3)) {
10910  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
10911  __Pyx_INCREF(__pyx_t_3);
10912  __Pyx_INCREF(function);
10913  __Pyx_DECREF_SET(__pyx_t_2, function);
10914  }
10915  }
10916  if (__pyx_t_3) {
10917  __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1353; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10918  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
10919  } else {
10920  __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1353; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10921  }
10922  __Pyx_GOTREF(__pyx_t_1);
10923  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
10924  __pyx_r = __pyx_t_1;
10925  __pyx_t_1 = 0;
10926  goto __pyx_L0;
10927 
10928  /* "PyClical.pyx":1344
10929  * return clifford(obj).inv()
10930  *
10931  * cpdef inline scalar(obj): # <<<<<<<<<<<<<<
10932  * """
10933  * Scalar part.
10934  */
10935 
10936  /* function exit code */
10937  __pyx_L1_error:;
10938  __Pyx_XDECREF(__pyx_t_1);
10939  __Pyx_XDECREF(__pyx_t_2);
10940  __Pyx_XDECREF(__pyx_t_3);
10941  __Pyx_AddTraceback("PyClical.scalar", __pyx_clineno, __pyx_lineno, __pyx_filename);
10942  __pyx_r = 0;
10943  __pyx_L0:;
10944  __Pyx_XGIVEREF(__pyx_r);
10945  __Pyx_RefNannyFinishContext();
10946  return __pyx_r;
10947  }
10948 
10949  /* Python wrapper */
10950  static PyObject *__pyx_pw_8PyClical_13scalar(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
10951  static char __pyx_doc_8PyClical_12scalar[] = "\n Scalar part.\n\n >>> scalar(clifford(\"1+{1}+{1,2}\"))\n 1.0\n >>> scalar(clifford(\"{1,2}\"))\n 0.0\n ";
10952  static PyObject *__pyx_pw_8PyClical_13scalar(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
10953  PyObject *__pyx_r = 0;
10954  __Pyx_RefNannyDeclarations
10955  __Pyx_RefNannySetupContext("scalar (wrapper)", 0);
10956  __pyx_r = __pyx_pf_8PyClical_12scalar(__pyx_self, ((PyObject *)__pyx_v_obj));
10957 
10958  /* function exit code */
10959  __Pyx_RefNannyFinishContext();
10960  return __pyx_r;
10961  }
10962 
10963  static PyObject *__pyx_pf_8PyClical_12scalar(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
10964  PyObject *__pyx_r = NULL;
10965  __Pyx_RefNannyDeclarations
10966  PyObject *__pyx_t_1 = NULL;
10967  int __pyx_lineno = 0;
10968  const char *__pyx_filename = NULL;
10969  int __pyx_clineno = 0;
10970  __Pyx_RefNannySetupContext("scalar", 0);
10971  __Pyx_XDECREF(__pyx_r);
10972  __pyx_t_1 = __pyx_f_8PyClical_scalar(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1344; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
10973  __Pyx_GOTREF(__pyx_t_1);
10974  __pyx_r = __pyx_t_1;
10975  __pyx_t_1 = 0;
10976  goto __pyx_L0;
10977 
10978  /* function exit code */
10979  __pyx_L1_error:;
10980  __Pyx_XDECREF(__pyx_t_1);
10981  __Pyx_AddTraceback("PyClical.scalar", __pyx_clineno, __pyx_lineno, __pyx_filename);
10982  __pyx_r = NULL;
10983  __pyx_L0:;
10984  __Pyx_XGIVEREF(__pyx_r);
10985  __Pyx_RefNannyFinishContext();
10986  return __pyx_r;
10987  }
10988 
10989  /* "PyClical.pyx":1355
10990  * return clifford(obj).scalar()
10991  *
10992  * cpdef inline real(obj): # <<<<<<<<<<<<<<
10993  * """
10994  * Real part: synonym for scalar part.
10995  */
10996 
10997  static PyObject *__pyx_pw_8PyClical_15real(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
10998  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_real(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
10999  PyObject *__pyx_r = NULL;
11000  __Pyx_RefNannyDeclarations
11001  PyObject *__pyx_t_1 = NULL;
11002  PyObject *__pyx_t_2 = NULL;
11003  PyObject *__pyx_t_3 = NULL;
11004  int __pyx_lineno = 0;
11005  const char *__pyx_filename = NULL;
11006  int __pyx_clineno = 0;
11007  __Pyx_RefNannySetupContext("real", 0);
11008 
11009  /* "PyClical.pyx":1364
11010  * 0.0
11011  * """
11012  * return clifford(obj).scalar() # <<<<<<<<<<<<<<
11013  *
11014  * cpdef inline imag(obj):
11015  */
11016  __Pyx_XDECREF(__pyx_r);
11017  __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1364; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11018  __Pyx_GOTREF(__pyx_t_2);
11019  __Pyx_INCREF(__pyx_v_obj);
11020  __Pyx_GIVEREF(__pyx_v_obj);
11021  PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_obj);
11022  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1364; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11023  __Pyx_GOTREF(__pyx_t_3);
11024  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
11025  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_scalar); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1364; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11026  __Pyx_GOTREF(__pyx_t_2);
11027  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
11028  __pyx_t_3 = NULL;
11029  if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_2))) {
11030  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
11031  if (likely(__pyx_t_3)) {
11032  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
11033  __Pyx_INCREF(__pyx_t_3);
11034  __Pyx_INCREF(function);
11035  __Pyx_DECREF_SET(__pyx_t_2, function);
11036  }
11037  }
11038  if (__pyx_t_3) {
11039  __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1364; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11040  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
11041  } else {
11042  __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1364; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11043  }
11044  __Pyx_GOTREF(__pyx_t_1);
11045  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
11046  __pyx_r = __pyx_t_1;
11047  __pyx_t_1 = 0;
11048  goto __pyx_L0;
11049 
11050  /* "PyClical.pyx":1355
11051  * return clifford(obj).scalar()
11052  *
11053  * cpdef inline real(obj): # <<<<<<<<<<<<<<
11054  * """
11055  * Real part: synonym for scalar part.
11056  */
11057 
11058  /* function exit code */
11059  __pyx_L1_error:;
11060  __Pyx_XDECREF(__pyx_t_1);
11061  __Pyx_XDECREF(__pyx_t_2);
11062  __Pyx_XDECREF(__pyx_t_3);
11063  __Pyx_AddTraceback("PyClical.real", __pyx_clineno, __pyx_lineno, __pyx_filename);
11064  __pyx_r = 0;
11065  __pyx_L0:;
11066  __Pyx_XGIVEREF(__pyx_r);
11067  __Pyx_RefNannyFinishContext();
11068  return __pyx_r;
11069  }
11070 
11071  /* Python wrapper */
11072  static PyObject *__pyx_pw_8PyClical_15real(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
11073  static char __pyx_doc_8PyClical_14real[] = "\n Real part: synonym for scalar part.\n\n >>> real(clifford(\"1+{1}+{1,2}\"))\n 1.0\n >>> real(clifford(\"{1,2}\"))\n 0.0\n ";
11074  static PyObject *__pyx_pw_8PyClical_15real(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
11075  PyObject *__pyx_r = 0;
11076  __Pyx_RefNannyDeclarations
11077  __Pyx_RefNannySetupContext("real (wrapper)", 0);
11078  __pyx_r = __pyx_pf_8PyClical_14real(__pyx_self, ((PyObject *)__pyx_v_obj));
11079 
11080  /* function exit code */
11081  __Pyx_RefNannyFinishContext();
11082  return __pyx_r;
11083  }
11084 
11085  static PyObject *__pyx_pf_8PyClical_14real(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
11086  PyObject *__pyx_r = NULL;
11087  __Pyx_RefNannyDeclarations
11088  PyObject *__pyx_t_1 = NULL;
11089  int __pyx_lineno = 0;
11090  const char *__pyx_filename = NULL;
11091  int __pyx_clineno = 0;
11092  __Pyx_RefNannySetupContext("real", 0);
11093  __Pyx_XDECREF(__pyx_r);
11094  __pyx_t_1 = __pyx_f_8PyClical_real(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1355; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11095  __Pyx_GOTREF(__pyx_t_1);
11096  __pyx_r = __pyx_t_1;
11097  __pyx_t_1 = 0;
11098  goto __pyx_L0;
11099 
11100  /* function exit code */
11101  __pyx_L1_error:;
11102  __Pyx_XDECREF(__pyx_t_1);
11103  __Pyx_AddTraceback("PyClical.real", __pyx_clineno, __pyx_lineno, __pyx_filename);
11104  __pyx_r = NULL;
11105  __pyx_L0:;
11106  __Pyx_XGIVEREF(__pyx_r);
11107  __Pyx_RefNannyFinishContext();
11108  return __pyx_r;
11109  }
11110 
11111  /* "PyClical.pyx":1366
11112  * return clifford(obj).scalar()
11113  *
11114  * cpdef inline imag(obj): # <<<<<<<<<<<<<<
11115  * """
11116  * Imaginary part: deprecated (always 0).
11117  */
11118 
11119  static PyObject *__pyx_pw_8PyClical_17imag(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
11120  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_imag(CYTHON_UNUSED PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
11121  PyObject *__pyx_r = NULL;
11122  __Pyx_RefNannyDeclarations
11123  __Pyx_RefNannySetupContext("imag", 0);
11124 
11125  /* "PyClical.pyx":1375
11126  * 0.0
11127  * """
11128  * return 0.0 # <<<<<<<<<<<<<<
11129  *
11130  * cpdef inline pure(obj):
11131  */
11132  __Pyx_XDECREF(__pyx_r);
11133  __Pyx_INCREF(__pyx_float_0_0);
11134  __pyx_r = __pyx_float_0_0;
11135  goto __pyx_L0;
11136 
11137  /* "PyClical.pyx":1366
11138  * return clifford(obj).scalar()
11139  *
11140  * cpdef inline imag(obj): # <<<<<<<<<<<<<<
11141  * """
11142  * Imaginary part: deprecated (always 0).
11143  */
11144 
11145  /* function exit code */
11146  __pyx_L0:;
11147  __Pyx_XGIVEREF(__pyx_r);
11148  __Pyx_RefNannyFinishContext();
11149  return __pyx_r;
11150  }
11151 
11152  /* Python wrapper */
11153  static PyObject *__pyx_pw_8PyClical_17imag(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
11154  static char __pyx_doc_8PyClical_16imag[] = "\n Imaginary part: deprecated (always 0).\n\n >>> imag(clifford(\"1+{1}+{1,2}\"))\n 0.0\n >>> imag(clifford(\"{1,2}\"))\n 0.0\n ";
11155  static PyObject *__pyx_pw_8PyClical_17imag(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
11156  PyObject *__pyx_r = 0;
11157  __Pyx_RefNannyDeclarations
11158  __Pyx_RefNannySetupContext("imag (wrapper)", 0);
11159  __pyx_r = __pyx_pf_8PyClical_16imag(__pyx_self, ((PyObject *)__pyx_v_obj));
11160 
11161  /* function exit code */
11162  __Pyx_RefNannyFinishContext();
11163  return __pyx_r;
11164  }
11165 
11166  static PyObject *__pyx_pf_8PyClical_16imag(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
11167  PyObject *__pyx_r = NULL;
11168  __Pyx_RefNannyDeclarations
11169  PyObject *__pyx_t_1 = NULL;
11170  int __pyx_lineno = 0;
11171  const char *__pyx_filename = NULL;
11172  int __pyx_clineno = 0;
11173  __Pyx_RefNannySetupContext("imag", 0);
11174  __Pyx_XDECREF(__pyx_r);
11175  __pyx_t_1 = __pyx_f_8PyClical_imag(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1366; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11176  __Pyx_GOTREF(__pyx_t_1);
11177  __pyx_r = __pyx_t_1;
11178  __pyx_t_1 = 0;
11179  goto __pyx_L0;
11180 
11181  /* function exit code */
11182  __pyx_L1_error:;
11183  __Pyx_XDECREF(__pyx_t_1);
11184  __Pyx_AddTraceback("PyClical.imag", __pyx_clineno, __pyx_lineno, __pyx_filename);
11185  __pyx_r = NULL;
11186  __pyx_L0:;
11187  __Pyx_XGIVEREF(__pyx_r);
11188  __Pyx_RefNannyFinishContext();
11189  return __pyx_r;
11190  }
11191 
11192  /* "PyClical.pyx":1377
11193  * return 0.0
11194  *
11195  * cpdef inline pure(obj): # <<<<<<<<<<<<<<
11196  * """
11197  * Pure part
11198  */
11199 
11200  static PyObject *__pyx_pw_8PyClical_19pure(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
11201  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_pure(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
11202  PyObject *__pyx_r = NULL;
11203  __Pyx_RefNannyDeclarations
11204  PyObject *__pyx_t_1 = NULL;
11205  PyObject *__pyx_t_2 = NULL;
11206  PyObject *__pyx_t_3 = NULL;
11207  int __pyx_lineno = 0;
11208  const char *__pyx_filename = NULL;
11209  int __pyx_clineno = 0;
11210  __Pyx_RefNannySetupContext("pure", 0);
11211 
11212  /* "PyClical.pyx":1386
11213  * {1,2}
11214  * """
11215  * return clifford(obj).pure() # <<<<<<<<<<<<<<
11216  *
11217  * cpdef inline even(obj):
11218  */
11219  __Pyx_XDECREF(__pyx_r);
11220  __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1386; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11221  __Pyx_GOTREF(__pyx_t_2);
11222  __Pyx_INCREF(__pyx_v_obj);
11223  __Pyx_GIVEREF(__pyx_v_obj);
11224  PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_obj);
11225  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1386; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11226  __Pyx_GOTREF(__pyx_t_3);
11227  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
11228  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_pure); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1386; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11229  __Pyx_GOTREF(__pyx_t_2);
11230  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
11231  __pyx_t_3 = NULL;
11232  if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_2))) {
11233  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
11234  if (likely(__pyx_t_3)) {
11235  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
11236  __Pyx_INCREF(__pyx_t_3);
11237  __Pyx_INCREF(function);
11238  __Pyx_DECREF_SET(__pyx_t_2, function);
11239  }
11240  }
11241  if (__pyx_t_3) {
11242  __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1386; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11243  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
11244  } else {
11245  __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1386; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11246  }
11247  __Pyx_GOTREF(__pyx_t_1);
11248  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
11249  __pyx_r = __pyx_t_1;
11250  __pyx_t_1 = 0;
11251  goto __pyx_L0;
11252 
11253  /* "PyClical.pyx":1377
11254  * return 0.0
11255  *
11256  * cpdef inline pure(obj): # <<<<<<<<<<<<<<
11257  * """
11258  * Pure part
11259  */
11260 
11261  /* function exit code */
11262  __pyx_L1_error:;
11263  __Pyx_XDECREF(__pyx_t_1);
11264  __Pyx_XDECREF(__pyx_t_2);
11265  __Pyx_XDECREF(__pyx_t_3);
11266  __Pyx_AddTraceback("PyClical.pure", __pyx_clineno, __pyx_lineno, __pyx_filename);
11267  __pyx_r = 0;
11268  __pyx_L0:;
11269  __Pyx_XGIVEREF(__pyx_r);
11270  __Pyx_RefNannyFinishContext();
11271  return __pyx_r;
11272  }
11273 
11274  /* Python wrapper */
11275  static PyObject *__pyx_pw_8PyClical_19pure(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
11276  static char __pyx_doc_8PyClical_18pure[] = "\n Pure part\n\n >>> print pure(clifford(\"1+{1}+{1,2}\"))\n {1}+{1,2}\n >>> print pure(clifford(\"{1,2}\"))\n {1,2}\n ";
11277  static PyObject *__pyx_pw_8PyClical_19pure(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
11278  PyObject *__pyx_r = 0;
11279  __Pyx_RefNannyDeclarations
11280  __Pyx_RefNannySetupContext("pure (wrapper)", 0);
11281  __pyx_r = __pyx_pf_8PyClical_18pure(__pyx_self, ((PyObject *)__pyx_v_obj));
11282 
11283  /* function exit code */
11284  __Pyx_RefNannyFinishContext();
11285  return __pyx_r;
11286  }
11287 
11288  static PyObject *__pyx_pf_8PyClical_18pure(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
11289  PyObject *__pyx_r = NULL;
11290  __Pyx_RefNannyDeclarations
11291  PyObject *__pyx_t_1 = NULL;
11292  int __pyx_lineno = 0;
11293  const char *__pyx_filename = NULL;
11294  int __pyx_clineno = 0;
11295  __Pyx_RefNannySetupContext("pure", 0);
11296  __Pyx_XDECREF(__pyx_r);
11297  __pyx_t_1 = __pyx_f_8PyClical_pure(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1377; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11298  __Pyx_GOTREF(__pyx_t_1);
11299  __pyx_r = __pyx_t_1;
11300  __pyx_t_1 = 0;
11301  goto __pyx_L0;
11302 
11303  /* function exit code */
11304  __pyx_L1_error:;
11305  __Pyx_XDECREF(__pyx_t_1);
11306  __Pyx_AddTraceback("PyClical.pure", __pyx_clineno, __pyx_lineno, __pyx_filename);
11307  __pyx_r = NULL;
11308  __pyx_L0:;
11309  __Pyx_XGIVEREF(__pyx_r);
11310  __Pyx_RefNannyFinishContext();
11311  return __pyx_r;
11312  }
11313 
11314  /* "PyClical.pyx":1388
11315  * return clifford(obj).pure()
11316  *
11317  * cpdef inline even(obj): # <<<<<<<<<<<<<<
11318  * """
11319  * Even part of multivector, sum of even grade terms.
11320  */
11321 
11322  static PyObject *__pyx_pw_8PyClical_21even(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
11323  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_even(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
11324  PyObject *__pyx_r = NULL;
11325  __Pyx_RefNannyDeclarations
11326  PyObject *__pyx_t_1 = NULL;
11327  PyObject *__pyx_t_2 = NULL;
11328  PyObject *__pyx_t_3 = NULL;
11329  int __pyx_lineno = 0;
11330  const char *__pyx_filename = NULL;
11331  int __pyx_clineno = 0;
11332  __Pyx_RefNannySetupContext("even", 0);
11333 
11334  /* "PyClical.pyx":1395
11335  * 1+{1,2}
11336  * """
11337  * return clifford(obj).even() # <<<<<<<<<<<<<<
11338  *
11339  * cpdef inline odd(obj):
11340  */
11341  __Pyx_XDECREF(__pyx_r);
11342  __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1395; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11343  __Pyx_GOTREF(__pyx_t_2);
11344  __Pyx_INCREF(__pyx_v_obj);
11345  __Pyx_GIVEREF(__pyx_v_obj);
11346  PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_obj);
11347  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1395; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11348  __Pyx_GOTREF(__pyx_t_3);
11349  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
11350  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_even); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1395; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11351  __Pyx_GOTREF(__pyx_t_2);
11352  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
11353  __pyx_t_3 = NULL;
11354  if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_2))) {
11355  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
11356  if (likely(__pyx_t_3)) {
11357  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
11358  __Pyx_INCREF(__pyx_t_3);
11359  __Pyx_INCREF(function);
11360  __Pyx_DECREF_SET(__pyx_t_2, function);
11361  }
11362  }
11363  if (__pyx_t_3) {
11364  __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1395; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11365  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
11366  } else {
11367  __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1395; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11368  }
11369  __Pyx_GOTREF(__pyx_t_1);
11370  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
11371  __pyx_r = __pyx_t_1;
11372  __pyx_t_1 = 0;
11373  goto __pyx_L0;
11374 
11375  /* "PyClical.pyx":1388
11376  * return clifford(obj).pure()
11377  *
11378  * cpdef inline even(obj): # <<<<<<<<<<<<<<
11379  * """
11380  * Even part of multivector, sum of even grade terms.
11381  */
11382 
11383  /* function exit code */
11384  __pyx_L1_error:;
11385  __Pyx_XDECREF(__pyx_t_1);
11386  __Pyx_XDECREF(__pyx_t_2);
11387  __Pyx_XDECREF(__pyx_t_3);
11388  __Pyx_AddTraceback("PyClical.even", __pyx_clineno, __pyx_lineno, __pyx_filename);
11389  __pyx_r = 0;
11390  __pyx_L0:;
11391  __Pyx_XGIVEREF(__pyx_r);
11392  __Pyx_RefNannyFinishContext();
11393  return __pyx_r;
11394  }
11395 
11396  /* Python wrapper */
11397  static PyObject *__pyx_pw_8PyClical_21even(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
11398  static char __pyx_doc_8PyClical_20even[] = "\n Even part of multivector, sum of even grade terms.\n\n >>> print even(clifford(\"1+{1}+{1,2}\"))\n 1+{1,2}\n ";
11399  static PyObject *__pyx_pw_8PyClical_21even(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
11400  PyObject *__pyx_r = 0;
11401  __Pyx_RefNannyDeclarations
11402  __Pyx_RefNannySetupContext("even (wrapper)", 0);
11403  __pyx_r = __pyx_pf_8PyClical_20even(__pyx_self, ((PyObject *)__pyx_v_obj));
11404 
11405  /* function exit code */
11406  __Pyx_RefNannyFinishContext();
11407  return __pyx_r;
11408  }
11409 
11410  static PyObject *__pyx_pf_8PyClical_20even(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
11411  PyObject *__pyx_r = NULL;
11412  __Pyx_RefNannyDeclarations
11413  PyObject *__pyx_t_1 = NULL;
11414  int __pyx_lineno = 0;
11415  const char *__pyx_filename = NULL;
11416  int __pyx_clineno = 0;
11417  __Pyx_RefNannySetupContext("even", 0);
11418  __Pyx_XDECREF(__pyx_r);
11419  __pyx_t_1 = __pyx_f_8PyClical_even(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1388; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11420  __Pyx_GOTREF(__pyx_t_1);
11421  __pyx_r = __pyx_t_1;
11422  __pyx_t_1 = 0;
11423  goto __pyx_L0;
11424 
11425  /* function exit code */
11426  __pyx_L1_error:;
11427  __Pyx_XDECREF(__pyx_t_1);
11428  __Pyx_AddTraceback("PyClical.even", __pyx_clineno, __pyx_lineno, __pyx_filename);
11429  __pyx_r = NULL;
11430  __pyx_L0:;
11431  __Pyx_XGIVEREF(__pyx_r);
11432  __Pyx_RefNannyFinishContext();
11433  return __pyx_r;
11434  }
11435 
11436  /* "PyClical.pyx":1397
11437  * return clifford(obj).even()
11438  *
11439  * cpdef inline odd(obj): # <<<<<<<<<<<<<<
11440  * """
11441  * Odd part of multivector, sum of odd grade terms.
11442  */
11443 
11444  static PyObject *__pyx_pw_8PyClical_23odd(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
11445  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_odd(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
11446  PyObject *__pyx_r = NULL;
11447  __Pyx_RefNannyDeclarations
11448  PyObject *__pyx_t_1 = NULL;
11449  PyObject *__pyx_t_2 = NULL;
11450  PyObject *__pyx_t_3 = NULL;
11451  int __pyx_lineno = 0;
11452  const char *__pyx_filename = NULL;
11453  int __pyx_clineno = 0;
11454  __Pyx_RefNannySetupContext("odd", 0);
11455 
11456  /* "PyClical.pyx":1404
11457  * {1}
11458  * """
11459  * return clifford(obj).odd() # <<<<<<<<<<<<<<
11460  *
11461  * cpdef inline involute(obj):
11462  */
11463  __Pyx_XDECREF(__pyx_r);
11464  __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1404; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11465  __Pyx_GOTREF(__pyx_t_2);
11466  __Pyx_INCREF(__pyx_v_obj);
11467  __Pyx_GIVEREF(__pyx_v_obj);
11468  PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_obj);
11469  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1404; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11470  __Pyx_GOTREF(__pyx_t_3);
11471  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
11472  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_odd); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1404; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11473  __Pyx_GOTREF(__pyx_t_2);
11474  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
11475  __pyx_t_3 = NULL;
11476  if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_2))) {
11477  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
11478  if (likely(__pyx_t_3)) {
11479  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
11480  __Pyx_INCREF(__pyx_t_3);
11481  __Pyx_INCREF(function);
11482  __Pyx_DECREF_SET(__pyx_t_2, function);
11483  }
11484  }
11485  if (__pyx_t_3) {
11486  __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1404; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11487  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
11488  } else {
11489  __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1404; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11490  }
11491  __Pyx_GOTREF(__pyx_t_1);
11492  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
11493  __pyx_r = __pyx_t_1;
11494  __pyx_t_1 = 0;
11495  goto __pyx_L0;
11496 
11497  /* "PyClical.pyx":1397
11498  * return clifford(obj).even()
11499  *
11500  * cpdef inline odd(obj): # <<<<<<<<<<<<<<
11501  * """
11502  * Odd part of multivector, sum of odd grade terms.
11503  */
11504 
11505  /* function exit code */
11506  __pyx_L1_error:;
11507  __Pyx_XDECREF(__pyx_t_1);
11508  __Pyx_XDECREF(__pyx_t_2);
11509  __Pyx_XDECREF(__pyx_t_3);
11510  __Pyx_AddTraceback("PyClical.odd", __pyx_clineno, __pyx_lineno, __pyx_filename);
11511  __pyx_r = 0;
11512  __pyx_L0:;
11513  __Pyx_XGIVEREF(__pyx_r);
11514  __Pyx_RefNannyFinishContext();
11515  return __pyx_r;
11516  }
11517 
11518  /* Python wrapper */
11519  static PyObject *__pyx_pw_8PyClical_23odd(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
11520  static char __pyx_doc_8PyClical_22odd[] = "\n Odd part of multivector, sum of odd grade terms.\n\n >>> print odd(clifford(\"1+{1}+{1,2}\"))\n {1}\n ";
11521  static PyObject *__pyx_pw_8PyClical_23odd(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
11522  PyObject *__pyx_r = 0;
11523  __Pyx_RefNannyDeclarations
11524  __Pyx_RefNannySetupContext("odd (wrapper)", 0);
11525  __pyx_r = __pyx_pf_8PyClical_22odd(__pyx_self, ((PyObject *)__pyx_v_obj));
11526 
11527  /* function exit code */
11528  __Pyx_RefNannyFinishContext();
11529  return __pyx_r;
11530  }
11531 
11532  static PyObject *__pyx_pf_8PyClical_22odd(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
11533  PyObject *__pyx_r = NULL;
11534  __Pyx_RefNannyDeclarations
11535  PyObject *__pyx_t_1 = NULL;
11536  int __pyx_lineno = 0;
11537  const char *__pyx_filename = NULL;
11538  int __pyx_clineno = 0;
11539  __Pyx_RefNannySetupContext("odd", 0);
11540  __Pyx_XDECREF(__pyx_r);
11541  __pyx_t_1 = __pyx_f_8PyClical_odd(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1397; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11542  __Pyx_GOTREF(__pyx_t_1);
11543  __pyx_r = __pyx_t_1;
11544  __pyx_t_1 = 0;
11545  goto __pyx_L0;
11546 
11547  /* function exit code */
11548  __pyx_L1_error:;
11549  __Pyx_XDECREF(__pyx_t_1);
11550  __Pyx_AddTraceback("PyClical.odd", __pyx_clineno, __pyx_lineno, __pyx_filename);
11551  __pyx_r = NULL;
11552  __pyx_L0:;
11553  __Pyx_XGIVEREF(__pyx_r);
11554  __Pyx_RefNannyFinishContext();
11555  return __pyx_r;
11556  }
11557 
11558  /* "PyClical.pyx":1406
11559  * return clifford(obj).odd()
11560  *
11561  * cpdef inline involute(obj): # <<<<<<<<<<<<<<
11562  * """
11563  * Main involution, each {i} is replaced by -{i} in each term, eg. {1}*{2} -> (-{2})*(-{1})
11564  */
11565 
11566  static PyObject *__pyx_pw_8PyClical_25involute(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
11567  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_involute(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
11568  PyObject *__pyx_r = NULL;
11569  __Pyx_RefNannyDeclarations
11570  PyObject *__pyx_t_1 = NULL;
11571  PyObject *__pyx_t_2 = NULL;
11572  PyObject *__pyx_t_3 = NULL;
11573  int __pyx_lineno = 0;
11574  const char *__pyx_filename = NULL;
11575  int __pyx_clineno = 0;
11576  __Pyx_RefNannySetupContext("involute", 0);
11577 
11578  /* "PyClical.pyx":1419
11579  * 1-{1}+{1,2}
11580  * """
11581  * return clifford(obj).involute() # <<<<<<<<<<<<<<
11582  *
11583  * cpdef inline reverse(obj):
11584  */
11585  __Pyx_XDECREF(__pyx_r);
11586  __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1419; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11587  __Pyx_GOTREF(__pyx_t_2);
11588  __Pyx_INCREF(__pyx_v_obj);
11589  __Pyx_GIVEREF(__pyx_v_obj);
11590  PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_obj);
11591  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1419; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11592  __Pyx_GOTREF(__pyx_t_3);
11593  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
11594  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_involute); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1419; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11595  __Pyx_GOTREF(__pyx_t_2);
11596  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
11597  __pyx_t_3 = NULL;
11598  if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_2))) {
11599  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
11600  if (likely(__pyx_t_3)) {
11601  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
11602  __Pyx_INCREF(__pyx_t_3);
11603  __Pyx_INCREF(function);
11604  __Pyx_DECREF_SET(__pyx_t_2, function);
11605  }
11606  }
11607  if (__pyx_t_3) {
11608  __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1419; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11609  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
11610  } else {
11611  __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1419; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11612  }
11613  __Pyx_GOTREF(__pyx_t_1);
11614  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
11615  __pyx_r = __pyx_t_1;
11616  __pyx_t_1 = 0;
11617  goto __pyx_L0;
11618 
11619  /* "PyClical.pyx":1406
11620  * return clifford(obj).odd()
11621  *
11622  * cpdef inline involute(obj): # <<<<<<<<<<<<<<
11623  * """
11624  * Main involution, each {i} is replaced by -{i} in each term, eg. {1}*{2} -> (-{2})*(-{1})
11625  */
11626 
11627  /* function exit code */
11628  __pyx_L1_error:;
11629  __Pyx_XDECREF(__pyx_t_1);
11630  __Pyx_XDECREF(__pyx_t_2);
11631  __Pyx_XDECREF(__pyx_t_3);
11632  __Pyx_AddTraceback("PyClical.involute", __pyx_clineno, __pyx_lineno, __pyx_filename);
11633  __pyx_r = 0;
11634  __pyx_L0:;
11635  __Pyx_XGIVEREF(__pyx_r);
11636  __Pyx_RefNannyFinishContext();
11637  return __pyx_r;
11638  }
11639 
11640  /* Python wrapper */
11641  static PyObject *__pyx_pw_8PyClical_25involute(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
11642  static char __pyx_doc_8PyClical_24involute[] = "\n Main involution, each {i} is replaced by -{i} in each term, eg. {1}*{2} -> (-{2})*(-{1})\n\n >>> print involute(clifford(\"{1}\"))\n -{1}\n >>> print involute(clifford(\"{2}\") * clifford(\"{1}\"))\n -{1,2}\n >>> print involute(clifford(\"{1}\") * clifford(\"{2}\"))\n {1,2}\n >>> print involute(clifford(\"1+{1}+{1,2}\"))\n 1-{1}+{1,2}\n ";
11643  static PyObject *__pyx_pw_8PyClical_25involute(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
11644  PyObject *__pyx_r = 0;
11645  __Pyx_RefNannyDeclarations
11646  __Pyx_RefNannySetupContext("involute (wrapper)", 0);
11647  __pyx_r = __pyx_pf_8PyClical_24involute(__pyx_self, ((PyObject *)__pyx_v_obj));
11648 
11649  /* function exit code */
11650  __Pyx_RefNannyFinishContext();
11651  return __pyx_r;
11652  }
11653 
11654  static PyObject *__pyx_pf_8PyClical_24involute(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
11655  PyObject *__pyx_r = NULL;
11656  __Pyx_RefNannyDeclarations
11657  PyObject *__pyx_t_1 = NULL;
11658  int __pyx_lineno = 0;
11659  const char *__pyx_filename = NULL;
11660  int __pyx_clineno = 0;
11661  __Pyx_RefNannySetupContext("involute", 0);
11662  __Pyx_XDECREF(__pyx_r);
11663  __pyx_t_1 = __pyx_f_8PyClical_involute(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1406; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11664  __Pyx_GOTREF(__pyx_t_1);
11665  __pyx_r = __pyx_t_1;
11666  __pyx_t_1 = 0;
11667  goto __pyx_L0;
11668 
11669  /* function exit code */
11670  __pyx_L1_error:;
11671  __Pyx_XDECREF(__pyx_t_1);
11672  __Pyx_AddTraceback("PyClical.involute", __pyx_clineno, __pyx_lineno, __pyx_filename);
11673  __pyx_r = NULL;
11674  __pyx_L0:;
11675  __Pyx_XGIVEREF(__pyx_r);
11676  __Pyx_RefNannyFinishContext();
11677  return __pyx_r;
11678  }
11679 
11680  /* "PyClical.pyx":1421
11681  * return clifford(obj).involute()
11682  *
11683  * cpdef inline reverse(obj): # <<<<<<<<<<<<<<
11684  * """
11685  * Reversion, eg. {1}*{2} -> {2}*{1}
11686  */
11687 
11688  static PyObject *__pyx_pw_8PyClical_27reverse(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
11689  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_reverse(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
11690  PyObject *__pyx_r = NULL;
11691  __Pyx_RefNannyDeclarations
11692  PyObject *__pyx_t_1 = NULL;
11693  PyObject *__pyx_t_2 = NULL;
11694  PyObject *__pyx_t_3 = NULL;
11695  int __pyx_lineno = 0;
11696  const char *__pyx_filename = NULL;
11697  int __pyx_clineno = 0;
11698  __Pyx_RefNannySetupContext("reverse", 0);
11699 
11700  /* "PyClical.pyx":1434
11701  * 1+{1}-{1,2}
11702  * """
11703  * return clifford(obj).reverse() # <<<<<<<<<<<<<<
11704  *
11705  * cpdef inline conj(obj):
11706  */
11707  __Pyx_XDECREF(__pyx_r);
11708  __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1434; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11709  __Pyx_GOTREF(__pyx_t_2);
11710  __Pyx_INCREF(__pyx_v_obj);
11711  __Pyx_GIVEREF(__pyx_v_obj);
11712  PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_obj);
11713  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1434; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11714  __Pyx_GOTREF(__pyx_t_3);
11715  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
11716  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_reverse); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1434; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11717  __Pyx_GOTREF(__pyx_t_2);
11718  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
11719  __pyx_t_3 = NULL;
11720  if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_2))) {
11721  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
11722  if (likely(__pyx_t_3)) {
11723  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
11724  __Pyx_INCREF(__pyx_t_3);
11725  __Pyx_INCREF(function);
11726  __Pyx_DECREF_SET(__pyx_t_2, function);
11727  }
11728  }
11729  if (__pyx_t_3) {
11730  __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1434; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11731  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
11732  } else {
11733  __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1434; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11734  }
11735  __Pyx_GOTREF(__pyx_t_1);
11736  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
11737  __pyx_r = __pyx_t_1;
11738  __pyx_t_1 = 0;
11739  goto __pyx_L0;
11740 
11741  /* "PyClical.pyx":1421
11742  * return clifford(obj).involute()
11743  *
11744  * cpdef inline reverse(obj): # <<<<<<<<<<<<<<
11745  * """
11746  * Reversion, eg. {1}*{2} -> {2}*{1}
11747  */
11748 
11749  /* function exit code */
11750  __pyx_L1_error:;
11751  __Pyx_XDECREF(__pyx_t_1);
11752  __Pyx_XDECREF(__pyx_t_2);
11753  __Pyx_XDECREF(__pyx_t_3);
11754  __Pyx_AddTraceback("PyClical.reverse", __pyx_clineno, __pyx_lineno, __pyx_filename);
11755  __pyx_r = 0;
11756  __pyx_L0:;
11757  __Pyx_XGIVEREF(__pyx_r);
11758  __Pyx_RefNannyFinishContext();
11759  return __pyx_r;
11760  }
11761 
11762  /* Python wrapper */
11763  static PyObject *__pyx_pw_8PyClical_27reverse(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
11764  static char __pyx_doc_8PyClical_26reverse[] = "\n Reversion, eg. {1}*{2} -> {2}*{1}\n\n >>> print reverse(clifford(\"{1}\"))\n {1}\n >>> print reverse(clifford(\"{2}\") * clifford(\"{1}\"))\n {1,2}\n >>> print reverse(clifford(\"{1}\") * clifford(\"{2}\"))\n -{1,2}\n >>> print reverse(clifford(\"1+{1}+{1,2}\"))\n 1+{1}-{1,2}\n ";
11765  static PyObject *__pyx_pw_8PyClical_27reverse(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
11766  PyObject *__pyx_r = 0;
11767  __Pyx_RefNannyDeclarations
11768  __Pyx_RefNannySetupContext("reverse (wrapper)", 0);
11769  __pyx_r = __pyx_pf_8PyClical_26reverse(__pyx_self, ((PyObject *)__pyx_v_obj));
11770 
11771  /* function exit code */
11772  __Pyx_RefNannyFinishContext();
11773  return __pyx_r;
11774  }
11775 
11776  static PyObject *__pyx_pf_8PyClical_26reverse(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
11777  PyObject *__pyx_r = NULL;
11778  __Pyx_RefNannyDeclarations
11779  PyObject *__pyx_t_1 = NULL;
11780  int __pyx_lineno = 0;
11781  const char *__pyx_filename = NULL;
11782  int __pyx_clineno = 0;
11783  __Pyx_RefNannySetupContext("reverse", 0);
11784  __Pyx_XDECREF(__pyx_r);
11785  __pyx_t_1 = __pyx_f_8PyClical_reverse(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1421; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11786  __Pyx_GOTREF(__pyx_t_1);
11787  __pyx_r = __pyx_t_1;
11788  __pyx_t_1 = 0;
11789  goto __pyx_L0;
11790 
11791  /* function exit code */
11792  __pyx_L1_error:;
11793  __Pyx_XDECREF(__pyx_t_1);
11794  __Pyx_AddTraceback("PyClical.reverse", __pyx_clineno, __pyx_lineno, __pyx_filename);
11795  __pyx_r = NULL;
11796  __pyx_L0:;
11797  __Pyx_XGIVEREF(__pyx_r);
11798  __Pyx_RefNannyFinishContext();
11799  return __pyx_r;
11800  }
11801 
11802  /* "PyClical.pyx":1436
11803  * return clifford(obj).reverse()
11804  *
11805  * cpdef inline conj(obj): # <<<<<<<<<<<<<<
11806  * """
11807  * Conjugation, reverse o involute == involute o reverse.
11808  */
11809 
11810  static PyObject *__pyx_pw_8PyClical_29conj(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
11811  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_conj(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
11812  PyObject *__pyx_r = NULL;
11813  __Pyx_RefNannyDeclarations
11814  PyObject *__pyx_t_1 = NULL;
11815  PyObject *__pyx_t_2 = NULL;
11816  PyObject *__pyx_t_3 = NULL;
11817  int __pyx_lineno = 0;
11818  const char *__pyx_filename = NULL;
11819  int __pyx_clineno = 0;
11820  __Pyx_RefNannySetupContext("conj", 0);
11821 
11822  /* "PyClical.pyx":1449
11823  * 1-{1}-{1,2}
11824  * """
11825  * return clifford(obj).conj() # <<<<<<<<<<<<<<
11826  *
11827  * cpdef inline quad(obj):
11828  */
11829  __Pyx_XDECREF(__pyx_r);
11830  __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1449; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11831  __Pyx_GOTREF(__pyx_t_2);
11832  __Pyx_INCREF(__pyx_v_obj);
11833  __Pyx_GIVEREF(__pyx_v_obj);
11834  PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_obj);
11835  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1449; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11836  __Pyx_GOTREF(__pyx_t_3);
11837  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
11838  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_conj); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1449; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11839  __Pyx_GOTREF(__pyx_t_2);
11840  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
11841  __pyx_t_3 = NULL;
11842  if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_2))) {
11843  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
11844  if (likely(__pyx_t_3)) {
11845  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
11846  __Pyx_INCREF(__pyx_t_3);
11847  __Pyx_INCREF(function);
11848  __Pyx_DECREF_SET(__pyx_t_2, function);
11849  }
11850  }
11851  if (__pyx_t_3) {
11852  __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1449; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11853  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
11854  } else {
11855  __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1449; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11856  }
11857  __Pyx_GOTREF(__pyx_t_1);
11858  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
11859  __pyx_r = __pyx_t_1;
11860  __pyx_t_1 = 0;
11861  goto __pyx_L0;
11862 
11863  /* "PyClical.pyx":1436
11864  * return clifford(obj).reverse()
11865  *
11866  * cpdef inline conj(obj): # <<<<<<<<<<<<<<
11867  * """
11868  * Conjugation, reverse o involute == involute o reverse.
11869  */
11870 
11871  /* function exit code */
11872  __pyx_L1_error:;
11873  __Pyx_XDECREF(__pyx_t_1);
11874  __Pyx_XDECREF(__pyx_t_2);
11875  __Pyx_XDECREF(__pyx_t_3);
11876  __Pyx_AddTraceback("PyClical.conj", __pyx_clineno, __pyx_lineno, __pyx_filename);
11877  __pyx_r = 0;
11878  __pyx_L0:;
11879  __Pyx_XGIVEREF(__pyx_r);
11880  __Pyx_RefNannyFinishContext();
11881  return __pyx_r;
11882  }
11883 
11884  /* Python wrapper */
11885  static PyObject *__pyx_pw_8PyClical_29conj(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
11886  static char __pyx_doc_8PyClical_28conj[] = "\n Conjugation, reverse o involute == involute o reverse.\n\n >>> print conj(clifford(\"{1}\"))\n -{1}\n >>> print conj(clifford(\"{2}\") * clifford(\"{1}\"))\n {1,2}\n >>> print conj(clifford(\"{1}\") * clifford(\"{2}\"))\n -{1,2}\n >>> print conj(clifford(\"1+{1}+{1,2}\"))\n 1-{1}-{1,2}\n ";
11887  static PyObject *__pyx_pw_8PyClical_29conj(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
11888  PyObject *__pyx_r = 0;
11889  __Pyx_RefNannyDeclarations
11890  __Pyx_RefNannySetupContext("conj (wrapper)", 0);
11891  __pyx_r = __pyx_pf_8PyClical_28conj(__pyx_self, ((PyObject *)__pyx_v_obj));
11892 
11893  /* function exit code */
11894  __Pyx_RefNannyFinishContext();
11895  return __pyx_r;
11896  }
11897 
11898  static PyObject *__pyx_pf_8PyClical_28conj(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
11899  PyObject *__pyx_r = NULL;
11900  __Pyx_RefNannyDeclarations
11901  PyObject *__pyx_t_1 = NULL;
11902  int __pyx_lineno = 0;
11903  const char *__pyx_filename = NULL;
11904  int __pyx_clineno = 0;
11905  __Pyx_RefNannySetupContext("conj", 0);
11906  __Pyx_XDECREF(__pyx_r);
11907  __pyx_t_1 = __pyx_f_8PyClical_conj(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1436; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11908  __Pyx_GOTREF(__pyx_t_1);
11909  __pyx_r = __pyx_t_1;
11910  __pyx_t_1 = 0;
11911  goto __pyx_L0;
11912 
11913  /* function exit code */
11914  __pyx_L1_error:;
11915  __Pyx_XDECREF(__pyx_t_1);
11916  __Pyx_AddTraceback("PyClical.conj", __pyx_clineno, __pyx_lineno, __pyx_filename);
11917  __pyx_r = NULL;
11918  __pyx_L0:;
11919  __Pyx_XGIVEREF(__pyx_r);
11920  __Pyx_RefNannyFinishContext();
11921  return __pyx_r;
11922  }
11923 
11924  /* "PyClical.pyx":1451
11925  * return clifford(obj).conj()
11926  *
11927  * cpdef inline quad(obj): # <<<<<<<<<<<<<<
11928  * """
11929  * Quadratic form == (rev(x)*x)(0).
11930  */
11931 
11932  static PyObject *__pyx_pw_8PyClical_31quad(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
11933  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_quad(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
11934  PyObject *__pyx_r = NULL;
11935  __Pyx_RefNannyDeclarations
11936  PyObject *__pyx_t_1 = NULL;
11937  PyObject *__pyx_t_2 = NULL;
11938  PyObject *__pyx_t_3 = NULL;
11939  int __pyx_lineno = 0;
11940  const char *__pyx_filename = NULL;
11941  int __pyx_clineno = 0;
11942  __Pyx_RefNannySetupContext("quad", 0);
11943 
11944  /* "PyClical.pyx":1460
11945  * 2.0
11946  * """
11947  * return clifford(obj).quad() # <<<<<<<<<<<<<<
11948  *
11949  * cpdef inline norm(obj):
11950  */
11951  __Pyx_XDECREF(__pyx_r);
11952  __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1460; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11953  __Pyx_GOTREF(__pyx_t_2);
11954  __Pyx_INCREF(__pyx_v_obj);
11955  __Pyx_GIVEREF(__pyx_v_obj);
11956  PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_obj);
11957  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1460; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11958  __Pyx_GOTREF(__pyx_t_3);
11959  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
11960  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_quad); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1460; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11961  __Pyx_GOTREF(__pyx_t_2);
11962  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
11963  __pyx_t_3 = NULL;
11964  if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_2))) {
11965  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
11966  if (likely(__pyx_t_3)) {
11967  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
11968  __Pyx_INCREF(__pyx_t_3);
11969  __Pyx_INCREF(function);
11970  __Pyx_DECREF_SET(__pyx_t_2, function);
11971  }
11972  }
11973  if (__pyx_t_3) {
11974  __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1460; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11975  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
11976  } else {
11977  __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1460; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
11978  }
11979  __Pyx_GOTREF(__pyx_t_1);
11980  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
11981  __pyx_r = __pyx_t_1;
11982  __pyx_t_1 = 0;
11983  goto __pyx_L0;
11984 
11985  /* "PyClical.pyx":1451
11986  * return clifford(obj).conj()
11987  *
11988  * cpdef inline quad(obj): # <<<<<<<<<<<<<<
11989  * """
11990  * Quadratic form == (rev(x)*x)(0).
11991  */
11992 
11993  /* function exit code */
11994  __pyx_L1_error:;
11995  __Pyx_XDECREF(__pyx_t_1);
11996  __Pyx_XDECREF(__pyx_t_2);
11997  __Pyx_XDECREF(__pyx_t_3);
11998  __Pyx_AddTraceback("PyClical.quad", __pyx_clineno, __pyx_lineno, __pyx_filename);
11999  __pyx_r = 0;
12000  __pyx_L0:;
12001  __Pyx_XGIVEREF(__pyx_r);
12002  __Pyx_RefNannyFinishContext();
12003  return __pyx_r;
12004  }
12005 
12006  /* Python wrapper */
12007  static PyObject *__pyx_pw_8PyClical_31quad(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
12008  static char __pyx_doc_8PyClical_30quad[] = "\n Quadratic form == (rev(x)*x)(0).\n\n >>> print quad(clifford(\"1+{1}+{1,2}\"))\n 3.0\n >>> print quad(clifford(\"1+{-1}+{1,2}+{1,2,3}\"))\n 2.0\n ";
12009  static PyObject *__pyx_pw_8PyClical_31quad(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
12010  PyObject *__pyx_r = 0;
12011  __Pyx_RefNannyDeclarations
12012  __Pyx_RefNannySetupContext("quad (wrapper)", 0);
12013  __pyx_r = __pyx_pf_8PyClical_30quad(__pyx_self, ((PyObject *)__pyx_v_obj));
12014 
12015  /* function exit code */
12016  __Pyx_RefNannyFinishContext();
12017  return __pyx_r;
12018  }
12019 
12020  static PyObject *__pyx_pf_8PyClical_30quad(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
12021  PyObject *__pyx_r = NULL;
12022  __Pyx_RefNannyDeclarations
12023  PyObject *__pyx_t_1 = NULL;
12024  int __pyx_lineno = 0;
12025  const char *__pyx_filename = NULL;
12026  int __pyx_clineno = 0;
12027  __Pyx_RefNannySetupContext("quad", 0);
12028  __Pyx_XDECREF(__pyx_r);
12029  __pyx_t_1 = __pyx_f_8PyClical_quad(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1451; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12030  __Pyx_GOTREF(__pyx_t_1);
12031  __pyx_r = __pyx_t_1;
12032  __pyx_t_1 = 0;
12033  goto __pyx_L0;
12034 
12035  /* function exit code */
12036  __pyx_L1_error:;
12037  __Pyx_XDECREF(__pyx_t_1);
12038  __Pyx_AddTraceback("PyClical.quad", __pyx_clineno, __pyx_lineno, __pyx_filename);
12039  __pyx_r = NULL;
12040  __pyx_L0:;
12041  __Pyx_XGIVEREF(__pyx_r);
12042  __Pyx_RefNannyFinishContext();
12043  return __pyx_r;
12044  }
12045 
12046  /* "PyClical.pyx":1462
12047  * return clifford(obj).quad()
12048  *
12049  * cpdef inline norm(obj): # <<<<<<<<<<<<<<
12050  * """
12051  * norm == sum of squares of coordinates.
12052  */
12053 
12054  static PyObject *__pyx_pw_8PyClical_33norm(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
12055  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_norm(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
12056  PyObject *__pyx_r = NULL;
12057  __Pyx_RefNannyDeclarations
12058  PyObject *__pyx_t_1 = NULL;
12059  PyObject *__pyx_t_2 = NULL;
12060  PyObject *__pyx_t_3 = NULL;
12061  int __pyx_lineno = 0;
12062  const char *__pyx_filename = NULL;
12063  int __pyx_clineno = 0;
12064  __Pyx_RefNannySetupContext("norm", 0);
12065 
12066  /* "PyClical.pyx":1471
12067  * 4.0
12068  * """
12069  * return clifford(obj).norm() # <<<<<<<<<<<<<<
12070  *
12071  * cpdef inline abs(obj):
12072  */
12073  __Pyx_XDECREF(__pyx_r);
12074  __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1471; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12075  __Pyx_GOTREF(__pyx_t_2);
12076  __Pyx_INCREF(__pyx_v_obj);
12077  __Pyx_GIVEREF(__pyx_v_obj);
12078  PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_obj);
12079  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1471; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12080  __Pyx_GOTREF(__pyx_t_3);
12081  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
12082  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_norm); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1471; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12083  __Pyx_GOTREF(__pyx_t_2);
12084  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
12085  __pyx_t_3 = NULL;
12086  if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_2))) {
12087  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
12088  if (likely(__pyx_t_3)) {
12089  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
12090  __Pyx_INCREF(__pyx_t_3);
12091  __Pyx_INCREF(function);
12092  __Pyx_DECREF_SET(__pyx_t_2, function);
12093  }
12094  }
12095  if (__pyx_t_3) {
12096  __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1471; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12097  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
12098  } else {
12099  __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1471; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12100  }
12101  __Pyx_GOTREF(__pyx_t_1);
12102  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
12103  __pyx_r = __pyx_t_1;
12104  __pyx_t_1 = 0;
12105  goto __pyx_L0;
12106 
12107  /* "PyClical.pyx":1462
12108  * return clifford(obj).quad()
12109  *
12110  * cpdef inline norm(obj): # <<<<<<<<<<<<<<
12111  * """
12112  * norm == sum of squares of coordinates.
12113  */
12114 
12115  /* function exit code */
12116  __pyx_L1_error:;
12117  __Pyx_XDECREF(__pyx_t_1);
12118  __Pyx_XDECREF(__pyx_t_2);
12119  __Pyx_XDECREF(__pyx_t_3);
12120  __Pyx_AddTraceback("PyClical.norm", __pyx_clineno, __pyx_lineno, __pyx_filename);
12121  __pyx_r = 0;
12122  __pyx_L0:;
12123  __Pyx_XGIVEREF(__pyx_r);
12124  __Pyx_RefNannyFinishContext();
12125  return __pyx_r;
12126  }
12127 
12128  /* Python wrapper */
12129  static PyObject *__pyx_pw_8PyClical_33norm(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
12130  static char __pyx_doc_8PyClical_32norm[] = "\n norm == sum of squares of coordinates.\n\n >>> norm(clifford(\"1+{1}+{1,2}\"))\n 3.0\n >>> norm(clifford(\"1+{-1}+{1,2}+{1,2,3}\"))\n 4.0\n ";
12131  static PyObject *__pyx_pw_8PyClical_33norm(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
12132  PyObject *__pyx_r = 0;
12133  __Pyx_RefNannyDeclarations
12134  __Pyx_RefNannySetupContext("norm (wrapper)", 0);
12135  __pyx_r = __pyx_pf_8PyClical_32norm(__pyx_self, ((PyObject *)__pyx_v_obj));
12136 
12137  /* function exit code */
12138  __Pyx_RefNannyFinishContext();
12139  return __pyx_r;
12140  }
12141 
12142  static PyObject *__pyx_pf_8PyClical_32norm(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
12143  PyObject *__pyx_r = NULL;
12144  __Pyx_RefNannyDeclarations
12145  PyObject *__pyx_t_1 = NULL;
12146  int __pyx_lineno = 0;
12147  const char *__pyx_filename = NULL;
12148  int __pyx_clineno = 0;
12149  __Pyx_RefNannySetupContext("norm", 0);
12150  __Pyx_XDECREF(__pyx_r);
12151  __pyx_t_1 = __pyx_f_8PyClical_norm(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1462; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12152  __Pyx_GOTREF(__pyx_t_1);
12153  __pyx_r = __pyx_t_1;
12154  __pyx_t_1 = 0;
12155  goto __pyx_L0;
12156 
12157  /* function exit code */
12158  __pyx_L1_error:;
12159  __Pyx_XDECREF(__pyx_t_1);
12160  __Pyx_AddTraceback("PyClical.norm", __pyx_clineno, __pyx_lineno, __pyx_filename);
12161  __pyx_r = NULL;
12162  __pyx_L0:;
12163  __Pyx_XGIVEREF(__pyx_r);
12164  __Pyx_RefNannyFinishContext();
12165  return __pyx_r;
12166  }
12167 
12168  /* "PyClical.pyx":1473
12169  * return clifford(obj).norm()
12170  *
12171  * cpdef inline abs(obj): # <<<<<<<<<<<<<<
12172  * """
12173  * Absolute value of multivector: multivector 2-norm.
12174  */
12175 
12176  static PyObject *__pyx_pw_8PyClical_35abs(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
12177  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_abs(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
12178  PyObject *__pyx_r = NULL;
12179  __Pyx_RefNannyDeclarations
12180  PyObject *__pyx_t_1 = NULL;
12181  int __pyx_lineno = 0;
12182  const char *__pyx_filename = NULL;
12183  int __pyx_clineno = 0;
12184  __Pyx_RefNannySetupContext("abs", 0);
12185 
12186  /* "PyClical.pyx":1480
12187  * 2.0
12188  * """
12189  * return glucat.abs(toClifford(obj)) # <<<<<<<<<<<<<<
12190  *
12191  * cpdef inline max_abs(obj):
12192  */
12193  __Pyx_XDECREF(__pyx_r);
12194  __pyx_t_1 = PyFloat_FromDouble(abs(__pyx_f_8PyClical_toClifford(__pyx_v_obj))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1480; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12195  __Pyx_GOTREF(__pyx_t_1);
12196  __pyx_r = __pyx_t_1;
12197  __pyx_t_1 = 0;
12198  goto __pyx_L0;
12199 
12200  /* "PyClical.pyx":1473
12201  * return clifford(obj).norm()
12202  *
12203  * cpdef inline abs(obj): # <<<<<<<<<<<<<<
12204  * """
12205  * Absolute value of multivector: multivector 2-norm.
12206  */
12207 
12208  /* function exit code */
12209  __pyx_L1_error:;
12210  __Pyx_XDECREF(__pyx_t_1);
12211  __Pyx_AddTraceback("PyClical.abs", __pyx_clineno, __pyx_lineno, __pyx_filename);
12212  __pyx_r = 0;
12213  __pyx_L0:;
12214  __Pyx_XGIVEREF(__pyx_r);
12215  __Pyx_RefNannyFinishContext();
12216  return __pyx_r;
12217  }
12218 
12219  /* Python wrapper */
12220  static PyObject *__pyx_pw_8PyClical_35abs(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
12221  static char __pyx_doc_8PyClical_34abs[] = "\n Absolute value of multivector: multivector 2-norm.\n\n >>> abs(clifford(\"1+{-1}+{1,2}+{1,2,3}\"))\n 2.0\n ";
12222  static PyObject *__pyx_pw_8PyClical_35abs(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
12223  PyObject *__pyx_r = 0;
12224  __Pyx_RefNannyDeclarations
12225  __Pyx_RefNannySetupContext("abs (wrapper)", 0);
12226  __pyx_r = __pyx_pf_8PyClical_34abs(__pyx_self, ((PyObject *)__pyx_v_obj));
12227 
12228  /* function exit code */
12229  __Pyx_RefNannyFinishContext();
12230  return __pyx_r;
12231  }
12232 
12233  static PyObject *__pyx_pf_8PyClical_34abs(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
12234  PyObject *__pyx_r = NULL;
12235  __Pyx_RefNannyDeclarations
12236  PyObject *__pyx_t_1 = NULL;
12237  int __pyx_lineno = 0;
12238  const char *__pyx_filename = NULL;
12239  int __pyx_clineno = 0;
12240  __Pyx_RefNannySetupContext("abs", 0);
12241  __Pyx_XDECREF(__pyx_r);
12242  __pyx_t_1 = __pyx_f_8PyClical_abs(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1473; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12243  __Pyx_GOTREF(__pyx_t_1);
12244  __pyx_r = __pyx_t_1;
12245  __pyx_t_1 = 0;
12246  goto __pyx_L0;
12247 
12248  /* function exit code */
12249  __pyx_L1_error:;
12250  __Pyx_XDECREF(__pyx_t_1);
12251  __Pyx_AddTraceback("PyClical.abs", __pyx_clineno, __pyx_lineno, __pyx_filename);
12252  __pyx_r = NULL;
12253  __pyx_L0:;
12254  __Pyx_XGIVEREF(__pyx_r);
12255  __Pyx_RefNannyFinishContext();
12256  return __pyx_r;
12257  }
12258 
12259  /* "PyClical.pyx":1482
12260  * return glucat.abs(toClifford(obj))
12261  *
12262  * cpdef inline max_abs(obj): # <<<<<<<<<<<<<<
12263  * """
12264  * Maximum absolute value of coordinates multivector: multivector infinity-norm.
12265  */
12266 
12267  static PyObject *__pyx_pw_8PyClical_37max_abs(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
12268  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_max_abs(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
12269  PyObject *__pyx_r = NULL;
12270  __Pyx_RefNannyDeclarations
12271  PyObject *__pyx_t_1 = NULL;
12272  int __pyx_lineno = 0;
12273  const char *__pyx_filename = NULL;
12274  int __pyx_clineno = 0;
12275  __Pyx_RefNannySetupContext("max_abs", 0);
12276 
12277  /* "PyClical.pyx":1492
12278  *
12279  * """
12280  * return glucat.max_abs(toClifford(obj)) # <<<<<<<<<<<<<<
12281  *
12282  * cpdef inline pow(obj, m):
12283  */
12284  __Pyx_XDECREF(__pyx_r);
12285  __pyx_t_1 = PyFloat_FromDouble(max_abs(__pyx_f_8PyClical_toClifford(__pyx_v_obj))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1492; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12286  __Pyx_GOTREF(__pyx_t_1);
12287  __pyx_r = __pyx_t_1;
12288  __pyx_t_1 = 0;
12289  goto __pyx_L0;
12290 
12291  /* "PyClical.pyx":1482
12292  * return glucat.abs(toClifford(obj))
12293  *
12294  * cpdef inline max_abs(obj): # <<<<<<<<<<<<<<
12295  * """
12296  * Maximum absolute value of coordinates multivector: multivector infinity-norm.
12297  */
12298 
12299  /* function exit code */
12300  __pyx_L1_error:;
12301  __Pyx_XDECREF(__pyx_t_1);
12302  __Pyx_AddTraceback("PyClical.max_abs", __pyx_clineno, __pyx_lineno, __pyx_filename);
12303  __pyx_r = 0;
12304  __pyx_L0:;
12305  __Pyx_XGIVEREF(__pyx_r);
12306  __Pyx_RefNannyFinishContext();
12307  return __pyx_r;
12308  }
12309 
12310  /* Python wrapper */
12311  static PyObject *__pyx_pw_8PyClical_37max_abs(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
12312  static char __pyx_doc_8PyClical_36max_abs[] = "\n Maximum absolute value of coordinates multivector: multivector infinity-norm.\n\n >>> max_abs(clifford(\"1+{-1}+{1,2}+{1,2,3}\"))\n 1.0\n >>> max_abs(clifford(\"3+2{1}+{1,2}\"))\n 3.0\n\n ";
12313  static PyObject *__pyx_pw_8PyClical_37max_abs(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
12314  PyObject *__pyx_r = 0;
12315  __Pyx_RefNannyDeclarations
12316  __Pyx_RefNannySetupContext("max_abs (wrapper)", 0);
12317  __pyx_r = __pyx_pf_8PyClical_36max_abs(__pyx_self, ((PyObject *)__pyx_v_obj));
12318 
12319  /* function exit code */
12320  __Pyx_RefNannyFinishContext();
12321  return __pyx_r;
12322  }
12323 
12324  static PyObject *__pyx_pf_8PyClical_36max_abs(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
12325  PyObject *__pyx_r = NULL;
12326  __Pyx_RefNannyDeclarations
12327  PyObject *__pyx_t_1 = NULL;
12328  int __pyx_lineno = 0;
12329  const char *__pyx_filename = NULL;
12330  int __pyx_clineno = 0;
12331  __Pyx_RefNannySetupContext("max_abs", 0);
12332  __Pyx_XDECREF(__pyx_r);
12333  __pyx_t_1 = __pyx_f_8PyClical_max_abs(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1482; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12334  __Pyx_GOTREF(__pyx_t_1);
12335  __pyx_r = __pyx_t_1;
12336  __pyx_t_1 = 0;
12337  goto __pyx_L0;
12338 
12339  /* function exit code */
12340  __pyx_L1_error:;
12341  __Pyx_XDECREF(__pyx_t_1);
12342  __Pyx_AddTraceback("PyClical.max_abs", __pyx_clineno, __pyx_lineno, __pyx_filename);
12343  __pyx_r = NULL;
12344  __pyx_L0:;
12345  __Pyx_XGIVEREF(__pyx_r);
12346  __Pyx_RefNannyFinishContext();
12347  return __pyx_r;
12348  }
12349 
12350  /* "PyClical.pyx":1494
12351  * return glucat.max_abs(toClifford(obj))
12352  *
12353  * cpdef inline pow(obj, m): # <<<<<<<<<<<<<<
12354  * """
12355  * Integer power of multivector: obj to the m.
12356  */
12357 
12358  static PyObject *__pyx_pw_8PyClical_39pow(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
12359  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_pow(PyObject *__pyx_v_obj, PyObject *__pyx_v_m, CYTHON_UNUSED int __pyx_skip_dispatch) {
12360  PyObject *__pyx_r = NULL;
12361  __Pyx_RefNannyDeclarations
12362  PyObject *__pyx_t_1 = NULL;
12363  PyObject *__pyx_t_2 = NULL;
12364  PyObject *__pyx_t_3 = NULL;
12365  PyObject *__pyx_t_4 = NULL;
12366  PyObject *__pyx_t_5 = NULL;
12367  PyObject *__pyx_t_6 = NULL;
12368  Py_ssize_t __pyx_t_7;
12369  PyObject *__pyx_t_8 = NULL;
12370  PyObject *__pyx_t_9 = NULL;
12371  PyObject *__pyx_t_10 = NULL;
12372  PyObject *__pyx_t_11 = NULL;
12373  int __pyx_lineno = 0;
12374  const char *__pyx_filename = NULL;
12375  int __pyx_clineno = 0;
12376  __Pyx_RefNannySetupContext("pow", 0);
12377 
12378  /* "PyClical.pyx":1513
12379  * 1
12380  * """
12381  * try: # <<<<<<<<<<<<<<
12382  * math.pow(obj, m)
12383  * except:
12384  */
12385  {
12386  __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3);
12387  __Pyx_XGOTREF(__pyx_t_1);
12388  __Pyx_XGOTREF(__pyx_t_2);
12389  __Pyx_XGOTREF(__pyx_t_3);
12390  /*try:*/ {
12391 
12392  /* "PyClical.pyx":1514
12393  * """
12394  * try:
12395  * math.pow(obj, m) # <<<<<<<<<<<<<<
12396  * except:
12397  * return clifford(obj).pow(m)
12398  */
12399  __pyx_t_5 = __Pyx_GetModuleGlobalName(__pyx_n_s_math); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1514; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
12400  __Pyx_GOTREF(__pyx_t_5);
12401  __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_pow); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1514; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
12402  __Pyx_GOTREF(__pyx_t_6);
12403  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
12404  __pyx_t_5 = NULL;
12405  __pyx_t_7 = 0;
12406  if (CYTHON_COMPILING_IN_CPYTHON && unlikely(PyMethod_Check(__pyx_t_6))) {
12407  __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_6);
12408  if (likely(__pyx_t_5)) {
12409  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6);
12410  __Pyx_INCREF(__pyx_t_5);
12411  __Pyx_INCREF(function);
12412  __Pyx_DECREF_SET(__pyx_t_6, function);
12413  __pyx_t_7 = 1;
12414  }
12415  }
12416  __pyx_t_8 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1514; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
12417  __Pyx_GOTREF(__pyx_t_8);
12418  if (__pyx_t_5) {
12419  __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_5); __pyx_t_5 = NULL;
12420  }
12421  __Pyx_INCREF(__pyx_v_obj);
12422  __Pyx_GIVEREF(__pyx_v_obj);
12423  PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_7, __pyx_v_obj);
12424  __Pyx_INCREF(__pyx_v_m);
12425  __Pyx_GIVEREF(__pyx_v_m);
12426  PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_7, __pyx_v_m);
12427  __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_8, NULL); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1514; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
12428  __Pyx_GOTREF(__pyx_t_4);
12429  __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
12430  __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
12431  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
12432 
12433  /* "PyClical.pyx":1513
12434  * 1
12435  * """
12436  * try: # <<<<<<<<<<<<<<
12437  * math.pow(obj, m)
12438  * except:
12439  */
12440  }
12441  __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
12442  __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
12443  __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
12444  goto __pyx_L10_try_end;
12445  __pyx_L3_error:;
12446  __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
12447  __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
12448  __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
12449  __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
12450 
12451  /* "PyClical.pyx":1515
12452  * try:
12453  * math.pow(obj, m)
12454  * except: # <<<<<<<<<<<<<<
12455  * return clifford(obj).pow(m)
12456  *
12457  */
12458  /*except:*/ {
12459  __Pyx_AddTraceback("PyClical.pow", __pyx_clineno, __pyx_lineno, __pyx_filename);
12460  if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_8) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1515; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
12461  __Pyx_GOTREF(__pyx_t_4);
12462  __Pyx_GOTREF(__pyx_t_6);
12463  __Pyx_GOTREF(__pyx_t_8);
12464 
12465  /* "PyClical.pyx":1516
12466  * math.pow(obj, m)
12467  * except:
12468  * return clifford(obj).pow(m) # <<<<<<<<<<<<<<
12469  *
12470  * cpdef inline outer_pow(obj, m):
12471  */
12472  __Pyx_XDECREF(__pyx_r);
12473  __pyx_t_9 = PyTuple_New(1); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1516; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
12474  __Pyx_GOTREF(__pyx_t_9);
12475  __Pyx_INCREF(__pyx_v_obj);
12476  __Pyx_GIVEREF(__pyx_v_obj);
12477  PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_v_obj);
12478  __pyx_t_10 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_t_9, NULL); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1516; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
12479  __Pyx_GOTREF(__pyx_t_10);
12480  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
12481  __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_10, __pyx_n_s_pow); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1516; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
12482  __Pyx_GOTREF(__pyx_t_9);
12483  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
12484  __pyx_t_10 = NULL;
12485  if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_9))) {
12486  __pyx_t_10 = PyMethod_GET_SELF(__pyx_t_9);
12487  if (likely(__pyx_t_10)) {
12488  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_9);
12489  __Pyx_INCREF(__pyx_t_10);
12490  __Pyx_INCREF(function);
12491  __Pyx_DECREF_SET(__pyx_t_9, function);
12492  }
12493  }
12494  if (!__pyx_t_10) {
12495  __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_t_9, __pyx_v_m); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1516; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
12496  __Pyx_GOTREF(__pyx_t_5);
12497  } else {
12498  __pyx_t_11 = PyTuple_New(1+1); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1516; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
12499  __Pyx_GOTREF(__pyx_t_11);
12500  __Pyx_GIVEREF(__pyx_t_10); PyTuple_SET_ITEM(__pyx_t_11, 0, __pyx_t_10); __pyx_t_10 = NULL;
12501  __Pyx_INCREF(__pyx_v_m);
12502  __Pyx_GIVEREF(__pyx_v_m);
12503  PyTuple_SET_ITEM(__pyx_t_11, 0+1, __pyx_v_m);
12504  __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_11, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1516; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
12505  __Pyx_GOTREF(__pyx_t_5);
12506  __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
12507  }
12508  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
12509  __pyx_r = __pyx_t_5;
12510  __pyx_t_5 = 0;
12511  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
12512  __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
12513  __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
12514  goto __pyx_L6_except_return;
12515  }
12516  __pyx_L5_except_error:;
12517 
12518  /* "PyClical.pyx":1513
12519  * 1
12520  * """
12521  * try: # <<<<<<<<<<<<<<
12522  * math.pow(obj, m)
12523  * except:
12524  */
12525  __Pyx_XGIVEREF(__pyx_t_1);
12526  __Pyx_XGIVEREF(__pyx_t_2);
12527  __Pyx_XGIVEREF(__pyx_t_3);
12528  __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
12529  goto __pyx_L1_error;
12530  __pyx_L6_except_return:;
12531  __Pyx_XGIVEREF(__pyx_t_1);
12532  __Pyx_XGIVEREF(__pyx_t_2);
12533  __Pyx_XGIVEREF(__pyx_t_3);
12534  __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
12535  goto __pyx_L0;
12536  __pyx_L10_try_end:;
12537  }
12538 
12539  /* "PyClical.pyx":1494
12540  * return glucat.max_abs(toClifford(obj))
12541  *
12542  * cpdef inline pow(obj, m): # <<<<<<<<<<<<<<
12543  * """
12544  * Integer power of multivector: obj to the m.
12545  */
12546 
12547  /* function exit code */
12548  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
12549  goto __pyx_L0;
12550  __pyx_L1_error:;
12551  __Pyx_XDECREF(__pyx_t_4);
12552  __Pyx_XDECREF(__pyx_t_5);
12553  __Pyx_XDECREF(__pyx_t_6);
12554  __Pyx_XDECREF(__pyx_t_8);
12555  __Pyx_XDECREF(__pyx_t_9);
12556  __Pyx_XDECREF(__pyx_t_10);
12557  __Pyx_XDECREF(__pyx_t_11);
12558  __Pyx_AddTraceback("PyClical.pow", __pyx_clineno, __pyx_lineno, __pyx_filename);
12559  __pyx_r = 0;
12560  __pyx_L0:;
12561  __Pyx_XGIVEREF(__pyx_r);
12562  __Pyx_RefNannyFinishContext();
12563  return __pyx_r;
12564  }
12565 
12566  /* Python wrapper */
12567  static PyObject *__pyx_pw_8PyClical_39pow(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
12568  static char __pyx_doc_8PyClical_38pow[] = "\n Integer power of multivector: obj to the m.\n\n >>> x=clifford(\"{1}\"); print pow(x,2)\n 1\n >>> x=clifford(\"2\"); print pow(x,2)\n 4\n >>> x=clifford(\"2+{1}\"); print pow(x,0)\n 1\n >>> x=clifford(\"2+{1}\"); print pow(x,1)\n 2+{1}\n >>> x=clifford(\"2+{1}\"); print pow(x,2)\n 5+4{1}\n >>> print pow(clifford(\"1+{1}+{1,2}\"),3)\n 1+3{1}+3{1,2}\n >>> i=clifford(\"{1,2}\");print exp(pi/2) * pow(i, i)\n 1\n ";
12569  static PyObject *__pyx_pw_8PyClical_39pow(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
12570  PyObject *__pyx_v_obj = 0;
12571  PyObject *__pyx_v_m = 0;
12572  int __pyx_lineno = 0;
12573  const char *__pyx_filename = NULL;
12574  int __pyx_clineno = 0;
12575  PyObject *__pyx_r = 0;
12576  __Pyx_RefNannyDeclarations
12577  __Pyx_RefNannySetupContext("pow (wrapper)", 0);
12578  {
12579  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_obj,&__pyx_n_s_m,0};
12580  PyObject* values[2] = {0,0};
12581  if (unlikely(__pyx_kwds)) {
12582  Py_ssize_t kw_args;
12583  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
12584  switch (pos_args) {
12585  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
12586  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
12587  case 0: break;
12588  default: goto __pyx_L5_argtuple_error;
12589  }
12590  kw_args = PyDict_Size(__pyx_kwds);
12591  switch (pos_args) {
12592  case 0:
12593  if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_obj)) != 0)) kw_args--;
12594  else goto __pyx_L5_argtuple_error;
12595  case 1:
12596  if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_m)) != 0)) kw_args--;
12597  else {
12598  __Pyx_RaiseArgtupleInvalid("pow", 1, 2, 2, 1); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1494; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
12599  }
12600  }
12601  if (unlikely(kw_args > 0)) {
12602  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "pow") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1494; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
12603  }
12604  } else if (PyTuple_GET_SIZE(__pyx_args) != 2) {
12605  goto __pyx_L5_argtuple_error;
12606  } else {
12607  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
12608  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
12609  }
12610  __pyx_v_obj = values[0];
12611  __pyx_v_m = values[1];
12612  }
12613  goto __pyx_L4_argument_unpacking_done;
12614  __pyx_L5_argtuple_error:;
12615  __Pyx_RaiseArgtupleInvalid("pow", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1494; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
12616  __pyx_L3_error:;
12617  __Pyx_AddTraceback("PyClical.pow", __pyx_clineno, __pyx_lineno, __pyx_filename);
12618  __Pyx_RefNannyFinishContext();
12619  return NULL;
12620  __pyx_L4_argument_unpacking_done:;
12621  __pyx_r = __pyx_pf_8PyClical_38pow(__pyx_self, __pyx_v_obj, __pyx_v_m);
12622 
12623  /* function exit code */
12624  __Pyx_RefNannyFinishContext();
12625  return __pyx_r;
12626  }
12627 
12628  static PyObject *__pyx_pf_8PyClical_38pow(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_m) {
12629  PyObject *__pyx_r = NULL;
12630  __Pyx_RefNannyDeclarations
12631  PyObject *__pyx_t_1 = NULL;
12632  int __pyx_lineno = 0;
12633  const char *__pyx_filename = NULL;
12634  int __pyx_clineno = 0;
12635  __Pyx_RefNannySetupContext("pow", 0);
12636  __Pyx_XDECREF(__pyx_r);
12637  __pyx_t_1 = __pyx_f_8PyClical_pow(__pyx_v_obj, __pyx_v_m, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1494; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12638  __Pyx_GOTREF(__pyx_t_1);
12639  __pyx_r = __pyx_t_1;
12640  __pyx_t_1 = 0;
12641  goto __pyx_L0;
12642 
12643  /* function exit code */
12644  __pyx_L1_error:;
12645  __Pyx_XDECREF(__pyx_t_1);
12646  __Pyx_AddTraceback("PyClical.pow", __pyx_clineno, __pyx_lineno, __pyx_filename);
12647  __pyx_r = NULL;
12648  __pyx_L0:;
12649  __Pyx_XGIVEREF(__pyx_r);
12650  __Pyx_RefNannyFinishContext();
12651  return __pyx_r;
12652  }
12653 
12654  /* "PyClical.pyx":1518
12655  * return clifford(obj).pow(m)
12656  *
12657  * cpdef inline outer_pow(obj, m): # <<<<<<<<<<<<<<
12658  * """
12659  * Outer product power of multivector.
12660  */
12661 
12662  static PyObject *__pyx_pw_8PyClical_41outer_pow(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
12663  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_outer_pow(PyObject *__pyx_v_obj, PyObject *__pyx_v_m, CYTHON_UNUSED int __pyx_skip_dispatch) {
12664  PyObject *__pyx_r = NULL;
12665  __Pyx_RefNannyDeclarations
12666  PyObject *__pyx_t_1 = NULL;
12667  PyObject *__pyx_t_2 = NULL;
12668  PyObject *__pyx_t_3 = NULL;
12669  PyObject *__pyx_t_4 = NULL;
12670  int __pyx_lineno = 0;
12671  const char *__pyx_filename = NULL;
12672  int __pyx_clineno = 0;
12673  __Pyx_RefNannySetupContext("outer_pow", 0);
12674 
12675  /* "PyClical.pyx":1525
12676  * 1+3{1}+3{1,2}
12677  * """
12678  * return clifford(obj).outer_pow(m) # <<<<<<<<<<<<<<
12679  *
12680  * cpdef inline complexifier(obj):
12681  */
12682  __Pyx_XDECREF(__pyx_r);
12683  __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1525; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12684  __Pyx_GOTREF(__pyx_t_2);
12685  __Pyx_INCREF(__pyx_v_obj);
12686  __Pyx_GIVEREF(__pyx_v_obj);
12687  PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_obj);
12688  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1525; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12689  __Pyx_GOTREF(__pyx_t_3);
12690  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
12691  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_outer_pow); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1525; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12692  __Pyx_GOTREF(__pyx_t_2);
12693  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
12694  __pyx_t_3 = NULL;
12695  if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_2))) {
12696  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
12697  if (likely(__pyx_t_3)) {
12698  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
12699  __Pyx_INCREF(__pyx_t_3);
12700  __Pyx_INCREF(function);
12701  __Pyx_DECREF_SET(__pyx_t_2, function);
12702  }
12703  }
12704  if (!__pyx_t_3) {
12705  __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_m); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1525; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12706  __Pyx_GOTREF(__pyx_t_1);
12707  } else {
12708  __pyx_t_4 = PyTuple_New(1+1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1525; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12709  __Pyx_GOTREF(__pyx_t_4);
12710  __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_3); __pyx_t_3 = NULL;
12711  __Pyx_INCREF(__pyx_v_m);
12712  __Pyx_GIVEREF(__pyx_v_m);
12713  PyTuple_SET_ITEM(__pyx_t_4, 0+1, __pyx_v_m);
12714  __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_4, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1525; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12715  __Pyx_GOTREF(__pyx_t_1);
12716  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
12717  }
12718  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
12719  __pyx_r = __pyx_t_1;
12720  __pyx_t_1 = 0;
12721  goto __pyx_L0;
12722 
12723  /* "PyClical.pyx":1518
12724  * return clifford(obj).pow(m)
12725  *
12726  * cpdef inline outer_pow(obj, m): # <<<<<<<<<<<<<<
12727  * """
12728  * Outer product power of multivector.
12729  */
12730 
12731  /* function exit code */
12732  __pyx_L1_error:;
12733  __Pyx_XDECREF(__pyx_t_1);
12734  __Pyx_XDECREF(__pyx_t_2);
12735  __Pyx_XDECREF(__pyx_t_3);
12736  __Pyx_XDECREF(__pyx_t_4);
12737  __Pyx_AddTraceback("PyClical.outer_pow", __pyx_clineno, __pyx_lineno, __pyx_filename);
12738  __pyx_r = 0;
12739  __pyx_L0:;
12740  __Pyx_XGIVEREF(__pyx_r);
12741  __Pyx_RefNannyFinishContext();
12742  return __pyx_r;
12743  }
12744 
12745  /* Python wrapper */
12746  static PyObject *__pyx_pw_8PyClical_41outer_pow(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
12747  static char __pyx_doc_8PyClical_40outer_pow[] = "\n Outer product power of multivector.\n\n >>> print outer_pow(clifford(\"1+{1}+{1,2}\"),3)\n 1+3{1}+3{1,2}\n ";
12748  static PyObject *__pyx_pw_8PyClical_41outer_pow(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
12749  PyObject *__pyx_v_obj = 0;
12750  PyObject *__pyx_v_m = 0;
12751  int __pyx_lineno = 0;
12752  const char *__pyx_filename = NULL;
12753  int __pyx_clineno = 0;
12754  PyObject *__pyx_r = 0;
12755  __Pyx_RefNannyDeclarations
12756  __Pyx_RefNannySetupContext("outer_pow (wrapper)", 0);
12757  {
12758  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_obj,&__pyx_n_s_m,0};
12759  PyObject* values[2] = {0,0};
12760  if (unlikely(__pyx_kwds)) {
12761  Py_ssize_t kw_args;
12762  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
12763  switch (pos_args) {
12764  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
12765  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
12766  case 0: break;
12767  default: goto __pyx_L5_argtuple_error;
12768  }
12769  kw_args = PyDict_Size(__pyx_kwds);
12770  switch (pos_args) {
12771  case 0:
12772  if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_obj)) != 0)) kw_args--;
12773  else goto __pyx_L5_argtuple_error;
12774  case 1:
12775  if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_m)) != 0)) kw_args--;
12776  else {
12777  __Pyx_RaiseArgtupleInvalid("outer_pow", 1, 2, 2, 1); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1518; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
12778  }
12779  }
12780  if (unlikely(kw_args > 0)) {
12781  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "outer_pow") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1518; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
12782  }
12783  } else if (PyTuple_GET_SIZE(__pyx_args) != 2) {
12784  goto __pyx_L5_argtuple_error;
12785  } else {
12786  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
12787  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
12788  }
12789  __pyx_v_obj = values[0];
12790  __pyx_v_m = values[1];
12791  }
12792  goto __pyx_L4_argument_unpacking_done;
12793  __pyx_L5_argtuple_error:;
12794  __Pyx_RaiseArgtupleInvalid("outer_pow", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1518; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
12795  __pyx_L3_error:;
12796  __Pyx_AddTraceback("PyClical.outer_pow", __pyx_clineno, __pyx_lineno, __pyx_filename);
12797  __Pyx_RefNannyFinishContext();
12798  return NULL;
12799  __pyx_L4_argument_unpacking_done:;
12800  __pyx_r = __pyx_pf_8PyClical_40outer_pow(__pyx_self, __pyx_v_obj, __pyx_v_m);
12801 
12802  /* function exit code */
12803  __Pyx_RefNannyFinishContext();
12804  return __pyx_r;
12805  }
12806 
12807  static PyObject *__pyx_pf_8PyClical_40outer_pow(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_m) {
12808  PyObject *__pyx_r = NULL;
12809  __Pyx_RefNannyDeclarations
12810  PyObject *__pyx_t_1 = NULL;
12811  int __pyx_lineno = 0;
12812  const char *__pyx_filename = NULL;
12813  int __pyx_clineno = 0;
12814  __Pyx_RefNannySetupContext("outer_pow", 0);
12815  __Pyx_XDECREF(__pyx_r);
12816  __pyx_t_1 = __pyx_f_8PyClical_outer_pow(__pyx_v_obj, __pyx_v_m, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1518; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12817  __Pyx_GOTREF(__pyx_t_1);
12818  __pyx_r = __pyx_t_1;
12819  __pyx_t_1 = 0;
12820  goto __pyx_L0;
12821 
12822  /* function exit code */
12823  __pyx_L1_error:;
12824  __Pyx_XDECREF(__pyx_t_1);
12825  __Pyx_AddTraceback("PyClical.outer_pow", __pyx_clineno, __pyx_lineno, __pyx_filename);
12826  __pyx_r = NULL;
12827  __pyx_L0:;
12828  __Pyx_XGIVEREF(__pyx_r);
12829  __Pyx_RefNannyFinishContext();
12830  return __pyx_r;
12831  }
12832 
12833  /* "PyClical.pyx":1527
12834  * return clifford(obj).outer_pow(m)
12835  *
12836  * cpdef inline complexifier(obj): # <<<<<<<<<<<<<<
12837  * """
12838  * Square root of -1 which commutes with all members of the frame of the given multivector.
12839  */
12840 
12841  static PyObject *__pyx_pw_8PyClical_43complexifier(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
12842  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_complexifier(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
12843  PyObject *__pyx_r = NULL;
12844  __Pyx_RefNannyDeclarations
12845  PyObject *__pyx_t_1 = NULL;
12846  PyObject *__pyx_t_2 = NULL;
12847  int __pyx_lineno = 0;
12848  const char *__pyx_filename = NULL;
12849  int __pyx_clineno = 0;
12850  __Pyx_RefNannySetupContext("complexifier", 0);
12851 
12852  /* "PyClical.pyx":1540
12853  * {-1}
12854  * """
12855  * return clifford().wrap( glucat.complexifier(toClifford(obj)) ) # <<<<<<<<<<<<<<
12856  *
12857  * cpdef inline sqrt(obj, i = None):
12858  */
12859  __Pyx_XDECREF(__pyx_r);
12860  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1540; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12861  __Pyx_GOTREF(__pyx_t_1);
12862  __pyx_t_2 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), complexifier(__pyx_f_8PyClical_toClifford(__pyx_v_obj))); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1540; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12863  __Pyx_GOTREF(__pyx_t_2);
12864  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
12865  __pyx_r = __pyx_t_2;
12866  __pyx_t_2 = 0;
12867  goto __pyx_L0;
12868 
12869  /* "PyClical.pyx":1527
12870  * return clifford(obj).outer_pow(m)
12871  *
12872  * cpdef inline complexifier(obj): # <<<<<<<<<<<<<<
12873  * """
12874  * Square root of -1 which commutes with all members of the frame of the given multivector.
12875  */
12876 
12877  /* function exit code */
12878  __pyx_L1_error:;
12879  __Pyx_XDECREF(__pyx_t_1);
12880  __Pyx_XDECREF(__pyx_t_2);
12881  __Pyx_AddTraceback("PyClical.complexifier", __pyx_clineno, __pyx_lineno, __pyx_filename);
12882  __pyx_r = 0;
12883  __pyx_L0:;
12884  __Pyx_XGIVEREF(__pyx_r);
12885  __Pyx_RefNannyFinishContext();
12886  return __pyx_r;
12887  }
12888 
12889  /* Python wrapper */
12890  static PyObject *__pyx_pw_8PyClical_43complexifier(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
12891  static char __pyx_doc_8PyClical_42complexifier[] = "\n Square root of -1 which commutes with all members of the frame of the given multivector.\n\n >>> print complexifier(clifford(index_set({1})))\n {1,2,3}\n >>> print complexifier(clifford(index_set({-1})))\n {-1}\n >>> print complexifier(index_set({1}))\n {1,2,3}\n >>> print complexifier(index_set({-1}))\n {-1}\n ";
12892  static PyObject *__pyx_pw_8PyClical_43complexifier(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
12893  PyObject *__pyx_r = 0;
12894  __Pyx_RefNannyDeclarations
12895  __Pyx_RefNannySetupContext("complexifier (wrapper)", 0);
12896  __pyx_r = __pyx_pf_8PyClical_42complexifier(__pyx_self, ((PyObject *)__pyx_v_obj));
12897 
12898  /* function exit code */
12899  __Pyx_RefNannyFinishContext();
12900  return __pyx_r;
12901  }
12902 
12903  static PyObject *__pyx_pf_8PyClical_42complexifier(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
12904  PyObject *__pyx_r = NULL;
12905  __Pyx_RefNannyDeclarations
12906  PyObject *__pyx_t_1 = NULL;
12907  int __pyx_lineno = 0;
12908  const char *__pyx_filename = NULL;
12909  int __pyx_clineno = 0;
12910  __Pyx_RefNannySetupContext("complexifier", 0);
12911  __Pyx_XDECREF(__pyx_r);
12912  __pyx_t_1 = __pyx_f_8PyClical_complexifier(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1527; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12913  __Pyx_GOTREF(__pyx_t_1);
12914  __pyx_r = __pyx_t_1;
12915  __pyx_t_1 = 0;
12916  goto __pyx_L0;
12917 
12918  /* function exit code */
12919  __pyx_L1_error:;
12920  __Pyx_XDECREF(__pyx_t_1);
12921  __Pyx_AddTraceback("PyClical.complexifier", __pyx_clineno, __pyx_lineno, __pyx_filename);
12922  __pyx_r = NULL;
12923  __pyx_L0:;
12924  __Pyx_XGIVEREF(__pyx_r);
12925  __Pyx_RefNannyFinishContext();
12926  return __pyx_r;
12927  }
12928 
12929  /* "PyClical.pyx":1542
12930  * return clifford().wrap( glucat.complexifier(toClifford(obj)) )
12931  *
12932  * cpdef inline sqrt(obj, i = None): # <<<<<<<<<<<<<<
12933  * """
12934  * Square root of multivector with optional complexifier.
12935  */
12936 
12937  static PyObject *__pyx_pw_8PyClical_45sqrt(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
12938  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_sqrt(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_sqrt *__pyx_optional_args) {
12939  PyObject *__pyx_v_i = ((PyObject *)Py_None);
12940  PyObject *__pyx_r = NULL;
12941  __Pyx_RefNannyDeclarations
12942  int __pyx_t_1;
12943  int __pyx_t_2;
12944  PyObject *__pyx_t_3 = NULL;
12945  Clifford __pyx_t_4;
12946  PyObject *__pyx_t_5 = NULL;
12947  PyObject *__pyx_t_6 = NULL;
12948  PyObject *__pyx_t_7 = NULL;
12949  PyObject *__pyx_t_8 = NULL;
12950  PyObject *__pyx_t_9 = NULL;
12951  PyObject *__pyx_t_10 = NULL;
12952  PyObject *__pyx_t_11 = NULL;
12953  int __pyx_lineno = 0;
12954  const char *__pyx_filename = NULL;
12955  int __pyx_clineno = 0;
12956  __Pyx_RefNannySetupContext("sqrt", 0);
12957  if (__pyx_optional_args) {
12958  if (__pyx_optional_args->__pyx_n > 0) {
12959  __pyx_v_i = __pyx_optional_args->i;
12960  }
12961  }
12962 
12963  /* "PyClical.pyx":1557
12964  * -1
12965  * """
12966  * if not (i is None): # <<<<<<<<<<<<<<
12967  * return clifford().wrap( glucat.sqrt(toClifford(obj), toClifford(i)) )
12968  * else:
12969  */
12970  __pyx_t_1 = (__pyx_v_i != Py_None);
12971  __pyx_t_2 = (__pyx_t_1 != 0);
12972  if (__pyx_t_2) {
12973 
12974  /* "PyClical.pyx":1558
12975  * """
12976  * if not (i is None):
12977  * return clifford().wrap( glucat.sqrt(toClifford(obj), toClifford(i)) ) # <<<<<<<<<<<<<<
12978  * else:
12979  * try:
12980  */
12981  __Pyx_XDECREF(__pyx_r);
12982  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1558; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12983  __Pyx_GOTREF(__pyx_t_3);
12984  try {
12985  __pyx_t_4 = sqrt(__pyx_f_8PyClical_toClifford(__pyx_v_obj), __pyx_f_8PyClical_toClifford(__pyx_v_i));
12986  } catch(...) {
12987  __Pyx_CppExn2PyErr();
12988  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1558; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12989  }
12990  __pyx_t_5 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_3), __pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1558; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
12991  __Pyx_GOTREF(__pyx_t_5);
12992  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
12993  __pyx_r = __pyx_t_5;
12994  __pyx_t_5 = 0;
12995  goto __pyx_L0;
12996 
12997  /* "PyClical.pyx":1557
12998  * -1
12999  * """
13000  * if not (i is None): # <<<<<<<<<<<<<<
13001  * return clifford().wrap( glucat.sqrt(toClifford(obj), toClifford(i)) )
13002  * else:
13003  */
13004  }
13005 
13006  /* "PyClical.pyx":1560
13007  * return clifford().wrap( glucat.sqrt(toClifford(obj), toClifford(i)) )
13008  * else:
13009  * try: # <<<<<<<<<<<<<<
13010  * return math.sqrt(obj)
13011  * except:
13012  */
13013  /*else*/ {
13014  {
13015  __Pyx_ExceptionSave(&__pyx_t_6, &__pyx_t_7, &__pyx_t_8);
13016  __Pyx_XGOTREF(__pyx_t_6);
13017  __Pyx_XGOTREF(__pyx_t_7);
13018  __Pyx_XGOTREF(__pyx_t_8);
13019  /*try:*/ {
13020 
13021  /* "PyClical.pyx":1561
13022  * else:
13023  * try:
13024  * return math.sqrt(obj) # <<<<<<<<<<<<<<
13025  * except:
13026  * return clifford().wrap( glucat.sqrt(toClifford(obj)) )
13027  */
13028  __Pyx_XDECREF(__pyx_r);
13029  __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_math); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1561; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
13030  __Pyx_GOTREF(__pyx_t_3);
13031  __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_sqrt); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1561; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
13032  __Pyx_GOTREF(__pyx_t_9);
13033  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
13034  __pyx_t_3 = NULL;
13035  if (CYTHON_COMPILING_IN_CPYTHON && unlikely(PyMethod_Check(__pyx_t_9))) {
13036  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_9);
13037  if (likely(__pyx_t_3)) {
13038  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_9);
13039  __Pyx_INCREF(__pyx_t_3);
13040  __Pyx_INCREF(function);
13041  __Pyx_DECREF_SET(__pyx_t_9, function);
13042  }
13043  }
13044  if (!__pyx_t_3) {
13045  __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_t_9, __pyx_v_obj); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1561; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
13046  __Pyx_GOTREF(__pyx_t_5);
13047  } else {
13048  __pyx_t_10 = PyTuple_New(1+1); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1561; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
13049  __Pyx_GOTREF(__pyx_t_10);
13050  __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_3); __pyx_t_3 = NULL;
13051  __Pyx_INCREF(__pyx_v_obj);
13052  __Pyx_GIVEREF(__pyx_v_obj);
13053  PyTuple_SET_ITEM(__pyx_t_10, 0+1, __pyx_v_obj);
13054  __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1561; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
13055  __Pyx_GOTREF(__pyx_t_5);
13056  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
13057  }
13058  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
13059  __pyx_r = __pyx_t_5;
13060  __pyx_t_5 = 0;
13061  goto __pyx_L8_try_return;
13062 
13063  /* "PyClical.pyx":1560
13064  * return clifford().wrap( glucat.sqrt(toClifford(obj), toClifford(i)) )
13065  * else:
13066  * try: # <<<<<<<<<<<<<<
13067  * return math.sqrt(obj)
13068  * except:
13069  */
13070  }
13071  __pyx_L4_error:;
13072  __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
13073  __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0;
13074  __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
13075  __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
13076 
13077  /* "PyClical.pyx":1562
13078  * try:
13079  * return math.sqrt(obj)
13080  * except: # <<<<<<<<<<<<<<
13081  * return clifford().wrap( glucat.sqrt(toClifford(obj)) )
13082  *
13083  */
13084  /*except:*/ {
13085  __Pyx_AddTraceback("PyClical.sqrt", __pyx_clineno, __pyx_lineno, __pyx_filename);
13086  if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_9, &__pyx_t_10) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1562; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
13087  __Pyx_GOTREF(__pyx_t_5);
13088  __Pyx_GOTREF(__pyx_t_9);
13089  __Pyx_GOTREF(__pyx_t_10);
13090 
13091  /* "PyClical.pyx":1563
13092  * return math.sqrt(obj)
13093  * except:
13094  * return clifford().wrap( glucat.sqrt(toClifford(obj)) ) # <<<<<<<<<<<<<<
13095  *
13096  * cpdef inline exp(obj):
13097  */
13098  __Pyx_XDECREF(__pyx_r);
13099  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1563; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
13100  __Pyx_GOTREF(__pyx_t_3);
13101  __pyx_t_11 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_3), sqrt(__pyx_f_8PyClical_toClifford(__pyx_v_obj))); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1563; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
13102  __Pyx_GOTREF(__pyx_t_11);
13103  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
13104  __pyx_r = __pyx_t_11;
13105  __pyx_t_11 = 0;
13106  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
13107  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
13108  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
13109  goto __pyx_L7_except_return;
13110  }
13111  __pyx_L6_except_error:;
13112 
13113  /* "PyClical.pyx":1560
13114  * return clifford().wrap( glucat.sqrt(toClifford(obj), toClifford(i)) )
13115  * else:
13116  * try: # <<<<<<<<<<<<<<
13117  * return math.sqrt(obj)
13118  * except:
13119  */
13120  __Pyx_XGIVEREF(__pyx_t_6);
13121  __Pyx_XGIVEREF(__pyx_t_7);
13122  __Pyx_XGIVEREF(__pyx_t_8);
13123  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
13124  goto __pyx_L1_error;
13125  __pyx_L8_try_return:;
13126  __Pyx_XGIVEREF(__pyx_t_6);
13127  __Pyx_XGIVEREF(__pyx_t_7);
13128  __Pyx_XGIVEREF(__pyx_t_8);
13129  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
13130  goto __pyx_L0;
13131  __pyx_L7_except_return:;
13132  __Pyx_XGIVEREF(__pyx_t_6);
13133  __Pyx_XGIVEREF(__pyx_t_7);
13134  __Pyx_XGIVEREF(__pyx_t_8);
13135  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
13136  goto __pyx_L0;
13137  }
13138  }
13139 
13140  /* "PyClical.pyx":1542
13141  * return clifford().wrap( glucat.complexifier(toClifford(obj)) )
13142  *
13143  * cpdef inline sqrt(obj, i = None): # <<<<<<<<<<<<<<
13144  * """
13145  * Square root of multivector with optional complexifier.
13146  */
13147 
13148  /* function exit code */
13149  __pyx_L1_error:;
13150  __Pyx_XDECREF(__pyx_t_3);
13151  __Pyx_XDECREF(__pyx_t_5);
13152  __Pyx_XDECREF(__pyx_t_9);
13153  __Pyx_XDECREF(__pyx_t_10);
13154  __Pyx_XDECREF(__pyx_t_11);
13155  __Pyx_AddTraceback("PyClical.sqrt", __pyx_clineno, __pyx_lineno, __pyx_filename);
13156  __pyx_r = 0;
13157  __pyx_L0:;
13158  __Pyx_XGIVEREF(__pyx_r);
13159  __Pyx_RefNannyFinishContext();
13160  return __pyx_r;
13161  }
13162 
13163  /* Python wrapper */
13164  static PyObject *__pyx_pw_8PyClical_45sqrt(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
13165  static char __pyx_doc_8PyClical_44sqrt[] = "\n Square root of multivector with optional complexifier.\n\n >>> print sqrt(-1)\n {-1}\n >>> print sqrt(clifford(\"2{-1}\"))\n 1+{-1}\n >>> j=sqrt(-1,complexifier(index_set({1}))); print j; print j*j\n {1,2,3}\n -1\n >>> j=sqrt(-1,\"{1,2,3}\"); print j; print j*j\n {1,2,3}\n -1\n ";
13166  static PyObject *__pyx_pw_8PyClical_45sqrt(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
13167  PyObject *__pyx_v_obj = 0;
13168  PyObject *__pyx_v_i = 0;
13169  int __pyx_lineno = 0;
13170  const char *__pyx_filename = NULL;
13171  int __pyx_clineno = 0;
13172  PyObject *__pyx_r = 0;
13173  __Pyx_RefNannyDeclarations
13174  __Pyx_RefNannySetupContext("sqrt (wrapper)", 0);
13175  {
13176  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_obj,&__pyx_n_s_i,0};
13177  PyObject* values[2] = {0,0};
13178  values[1] = ((PyObject *)Py_None);
13179  if (unlikely(__pyx_kwds)) {
13180  Py_ssize_t kw_args;
13181  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
13182  switch (pos_args) {
13183  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
13184  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
13185  case 0: break;
13186  default: goto __pyx_L5_argtuple_error;
13187  }
13188  kw_args = PyDict_Size(__pyx_kwds);
13189  switch (pos_args) {
13190  case 0:
13191  if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_obj)) != 0)) kw_args--;
13192  else goto __pyx_L5_argtuple_error;
13193  case 1:
13194  if (kw_args > 0) {
13195  PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_i);
13196  if (value) { values[1] = value; kw_args--; }
13197  }
13198  }
13199  if (unlikely(kw_args > 0)) {
13200  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "sqrt") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1542; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
13201  }
13202  } else {
13203  switch (PyTuple_GET_SIZE(__pyx_args)) {
13204  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
13205  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
13206  break;
13207  default: goto __pyx_L5_argtuple_error;
13208  }
13209  }
13210  __pyx_v_obj = values[0];
13211  __pyx_v_i = values[1];
13212  }
13213  goto __pyx_L4_argument_unpacking_done;
13214  __pyx_L5_argtuple_error:;
13215  __Pyx_RaiseArgtupleInvalid("sqrt", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1542; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
13216  __pyx_L3_error:;
13217  __Pyx_AddTraceback("PyClical.sqrt", __pyx_clineno, __pyx_lineno, __pyx_filename);
13218  __Pyx_RefNannyFinishContext();
13219  return NULL;
13220  __pyx_L4_argument_unpacking_done:;
13221  __pyx_r = __pyx_pf_8PyClical_44sqrt(__pyx_self, __pyx_v_obj, __pyx_v_i);
13222 
13223  /* function exit code */
13224  __Pyx_RefNannyFinishContext();
13225  return __pyx_r;
13226  }
13227 
13228  static PyObject *__pyx_pf_8PyClical_44sqrt(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_i) {
13229  PyObject *__pyx_r = NULL;
13230  __Pyx_RefNannyDeclarations
13231  PyObject *__pyx_t_1 = NULL;
13232  struct __pyx_opt_args_8PyClical_sqrt __pyx_t_2;
13233  int __pyx_lineno = 0;
13234  const char *__pyx_filename = NULL;
13235  int __pyx_clineno = 0;
13236  __Pyx_RefNannySetupContext("sqrt", 0);
13237  __Pyx_XDECREF(__pyx_r);
13238  __pyx_t_2.__pyx_n = 1;
13239  __pyx_t_2.i = __pyx_v_i;
13240  __pyx_t_1 = __pyx_f_8PyClical_sqrt(__pyx_v_obj, 0, &__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1542; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
13241  __Pyx_GOTREF(__pyx_t_1);
13242  __pyx_r = __pyx_t_1;
13243  __pyx_t_1 = 0;
13244  goto __pyx_L0;
13245 
13246  /* function exit code */
13247  __pyx_L1_error:;
13248  __Pyx_XDECREF(__pyx_t_1);
13249  __Pyx_AddTraceback("PyClical.sqrt", __pyx_clineno, __pyx_lineno, __pyx_filename);
13250  __pyx_r = NULL;
13251  __pyx_L0:;
13252  __Pyx_XGIVEREF(__pyx_r);
13253  __Pyx_RefNannyFinishContext();
13254  return __pyx_r;
13255  }
13256 
13257  /* "PyClical.pyx":1565
13258  * return clifford().wrap( glucat.sqrt(toClifford(obj)) )
13259  *
13260  * cpdef inline exp(obj): # <<<<<<<<<<<<<<
13261  * """
13262  * Exponential of multivector.
13263  */
13264 
13265  static PyObject *__pyx_pw_8PyClical_47exp(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
13266  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_exp(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
13267  PyObject *__pyx_r = NULL;
13268  __Pyx_RefNannyDeclarations
13269  PyObject *__pyx_t_1 = NULL;
13270  PyObject *__pyx_t_2 = NULL;
13271  PyObject *__pyx_t_3 = NULL;
13272  PyObject *__pyx_t_4 = NULL;
13273  PyObject *__pyx_t_5 = NULL;
13274  PyObject *__pyx_t_6 = NULL;
13275  PyObject *__pyx_t_7 = NULL;
13276  PyObject *__pyx_t_8 = NULL;
13277  int __pyx_lineno = 0;
13278  const char *__pyx_filename = NULL;
13279  int __pyx_clineno = 0;
13280  __Pyx_RefNannySetupContext("exp", 0);
13281 
13282  /* "PyClical.pyx":1574
13283  * {1,2}
13284  * """
13285  * try: # <<<<<<<<<<<<<<
13286  * return math.exp(obj)
13287  * except:
13288  */
13289  {
13290  __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3);
13291  __Pyx_XGOTREF(__pyx_t_1);
13292  __Pyx_XGOTREF(__pyx_t_2);
13293  __Pyx_XGOTREF(__pyx_t_3);
13294  /*try:*/ {
13295 
13296  /* "PyClical.pyx":1575
13297  * """
13298  * try:
13299  * return math.exp(obj) # <<<<<<<<<<<<<<
13300  * except:
13301  * return clifford().wrap( glucat.exp(toClifford(obj)) )
13302  */
13303  __Pyx_XDECREF(__pyx_r);
13304  __pyx_t_5 = __Pyx_GetModuleGlobalName(__pyx_n_s_math); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1575; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
13305  __Pyx_GOTREF(__pyx_t_5);
13306  __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_exp); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1575; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
13307  __Pyx_GOTREF(__pyx_t_6);
13308  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
13309  __pyx_t_5 = NULL;
13310  if (CYTHON_COMPILING_IN_CPYTHON && unlikely(PyMethod_Check(__pyx_t_6))) {
13311  __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_6);
13312  if (likely(__pyx_t_5)) {
13313  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6);
13314  __Pyx_INCREF(__pyx_t_5);
13315  __Pyx_INCREF(function);
13316  __Pyx_DECREF_SET(__pyx_t_6, function);
13317  }
13318  }
13319  if (!__pyx_t_5) {
13320  __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_obj); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1575; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
13321  __Pyx_GOTREF(__pyx_t_4);
13322  } else {
13323  __pyx_t_7 = PyTuple_New(1+1); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1575; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
13324  __Pyx_GOTREF(__pyx_t_7);
13325  __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_5); __pyx_t_5 = NULL;
13326  __Pyx_INCREF(__pyx_v_obj);
13327  __Pyx_GIVEREF(__pyx_v_obj);
13328  PyTuple_SET_ITEM(__pyx_t_7, 0+1, __pyx_v_obj);
13329  __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_7, NULL); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1575; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
13330  __Pyx_GOTREF(__pyx_t_4);
13331  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
13332  }
13333  __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
13334  __pyx_r = __pyx_t_4;
13335  __pyx_t_4 = 0;
13336  goto __pyx_L7_try_return;
13337 
13338  /* "PyClical.pyx":1574
13339  * {1,2}
13340  * """
13341  * try: # <<<<<<<<<<<<<<
13342  * return math.exp(obj)
13343  * except:
13344  */
13345  }
13346  __pyx_L3_error:;
13347  __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
13348  __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
13349  __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
13350  __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
13351 
13352  /* "PyClical.pyx":1576
13353  * try:
13354  * return math.exp(obj)
13355  * except: # <<<<<<<<<<<<<<
13356  * return clifford().wrap( glucat.exp(toClifford(obj)) )
13357  *
13358  */
13359  /*except:*/ {
13360  __Pyx_AddTraceback("PyClical.exp", __pyx_clineno, __pyx_lineno, __pyx_filename);
13361  if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_7) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1576; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
13362  __Pyx_GOTREF(__pyx_t_4);
13363  __Pyx_GOTREF(__pyx_t_6);
13364  __Pyx_GOTREF(__pyx_t_7);
13365 
13366  /* "PyClical.pyx":1577
13367  * return math.exp(obj)
13368  * except:
13369  * return clifford().wrap( glucat.exp(toClifford(obj)) ) # <<<<<<<<<<<<<<
13370  *
13371  * cpdef inline log(obj,i = None):
13372  */
13373  __Pyx_XDECREF(__pyx_r);
13374  __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1577; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
13375  __Pyx_GOTREF(__pyx_t_5);
13376  __pyx_t_8 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_5), exp(__pyx_f_8PyClical_toClifford(__pyx_v_obj))); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1577; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
13377  __Pyx_GOTREF(__pyx_t_8);
13378  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
13379  __pyx_r = __pyx_t_8;
13380  __pyx_t_8 = 0;
13381  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
13382  __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
13383  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
13384  goto __pyx_L6_except_return;
13385  }
13386  __pyx_L5_except_error:;
13387 
13388  /* "PyClical.pyx":1574
13389  * {1,2}
13390  * """
13391  * try: # <<<<<<<<<<<<<<
13392  * return math.exp(obj)
13393  * except:
13394  */
13395  __Pyx_XGIVEREF(__pyx_t_1);
13396  __Pyx_XGIVEREF(__pyx_t_2);
13397  __Pyx_XGIVEREF(__pyx_t_3);
13398  __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
13399  goto __pyx_L1_error;
13400  __pyx_L7_try_return:;
13401  __Pyx_XGIVEREF(__pyx_t_1);
13402  __Pyx_XGIVEREF(__pyx_t_2);
13403  __Pyx_XGIVEREF(__pyx_t_3);
13404  __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
13405  goto __pyx_L0;
13406  __pyx_L6_except_return:;
13407  __Pyx_XGIVEREF(__pyx_t_1);
13408  __Pyx_XGIVEREF(__pyx_t_2);
13409  __Pyx_XGIVEREF(__pyx_t_3);
13410  __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
13411  goto __pyx_L0;
13412  }
13413 
13414  /* "PyClical.pyx":1565
13415  * return clifford().wrap( glucat.sqrt(toClifford(obj)) )
13416  *
13417  * cpdef inline exp(obj): # <<<<<<<<<<<<<<
13418  * """
13419  * Exponential of multivector.
13420  */
13421 
13422  /* function exit code */
13423  __pyx_L1_error:;
13424  __Pyx_XDECREF(__pyx_t_4);
13425  __Pyx_XDECREF(__pyx_t_5);
13426  __Pyx_XDECREF(__pyx_t_6);
13427  __Pyx_XDECREF(__pyx_t_7);
13428  __Pyx_XDECREF(__pyx_t_8);
13429  __Pyx_AddTraceback("PyClical.exp", __pyx_clineno, __pyx_lineno, __pyx_filename);
13430  __pyx_r = 0;
13431  __pyx_L0:;
13432  __Pyx_XGIVEREF(__pyx_r);
13433  __Pyx_RefNannyFinishContext();
13434  return __pyx_r;
13435  }
13436 
13437  /* Python wrapper */
13438  static PyObject *__pyx_pw_8PyClical_47exp(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
13439  static char __pyx_doc_8PyClical_46exp[] = "\n Exponential of multivector.\n\n >>> x=clifford(\"{1,2}\") * pi/4; print exp(x)\n 0.7071+0.7071{1,2}\n >>> x=clifford(\"{1,2}\") * pi/2; print exp(x)\n {1,2}\n ";
13440  static PyObject *__pyx_pw_8PyClical_47exp(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
13441  PyObject *__pyx_r = 0;
13442  __Pyx_RefNannyDeclarations
13443  __Pyx_RefNannySetupContext("exp (wrapper)", 0);
13444  __pyx_r = __pyx_pf_8PyClical_46exp(__pyx_self, ((PyObject *)__pyx_v_obj));
13445 
13446  /* function exit code */
13447  __Pyx_RefNannyFinishContext();
13448  return __pyx_r;
13449  }
13450 
13451  static PyObject *__pyx_pf_8PyClical_46exp(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
13452  PyObject *__pyx_r = NULL;
13453  __Pyx_RefNannyDeclarations
13454  PyObject *__pyx_t_1 = NULL;
13455  int __pyx_lineno = 0;
13456  const char *__pyx_filename = NULL;
13457  int __pyx_clineno = 0;
13458  __Pyx_RefNannySetupContext("exp", 0);
13459  __Pyx_XDECREF(__pyx_r);
13460  __pyx_t_1 = __pyx_f_8PyClical_exp(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1565; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
13461  __Pyx_GOTREF(__pyx_t_1);
13462  __pyx_r = __pyx_t_1;
13463  __pyx_t_1 = 0;
13464  goto __pyx_L0;
13465 
13466  /* function exit code */
13467  __pyx_L1_error:;
13468  __Pyx_XDECREF(__pyx_t_1);
13469  __Pyx_AddTraceback("PyClical.exp", __pyx_clineno, __pyx_lineno, __pyx_filename);
13470  __pyx_r = NULL;
13471  __pyx_L0:;
13472  __Pyx_XGIVEREF(__pyx_r);
13473  __Pyx_RefNannyFinishContext();
13474  return __pyx_r;
13475  }
13476 
13477  /* "PyClical.pyx":1579
13478  * return clifford().wrap( glucat.exp(toClifford(obj)) )
13479  *
13480  * cpdef inline log(obj,i = None): # <<<<<<<<<<<<<<
13481  * """
13482  * Natural logarithm of multivector with optional complexifier.
13483  */
13484 
13485  static PyObject *__pyx_pw_8PyClical_49log(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
13486  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_log(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_log *__pyx_optional_args) {
13487  PyObject *__pyx_v_i = ((PyObject *)Py_None);
13488  PyObject *__pyx_r = NULL;
13489  __Pyx_RefNannyDeclarations
13490  int __pyx_t_1;
13491  int __pyx_t_2;
13492  PyObject *__pyx_t_3 = NULL;
13493  Clifford __pyx_t_4;
13494  PyObject *__pyx_t_5 = NULL;
13495  PyObject *__pyx_t_6 = NULL;
13496  PyObject *__pyx_t_7 = NULL;
13497  PyObject *__pyx_t_8 = NULL;
13498  PyObject *__pyx_t_9 = NULL;
13499  PyObject *__pyx_t_10 = NULL;
13500  PyObject *__pyx_t_11 = NULL;
13501  int __pyx_lineno = 0;
13502  const char *__pyx_filename = NULL;
13503  int __pyx_clineno = 0;
13504  __Pyx_RefNannySetupContext("log", 0);
13505  if (__pyx_optional_args) {
13506  if (__pyx_optional_args->__pyx_n > 0) {
13507  __pyx_v_i = __pyx_optional_args->i;
13508  }
13509  }
13510 
13511  /* "PyClical.pyx":1594
13512  * RuntimeError: check_complex(val, i): i is not a valid complexifier for val
13513  * """
13514  * if not (i is None): # <<<<<<<<<<<<<<
13515  * return clifford().wrap( glucat.log(toClifford(obj), toClifford(i)) )
13516  * else:
13517  */
13518  __pyx_t_1 = (__pyx_v_i != Py_None);
13519  __pyx_t_2 = (__pyx_t_1 != 0);
13520  if (__pyx_t_2) {
13521 
13522  /* "PyClical.pyx":1595
13523  * """
13524  * if not (i is None):
13525  * return clifford().wrap( glucat.log(toClifford(obj), toClifford(i)) ) # <<<<<<<<<<<<<<
13526  * else:
13527  * try:
13528  */
13529  __Pyx_XDECREF(__pyx_r);
13530  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1595; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
13531  __Pyx_GOTREF(__pyx_t_3);
13532  try {
13533  __pyx_t_4 = log(__pyx_f_8PyClical_toClifford(__pyx_v_obj), __pyx_f_8PyClical_toClifford(__pyx_v_i));
13534  } catch(...) {
13535  __Pyx_CppExn2PyErr();
13536  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1595; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
13537  }
13538  __pyx_t_5 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_3), __pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1595; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
13539  __Pyx_GOTREF(__pyx_t_5);
13540  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
13541  __pyx_r = __pyx_t_5;
13542  __pyx_t_5 = 0;
13543  goto __pyx_L0;
13544 
13545  /* "PyClical.pyx":1594
13546  * RuntimeError: check_complex(val, i): i is not a valid complexifier for val
13547  * """
13548  * if not (i is None): # <<<<<<<<<<<<<<
13549  * return clifford().wrap( glucat.log(toClifford(obj), toClifford(i)) )
13550  * else:
13551  */
13552  }
13553 
13554  /* "PyClical.pyx":1597
13555  * return clifford().wrap( glucat.log(toClifford(obj), toClifford(i)) )
13556  * else:
13557  * try: # <<<<<<<<<<<<<<
13558  * return math.log(obj)
13559  * except:
13560  */
13561  /*else*/ {
13562  {
13563  __Pyx_ExceptionSave(&__pyx_t_6, &__pyx_t_7, &__pyx_t_8);
13564  __Pyx_XGOTREF(__pyx_t_6);
13565  __Pyx_XGOTREF(__pyx_t_7);
13566  __Pyx_XGOTREF(__pyx_t_8);
13567  /*try:*/ {
13568 
13569  /* "PyClical.pyx":1598
13570  * else:
13571  * try:
13572  * return math.log(obj) # <<<<<<<<<<<<<<
13573  * except:
13574  * return clifford().wrap( glucat.log(toClifford(obj)) )
13575  */
13576  __Pyx_XDECREF(__pyx_r);
13577  __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_math); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1598; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
13578  __Pyx_GOTREF(__pyx_t_3);
13579  __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_log); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1598; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
13580  __Pyx_GOTREF(__pyx_t_9);
13581  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
13582  __pyx_t_3 = NULL;
13583  if (CYTHON_COMPILING_IN_CPYTHON && unlikely(PyMethod_Check(__pyx_t_9))) {
13584  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_9);
13585  if (likely(__pyx_t_3)) {
13586  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_9);
13587  __Pyx_INCREF(__pyx_t_3);
13588  __Pyx_INCREF(function);
13589  __Pyx_DECREF_SET(__pyx_t_9, function);
13590  }
13591  }
13592  if (!__pyx_t_3) {
13593  __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_t_9, __pyx_v_obj); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1598; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
13594  __Pyx_GOTREF(__pyx_t_5);
13595  } else {
13596  __pyx_t_10 = PyTuple_New(1+1); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1598; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
13597  __Pyx_GOTREF(__pyx_t_10);
13598  __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_3); __pyx_t_3 = NULL;
13599  __Pyx_INCREF(__pyx_v_obj);
13600  __Pyx_GIVEREF(__pyx_v_obj);
13601  PyTuple_SET_ITEM(__pyx_t_10, 0+1, __pyx_v_obj);
13602  __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1598; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
13603  __Pyx_GOTREF(__pyx_t_5);
13604  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
13605  }
13606  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
13607  __pyx_r = __pyx_t_5;
13608  __pyx_t_5 = 0;
13609  goto __pyx_L8_try_return;
13610 
13611  /* "PyClical.pyx":1597
13612  * return clifford().wrap( glucat.log(toClifford(obj), toClifford(i)) )
13613  * else:
13614  * try: # <<<<<<<<<<<<<<
13615  * return math.log(obj)
13616  * except:
13617  */
13618  }
13619  __pyx_L4_error:;
13620  __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
13621  __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0;
13622  __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
13623  __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
13624 
13625  /* "PyClical.pyx":1599
13626  * try:
13627  * return math.log(obj)
13628  * except: # <<<<<<<<<<<<<<
13629  * return clifford().wrap( glucat.log(toClifford(obj)) )
13630  *
13631  */
13632  /*except:*/ {
13633  __Pyx_AddTraceback("PyClical.log", __pyx_clineno, __pyx_lineno, __pyx_filename);
13634  if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_9, &__pyx_t_10) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1599; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
13635  __Pyx_GOTREF(__pyx_t_5);
13636  __Pyx_GOTREF(__pyx_t_9);
13637  __Pyx_GOTREF(__pyx_t_10);
13638 
13639  /* "PyClical.pyx":1600
13640  * return math.log(obj)
13641  * except:
13642  * return clifford().wrap( glucat.log(toClifford(obj)) ) # <<<<<<<<<<<<<<
13643  *
13644  * cpdef inline cos(obj,i = None):
13645  */
13646  __Pyx_XDECREF(__pyx_r);
13647  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1600; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
13648  __Pyx_GOTREF(__pyx_t_3);
13649  __pyx_t_11 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_3), log(__pyx_f_8PyClical_toClifford(__pyx_v_obj))); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1600; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
13650  __Pyx_GOTREF(__pyx_t_11);
13651  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
13652  __pyx_r = __pyx_t_11;
13653  __pyx_t_11 = 0;
13654  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
13655  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
13656  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
13657  goto __pyx_L7_except_return;
13658  }
13659  __pyx_L6_except_error:;
13660 
13661  /* "PyClical.pyx":1597
13662  * return clifford().wrap( glucat.log(toClifford(obj), toClifford(i)) )
13663  * else:
13664  * try: # <<<<<<<<<<<<<<
13665  * return math.log(obj)
13666  * except:
13667  */
13668  __Pyx_XGIVEREF(__pyx_t_6);
13669  __Pyx_XGIVEREF(__pyx_t_7);
13670  __Pyx_XGIVEREF(__pyx_t_8);
13671  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
13672  goto __pyx_L1_error;
13673  __pyx_L8_try_return:;
13674  __Pyx_XGIVEREF(__pyx_t_6);
13675  __Pyx_XGIVEREF(__pyx_t_7);
13676  __Pyx_XGIVEREF(__pyx_t_8);
13677  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
13678  goto __pyx_L0;
13679  __pyx_L7_except_return:;
13680  __Pyx_XGIVEREF(__pyx_t_6);
13681  __Pyx_XGIVEREF(__pyx_t_7);
13682  __Pyx_XGIVEREF(__pyx_t_8);
13683  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
13684  goto __pyx_L0;
13685  }
13686  }
13687 
13688  /* "PyClical.pyx":1579
13689  * return clifford().wrap( glucat.exp(toClifford(obj)) )
13690  *
13691  * cpdef inline log(obj,i = None): # <<<<<<<<<<<<<<
13692  * """
13693  * Natural logarithm of multivector with optional complexifier.
13694  */
13695 
13696  /* function exit code */
13697  __pyx_L1_error:;
13698  __Pyx_XDECREF(__pyx_t_3);
13699  __Pyx_XDECREF(__pyx_t_5);
13700  __Pyx_XDECREF(__pyx_t_9);
13701  __Pyx_XDECREF(__pyx_t_10);
13702  __Pyx_XDECREF(__pyx_t_11);
13703  __Pyx_AddTraceback("PyClical.log", __pyx_clineno, __pyx_lineno, __pyx_filename);
13704  __pyx_r = 0;
13705  __pyx_L0:;
13706  __Pyx_XGIVEREF(__pyx_r);
13707  __Pyx_RefNannyFinishContext();
13708  return __pyx_r;
13709  }
13710 
13711  /* Python wrapper */
13712  static PyObject *__pyx_pw_8PyClical_49log(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
13713  static char __pyx_doc_8PyClical_48log[] = "\n Natural logarithm of multivector with optional complexifier.\n\n >>> x=clifford(\"{-1}\"); print (log(x,\"{-1}\") * 2/pi)\n {-1}\n >>> x=clifford(\"{1,2}\"); print (log(x,\"{1,2,3}\") * 2/pi)\n {1,2}\n >>> x=clifford(\"{1,2}\"); print (log(x) * 2/pi)\n {1,2}\n >>> x=clifford(\"{1,2}\"); print (log(x,\"{1,2}\") * 2/pi)\n Traceback (most recent call last):\n ...\n RuntimeError: check_complex(val, i): i is not a valid complexifier for val\n ";
13714  static PyObject *__pyx_pw_8PyClical_49log(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
13715  PyObject *__pyx_v_obj = 0;
13716  PyObject *__pyx_v_i = 0;
13717  int __pyx_lineno = 0;
13718  const char *__pyx_filename = NULL;
13719  int __pyx_clineno = 0;
13720  PyObject *__pyx_r = 0;
13721  __Pyx_RefNannyDeclarations
13722  __Pyx_RefNannySetupContext("log (wrapper)", 0);
13723  {
13724  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_obj,&__pyx_n_s_i,0};
13725  PyObject* values[2] = {0,0};
13726  values[1] = ((PyObject *)Py_None);
13727  if (unlikely(__pyx_kwds)) {
13728  Py_ssize_t kw_args;
13729  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
13730  switch (pos_args) {
13731  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
13732  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
13733  case 0: break;
13734  default: goto __pyx_L5_argtuple_error;
13735  }
13736  kw_args = PyDict_Size(__pyx_kwds);
13737  switch (pos_args) {
13738  case 0:
13739  if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_obj)) != 0)) kw_args--;
13740  else goto __pyx_L5_argtuple_error;
13741  case 1:
13742  if (kw_args > 0) {
13743  PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_i);
13744  if (value) { values[1] = value; kw_args--; }
13745  }
13746  }
13747  if (unlikely(kw_args > 0)) {
13748  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "log") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1579; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
13749  }
13750  } else {
13751  switch (PyTuple_GET_SIZE(__pyx_args)) {
13752  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
13753  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
13754  break;
13755  default: goto __pyx_L5_argtuple_error;
13756  }
13757  }
13758  __pyx_v_obj = values[0];
13759  __pyx_v_i = values[1];
13760  }
13761  goto __pyx_L4_argument_unpacking_done;
13762  __pyx_L5_argtuple_error:;
13763  __Pyx_RaiseArgtupleInvalid("log", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1579; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
13764  __pyx_L3_error:;
13765  __Pyx_AddTraceback("PyClical.log", __pyx_clineno, __pyx_lineno, __pyx_filename);
13766  __Pyx_RefNannyFinishContext();
13767  return NULL;
13768  __pyx_L4_argument_unpacking_done:;
13769  __pyx_r = __pyx_pf_8PyClical_48log(__pyx_self, __pyx_v_obj, __pyx_v_i);
13770 
13771  /* function exit code */
13772  __Pyx_RefNannyFinishContext();
13773  return __pyx_r;
13774  }
13775 
13776  static PyObject *__pyx_pf_8PyClical_48log(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_i) {
13777  PyObject *__pyx_r = NULL;
13778  __Pyx_RefNannyDeclarations
13779  PyObject *__pyx_t_1 = NULL;
13780  struct __pyx_opt_args_8PyClical_log __pyx_t_2;
13781  int __pyx_lineno = 0;
13782  const char *__pyx_filename = NULL;
13783  int __pyx_clineno = 0;
13784  __Pyx_RefNannySetupContext("log", 0);
13785  __Pyx_XDECREF(__pyx_r);
13786  __pyx_t_2.__pyx_n = 1;
13787  __pyx_t_2.i = __pyx_v_i;
13788  __pyx_t_1 = __pyx_f_8PyClical_log(__pyx_v_obj, 0, &__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1579; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
13789  __Pyx_GOTREF(__pyx_t_1);
13790  __pyx_r = __pyx_t_1;
13791  __pyx_t_1 = 0;
13792  goto __pyx_L0;
13793 
13794  /* function exit code */
13795  __pyx_L1_error:;
13796  __Pyx_XDECREF(__pyx_t_1);
13797  __Pyx_AddTraceback("PyClical.log", __pyx_clineno, __pyx_lineno, __pyx_filename);
13798  __pyx_r = NULL;
13799  __pyx_L0:;
13800  __Pyx_XGIVEREF(__pyx_r);
13801  __Pyx_RefNannyFinishContext();
13802  return __pyx_r;
13803  }
13804 
13805  /* "PyClical.pyx":1602
13806  * return clifford().wrap( glucat.log(toClifford(obj)) )
13807  *
13808  * cpdef inline cos(obj,i = None): # <<<<<<<<<<<<<<
13809  * """
13810  * Cosine of multivector with optional complexifier.
13811  */
13812 
13813  static PyObject *__pyx_pw_8PyClical_51cos(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
13814  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_cos(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_cos *__pyx_optional_args) {
13815  PyObject *__pyx_v_i = ((PyObject *)Py_None);
13816  PyObject *__pyx_r = NULL;
13817  __Pyx_RefNannyDeclarations
13818  int __pyx_t_1;
13819  int __pyx_t_2;
13820  PyObject *__pyx_t_3 = NULL;
13821  Clifford __pyx_t_4;
13822  PyObject *__pyx_t_5 = NULL;
13823  PyObject *__pyx_t_6 = NULL;
13824  PyObject *__pyx_t_7 = NULL;
13825  PyObject *__pyx_t_8 = NULL;
13826  PyObject *__pyx_t_9 = NULL;
13827  PyObject *__pyx_t_10 = NULL;
13828  PyObject *__pyx_t_11 = NULL;
13829  int __pyx_lineno = 0;
13830  const char *__pyx_filename = NULL;
13831  int __pyx_clineno = 0;
13832  __Pyx_RefNannySetupContext("cos", 0);
13833  if (__pyx_optional_args) {
13834  if (__pyx_optional_args->__pyx_n > 0) {
13835  __pyx_v_i = __pyx_optional_args->i;
13836  }
13837  }
13838 
13839  /* "PyClical.pyx":1611
13840  * {1,2}
13841  * """
13842  * if not (i is None): # <<<<<<<<<<<<<<
13843  * return clifford().wrap( glucat.cos(toClifford(obj), toClifford(i)) )
13844  * else:
13845  */
13846  __pyx_t_1 = (__pyx_v_i != Py_None);
13847  __pyx_t_2 = (__pyx_t_1 != 0);
13848  if (__pyx_t_2) {
13849 
13850  /* "PyClical.pyx":1612
13851  * """
13852  * if not (i is None):
13853  * return clifford().wrap( glucat.cos(toClifford(obj), toClifford(i)) ) # <<<<<<<<<<<<<<
13854  * else:
13855  * try:
13856  */
13857  __Pyx_XDECREF(__pyx_r);
13858  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1612; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
13859  __Pyx_GOTREF(__pyx_t_3);
13860  try {
13861  __pyx_t_4 = cos(__pyx_f_8PyClical_toClifford(__pyx_v_obj), __pyx_f_8PyClical_toClifford(__pyx_v_i));
13862  } catch(...) {
13863  __Pyx_CppExn2PyErr();
13864  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1612; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
13865  }
13866  __pyx_t_5 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_3), __pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1612; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
13867  __Pyx_GOTREF(__pyx_t_5);
13868  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
13869  __pyx_r = __pyx_t_5;
13870  __pyx_t_5 = 0;
13871  goto __pyx_L0;
13872 
13873  /* "PyClical.pyx":1611
13874  * {1,2}
13875  * """
13876  * if not (i is None): # <<<<<<<<<<<<<<
13877  * return clifford().wrap( glucat.cos(toClifford(obj), toClifford(i)) )
13878  * else:
13879  */
13880  }
13881 
13882  /* "PyClical.pyx":1614
13883  * return clifford().wrap( glucat.cos(toClifford(obj), toClifford(i)) )
13884  * else:
13885  * try: # <<<<<<<<<<<<<<
13886  * return math.cos(obj)
13887  * except:
13888  */
13889  /*else*/ {
13890  {
13891  __Pyx_ExceptionSave(&__pyx_t_6, &__pyx_t_7, &__pyx_t_8);
13892  __Pyx_XGOTREF(__pyx_t_6);
13893  __Pyx_XGOTREF(__pyx_t_7);
13894  __Pyx_XGOTREF(__pyx_t_8);
13895  /*try:*/ {
13896 
13897  /* "PyClical.pyx":1615
13898  * else:
13899  * try:
13900  * return math.cos(obj) # <<<<<<<<<<<<<<
13901  * except:
13902  * return clifford().wrap( glucat.cos(toClifford(obj)) )
13903  */
13904  __Pyx_XDECREF(__pyx_r);
13905  __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_math); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1615; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
13906  __Pyx_GOTREF(__pyx_t_3);
13907  __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_cos); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1615; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
13908  __Pyx_GOTREF(__pyx_t_9);
13909  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
13910  __pyx_t_3 = NULL;
13911  if (CYTHON_COMPILING_IN_CPYTHON && unlikely(PyMethod_Check(__pyx_t_9))) {
13912  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_9);
13913  if (likely(__pyx_t_3)) {
13914  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_9);
13915  __Pyx_INCREF(__pyx_t_3);
13916  __Pyx_INCREF(function);
13917  __Pyx_DECREF_SET(__pyx_t_9, function);
13918  }
13919  }
13920  if (!__pyx_t_3) {
13921  __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_t_9, __pyx_v_obj); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1615; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
13922  __Pyx_GOTREF(__pyx_t_5);
13923  } else {
13924  __pyx_t_10 = PyTuple_New(1+1); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1615; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
13925  __Pyx_GOTREF(__pyx_t_10);
13926  __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_3); __pyx_t_3 = NULL;
13927  __Pyx_INCREF(__pyx_v_obj);
13928  __Pyx_GIVEREF(__pyx_v_obj);
13929  PyTuple_SET_ITEM(__pyx_t_10, 0+1, __pyx_v_obj);
13930  __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1615; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
13931  __Pyx_GOTREF(__pyx_t_5);
13932  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
13933  }
13934  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
13935  __pyx_r = __pyx_t_5;
13936  __pyx_t_5 = 0;
13937  goto __pyx_L8_try_return;
13938 
13939  /* "PyClical.pyx":1614
13940  * return clifford().wrap( glucat.cos(toClifford(obj), toClifford(i)) )
13941  * else:
13942  * try: # <<<<<<<<<<<<<<
13943  * return math.cos(obj)
13944  * except:
13945  */
13946  }
13947  __pyx_L4_error:;
13948  __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
13949  __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0;
13950  __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
13951  __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
13952 
13953  /* "PyClical.pyx":1616
13954  * try:
13955  * return math.cos(obj)
13956  * except: # <<<<<<<<<<<<<<
13957  * return clifford().wrap( glucat.cos(toClifford(obj)) )
13958  *
13959  */
13960  /*except:*/ {
13961  __Pyx_AddTraceback("PyClical.cos", __pyx_clineno, __pyx_lineno, __pyx_filename);
13962  if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_9, &__pyx_t_10) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1616; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
13963  __Pyx_GOTREF(__pyx_t_5);
13964  __Pyx_GOTREF(__pyx_t_9);
13965  __Pyx_GOTREF(__pyx_t_10);
13966 
13967  /* "PyClical.pyx":1617
13968  * return math.cos(obj)
13969  * except:
13970  * return clifford().wrap( glucat.cos(toClifford(obj)) ) # <<<<<<<<<<<<<<
13971  *
13972  * cpdef inline acos(obj,i = None):
13973  */
13974  __Pyx_XDECREF(__pyx_r);
13975  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1617; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
13976  __Pyx_GOTREF(__pyx_t_3);
13977  __pyx_t_11 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_3), cos(__pyx_f_8PyClical_toClifford(__pyx_v_obj))); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1617; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
13978  __Pyx_GOTREF(__pyx_t_11);
13979  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
13980  __pyx_r = __pyx_t_11;
13981  __pyx_t_11 = 0;
13982  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
13983  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
13984  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
13985  goto __pyx_L7_except_return;
13986  }
13987  __pyx_L6_except_error:;
13988 
13989  /* "PyClical.pyx":1614
13990  * return clifford().wrap( glucat.cos(toClifford(obj), toClifford(i)) )
13991  * else:
13992  * try: # <<<<<<<<<<<<<<
13993  * return math.cos(obj)
13994  * except:
13995  */
13996  __Pyx_XGIVEREF(__pyx_t_6);
13997  __Pyx_XGIVEREF(__pyx_t_7);
13998  __Pyx_XGIVEREF(__pyx_t_8);
13999  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
14000  goto __pyx_L1_error;
14001  __pyx_L8_try_return:;
14002  __Pyx_XGIVEREF(__pyx_t_6);
14003  __Pyx_XGIVEREF(__pyx_t_7);
14004  __Pyx_XGIVEREF(__pyx_t_8);
14005  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
14006  goto __pyx_L0;
14007  __pyx_L7_except_return:;
14008  __Pyx_XGIVEREF(__pyx_t_6);
14009  __Pyx_XGIVEREF(__pyx_t_7);
14010  __Pyx_XGIVEREF(__pyx_t_8);
14011  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
14012  goto __pyx_L0;
14013  }
14014  }
14015 
14016  /* "PyClical.pyx":1602
14017  * return clifford().wrap( glucat.log(toClifford(obj)) )
14018  *
14019  * cpdef inline cos(obj,i = None): # <<<<<<<<<<<<<<
14020  * """
14021  * Cosine of multivector with optional complexifier.
14022  */
14023 
14024  /* function exit code */
14025  __pyx_L1_error:;
14026  __Pyx_XDECREF(__pyx_t_3);
14027  __Pyx_XDECREF(__pyx_t_5);
14028  __Pyx_XDECREF(__pyx_t_9);
14029  __Pyx_XDECREF(__pyx_t_10);
14030  __Pyx_XDECREF(__pyx_t_11);
14031  __Pyx_AddTraceback("PyClical.cos", __pyx_clineno, __pyx_lineno, __pyx_filename);
14032  __pyx_r = 0;
14033  __pyx_L0:;
14034  __Pyx_XGIVEREF(__pyx_r);
14035  __Pyx_RefNannyFinishContext();
14036  return __pyx_r;
14037  }
14038 
14039  /* Python wrapper */
14040  static PyObject *__pyx_pw_8PyClical_51cos(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
14041  static char __pyx_doc_8PyClical_50cos[] = "\n Cosine of multivector with optional complexifier.\n\n >>> x=clifford(\"{1,2}\"); print cos(acos(x),\"{1,2,3}\")\n {1,2}\n >>> x=clifford(\"{1,2}\"); print cos(acos(x))\n {1,2}\n ";
14042  static PyObject *__pyx_pw_8PyClical_51cos(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
14043  PyObject *__pyx_v_obj = 0;
14044  PyObject *__pyx_v_i = 0;
14045  int __pyx_lineno = 0;
14046  const char *__pyx_filename = NULL;
14047  int __pyx_clineno = 0;
14048  PyObject *__pyx_r = 0;
14049  __Pyx_RefNannyDeclarations
14050  __Pyx_RefNannySetupContext("cos (wrapper)", 0);
14051  {
14052  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_obj,&__pyx_n_s_i,0};
14053  PyObject* values[2] = {0,0};
14054  values[1] = ((PyObject *)Py_None);
14055  if (unlikely(__pyx_kwds)) {
14056  Py_ssize_t kw_args;
14057  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
14058  switch (pos_args) {
14059  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
14060  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
14061  case 0: break;
14062  default: goto __pyx_L5_argtuple_error;
14063  }
14064  kw_args = PyDict_Size(__pyx_kwds);
14065  switch (pos_args) {
14066  case 0:
14067  if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_obj)) != 0)) kw_args--;
14068  else goto __pyx_L5_argtuple_error;
14069  case 1:
14070  if (kw_args > 0) {
14071  PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_i);
14072  if (value) { values[1] = value; kw_args--; }
14073  }
14074  }
14075  if (unlikely(kw_args > 0)) {
14076  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "cos") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1602; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
14077  }
14078  } else {
14079  switch (PyTuple_GET_SIZE(__pyx_args)) {
14080  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
14081  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
14082  break;
14083  default: goto __pyx_L5_argtuple_error;
14084  }
14085  }
14086  __pyx_v_obj = values[0];
14087  __pyx_v_i = values[1];
14088  }
14089  goto __pyx_L4_argument_unpacking_done;
14090  __pyx_L5_argtuple_error:;
14091  __Pyx_RaiseArgtupleInvalid("cos", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1602; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
14092  __pyx_L3_error:;
14093  __Pyx_AddTraceback("PyClical.cos", __pyx_clineno, __pyx_lineno, __pyx_filename);
14094  __Pyx_RefNannyFinishContext();
14095  return NULL;
14096  __pyx_L4_argument_unpacking_done:;
14097  __pyx_r = __pyx_pf_8PyClical_50cos(__pyx_self, __pyx_v_obj, __pyx_v_i);
14098 
14099  /* function exit code */
14100  __Pyx_RefNannyFinishContext();
14101  return __pyx_r;
14102  }
14103 
14104  static PyObject *__pyx_pf_8PyClical_50cos(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_i) {
14105  PyObject *__pyx_r = NULL;
14106  __Pyx_RefNannyDeclarations
14107  PyObject *__pyx_t_1 = NULL;
14108  struct __pyx_opt_args_8PyClical_cos __pyx_t_2;
14109  int __pyx_lineno = 0;
14110  const char *__pyx_filename = NULL;
14111  int __pyx_clineno = 0;
14112  __Pyx_RefNannySetupContext("cos", 0);
14113  __Pyx_XDECREF(__pyx_r);
14114  __pyx_t_2.__pyx_n = 1;
14115  __pyx_t_2.i = __pyx_v_i;
14116  __pyx_t_1 = __pyx_f_8PyClical_cos(__pyx_v_obj, 0, &__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1602; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
14117  __Pyx_GOTREF(__pyx_t_1);
14118  __pyx_r = __pyx_t_1;
14119  __pyx_t_1 = 0;
14120  goto __pyx_L0;
14121 
14122  /* function exit code */
14123  __pyx_L1_error:;
14124  __Pyx_XDECREF(__pyx_t_1);
14125  __Pyx_AddTraceback("PyClical.cos", __pyx_clineno, __pyx_lineno, __pyx_filename);
14126  __pyx_r = NULL;
14127  __pyx_L0:;
14128  __Pyx_XGIVEREF(__pyx_r);
14129  __Pyx_RefNannyFinishContext();
14130  return __pyx_r;
14131  }
14132 
14133  /* "PyClical.pyx":1619
14134  * return clifford().wrap( glucat.cos(toClifford(obj)) )
14135  *
14136  * cpdef inline acos(obj,i = None): # <<<<<<<<<<<<<<
14137  * """
14138  * Inverse cosine of multivector with optional complexifier.
14139  */
14140 
14141  static PyObject *__pyx_pw_8PyClical_53acos(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
14142  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_acos(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_acos *__pyx_optional_args) {
14143  PyObject *__pyx_v_i = ((PyObject *)Py_None);
14144  PyObject *__pyx_r = NULL;
14145  __Pyx_RefNannyDeclarations
14146  int __pyx_t_1;
14147  int __pyx_t_2;
14148  PyObject *__pyx_t_3 = NULL;
14149  Clifford __pyx_t_4;
14150  PyObject *__pyx_t_5 = NULL;
14151  PyObject *__pyx_t_6 = NULL;
14152  PyObject *__pyx_t_7 = NULL;
14153  PyObject *__pyx_t_8 = NULL;
14154  PyObject *__pyx_t_9 = NULL;
14155  PyObject *__pyx_t_10 = NULL;
14156  PyObject *__pyx_t_11 = NULL;
14157  int __pyx_lineno = 0;
14158  const char *__pyx_filename = NULL;
14159  int __pyx_clineno = 0;
14160  __Pyx_RefNannySetupContext("acos", 0);
14161  if (__pyx_optional_args) {
14162  if (__pyx_optional_args->__pyx_n > 0) {
14163  __pyx_v_i = __pyx_optional_args->i;
14164  }
14165  }
14166 
14167  /* "PyClical.pyx":1632
14168  * {1,2}
14169  * """
14170  * if not (i is None): # <<<<<<<<<<<<<<
14171  * return clifford().wrap( glucat.acos(toClifford(obj), toClifford(i)) )
14172  * else:
14173  */
14174  __pyx_t_1 = (__pyx_v_i != Py_None);
14175  __pyx_t_2 = (__pyx_t_1 != 0);
14176  if (__pyx_t_2) {
14177 
14178  /* "PyClical.pyx":1633
14179  * """
14180  * if not (i is None):
14181  * return clifford().wrap( glucat.acos(toClifford(obj), toClifford(i)) ) # <<<<<<<<<<<<<<
14182  * else:
14183  * try:
14184  */
14185  __Pyx_XDECREF(__pyx_r);
14186  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1633; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
14187  __Pyx_GOTREF(__pyx_t_3);
14188  try {
14189  __pyx_t_4 = acos(__pyx_f_8PyClical_toClifford(__pyx_v_obj), __pyx_f_8PyClical_toClifford(__pyx_v_i));
14190  } catch(...) {
14191  __Pyx_CppExn2PyErr();
14192  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1633; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
14193  }
14194  __pyx_t_5 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_3), __pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1633; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
14195  __Pyx_GOTREF(__pyx_t_5);
14196  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
14197  __pyx_r = __pyx_t_5;
14198  __pyx_t_5 = 0;
14199  goto __pyx_L0;
14200 
14201  /* "PyClical.pyx":1632
14202  * {1,2}
14203  * """
14204  * if not (i is None): # <<<<<<<<<<<<<<
14205  * return clifford().wrap( glucat.acos(toClifford(obj), toClifford(i)) )
14206  * else:
14207  */
14208  }
14209 
14210  /* "PyClical.pyx":1635
14211  * return clifford().wrap( glucat.acos(toClifford(obj), toClifford(i)) )
14212  * else:
14213  * try: # <<<<<<<<<<<<<<
14214  * return math.acos(obj)
14215  * except:
14216  */
14217  /*else*/ {
14218  {
14219  __Pyx_ExceptionSave(&__pyx_t_6, &__pyx_t_7, &__pyx_t_8);
14220  __Pyx_XGOTREF(__pyx_t_6);
14221  __Pyx_XGOTREF(__pyx_t_7);
14222  __Pyx_XGOTREF(__pyx_t_8);
14223  /*try:*/ {
14224 
14225  /* "PyClical.pyx":1636
14226  * else:
14227  * try:
14228  * return math.acos(obj) # <<<<<<<<<<<<<<
14229  * except:
14230  * return clifford().wrap( glucat.acos(toClifford(obj)) )
14231  */
14232  __Pyx_XDECREF(__pyx_r);
14233  __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_math); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1636; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
14234  __Pyx_GOTREF(__pyx_t_3);
14235  __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_acos); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1636; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
14236  __Pyx_GOTREF(__pyx_t_9);
14237  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
14238  __pyx_t_3 = NULL;
14239  if (CYTHON_COMPILING_IN_CPYTHON && unlikely(PyMethod_Check(__pyx_t_9))) {
14240  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_9);
14241  if (likely(__pyx_t_3)) {
14242  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_9);
14243  __Pyx_INCREF(__pyx_t_3);
14244  __Pyx_INCREF(function);
14245  __Pyx_DECREF_SET(__pyx_t_9, function);
14246  }
14247  }
14248  if (!__pyx_t_3) {
14249  __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_t_9, __pyx_v_obj); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1636; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
14250  __Pyx_GOTREF(__pyx_t_5);
14251  } else {
14252  __pyx_t_10 = PyTuple_New(1+1); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1636; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
14253  __Pyx_GOTREF(__pyx_t_10);
14254  __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_3); __pyx_t_3 = NULL;
14255  __Pyx_INCREF(__pyx_v_obj);
14256  __Pyx_GIVEREF(__pyx_v_obj);
14257  PyTuple_SET_ITEM(__pyx_t_10, 0+1, __pyx_v_obj);
14258  __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1636; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
14259  __Pyx_GOTREF(__pyx_t_5);
14260  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
14261  }
14262  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
14263  __pyx_r = __pyx_t_5;
14264  __pyx_t_5 = 0;
14265  goto __pyx_L8_try_return;
14266 
14267  /* "PyClical.pyx":1635
14268  * return clifford().wrap( glucat.acos(toClifford(obj), toClifford(i)) )
14269  * else:
14270  * try: # <<<<<<<<<<<<<<
14271  * return math.acos(obj)
14272  * except:
14273  */
14274  }
14275  __pyx_L4_error:;
14276  __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
14277  __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0;
14278  __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
14279  __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
14280 
14281  /* "PyClical.pyx":1637
14282  * try:
14283  * return math.acos(obj)
14284  * except: # <<<<<<<<<<<<<<
14285  * return clifford().wrap( glucat.acos(toClifford(obj)) )
14286  *
14287  */
14288  /*except:*/ {
14289  __Pyx_AddTraceback("PyClical.acos", __pyx_clineno, __pyx_lineno, __pyx_filename);
14290  if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_9, &__pyx_t_10) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1637; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
14291  __Pyx_GOTREF(__pyx_t_5);
14292  __Pyx_GOTREF(__pyx_t_9);
14293  __Pyx_GOTREF(__pyx_t_10);
14294 
14295  /* "PyClical.pyx":1638
14296  * return math.acos(obj)
14297  * except:
14298  * return clifford().wrap( glucat.acos(toClifford(obj)) ) # <<<<<<<<<<<<<<
14299  *
14300  * cpdef inline cosh(obj):
14301  */
14302  __Pyx_XDECREF(__pyx_r);
14303  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1638; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
14304  __Pyx_GOTREF(__pyx_t_3);
14305  __pyx_t_11 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_3), acos(__pyx_f_8PyClical_toClifford(__pyx_v_obj))); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1638; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
14306  __Pyx_GOTREF(__pyx_t_11);
14307  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
14308  __pyx_r = __pyx_t_11;
14309  __pyx_t_11 = 0;
14310  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
14311  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
14312  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
14313  goto __pyx_L7_except_return;
14314  }
14315  __pyx_L6_except_error:;
14316 
14317  /* "PyClical.pyx":1635
14318  * return clifford().wrap( glucat.acos(toClifford(obj), toClifford(i)) )
14319  * else:
14320  * try: # <<<<<<<<<<<<<<
14321  * return math.acos(obj)
14322  * except:
14323  */
14324  __Pyx_XGIVEREF(__pyx_t_6);
14325  __Pyx_XGIVEREF(__pyx_t_7);
14326  __Pyx_XGIVEREF(__pyx_t_8);
14327  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
14328  goto __pyx_L1_error;
14329  __pyx_L8_try_return:;
14330  __Pyx_XGIVEREF(__pyx_t_6);
14331  __Pyx_XGIVEREF(__pyx_t_7);
14332  __Pyx_XGIVEREF(__pyx_t_8);
14333  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
14334  goto __pyx_L0;
14335  __pyx_L7_except_return:;
14336  __Pyx_XGIVEREF(__pyx_t_6);
14337  __Pyx_XGIVEREF(__pyx_t_7);
14338  __Pyx_XGIVEREF(__pyx_t_8);
14339  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
14340  goto __pyx_L0;
14341  }
14342  }
14343 
14344  /* "PyClical.pyx":1619
14345  * return clifford().wrap( glucat.cos(toClifford(obj)) )
14346  *
14347  * cpdef inline acos(obj,i = None): # <<<<<<<<<<<<<<
14348  * """
14349  * Inverse cosine of multivector with optional complexifier.
14350  */
14351 
14352  /* function exit code */
14353  __pyx_L1_error:;
14354  __Pyx_XDECREF(__pyx_t_3);
14355  __Pyx_XDECREF(__pyx_t_5);
14356  __Pyx_XDECREF(__pyx_t_9);
14357  __Pyx_XDECREF(__pyx_t_10);
14358  __Pyx_XDECREF(__pyx_t_11);
14359  __Pyx_AddTraceback("PyClical.acos", __pyx_clineno, __pyx_lineno, __pyx_filename);
14360  __pyx_r = 0;
14361  __pyx_L0:;
14362  __Pyx_XGIVEREF(__pyx_r);
14363  __Pyx_RefNannyFinishContext();
14364  return __pyx_r;
14365  }
14366 
14367  /* Python wrapper */
14368  static PyObject *__pyx_pw_8PyClical_53acos(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
14369  static char __pyx_doc_8PyClical_52acos[] = "\n Inverse cosine of multivector with optional complexifier.\n\n >>> x=clifford(\"{1,2}\"); print cos(acos(x),\"{1,2,3}\")\n {1,2}\n >>> x=clifford(\"{1,2}\"); print cos(acos(x),\"{-1,1,2,3,4}\")\n {1,2}\n >>> print acos(0) / pi\n 0.5\n >>> x=clifford(\"{1,2}\"); print cos(acos(x))\n {1,2}\n ";
14370  static PyObject *__pyx_pw_8PyClical_53acos(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
14371  PyObject *__pyx_v_obj = 0;
14372  PyObject *__pyx_v_i = 0;
14373  int __pyx_lineno = 0;
14374  const char *__pyx_filename = NULL;
14375  int __pyx_clineno = 0;
14376  PyObject *__pyx_r = 0;
14377  __Pyx_RefNannyDeclarations
14378  __Pyx_RefNannySetupContext("acos (wrapper)", 0);
14379  {
14380  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_obj,&__pyx_n_s_i,0};
14381  PyObject* values[2] = {0,0};
14382  values[1] = ((PyObject *)Py_None);
14383  if (unlikely(__pyx_kwds)) {
14384  Py_ssize_t kw_args;
14385  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
14386  switch (pos_args) {
14387  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
14388  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
14389  case 0: break;
14390  default: goto __pyx_L5_argtuple_error;
14391  }
14392  kw_args = PyDict_Size(__pyx_kwds);
14393  switch (pos_args) {
14394  case 0:
14395  if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_obj)) != 0)) kw_args--;
14396  else goto __pyx_L5_argtuple_error;
14397  case 1:
14398  if (kw_args > 0) {
14399  PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_i);
14400  if (value) { values[1] = value; kw_args--; }
14401  }
14402  }
14403  if (unlikely(kw_args > 0)) {
14404  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "acos") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1619; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
14405  }
14406  } else {
14407  switch (PyTuple_GET_SIZE(__pyx_args)) {
14408  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
14409  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
14410  break;
14411  default: goto __pyx_L5_argtuple_error;
14412  }
14413  }
14414  __pyx_v_obj = values[0];
14415  __pyx_v_i = values[1];
14416  }
14417  goto __pyx_L4_argument_unpacking_done;
14418  __pyx_L5_argtuple_error:;
14419  __Pyx_RaiseArgtupleInvalid("acos", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1619; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
14420  __pyx_L3_error:;
14421  __Pyx_AddTraceback("PyClical.acos", __pyx_clineno, __pyx_lineno, __pyx_filename);
14422  __Pyx_RefNannyFinishContext();
14423  return NULL;
14424  __pyx_L4_argument_unpacking_done:;
14425  __pyx_r = __pyx_pf_8PyClical_52acos(__pyx_self, __pyx_v_obj, __pyx_v_i);
14426 
14427  /* function exit code */
14428  __Pyx_RefNannyFinishContext();
14429  return __pyx_r;
14430  }
14431 
14432  static PyObject *__pyx_pf_8PyClical_52acos(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_i) {
14433  PyObject *__pyx_r = NULL;
14434  __Pyx_RefNannyDeclarations
14435  PyObject *__pyx_t_1 = NULL;
14436  struct __pyx_opt_args_8PyClical_acos __pyx_t_2;
14437  int __pyx_lineno = 0;
14438  const char *__pyx_filename = NULL;
14439  int __pyx_clineno = 0;
14440  __Pyx_RefNannySetupContext("acos", 0);
14441  __Pyx_XDECREF(__pyx_r);
14442  __pyx_t_2.__pyx_n = 1;
14443  __pyx_t_2.i = __pyx_v_i;
14444  __pyx_t_1 = __pyx_f_8PyClical_acos(__pyx_v_obj, 0, &__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1619; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
14445  __Pyx_GOTREF(__pyx_t_1);
14446  __pyx_r = __pyx_t_1;
14447  __pyx_t_1 = 0;
14448  goto __pyx_L0;
14449 
14450  /* function exit code */
14451  __pyx_L1_error:;
14452  __Pyx_XDECREF(__pyx_t_1);
14453  __Pyx_AddTraceback("PyClical.acos", __pyx_clineno, __pyx_lineno, __pyx_filename);
14454  __pyx_r = NULL;
14455  __pyx_L0:;
14456  __Pyx_XGIVEREF(__pyx_r);
14457  __Pyx_RefNannyFinishContext();
14458  return __pyx_r;
14459  }
14460 
14461  /* "PyClical.pyx":1640
14462  * return clifford().wrap( glucat.acos(toClifford(obj)) )
14463  *
14464  * cpdef inline cosh(obj): # <<<<<<<<<<<<<<
14465  * """
14466  * Hyperbolic cosine of multivector.
14467  */
14468 
14469  static PyObject *__pyx_pw_8PyClical_55cosh(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
14470  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_cosh(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
14471  PyObject *__pyx_r = NULL;
14472  __Pyx_RefNannyDeclarations
14473  PyObject *__pyx_t_1 = NULL;
14474  PyObject *__pyx_t_2 = NULL;
14475  PyObject *__pyx_t_3 = NULL;
14476  PyObject *__pyx_t_4 = NULL;
14477  PyObject *__pyx_t_5 = NULL;
14478  PyObject *__pyx_t_6 = NULL;
14479  PyObject *__pyx_t_7 = NULL;
14480  PyObject *__pyx_t_8 = NULL;
14481  int __pyx_lineno = 0;
14482  const char *__pyx_filename = NULL;
14483  int __pyx_clineno = 0;
14484  __Pyx_RefNannySetupContext("cosh", 0);
14485 
14486  /* "PyClical.pyx":1651
14487  * {1,2}
14488  * """
14489  * try: # <<<<<<<<<<<<<<
14490  * return math.cosh(obj)
14491  * except:
14492  */
14493  {
14494  __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3);
14495  __Pyx_XGOTREF(__pyx_t_1);
14496  __Pyx_XGOTREF(__pyx_t_2);
14497  __Pyx_XGOTREF(__pyx_t_3);
14498  /*try:*/ {
14499 
14500  /* "PyClical.pyx":1652
14501  * """
14502  * try:
14503  * return math.cosh(obj) # <<<<<<<<<<<<<<
14504  * except:
14505  * return clifford().wrap( glucat.cosh(toClifford(obj)) )
14506  */
14507  __Pyx_XDECREF(__pyx_r);
14508  __pyx_t_5 = __Pyx_GetModuleGlobalName(__pyx_n_s_math); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
14509  __Pyx_GOTREF(__pyx_t_5);
14510  __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_cosh); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
14511  __Pyx_GOTREF(__pyx_t_6);
14512  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
14513  __pyx_t_5 = NULL;
14514  if (CYTHON_COMPILING_IN_CPYTHON && unlikely(PyMethod_Check(__pyx_t_6))) {
14515  __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_6);
14516  if (likely(__pyx_t_5)) {
14517  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6);
14518  __Pyx_INCREF(__pyx_t_5);
14519  __Pyx_INCREF(function);
14520  __Pyx_DECREF_SET(__pyx_t_6, function);
14521  }
14522  }
14523  if (!__pyx_t_5) {
14524  __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_obj); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
14525  __Pyx_GOTREF(__pyx_t_4);
14526  } else {
14527  __pyx_t_7 = PyTuple_New(1+1); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
14528  __Pyx_GOTREF(__pyx_t_7);
14529  __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_5); __pyx_t_5 = NULL;
14530  __Pyx_INCREF(__pyx_v_obj);
14531  __Pyx_GIVEREF(__pyx_v_obj);
14532  PyTuple_SET_ITEM(__pyx_t_7, 0+1, __pyx_v_obj);
14533  __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_7, NULL); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
14534  __Pyx_GOTREF(__pyx_t_4);
14535  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
14536  }
14537  __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
14538  __pyx_r = __pyx_t_4;
14539  __pyx_t_4 = 0;
14540  goto __pyx_L7_try_return;
14541 
14542  /* "PyClical.pyx":1651
14543  * {1,2}
14544  * """
14545  * try: # <<<<<<<<<<<<<<
14546  * return math.cosh(obj)
14547  * except:
14548  */
14549  }
14550  __pyx_L3_error:;
14551  __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
14552  __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
14553  __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
14554  __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
14555 
14556  /* "PyClical.pyx":1653
14557  * try:
14558  * return math.cosh(obj)
14559  * except: # <<<<<<<<<<<<<<
14560  * return clifford().wrap( glucat.cosh(toClifford(obj)) )
14561  *
14562  */
14563  /*except:*/ {
14564  __Pyx_AddTraceback("PyClical.cosh", __pyx_clineno, __pyx_lineno, __pyx_filename);
14565  if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_7) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1653; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
14566  __Pyx_GOTREF(__pyx_t_4);
14567  __Pyx_GOTREF(__pyx_t_6);
14568  __Pyx_GOTREF(__pyx_t_7);
14569 
14570  /* "PyClical.pyx":1654
14571  * return math.cosh(obj)
14572  * except:
14573  * return clifford().wrap( glucat.cosh(toClifford(obj)) ) # <<<<<<<<<<<<<<
14574  *
14575  * cpdef inline acosh(obj,i = None):
14576  */
14577  __Pyx_XDECREF(__pyx_r);
14578  __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1654; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
14579  __Pyx_GOTREF(__pyx_t_5);
14580  __pyx_t_8 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_5), cosh(__pyx_f_8PyClical_toClifford(__pyx_v_obj))); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1654; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
14581  __Pyx_GOTREF(__pyx_t_8);
14582  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
14583  __pyx_r = __pyx_t_8;
14584  __pyx_t_8 = 0;
14585  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
14586  __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
14587  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
14588  goto __pyx_L6_except_return;
14589  }
14590  __pyx_L5_except_error:;
14591 
14592  /* "PyClical.pyx":1651
14593  * {1,2}
14594  * """
14595  * try: # <<<<<<<<<<<<<<
14596  * return math.cosh(obj)
14597  * except:
14598  */
14599  __Pyx_XGIVEREF(__pyx_t_1);
14600  __Pyx_XGIVEREF(__pyx_t_2);
14601  __Pyx_XGIVEREF(__pyx_t_3);
14602  __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
14603  goto __pyx_L1_error;
14604  __pyx_L7_try_return:;
14605  __Pyx_XGIVEREF(__pyx_t_1);
14606  __Pyx_XGIVEREF(__pyx_t_2);
14607  __Pyx_XGIVEREF(__pyx_t_3);
14608  __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
14609  goto __pyx_L0;
14610  __pyx_L6_except_return:;
14611  __Pyx_XGIVEREF(__pyx_t_1);
14612  __Pyx_XGIVEREF(__pyx_t_2);
14613  __Pyx_XGIVEREF(__pyx_t_3);
14614  __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
14615  goto __pyx_L0;
14616  }
14617 
14618  /* "PyClical.pyx":1640
14619  * return clifford().wrap( glucat.acos(toClifford(obj)) )
14620  *
14621  * cpdef inline cosh(obj): # <<<<<<<<<<<<<<
14622  * """
14623  * Hyperbolic cosine of multivector.
14624  */
14625 
14626  /* function exit code */
14627  __pyx_L1_error:;
14628  __Pyx_XDECREF(__pyx_t_4);
14629  __Pyx_XDECREF(__pyx_t_5);
14630  __Pyx_XDECREF(__pyx_t_6);
14631  __Pyx_XDECREF(__pyx_t_7);
14632  __Pyx_XDECREF(__pyx_t_8);
14633  __Pyx_AddTraceback("PyClical.cosh", __pyx_clineno, __pyx_lineno, __pyx_filename);
14634  __pyx_r = 0;
14635  __pyx_L0:;
14636  __Pyx_XGIVEREF(__pyx_r);
14637  __Pyx_RefNannyFinishContext();
14638  return __pyx_r;
14639  }
14640 
14641  /* Python wrapper */
14642  static PyObject *__pyx_pw_8PyClical_55cosh(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
14643  static char __pyx_doc_8PyClical_54cosh[] = "\n Hyperbolic cosine of multivector.\n\n >>> x=clifford(\"{1,2}\") * pi; print cosh(x)\n -1\n >>> x=clifford(\"{1,2,3}\"); print cosh(acosh(x))\n {1,2,3}\n >>> x=clifford(\"{1,2}\"); print cosh(acosh(x))\n {1,2}\n ";
14644  static PyObject *__pyx_pw_8PyClical_55cosh(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
14645  PyObject *__pyx_r = 0;
14646  __Pyx_RefNannyDeclarations
14647  __Pyx_RefNannySetupContext("cosh (wrapper)", 0);
14648  __pyx_r = __pyx_pf_8PyClical_54cosh(__pyx_self, ((PyObject *)__pyx_v_obj));
14649 
14650  /* function exit code */
14651  __Pyx_RefNannyFinishContext();
14652  return __pyx_r;
14653  }
14654 
14655  static PyObject *__pyx_pf_8PyClical_54cosh(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
14656  PyObject *__pyx_r = NULL;
14657  __Pyx_RefNannyDeclarations
14658  PyObject *__pyx_t_1 = NULL;
14659  int __pyx_lineno = 0;
14660  const char *__pyx_filename = NULL;
14661  int __pyx_clineno = 0;
14662  __Pyx_RefNannySetupContext("cosh", 0);
14663  __Pyx_XDECREF(__pyx_r);
14664  __pyx_t_1 = __pyx_f_8PyClical_cosh(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1640; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
14665  __Pyx_GOTREF(__pyx_t_1);
14666  __pyx_r = __pyx_t_1;
14667  __pyx_t_1 = 0;
14668  goto __pyx_L0;
14669 
14670  /* function exit code */
14671  __pyx_L1_error:;
14672  __Pyx_XDECREF(__pyx_t_1);
14673  __Pyx_AddTraceback("PyClical.cosh", __pyx_clineno, __pyx_lineno, __pyx_filename);
14674  __pyx_r = NULL;
14675  __pyx_L0:;
14676  __Pyx_XGIVEREF(__pyx_r);
14677  __Pyx_RefNannyFinishContext();
14678  return __pyx_r;
14679  }
14680 
14681  /* "PyClical.pyx":1656
14682  * return clifford().wrap( glucat.cosh(toClifford(obj)) )
14683  *
14684  * cpdef inline acosh(obj,i = None): # <<<<<<<<<<<<<<
14685  * """
14686  * Inverse hyperbolic cosine of multivector with optional complexifier.
14687  */
14688 
14689  static PyObject *__pyx_pw_8PyClical_57acosh(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
14690  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_acosh(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_acosh *__pyx_optional_args) {
14691  PyObject *__pyx_v_i = ((PyObject *)Py_None);
14692  PyObject *__pyx_r = NULL;
14693  __Pyx_RefNannyDeclarations
14694  int __pyx_t_1;
14695  int __pyx_t_2;
14696  PyObject *__pyx_t_3 = NULL;
14697  Clifford __pyx_t_4;
14698  PyObject *__pyx_t_5 = NULL;
14699  PyObject *__pyx_t_6 = NULL;
14700  PyObject *__pyx_t_7 = NULL;
14701  PyObject *__pyx_t_8 = NULL;
14702  PyObject *__pyx_t_9 = NULL;
14703  PyObject *__pyx_t_10 = NULL;
14704  PyObject *__pyx_t_11 = NULL;
14705  int __pyx_lineno = 0;
14706  const char *__pyx_filename = NULL;
14707  int __pyx_clineno = 0;
14708  __Pyx_RefNannySetupContext("acosh", 0);
14709  if (__pyx_optional_args) {
14710  if (__pyx_optional_args->__pyx_n > 0) {
14711  __pyx_v_i = __pyx_optional_args->i;
14712  }
14713  }
14714 
14715  /* "PyClical.pyx":1671
14716  * {1,2}
14717  * """
14718  * if not (i is None): # <<<<<<<<<<<<<<
14719  * return clifford().wrap( glucat.acosh(toClifford(obj), toClifford(i)) )
14720  * else:
14721  */
14722  __pyx_t_1 = (__pyx_v_i != Py_None);
14723  __pyx_t_2 = (__pyx_t_1 != 0);
14724  if (__pyx_t_2) {
14725 
14726  /* "PyClical.pyx":1672
14727  * """
14728  * if not (i is None):
14729  * return clifford().wrap( glucat.acosh(toClifford(obj), toClifford(i)) ) # <<<<<<<<<<<<<<
14730  * else:
14731  * try:
14732  */
14733  __Pyx_XDECREF(__pyx_r);
14734  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1672; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
14735  __Pyx_GOTREF(__pyx_t_3);
14736  try {
14737  __pyx_t_4 = acosh(__pyx_f_8PyClical_toClifford(__pyx_v_obj), __pyx_f_8PyClical_toClifford(__pyx_v_i));
14738  } catch(...) {
14739  __Pyx_CppExn2PyErr();
14740  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1672; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
14741  }
14742  __pyx_t_5 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_3), __pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1672; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
14743  __Pyx_GOTREF(__pyx_t_5);
14744  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
14745  __pyx_r = __pyx_t_5;
14746  __pyx_t_5 = 0;
14747  goto __pyx_L0;
14748 
14749  /* "PyClical.pyx":1671
14750  * {1,2}
14751  * """
14752  * if not (i is None): # <<<<<<<<<<<<<<
14753  * return clifford().wrap( glucat.acosh(toClifford(obj), toClifford(i)) )
14754  * else:
14755  */
14756  }
14757 
14758  /* "PyClical.pyx":1674
14759  * return clifford().wrap( glucat.acosh(toClifford(obj), toClifford(i)) )
14760  * else:
14761  * try: # <<<<<<<<<<<<<<
14762  * return math.acosh(obj)
14763  * except:
14764  */
14765  /*else*/ {
14766  {
14767  __Pyx_ExceptionSave(&__pyx_t_6, &__pyx_t_7, &__pyx_t_8);
14768  __Pyx_XGOTREF(__pyx_t_6);
14769  __Pyx_XGOTREF(__pyx_t_7);
14770  __Pyx_XGOTREF(__pyx_t_8);
14771  /*try:*/ {
14772 
14773  /* "PyClical.pyx":1675
14774  * else:
14775  * try:
14776  * return math.acosh(obj) # <<<<<<<<<<<<<<
14777  * except:
14778  * return clifford().wrap( glucat.acosh(toClifford(obj)) )
14779  */
14780  __Pyx_XDECREF(__pyx_r);
14781  __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_math); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1675; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
14782  __Pyx_GOTREF(__pyx_t_3);
14783  __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_acosh); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1675; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
14784  __Pyx_GOTREF(__pyx_t_9);
14785  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
14786  __pyx_t_3 = NULL;
14787  if (CYTHON_COMPILING_IN_CPYTHON && unlikely(PyMethod_Check(__pyx_t_9))) {
14788  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_9);
14789  if (likely(__pyx_t_3)) {
14790  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_9);
14791  __Pyx_INCREF(__pyx_t_3);
14792  __Pyx_INCREF(function);
14793  __Pyx_DECREF_SET(__pyx_t_9, function);
14794  }
14795  }
14796  if (!__pyx_t_3) {
14797  __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_t_9, __pyx_v_obj); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1675; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
14798  __Pyx_GOTREF(__pyx_t_5);
14799  } else {
14800  __pyx_t_10 = PyTuple_New(1+1); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1675; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
14801  __Pyx_GOTREF(__pyx_t_10);
14802  __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_3); __pyx_t_3 = NULL;
14803  __Pyx_INCREF(__pyx_v_obj);
14804  __Pyx_GIVEREF(__pyx_v_obj);
14805  PyTuple_SET_ITEM(__pyx_t_10, 0+1, __pyx_v_obj);
14806  __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1675; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
14807  __Pyx_GOTREF(__pyx_t_5);
14808  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
14809  }
14810  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
14811  __pyx_r = __pyx_t_5;
14812  __pyx_t_5 = 0;
14813  goto __pyx_L8_try_return;
14814 
14815  /* "PyClical.pyx":1674
14816  * return clifford().wrap( glucat.acosh(toClifford(obj), toClifford(i)) )
14817  * else:
14818  * try: # <<<<<<<<<<<<<<
14819  * return math.acosh(obj)
14820  * except:
14821  */
14822  }
14823  __pyx_L4_error:;
14824  __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
14825  __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0;
14826  __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
14827  __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
14828 
14829  /* "PyClical.pyx":1676
14830  * try:
14831  * return math.acosh(obj)
14832  * except: # <<<<<<<<<<<<<<
14833  * return clifford().wrap( glucat.acosh(toClifford(obj)) )
14834  *
14835  */
14836  /*except:*/ {
14837  __Pyx_AddTraceback("PyClical.acosh", __pyx_clineno, __pyx_lineno, __pyx_filename);
14838  if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_9, &__pyx_t_10) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1676; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
14839  __Pyx_GOTREF(__pyx_t_5);
14840  __Pyx_GOTREF(__pyx_t_9);
14841  __Pyx_GOTREF(__pyx_t_10);
14842 
14843  /* "PyClical.pyx":1677
14844  * return math.acosh(obj)
14845  * except:
14846  * return clifford().wrap( glucat.acosh(toClifford(obj)) ) # <<<<<<<<<<<<<<
14847  *
14848  * cpdef inline sin(obj,i = None):
14849  */
14850  __Pyx_XDECREF(__pyx_r);
14851  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1677; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
14852  __Pyx_GOTREF(__pyx_t_3);
14853  __pyx_t_11 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_3), acosh(__pyx_f_8PyClical_toClifford(__pyx_v_obj))); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1677; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
14854  __Pyx_GOTREF(__pyx_t_11);
14855  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
14856  __pyx_r = __pyx_t_11;
14857  __pyx_t_11 = 0;
14858  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
14859  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
14860  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
14861  goto __pyx_L7_except_return;
14862  }
14863  __pyx_L6_except_error:;
14864 
14865  /* "PyClical.pyx":1674
14866  * return clifford().wrap( glucat.acosh(toClifford(obj), toClifford(i)) )
14867  * else:
14868  * try: # <<<<<<<<<<<<<<
14869  * return math.acosh(obj)
14870  * except:
14871  */
14872  __Pyx_XGIVEREF(__pyx_t_6);
14873  __Pyx_XGIVEREF(__pyx_t_7);
14874  __Pyx_XGIVEREF(__pyx_t_8);
14875  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
14876  goto __pyx_L1_error;
14877  __pyx_L8_try_return:;
14878  __Pyx_XGIVEREF(__pyx_t_6);
14879  __Pyx_XGIVEREF(__pyx_t_7);
14880  __Pyx_XGIVEREF(__pyx_t_8);
14881  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
14882  goto __pyx_L0;
14883  __pyx_L7_except_return:;
14884  __Pyx_XGIVEREF(__pyx_t_6);
14885  __Pyx_XGIVEREF(__pyx_t_7);
14886  __Pyx_XGIVEREF(__pyx_t_8);
14887  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
14888  goto __pyx_L0;
14889  }
14890  }
14891 
14892  /* "PyClical.pyx":1656
14893  * return clifford().wrap( glucat.cosh(toClifford(obj)) )
14894  *
14895  * cpdef inline acosh(obj,i = None): # <<<<<<<<<<<<<<
14896  * """
14897  * Inverse hyperbolic cosine of multivector with optional complexifier.
14898  */
14899 
14900  /* function exit code */
14901  __pyx_L1_error:;
14902  __Pyx_XDECREF(__pyx_t_3);
14903  __Pyx_XDECREF(__pyx_t_5);
14904  __Pyx_XDECREF(__pyx_t_9);
14905  __Pyx_XDECREF(__pyx_t_10);
14906  __Pyx_XDECREF(__pyx_t_11);
14907  __Pyx_AddTraceback("PyClical.acosh", __pyx_clineno, __pyx_lineno, __pyx_filename);
14908  __pyx_r = 0;
14909  __pyx_L0:;
14910  __Pyx_XGIVEREF(__pyx_r);
14911  __Pyx_RefNannyFinishContext();
14912  return __pyx_r;
14913  }
14914 
14915  /* Python wrapper */
14916  static PyObject *__pyx_pw_8PyClical_57acosh(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
14917  static char __pyx_doc_8PyClical_56acosh[] = "\n Inverse hyperbolic cosine of multivector with optional complexifier.\n\n >>> print acosh(0,\"{-2,-1,1}\")\n 1.571{-2,-1,1}\n >>> x=clifford(\"{1,2,3}\"); print cosh(acosh(x,\"{-1,1,2,3,4}\"))\n {1,2,3}\n >>> print acosh(0)\n 1.571{-1}\n >>> x=clifford(\"{1,2,3}\"); print cosh(acosh(x))\n {1,2,3}\n >>> x=clifford(\"{1,2}\"); print cosh(acosh(x))\n {1,2}\n ";
14918  static PyObject *__pyx_pw_8PyClical_57acosh(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
14919  PyObject *__pyx_v_obj = 0;
14920  PyObject *__pyx_v_i = 0;
14921  int __pyx_lineno = 0;
14922  const char *__pyx_filename = NULL;
14923  int __pyx_clineno = 0;
14924  PyObject *__pyx_r = 0;
14925  __Pyx_RefNannyDeclarations
14926  __Pyx_RefNannySetupContext("acosh (wrapper)", 0);
14927  {
14928  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_obj,&__pyx_n_s_i,0};
14929  PyObject* values[2] = {0,0};
14930  values[1] = ((PyObject *)Py_None);
14931  if (unlikely(__pyx_kwds)) {
14932  Py_ssize_t kw_args;
14933  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
14934  switch (pos_args) {
14935  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
14936  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
14937  case 0: break;
14938  default: goto __pyx_L5_argtuple_error;
14939  }
14940  kw_args = PyDict_Size(__pyx_kwds);
14941  switch (pos_args) {
14942  case 0:
14943  if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_obj)) != 0)) kw_args--;
14944  else goto __pyx_L5_argtuple_error;
14945  case 1:
14946  if (kw_args > 0) {
14947  PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_i);
14948  if (value) { values[1] = value; kw_args--; }
14949  }
14950  }
14951  if (unlikely(kw_args > 0)) {
14952  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "acosh") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1656; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
14953  }
14954  } else {
14955  switch (PyTuple_GET_SIZE(__pyx_args)) {
14956  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
14957  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
14958  break;
14959  default: goto __pyx_L5_argtuple_error;
14960  }
14961  }
14962  __pyx_v_obj = values[0];
14963  __pyx_v_i = values[1];
14964  }
14965  goto __pyx_L4_argument_unpacking_done;
14966  __pyx_L5_argtuple_error:;
14967  __Pyx_RaiseArgtupleInvalid("acosh", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1656; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
14968  __pyx_L3_error:;
14969  __Pyx_AddTraceback("PyClical.acosh", __pyx_clineno, __pyx_lineno, __pyx_filename);
14970  __Pyx_RefNannyFinishContext();
14971  return NULL;
14972  __pyx_L4_argument_unpacking_done:;
14973  __pyx_r = __pyx_pf_8PyClical_56acosh(__pyx_self, __pyx_v_obj, __pyx_v_i);
14974 
14975  /* function exit code */
14976  __Pyx_RefNannyFinishContext();
14977  return __pyx_r;
14978  }
14979 
14980  static PyObject *__pyx_pf_8PyClical_56acosh(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_i) {
14981  PyObject *__pyx_r = NULL;
14982  __Pyx_RefNannyDeclarations
14983  PyObject *__pyx_t_1 = NULL;
14984  struct __pyx_opt_args_8PyClical_acosh __pyx_t_2;
14985  int __pyx_lineno = 0;
14986  const char *__pyx_filename = NULL;
14987  int __pyx_clineno = 0;
14988  __Pyx_RefNannySetupContext("acosh", 0);
14989  __Pyx_XDECREF(__pyx_r);
14990  __pyx_t_2.__pyx_n = 1;
14991  __pyx_t_2.i = __pyx_v_i;
14992  __pyx_t_1 = __pyx_f_8PyClical_acosh(__pyx_v_obj, 0, &__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1656; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
14993  __Pyx_GOTREF(__pyx_t_1);
14994  __pyx_r = __pyx_t_1;
14995  __pyx_t_1 = 0;
14996  goto __pyx_L0;
14997 
14998  /* function exit code */
14999  __pyx_L1_error:;
15000  __Pyx_XDECREF(__pyx_t_1);
15001  __Pyx_AddTraceback("PyClical.acosh", __pyx_clineno, __pyx_lineno, __pyx_filename);
15002  __pyx_r = NULL;
15003  __pyx_L0:;
15004  __Pyx_XGIVEREF(__pyx_r);
15005  __Pyx_RefNannyFinishContext();
15006  return __pyx_r;
15007  }
15008 
15009  /* "PyClical.pyx":1679
15010  * return clifford().wrap( glucat.acosh(toClifford(obj)) )
15011  *
15012  * cpdef inline sin(obj,i = None): # <<<<<<<<<<<<<<
15013  * """
15014  * Sine of multivector with optional complexifier.
15015  */
15016 
15017  static PyObject *__pyx_pw_8PyClical_59sin(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
15018  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_sin(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_sin *__pyx_optional_args) {
15019  PyObject *__pyx_v_i = ((PyObject *)Py_None);
15020  PyObject *__pyx_r = NULL;
15021  __Pyx_RefNannyDeclarations
15022  int __pyx_t_1;
15023  int __pyx_t_2;
15024  PyObject *__pyx_t_3 = NULL;
15025  Clifford __pyx_t_4;
15026  PyObject *__pyx_t_5 = NULL;
15027  PyObject *__pyx_t_6 = NULL;
15028  PyObject *__pyx_t_7 = NULL;
15029  PyObject *__pyx_t_8 = NULL;
15030  PyObject *__pyx_t_9 = NULL;
15031  PyObject *__pyx_t_10 = NULL;
15032  PyObject *__pyx_t_11 = NULL;
15033  int __pyx_lineno = 0;
15034  const char *__pyx_filename = NULL;
15035  int __pyx_clineno = 0;
15036  __Pyx_RefNannySetupContext("sin", 0);
15037  if (__pyx_optional_args) {
15038  if (__pyx_optional_args->__pyx_n > 0) {
15039  __pyx_v_i = __pyx_optional_args->i;
15040  }
15041  }
15042 
15043  /* "PyClical.pyx":1690
15044  * {1,2,3}
15045  * """
15046  * if not (i is None): # <<<<<<<<<<<<<<
15047  * return clifford().wrap( glucat.sin(toClifford(obj), toClifford(i)) )
15048  * else:
15049  */
15050  __pyx_t_1 = (__pyx_v_i != Py_None);
15051  __pyx_t_2 = (__pyx_t_1 != 0);
15052  if (__pyx_t_2) {
15053 
15054  /* "PyClical.pyx":1691
15055  * """
15056  * if not (i is None):
15057  * return clifford().wrap( glucat.sin(toClifford(obj), toClifford(i)) ) # <<<<<<<<<<<<<<
15058  * else:
15059  * try:
15060  */
15061  __Pyx_XDECREF(__pyx_r);
15062  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1691; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
15063  __Pyx_GOTREF(__pyx_t_3);
15064  try {
15065  __pyx_t_4 = sin(__pyx_f_8PyClical_toClifford(__pyx_v_obj), __pyx_f_8PyClical_toClifford(__pyx_v_i));
15066  } catch(...) {
15067  __Pyx_CppExn2PyErr();
15068  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1691; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
15069  }
15070  __pyx_t_5 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_3), __pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1691; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
15071  __Pyx_GOTREF(__pyx_t_5);
15072  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
15073  __pyx_r = __pyx_t_5;
15074  __pyx_t_5 = 0;
15075  goto __pyx_L0;
15076 
15077  /* "PyClical.pyx":1690
15078  * {1,2,3}
15079  * """
15080  * if not (i is None): # <<<<<<<<<<<<<<
15081  * return clifford().wrap( glucat.sin(toClifford(obj), toClifford(i)) )
15082  * else:
15083  */
15084  }
15085 
15086  /* "PyClical.pyx":1693
15087  * return clifford().wrap( glucat.sin(toClifford(obj), toClifford(i)) )
15088  * else:
15089  * try: # <<<<<<<<<<<<<<
15090  * return math.sin(obj)
15091  * except:
15092  */
15093  /*else*/ {
15094  {
15095  __Pyx_ExceptionSave(&__pyx_t_6, &__pyx_t_7, &__pyx_t_8);
15096  __Pyx_XGOTREF(__pyx_t_6);
15097  __Pyx_XGOTREF(__pyx_t_7);
15098  __Pyx_XGOTREF(__pyx_t_8);
15099  /*try:*/ {
15100 
15101  /* "PyClical.pyx":1694
15102  * else:
15103  * try:
15104  * return math.sin(obj) # <<<<<<<<<<<<<<
15105  * except:
15106  * return clifford().wrap( glucat.sin(toClifford(obj)) )
15107  */
15108  __Pyx_XDECREF(__pyx_r);
15109  __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_math); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1694; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
15110  __Pyx_GOTREF(__pyx_t_3);
15111  __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_sin); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1694; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
15112  __Pyx_GOTREF(__pyx_t_9);
15113  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
15114  __pyx_t_3 = NULL;
15115  if (CYTHON_COMPILING_IN_CPYTHON && unlikely(PyMethod_Check(__pyx_t_9))) {
15116  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_9);
15117  if (likely(__pyx_t_3)) {
15118  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_9);
15119  __Pyx_INCREF(__pyx_t_3);
15120  __Pyx_INCREF(function);
15121  __Pyx_DECREF_SET(__pyx_t_9, function);
15122  }
15123  }
15124  if (!__pyx_t_3) {
15125  __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_t_9, __pyx_v_obj); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1694; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
15126  __Pyx_GOTREF(__pyx_t_5);
15127  } else {
15128  __pyx_t_10 = PyTuple_New(1+1); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1694; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
15129  __Pyx_GOTREF(__pyx_t_10);
15130  __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_3); __pyx_t_3 = NULL;
15131  __Pyx_INCREF(__pyx_v_obj);
15132  __Pyx_GIVEREF(__pyx_v_obj);
15133  PyTuple_SET_ITEM(__pyx_t_10, 0+1, __pyx_v_obj);
15134  __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1694; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
15135  __Pyx_GOTREF(__pyx_t_5);
15136  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
15137  }
15138  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
15139  __pyx_r = __pyx_t_5;
15140  __pyx_t_5 = 0;
15141  goto __pyx_L8_try_return;
15142 
15143  /* "PyClical.pyx":1693
15144  * return clifford().wrap( glucat.sin(toClifford(obj), toClifford(i)) )
15145  * else:
15146  * try: # <<<<<<<<<<<<<<
15147  * return math.sin(obj)
15148  * except:
15149  */
15150  }
15151  __pyx_L4_error:;
15152  __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
15153  __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0;
15154  __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
15155  __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
15156 
15157  /* "PyClical.pyx":1695
15158  * try:
15159  * return math.sin(obj)
15160  * except: # <<<<<<<<<<<<<<
15161  * return clifford().wrap( glucat.sin(toClifford(obj)) )
15162  *
15163  */
15164  /*except:*/ {
15165  __Pyx_AddTraceback("PyClical.sin", __pyx_clineno, __pyx_lineno, __pyx_filename);
15166  if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_9, &__pyx_t_10) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1695; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
15167  __Pyx_GOTREF(__pyx_t_5);
15168  __Pyx_GOTREF(__pyx_t_9);
15169  __Pyx_GOTREF(__pyx_t_10);
15170 
15171  /* "PyClical.pyx":1696
15172  * return math.sin(obj)
15173  * except:
15174  * return clifford().wrap( glucat.sin(toClifford(obj)) ) # <<<<<<<<<<<<<<
15175  *
15176  * cpdef inline asin(obj,i = None):
15177  */
15178  __Pyx_XDECREF(__pyx_r);
15179  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1696; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
15180  __Pyx_GOTREF(__pyx_t_3);
15181  __pyx_t_11 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_3), sin(__pyx_f_8PyClical_toClifford(__pyx_v_obj))); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1696; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
15182  __Pyx_GOTREF(__pyx_t_11);
15183  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
15184  __pyx_r = __pyx_t_11;
15185  __pyx_t_11 = 0;
15186  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
15187  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
15188  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
15189  goto __pyx_L7_except_return;
15190  }
15191  __pyx_L6_except_error:;
15192 
15193  /* "PyClical.pyx":1693
15194  * return clifford().wrap( glucat.sin(toClifford(obj), toClifford(i)) )
15195  * else:
15196  * try: # <<<<<<<<<<<<<<
15197  * return math.sin(obj)
15198  * except:
15199  */
15200  __Pyx_XGIVEREF(__pyx_t_6);
15201  __Pyx_XGIVEREF(__pyx_t_7);
15202  __Pyx_XGIVEREF(__pyx_t_8);
15203  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
15204  goto __pyx_L1_error;
15205  __pyx_L8_try_return:;
15206  __Pyx_XGIVEREF(__pyx_t_6);
15207  __Pyx_XGIVEREF(__pyx_t_7);
15208  __Pyx_XGIVEREF(__pyx_t_8);
15209  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
15210  goto __pyx_L0;
15211  __pyx_L7_except_return:;
15212  __Pyx_XGIVEREF(__pyx_t_6);
15213  __Pyx_XGIVEREF(__pyx_t_7);
15214  __Pyx_XGIVEREF(__pyx_t_8);
15215  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
15216  goto __pyx_L0;
15217  }
15218  }
15219 
15220  /* "PyClical.pyx":1679
15221  * return clifford().wrap( glucat.acosh(toClifford(obj)) )
15222  *
15223  * cpdef inline sin(obj,i = None): # <<<<<<<<<<<<<<
15224  * """
15225  * Sine of multivector with optional complexifier.
15226  */
15227 
15228  /* function exit code */
15229  __pyx_L1_error:;
15230  __Pyx_XDECREF(__pyx_t_3);
15231  __Pyx_XDECREF(__pyx_t_5);
15232  __Pyx_XDECREF(__pyx_t_9);
15233  __Pyx_XDECREF(__pyx_t_10);
15234  __Pyx_XDECREF(__pyx_t_11);
15235  __Pyx_AddTraceback("PyClical.sin", __pyx_clineno, __pyx_lineno, __pyx_filename);
15236  __pyx_r = 0;
15237  __pyx_L0:;
15238  __Pyx_XGIVEREF(__pyx_r);
15239  __Pyx_RefNannyFinishContext();
15240  return __pyx_r;
15241  }
15242 
15243  /* Python wrapper */
15244  static PyObject *__pyx_pw_8PyClical_59sin(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
15245  static char __pyx_doc_8PyClical_58sin[] = "\n Sine of multivector with optional complexifier.\n\n >>> s=\"{-1}\"; x=clifford(s); print asin(sin(x,s),s)\n {-1}\n >>> s=\"{-1}\"; x=clifford(s); print asin(sin(x,s),\"{-2,-1,1}\")\n {-1}\n >>> x=clifford(\"{1,2,3}\"); print asin(sin(x))\n {1,2,3}\n ";
15246  static PyObject *__pyx_pw_8PyClical_59sin(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
15247  PyObject *__pyx_v_obj = 0;
15248  PyObject *__pyx_v_i = 0;
15249  int __pyx_lineno = 0;
15250  const char *__pyx_filename = NULL;
15251  int __pyx_clineno = 0;
15252  PyObject *__pyx_r = 0;
15253  __Pyx_RefNannyDeclarations
15254  __Pyx_RefNannySetupContext("sin (wrapper)", 0);
15255  {
15256  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_obj,&__pyx_n_s_i,0};
15257  PyObject* values[2] = {0,0};
15258  values[1] = ((PyObject *)Py_None);
15259  if (unlikely(__pyx_kwds)) {
15260  Py_ssize_t kw_args;
15261  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
15262  switch (pos_args) {
15263  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
15264  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
15265  case 0: break;
15266  default: goto __pyx_L5_argtuple_error;
15267  }
15268  kw_args = PyDict_Size(__pyx_kwds);
15269  switch (pos_args) {
15270  case 0:
15271  if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_obj)) != 0)) kw_args--;
15272  else goto __pyx_L5_argtuple_error;
15273  case 1:
15274  if (kw_args > 0) {
15275  PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_i);
15276  if (value) { values[1] = value; kw_args--; }
15277  }
15278  }
15279  if (unlikely(kw_args > 0)) {
15280  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "sin") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1679; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
15281  }
15282  } else {
15283  switch (PyTuple_GET_SIZE(__pyx_args)) {
15284  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
15285  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
15286  break;
15287  default: goto __pyx_L5_argtuple_error;
15288  }
15289  }
15290  __pyx_v_obj = values[0];
15291  __pyx_v_i = values[1];
15292  }
15293  goto __pyx_L4_argument_unpacking_done;
15294  __pyx_L5_argtuple_error:;
15295  __Pyx_RaiseArgtupleInvalid("sin", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1679; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
15296  __pyx_L3_error:;
15297  __Pyx_AddTraceback("PyClical.sin", __pyx_clineno, __pyx_lineno, __pyx_filename);
15298  __Pyx_RefNannyFinishContext();
15299  return NULL;
15300  __pyx_L4_argument_unpacking_done:;
15301  __pyx_r = __pyx_pf_8PyClical_58sin(__pyx_self, __pyx_v_obj, __pyx_v_i);
15302 
15303  /* function exit code */
15304  __Pyx_RefNannyFinishContext();
15305  return __pyx_r;
15306  }
15307 
15308  static PyObject *__pyx_pf_8PyClical_58sin(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_i) {
15309  PyObject *__pyx_r = NULL;
15310  __Pyx_RefNannyDeclarations
15311  PyObject *__pyx_t_1 = NULL;
15312  struct __pyx_opt_args_8PyClical_sin __pyx_t_2;
15313  int __pyx_lineno = 0;
15314  const char *__pyx_filename = NULL;
15315  int __pyx_clineno = 0;
15316  __Pyx_RefNannySetupContext("sin", 0);
15317  __Pyx_XDECREF(__pyx_r);
15318  __pyx_t_2.__pyx_n = 1;
15319  __pyx_t_2.i = __pyx_v_i;
15320  __pyx_t_1 = __pyx_f_8PyClical_sin(__pyx_v_obj, 0, &__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1679; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
15321  __Pyx_GOTREF(__pyx_t_1);
15322  __pyx_r = __pyx_t_1;
15323  __pyx_t_1 = 0;
15324  goto __pyx_L0;
15325 
15326  /* function exit code */
15327  __pyx_L1_error:;
15328  __Pyx_XDECREF(__pyx_t_1);
15329  __Pyx_AddTraceback("PyClical.sin", __pyx_clineno, __pyx_lineno, __pyx_filename);
15330  __pyx_r = NULL;
15331  __pyx_L0:;
15332  __Pyx_XGIVEREF(__pyx_r);
15333  __Pyx_RefNannyFinishContext();
15334  return __pyx_r;
15335  }
15336 
15337  /* "PyClical.pyx":1698
15338  * return clifford().wrap( glucat.sin(toClifford(obj)) )
15339  *
15340  * cpdef inline asin(obj,i = None): # <<<<<<<<<<<<<<
15341  * """
15342  * Inverse sine of multivector with optional complexifier.
15343  */
15344 
15345  static PyObject *__pyx_pw_8PyClical_61asin(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
15346  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_asin(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_asin *__pyx_optional_args) {
15347  PyObject *__pyx_v_i = ((PyObject *)Py_None);
15348  PyObject *__pyx_r = NULL;
15349  __Pyx_RefNannyDeclarations
15350  int __pyx_t_1;
15351  int __pyx_t_2;
15352  PyObject *__pyx_t_3 = NULL;
15353  Clifford __pyx_t_4;
15354  PyObject *__pyx_t_5 = NULL;
15355  PyObject *__pyx_t_6 = NULL;
15356  PyObject *__pyx_t_7 = NULL;
15357  PyObject *__pyx_t_8 = NULL;
15358  PyObject *__pyx_t_9 = NULL;
15359  PyObject *__pyx_t_10 = NULL;
15360  PyObject *__pyx_t_11 = NULL;
15361  int __pyx_lineno = 0;
15362  const char *__pyx_filename = NULL;
15363  int __pyx_clineno = 0;
15364  __Pyx_RefNannySetupContext("asin", 0);
15365  if (__pyx_optional_args) {
15366  if (__pyx_optional_args->__pyx_n > 0) {
15367  __pyx_v_i = __pyx_optional_args->i;
15368  }
15369  }
15370 
15371  /* "PyClical.pyx":1711
15372  * {1,2,3}
15373  * """
15374  * if not (i is None): # <<<<<<<<<<<<<<
15375  * return clifford().wrap( glucat.asin(toClifford(obj), toClifford(i)) )
15376  * else:
15377  */
15378  __pyx_t_1 = (__pyx_v_i != Py_None);
15379  __pyx_t_2 = (__pyx_t_1 != 0);
15380  if (__pyx_t_2) {
15381 
15382  /* "PyClical.pyx":1712
15383  * """
15384  * if not (i is None):
15385  * return clifford().wrap( glucat.asin(toClifford(obj), toClifford(i)) ) # <<<<<<<<<<<<<<
15386  * else:
15387  * try:
15388  */
15389  __Pyx_XDECREF(__pyx_r);
15390  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1712; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
15391  __Pyx_GOTREF(__pyx_t_3);
15392  try {
15393  __pyx_t_4 = asin(__pyx_f_8PyClical_toClifford(__pyx_v_obj), __pyx_f_8PyClical_toClifford(__pyx_v_i));
15394  } catch(...) {
15395  __Pyx_CppExn2PyErr();
15396  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1712; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
15397  }
15398  __pyx_t_5 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_3), __pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1712; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
15399  __Pyx_GOTREF(__pyx_t_5);
15400  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
15401  __pyx_r = __pyx_t_5;
15402  __pyx_t_5 = 0;
15403  goto __pyx_L0;
15404 
15405  /* "PyClical.pyx":1711
15406  * {1,2,3}
15407  * """
15408  * if not (i is None): # <<<<<<<<<<<<<<
15409  * return clifford().wrap( glucat.asin(toClifford(obj), toClifford(i)) )
15410  * else:
15411  */
15412  }
15413 
15414  /* "PyClical.pyx":1714
15415  * return clifford().wrap( glucat.asin(toClifford(obj), toClifford(i)) )
15416  * else:
15417  * try: # <<<<<<<<<<<<<<
15418  * return math.asin(obj)
15419  * except:
15420  */
15421  /*else*/ {
15422  {
15423  __Pyx_ExceptionSave(&__pyx_t_6, &__pyx_t_7, &__pyx_t_8);
15424  __Pyx_XGOTREF(__pyx_t_6);
15425  __Pyx_XGOTREF(__pyx_t_7);
15426  __Pyx_XGOTREF(__pyx_t_8);
15427  /*try:*/ {
15428 
15429  /* "PyClical.pyx":1715
15430  * else:
15431  * try:
15432  * return math.asin(obj) # <<<<<<<<<<<<<<
15433  * except:
15434  * return clifford().wrap( glucat.asin(toClifford(obj)) )
15435  */
15436  __Pyx_XDECREF(__pyx_r);
15437  __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_math); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1715; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
15438  __Pyx_GOTREF(__pyx_t_3);
15439  __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_asin); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1715; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
15440  __Pyx_GOTREF(__pyx_t_9);
15441  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
15442  __pyx_t_3 = NULL;
15443  if (CYTHON_COMPILING_IN_CPYTHON && unlikely(PyMethod_Check(__pyx_t_9))) {
15444  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_9);
15445  if (likely(__pyx_t_3)) {
15446  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_9);
15447  __Pyx_INCREF(__pyx_t_3);
15448  __Pyx_INCREF(function);
15449  __Pyx_DECREF_SET(__pyx_t_9, function);
15450  }
15451  }
15452  if (!__pyx_t_3) {
15453  __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_t_9, __pyx_v_obj); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1715; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
15454  __Pyx_GOTREF(__pyx_t_5);
15455  } else {
15456  __pyx_t_10 = PyTuple_New(1+1); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1715; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
15457  __Pyx_GOTREF(__pyx_t_10);
15458  __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_3); __pyx_t_3 = NULL;
15459  __Pyx_INCREF(__pyx_v_obj);
15460  __Pyx_GIVEREF(__pyx_v_obj);
15461  PyTuple_SET_ITEM(__pyx_t_10, 0+1, __pyx_v_obj);
15462  __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1715; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
15463  __Pyx_GOTREF(__pyx_t_5);
15464  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
15465  }
15466  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
15467  __pyx_r = __pyx_t_5;
15468  __pyx_t_5 = 0;
15469  goto __pyx_L8_try_return;
15470 
15471  /* "PyClical.pyx":1714
15472  * return clifford().wrap( glucat.asin(toClifford(obj), toClifford(i)) )
15473  * else:
15474  * try: # <<<<<<<<<<<<<<
15475  * return math.asin(obj)
15476  * except:
15477  */
15478  }
15479  __pyx_L4_error:;
15480  __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
15481  __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0;
15482  __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
15483  __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
15484 
15485  /* "PyClical.pyx":1716
15486  * try:
15487  * return math.asin(obj)
15488  * except: # <<<<<<<<<<<<<<
15489  * return clifford().wrap( glucat.asin(toClifford(obj)) )
15490  *
15491  */
15492  /*except:*/ {
15493  __Pyx_AddTraceback("PyClical.asin", __pyx_clineno, __pyx_lineno, __pyx_filename);
15494  if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_9, &__pyx_t_10) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1716; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
15495  __Pyx_GOTREF(__pyx_t_5);
15496  __Pyx_GOTREF(__pyx_t_9);
15497  __Pyx_GOTREF(__pyx_t_10);
15498 
15499  /* "PyClical.pyx":1717
15500  * return math.asin(obj)
15501  * except:
15502  * return clifford().wrap( glucat.asin(toClifford(obj)) ) # <<<<<<<<<<<<<<
15503  *
15504  * cpdef inline sinh(obj):
15505  */
15506  __Pyx_XDECREF(__pyx_r);
15507  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1717; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
15508  __Pyx_GOTREF(__pyx_t_3);
15509  __pyx_t_11 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_3), asin(__pyx_f_8PyClical_toClifford(__pyx_v_obj))); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1717; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
15510  __Pyx_GOTREF(__pyx_t_11);
15511  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
15512  __pyx_r = __pyx_t_11;
15513  __pyx_t_11 = 0;
15514  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
15515  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
15516  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
15517  goto __pyx_L7_except_return;
15518  }
15519  __pyx_L6_except_error:;
15520 
15521  /* "PyClical.pyx":1714
15522  * return clifford().wrap( glucat.asin(toClifford(obj), toClifford(i)) )
15523  * else:
15524  * try: # <<<<<<<<<<<<<<
15525  * return math.asin(obj)
15526  * except:
15527  */
15528  __Pyx_XGIVEREF(__pyx_t_6);
15529  __Pyx_XGIVEREF(__pyx_t_7);
15530  __Pyx_XGIVEREF(__pyx_t_8);
15531  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
15532  goto __pyx_L1_error;
15533  __pyx_L8_try_return:;
15534  __Pyx_XGIVEREF(__pyx_t_6);
15535  __Pyx_XGIVEREF(__pyx_t_7);
15536  __Pyx_XGIVEREF(__pyx_t_8);
15537  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
15538  goto __pyx_L0;
15539  __pyx_L7_except_return:;
15540  __Pyx_XGIVEREF(__pyx_t_6);
15541  __Pyx_XGIVEREF(__pyx_t_7);
15542  __Pyx_XGIVEREF(__pyx_t_8);
15543  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
15544  goto __pyx_L0;
15545  }
15546  }
15547 
15548  /* "PyClical.pyx":1698
15549  * return clifford().wrap( glucat.sin(toClifford(obj)) )
15550  *
15551  * cpdef inline asin(obj,i = None): # <<<<<<<<<<<<<<
15552  * """
15553  * Inverse sine of multivector with optional complexifier.
15554  */
15555 
15556  /* function exit code */
15557  __pyx_L1_error:;
15558  __Pyx_XDECREF(__pyx_t_3);
15559  __Pyx_XDECREF(__pyx_t_5);
15560  __Pyx_XDECREF(__pyx_t_9);
15561  __Pyx_XDECREF(__pyx_t_10);
15562  __Pyx_XDECREF(__pyx_t_11);
15563  __Pyx_AddTraceback("PyClical.asin", __pyx_clineno, __pyx_lineno, __pyx_filename);
15564  __pyx_r = 0;
15565  __pyx_L0:;
15566  __Pyx_XGIVEREF(__pyx_r);
15567  __Pyx_RefNannyFinishContext();
15568  return __pyx_r;
15569  }
15570 
15571  /* Python wrapper */
15572  static PyObject *__pyx_pw_8PyClical_61asin(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
15573  static char __pyx_doc_8PyClical_60asin[] = "\n Inverse sine of multivector with optional complexifier.\n\n >>> s=\"{-1}\"; x=clifford(s); print asin(sin(x,s),s)\n {-1}\n >>> s=\"{-1}\"; x=clifford(s); print asin(sin(x,s),\"{-2,-1,1}\")\n {-1}\n >>> print asin(1) / pi\n 0.5\n >>> x=clifford(\"{1,2,3}\"); print asin(sin(x))\n {1,2,3}\n ";
15574  static PyObject *__pyx_pw_8PyClical_61asin(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
15575  PyObject *__pyx_v_obj = 0;
15576  PyObject *__pyx_v_i = 0;
15577  int __pyx_lineno = 0;
15578  const char *__pyx_filename = NULL;
15579  int __pyx_clineno = 0;
15580  PyObject *__pyx_r = 0;
15581  __Pyx_RefNannyDeclarations
15582  __Pyx_RefNannySetupContext("asin (wrapper)", 0);
15583  {
15584  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_obj,&__pyx_n_s_i,0};
15585  PyObject* values[2] = {0,0};
15586  values[1] = ((PyObject *)Py_None);
15587  if (unlikely(__pyx_kwds)) {
15588  Py_ssize_t kw_args;
15589  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
15590  switch (pos_args) {
15591  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
15592  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
15593  case 0: break;
15594  default: goto __pyx_L5_argtuple_error;
15595  }
15596  kw_args = PyDict_Size(__pyx_kwds);
15597  switch (pos_args) {
15598  case 0:
15599  if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_obj)) != 0)) kw_args--;
15600  else goto __pyx_L5_argtuple_error;
15601  case 1:
15602  if (kw_args > 0) {
15603  PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_i);
15604  if (value) { values[1] = value; kw_args--; }
15605  }
15606  }
15607  if (unlikely(kw_args > 0)) {
15608  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "asin") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1698; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
15609  }
15610  } else {
15611  switch (PyTuple_GET_SIZE(__pyx_args)) {
15612  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
15613  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
15614  break;
15615  default: goto __pyx_L5_argtuple_error;
15616  }
15617  }
15618  __pyx_v_obj = values[0];
15619  __pyx_v_i = values[1];
15620  }
15621  goto __pyx_L4_argument_unpacking_done;
15622  __pyx_L5_argtuple_error:;
15623  __Pyx_RaiseArgtupleInvalid("asin", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1698; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
15624  __pyx_L3_error:;
15625  __Pyx_AddTraceback("PyClical.asin", __pyx_clineno, __pyx_lineno, __pyx_filename);
15626  __Pyx_RefNannyFinishContext();
15627  return NULL;
15628  __pyx_L4_argument_unpacking_done:;
15629  __pyx_r = __pyx_pf_8PyClical_60asin(__pyx_self, __pyx_v_obj, __pyx_v_i);
15630 
15631  /* function exit code */
15632  __Pyx_RefNannyFinishContext();
15633  return __pyx_r;
15634  }
15635 
15636  static PyObject *__pyx_pf_8PyClical_60asin(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_i) {
15637  PyObject *__pyx_r = NULL;
15638  __Pyx_RefNannyDeclarations
15639  PyObject *__pyx_t_1 = NULL;
15640  struct __pyx_opt_args_8PyClical_asin __pyx_t_2;
15641  int __pyx_lineno = 0;
15642  const char *__pyx_filename = NULL;
15643  int __pyx_clineno = 0;
15644  __Pyx_RefNannySetupContext("asin", 0);
15645  __Pyx_XDECREF(__pyx_r);
15646  __pyx_t_2.__pyx_n = 1;
15647  __pyx_t_2.i = __pyx_v_i;
15648  __pyx_t_1 = __pyx_f_8PyClical_asin(__pyx_v_obj, 0, &__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1698; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
15649  __Pyx_GOTREF(__pyx_t_1);
15650  __pyx_r = __pyx_t_1;
15651  __pyx_t_1 = 0;
15652  goto __pyx_L0;
15653 
15654  /* function exit code */
15655  __pyx_L1_error:;
15656  __Pyx_XDECREF(__pyx_t_1);
15657  __Pyx_AddTraceback("PyClical.asin", __pyx_clineno, __pyx_lineno, __pyx_filename);
15658  __pyx_r = NULL;
15659  __pyx_L0:;
15660  __Pyx_XGIVEREF(__pyx_r);
15661  __Pyx_RefNannyFinishContext();
15662  return __pyx_r;
15663  }
15664 
15665  /* "PyClical.pyx":1719
15666  * return clifford().wrap( glucat.asin(toClifford(obj)) )
15667  *
15668  * cpdef inline sinh(obj): # <<<<<<<<<<<<<<
15669  * """
15670  * Hyperbolic sine of multivector.
15671  */
15672 
15673  static PyObject *__pyx_pw_8PyClical_63sinh(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
15674  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_sinh(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
15675  PyObject *__pyx_r = NULL;
15676  __Pyx_RefNannyDeclarations
15677  PyObject *__pyx_t_1 = NULL;
15678  PyObject *__pyx_t_2 = NULL;
15679  PyObject *__pyx_t_3 = NULL;
15680  PyObject *__pyx_t_4 = NULL;
15681  PyObject *__pyx_t_5 = NULL;
15682  PyObject *__pyx_t_6 = NULL;
15683  PyObject *__pyx_t_7 = NULL;
15684  PyObject *__pyx_t_8 = NULL;
15685  int __pyx_lineno = 0;
15686  const char *__pyx_filename = NULL;
15687  int __pyx_clineno = 0;
15688  __Pyx_RefNannySetupContext("sinh", 0);
15689 
15690  /* "PyClical.pyx":1728
15691  * 0.5{1,2}
15692  * """
15693  * try: # <<<<<<<<<<<<<<
15694  * return math.sinh(obj)
15695  * except:
15696  */
15697  {
15698  __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3);
15699  __Pyx_XGOTREF(__pyx_t_1);
15700  __Pyx_XGOTREF(__pyx_t_2);
15701  __Pyx_XGOTREF(__pyx_t_3);
15702  /*try:*/ {
15703 
15704  /* "PyClical.pyx":1729
15705  * """
15706  * try:
15707  * return math.sinh(obj) # <<<<<<<<<<<<<<
15708  * except:
15709  * return clifford().wrap( glucat.sinh(toClifford(obj)) )
15710  */
15711  __Pyx_XDECREF(__pyx_r);
15712  __pyx_t_5 = __Pyx_GetModuleGlobalName(__pyx_n_s_math); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1729; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
15713  __Pyx_GOTREF(__pyx_t_5);
15714  __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_sinh); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1729; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
15715  __Pyx_GOTREF(__pyx_t_6);
15716  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
15717  __pyx_t_5 = NULL;
15718  if (CYTHON_COMPILING_IN_CPYTHON && unlikely(PyMethod_Check(__pyx_t_6))) {
15719  __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_6);
15720  if (likely(__pyx_t_5)) {
15721  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6);
15722  __Pyx_INCREF(__pyx_t_5);
15723  __Pyx_INCREF(function);
15724  __Pyx_DECREF_SET(__pyx_t_6, function);
15725  }
15726  }
15727  if (!__pyx_t_5) {
15728  __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_obj); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1729; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
15729  __Pyx_GOTREF(__pyx_t_4);
15730  } else {
15731  __pyx_t_7 = PyTuple_New(1+1); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1729; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
15732  __Pyx_GOTREF(__pyx_t_7);
15733  __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_5); __pyx_t_5 = NULL;
15734  __Pyx_INCREF(__pyx_v_obj);
15735  __Pyx_GIVEREF(__pyx_v_obj);
15736  PyTuple_SET_ITEM(__pyx_t_7, 0+1, __pyx_v_obj);
15737  __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_7, NULL); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1729; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
15738  __Pyx_GOTREF(__pyx_t_4);
15739  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
15740  }
15741  __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
15742  __pyx_r = __pyx_t_4;
15743  __pyx_t_4 = 0;
15744  goto __pyx_L7_try_return;
15745 
15746  /* "PyClical.pyx":1728
15747  * 0.5{1,2}
15748  * """
15749  * try: # <<<<<<<<<<<<<<
15750  * return math.sinh(obj)
15751  * except:
15752  */
15753  }
15754  __pyx_L3_error:;
15755  __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
15756  __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
15757  __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
15758  __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
15759 
15760  /* "PyClical.pyx":1730
15761  * try:
15762  * return math.sinh(obj)
15763  * except: # <<<<<<<<<<<<<<
15764  * return clifford().wrap( glucat.sinh(toClifford(obj)) )
15765  *
15766  */
15767  /*except:*/ {
15768  __Pyx_AddTraceback("PyClical.sinh", __pyx_clineno, __pyx_lineno, __pyx_filename);
15769  if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_7) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1730; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
15770  __Pyx_GOTREF(__pyx_t_4);
15771  __Pyx_GOTREF(__pyx_t_6);
15772  __Pyx_GOTREF(__pyx_t_7);
15773 
15774  /* "PyClical.pyx":1731
15775  * return math.sinh(obj)
15776  * except:
15777  * return clifford().wrap( glucat.sinh(toClifford(obj)) ) # <<<<<<<<<<<<<<
15778  *
15779  * cpdef inline asinh(obj,i = None):
15780  */
15781  __Pyx_XDECREF(__pyx_r);
15782  __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1731; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
15783  __Pyx_GOTREF(__pyx_t_5);
15784  __pyx_t_8 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_5), sinh(__pyx_f_8PyClical_toClifford(__pyx_v_obj))); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1731; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
15785  __Pyx_GOTREF(__pyx_t_8);
15786  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
15787  __pyx_r = __pyx_t_8;
15788  __pyx_t_8 = 0;
15789  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
15790  __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
15791  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
15792  goto __pyx_L6_except_return;
15793  }
15794  __pyx_L5_except_error:;
15795 
15796  /* "PyClical.pyx":1728
15797  * 0.5{1,2}
15798  * """
15799  * try: # <<<<<<<<<<<<<<
15800  * return math.sinh(obj)
15801  * except:
15802  */
15803  __Pyx_XGIVEREF(__pyx_t_1);
15804  __Pyx_XGIVEREF(__pyx_t_2);
15805  __Pyx_XGIVEREF(__pyx_t_3);
15806  __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
15807  goto __pyx_L1_error;
15808  __pyx_L7_try_return:;
15809  __Pyx_XGIVEREF(__pyx_t_1);
15810  __Pyx_XGIVEREF(__pyx_t_2);
15811  __Pyx_XGIVEREF(__pyx_t_3);
15812  __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
15813  goto __pyx_L0;
15814  __pyx_L6_except_return:;
15815  __Pyx_XGIVEREF(__pyx_t_1);
15816  __Pyx_XGIVEREF(__pyx_t_2);
15817  __Pyx_XGIVEREF(__pyx_t_3);
15818  __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
15819  goto __pyx_L0;
15820  }
15821 
15822  /* "PyClical.pyx":1719
15823  * return clifford().wrap( glucat.asin(toClifford(obj)) )
15824  *
15825  * cpdef inline sinh(obj): # <<<<<<<<<<<<<<
15826  * """
15827  * Hyperbolic sine of multivector.
15828  */
15829 
15830  /* function exit code */
15831  __pyx_L1_error:;
15832  __Pyx_XDECREF(__pyx_t_4);
15833  __Pyx_XDECREF(__pyx_t_5);
15834  __Pyx_XDECREF(__pyx_t_6);
15835  __Pyx_XDECREF(__pyx_t_7);
15836  __Pyx_XDECREF(__pyx_t_8);
15837  __Pyx_AddTraceback("PyClical.sinh", __pyx_clineno, __pyx_lineno, __pyx_filename);
15838  __pyx_r = 0;
15839  __pyx_L0:;
15840  __Pyx_XGIVEREF(__pyx_r);
15841  __Pyx_RefNannyFinishContext();
15842  return __pyx_r;
15843  }
15844 
15845  /* Python wrapper */
15846  static PyObject *__pyx_pw_8PyClical_63sinh(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
15847  static char __pyx_doc_8PyClical_62sinh[] = "\n Hyperbolic sine of multivector.\n\n >>> x=clifford(\"{1,2}\") * pi/2; print sinh(x)\n {1,2}\n >>> x=clifford(\"{1,2}\") * pi/6; print sinh(x)\n 0.5{1,2}\n ";
15848  static PyObject *__pyx_pw_8PyClical_63sinh(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
15849  PyObject *__pyx_r = 0;
15850  __Pyx_RefNannyDeclarations
15851  __Pyx_RefNannySetupContext("sinh (wrapper)", 0);
15852  __pyx_r = __pyx_pf_8PyClical_62sinh(__pyx_self, ((PyObject *)__pyx_v_obj));
15853 
15854  /* function exit code */
15855  __Pyx_RefNannyFinishContext();
15856  return __pyx_r;
15857  }
15858 
15859  static PyObject *__pyx_pf_8PyClical_62sinh(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
15860  PyObject *__pyx_r = NULL;
15861  __Pyx_RefNannyDeclarations
15862  PyObject *__pyx_t_1 = NULL;
15863  int __pyx_lineno = 0;
15864  const char *__pyx_filename = NULL;
15865  int __pyx_clineno = 0;
15866  __Pyx_RefNannySetupContext("sinh", 0);
15867  __Pyx_XDECREF(__pyx_r);
15868  __pyx_t_1 = __pyx_f_8PyClical_sinh(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1719; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
15869  __Pyx_GOTREF(__pyx_t_1);
15870  __pyx_r = __pyx_t_1;
15871  __pyx_t_1 = 0;
15872  goto __pyx_L0;
15873 
15874  /* function exit code */
15875  __pyx_L1_error:;
15876  __Pyx_XDECREF(__pyx_t_1);
15877  __Pyx_AddTraceback("PyClical.sinh", __pyx_clineno, __pyx_lineno, __pyx_filename);
15878  __pyx_r = NULL;
15879  __pyx_L0:;
15880  __Pyx_XGIVEREF(__pyx_r);
15881  __Pyx_RefNannyFinishContext();
15882  return __pyx_r;
15883  }
15884 
15885  /* "PyClical.pyx":1733
15886  * return clifford().wrap( glucat.sinh(toClifford(obj)) )
15887  *
15888  * cpdef inline asinh(obj,i = None): # <<<<<<<<<<<<<<
15889  * """
15890  * Inverse hyperbolic sine of multivector with optional complexifier.
15891  */
15892 
15893  static PyObject *__pyx_pw_8PyClical_65asinh(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
15894  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_asinh(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_asinh *__pyx_optional_args) {
15895  PyObject *__pyx_v_i = ((PyObject *)Py_None);
15896  PyObject *__pyx_r = NULL;
15897  __Pyx_RefNannyDeclarations
15898  int __pyx_t_1;
15899  int __pyx_t_2;
15900  PyObject *__pyx_t_3 = NULL;
15901  Clifford __pyx_t_4;
15902  PyObject *__pyx_t_5 = NULL;
15903  PyObject *__pyx_t_6 = NULL;
15904  PyObject *__pyx_t_7 = NULL;
15905  PyObject *__pyx_t_8 = NULL;
15906  PyObject *__pyx_t_9 = NULL;
15907  PyObject *__pyx_t_10 = NULL;
15908  PyObject *__pyx_t_11 = NULL;
15909  int __pyx_lineno = 0;
15910  const char *__pyx_filename = NULL;
15911  int __pyx_clineno = 0;
15912  __Pyx_RefNannySetupContext("asinh", 0);
15913  if (__pyx_optional_args) {
15914  if (__pyx_optional_args->__pyx_n > 0) {
15915  __pyx_v_i = __pyx_optional_args->i;
15916  }
15917  }
15918 
15919  /* "PyClical.pyx":1744
15920  * {1,2}
15921  * """
15922  * if not (i is None): # <<<<<<<<<<<<<<
15923  * return clifford().wrap( glucat.asinh(toClifford(obj), toClifford(i)) )
15924  * else:
15925  */
15926  __pyx_t_1 = (__pyx_v_i != Py_None);
15927  __pyx_t_2 = (__pyx_t_1 != 0);
15928  if (__pyx_t_2) {
15929 
15930  /* "PyClical.pyx":1745
15931  * """
15932  * if not (i is None):
15933  * return clifford().wrap( glucat.asinh(toClifford(obj), toClifford(i)) ) # <<<<<<<<<<<<<<
15934  * else:
15935  * try:
15936  */
15937  __Pyx_XDECREF(__pyx_r);
15938  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1745; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
15939  __Pyx_GOTREF(__pyx_t_3);
15940  try {
15941  __pyx_t_4 = asinh(__pyx_f_8PyClical_toClifford(__pyx_v_obj), __pyx_f_8PyClical_toClifford(__pyx_v_i));
15942  } catch(...) {
15943  __Pyx_CppExn2PyErr();
15944  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1745; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
15945  }
15946  __pyx_t_5 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_3), __pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1745; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
15947  __Pyx_GOTREF(__pyx_t_5);
15948  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
15949  __pyx_r = __pyx_t_5;
15950  __pyx_t_5 = 0;
15951  goto __pyx_L0;
15952 
15953  /* "PyClical.pyx":1744
15954  * {1,2}
15955  * """
15956  * if not (i is None): # <<<<<<<<<<<<<<
15957  * return clifford().wrap( glucat.asinh(toClifford(obj), toClifford(i)) )
15958  * else:
15959  */
15960  }
15961 
15962  /* "PyClical.pyx":1747
15963  * return clifford().wrap( glucat.asinh(toClifford(obj), toClifford(i)) )
15964  * else:
15965  * try: # <<<<<<<<<<<<<<
15966  * return math.asinh(obj)
15967  * except:
15968  */
15969  /*else*/ {
15970  {
15971  __Pyx_ExceptionSave(&__pyx_t_6, &__pyx_t_7, &__pyx_t_8);
15972  __Pyx_XGOTREF(__pyx_t_6);
15973  __Pyx_XGOTREF(__pyx_t_7);
15974  __Pyx_XGOTREF(__pyx_t_8);
15975  /*try:*/ {
15976 
15977  /* "PyClical.pyx":1748
15978  * else:
15979  * try:
15980  * return math.asinh(obj) # <<<<<<<<<<<<<<
15981  * except:
15982  * return clifford().wrap( glucat.asinh(toClifford(obj)) )
15983  */
15984  __Pyx_XDECREF(__pyx_r);
15985  __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_math); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1748; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
15986  __Pyx_GOTREF(__pyx_t_3);
15987  __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_asinh); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1748; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
15988  __Pyx_GOTREF(__pyx_t_9);
15989  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
15990  __pyx_t_3 = NULL;
15991  if (CYTHON_COMPILING_IN_CPYTHON && unlikely(PyMethod_Check(__pyx_t_9))) {
15992  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_9);
15993  if (likely(__pyx_t_3)) {
15994  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_9);
15995  __Pyx_INCREF(__pyx_t_3);
15996  __Pyx_INCREF(function);
15997  __Pyx_DECREF_SET(__pyx_t_9, function);
15998  }
15999  }
16000  if (!__pyx_t_3) {
16001  __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_t_9, __pyx_v_obj); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1748; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
16002  __Pyx_GOTREF(__pyx_t_5);
16003  } else {
16004  __pyx_t_10 = PyTuple_New(1+1); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1748; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
16005  __Pyx_GOTREF(__pyx_t_10);
16006  __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_3); __pyx_t_3 = NULL;
16007  __Pyx_INCREF(__pyx_v_obj);
16008  __Pyx_GIVEREF(__pyx_v_obj);
16009  PyTuple_SET_ITEM(__pyx_t_10, 0+1, __pyx_v_obj);
16010  __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1748; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
16011  __Pyx_GOTREF(__pyx_t_5);
16012  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
16013  }
16014  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
16015  __pyx_r = __pyx_t_5;
16016  __pyx_t_5 = 0;
16017  goto __pyx_L8_try_return;
16018 
16019  /* "PyClical.pyx":1747
16020  * return clifford().wrap( glucat.asinh(toClifford(obj), toClifford(i)) )
16021  * else:
16022  * try: # <<<<<<<<<<<<<<
16023  * return math.asinh(obj)
16024  * except:
16025  */
16026  }
16027  __pyx_L4_error:;
16028  __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
16029  __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0;
16030  __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
16031  __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
16032 
16033  /* "PyClical.pyx":1749
16034  * try:
16035  * return math.asinh(obj)
16036  * except: # <<<<<<<<<<<<<<
16037  * return clifford().wrap( glucat.asinh(toClifford(obj)) )
16038  *
16039  */
16040  /*except:*/ {
16041  __Pyx_AddTraceback("PyClical.asinh", __pyx_clineno, __pyx_lineno, __pyx_filename);
16042  if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_9, &__pyx_t_10) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1749; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
16043  __Pyx_GOTREF(__pyx_t_5);
16044  __Pyx_GOTREF(__pyx_t_9);
16045  __Pyx_GOTREF(__pyx_t_10);
16046 
16047  /* "PyClical.pyx":1750
16048  * return math.asinh(obj)
16049  * except:
16050  * return clifford().wrap( glucat.asinh(toClifford(obj)) ) # <<<<<<<<<<<<<<
16051  *
16052  * cpdef inline tan(obj,i = None):
16053  */
16054  __Pyx_XDECREF(__pyx_r);
16055  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1750; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
16056  __Pyx_GOTREF(__pyx_t_3);
16057  __pyx_t_11 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_3), asinh(__pyx_f_8PyClical_toClifford(__pyx_v_obj))); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1750; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
16058  __Pyx_GOTREF(__pyx_t_11);
16059  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
16060  __pyx_r = __pyx_t_11;
16061  __pyx_t_11 = 0;
16062  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
16063  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
16064  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
16065  goto __pyx_L7_except_return;
16066  }
16067  __pyx_L6_except_error:;
16068 
16069  /* "PyClical.pyx":1747
16070  * return clifford().wrap( glucat.asinh(toClifford(obj), toClifford(i)) )
16071  * else:
16072  * try: # <<<<<<<<<<<<<<
16073  * return math.asinh(obj)
16074  * except:
16075  */
16076  __Pyx_XGIVEREF(__pyx_t_6);
16077  __Pyx_XGIVEREF(__pyx_t_7);
16078  __Pyx_XGIVEREF(__pyx_t_8);
16079  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
16080  goto __pyx_L1_error;
16081  __pyx_L8_try_return:;
16082  __Pyx_XGIVEREF(__pyx_t_6);
16083  __Pyx_XGIVEREF(__pyx_t_7);
16084  __Pyx_XGIVEREF(__pyx_t_8);
16085  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
16086  goto __pyx_L0;
16087  __pyx_L7_except_return:;
16088  __Pyx_XGIVEREF(__pyx_t_6);
16089  __Pyx_XGIVEREF(__pyx_t_7);
16090  __Pyx_XGIVEREF(__pyx_t_8);
16091  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
16092  goto __pyx_L0;
16093  }
16094  }
16095 
16096  /* "PyClical.pyx":1733
16097  * return clifford().wrap( glucat.sinh(toClifford(obj)) )
16098  *
16099  * cpdef inline asinh(obj,i = None): # <<<<<<<<<<<<<<
16100  * """
16101  * Inverse hyperbolic sine of multivector with optional complexifier.
16102  */
16103 
16104  /* function exit code */
16105  __pyx_L1_error:;
16106  __Pyx_XDECREF(__pyx_t_3);
16107  __Pyx_XDECREF(__pyx_t_5);
16108  __Pyx_XDECREF(__pyx_t_9);
16109  __Pyx_XDECREF(__pyx_t_10);
16110  __Pyx_XDECREF(__pyx_t_11);
16111  __Pyx_AddTraceback("PyClical.asinh", __pyx_clineno, __pyx_lineno, __pyx_filename);
16112  __pyx_r = 0;
16113  __pyx_L0:;
16114  __Pyx_XGIVEREF(__pyx_r);
16115  __Pyx_RefNannyFinishContext();
16116  return __pyx_r;
16117  }
16118 
16119  /* Python wrapper */
16120  static PyObject *__pyx_pw_8PyClical_65asinh(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
16121  static char __pyx_doc_8PyClical_64asinh[] = "\n Inverse hyperbolic sine of multivector with optional complexifier.\n\n >>> x=clifford(\"{1,2}\"); print asinh(x,\"{1,2,3}\") * 2/pi\n {1,2}\n >>> x=clifford(\"{1,2}\"); print asinh(x) * 2/pi\n {1,2}\n >>> x=clifford(\"{1,2}\") / 2; print asinh(x) * 6/pi\n {1,2}\n ";
16122  static PyObject *__pyx_pw_8PyClical_65asinh(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
16123  PyObject *__pyx_v_obj = 0;
16124  PyObject *__pyx_v_i = 0;
16125  int __pyx_lineno = 0;
16126  const char *__pyx_filename = NULL;
16127  int __pyx_clineno = 0;
16128  PyObject *__pyx_r = 0;
16129  __Pyx_RefNannyDeclarations
16130  __Pyx_RefNannySetupContext("asinh (wrapper)", 0);
16131  {
16132  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_obj,&__pyx_n_s_i,0};
16133  PyObject* values[2] = {0,0};
16134  values[1] = ((PyObject *)Py_None);
16135  if (unlikely(__pyx_kwds)) {
16136  Py_ssize_t kw_args;
16137  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
16138  switch (pos_args) {
16139  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
16140  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
16141  case 0: break;
16142  default: goto __pyx_L5_argtuple_error;
16143  }
16144  kw_args = PyDict_Size(__pyx_kwds);
16145  switch (pos_args) {
16146  case 0:
16147  if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_obj)) != 0)) kw_args--;
16148  else goto __pyx_L5_argtuple_error;
16149  case 1:
16150  if (kw_args > 0) {
16151  PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_i);
16152  if (value) { values[1] = value; kw_args--; }
16153  }
16154  }
16155  if (unlikely(kw_args > 0)) {
16156  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "asinh") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1733; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
16157  }
16158  } else {
16159  switch (PyTuple_GET_SIZE(__pyx_args)) {
16160  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
16161  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
16162  break;
16163  default: goto __pyx_L5_argtuple_error;
16164  }
16165  }
16166  __pyx_v_obj = values[0];
16167  __pyx_v_i = values[1];
16168  }
16169  goto __pyx_L4_argument_unpacking_done;
16170  __pyx_L5_argtuple_error:;
16171  __Pyx_RaiseArgtupleInvalid("asinh", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1733; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
16172  __pyx_L3_error:;
16173  __Pyx_AddTraceback("PyClical.asinh", __pyx_clineno, __pyx_lineno, __pyx_filename);
16174  __Pyx_RefNannyFinishContext();
16175  return NULL;
16176  __pyx_L4_argument_unpacking_done:;
16177  __pyx_r = __pyx_pf_8PyClical_64asinh(__pyx_self, __pyx_v_obj, __pyx_v_i);
16178 
16179  /* function exit code */
16180  __Pyx_RefNannyFinishContext();
16181  return __pyx_r;
16182  }
16183 
16184  static PyObject *__pyx_pf_8PyClical_64asinh(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_i) {
16185  PyObject *__pyx_r = NULL;
16186  __Pyx_RefNannyDeclarations
16187  PyObject *__pyx_t_1 = NULL;
16188  struct __pyx_opt_args_8PyClical_asinh __pyx_t_2;
16189  int __pyx_lineno = 0;
16190  const char *__pyx_filename = NULL;
16191  int __pyx_clineno = 0;
16192  __Pyx_RefNannySetupContext("asinh", 0);
16193  __Pyx_XDECREF(__pyx_r);
16194  __pyx_t_2.__pyx_n = 1;
16195  __pyx_t_2.i = __pyx_v_i;
16196  __pyx_t_1 = __pyx_f_8PyClical_asinh(__pyx_v_obj, 0, &__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1733; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
16197  __Pyx_GOTREF(__pyx_t_1);
16198  __pyx_r = __pyx_t_1;
16199  __pyx_t_1 = 0;
16200  goto __pyx_L0;
16201 
16202  /* function exit code */
16203  __pyx_L1_error:;
16204  __Pyx_XDECREF(__pyx_t_1);
16205  __Pyx_AddTraceback("PyClical.asinh", __pyx_clineno, __pyx_lineno, __pyx_filename);
16206  __pyx_r = NULL;
16207  __pyx_L0:;
16208  __Pyx_XGIVEREF(__pyx_r);
16209  __Pyx_RefNannyFinishContext();
16210  return __pyx_r;
16211  }
16212 
16213  /* "PyClical.pyx":1752
16214  * return clifford().wrap( glucat.asinh(toClifford(obj)) )
16215  *
16216  * cpdef inline tan(obj,i = None): # <<<<<<<<<<<<<<
16217  * """
16218  * Tangent of multivector with optional complexifier.
16219  */
16220 
16221  static PyObject *__pyx_pw_8PyClical_67tan(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
16222  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_tan(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_tan *__pyx_optional_args) {
16223  PyObject *__pyx_v_i = ((PyObject *)Py_None);
16224  PyObject *__pyx_r = NULL;
16225  __Pyx_RefNannyDeclarations
16226  int __pyx_t_1;
16227  int __pyx_t_2;
16228  PyObject *__pyx_t_3 = NULL;
16229  Clifford __pyx_t_4;
16230  PyObject *__pyx_t_5 = NULL;
16231  PyObject *__pyx_t_6 = NULL;
16232  PyObject *__pyx_t_7 = NULL;
16233  PyObject *__pyx_t_8 = NULL;
16234  PyObject *__pyx_t_9 = NULL;
16235  PyObject *__pyx_t_10 = NULL;
16236  PyObject *__pyx_t_11 = NULL;
16237  int __pyx_lineno = 0;
16238  const char *__pyx_filename = NULL;
16239  int __pyx_clineno = 0;
16240  __Pyx_RefNannySetupContext("tan", 0);
16241  if (__pyx_optional_args) {
16242  if (__pyx_optional_args->__pyx_n > 0) {
16243  __pyx_v_i = __pyx_optional_args->i;
16244  }
16245  }
16246 
16247  /* "PyClical.pyx":1761
16248  * 0.7616{1,2}
16249  * """
16250  * if not (i is None): # <<<<<<<<<<<<<<
16251  * return clifford().wrap( glucat.tan(toClifford(obj), toClifford(i)) )
16252  * else:
16253  */
16254  __pyx_t_1 = (__pyx_v_i != Py_None);
16255  __pyx_t_2 = (__pyx_t_1 != 0);
16256  if (__pyx_t_2) {
16257 
16258  /* "PyClical.pyx":1762
16259  * """
16260  * if not (i is None):
16261  * return clifford().wrap( glucat.tan(toClifford(obj), toClifford(i)) ) # <<<<<<<<<<<<<<
16262  * else:
16263  * try:
16264  */
16265  __Pyx_XDECREF(__pyx_r);
16266  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1762; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
16267  __Pyx_GOTREF(__pyx_t_3);
16268  try {
16269  __pyx_t_4 = tan(__pyx_f_8PyClical_toClifford(__pyx_v_obj), __pyx_f_8PyClical_toClifford(__pyx_v_i));
16270  } catch(...) {
16271  __Pyx_CppExn2PyErr();
16272  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1762; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
16273  }
16274  __pyx_t_5 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_3), __pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1762; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
16275  __Pyx_GOTREF(__pyx_t_5);
16276  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
16277  __pyx_r = __pyx_t_5;
16278  __pyx_t_5 = 0;
16279  goto __pyx_L0;
16280 
16281  /* "PyClical.pyx":1761
16282  * 0.7616{1,2}
16283  * """
16284  * if not (i is None): # <<<<<<<<<<<<<<
16285  * return clifford().wrap( glucat.tan(toClifford(obj), toClifford(i)) )
16286  * else:
16287  */
16288  }
16289 
16290  /* "PyClical.pyx":1764
16291  * return clifford().wrap( glucat.tan(toClifford(obj), toClifford(i)) )
16292  * else:
16293  * try: # <<<<<<<<<<<<<<
16294  * return math.tan(obj)
16295  * except:
16296  */
16297  /*else*/ {
16298  {
16299  __Pyx_ExceptionSave(&__pyx_t_6, &__pyx_t_7, &__pyx_t_8);
16300  __Pyx_XGOTREF(__pyx_t_6);
16301  __Pyx_XGOTREF(__pyx_t_7);
16302  __Pyx_XGOTREF(__pyx_t_8);
16303  /*try:*/ {
16304 
16305  /* "PyClical.pyx":1765
16306  * else:
16307  * try:
16308  * return math.tan(obj) # <<<<<<<<<<<<<<
16309  * except:
16310  * return clifford().wrap( glucat.tan(toClifford(obj)) )
16311  */
16312  __Pyx_XDECREF(__pyx_r);
16313  __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_math); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1765; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
16314  __Pyx_GOTREF(__pyx_t_3);
16315  __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_tan); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1765; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
16316  __Pyx_GOTREF(__pyx_t_9);
16317  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
16318  __pyx_t_3 = NULL;
16319  if (CYTHON_COMPILING_IN_CPYTHON && unlikely(PyMethod_Check(__pyx_t_9))) {
16320  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_9);
16321  if (likely(__pyx_t_3)) {
16322  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_9);
16323  __Pyx_INCREF(__pyx_t_3);
16324  __Pyx_INCREF(function);
16325  __Pyx_DECREF_SET(__pyx_t_9, function);
16326  }
16327  }
16328  if (!__pyx_t_3) {
16329  __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_t_9, __pyx_v_obj); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1765; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
16330  __Pyx_GOTREF(__pyx_t_5);
16331  } else {
16332  __pyx_t_10 = PyTuple_New(1+1); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1765; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
16333  __Pyx_GOTREF(__pyx_t_10);
16334  __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_3); __pyx_t_3 = NULL;
16335  __Pyx_INCREF(__pyx_v_obj);
16336  __Pyx_GIVEREF(__pyx_v_obj);
16337  PyTuple_SET_ITEM(__pyx_t_10, 0+1, __pyx_v_obj);
16338  __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1765; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
16339  __Pyx_GOTREF(__pyx_t_5);
16340  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
16341  }
16342  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
16343  __pyx_r = __pyx_t_5;
16344  __pyx_t_5 = 0;
16345  goto __pyx_L8_try_return;
16346 
16347  /* "PyClical.pyx":1764
16348  * return clifford().wrap( glucat.tan(toClifford(obj), toClifford(i)) )
16349  * else:
16350  * try: # <<<<<<<<<<<<<<
16351  * return math.tan(obj)
16352  * except:
16353  */
16354  }
16355  __pyx_L4_error:;
16356  __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
16357  __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0;
16358  __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
16359  __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
16360 
16361  /* "PyClical.pyx":1766
16362  * try:
16363  * return math.tan(obj)
16364  * except: # <<<<<<<<<<<<<<
16365  * return clifford().wrap( glucat.tan(toClifford(obj)) )
16366  *
16367  */
16368  /*except:*/ {
16369  __Pyx_AddTraceback("PyClical.tan", __pyx_clineno, __pyx_lineno, __pyx_filename);
16370  if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_9, &__pyx_t_10) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1766; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
16371  __Pyx_GOTREF(__pyx_t_5);
16372  __Pyx_GOTREF(__pyx_t_9);
16373  __Pyx_GOTREF(__pyx_t_10);
16374 
16375  /* "PyClical.pyx":1767
16376  * return math.tan(obj)
16377  * except:
16378  * return clifford().wrap( glucat.tan(toClifford(obj)) ) # <<<<<<<<<<<<<<
16379  *
16380  * cpdef inline atan(obj,i = None):
16381  */
16382  __Pyx_XDECREF(__pyx_r);
16383  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1767; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
16384  __Pyx_GOTREF(__pyx_t_3);
16385  __pyx_t_11 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_3), tan(__pyx_f_8PyClical_toClifford(__pyx_v_obj))); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1767; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
16386  __Pyx_GOTREF(__pyx_t_11);
16387  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
16388  __pyx_r = __pyx_t_11;
16389  __pyx_t_11 = 0;
16390  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
16391  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
16392  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
16393  goto __pyx_L7_except_return;
16394  }
16395  __pyx_L6_except_error:;
16396 
16397  /* "PyClical.pyx":1764
16398  * return clifford().wrap( glucat.tan(toClifford(obj), toClifford(i)) )
16399  * else:
16400  * try: # <<<<<<<<<<<<<<
16401  * return math.tan(obj)
16402  * except:
16403  */
16404  __Pyx_XGIVEREF(__pyx_t_6);
16405  __Pyx_XGIVEREF(__pyx_t_7);
16406  __Pyx_XGIVEREF(__pyx_t_8);
16407  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
16408  goto __pyx_L1_error;
16409  __pyx_L8_try_return:;
16410  __Pyx_XGIVEREF(__pyx_t_6);
16411  __Pyx_XGIVEREF(__pyx_t_7);
16412  __Pyx_XGIVEREF(__pyx_t_8);
16413  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
16414  goto __pyx_L0;
16415  __pyx_L7_except_return:;
16416  __Pyx_XGIVEREF(__pyx_t_6);
16417  __Pyx_XGIVEREF(__pyx_t_7);
16418  __Pyx_XGIVEREF(__pyx_t_8);
16419  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
16420  goto __pyx_L0;
16421  }
16422  }
16423 
16424  /* "PyClical.pyx":1752
16425  * return clifford().wrap( glucat.asinh(toClifford(obj)) )
16426  *
16427  * cpdef inline tan(obj,i = None): # <<<<<<<<<<<<<<
16428  * """
16429  * Tangent of multivector with optional complexifier.
16430  */
16431 
16432  /* function exit code */
16433  __pyx_L1_error:;
16434  __Pyx_XDECREF(__pyx_t_3);
16435  __Pyx_XDECREF(__pyx_t_5);
16436  __Pyx_XDECREF(__pyx_t_9);
16437  __Pyx_XDECREF(__pyx_t_10);
16438  __Pyx_XDECREF(__pyx_t_11);
16439  __Pyx_AddTraceback("PyClical.tan", __pyx_clineno, __pyx_lineno, __pyx_filename);
16440  __pyx_r = 0;
16441  __pyx_L0:;
16442  __Pyx_XGIVEREF(__pyx_r);
16443  __Pyx_RefNannyFinishContext();
16444  return __pyx_r;
16445  }
16446 
16447  /* Python wrapper */
16448  static PyObject *__pyx_pw_8PyClical_67tan(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
16449  static char __pyx_doc_8PyClical_66tan[] = "\n Tangent of multivector with optional complexifier.\n\n >>> x=clifford(\"{1,2}\"); print tan(x,\"{1,2,3}\")\n 0.7616{1,2}\n >>> x=clifford(\"{1,2}\"); print tan(x)\n 0.7616{1,2}\n ";
16450  static PyObject *__pyx_pw_8PyClical_67tan(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
16451  PyObject *__pyx_v_obj = 0;
16452  PyObject *__pyx_v_i = 0;
16453  int __pyx_lineno = 0;
16454  const char *__pyx_filename = NULL;
16455  int __pyx_clineno = 0;
16456  PyObject *__pyx_r = 0;
16457  __Pyx_RefNannyDeclarations
16458  __Pyx_RefNannySetupContext("tan (wrapper)", 0);
16459  {
16460  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_obj,&__pyx_n_s_i,0};
16461  PyObject* values[2] = {0,0};
16462  values[1] = ((PyObject *)Py_None);
16463  if (unlikely(__pyx_kwds)) {
16464  Py_ssize_t kw_args;
16465  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
16466  switch (pos_args) {
16467  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
16468  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
16469  case 0: break;
16470  default: goto __pyx_L5_argtuple_error;
16471  }
16472  kw_args = PyDict_Size(__pyx_kwds);
16473  switch (pos_args) {
16474  case 0:
16475  if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_obj)) != 0)) kw_args--;
16476  else goto __pyx_L5_argtuple_error;
16477  case 1:
16478  if (kw_args > 0) {
16479  PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_i);
16480  if (value) { values[1] = value; kw_args--; }
16481  }
16482  }
16483  if (unlikely(kw_args > 0)) {
16484  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "tan") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1752; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
16485  }
16486  } else {
16487  switch (PyTuple_GET_SIZE(__pyx_args)) {
16488  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
16489  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
16490  break;
16491  default: goto __pyx_L5_argtuple_error;
16492  }
16493  }
16494  __pyx_v_obj = values[0];
16495  __pyx_v_i = values[1];
16496  }
16497  goto __pyx_L4_argument_unpacking_done;
16498  __pyx_L5_argtuple_error:;
16499  __Pyx_RaiseArgtupleInvalid("tan", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1752; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
16500  __pyx_L3_error:;
16501  __Pyx_AddTraceback("PyClical.tan", __pyx_clineno, __pyx_lineno, __pyx_filename);
16502  __Pyx_RefNannyFinishContext();
16503  return NULL;
16504  __pyx_L4_argument_unpacking_done:;
16505  __pyx_r = __pyx_pf_8PyClical_66tan(__pyx_self, __pyx_v_obj, __pyx_v_i);
16506 
16507  /* function exit code */
16508  __Pyx_RefNannyFinishContext();
16509  return __pyx_r;
16510  }
16511 
16512  static PyObject *__pyx_pf_8PyClical_66tan(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_i) {
16513  PyObject *__pyx_r = NULL;
16514  __Pyx_RefNannyDeclarations
16515  PyObject *__pyx_t_1 = NULL;
16516  struct __pyx_opt_args_8PyClical_tan __pyx_t_2;
16517  int __pyx_lineno = 0;
16518  const char *__pyx_filename = NULL;
16519  int __pyx_clineno = 0;
16520  __Pyx_RefNannySetupContext("tan", 0);
16521  __Pyx_XDECREF(__pyx_r);
16522  __pyx_t_2.__pyx_n = 1;
16523  __pyx_t_2.i = __pyx_v_i;
16524  __pyx_t_1 = __pyx_f_8PyClical_tan(__pyx_v_obj, 0, &__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1752; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
16525  __Pyx_GOTREF(__pyx_t_1);
16526  __pyx_r = __pyx_t_1;
16527  __pyx_t_1 = 0;
16528  goto __pyx_L0;
16529 
16530  /* function exit code */
16531  __pyx_L1_error:;
16532  __Pyx_XDECREF(__pyx_t_1);
16533  __Pyx_AddTraceback("PyClical.tan", __pyx_clineno, __pyx_lineno, __pyx_filename);
16534  __pyx_r = NULL;
16535  __pyx_L0:;
16536  __Pyx_XGIVEREF(__pyx_r);
16537  __Pyx_RefNannyFinishContext();
16538  return __pyx_r;
16539  }
16540 
16541  /* "PyClical.pyx":1769
16542  * return clifford().wrap( glucat.tan(toClifford(obj)) )
16543  *
16544  * cpdef inline atan(obj,i = None): # <<<<<<<<<<<<<<
16545  * """
16546  * Inverse tangent of multivector with optional complexifier.
16547  */
16548 
16549  static PyObject *__pyx_pw_8PyClical_69atan(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
16550  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_atan(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_atan *__pyx_optional_args) {
16551  PyObject *__pyx_v_i = ((PyObject *)Py_None);
16552  PyObject *__pyx_r = NULL;
16553  __Pyx_RefNannyDeclarations
16554  int __pyx_t_1;
16555  int __pyx_t_2;
16556  PyObject *__pyx_t_3 = NULL;
16557  Clifford __pyx_t_4;
16558  PyObject *__pyx_t_5 = NULL;
16559  PyObject *__pyx_t_6 = NULL;
16560  PyObject *__pyx_t_7 = NULL;
16561  PyObject *__pyx_t_8 = NULL;
16562  PyObject *__pyx_t_9 = NULL;
16563  PyObject *__pyx_t_10 = NULL;
16564  PyObject *__pyx_t_11 = NULL;
16565  int __pyx_lineno = 0;
16566  const char *__pyx_filename = NULL;
16567  int __pyx_clineno = 0;
16568  __Pyx_RefNannySetupContext("atan", 0);
16569  if (__pyx_optional_args) {
16570  if (__pyx_optional_args->__pyx_n > 0) {
16571  __pyx_v_i = __pyx_optional_args->i;
16572  }
16573  }
16574 
16575  /* "PyClical.pyx":1778
16576  * {1}
16577  * """
16578  * if not (i is None): # <<<<<<<<<<<<<<
16579  * return clifford().wrap( glucat.atan(toClifford(obj), toClifford(i)) )
16580  * else:
16581  */
16582  __pyx_t_1 = (__pyx_v_i != Py_None);
16583  __pyx_t_2 = (__pyx_t_1 != 0);
16584  if (__pyx_t_2) {
16585 
16586  /* "PyClical.pyx":1779
16587  * """
16588  * if not (i is None):
16589  * return clifford().wrap( glucat.atan(toClifford(obj), toClifford(i)) ) # <<<<<<<<<<<<<<
16590  * else:
16591  * try:
16592  */
16593  __Pyx_XDECREF(__pyx_r);
16594  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1779; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
16595  __Pyx_GOTREF(__pyx_t_3);
16596  try {
16597  __pyx_t_4 = atan(__pyx_f_8PyClical_toClifford(__pyx_v_obj), __pyx_f_8PyClical_toClifford(__pyx_v_i));
16598  } catch(...) {
16599  __Pyx_CppExn2PyErr();
16600  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1779; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
16601  }
16602  __pyx_t_5 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_3), __pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1779; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
16603  __Pyx_GOTREF(__pyx_t_5);
16604  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
16605  __pyx_r = __pyx_t_5;
16606  __pyx_t_5 = 0;
16607  goto __pyx_L0;
16608 
16609  /* "PyClical.pyx":1778
16610  * {1}
16611  * """
16612  * if not (i is None): # <<<<<<<<<<<<<<
16613  * return clifford().wrap( glucat.atan(toClifford(obj), toClifford(i)) )
16614  * else:
16615  */
16616  }
16617 
16618  /* "PyClical.pyx":1781
16619  * return clifford().wrap( glucat.atan(toClifford(obj), toClifford(i)) )
16620  * else:
16621  * try: # <<<<<<<<<<<<<<
16622  * return math.atan(obj)
16623  * except:
16624  */
16625  /*else*/ {
16626  {
16627  __Pyx_ExceptionSave(&__pyx_t_6, &__pyx_t_7, &__pyx_t_8);
16628  __Pyx_XGOTREF(__pyx_t_6);
16629  __Pyx_XGOTREF(__pyx_t_7);
16630  __Pyx_XGOTREF(__pyx_t_8);
16631  /*try:*/ {
16632 
16633  /* "PyClical.pyx":1782
16634  * else:
16635  * try:
16636  * return math.atan(obj) # <<<<<<<<<<<<<<
16637  * except:
16638  * return clifford().wrap( glucat.atan(toClifford(obj)) )
16639  */
16640  __Pyx_XDECREF(__pyx_r);
16641  __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_math); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1782; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
16642  __Pyx_GOTREF(__pyx_t_3);
16643  __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_atan); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1782; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
16644  __Pyx_GOTREF(__pyx_t_9);
16645  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
16646  __pyx_t_3 = NULL;
16647  if (CYTHON_COMPILING_IN_CPYTHON && unlikely(PyMethod_Check(__pyx_t_9))) {
16648  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_9);
16649  if (likely(__pyx_t_3)) {
16650  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_9);
16651  __Pyx_INCREF(__pyx_t_3);
16652  __Pyx_INCREF(function);
16653  __Pyx_DECREF_SET(__pyx_t_9, function);
16654  }
16655  }
16656  if (!__pyx_t_3) {
16657  __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_t_9, __pyx_v_obj); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1782; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
16658  __Pyx_GOTREF(__pyx_t_5);
16659  } else {
16660  __pyx_t_10 = PyTuple_New(1+1); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1782; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
16661  __Pyx_GOTREF(__pyx_t_10);
16662  __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_3); __pyx_t_3 = NULL;
16663  __Pyx_INCREF(__pyx_v_obj);
16664  __Pyx_GIVEREF(__pyx_v_obj);
16665  PyTuple_SET_ITEM(__pyx_t_10, 0+1, __pyx_v_obj);
16666  __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1782; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
16667  __Pyx_GOTREF(__pyx_t_5);
16668  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
16669  }
16670  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
16671  __pyx_r = __pyx_t_5;
16672  __pyx_t_5 = 0;
16673  goto __pyx_L8_try_return;
16674 
16675  /* "PyClical.pyx":1781
16676  * return clifford().wrap( glucat.atan(toClifford(obj), toClifford(i)) )
16677  * else:
16678  * try: # <<<<<<<<<<<<<<
16679  * return math.atan(obj)
16680  * except:
16681  */
16682  }
16683  __pyx_L4_error:;
16684  __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
16685  __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0;
16686  __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
16687  __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
16688 
16689  /* "PyClical.pyx":1783
16690  * try:
16691  * return math.atan(obj)
16692  * except: # <<<<<<<<<<<<<<
16693  * return clifford().wrap( glucat.atan(toClifford(obj)) )
16694  *
16695  */
16696  /*except:*/ {
16697  __Pyx_AddTraceback("PyClical.atan", __pyx_clineno, __pyx_lineno, __pyx_filename);
16698  if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_9, &__pyx_t_10) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1783; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
16699  __Pyx_GOTREF(__pyx_t_5);
16700  __Pyx_GOTREF(__pyx_t_9);
16701  __Pyx_GOTREF(__pyx_t_10);
16702 
16703  /* "PyClical.pyx":1784
16704  * return math.atan(obj)
16705  * except:
16706  * return clifford().wrap( glucat.atan(toClifford(obj)) ) # <<<<<<<<<<<<<<
16707  *
16708  * cpdef inline tanh(obj):
16709  */
16710  __Pyx_XDECREF(__pyx_r);
16711  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1784; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
16712  __Pyx_GOTREF(__pyx_t_3);
16713  __pyx_t_11 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_3), atan(__pyx_f_8PyClical_toClifford(__pyx_v_obj))); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1784; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
16714  __Pyx_GOTREF(__pyx_t_11);
16715  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
16716  __pyx_r = __pyx_t_11;
16717  __pyx_t_11 = 0;
16718  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
16719  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
16720  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
16721  goto __pyx_L7_except_return;
16722  }
16723  __pyx_L6_except_error:;
16724 
16725  /* "PyClical.pyx":1781
16726  * return clifford().wrap( glucat.atan(toClifford(obj), toClifford(i)) )
16727  * else:
16728  * try: # <<<<<<<<<<<<<<
16729  * return math.atan(obj)
16730  * except:
16731  */
16732  __Pyx_XGIVEREF(__pyx_t_6);
16733  __Pyx_XGIVEREF(__pyx_t_7);
16734  __Pyx_XGIVEREF(__pyx_t_8);
16735  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
16736  goto __pyx_L1_error;
16737  __pyx_L8_try_return:;
16738  __Pyx_XGIVEREF(__pyx_t_6);
16739  __Pyx_XGIVEREF(__pyx_t_7);
16740  __Pyx_XGIVEREF(__pyx_t_8);
16741  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
16742  goto __pyx_L0;
16743  __pyx_L7_except_return:;
16744  __Pyx_XGIVEREF(__pyx_t_6);
16745  __Pyx_XGIVEREF(__pyx_t_7);
16746  __Pyx_XGIVEREF(__pyx_t_8);
16747  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
16748  goto __pyx_L0;
16749  }
16750  }
16751 
16752  /* "PyClical.pyx":1769
16753  * return clifford().wrap( glucat.tan(toClifford(obj)) )
16754  *
16755  * cpdef inline atan(obj,i = None): # <<<<<<<<<<<<<<
16756  * """
16757  * Inverse tangent of multivector with optional complexifier.
16758  */
16759 
16760  /* function exit code */
16761  __pyx_L1_error:;
16762  __Pyx_XDECREF(__pyx_t_3);
16763  __Pyx_XDECREF(__pyx_t_5);
16764  __Pyx_XDECREF(__pyx_t_9);
16765  __Pyx_XDECREF(__pyx_t_10);
16766  __Pyx_XDECREF(__pyx_t_11);
16767  __Pyx_AddTraceback("PyClical.atan", __pyx_clineno, __pyx_lineno, __pyx_filename);
16768  __pyx_r = 0;
16769  __pyx_L0:;
16770  __Pyx_XGIVEREF(__pyx_r);
16771  __Pyx_RefNannyFinishContext();
16772  return __pyx_r;
16773  }
16774 
16775  /* Python wrapper */
16776  static PyObject *__pyx_pw_8PyClical_69atan(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
16777  static char __pyx_doc_8PyClical_68atan[] = "\n Inverse tangent of multivector with optional complexifier.\n\n >>> s=index_set({1,2,3}); x=clifford(\"{1}\"); print tan(atan(x,s),s)\n {1}\n >>> x=clifford(\"{1}\"); print tan(atan(x))\n {1}\n ";
16778  static PyObject *__pyx_pw_8PyClical_69atan(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
16779  PyObject *__pyx_v_obj = 0;
16780  PyObject *__pyx_v_i = 0;
16781  int __pyx_lineno = 0;
16782  const char *__pyx_filename = NULL;
16783  int __pyx_clineno = 0;
16784  PyObject *__pyx_r = 0;
16785  __Pyx_RefNannyDeclarations
16786  __Pyx_RefNannySetupContext("atan (wrapper)", 0);
16787  {
16788  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_obj,&__pyx_n_s_i,0};
16789  PyObject* values[2] = {0,0};
16790  values[1] = ((PyObject *)Py_None);
16791  if (unlikely(__pyx_kwds)) {
16792  Py_ssize_t kw_args;
16793  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
16794  switch (pos_args) {
16795  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
16796  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
16797  case 0: break;
16798  default: goto __pyx_L5_argtuple_error;
16799  }
16800  kw_args = PyDict_Size(__pyx_kwds);
16801  switch (pos_args) {
16802  case 0:
16803  if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_obj)) != 0)) kw_args--;
16804  else goto __pyx_L5_argtuple_error;
16805  case 1:
16806  if (kw_args > 0) {
16807  PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_i);
16808  if (value) { values[1] = value; kw_args--; }
16809  }
16810  }
16811  if (unlikely(kw_args > 0)) {
16812  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "atan") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1769; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
16813  }
16814  } else {
16815  switch (PyTuple_GET_SIZE(__pyx_args)) {
16816  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
16817  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
16818  break;
16819  default: goto __pyx_L5_argtuple_error;
16820  }
16821  }
16822  __pyx_v_obj = values[0];
16823  __pyx_v_i = values[1];
16824  }
16825  goto __pyx_L4_argument_unpacking_done;
16826  __pyx_L5_argtuple_error:;
16827  __Pyx_RaiseArgtupleInvalid("atan", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1769; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
16828  __pyx_L3_error:;
16829  __Pyx_AddTraceback("PyClical.atan", __pyx_clineno, __pyx_lineno, __pyx_filename);
16830  __Pyx_RefNannyFinishContext();
16831  return NULL;
16832  __pyx_L4_argument_unpacking_done:;
16833  __pyx_r = __pyx_pf_8PyClical_68atan(__pyx_self, __pyx_v_obj, __pyx_v_i);
16834 
16835  /* function exit code */
16836  __Pyx_RefNannyFinishContext();
16837  return __pyx_r;
16838  }
16839 
16840  static PyObject *__pyx_pf_8PyClical_68atan(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_i) {
16841  PyObject *__pyx_r = NULL;
16842  __Pyx_RefNannyDeclarations
16843  PyObject *__pyx_t_1 = NULL;
16844  struct __pyx_opt_args_8PyClical_atan __pyx_t_2;
16845  int __pyx_lineno = 0;
16846  const char *__pyx_filename = NULL;
16847  int __pyx_clineno = 0;
16848  __Pyx_RefNannySetupContext("atan", 0);
16849  __Pyx_XDECREF(__pyx_r);
16850  __pyx_t_2.__pyx_n = 1;
16851  __pyx_t_2.i = __pyx_v_i;
16852  __pyx_t_1 = __pyx_f_8PyClical_atan(__pyx_v_obj, 0, &__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1769; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
16853  __Pyx_GOTREF(__pyx_t_1);
16854  __pyx_r = __pyx_t_1;
16855  __pyx_t_1 = 0;
16856  goto __pyx_L0;
16857 
16858  /* function exit code */
16859  __pyx_L1_error:;
16860  __Pyx_XDECREF(__pyx_t_1);
16861  __Pyx_AddTraceback("PyClical.atan", __pyx_clineno, __pyx_lineno, __pyx_filename);
16862  __pyx_r = NULL;
16863  __pyx_L0:;
16864  __Pyx_XGIVEREF(__pyx_r);
16865  __Pyx_RefNannyFinishContext();
16866  return __pyx_r;
16867  }
16868 
16869  /* "PyClical.pyx":1786
16870  * return clifford().wrap( glucat.atan(toClifford(obj)) )
16871  *
16872  * cpdef inline tanh(obj): # <<<<<<<<<<<<<<
16873  * """
16874  * Hyperbolic tangent of multivector.
16875  */
16876 
16877  static PyObject *__pyx_pw_8PyClical_71tanh(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
16878  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_tanh(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
16879  PyObject *__pyx_r = NULL;
16880  __Pyx_RefNannyDeclarations
16881  PyObject *__pyx_t_1 = NULL;
16882  PyObject *__pyx_t_2 = NULL;
16883  PyObject *__pyx_t_3 = NULL;
16884  PyObject *__pyx_t_4 = NULL;
16885  PyObject *__pyx_t_5 = NULL;
16886  PyObject *__pyx_t_6 = NULL;
16887  PyObject *__pyx_t_7 = NULL;
16888  PyObject *__pyx_t_8 = NULL;
16889  int __pyx_lineno = 0;
16890  const char *__pyx_filename = NULL;
16891  int __pyx_clineno = 0;
16892  __Pyx_RefNannySetupContext("tanh", 0);
16893 
16894  /* "PyClical.pyx":1793
16895  * {1,2}
16896  * """
16897  * try: # <<<<<<<<<<<<<<
16898  * return math.tanh(obj)
16899  * except:
16900  */
16901  {
16902  __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3);
16903  __Pyx_XGOTREF(__pyx_t_1);
16904  __Pyx_XGOTREF(__pyx_t_2);
16905  __Pyx_XGOTREF(__pyx_t_3);
16906  /*try:*/ {
16907 
16908  /* "PyClical.pyx":1794
16909  * """
16910  * try:
16911  * return math.tanh(obj) # <<<<<<<<<<<<<<
16912  * except:
16913  * return clifford().wrap( glucat.tanh(toClifford(obj)) )
16914  */
16915  __Pyx_XDECREF(__pyx_r);
16916  __pyx_t_5 = __Pyx_GetModuleGlobalName(__pyx_n_s_math); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1794; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
16917  __Pyx_GOTREF(__pyx_t_5);
16918  __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_tanh); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1794; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
16919  __Pyx_GOTREF(__pyx_t_6);
16920  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
16921  __pyx_t_5 = NULL;
16922  if (CYTHON_COMPILING_IN_CPYTHON && unlikely(PyMethod_Check(__pyx_t_6))) {
16923  __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_6);
16924  if (likely(__pyx_t_5)) {
16925  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6);
16926  __Pyx_INCREF(__pyx_t_5);
16927  __Pyx_INCREF(function);
16928  __Pyx_DECREF_SET(__pyx_t_6, function);
16929  }
16930  }
16931  if (!__pyx_t_5) {
16932  __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_obj); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1794; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
16933  __Pyx_GOTREF(__pyx_t_4);
16934  } else {
16935  __pyx_t_7 = PyTuple_New(1+1); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1794; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
16936  __Pyx_GOTREF(__pyx_t_7);
16937  __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_5); __pyx_t_5 = NULL;
16938  __Pyx_INCREF(__pyx_v_obj);
16939  __Pyx_GIVEREF(__pyx_v_obj);
16940  PyTuple_SET_ITEM(__pyx_t_7, 0+1, __pyx_v_obj);
16941  __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_7, NULL); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1794; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
16942  __Pyx_GOTREF(__pyx_t_4);
16943  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
16944  }
16945  __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
16946  __pyx_r = __pyx_t_4;
16947  __pyx_t_4 = 0;
16948  goto __pyx_L7_try_return;
16949 
16950  /* "PyClical.pyx":1793
16951  * {1,2}
16952  * """
16953  * try: # <<<<<<<<<<<<<<
16954  * return math.tanh(obj)
16955  * except:
16956  */
16957  }
16958  __pyx_L3_error:;
16959  __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
16960  __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
16961  __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
16962  __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
16963 
16964  /* "PyClical.pyx":1795
16965  * try:
16966  * return math.tanh(obj)
16967  * except: # <<<<<<<<<<<<<<
16968  * return clifford().wrap( glucat.tanh(toClifford(obj)) )
16969  *
16970  */
16971  /*except:*/ {
16972  __Pyx_AddTraceback("PyClical.tanh", __pyx_clineno, __pyx_lineno, __pyx_filename);
16973  if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_7) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1795; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
16974  __Pyx_GOTREF(__pyx_t_4);
16975  __Pyx_GOTREF(__pyx_t_6);
16976  __Pyx_GOTREF(__pyx_t_7);
16977 
16978  /* "PyClical.pyx":1796
16979  * return math.tanh(obj)
16980  * except:
16981  * return clifford().wrap( glucat.tanh(toClifford(obj)) ) # <<<<<<<<<<<<<<
16982  *
16983  * cpdef inline atanh(obj,i = None):
16984  */
16985  __Pyx_XDECREF(__pyx_r);
16986  __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1796; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
16987  __Pyx_GOTREF(__pyx_t_5);
16988  __pyx_t_8 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_5), tanh(__pyx_f_8PyClical_toClifford(__pyx_v_obj))); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1796; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
16989  __Pyx_GOTREF(__pyx_t_8);
16990  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
16991  __pyx_r = __pyx_t_8;
16992  __pyx_t_8 = 0;
16993  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
16994  __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
16995  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
16996  goto __pyx_L6_except_return;
16997  }
16998  __pyx_L5_except_error:;
16999 
17000  /* "PyClical.pyx":1793
17001  * {1,2}
17002  * """
17003  * try: # <<<<<<<<<<<<<<
17004  * return math.tanh(obj)
17005  * except:
17006  */
17007  __Pyx_XGIVEREF(__pyx_t_1);
17008  __Pyx_XGIVEREF(__pyx_t_2);
17009  __Pyx_XGIVEREF(__pyx_t_3);
17010  __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
17011  goto __pyx_L1_error;
17012  __pyx_L7_try_return:;
17013  __Pyx_XGIVEREF(__pyx_t_1);
17014  __Pyx_XGIVEREF(__pyx_t_2);
17015  __Pyx_XGIVEREF(__pyx_t_3);
17016  __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
17017  goto __pyx_L0;
17018  __pyx_L6_except_return:;
17019  __Pyx_XGIVEREF(__pyx_t_1);
17020  __Pyx_XGIVEREF(__pyx_t_2);
17021  __Pyx_XGIVEREF(__pyx_t_3);
17022  __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
17023  goto __pyx_L0;
17024  }
17025 
17026  /* "PyClical.pyx":1786
17027  * return clifford().wrap( glucat.atan(toClifford(obj)) )
17028  *
17029  * cpdef inline tanh(obj): # <<<<<<<<<<<<<<
17030  * """
17031  * Hyperbolic tangent of multivector.
17032  */
17033 
17034  /* function exit code */
17035  __pyx_L1_error:;
17036  __Pyx_XDECREF(__pyx_t_4);
17037  __Pyx_XDECREF(__pyx_t_5);
17038  __Pyx_XDECREF(__pyx_t_6);
17039  __Pyx_XDECREF(__pyx_t_7);
17040  __Pyx_XDECREF(__pyx_t_8);
17041  __Pyx_AddTraceback("PyClical.tanh", __pyx_clineno, __pyx_lineno, __pyx_filename);
17042  __pyx_r = 0;
17043  __pyx_L0:;
17044  __Pyx_XGIVEREF(__pyx_r);
17045  __Pyx_RefNannyFinishContext();
17046  return __pyx_r;
17047  }
17048 
17049  /* Python wrapper */
17050  static PyObject *__pyx_pw_8PyClical_71tanh(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
17051  static char __pyx_doc_8PyClical_70tanh[] = "\n Hyperbolic tangent of multivector.\n\n >>> x=clifford(\"{1,2}\") * pi/4; print tanh(x)\n {1,2}\n ";
17052  static PyObject *__pyx_pw_8PyClical_71tanh(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
17053  PyObject *__pyx_r = 0;
17054  __Pyx_RefNannyDeclarations
17055  __Pyx_RefNannySetupContext("tanh (wrapper)", 0);
17056  __pyx_r = __pyx_pf_8PyClical_70tanh(__pyx_self, ((PyObject *)__pyx_v_obj));
17057 
17058  /* function exit code */
17059  __Pyx_RefNannyFinishContext();
17060  return __pyx_r;
17061  }
17062 
17063  static PyObject *__pyx_pf_8PyClical_70tanh(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
17064  PyObject *__pyx_r = NULL;
17065  __Pyx_RefNannyDeclarations
17066  PyObject *__pyx_t_1 = NULL;
17067  int __pyx_lineno = 0;
17068  const char *__pyx_filename = NULL;
17069  int __pyx_clineno = 0;
17070  __Pyx_RefNannySetupContext("tanh", 0);
17071  __Pyx_XDECREF(__pyx_r);
17072  __pyx_t_1 = __pyx_f_8PyClical_tanh(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1786; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17073  __Pyx_GOTREF(__pyx_t_1);
17074  __pyx_r = __pyx_t_1;
17075  __pyx_t_1 = 0;
17076  goto __pyx_L0;
17077 
17078  /* function exit code */
17079  __pyx_L1_error:;
17080  __Pyx_XDECREF(__pyx_t_1);
17081  __Pyx_AddTraceback("PyClical.tanh", __pyx_clineno, __pyx_lineno, __pyx_filename);
17082  __pyx_r = NULL;
17083  __pyx_L0:;
17084  __Pyx_XGIVEREF(__pyx_r);
17085  __Pyx_RefNannyFinishContext();
17086  return __pyx_r;
17087  }
17088 
17089  /* "PyClical.pyx":1798
17090  * return clifford().wrap( glucat.tanh(toClifford(obj)) )
17091  *
17092  * cpdef inline atanh(obj,i = None): # <<<<<<<<<<<<<<
17093  * """
17094  * Inverse hyperbolic tangent of multivector with optional complexifier.
17095  */
17096 
17097  static PyObject *__pyx_pw_8PyClical_73atanh(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
17098  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_atanh(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_atanh *__pyx_optional_args) {
17099  PyObject *__pyx_v_i = ((PyObject *)Py_None);
17100  PyObject *__pyx_r = NULL;
17101  __Pyx_RefNannyDeclarations
17102  int __pyx_t_1;
17103  int __pyx_t_2;
17104  PyObject *__pyx_t_3 = NULL;
17105  Clifford __pyx_t_4;
17106  PyObject *__pyx_t_5 = NULL;
17107  PyObject *__pyx_t_6 = NULL;
17108  PyObject *__pyx_t_7 = NULL;
17109  PyObject *__pyx_t_8 = NULL;
17110  PyObject *__pyx_t_9 = NULL;
17111  PyObject *__pyx_t_10 = NULL;
17112  PyObject *__pyx_t_11 = NULL;
17113  int __pyx_lineno = 0;
17114  const char *__pyx_filename = NULL;
17115  int __pyx_clineno = 0;
17116  __Pyx_RefNannySetupContext("atanh", 0);
17117  if (__pyx_optional_args) {
17118  if (__pyx_optional_args->__pyx_n > 0) {
17119  __pyx_v_i = __pyx_optional_args->i;
17120  }
17121  }
17122 
17123  /* "PyClical.pyx":1807
17124  * {1,2}
17125  * """
17126  * if not (i is None): # <<<<<<<<<<<<<<
17127  * return clifford().wrap( glucat.atanh(toClifford(obj), toClifford(i)) )
17128  * else:
17129  */
17130  __pyx_t_1 = (__pyx_v_i != Py_None);
17131  __pyx_t_2 = (__pyx_t_1 != 0);
17132  if (__pyx_t_2) {
17133 
17134  /* "PyClical.pyx":1808
17135  * """
17136  * if not (i is None):
17137  * return clifford().wrap( glucat.atanh(toClifford(obj), toClifford(i)) ) # <<<<<<<<<<<<<<
17138  * else:
17139  * try:
17140  */
17141  __Pyx_XDECREF(__pyx_r);
17142  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1808; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17143  __Pyx_GOTREF(__pyx_t_3);
17144  try {
17145  __pyx_t_4 = atanh(__pyx_f_8PyClical_toClifford(__pyx_v_obj), __pyx_f_8PyClical_toClifford(__pyx_v_i));
17146  } catch(...) {
17147  __Pyx_CppExn2PyErr();
17148  {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1808; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17149  }
17150  __pyx_t_5 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_3), __pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1808; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17151  __Pyx_GOTREF(__pyx_t_5);
17152  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
17153  __pyx_r = __pyx_t_5;
17154  __pyx_t_5 = 0;
17155  goto __pyx_L0;
17156 
17157  /* "PyClical.pyx":1807
17158  * {1,2}
17159  * """
17160  * if not (i is None): # <<<<<<<<<<<<<<
17161  * return clifford().wrap( glucat.atanh(toClifford(obj), toClifford(i)) )
17162  * else:
17163  */
17164  }
17165 
17166  /* "PyClical.pyx":1810
17167  * return clifford().wrap( glucat.atanh(toClifford(obj), toClifford(i)) )
17168  * else:
17169  * try: # <<<<<<<<<<<<<<
17170  * return math.atanh(obj)
17171  * except:
17172  */
17173  /*else*/ {
17174  {
17175  __Pyx_ExceptionSave(&__pyx_t_6, &__pyx_t_7, &__pyx_t_8);
17176  __Pyx_XGOTREF(__pyx_t_6);
17177  __Pyx_XGOTREF(__pyx_t_7);
17178  __Pyx_XGOTREF(__pyx_t_8);
17179  /*try:*/ {
17180 
17181  /* "PyClical.pyx":1811
17182  * else:
17183  * try:
17184  * return math.atanh(obj) # <<<<<<<<<<<<<<
17185  * except:
17186  * return clifford().wrap( glucat.atanh(toClifford(obj)) )
17187  */
17188  __Pyx_XDECREF(__pyx_r);
17189  __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_math); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1811; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
17190  __Pyx_GOTREF(__pyx_t_3);
17191  __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_atanh); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1811; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
17192  __Pyx_GOTREF(__pyx_t_9);
17193  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
17194  __pyx_t_3 = NULL;
17195  if (CYTHON_COMPILING_IN_CPYTHON && unlikely(PyMethod_Check(__pyx_t_9))) {
17196  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_9);
17197  if (likely(__pyx_t_3)) {
17198  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_9);
17199  __Pyx_INCREF(__pyx_t_3);
17200  __Pyx_INCREF(function);
17201  __Pyx_DECREF_SET(__pyx_t_9, function);
17202  }
17203  }
17204  if (!__pyx_t_3) {
17205  __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_t_9, __pyx_v_obj); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1811; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
17206  __Pyx_GOTREF(__pyx_t_5);
17207  } else {
17208  __pyx_t_10 = PyTuple_New(1+1); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1811; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
17209  __Pyx_GOTREF(__pyx_t_10);
17210  __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_3); __pyx_t_3 = NULL;
17211  __Pyx_INCREF(__pyx_v_obj);
17212  __Pyx_GIVEREF(__pyx_v_obj);
17213  PyTuple_SET_ITEM(__pyx_t_10, 0+1, __pyx_v_obj);
17214  __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1811; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
17215  __Pyx_GOTREF(__pyx_t_5);
17216  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
17217  }
17218  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
17219  __pyx_r = __pyx_t_5;
17220  __pyx_t_5 = 0;
17221  goto __pyx_L8_try_return;
17222 
17223  /* "PyClical.pyx":1810
17224  * return clifford().wrap( glucat.atanh(toClifford(obj), toClifford(i)) )
17225  * else:
17226  * try: # <<<<<<<<<<<<<<
17227  * return math.atanh(obj)
17228  * except:
17229  */
17230  }
17231  __pyx_L4_error:;
17232  __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
17233  __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0;
17234  __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
17235  __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
17236 
17237  /* "PyClical.pyx":1812
17238  * try:
17239  * return math.atanh(obj)
17240  * except: # <<<<<<<<<<<<<<
17241  * return clifford().wrap( glucat.atanh(toClifford(obj)) )
17242  *
17243  */
17244  /*except:*/ {
17245  __Pyx_AddTraceback("PyClical.atanh", __pyx_clineno, __pyx_lineno, __pyx_filename);
17246  if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_9, &__pyx_t_10) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1812; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
17247  __Pyx_GOTREF(__pyx_t_5);
17248  __Pyx_GOTREF(__pyx_t_9);
17249  __Pyx_GOTREF(__pyx_t_10);
17250 
17251  /* "PyClical.pyx":1813
17252  * return math.atanh(obj)
17253  * except:
17254  * return clifford().wrap( glucat.atanh(toClifford(obj)) ) # <<<<<<<<<<<<<<
17255  *
17256  * cpdef inline random_clifford(index_set ixt, fill = 1.0):
17257  */
17258  __Pyx_XDECREF(__pyx_r);
17259  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1813; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
17260  __Pyx_GOTREF(__pyx_t_3);
17261  __pyx_t_11 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_3), atanh(__pyx_f_8PyClical_toClifford(__pyx_v_obj))); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1813; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
17262  __Pyx_GOTREF(__pyx_t_11);
17263  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
17264  __pyx_r = __pyx_t_11;
17265  __pyx_t_11 = 0;
17266  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
17267  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
17268  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
17269  goto __pyx_L7_except_return;
17270  }
17271  __pyx_L6_except_error:;
17272 
17273  /* "PyClical.pyx":1810
17274  * return clifford().wrap( glucat.atanh(toClifford(obj), toClifford(i)) )
17275  * else:
17276  * try: # <<<<<<<<<<<<<<
17277  * return math.atanh(obj)
17278  * except:
17279  */
17280  __Pyx_XGIVEREF(__pyx_t_6);
17281  __Pyx_XGIVEREF(__pyx_t_7);
17282  __Pyx_XGIVEREF(__pyx_t_8);
17283  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
17284  goto __pyx_L1_error;
17285  __pyx_L8_try_return:;
17286  __Pyx_XGIVEREF(__pyx_t_6);
17287  __Pyx_XGIVEREF(__pyx_t_7);
17288  __Pyx_XGIVEREF(__pyx_t_8);
17289  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
17290  goto __pyx_L0;
17291  __pyx_L7_except_return:;
17292  __Pyx_XGIVEREF(__pyx_t_6);
17293  __Pyx_XGIVEREF(__pyx_t_7);
17294  __Pyx_XGIVEREF(__pyx_t_8);
17295  __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8);
17296  goto __pyx_L0;
17297  }
17298  }
17299 
17300  /* "PyClical.pyx":1798
17301  * return clifford().wrap( glucat.tanh(toClifford(obj)) )
17302  *
17303  * cpdef inline atanh(obj,i = None): # <<<<<<<<<<<<<<
17304  * """
17305  * Inverse hyperbolic tangent of multivector with optional complexifier.
17306  */
17307 
17308  /* function exit code */
17309  __pyx_L1_error:;
17310  __Pyx_XDECREF(__pyx_t_3);
17311  __Pyx_XDECREF(__pyx_t_5);
17312  __Pyx_XDECREF(__pyx_t_9);
17313  __Pyx_XDECREF(__pyx_t_10);
17314  __Pyx_XDECREF(__pyx_t_11);
17315  __Pyx_AddTraceback("PyClical.atanh", __pyx_clineno, __pyx_lineno, __pyx_filename);
17316  __pyx_r = 0;
17317  __pyx_L0:;
17318  __Pyx_XGIVEREF(__pyx_r);
17319  __Pyx_RefNannyFinishContext();
17320  return __pyx_r;
17321  }
17322 
17323  /* Python wrapper */
17324  static PyObject *__pyx_pw_8PyClical_73atanh(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
17325  static char __pyx_doc_8PyClical_72atanh[] = "\n Inverse hyperbolic tangent of multivector with optional complexifier.\n\n >>> s=index_set({1,2,3}); x=clifford(\"{1,2}\"); print tanh(atanh(x,s))\n {1,2}\n >>> x=clifford(\"{1,2}\"); print tanh(atanh(x))\n {1,2}\n ";
17326  static PyObject *__pyx_pw_8PyClical_73atanh(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
17327  PyObject *__pyx_v_obj = 0;
17328  PyObject *__pyx_v_i = 0;
17329  int __pyx_lineno = 0;
17330  const char *__pyx_filename = NULL;
17331  int __pyx_clineno = 0;
17332  PyObject *__pyx_r = 0;
17333  __Pyx_RefNannyDeclarations
17334  __Pyx_RefNannySetupContext("atanh (wrapper)", 0);
17335  {
17336  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_obj,&__pyx_n_s_i,0};
17337  PyObject* values[2] = {0,0};
17338  values[1] = ((PyObject *)Py_None);
17339  if (unlikely(__pyx_kwds)) {
17340  Py_ssize_t kw_args;
17341  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
17342  switch (pos_args) {
17343  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
17344  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
17345  case 0: break;
17346  default: goto __pyx_L5_argtuple_error;
17347  }
17348  kw_args = PyDict_Size(__pyx_kwds);
17349  switch (pos_args) {
17350  case 0:
17351  if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_obj)) != 0)) kw_args--;
17352  else goto __pyx_L5_argtuple_error;
17353  case 1:
17354  if (kw_args > 0) {
17355  PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_i);
17356  if (value) { values[1] = value; kw_args--; }
17357  }
17358  }
17359  if (unlikely(kw_args > 0)) {
17360  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "atanh") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1798; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
17361  }
17362  } else {
17363  switch (PyTuple_GET_SIZE(__pyx_args)) {
17364  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
17365  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
17366  break;
17367  default: goto __pyx_L5_argtuple_error;
17368  }
17369  }
17370  __pyx_v_obj = values[0];
17371  __pyx_v_i = values[1];
17372  }
17373  goto __pyx_L4_argument_unpacking_done;
17374  __pyx_L5_argtuple_error:;
17375  __Pyx_RaiseArgtupleInvalid("atanh", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1798; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
17376  __pyx_L3_error:;
17377  __Pyx_AddTraceback("PyClical.atanh", __pyx_clineno, __pyx_lineno, __pyx_filename);
17378  __Pyx_RefNannyFinishContext();
17379  return NULL;
17380  __pyx_L4_argument_unpacking_done:;
17381  __pyx_r = __pyx_pf_8PyClical_72atanh(__pyx_self, __pyx_v_obj, __pyx_v_i);
17382 
17383  /* function exit code */
17384  __Pyx_RefNannyFinishContext();
17385  return __pyx_r;
17386  }
17387 
17388  static PyObject *__pyx_pf_8PyClical_72atanh(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj, PyObject *__pyx_v_i) {
17389  PyObject *__pyx_r = NULL;
17390  __Pyx_RefNannyDeclarations
17391  PyObject *__pyx_t_1 = NULL;
17392  struct __pyx_opt_args_8PyClical_atanh __pyx_t_2;
17393  int __pyx_lineno = 0;
17394  const char *__pyx_filename = NULL;
17395  int __pyx_clineno = 0;
17396  __Pyx_RefNannySetupContext("atanh", 0);
17397  __Pyx_XDECREF(__pyx_r);
17398  __pyx_t_2.__pyx_n = 1;
17399  __pyx_t_2.i = __pyx_v_i;
17400  __pyx_t_1 = __pyx_f_8PyClical_atanh(__pyx_v_obj, 0, &__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1798; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17401  __Pyx_GOTREF(__pyx_t_1);
17402  __pyx_r = __pyx_t_1;
17403  __pyx_t_1 = 0;
17404  goto __pyx_L0;
17405 
17406  /* function exit code */
17407  __pyx_L1_error:;
17408  __Pyx_XDECREF(__pyx_t_1);
17409  __Pyx_AddTraceback("PyClical.atanh", __pyx_clineno, __pyx_lineno, __pyx_filename);
17410  __pyx_r = NULL;
17411  __pyx_L0:;
17412  __Pyx_XGIVEREF(__pyx_r);
17413  __Pyx_RefNannyFinishContext();
17414  return __pyx_r;
17415  }
17416 
17417  /* "PyClical.pyx":1815
17418  * return clifford().wrap( glucat.atanh(toClifford(obj)) )
17419  *
17420  * cpdef inline random_clifford(index_set ixt, fill = 1.0): # <<<<<<<<<<<<<<
17421  * """
17422  * Random multivector within a frame.
17423  */
17424 
17425  static PyObject *__pyx_pw_8PyClical_75random_clifford(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
17426  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_random_clifford(struct __pyx_obj_8PyClical_index_set *__pyx_v_ixt, CYTHON_UNUSED int __pyx_skip_dispatch, struct __pyx_opt_args_8PyClical_random_clifford *__pyx_optional_args) {
17427  PyObject *__pyx_v_fill = ((PyObject *)__pyx_float_1_0);
17428  PyObject *__pyx_r = NULL;
17429  __Pyx_RefNannyDeclarations
17430  PyObject *__pyx_t_1 = NULL;
17431  PyObject *__pyx_t_2 = NULL;
17432  scalar_t __pyx_t_3;
17433  PyObject *__pyx_t_4 = NULL;
17434  int __pyx_lineno = 0;
17435  const char *__pyx_filename = NULL;
17436  int __pyx_clineno = 0;
17437  __Pyx_RefNannySetupContext("random_clifford", 0);
17438  if (__pyx_optional_args) {
17439  if (__pyx_optional_args->__pyx_n > 0) {
17440  __pyx_v_fill = __pyx_optional_args->fill;
17441  }
17442  }
17443 
17444  /* "PyClical.pyx":1822
17445  * {-3,-1,2}
17446  * """
17447  * return clifford().wrap( clifford().instance.random(ixt.unwrap(), <scalar_t>fill) ) # <<<<<<<<<<<<<<
17448  *
17449  * cpdef inline cga3(obj):
17450  */
17451  __Pyx_XDECREF(__pyx_r);
17452  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1822; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17453  __Pyx_GOTREF(__pyx_t_1);
17454  __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1822; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17455  __Pyx_GOTREF(__pyx_t_2);
17456  __pyx_t_3 = __pyx_PyFloat_AsDouble(__pyx_v_fill); if (unlikely((__pyx_t_3 == (scalar_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1822; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17457  __pyx_t_4 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), ((struct __pyx_obj_8PyClical_clifford *)__pyx_t_2)->instance->random(__pyx_f_8PyClical_9index_set_unwrap(__pyx_v_ixt), ((scalar_t)__pyx_t_3))); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1822; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17458  __Pyx_GOTREF(__pyx_t_4);
17459  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
17460  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
17461  __pyx_r = __pyx_t_4;
17462  __pyx_t_4 = 0;
17463  goto __pyx_L0;
17464 
17465  /* "PyClical.pyx":1815
17466  * return clifford().wrap( glucat.atanh(toClifford(obj)) )
17467  *
17468  * cpdef inline random_clifford(index_set ixt, fill = 1.0): # <<<<<<<<<<<<<<
17469  * """
17470  * Random multivector within a frame.
17471  */
17472 
17473  /* function exit code */
17474  __pyx_L1_error:;
17475  __Pyx_XDECREF(__pyx_t_1);
17476  __Pyx_XDECREF(__pyx_t_2);
17477  __Pyx_XDECREF(__pyx_t_4);
17478  __Pyx_AddTraceback("PyClical.random_clifford", __pyx_clineno, __pyx_lineno, __pyx_filename);
17479  __pyx_r = 0;
17480  __pyx_L0:;
17481  __Pyx_XGIVEREF(__pyx_r);
17482  __Pyx_RefNannyFinishContext();
17483  return __pyx_r;
17484  }
17485 
17486  /* Python wrapper */
17487  static PyObject *__pyx_pw_8PyClical_75random_clifford(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
17488  static char __pyx_doc_8PyClical_74random_clifford[] = "\n Random multivector within a frame.\n\n >>> print random_clifford(index_set({-3,-1,2})).frame()\n {-3,-1,2}\n ";
17489  static PyObject *__pyx_pw_8PyClical_75random_clifford(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
17490  struct __pyx_obj_8PyClical_index_set *__pyx_v_ixt = 0;
17491  PyObject *__pyx_v_fill = 0;
17492  int __pyx_lineno = 0;
17493  const char *__pyx_filename = NULL;
17494  int __pyx_clineno = 0;
17495  PyObject *__pyx_r = 0;
17496  __Pyx_RefNannyDeclarations
17497  __Pyx_RefNannySetupContext("random_clifford (wrapper)", 0);
17498  {
17499  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_ixt,&__pyx_n_s_fill,0};
17500  PyObject* values[2] = {0,0};
17501  values[1] = ((PyObject *)__pyx_float_1_0);
17502  if (unlikely(__pyx_kwds)) {
17503  Py_ssize_t kw_args;
17504  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
17505  switch (pos_args) {
17506  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
17507  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
17508  case 0: break;
17509  default: goto __pyx_L5_argtuple_error;
17510  }
17511  kw_args = PyDict_Size(__pyx_kwds);
17512  switch (pos_args) {
17513  case 0:
17514  if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ixt)) != 0)) kw_args--;
17515  else goto __pyx_L5_argtuple_error;
17516  case 1:
17517  if (kw_args > 0) {
17518  PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_fill);
17519  if (value) { values[1] = value; kw_args--; }
17520  }
17521  }
17522  if (unlikely(kw_args > 0)) {
17523  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "random_clifford") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1815; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
17524  }
17525  } else {
17526  switch (PyTuple_GET_SIZE(__pyx_args)) {
17527  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
17528  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
17529  break;
17530  default: goto __pyx_L5_argtuple_error;
17531  }
17532  }
17533  __pyx_v_ixt = ((struct __pyx_obj_8PyClical_index_set *)values[0]);
17534  __pyx_v_fill = values[1];
17535  }
17536  goto __pyx_L4_argument_unpacking_done;
17537  __pyx_L5_argtuple_error:;
17538  __Pyx_RaiseArgtupleInvalid("random_clifford", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1815; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
17539  __pyx_L3_error:;
17540  __Pyx_AddTraceback("PyClical.random_clifford", __pyx_clineno, __pyx_lineno, __pyx_filename);
17541  __Pyx_RefNannyFinishContext();
17542  return NULL;
17543  __pyx_L4_argument_unpacking_done:;
17544  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ixt), __pyx_ptype_8PyClical_index_set, 1, "ixt", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1815; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17545  __pyx_r = __pyx_pf_8PyClical_74random_clifford(__pyx_self, __pyx_v_ixt, __pyx_v_fill);
17546 
17547  /* function exit code */
17548  goto __pyx_L0;
17549  __pyx_L1_error:;
17550  __pyx_r = NULL;
17551  __pyx_L0:;
17552  __Pyx_RefNannyFinishContext();
17553  return __pyx_r;
17554  }
17555 
17556  static PyObject *__pyx_pf_8PyClical_74random_clifford(CYTHON_UNUSED PyObject *__pyx_self, struct __pyx_obj_8PyClical_index_set *__pyx_v_ixt, PyObject *__pyx_v_fill) {
17557  PyObject *__pyx_r = NULL;
17558  __Pyx_RefNannyDeclarations
17559  PyObject *__pyx_t_1 = NULL;
17560  struct __pyx_opt_args_8PyClical_random_clifford __pyx_t_2;
17561  int __pyx_lineno = 0;
17562  const char *__pyx_filename = NULL;
17563  int __pyx_clineno = 0;
17564  __Pyx_RefNannySetupContext("random_clifford", 0);
17565  __Pyx_XDECREF(__pyx_r);
17566  __pyx_t_2.__pyx_n = 1;
17567  __pyx_t_2.fill = __pyx_v_fill;
17568  __pyx_t_1 = __pyx_f_8PyClical_random_clifford(__pyx_v_ixt, 0, &__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1815; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17569  __Pyx_GOTREF(__pyx_t_1);
17570  __pyx_r = __pyx_t_1;
17571  __pyx_t_1 = 0;
17572  goto __pyx_L0;
17573 
17574  /* function exit code */
17575  __pyx_L1_error:;
17576  __Pyx_XDECREF(__pyx_t_1);
17577  __Pyx_AddTraceback("PyClical.random_clifford", __pyx_clineno, __pyx_lineno, __pyx_filename);
17578  __pyx_r = NULL;
17579  __pyx_L0:;
17580  __Pyx_XGIVEREF(__pyx_r);
17581  __Pyx_RefNannyFinishContext();
17582  return __pyx_r;
17583  }
17584 
17585  /* "PyClical.pyx":1824
17586  * return clifford().wrap( clifford().instance.random(ixt.unwrap(), <scalar_t>fill) )
17587  *
17588  * cpdef inline cga3(obj): # <<<<<<<<<<<<<<
17589  * """
17590  * Convert Euclidean 3D multivector to Conformal Geometric Algebra using Doran and Lasenby definition.
17591  */
17592 
17593  static PyObject *__pyx_pw_8PyClical_77cga3(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
17594  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_cga3(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
17595  PyObject *__pyx_r = NULL;
17596  __Pyx_RefNannyDeclarations
17597  PyObject *__pyx_t_1 = NULL;
17598  PyObject *__pyx_t_2 = NULL;
17599  int __pyx_lineno = 0;
17600  const char *__pyx_filename = NULL;
17601  int __pyx_clineno = 0;
17602  __Pyx_RefNannySetupContext("cga3", 0);
17603 
17604  /* "PyClical.pyx":1831
17605  * 87{-1}+4{1}+18{2}+2{3}+85{4}
17606  * """
17607  * return clifford().wrap( glucat.cga3(toClifford(obj)) ) # <<<<<<<<<<<<<<
17608  *
17609  * cpdef inline cga3std(obj):
17610  */
17611  __Pyx_XDECREF(__pyx_r);
17612  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1831; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17613  __Pyx_GOTREF(__pyx_t_1);
17614  __pyx_t_2 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), cga3::cga3(__pyx_f_8PyClical_toClifford(__pyx_v_obj))); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1831; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17615  __Pyx_GOTREF(__pyx_t_2);
17616  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
17617  __pyx_r = __pyx_t_2;
17618  __pyx_t_2 = 0;
17619  goto __pyx_L0;
17620 
17621  /* "PyClical.pyx":1824
17622  * return clifford().wrap( clifford().instance.random(ixt.unwrap(), <scalar_t>fill) )
17623  *
17624  * cpdef inline cga3(obj): # <<<<<<<<<<<<<<
17625  * """
17626  * Convert Euclidean 3D multivector to Conformal Geometric Algebra using Doran and Lasenby definition.
17627  */
17628 
17629  /* function exit code */
17630  __pyx_L1_error:;
17631  __Pyx_XDECREF(__pyx_t_1);
17632  __Pyx_XDECREF(__pyx_t_2);
17633  __Pyx_AddTraceback("PyClical.cga3", __pyx_clineno, __pyx_lineno, __pyx_filename);
17634  __pyx_r = 0;
17635  __pyx_L0:;
17636  __Pyx_XGIVEREF(__pyx_r);
17637  __Pyx_RefNannyFinishContext();
17638  return __pyx_r;
17639  }
17640 
17641  /* Python wrapper */
17642  static PyObject *__pyx_pw_8PyClical_77cga3(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
17643  static char __pyx_doc_8PyClical_76cga3[] = "\n Convert Euclidean 3D multivector to Conformal Geometric Algebra using Doran and Lasenby definition.\n\n >>> x=clifford(\"2{1}+9{2}+{3}\"); print cga3(x)\n 87{-1}+4{1}+18{2}+2{3}+85{4}\n ";
17644  static PyObject *__pyx_pw_8PyClical_77cga3(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
17645  PyObject *__pyx_r = 0;
17646  __Pyx_RefNannyDeclarations
17647  __Pyx_RefNannySetupContext("cga3 (wrapper)", 0);
17648  __pyx_r = __pyx_pf_8PyClical_76cga3(__pyx_self, ((PyObject *)__pyx_v_obj));
17649 
17650  /* function exit code */
17651  __Pyx_RefNannyFinishContext();
17652  return __pyx_r;
17653  }
17654 
17655  static PyObject *__pyx_pf_8PyClical_76cga3(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
17656  PyObject *__pyx_r = NULL;
17657  __Pyx_RefNannyDeclarations
17658  PyObject *__pyx_t_1 = NULL;
17659  int __pyx_lineno = 0;
17660  const char *__pyx_filename = NULL;
17661  int __pyx_clineno = 0;
17662  __Pyx_RefNannySetupContext("cga3", 0);
17663  __Pyx_XDECREF(__pyx_r);
17664  __pyx_t_1 = __pyx_f_8PyClical_cga3(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1824; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17665  __Pyx_GOTREF(__pyx_t_1);
17666  __pyx_r = __pyx_t_1;
17667  __pyx_t_1 = 0;
17668  goto __pyx_L0;
17669 
17670  /* function exit code */
17671  __pyx_L1_error:;
17672  __Pyx_XDECREF(__pyx_t_1);
17673  __Pyx_AddTraceback("PyClical.cga3", __pyx_clineno, __pyx_lineno, __pyx_filename);
17674  __pyx_r = NULL;
17675  __pyx_L0:;
17676  __Pyx_XGIVEREF(__pyx_r);
17677  __Pyx_RefNannyFinishContext();
17678  return __pyx_r;
17679  }
17680 
17681  /* "PyClical.pyx":1833
17682  * return clifford().wrap( glucat.cga3(toClifford(obj)) )
17683  *
17684  * cpdef inline cga3std(obj): # <<<<<<<<<<<<<<
17685  * """
17686  * Convert CGA3 null vector to standard conformal null vector using Doran and Lasenby definition.
17687  */
17688 
17689  static PyObject *__pyx_pw_8PyClical_79cga3std(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
17690  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_cga3std(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
17691  PyObject *__pyx_r = NULL;
17692  __Pyx_RefNannyDeclarations
17693  PyObject *__pyx_t_1 = NULL;
17694  PyObject *__pyx_t_2 = NULL;
17695  int __pyx_lineno = 0;
17696  const char *__pyx_filename = NULL;
17697  int __pyx_clineno = 0;
17698  __Pyx_RefNannySetupContext("cga3std", 0);
17699 
17700  /* "PyClical.pyx":1842
17701  * 0
17702  * """
17703  * return clifford().wrap( glucat.cga3std(toClifford(obj)) ) # <<<<<<<<<<<<<<
17704  *
17705  * cpdef inline agc3(obj):
17706  */
17707  __Pyx_XDECREF(__pyx_r);
17708  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1842; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17709  __Pyx_GOTREF(__pyx_t_1);
17710  __pyx_t_2 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), cga3::cga3std(__pyx_f_8PyClical_toClifford(__pyx_v_obj))); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1842; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17711  __Pyx_GOTREF(__pyx_t_2);
17712  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
17713  __pyx_r = __pyx_t_2;
17714  __pyx_t_2 = 0;
17715  goto __pyx_L0;
17716 
17717  /* "PyClical.pyx":1833
17718  * return clifford().wrap( glucat.cga3(toClifford(obj)) )
17719  *
17720  * cpdef inline cga3std(obj): # <<<<<<<<<<<<<<
17721  * """
17722  * Convert CGA3 null vector to standard conformal null vector using Doran and Lasenby definition.
17723  */
17724 
17725  /* function exit code */
17726  __pyx_L1_error:;
17727  __Pyx_XDECREF(__pyx_t_1);
17728  __Pyx_XDECREF(__pyx_t_2);
17729  __Pyx_AddTraceback("PyClical.cga3std", __pyx_clineno, __pyx_lineno, __pyx_filename);
17730  __pyx_r = 0;
17731  __pyx_L0:;
17732  __Pyx_XGIVEREF(__pyx_r);
17733  __Pyx_RefNannyFinishContext();
17734  return __pyx_r;
17735  }
17736 
17737  /* Python wrapper */
17738  static PyObject *__pyx_pw_8PyClical_79cga3std(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
17739  static char __pyx_doc_8PyClical_78cga3std[] = "\n Convert CGA3 null vector to standard conformal null vector using Doran and Lasenby definition.\n\n >>> x=clifford(\"2{1}+9{2}+{3}\"); print cga3std(cga3(x))\n 87{-1}+4{1}+18{2}+2{3}+85{4}\n >>> x=clifford(\"2{1}+9{2}+{3}\"); print cga3std(cga3(x))-cga3(x)\n 0\n ";
17740  static PyObject *__pyx_pw_8PyClical_79cga3std(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
17741  PyObject *__pyx_r = 0;
17742  __Pyx_RefNannyDeclarations
17743  __Pyx_RefNannySetupContext("cga3std (wrapper)", 0);
17744  __pyx_r = __pyx_pf_8PyClical_78cga3std(__pyx_self, ((PyObject *)__pyx_v_obj));
17745 
17746  /* function exit code */
17747  __Pyx_RefNannyFinishContext();
17748  return __pyx_r;
17749  }
17750 
17751  static PyObject *__pyx_pf_8PyClical_78cga3std(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
17752  PyObject *__pyx_r = NULL;
17753  __Pyx_RefNannyDeclarations
17754  PyObject *__pyx_t_1 = NULL;
17755  int __pyx_lineno = 0;
17756  const char *__pyx_filename = NULL;
17757  int __pyx_clineno = 0;
17758  __Pyx_RefNannySetupContext("cga3std", 0);
17759  __Pyx_XDECREF(__pyx_r);
17760  __pyx_t_1 = __pyx_f_8PyClical_cga3std(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1833; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17761  __Pyx_GOTREF(__pyx_t_1);
17762  __pyx_r = __pyx_t_1;
17763  __pyx_t_1 = 0;
17764  goto __pyx_L0;
17765 
17766  /* function exit code */
17767  __pyx_L1_error:;
17768  __Pyx_XDECREF(__pyx_t_1);
17769  __Pyx_AddTraceback("PyClical.cga3std", __pyx_clineno, __pyx_lineno, __pyx_filename);
17770  __pyx_r = NULL;
17771  __pyx_L0:;
17772  __Pyx_XGIVEREF(__pyx_r);
17773  __Pyx_RefNannyFinishContext();
17774  return __pyx_r;
17775  }
17776 
17777  /* "PyClical.pyx":1844
17778  * return clifford().wrap( glucat.cga3std(toClifford(obj)) )
17779  *
17780  * cpdef inline agc3(obj): # <<<<<<<<<<<<<<
17781  * """
17782  * Convert CGA3 null vector to Euclidean 3D vector using Doran and Lasenby definition.
17783  */
17784 
17785  static PyObject *__pyx_pw_8PyClical_81agc3(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
17786  static CYTHON_INLINE PyObject *__pyx_f_8PyClical_agc3(PyObject *__pyx_v_obj, CYTHON_UNUSED int __pyx_skip_dispatch) {
17787  PyObject *__pyx_r = NULL;
17788  __Pyx_RefNannyDeclarations
17789  PyObject *__pyx_t_1 = NULL;
17790  PyObject *__pyx_t_2 = NULL;
17791  int __pyx_lineno = 0;
17792  const char *__pyx_filename = NULL;
17793  int __pyx_clineno = 0;
17794  __Pyx_RefNannySetupContext("agc3", 0);
17795 
17796  /* "PyClical.pyx":1853
17797  * 0
17798  * """
17799  * return clifford().wrap( glucat.agc3(toClifford(obj)) ) # <<<<<<<<<<<<<<
17800  *
17801  * # Some abbreviations.
17802  */
17803  __Pyx_XDECREF(__pyx_r);
17804  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1853; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17805  __Pyx_GOTREF(__pyx_t_1);
17806  __pyx_t_2 = __pyx_f_8PyClical_8clifford_wrap(((struct __pyx_obj_8PyClical_clifford *)__pyx_t_1), cga3::agc3(__pyx_f_8PyClical_toClifford(__pyx_v_obj))); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1853; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17807  __Pyx_GOTREF(__pyx_t_2);
17808  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
17809  __pyx_r = __pyx_t_2;
17810  __pyx_t_2 = 0;
17811  goto __pyx_L0;
17812 
17813  /* "PyClical.pyx":1844
17814  * return clifford().wrap( glucat.cga3std(toClifford(obj)) )
17815  *
17816  * cpdef inline agc3(obj): # <<<<<<<<<<<<<<
17817  * """
17818  * Convert CGA3 null vector to Euclidean 3D vector using Doran and Lasenby definition.
17819  */
17820 
17821  /* function exit code */
17822  __pyx_L1_error:;
17823  __Pyx_XDECREF(__pyx_t_1);
17824  __Pyx_XDECREF(__pyx_t_2);
17825  __Pyx_AddTraceback("PyClical.agc3", __pyx_clineno, __pyx_lineno, __pyx_filename);
17826  __pyx_r = 0;
17827  __pyx_L0:;
17828  __Pyx_XGIVEREF(__pyx_r);
17829  __Pyx_RefNannyFinishContext();
17830  return __pyx_r;
17831  }
17832 
17833  /* Python wrapper */
17834  static PyObject *__pyx_pw_8PyClical_81agc3(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
17835  static char __pyx_doc_8PyClical_80agc3[] = "\n Convert CGA3 null vector to Euclidean 3D vector using Doran and Lasenby definition.\n\n >>> x=clifford(\"2{1}+9{2}+{3}\"); print agc3(cga3(x))\n 2{1}+9{2}+{3}\n >>> x=clifford(\"2{1}+9{2}+{3}\"); print agc3(cga3(x))-x\n 0\n ";
17836  static PyObject *__pyx_pw_8PyClical_81agc3(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
17837  PyObject *__pyx_r = 0;
17838  __Pyx_RefNannyDeclarations
17839  __Pyx_RefNannySetupContext("agc3 (wrapper)", 0);
17840  __pyx_r = __pyx_pf_8PyClical_80agc3(__pyx_self, ((PyObject *)__pyx_v_obj));
17841 
17842  /* function exit code */
17843  __Pyx_RefNannyFinishContext();
17844  return __pyx_r;
17845  }
17846 
17847  static PyObject *__pyx_pf_8PyClical_80agc3(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
17848  PyObject *__pyx_r = NULL;
17849  __Pyx_RefNannyDeclarations
17850  PyObject *__pyx_t_1 = NULL;
17851  int __pyx_lineno = 0;
17852  const char *__pyx_filename = NULL;
17853  int __pyx_clineno = 0;
17854  __Pyx_RefNannySetupContext("agc3", 0);
17855  __Pyx_XDECREF(__pyx_r);
17856  __pyx_t_1 = __pyx_f_8PyClical_agc3(__pyx_v_obj, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1844; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17857  __Pyx_GOTREF(__pyx_t_1);
17858  __pyx_r = __pyx_t_1;
17859  __pyx_t_1 = 0;
17860  goto __pyx_L0;
17861 
17862  /* function exit code */
17863  __pyx_L1_error:;
17864  __Pyx_XDECREF(__pyx_t_1);
17865  __Pyx_AddTraceback("PyClical.agc3", __pyx_clineno, __pyx_lineno, __pyx_filename);
17866  __pyx_r = NULL;
17867  __pyx_L0:;
17868  __Pyx_XGIVEREF(__pyx_r);
17869  __Pyx_RefNannyFinishContext();
17870  return __pyx_r;
17871  }
17872 
17873  /* "PyClical.pyx":1887
17874  * """
17875  *
17876  * def e(obj): # <<<<<<<<<<<<<<
17877  * """
17878  * Abbreviation for clifford(index_set(obj)).
17879  */
17880 
17881  /* Python wrapper */
17882  static PyObject *__pyx_pw_8PyClical_83e(PyObject *__pyx_self, PyObject *__pyx_v_obj); /*proto*/
17883  static char __pyx_doc_8PyClical_82e[] = "\n Abbreviation for clifford(index_set(obj)).\n\n >>> print e(1)\n {1}\n >>> print e(-1)\n {-1}\n >>> print e(0)\n 1\n ";
17884  static PyMethodDef __pyx_mdef_8PyClical_83e = {"e", (PyCFunction)__pyx_pw_8PyClical_83e, METH_O, __pyx_doc_8PyClical_82e};
17885  static PyObject *__pyx_pw_8PyClical_83e(PyObject *__pyx_self, PyObject *__pyx_v_obj) {
17886  PyObject *__pyx_r = 0;
17887  __Pyx_RefNannyDeclarations
17888  __Pyx_RefNannySetupContext("e (wrapper)", 0);
17889  __pyx_r = __pyx_pf_8PyClical_82e(__pyx_self, ((PyObject *)__pyx_v_obj));
17890 
17891  /* function exit code */
17892  __Pyx_RefNannyFinishContext();
17893  return __pyx_r;
17894  }
17895 
17896  static PyObject *__pyx_pf_8PyClical_82e(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_obj) {
17897  PyObject *__pyx_r = NULL;
17898  __Pyx_RefNannyDeclarations
17899  PyObject *__pyx_t_1 = NULL;
17900  PyObject *__pyx_t_2 = NULL;
17901  int __pyx_lineno = 0;
17902  const char *__pyx_filename = NULL;
17903  int __pyx_clineno = 0;
17904  __Pyx_RefNannySetupContext("e", 0);
17905 
17906  /* "PyClical.pyx":1898
17907  * 1
17908  * """
17909  * return clifford(index_set(obj)) # <<<<<<<<<<<<<<
17910  *
17911  * def istpq(p, q):
17912  */
17913  __Pyx_XDECREF(__pyx_r);
17914  __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1898; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17915  __Pyx_GOTREF(__pyx_t_1);
17916  __Pyx_INCREF(__pyx_v_obj);
17917  __Pyx_GIVEREF(__pyx_v_obj);
17918  PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_obj);
17919  __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_index_set), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1898; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17920  __Pyx_GOTREF(__pyx_t_2);
17921  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
17922  __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1898; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17923  __Pyx_GOTREF(__pyx_t_1);
17924  __Pyx_GIVEREF(__pyx_t_2);
17925  PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_2);
17926  __pyx_t_2 = 0;
17927  __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1898; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
17928  __Pyx_GOTREF(__pyx_t_2);
17929  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
17930  __pyx_r = __pyx_t_2;
17931  __pyx_t_2 = 0;
17932  goto __pyx_L0;
17933 
17934  /* "PyClical.pyx":1887
17935  * """
17936  *
17937  * def e(obj): # <<<<<<<<<<<<<<
17938  * """
17939  * Abbreviation for clifford(index_set(obj)).
17940  */
17941 
17942  /* function exit code */
17943  __pyx_L1_error:;
17944  __Pyx_XDECREF(__pyx_t_1);
17945  __Pyx_XDECREF(__pyx_t_2);
17946  __Pyx_AddTraceback("PyClical.e", __pyx_clineno, __pyx_lineno, __pyx_filename);
17947  __pyx_r = NULL;
17948  __pyx_L0:;
17949  __Pyx_XGIVEREF(__pyx_r);
17950  __Pyx_RefNannyFinishContext();
17951  return __pyx_r;
17952  }
17953 
17954  /* "PyClical.pyx":1900
17955  * return clifford(index_set(obj))
17956  *
17957  * def istpq(p, q): # <<<<<<<<<<<<<<
17958  * """
17959  * Abbreviation for index_set({-q,...p}).
17960  */
17961 
17962  /* Python wrapper */
17963  static PyObject *__pyx_pw_8PyClical_85istpq(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
17964  static char __pyx_doc_8PyClical_84istpq[] = "\n Abbreviation for index_set({-q,...p}).\n\n >>> print istpq(2,3)\n {-3,-2,-1,1,2}\n ";
17965  static PyMethodDef __pyx_mdef_8PyClical_85istpq = {"istpq", (PyCFunction)__pyx_pw_8PyClical_85istpq, METH_VARARGS|METH_KEYWORDS, __pyx_doc_8PyClical_84istpq};
17966  static PyObject *__pyx_pw_8PyClical_85istpq(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
17967  PyObject *__pyx_v_p = 0;
17968  PyObject *__pyx_v_q = 0;
17969  int __pyx_lineno = 0;
17970  const char *__pyx_filename = NULL;
17971  int __pyx_clineno = 0;
17972  PyObject *__pyx_r = 0;
17973  __Pyx_RefNannyDeclarations
17974  __Pyx_RefNannySetupContext("istpq (wrapper)", 0);
17975  {
17976  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_p,&__pyx_n_s_q,0};
17977  PyObject* values[2] = {0,0};
17978  if (unlikely(__pyx_kwds)) {
17979  Py_ssize_t kw_args;
17980  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
17981  switch (pos_args) {
17982  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
17983  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
17984  case 0: break;
17985  default: goto __pyx_L5_argtuple_error;
17986  }
17987  kw_args = PyDict_Size(__pyx_kwds);
17988  switch (pos_args) {
17989  case 0:
17990  if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_p)) != 0)) kw_args--;
17991  else goto __pyx_L5_argtuple_error;
17992  case 1:
17993  if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_q)) != 0)) kw_args--;
17994  else {
17995  __Pyx_RaiseArgtupleInvalid("istpq", 1, 2, 2, 1); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1900; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
17996  }
17997  }
17998  if (unlikely(kw_args > 0)) {
17999  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "istpq") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1900; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
18000  }
18001  } else if (PyTuple_GET_SIZE(__pyx_args) != 2) {
18002  goto __pyx_L5_argtuple_error;
18003  } else {
18004  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
18005  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
18006  }
18007  __pyx_v_p = values[0];
18008  __pyx_v_q = values[1];
18009  }
18010  goto __pyx_L4_argument_unpacking_done;
18011  __pyx_L5_argtuple_error:;
18012  __Pyx_RaiseArgtupleInvalid("istpq", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1900; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
18013  __pyx_L3_error:;
18014  __Pyx_AddTraceback("PyClical.istpq", __pyx_clineno, __pyx_lineno, __pyx_filename);
18015  __Pyx_RefNannyFinishContext();
18016  return NULL;
18017  __pyx_L4_argument_unpacking_done:;
18018  __pyx_r = __pyx_pf_8PyClical_84istpq(__pyx_self, __pyx_v_p, __pyx_v_q);
18019 
18020  /* function exit code */
18021  __Pyx_RefNannyFinishContext();
18022  return __pyx_r;
18023  }
18024 
18025  static PyObject *__pyx_pf_8PyClical_84istpq(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_p, PyObject *__pyx_v_q) {
18026  PyObject *__pyx_r = NULL;
18027  __Pyx_RefNannyDeclarations
18028  PyObject *__pyx_t_1 = NULL;
18029  PyObject *__pyx_t_2 = NULL;
18030  PyObject *__pyx_t_3 = NULL;
18031  int __pyx_lineno = 0;
18032  const char *__pyx_filename = NULL;
18033  int __pyx_clineno = 0;
18034  __Pyx_RefNannySetupContext("istpq", 0);
18035 
18036  /* "PyClical.pyx":1907
18037  * {-3,-2,-1,1,2}
18038  * """
18039  * return index_set(set(range(-q,p+1))) # <<<<<<<<<<<<<<
18040  *
18041  * ninf3 = e(4) + e(-1) # Null infinity point in 3D Conformal Geometric Algebra [DL].
18042  */
18043  __Pyx_XDECREF(__pyx_r);
18044  __pyx_t_1 = PyNumber_Negative(__pyx_v_q); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1907; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
18045  __Pyx_GOTREF(__pyx_t_1);
18046  __pyx_t_2 = __Pyx_PyInt_AddObjC(__pyx_v_p, __pyx_int_1, 1, 0); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1907; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
18047  __Pyx_GOTREF(__pyx_t_2);
18048  __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1907; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
18049  __Pyx_GOTREF(__pyx_t_3);
18050  __Pyx_GIVEREF(__pyx_t_1);
18051  PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_1);
18052  __Pyx_GIVEREF(__pyx_t_2);
18053  PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_2);
18054  __pyx_t_1 = 0;
18055  __pyx_t_2 = 0;
18056  __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_range, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1907; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
18057  __Pyx_GOTREF(__pyx_t_2);
18058  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
18059  __pyx_t_3 = PySet_New(__pyx_t_2); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1907; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
18060  __Pyx_GOTREF(__pyx_t_3);
18061  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
18062  __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1907; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
18063  __Pyx_GOTREF(__pyx_t_2);
18064  __Pyx_GIVEREF(__pyx_t_3);
18065  PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_3);
18066  __pyx_t_3 = 0;
18067  __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_index_set), __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1907; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
18068  __Pyx_GOTREF(__pyx_t_3);
18069  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
18070  __pyx_r = __pyx_t_3;
18071  __pyx_t_3 = 0;
18072  goto __pyx_L0;
18073 
18074  /* "PyClical.pyx":1900
18075  * return clifford(index_set(obj))
18076  *
18077  * def istpq(p, q): # <<<<<<<<<<<<<<
18078  * """
18079  * Abbreviation for index_set({-q,...p}).
18080  */
18081 
18082  /* function exit code */
18083  __pyx_L1_error:;
18084  __Pyx_XDECREF(__pyx_t_1);
18085  __Pyx_XDECREF(__pyx_t_2);
18086  __Pyx_XDECREF(__pyx_t_3);
18087  __Pyx_AddTraceback("PyClical.istpq", __pyx_clineno, __pyx_lineno, __pyx_filename);
18088  __pyx_r = NULL;
18089  __pyx_L0:;
18090  __Pyx_XGIVEREF(__pyx_r);
18091  __Pyx_RefNannyFinishContext();
18092  return __pyx_r;
18093  }
18094 
18095  /* "PyClical.pyx":1913
18096  *
18097  * # Doctest interface.
18098  * def _test(): # <<<<<<<<<<<<<<
18099  * import PyClical, doctest
18100  * return doctest.testmod(PyClical)
18101  */
18102 
18103  /* Python wrapper */
18104  static PyObject *__pyx_pw_8PyClical_87_test(PyObject *__pyx_self, CYTHON_UNUSED PyObject *unused); /*proto*/
18105  static PyMethodDef __pyx_mdef_8PyClical_87_test = {"_test", (PyCFunction)__pyx_pw_8PyClical_87_test, METH_NOARGS, 0};
18106  static PyObject *__pyx_pw_8PyClical_87_test(PyObject *__pyx_self, CYTHON_UNUSED PyObject *unused) {
18107  PyObject *__pyx_r = 0;
18108  __Pyx_RefNannyDeclarations
18109  __Pyx_RefNannySetupContext("_test (wrapper)", 0);
18110  __pyx_r = __pyx_pf_8PyClical_86_test(__pyx_self);
18111 
18112  /* function exit code */
18113  __Pyx_RefNannyFinishContext();
18114  return __pyx_r;
18115  }
18116 
18117  static PyObject *__pyx_pf_8PyClical_86_test(CYTHON_UNUSED PyObject *__pyx_self) {
18118  PyObject *__pyx_v_PyClical = NULL;
18119  PyObject *__pyx_v_doctest = NULL;
18120  PyObject *__pyx_r = NULL;
18121  __Pyx_RefNannyDeclarations
18122  PyObject *__pyx_t_1 = NULL;
18123  PyObject *__pyx_t_2 = NULL;
18124  PyObject *__pyx_t_3 = NULL;
18125  PyObject *__pyx_t_4 = NULL;
18126  int __pyx_lineno = 0;
18127  const char *__pyx_filename = NULL;
18128  int __pyx_clineno = 0;
18129  __Pyx_RefNannySetupContext("_test", 0);
18130 
18131  /* "PyClical.pyx":1914
18132  * # Doctest interface.
18133  * def _test():
18134  * import PyClical, doctest # <<<<<<<<<<<<<<
18135  * return doctest.testmod(PyClical)
18136  *
18137  */
18138  __pyx_t_1 = __Pyx_Import(__pyx_n_s_PyClical, 0, -1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1914; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
18139  __Pyx_GOTREF(__pyx_t_1);
18140  __pyx_v_PyClical = __pyx_t_1;
18141  __pyx_t_1 = 0;
18142  __pyx_t_1 = __Pyx_Import(__pyx_n_s_doctest, 0, -1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1914; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
18143  __Pyx_GOTREF(__pyx_t_1);
18144  __pyx_v_doctest = __pyx_t_1;
18145  __pyx_t_1 = 0;
18146 
18147  /* "PyClical.pyx":1915
18148  * def _test():
18149  * import PyClical, doctest
18150  * return doctest.testmod(PyClical) # <<<<<<<<<<<<<<
18151  *
18152  * if __name__ == "__main__":
18153  */
18154  __Pyx_XDECREF(__pyx_r);
18155  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_doctest, __pyx_n_s_testmod); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1915; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
18156  __Pyx_GOTREF(__pyx_t_2);
18157  __pyx_t_3 = NULL;
18158  if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_2))) {
18159  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
18160  if (likely(__pyx_t_3)) {
18161  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
18162  __Pyx_INCREF(__pyx_t_3);
18163  __Pyx_INCREF(function);
18164  __Pyx_DECREF_SET(__pyx_t_2, function);
18165  }
18166  }
18167  if (!__pyx_t_3) {
18168  __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_PyClical); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1915; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
18169  __Pyx_GOTREF(__pyx_t_1);
18170  } else {
18171  __pyx_t_4 = PyTuple_New(1+1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1915; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
18172  __Pyx_GOTREF(__pyx_t_4);
18173  __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_3); __pyx_t_3 = NULL;
18174  __Pyx_INCREF(__pyx_v_PyClical);
18175  __Pyx_GIVEREF(__pyx_v_PyClical);
18176  PyTuple_SET_ITEM(__pyx_t_4, 0+1, __pyx_v_PyClical);
18177  __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_4, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1915; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
18178  __Pyx_GOTREF(__pyx_t_1);
18179  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
18180  }
18181  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
18182  __pyx_r = __pyx_t_1;
18183  __pyx_t_1 = 0;
18184  goto __pyx_L0;
18185 
18186  /* "PyClical.pyx":1913
18187  *
18188  * # Doctest interface.
18189  * def _test(): # <<<<<<<<<<<<<<
18190  * import PyClical, doctest
18191  * return doctest.testmod(PyClical)
18192  */
18193 
18194  /* function exit code */
18195  __pyx_L1_error:;
18196  __Pyx_XDECREF(__pyx_t_1);
18197  __Pyx_XDECREF(__pyx_t_2);
18198  __Pyx_XDECREF(__pyx_t_3);
18199  __Pyx_XDECREF(__pyx_t_4);
18200  __Pyx_AddTraceback("PyClical._test", __pyx_clineno, __pyx_lineno, __pyx_filename);
18201  __pyx_r = NULL;
18202  __pyx_L0:;
18203  __Pyx_XDECREF(__pyx_v_PyClical);
18204  __Pyx_XDECREF(__pyx_v_doctest);
18205  __Pyx_XGIVEREF(__pyx_r);
18206  __Pyx_RefNannyFinishContext();
18207  return __pyx_r;
18208  }
18209  static struct __pyx_vtabstruct_8PyClical_index_set __pyx_vtable_8PyClical_index_set;
18210 
18211  static PyObject *__pyx_tp_new_8PyClical_index_set(PyTypeObject *t, PyObject *a, PyObject *k) {
18212  struct __pyx_obj_8PyClical_index_set *p;
18213  PyObject *o;
18214  if (likely((t->tp_flags & Py_TPFLAGS_IS_ABSTRACT) == 0)) {
18215  o = (*t->tp_alloc)(t, 0);
18216  } else {
18217  o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0);
18218  }
18219  if (unlikely(!o)) return 0;
18220  p = ((struct __pyx_obj_8PyClical_index_set *)o);
18221  p->__pyx_vtab = __pyx_vtabptr_8PyClical_index_set;
18222  if (unlikely(__pyx_pw_8PyClical_9index_set_3__cinit__(o, a, k) < 0)) {
18223  Py_DECREF(o); o = 0;
18224  }
18225  return o;
18226  }
18227 
18228  static void __pyx_tp_dealloc_8PyClical_index_set(PyObject *o) {
18229  #if PY_VERSION_HEX >= 0x030400a1
18230  if (unlikely(Py_TYPE(o)->tp_finalize) && (!PyType_IS_GC(Py_TYPE(o)) || !_PyGC_FINALIZED(o))) {
18231  if (PyObject_CallFinalizerFromDealloc(o)) return;
18232  }
18233  #endif
18234  {
18235  PyObject *etype, *eval, *etb;
18236  PyErr_Fetch(&etype, &eval, &etb);
18237  ++Py_REFCNT(o);
18238  __pyx_pw_8PyClical_9index_set_5__dealloc__(o);
18239  --Py_REFCNT(o);
18240  PyErr_Restore(etype, eval, etb);
18241  }
18242  (*Py_TYPE(o)->tp_free)(o);
18243  }
18244  static PyObject *__pyx_sq_item_8PyClical_index_set(PyObject *o, Py_ssize_t i) {
18245  PyObject *r;
18246  PyObject *x = PyInt_FromSsize_t(i); if(!x) return 0;
18247  r = Py_TYPE(o)->tp_as_mapping->mp_subscript(o, x);
18248  Py_DECREF(x);
18249  return r;
18250  }
18251 
18252  static int __pyx_mp_ass_subscript_8PyClical_index_set(PyObject *o, PyObject *i, PyObject *v) {
18253  if (v) {
18254  return __pyx_pw_8PyClical_9index_set_9__setitem__(o, i, v);
18255  }
18256  else {
18257  PyErr_Format(PyExc_NotImplementedError,
18258  "Subscript deletion not supported by %.200s", Py_TYPE(o)->tp_name);
18259  return -1;
18260  }
18261  }
18262 
18263  static PyMethodDef __pyx_methods_8PyClical_index_set[] = {
18264  {"copy", (PyCFunction)__pyx_pw_8PyClical_9index_set_1copy, METH_NOARGS, __pyx_doc_8PyClical_9index_set_copy},
18265  {"count", (PyCFunction)__pyx_pw_8PyClical_9index_set_32count, METH_NOARGS, __pyx_doc_8PyClical_9index_set_31count},
18266  {"count_neg", (PyCFunction)__pyx_pw_8PyClical_9index_set_34count_neg, METH_NOARGS, __pyx_doc_8PyClical_9index_set_33count_neg},
18267  {"count_pos", (PyCFunction)__pyx_pw_8PyClical_9index_set_36count_pos, METH_NOARGS, __pyx_doc_8PyClical_9index_set_35count_pos},
18268  {"min", (PyCFunction)__pyx_pw_8PyClical_9index_set_38min, METH_NOARGS, __pyx_doc_8PyClical_9index_set_37min},
18269  {"max", (PyCFunction)__pyx_pw_8PyClical_9index_set_40max, METH_NOARGS, __pyx_doc_8PyClical_9index_set_39max},
18270  {"hash_fn", (PyCFunction)__pyx_pw_8PyClical_9index_set_42hash_fn, METH_NOARGS, __pyx_doc_8PyClical_9index_set_41hash_fn},
18271  {"sign_of_mult", (PyCFunction)__pyx_pw_8PyClical_9index_set_44sign_of_mult, METH_O, __pyx_doc_8PyClical_9index_set_43sign_of_mult},
18272  {"sign_of_square", (PyCFunction)__pyx_pw_8PyClical_9index_set_46sign_of_square, METH_NOARGS, __pyx_doc_8PyClical_9index_set_45sign_of_square},
18273  {0, 0, 0, 0}
18274  };
18275 
18276  static PyNumberMethods __pyx_tp_as_number_index_set = {
18277  0, /*nb_add*/
18278  0, /*nb_subtract*/
18279  0, /*nb_multiply*/
18280  #if PY_MAJOR_VERSION < 3 || CYTHON_COMPILING_IN_PYPY
18281  0, /*nb_divide*/
18282  #endif
18283  0, /*nb_remainder*/
18284  0, /*nb_divmod*/
18285  0, /*nb_power*/
18286  0, /*nb_negative*/
18287  0, /*nb_positive*/
18288  0, /*nb_absolute*/
18289  0, /*nb_nonzero*/
18290  __pyx_pw_8PyClical_9index_set_18__invert__, /*nb_invert*/
18291  0, /*nb_lshift*/
18292  0, /*nb_rshift*/
18293  __pyx_pw_8PyClical_9index_set_24__and__, /*nb_and*/
18294  __pyx_pw_8PyClical_9index_set_20__xor__, /*nb_xor*/
18295  __pyx_pw_8PyClical_9index_set_28__or__, /*nb_or*/
18296  #if PY_MAJOR_VERSION < 3 || CYTHON_COMPILING_IN_PYPY
18297  0, /*nb_coerce*/
18298  #endif
18299  0, /*nb_int*/
18300  #if PY_MAJOR_VERSION < 3
18301  0, /*nb_long*/
18302  #else
18303  0, /*reserved*/
18304  #endif
18305  0, /*nb_float*/
18306  #if PY_MAJOR_VERSION < 3 || CYTHON_COMPILING_IN_PYPY
18307  0, /*nb_oct*/
18308  #endif
18309  #if PY_MAJOR_VERSION < 3 || CYTHON_COMPILING_IN_PYPY
18310  0, /*nb_hex*/
18311  #endif
18312  0, /*nb_inplace_add*/
18313  0, /*nb_inplace_subtract*/
18314  0, /*nb_inplace_multiply*/
18315  #if PY_MAJOR_VERSION < 3 || CYTHON_COMPILING_IN_PYPY
18316  0, /*nb_inplace_divide*/
18317  #endif
18318  0, /*nb_inplace_remainder*/
18319  0, /*nb_inplace_power*/
18320  0, /*nb_inplace_lshift*/
18321  0, /*nb_inplace_rshift*/
18322  __pyx_pw_8PyClical_9index_set_26__iand__, /*nb_inplace_and*/
18323  __pyx_pw_8PyClical_9index_set_22__ixor__, /*nb_inplace_xor*/
18324  __pyx_pw_8PyClical_9index_set_30__ior__, /*nb_inplace_or*/
18325  0, /*nb_floor_divide*/
18326  0, /*nb_true_divide*/
18327  0, /*nb_inplace_floor_divide*/
18328  0, /*nb_inplace_true_divide*/
18329  0, /*nb_index*/
18330  #if PY_VERSION_HEX >= 0x03050000
18331  0, /*nb_matrix_multiply*/
18332  #endif
18333  #if PY_VERSION_HEX >= 0x03050000
18334  0, /*nb_inplace_matrix_multiply*/
18335  #endif
18336  };
18337 
18338  static PySequenceMethods __pyx_tp_as_sequence_index_set = {
18339  0, /*sq_length*/
18340  0, /*sq_concat*/
18341  0, /*sq_repeat*/
18342  __pyx_sq_item_8PyClical_index_set, /*sq_item*/
18343  0, /*sq_slice*/
18344  0, /*sq_ass_item*/
18345  0, /*sq_ass_slice*/
18346  __pyx_pw_8PyClical_9index_set_13__contains__, /*sq_contains*/
18347  0, /*sq_inplace_concat*/
18348  0, /*sq_inplace_repeat*/
18349  };
18350 
18351  static PyMappingMethods __pyx_tp_as_mapping_index_set = {
18352  0, /*mp_length*/
18353  __pyx_pw_8PyClical_9index_set_11__getitem__, /*mp_subscript*/
18354  __pyx_mp_ass_subscript_8PyClical_index_set, /*mp_ass_subscript*/
18355  };
18356 
18357  static PyTypeObject __pyx_type_8PyClical_index_set = {
18358  PyVarObject_HEAD_INIT(0, 0)
18359  "PyClical.index_set", /*tp_name*/
18360  sizeof(struct __pyx_obj_8PyClical_index_set), /*tp_basicsize*/
18361  0, /*tp_itemsize*/
18362  __pyx_tp_dealloc_8PyClical_index_set, /*tp_dealloc*/
18363  0, /*tp_print*/
18364  0, /*tp_getattr*/
18365  0, /*tp_setattr*/
18366  #if PY_MAJOR_VERSION < 3
18367  0, /*tp_compare*/
18368  #endif
18369  #if PY_MAJOR_VERSION >= 3
18370  0, /*tp_as_async*/
18371  #endif
18372  __pyx_pw_8PyClical_9index_set_48__repr__, /*tp_repr*/
18373  &__pyx_tp_as_number_index_set, /*tp_as_number*/
18374  &__pyx_tp_as_sequence_index_set, /*tp_as_sequence*/
18375  &__pyx_tp_as_mapping_index_set, /*tp_as_mapping*/
18376  0, /*tp_hash*/
18377  0, /*tp_call*/
18378  __pyx_pw_8PyClical_9index_set_50__str__, /*tp_str*/
18379  0, /*tp_getattro*/
18380  0, /*tp_setattro*/
18381  0, /*tp_as_buffer*/
18382  Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE, /*tp_flags*/
18383  "\n Python class index_set wraps C++ class IndexSet.\n ", /*tp_doc*/
18384  0, /*tp_traverse*/
18385  0, /*tp_clear*/
18386  __pyx_pw_8PyClical_9index_set_7__richcmp__, /*tp_richcompare*/
18387  0, /*tp_weaklistoffset*/
18388  __pyx_pw_8PyClical_9index_set_15__iter__, /*tp_iter*/
18389  0, /*tp_iternext*/
18390  __pyx_methods_8PyClical_index_set, /*tp_methods*/
18391  0, /*tp_members*/
18392  0, /*tp_getset*/
18393  0, /*tp_base*/
18394  0, /*tp_dict*/
18395  0, /*tp_descr_get*/
18396  0, /*tp_descr_set*/
18397  0, /*tp_dictoffset*/
18398  0, /*tp_init*/
18399  0, /*tp_alloc*/
18400  __pyx_tp_new_8PyClical_index_set, /*tp_new*/
18401  0, /*tp_free*/
18402  0, /*tp_is_gc*/
18403  0, /*tp_bases*/
18404  0, /*tp_mro*/
18405  0, /*tp_cache*/
18406  0, /*tp_subclasses*/
18407  0, /*tp_weaklist*/
18408  0, /*tp_del*/
18409  0, /*tp_version_tag*/
18410  #if PY_VERSION_HEX >= 0x030400a1
18411  0, /*tp_finalize*/
18412  #endif
18413  };
18414  static struct __pyx_vtabstruct_8PyClical_clifford __pyx_vtable_8PyClical_clifford;
18415 
18416  static PyObject *__pyx_tp_new_8PyClical_clifford(PyTypeObject *t, PyObject *a, PyObject *k) {
18417  struct __pyx_obj_8PyClical_clifford *p;
18418  PyObject *o;
18419  if (likely((t->tp_flags & Py_TPFLAGS_IS_ABSTRACT) == 0)) {
18420  o = (*t->tp_alloc)(t, 0);
18421  } else {
18422  o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0);
18423  }
18424  if (unlikely(!o)) return 0;
18425  p = ((struct __pyx_obj_8PyClical_clifford *)o);
18426  p->__pyx_vtab = __pyx_vtabptr_8PyClical_clifford;
18427  if (unlikely(__pyx_pw_8PyClical_8clifford_3__cinit__(o, a, k) < 0)) {
18428  Py_DECREF(o); o = 0;
18429  }
18430  return o;
18431  }
18432 
18433  static void __pyx_tp_dealloc_8PyClical_clifford(PyObject *o) {
18434  #if PY_VERSION_HEX >= 0x030400a1
18435  if (unlikely(Py_TYPE(o)->tp_finalize) && (!PyType_IS_GC(Py_TYPE(o)) || !_PyGC_FINALIZED(o))) {
18436  if (PyObject_CallFinalizerFromDealloc(o)) return;
18437  }
18438  #endif
18439  {
18440  PyObject *etype, *eval, *etb;
18441  PyErr_Fetch(&etype, &eval, &etb);
18442  ++Py_REFCNT(o);
18443  __pyx_pw_8PyClical_8clifford_5__dealloc__(o);
18444  --Py_REFCNT(o);
18445  PyErr_Restore(etype, eval, etb);
18446  }
18447  (*Py_TYPE(o)->tp_free)(o);
18448  }
18449  static PyObject *__pyx_sq_item_8PyClical_clifford(PyObject *o, Py_ssize_t i) {
18450  PyObject *r;
18451  PyObject *x = PyInt_FromSsize_t(i); if(!x) return 0;
18452  r = Py_TYPE(o)->tp_as_mapping->mp_subscript(o, x);
18453  Py_DECREF(x);
18454  return r;
18455  }
18456 
18457  static PyMethodDef __pyx_methods_8PyClical_clifford[] = {
18458  {"copy", (PyCFunction)__pyx_pw_8PyClical_8clifford_1copy, METH_NOARGS, __pyx_doc_8PyClical_8clifford_copy},
18459  {"reframe", (PyCFunction)__pyx_pw_8PyClical_8clifford_11reframe, METH_O, __pyx_doc_8PyClical_8clifford_10reframe},
18460  {"inv", (PyCFunction)__pyx_pw_8PyClical_8clifford_49inv, METH_NOARGS, __pyx_doc_8PyClical_8clifford_48inv},
18461  {"pow", (PyCFunction)__pyx_pw_8PyClical_8clifford_57pow, METH_O, __pyx_doc_8PyClical_8clifford_56pow},
18462  {"outer_pow", (PyCFunction)__pyx_pw_8PyClical_8clifford_59outer_pow, METH_O, __pyx_doc_8PyClical_8clifford_58outer_pow},
18463  {"scalar", (PyCFunction)__pyx_pw_8PyClical_8clifford_63scalar, METH_NOARGS, __pyx_doc_8PyClical_8clifford_62scalar},
18464  {"pure", (PyCFunction)__pyx_pw_8PyClical_8clifford_65pure, METH_NOARGS, __pyx_doc_8PyClical_8clifford_64pure},
18465  {"even", (PyCFunction)__pyx_pw_8PyClical_8clifford_67even, METH_NOARGS, __pyx_doc_8PyClical_8clifford_66even},
18466  {"odd", (PyCFunction)__pyx_pw_8PyClical_8clifford_69odd, METH_NOARGS, __pyx_doc_8PyClical_8clifford_68odd},
18467  {"vector_part", (PyCFunction)__pyx_pw_8PyClical_8clifford_71vector_part, METH_VARARGS|METH_KEYWORDS, __pyx_doc_8PyClical_8clifford_70vector_part},
18468  {"involute", (PyCFunction)__pyx_pw_8PyClical_8clifford_73involute, METH_NOARGS, __pyx_doc_8PyClical_8clifford_72involute},
18469  {"reverse", (PyCFunction)__pyx_pw_8PyClical_8clifford_75reverse, METH_NOARGS, __pyx_doc_8PyClical_8clifford_74reverse},
18470  {"conj", (PyCFunction)__pyx_pw_8PyClical_8clifford_77conj, METH_NOARGS, __pyx_doc_8PyClical_8clifford_76conj},
18471  {"quad", (PyCFunction)__pyx_pw_8PyClical_8clifford_79quad, METH_NOARGS, __pyx_doc_8PyClical_8clifford_78quad},
18472  {"norm", (PyCFunction)__pyx_pw_8PyClical_8clifford_81norm, METH_NOARGS, __pyx_doc_8PyClical_8clifford_80norm},
18473  {"abs", (PyCFunction)__pyx_pw_8PyClical_8clifford_83abs, METH_NOARGS, __pyx_doc_8PyClical_8clifford_82abs},
18474  {"max_abs", (PyCFunction)__pyx_pw_8PyClical_8clifford_85max_abs, METH_NOARGS, __pyx_doc_8PyClical_8clifford_84max_abs},
18475  {"truncated", (PyCFunction)__pyx_pw_8PyClical_8clifford_87truncated, METH_O, __pyx_doc_8PyClical_8clifford_86truncated},
18476  {"isnan", (PyCFunction)__pyx_pw_8PyClical_8clifford_89isnan, METH_NOARGS, __pyx_doc_8PyClical_8clifford_88isnan},
18477  {"frame", (PyCFunction)__pyx_pw_8PyClical_8clifford_91frame, METH_NOARGS, __pyx_doc_8PyClical_8clifford_90frame},
18478  {0, 0, 0, 0}
18479  };
18480 
18481  static PyNumberMethods __pyx_tp_as_number_clifford = {
18482  __pyx_pw_8PyClical_8clifford_21__add__, /*nb_add*/
18483  __pyx_pw_8PyClical_8clifford_25__sub__, /*nb_subtract*/
18484  __pyx_pw_8PyClical_8clifford_29__mul__, /*nb_multiply*/
18485  #if PY_MAJOR_VERSION < 3 || CYTHON_COMPILING_IN_PYPY
18486  __pyx_pw_8PyClical_8clifford_45__div__, /*nb_divide*/
18487  #endif
18488  __pyx_pw_8PyClical_8clifford_33__mod__, /*nb_remainder*/
18489  0, /*nb_divmod*/
18490  __pyx_pw_8PyClical_8clifford_55__pow__, /*nb_power*/
18491  __pyx_pw_8PyClical_8clifford_17__neg__, /*nb_negative*/
18492  __pyx_pw_8PyClical_8clifford_19__pos__, /*nb_positive*/
18493  0, /*nb_absolute*/
18494  0, /*nb_nonzero*/
18495  0, /*nb_invert*/
18496  0, /*nb_lshift*/
18497  0, /*nb_rshift*/
18498  __pyx_pw_8PyClical_8clifford_37__and__, /*nb_and*/
18499  __pyx_pw_8PyClical_8clifford_41__xor__, /*nb_xor*/
18500  __pyx_pw_8PyClical_8clifford_51__or__, /*nb_or*/
18501  #if PY_MAJOR_VERSION < 3 || CYTHON_COMPILING_IN_PYPY
18502  0, /*nb_coerce*/
18503  #endif
18504  0, /*nb_int*/
18505  #if PY_MAJOR_VERSION < 3
18506  0, /*nb_long*/
18507  #else
18508  0, /*reserved*/
18509  #endif
18510  0, /*nb_float*/
18511  #if PY_MAJOR_VERSION < 3 || CYTHON_COMPILING_IN_PYPY
18512  0, /*nb_oct*/
18513  #endif
18514  #if PY_MAJOR_VERSION < 3 || CYTHON_COMPILING_IN_PYPY
18515  0, /*nb_hex*/
18516  #endif
18517  __pyx_pw_8PyClical_8clifford_23__iadd__, /*nb_inplace_add*/
18518  __pyx_pw_8PyClical_8clifford_27__isub__, /*nb_inplace_subtract*/
18519  __pyx_pw_8PyClical_8clifford_31__imul__, /*nb_inplace_multiply*/
18520  #if PY_MAJOR_VERSION < 3 || CYTHON_COMPILING_IN_PYPY
18521  __pyx_pw_8PyClical_8clifford_47__idiv__, /*nb_inplace_divide*/
18522  #endif
18523  __pyx_pw_8PyClical_8clifford_35__imod__, /*nb_inplace_remainder*/
18524  0, /*nb_inplace_power*/
18525  0, /*nb_inplace_lshift*/
18526  0, /*nb_inplace_rshift*/
18527  __pyx_pw_8PyClical_8clifford_39__iand__, /*nb_inplace_and*/
18528  __pyx_pw_8PyClical_8clifford_43__ixor__, /*nb_inplace_xor*/
18529  __pyx_pw_8PyClical_8clifford_53__ior__, /*nb_inplace_or*/
18530  0, /*nb_floor_divide*/
18531  0, /*nb_true_divide*/
18532  0, /*nb_inplace_floor_divide*/
18533  0, /*nb_inplace_true_divide*/
18534  0, /*nb_index*/
18535  #if PY_VERSION_HEX >= 0x03050000
18536  0, /*nb_matrix_multiply*/
18537  #endif
18538  #if PY_VERSION_HEX >= 0x03050000
18539  0, /*nb_inplace_matrix_multiply*/
18540  #endif
18541  };
18542 
18543  static PySequenceMethods __pyx_tp_as_sequence_clifford = {
18544  0, /*sq_length*/
18545  0, /*sq_concat*/
18546  0, /*sq_repeat*/
18547  __pyx_sq_item_8PyClical_clifford, /*sq_item*/
18548  0, /*sq_slice*/
18549  0, /*sq_ass_item*/
18550  0, /*sq_ass_slice*/
18551  __pyx_pw_8PyClical_8clifford_7__contains__, /*sq_contains*/
18552  0, /*sq_inplace_concat*/
18553  0, /*sq_inplace_repeat*/
18554  };
18555 
18556  static PyMappingMethods __pyx_tp_as_mapping_clifford = {
18557  0, /*mp_length*/
18558  __pyx_pw_8PyClical_8clifford_15__getitem__, /*mp_subscript*/
18559  0, /*mp_ass_subscript*/
18560  };
18561 
18562  static PyTypeObject __pyx_type_8PyClical_clifford = {
18563  PyVarObject_HEAD_INIT(0, 0)
18564  "PyClical.clifford", /*tp_name*/
18565  sizeof(struct __pyx_obj_8PyClical_clifford), /*tp_basicsize*/
18566  0, /*tp_itemsize*/
18567  __pyx_tp_dealloc_8PyClical_clifford, /*tp_dealloc*/
18568  0, /*tp_print*/
18569  0, /*tp_getattr*/
18570  0, /*tp_setattr*/
18571  #if PY_MAJOR_VERSION < 3
18572  0, /*tp_compare*/
18573  #endif
18574  #if PY_MAJOR_VERSION >= 3
18575  0, /*tp_as_async*/
18576  #endif
18577  __pyx_pw_8PyClical_8clifford_93__repr__, /*tp_repr*/
18578  &__pyx_tp_as_number_clifford, /*tp_as_number*/
18579  &__pyx_tp_as_sequence_clifford, /*tp_as_sequence*/
18580  &__pyx_tp_as_mapping_clifford, /*tp_as_mapping*/
18581  0, /*tp_hash*/
18582  __pyx_pw_8PyClical_8clifford_61__call__, /*tp_call*/
18583  __pyx_pw_8PyClical_8clifford_95__str__, /*tp_str*/
18584  0, /*tp_getattro*/
18585  0, /*tp_setattro*/
18586  0, /*tp_as_buffer*/
18587  Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE, /*tp_flags*/
18588  "\n Python class clifford wraps C++ class Clifford.\n ", /*tp_doc*/
18589  0, /*tp_traverse*/
18590  0, /*tp_clear*/
18591  __pyx_pw_8PyClical_8clifford_13__richcmp__, /*tp_richcompare*/
18592  0, /*tp_weaklistoffset*/
18593  __pyx_pw_8PyClical_8clifford_9__iter__, /*tp_iter*/
18594  0, /*tp_iternext*/
18595  __pyx_methods_8PyClical_clifford, /*tp_methods*/
18596  0, /*tp_members*/
18597  0, /*tp_getset*/
18598  0, /*tp_base*/
18599  0, /*tp_dict*/
18600  0, /*tp_descr_get*/
18601  0, /*tp_descr_set*/
18602  0, /*tp_dictoffset*/
18603  0, /*tp_init*/
18604  0, /*tp_alloc*/
18605  __pyx_tp_new_8PyClical_clifford, /*tp_new*/
18606  0, /*tp_free*/
18607  0, /*tp_is_gc*/
18608  0, /*tp_bases*/
18609  0, /*tp_mro*/
18610  0, /*tp_cache*/
18611  0, /*tp_subclasses*/
18612  0, /*tp_weaklist*/
18613  0, /*tp_del*/
18614  0, /*tp_version_tag*/
18615  #if PY_VERSION_HEX >= 0x030400a1
18616  0, /*tp_finalize*/
18617  #endif
18618  };
18619 
18620  static struct __pyx_obj_8PyClical___pyx_scope_struct____iter__ *__pyx_freelist_8PyClical___pyx_scope_struct____iter__[8];
18621  static int __pyx_freecount_8PyClical___pyx_scope_struct____iter__ = 0;
18622 
18623  static PyObject *__pyx_tp_new_8PyClical___pyx_scope_struct____iter__(PyTypeObject *t, CYTHON_UNUSED PyObject *a, CYTHON_UNUSED PyObject *k) {
18624  PyObject *o;
18625  if (CYTHON_COMPILING_IN_CPYTHON && likely((__pyx_freecount_8PyClical___pyx_scope_struct____iter__ > 0) & (t->tp_basicsize == sizeof(struct __pyx_obj_8PyClical___pyx_scope_struct____iter__)))) {
18626  o = (PyObject*)__pyx_freelist_8PyClical___pyx_scope_struct____iter__[--__pyx_freecount_8PyClical___pyx_scope_struct____iter__];
18627  memset(o, 0, sizeof(struct __pyx_obj_8PyClical___pyx_scope_struct____iter__));
18628  (void) PyObject_INIT(o, t);
18629  PyObject_GC_Track(o);
18630  } else {
18631  o = (*t->tp_alloc)(t, 0);
18632  if (unlikely(!o)) return 0;
18633  }
18634  return o;
18635  }
18636 
18637  static void __pyx_tp_dealloc_8PyClical___pyx_scope_struct____iter__(PyObject *o) {
18638  struct __pyx_obj_8PyClical___pyx_scope_struct____iter__ *p = (struct __pyx_obj_8PyClical___pyx_scope_struct____iter__ *)o;
18639  PyObject_GC_UnTrack(o);
18640  Py_CLEAR(p->__pyx_v_idx);
18641  Py_CLEAR(p->__pyx_v_self);
18642  Py_CLEAR(p->__pyx_t_0);
18643  if (CYTHON_COMPILING_IN_CPYTHON && ((__pyx_freecount_8PyClical___pyx_scope_struct____iter__ < 8) & (Py_TYPE(o)->tp_basicsize == sizeof(struct __pyx_obj_8PyClical___pyx_scope_struct____iter__)))) {
18644  __pyx_freelist_8PyClical___pyx_scope_struct____iter__[__pyx_freecount_8PyClical___pyx_scope_struct____iter__++] = ((struct __pyx_obj_8PyClical___pyx_scope_struct____iter__ *)o);
18645  } else {
18646  (*Py_TYPE(o)->tp_free)(o);
18647  }
18648  }
18649 
18650  static int __pyx_tp_traverse_8PyClical___pyx_scope_struct____iter__(PyObject *o, visitproc v, void *a) {
18651  int e;
18652  struct __pyx_obj_8PyClical___pyx_scope_struct____iter__ *p = (struct __pyx_obj_8PyClical___pyx_scope_struct____iter__ *)o;
18653  if (p->__pyx_v_idx) {
18654  e = (*v)(p->__pyx_v_idx, a); if (e) return e;
18655  }
18656  if (p->__pyx_v_self) {
18657  e = (*v)(((PyObject*)p->__pyx_v_self), a); if (e) return e;
18658  }
18659  if (p->__pyx_t_0) {
18660  e = (*v)(p->__pyx_t_0, a); if (e) return e;
18661  }
18662  return 0;
18663  }
18664 
18665  static int __pyx_tp_clear_8PyClical___pyx_scope_struct____iter__(PyObject *o) {
18666  PyObject* tmp;
18667  struct __pyx_obj_8PyClical___pyx_scope_struct____iter__ *p = (struct __pyx_obj_8PyClical___pyx_scope_struct____iter__ *)o;
18668  tmp = ((PyObject*)p->__pyx_v_idx);
18669  p->__pyx_v_idx = Py_None; Py_INCREF(Py_None);
18670  Py_XDECREF(tmp);
18671  tmp = ((PyObject*)p->__pyx_v_self);
18672  p->__pyx_v_self = ((struct __pyx_obj_8PyClical_index_set *)Py_None); Py_INCREF(Py_None);
18673  Py_XDECREF(tmp);
18674  tmp = ((PyObject*)p->__pyx_t_0);
18675  p->__pyx_t_0 = Py_None; Py_INCREF(Py_None);
18676  Py_XDECREF(tmp);
18677  return 0;
18678  }
18679 
18680  static PyTypeObject __pyx_type_8PyClical___pyx_scope_struct____iter__ = {
18681  PyVarObject_HEAD_INIT(0, 0)
18682  "PyClical.__pyx_scope_struct____iter__", /*tp_name*/
18683  sizeof(struct __pyx_obj_8PyClical___pyx_scope_struct____iter__), /*tp_basicsize*/
18684  0, /*tp_itemsize*/
18685  __pyx_tp_dealloc_8PyClical___pyx_scope_struct____iter__, /*tp_dealloc*/
18686  0, /*tp_print*/
18687  0, /*tp_getattr*/
18688  0, /*tp_setattr*/
18689  #if PY_MAJOR_VERSION < 3
18690  0, /*tp_compare*/
18691  #endif
18692  #if PY_MAJOR_VERSION >= 3
18693  0, /*tp_as_async*/
18694  #endif
18695  0, /*tp_repr*/
18696  0, /*tp_as_number*/
18697  0, /*tp_as_sequence*/
18698  0, /*tp_as_mapping*/
18699  0, /*tp_hash*/
18700  0, /*tp_call*/
18701  0, /*tp_str*/
18702  0, /*tp_getattro*/
18703  0, /*tp_setattro*/
18704  0, /*tp_as_buffer*/
18705  Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
18706  0, /*tp_doc*/
18707  __pyx_tp_traverse_8PyClical___pyx_scope_struct____iter__, /*tp_traverse*/
18708  __pyx_tp_clear_8PyClical___pyx_scope_struct____iter__, /*tp_clear*/
18709  0, /*tp_richcompare*/
18710  0, /*tp_weaklistoffset*/
18711  0, /*tp_iter*/
18712  0, /*tp_iternext*/
18713  0, /*tp_methods*/
18714  0, /*tp_members*/
18715  0, /*tp_getset*/
18716  0, /*tp_base*/
18717  0, /*tp_dict*/
18718  0, /*tp_descr_get*/
18719  0, /*tp_descr_set*/
18720  0, /*tp_dictoffset*/
18721  0, /*tp_init*/
18722  0, /*tp_alloc*/
18723  __pyx_tp_new_8PyClical___pyx_scope_struct____iter__, /*tp_new*/
18724  0, /*tp_free*/
18725  0, /*tp_is_gc*/
18726  0, /*tp_bases*/
18727  0, /*tp_mro*/
18728  0, /*tp_cache*/
18729  0, /*tp_subclasses*/
18730  0, /*tp_weaklist*/
18731  0, /*tp_del*/
18732  0, /*tp_version_tag*/
18733  #if PY_VERSION_HEX >= 0x030400a1
18734  0, /*tp_finalize*/
18735  #endif
18736  };
18737 
18738  static PyMethodDef __pyx_methods[] = {
18739  {"compare", (PyCFunction)__pyx_pw_8PyClical_3compare, METH_VARARGS|METH_KEYWORDS, __pyx_doc_8PyClical_2compare},
18740  {"min_neg", (PyCFunction)__pyx_pw_8PyClical_5min_neg, METH_O, __pyx_doc_8PyClical_4min_neg},
18741  {"max_pos", (PyCFunction)__pyx_pw_8PyClical_7max_pos, METH_O, __pyx_doc_8PyClical_6max_pos},
18742  {"inv", (PyCFunction)__pyx_pw_8PyClical_11inv, METH_O, __pyx_doc_8PyClical_10inv},
18743  {"scalar", (PyCFunction)__pyx_pw_8PyClical_13scalar, METH_O, __pyx_doc_8PyClical_12scalar},
18744  {"real", (PyCFunction)__pyx_pw_8PyClical_15real, METH_O, __pyx_doc_8PyClical_14real},
18745  {"imag", (PyCFunction)__pyx_pw_8PyClical_17imag, METH_O, __pyx_doc_8PyClical_16imag},
18746  {"pure", (PyCFunction)__pyx_pw_8PyClical_19pure, METH_O, __pyx_doc_8PyClical_18pure},
18747  {"even", (PyCFunction)__pyx_pw_8PyClical_21even, METH_O, __pyx_doc_8PyClical_20even},
18748  {"odd", (PyCFunction)__pyx_pw_8PyClical_23odd, METH_O, __pyx_doc_8PyClical_22odd},
18749  {"involute", (PyCFunction)__pyx_pw_8PyClical_25involute, METH_O, __pyx_doc_8PyClical_24involute},
18750  {"reverse", (PyCFunction)__pyx_pw_8PyClical_27reverse, METH_O, __pyx_doc_8PyClical_26reverse},
18751  {"conj", (PyCFunction)__pyx_pw_8PyClical_29conj, METH_O, __pyx_doc_8PyClical_28conj},
18752  {"quad", (PyCFunction)__pyx_pw_8PyClical_31quad, METH_O, __pyx_doc_8PyClical_30quad},
18753  {"norm", (PyCFunction)__pyx_pw_8PyClical_33norm, METH_O, __pyx_doc_8PyClical_32norm},
18754  {"abs", (PyCFunction)__pyx_pw_8PyClical_35abs, METH_O, __pyx_doc_8PyClical_34abs},
18755  {"max_abs", (PyCFunction)__pyx_pw_8PyClical_37max_abs, METH_O, __pyx_doc_8PyClical_36max_abs},
18756  {"pow", (PyCFunction)__pyx_pw_8PyClical_39pow, METH_VARARGS|METH_KEYWORDS, __pyx_doc_8PyClical_38pow},
18757  {"outer_pow", (PyCFunction)__pyx_pw_8PyClical_41outer_pow, METH_VARARGS|METH_KEYWORDS, __pyx_doc_8PyClical_40outer_pow},
18758  {"complexifier", (PyCFunction)__pyx_pw_8PyClical_43complexifier, METH_O, __pyx_doc_8PyClical_42complexifier},
18759  {"sqrt", (PyCFunction)__pyx_pw_8PyClical_45sqrt, METH_VARARGS|METH_KEYWORDS, __pyx_doc_8PyClical_44sqrt},
18760  {"exp", (PyCFunction)__pyx_pw_8PyClical_47exp, METH_O, __pyx_doc_8PyClical_46exp},
18761  {"log", (PyCFunction)__pyx_pw_8PyClical_49log, METH_VARARGS|METH_KEYWORDS, __pyx_doc_8PyClical_48log},
18762  {"cos", (PyCFunction)__pyx_pw_8PyClical_51cos, METH_VARARGS|METH_KEYWORDS, __pyx_doc_8PyClical_50cos},
18763  {"acos", (PyCFunction)__pyx_pw_8PyClical_53acos, METH_VARARGS|METH_KEYWORDS, __pyx_doc_8PyClical_52acos},
18764  {"cosh", (PyCFunction)__pyx_pw_8PyClical_55cosh, METH_O, __pyx_doc_8PyClical_54cosh},
18765  {"acosh", (PyCFunction)__pyx_pw_8PyClical_57acosh, METH_VARARGS|METH_KEYWORDS, __pyx_doc_8PyClical_56acosh},
18766  {"sin", (PyCFunction)__pyx_pw_8PyClical_59sin, METH_VARARGS|METH_KEYWORDS, __pyx_doc_8PyClical_58sin},
18767  {"asin", (PyCFunction)__pyx_pw_8PyClical_61asin, METH_VARARGS|METH_KEYWORDS, __pyx_doc_8PyClical_60asin},
18768  {"sinh", (PyCFunction)__pyx_pw_8PyClical_63sinh, METH_O, __pyx_doc_8PyClical_62sinh},
18769  {"asinh", (PyCFunction)__pyx_pw_8PyClical_65asinh, METH_VARARGS|METH_KEYWORDS, __pyx_doc_8PyClical_64asinh},
18770  {"tan", (PyCFunction)__pyx_pw_8PyClical_67tan, METH_VARARGS|METH_KEYWORDS, __pyx_doc_8PyClical_66tan},
18771  {"atan", (PyCFunction)__pyx_pw_8PyClical_69atan, METH_VARARGS|METH_KEYWORDS, __pyx_doc_8PyClical_68atan},
18772  {"tanh", (PyCFunction)__pyx_pw_8PyClical_71tanh, METH_O, __pyx_doc_8PyClical_70tanh},
18773  {"atanh", (PyCFunction)__pyx_pw_8PyClical_73atanh, METH_VARARGS|METH_KEYWORDS, __pyx_doc_8PyClical_72atanh},
18774  {"random_clifford", (PyCFunction)__pyx_pw_8PyClical_75random_clifford, METH_VARARGS|METH_KEYWORDS, __pyx_doc_8PyClical_74random_clifford},
18775  {"cga3", (PyCFunction)__pyx_pw_8PyClical_77cga3, METH_O, __pyx_doc_8PyClical_76cga3},
18776  {"cga3std", (PyCFunction)__pyx_pw_8PyClical_79cga3std, METH_O, __pyx_doc_8PyClical_78cga3std},
18777  {"agc3", (PyCFunction)__pyx_pw_8PyClical_81agc3, METH_O, __pyx_doc_8PyClical_80agc3},
18778  {0, 0, 0, 0}
18779  };
18780 
18781  #if PY_MAJOR_VERSION >= 3
18782  static struct PyModuleDef __pyx_moduledef = {
18783  #if PY_VERSION_HEX < 0x03020000
18784  { PyObject_HEAD_INIT(NULL) NULL, 0, NULL },
18785  #else
18786  PyModuleDef_HEAD_INIT,
18787  #endif
18788  "PyClical",
18789  0, /* m_doc */
18790  -1, /* m_size */
18791  __pyx_methods /* m_methods */,
18792  NULL, /* m_reload */
18793  NULL, /* m_traverse */
18794  NULL, /* m_clear */
18795  NULL /* m_free */
18796  };
18797  #endif
18798 
18799 static __Pyx_StringTabEntry __pyx_string_tab[] = {
18800  {&__pyx_kp_s_, __pyx_k_, sizeof(__pyx_k_), 0, 0, 1, 0},
18801  {&__pyx_kp_s_0_8_2, __pyx_k_0_8_2, sizeof(__pyx_k_0_8_2), 0, 0, 1, 0},
18802  {&__pyx_kp_u_Abbreviation_for_clifford_index, __pyx_k_Abbreviation_for_clifford_index, sizeof(__pyx_k_Abbreviation_for_clifford_index), 0, 1, 0, 0},
18803  {&__pyx_kp_u_Abbreviation_for_index_set_q_p, __pyx_k_Abbreviation_for_index_set_q_p, sizeof(__pyx_k_Abbreviation_for_index_set_q_p), 0, 1, 0, 0},
18804  {&__pyx_kp_u_Absolute_value_of_multivector_m, __pyx_k_Absolute_value_of_multivector_m, sizeof(__pyx_k_Absolute_value_of_multivector_m), 0, 1, 0, 0},
18805  {&__pyx_kp_u_Absolute_value_square_root_of_n, __pyx_k_Absolute_value_square_root_of_n, sizeof(__pyx_k_Absolute_value_square_root_of_n), 0, 1, 0, 0},
18806  {&__pyx_kp_s_Cannot_initialize_clifford_objec, __pyx_k_Cannot_initialize_clifford_objec, sizeof(__pyx_k_Cannot_initialize_clifford_objec), 0, 0, 1, 0},
18807  {&__pyx_kp_s_Cannot_initialize_index_set_obje, __pyx_k_Cannot_initialize_index_set_obje, sizeof(__pyx_k_Cannot_initialize_index_set_obje), 0, 0, 1, 0},
18808  {&__pyx_kp_s_Cannot_reframe, __pyx_k_Cannot_reframe, sizeof(__pyx_k_Cannot_reframe), 0, 0, 1, 0},
18809  {&__pyx_kp_s_Cannot_take_vector_part_of, __pyx_k_Cannot_take_vector_part_of, sizeof(__pyx_k_Cannot_take_vector_part_of), 0, 0, 1, 0},
18810  {&__pyx_kp_u_Cardinality_Number_of_indices_i, __pyx_k_Cardinality_Number_of_indices_i, sizeof(__pyx_k_Cardinality_Number_of_indices_i), 0, 1, 0, 0},
18811  {&__pyx_kp_u_Check_if_a_multivector_contains, __pyx_k_Check_if_a_multivector_contains, sizeof(__pyx_k_Check_if_a_multivector_contains), 0, 1, 0, 0},
18812  {&__pyx_kp_u_Conjugation_reverse_o_involute, __pyx_k_Conjugation_reverse_o_involute, sizeof(__pyx_k_Conjugation_reverse_o_involute), 0, 1, 0, 0},
18813  {&__pyx_kp_u_Conjugation_reverse_o_involute_2, __pyx_k_Conjugation_reverse_o_involute_2, sizeof(__pyx_k_Conjugation_reverse_o_involute_2), 0, 1, 0, 0},
18814  {&__pyx_kp_u_Contraction_print_clifford_1_cl, __pyx_k_Contraction_print_clifford_1_cl, sizeof(__pyx_k_Contraction_print_clifford_1_cl), 0, 1, 0, 0},
18815  {&__pyx_kp_u_Contraction_x_clifford_1_x_clif, __pyx_k_Contraction_x_clifford_1_x_clif, sizeof(__pyx_k_Contraction_x_clifford_1_x_clif), 0, 1, 0, 0},
18816  {&__pyx_kp_u_Convert_CGA3_null_vector_to_Euc, __pyx_k_Convert_CGA3_null_vector_to_Euc, sizeof(__pyx_k_Convert_CGA3_null_vector_to_Euc), 0, 1, 0, 0},
18817  {&__pyx_kp_u_Convert_CGA3_null_vector_to_sta, __pyx_k_Convert_CGA3_null_vector_to_sta, sizeof(__pyx_k_Convert_CGA3_null_vector_to_sta), 0, 1, 0, 0},
18818  {&__pyx_kp_u_Convert_Euclidean_3D_multivecto, __pyx_k_Convert_Euclidean_3D_multivecto, sizeof(__pyx_k_Convert_Euclidean_3D_multivecto), 0, 1, 0, 0},
18819  {&__pyx_kp_u_Copy_this_clifford_object_x_cli, __pyx_k_Copy_this_clifford_object_x_cli, sizeof(__pyx_k_Copy_this_clifford_object_x_cli), 0, 1, 0, 0},
18820  {&__pyx_kp_u_Copy_this_index_set_object_s_in, __pyx_k_Copy_this_index_set_object_s_in, sizeof(__pyx_k_Copy_this_index_set_object_s_in), 0, 1, 0, 0},
18821  {&__pyx_kp_u_Cosine_of_multivector_with_opti, __pyx_k_Cosine_of_multivector_with_opti, sizeof(__pyx_k_Cosine_of_multivector_with_opti), 0, 1, 0, 0},
18822  {&__pyx_kp_u_Even_part_of_multivector_sum_of, __pyx_k_Even_part_of_multivector_sum_of, sizeof(__pyx_k_Even_part_of_multivector_sum_of), 0, 1, 0, 0},
18823  {&__pyx_kp_u_Even_part_of_multivector_sum_of_2, __pyx_k_Even_part_of_multivector_sum_of_2, sizeof(__pyx_k_Even_part_of_multivector_sum_of_2), 0, 1, 0, 0},
18824  {&__pyx_kp_u_Exponential_of_multivector_x_cl, __pyx_k_Exponential_of_multivector_x_cl, sizeof(__pyx_k_Exponential_of_multivector_x_cl), 0, 1, 0, 0},
18825  {&__pyx_kp_u_Geometric_difference_print_clif, __pyx_k_Geometric_difference_print_clif, sizeof(__pyx_k_Geometric_difference_print_clif), 0, 1, 0, 0},
18826  {&__pyx_kp_u_Geometric_difference_x_clifford, __pyx_k_Geometric_difference_x_clifford, sizeof(__pyx_k_Geometric_difference_x_clifford), 0, 1, 0, 0},
18827  {&__pyx_kp_u_Geometric_multiplicative_invers, __pyx_k_Geometric_multiplicative_invers, sizeof(__pyx_k_Geometric_multiplicative_invers), 0, 1, 0, 0},
18828  {&__pyx_kp_u_Geometric_multiplicative_invers_2, __pyx_k_Geometric_multiplicative_invers_2, sizeof(__pyx_k_Geometric_multiplicative_invers_2), 0, 1, 0, 0},
18829  {&__pyx_kp_u_Geometric_product_print_cliffor, __pyx_k_Geometric_product_print_cliffor, sizeof(__pyx_k_Geometric_product_print_cliffor), 0, 1, 0, 0},
18830  {&__pyx_kp_u_Geometric_product_x_clifford_2, __pyx_k_Geometric_product_x_clifford_2, sizeof(__pyx_k_Geometric_product_x_clifford_2), 0, 1, 0, 0},
18831  {&__pyx_kp_u_Geometric_quotient_print_cliffo, __pyx_k_Geometric_quotient_print_cliffo, sizeof(__pyx_k_Geometric_quotient_print_cliffo), 0, 1, 0, 0},
18832  {&__pyx_kp_u_Geometric_quotient_x_clifford_1, __pyx_k_Geometric_quotient_x_clifford_1, sizeof(__pyx_k_Geometric_quotient_x_clifford_1), 0, 1, 0, 0},
18833  {&__pyx_kp_u_Geometric_sum_print_clifford_1, __pyx_k_Geometric_sum_print_clifford_1, sizeof(__pyx_k_Geometric_sum_print_clifford_1), 0, 1, 0, 0},
18834  {&__pyx_kp_u_Geometric_sum_x_clifford_1_x_cl, __pyx_k_Geometric_sum_x_clifford_1_x_cl, sizeof(__pyx_k_Geometric_sum_x_clifford_1_x_cl), 0, 1, 0, 0},
18835  {&__pyx_kp_u_Get_the_value_of_an_index_set_o, __pyx_k_Get_the_value_of_an_index_set_o, sizeof(__pyx_k_Get_the_value_of_an_index_set_o), 0, 1, 0, 0},
18836  {&__pyx_kp_u_Hyperbolic_cosine_of_multivecto, __pyx_k_Hyperbolic_cosine_of_multivecto, sizeof(__pyx_k_Hyperbolic_cosine_of_multivecto), 0, 1, 0, 0},
18837  {&__pyx_kp_u_Hyperbolic_sine_of_multivector, __pyx_k_Hyperbolic_sine_of_multivector, sizeof(__pyx_k_Hyperbolic_sine_of_multivector), 0, 1, 0, 0},
18838  {&__pyx_kp_u_Hyperbolic_tangent_of_multivect, __pyx_k_Hyperbolic_tangent_of_multivect, sizeof(__pyx_k_Hyperbolic_tangent_of_multivect), 0, 1, 0, 0},
18839  {&__pyx_kp_u_Imaginary_part_deprecated_alway, __pyx_k_Imaginary_part_deprecated_alway, sizeof(__pyx_k_Imaginary_part_deprecated_alway), 0, 1, 0, 0},
18840  {&__pyx_n_s_IndexError, __pyx_k_IndexError, sizeof(__pyx_k_IndexError), 0, 0, 1, 1},
18841  {&__pyx_kp_u_Inner_product_print_clifford_1, __pyx_k_Inner_product_print_clifford_1, sizeof(__pyx_k_Inner_product_print_clifford_1), 0, 1, 0, 0},
18842  {&__pyx_kp_u_Inner_product_x_clifford_1_x_cl, __pyx_k_Inner_product_x_clifford_1_x_cl, sizeof(__pyx_k_Inner_product_x_clifford_1_x_cl), 0, 1, 0, 0},
18843  {&__pyx_kp_u_Integer_power_of_multivector_ob, __pyx_k_Integer_power_of_multivector_ob, sizeof(__pyx_k_Integer_power_of_multivector_ob), 0, 1, 0, 0},
18844  {&__pyx_n_s_Integral, __pyx_k_Integral, sizeof(__pyx_k_Integral), 0, 0, 1, 1},
18845  {&__pyx_kp_u_Inverse_cosine_of_multivector_w, __pyx_k_Inverse_cosine_of_multivector_w, sizeof(__pyx_k_Inverse_cosine_of_multivector_w), 0, 1, 0, 0},
18846  {&__pyx_kp_u_Inverse_hyperbolic_cosine_of_mu, __pyx_k_Inverse_hyperbolic_cosine_of_mu, sizeof(__pyx_k_Inverse_hyperbolic_cosine_of_mu), 0, 1, 0, 0},
18847  {&__pyx_kp_u_Inverse_hyperbolic_sine_of_mult, __pyx_k_Inverse_hyperbolic_sine_of_mult, sizeof(__pyx_k_Inverse_hyperbolic_sine_of_mult), 0, 1, 0, 0},
18848  {&__pyx_kp_u_Inverse_hyperbolic_tangent_of_m, __pyx_k_Inverse_hyperbolic_tangent_of_m, sizeof(__pyx_k_Inverse_hyperbolic_tangent_of_m), 0, 1, 0, 0},
18849  {&__pyx_kp_u_Inverse_sine_of_multivector_wit, __pyx_k_Inverse_sine_of_multivector_wit, sizeof(__pyx_k_Inverse_sine_of_multivector_wit), 0, 1, 0, 0},
18850  {&__pyx_kp_u_Inverse_tangent_of_multivector, __pyx_k_Inverse_tangent_of_multivector, sizeof(__pyx_k_Inverse_tangent_of_multivector), 0, 1, 0, 0},
18851  {&__pyx_kp_u_Iterate_over_the_indices_of_an, __pyx_k_Iterate_over_the_indices_of_an, sizeof(__pyx_k_Iterate_over_the_indices_of_an), 0, 1, 0, 0},
18852  {&__pyx_kp_u_Main_involution_each_i_is_repla, __pyx_k_Main_involution_each_i_is_repla, sizeof(__pyx_k_Main_involution_each_i_is_repla), 0, 1, 0, 0},
18853  {&__pyx_kp_u_Main_involution_each_i_is_repla_2, __pyx_k_Main_involution_each_i_is_repla_2, sizeof(__pyx_k_Main_involution_each_i_is_repla_2), 0, 1, 0, 0},
18854  {&__pyx_kp_u_Maximum_absolute_value_of_coord, __pyx_k_Maximum_absolute_value_of_coord, sizeof(__pyx_k_Maximum_absolute_value_of_coord), 0, 1, 0, 0},
18855  {&__pyx_kp_u_Maximum_member_index_set_1_1_2, __pyx_k_Maximum_member_index_set_1_1_2, sizeof(__pyx_k_Maximum_member_index_set_1_1_2), 0, 1, 0, 0},
18856  {&__pyx_kp_u_Maximum_of_absolute_values_of_c, __pyx_k_Maximum_of_absolute_values_of_c, sizeof(__pyx_k_Maximum_of_absolute_values_of_c), 0, 1, 0, 0},
18857  {&__pyx_kp_u_Maximum_positive_index_or_0_if, __pyx_k_Maximum_positive_index_or_0_if, sizeof(__pyx_k_Maximum_positive_index_or_0_if), 0, 1, 0, 0},
18858  {&__pyx_kp_u_Minimum_member_index_set_1_1_2, __pyx_k_Minimum_member_index_set_1_1_2, sizeof(__pyx_k_Minimum_member_index_set_1_1_2), 0, 1, 0, 0},
18859  {&__pyx_kp_u_Minimum_negative_index_or_0_if, __pyx_k_Minimum_negative_index_or_0_if, sizeof(__pyx_k_Minimum_negative_index_or_0_if), 0, 1, 0, 0},
18860  {&__pyx_kp_u_Natural_logarithm_of_multivecto, __pyx_k_Natural_logarithm_of_multivecto, sizeof(__pyx_k_Natural_logarithm_of_multivecto), 0, 1, 0, 0},
18861  {&__pyx_kp_u_Norm_sum_of_squares_of_coordina, __pyx_k_Norm_sum_of_squares_of_coordina, sizeof(__pyx_k_Norm_sum_of_squares_of_coordina), 0, 1, 0, 0},
18862  {&__pyx_n_s_NotImplemented, __pyx_k_NotImplemented, sizeof(__pyx_k_NotImplemented), 0, 0, 1, 1},
18863  {&__pyx_kp_s_Not_applicable, __pyx_k_Not_applicable, sizeof(__pyx_k_Not_applicable), 0, 0, 1, 0},
18864  {&__pyx_kp_u_Not_applicable_for_a_in_cliffor, __pyx_k_Not_applicable_for_a_in_cliffor, sizeof(__pyx_k_Not_applicable_for_a_in_cliffor), 0, 1, 0, 0},
18865  {&__pyx_kp_u_Number_of_negative_indices_incl, __pyx_k_Number_of_negative_indices_incl, sizeof(__pyx_k_Number_of_negative_indices_incl), 0, 1, 0, 0},
18866  {&__pyx_kp_u_Number_of_positive_indices_incl, __pyx_k_Number_of_positive_indices_incl, sizeof(__pyx_k_Number_of_positive_indices_incl), 0, 1, 0, 0},
18867  {&__pyx_kp_u_Odd_part_of_multivector_sum_of, __pyx_k_Odd_part_of_multivector_sum_of, sizeof(__pyx_k_Odd_part_of_multivector_sum_of), 0, 1, 0, 0},
18868  {&__pyx_kp_u_Odd_part_of_multivector_sum_of_2, __pyx_k_Odd_part_of_multivector_sum_of_2, sizeof(__pyx_k_Odd_part_of_multivector_sum_of_2), 0, 1, 0, 0},
18869  {&__pyx_kp_u_Outer_product_power_of_multivec, __pyx_k_Outer_product_power_of_multivec, sizeof(__pyx_k_Outer_product_power_of_multivec), 0, 1, 0, 0},
18870  {&__pyx_kp_u_Outer_product_power_x_clifford, __pyx_k_Outer_product_power_x_clifford, sizeof(__pyx_k_Outer_product_power_x_clifford), 0, 1, 0, 0},
18871  {&__pyx_kp_u_Outer_product_print_clifford_1, __pyx_k_Outer_product_print_clifford_1, sizeof(__pyx_k_Outer_product_print_clifford_1), 0, 1, 0, 0},
18872  {&__pyx_kp_u_Outer_product_x_clifford_1_x_cl, __pyx_k_Outer_product_x_clifford_1_x_cl, sizeof(__pyx_k_Outer_product_x_clifford_1_x_cl), 0, 1, 0, 0},
18873  {&__pyx_kp_u_Power_self_to_the_m_x_clifford, __pyx_k_Power_self_to_the_m_x_clifford, sizeof(__pyx_k_Power_self_to_the_m_x_clifford), 0, 1, 0, 0},
18874  {&__pyx_kp_u_Power_self_to_the_m_x_clifford_2, __pyx_k_Power_self_to_the_m_x_clifford_2, sizeof(__pyx_k_Power_self_to_the_m_x_clifford_2), 0, 1, 0, 0},
18875  {&__pyx_kp_u_Pure_grade_vector_part_print_cl, __pyx_k_Pure_grade_vector_part_print_cl, sizeof(__pyx_k_Pure_grade_vector_part_print_cl), 0, 1, 0, 0},
18876  {&__pyx_kp_u_Pure_part_print_clifford_1_1_1, __pyx_k_Pure_part_print_clifford_1_1_1, sizeof(__pyx_k_Pure_part_print_clifford_1_1_1), 0, 1, 0, 0},
18877  {&__pyx_kp_u_Pure_part_print_pure_clifford_1, __pyx_k_Pure_part_print_pure_clifford_1, sizeof(__pyx_k_Pure_part_print_pure_clifford_1), 0, 1, 0, 0},
18878  {&__pyx_kp_u_Put_self_into_a_larger_frame_co, __pyx_k_Put_self_into_a_larger_frame_co, sizeof(__pyx_k_Put_self_into_a_larger_frame_co), 0, 1, 0, 0},
18879  {&__pyx_n_s_PyClical, __pyx_k_PyClical, sizeof(__pyx_k_PyClical), 0, 0, 1, 1},
18880  {&__pyx_kp_u_Quadratic_form_rev_x_x_0_print, __pyx_k_Quadratic_form_rev_x_x_0_print, sizeof(__pyx_k_Quadratic_form_rev_x_x_0_print), 0, 1, 0, 0},
18881  {&__pyx_kp_u_Quadratic_form_rev_x_x_0_print_2, __pyx_k_Quadratic_form_rev_x_x_0_print_2, sizeof(__pyx_k_Quadratic_form_rev_x_x_0_print_2), 0, 1, 0, 0},
18882  {&__pyx_kp_u_Random_multivector_within_a_fra, __pyx_k_Random_multivector_within_a_fra, sizeof(__pyx_k_Random_multivector_within_a_fra), 0, 1, 0, 0},
18883  {&__pyx_n_s_Real, __pyx_k_Real, sizeof(__pyx_k_Real), 0, 0, 1, 1},
18884  {&__pyx_kp_u_Real_part_synonym_for_scalar_pa, __pyx_k_Real_part_synonym_for_scalar_pa, sizeof(__pyx_k_Real_part_synonym_for_scalar_pa), 0, 1, 0, 0},
18885  {&__pyx_kp_u_Remove_all_terms_of_self_with_r, __pyx_k_Remove_all_terms_of_self_with_r, sizeof(__pyx_k_Remove_all_terms_of_self_with_r), 0, 1, 0, 0},
18886  {&__pyx_kp_u_Reversion_eg_1_2_2_1_print_reve, __pyx_k_Reversion_eg_1_2_2_1_print_reve, sizeof(__pyx_k_Reversion_eg_1_2_2_1_print_reve), 0, 1, 0, 0},
18887  {&__pyx_kp_u_Reversion_eg_clifford_1_cliffor, __pyx_k_Reversion_eg_clifford_1_cliffor, sizeof(__pyx_k_Reversion_eg_clifford_1_cliffor), 0, 1, 0, 0},
18888  {&__pyx_n_s_RuntimeError, __pyx_k_RuntimeError, sizeof(__pyx_k_RuntimeError), 0, 0, 1, 1},
18889  {&__pyx_kp_u_Scalar_part_clifford_1_1_1_2_sc, __pyx_k_Scalar_part_clifford_1_1_1_2_sc, sizeof(__pyx_k_Scalar_part_clifford_1_1_1_2_sc), 0, 1, 0, 0},
18890  {&__pyx_kp_u_Scalar_part_scalar_clifford_1_1, __pyx_k_Scalar_part_scalar_clifford_1_1, sizeof(__pyx_k_Scalar_part_scalar_clifford_1_1), 0, 1, 0, 0},
18891  {&__pyx_n_s_Sequence, __pyx_k_Sequence, sizeof(__pyx_k_Sequence), 0, 0, 1, 1},
18892  {&__pyx_kp_u_Set_complement_not_print_index, __pyx_k_Set_complement_not_print_index, sizeof(__pyx_k_Set_complement_not_print_index), 0, 1, 0, 0},
18893  {&__pyx_kp_u_Set_intersection_and_print_inde, __pyx_k_Set_intersection_and_print_inde, sizeof(__pyx_k_Set_intersection_and_print_inde), 0, 1, 0, 0},
18894  {&__pyx_kp_u_Set_intersection_and_x_index_se, __pyx_k_Set_intersection_and_x_index_se, sizeof(__pyx_k_Set_intersection_and_x_index_se), 0, 1, 0, 0},
18895  {&__pyx_kp_u_Set_the_value_of_an_index_set_o, __pyx_k_Set_the_value_of_an_index_set_o, sizeof(__pyx_k_Set_the_value_of_an_index_set_o), 0, 1, 0, 0},
18896  {&__pyx_kp_u_Set_union_or_print_index_set_1, __pyx_k_Set_union_or_print_index_set_1, sizeof(__pyx_k_Set_union_or_print_index_set_1), 0, 1, 0, 0},
18897  {&__pyx_kp_u_Set_union_or_x_index_set_1_x_in, __pyx_k_Set_union_or_x_index_set_1_x_in, sizeof(__pyx_k_Set_union_or_x_index_set_1_x_in), 0, 1, 0, 0},
18898  {&__pyx_kp_u_Sign_of_geometric_product_of_tw, __pyx_k_Sign_of_geometric_product_of_tw, sizeof(__pyx_k_Sign_of_geometric_product_of_tw), 0, 1, 0, 0},
18899  {&__pyx_kp_u_Sign_of_geometric_square_of_a_C, __pyx_k_Sign_of_geometric_square_of_a_C, sizeof(__pyx_k_Sign_of_geometric_square_of_a_C), 0, 1, 0, 0},
18900  {&__pyx_kp_u_Sine_of_multivector_with_option, __pyx_k_Sine_of_multivector_with_option, sizeof(__pyx_k_Sine_of_multivector_with_option), 0, 1, 0, 0},
18901  {&__pyx_kp_u_Square_root_of_1_which_commutes, __pyx_k_Square_root_of_1_which_commutes, sizeof(__pyx_k_Square_root_of_1_which_commutes), 0, 1, 0, 0},
18902  {&__pyx_kp_u_Square_root_of_multivector_with, __pyx_k_Square_root_of_multivector_with, sizeof(__pyx_k_Square_root_of_multivector_with), 0, 1, 0, 0},
18903  {&__pyx_kp_u_Subalgebra_generated_by_all_gen, __pyx_k_Subalgebra_generated_by_all_gen, sizeof(__pyx_k_Subalgebra_generated_by_all_gen), 0, 1, 0, 0},
18904  {&__pyx_kp_u_Subscripting_map_from_index_set, __pyx_k_Subscripting_map_from_index_set, sizeof(__pyx_k_Subscripting_map_from_index_set), 0, 1, 0, 0},
18905  {&__pyx_kp_u_Symmetric_set_difference_exclus, __pyx_k_Symmetric_set_difference_exclus, sizeof(__pyx_k_Symmetric_set_difference_exclus), 0, 1, 0, 0},
18906  {&__pyx_kp_u_Symmetric_set_difference_exclus_2, __pyx_k_Symmetric_set_difference_exclus_2, sizeof(__pyx_k_Symmetric_set_difference_exclus_2), 0, 1, 0, 0},
18907  {&__pyx_kp_u_Tangent_of_multivector_with_opt, __pyx_k_Tangent_of_multivector_with_opt, sizeof(__pyx_k_Tangent_of_multivector_with_opt), 0, 1, 0, 0},
18908  {&__pyx_kp_u_Tests_for_functions_that_Doctes, __pyx_k_Tests_for_functions_that_Doctes, sizeof(__pyx_k_Tests_for_functions_that_Doctes), 0, 1, 0, 0},
18909  {&__pyx_kp_u_Tests_for_functions_that_Doctes_2, __pyx_k_Tests_for_functions_that_Doctes_2, sizeof(__pyx_k_Tests_for_functions_that_Doctes_2), 0, 1, 0, 0},
18910  {&__pyx_kp_u_The_informal_string_representat, __pyx_k_The_informal_string_representat, sizeof(__pyx_k_The_informal_string_representat), 0, 1, 0, 0},
18911  {&__pyx_kp_u_The_informal_string_representat_2, __pyx_k_The_informal_string_representat_2, sizeof(__pyx_k_The_informal_string_representat_2), 0, 1, 0, 0},
18912  {&__pyx_kp_u_The_official_string_representat, __pyx_k_The_official_string_representat, sizeof(__pyx_k_The_official_string_representat), 0, 1, 0, 0},
18913  {&__pyx_kp_u_The_official_string_representat_2, __pyx_k_The_official_string_representat_2, sizeof(__pyx_k_The_official_string_representat_2), 0, 1, 0, 0},
18914  {&__pyx_kp_s_This_comparison_operator_is_not, __pyx_k_This_comparison_operator_is_not, sizeof(__pyx_k_This_comparison_operator_is_not), 0, 0, 1, 0},
18915  {&__pyx_kp_u_Transform_left_hand_side_using, __pyx_k_Transform_left_hand_side_using, sizeof(__pyx_k_Transform_left_hand_side_using), 0, 1, 0, 0},
18916  {&__pyx_kp_u_Transform_left_hand_side_using_2, __pyx_k_Transform_left_hand_side_using_2, sizeof(__pyx_k_Transform_left_hand_side_using_2), 0, 1, 0, 0},
18917  {&__pyx_n_s_TypeError, __pyx_k_TypeError, sizeof(__pyx_k_TypeError), 0, 0, 1, 1},
18918  {&__pyx_kp_u_Unary_print_clifford_1_1, __pyx_k_Unary_print_clifford_1_1, sizeof(__pyx_k_Unary_print_clifford_1_1), 0, 1, 0, 0},
18919  {&__pyx_kp_u_Unary_print_clifford_1_1_2, __pyx_k_Unary_print_clifford_1_1_2, sizeof(__pyx_k_Unary_print_clifford_1_1_2), 0, 1, 0, 0},
18920  {&__pyx_n_s_ValueError, __pyx_k_ValueError, sizeof(__pyx_k_ValueError), 0, 0, 1, 1},
18921  {&__pyx_kp_u_Vector_part_of_multivector_as_a, __pyx_k_Vector_part_of_multivector_as_a, sizeof(__pyx_k_Vector_part_of_multivector_as_a), 0, 1, 0, 0},
18922  {&__pyx_kp_s__2, __pyx_k__2, sizeof(__pyx_k__2), 0, 0, 1, 0},
18923  {&__pyx_kp_s__3, __pyx_k__3, sizeof(__pyx_k__3), 0, 0, 1, 0},
18924  {&__pyx_kp_s__4, __pyx_k__4, sizeof(__pyx_k__4), 0, 0, 1, 0},
18925  {&__pyx_kp_s__5, __pyx_k__5, sizeof(__pyx_k__5), 0, 0, 1, 0},
18926  {&__pyx_kp_s__6, __pyx_k__6, sizeof(__pyx_k__6), 0, 0, 1, 0},
18927  {&__pyx_kp_s__7, __pyx_k__7, sizeof(__pyx_k__7), 0, 0, 1, 0},
18928  {&__pyx_kp_u_abs_line_1473, __pyx_k_abs_line_1473, sizeof(__pyx_k_abs_line_1473), 0, 1, 0, 0},
18929  {&__pyx_n_s_acos, __pyx_k_acos, sizeof(__pyx_k_acos), 0, 0, 1, 1},
18930  {&__pyx_kp_u_acos_line_1619, __pyx_k_acos_line_1619, sizeof(__pyx_k_acos_line_1619), 0, 1, 0, 0},
18931  {&__pyx_n_s_acosh, __pyx_k_acosh, sizeof(__pyx_k_acosh), 0, 0, 1, 1},
18932  {&__pyx_kp_u_acosh_line_1656, __pyx_k_acosh_line_1656, sizeof(__pyx_k_acosh_line_1656), 0, 1, 0, 0},
18933  {&__pyx_kp_u_agc3_line_1844, __pyx_k_agc3_line_1844, sizeof(__pyx_k_agc3_line_1844), 0, 1, 0, 0},
18934  {&__pyx_n_s_args, __pyx_k_args, sizeof(__pyx_k_args), 0, 0, 1, 1},
18935  {&__pyx_kp_s_as_frame, __pyx_k_as_frame, sizeof(__pyx_k_as_frame), 0, 0, 1, 0},
18936  {&__pyx_n_s_asin, __pyx_k_asin, sizeof(__pyx_k_asin), 0, 0, 1, 1},
18937  {&__pyx_kp_u_asin_line_1698, __pyx_k_asin_line_1698, sizeof(__pyx_k_asin_line_1698), 0, 1, 0, 0},
18938  {&__pyx_n_s_asinh, __pyx_k_asinh, sizeof(__pyx_k_asinh), 0, 0, 1, 1},
18939  {&__pyx_kp_u_asinh_line_1733, __pyx_k_asinh_line_1733, sizeof(__pyx_k_asinh_line_1733), 0, 1, 0, 0},
18940  {&__pyx_n_s_atan, __pyx_k_atan, sizeof(__pyx_k_atan), 0, 0, 1, 1},
18941  {&__pyx_kp_u_atan_line_1769, __pyx_k_atan_line_1769, sizeof(__pyx_k_atan_line_1769), 0, 1, 0, 0},
18942  {&__pyx_n_s_atanh, __pyx_k_atanh, sizeof(__pyx_k_atanh), 0, 0, 1, 1},
18943  {&__pyx_kp_u_atanh_line_1798, __pyx_k_atanh_line_1798, sizeof(__pyx_k_atanh_line_1798), 0, 1, 0, 0},
18944  {&__pyx_kp_u_cga3_line_1824, __pyx_k_cga3_line_1824, sizeof(__pyx_k_cga3_line_1824), 0, 1, 0, 0},
18945  {&__pyx_kp_u_cga3std_line_1833, __pyx_k_cga3std_line_1833, sizeof(__pyx_k_cga3std_line_1833), 0, 1, 0, 0},
18946  {&__pyx_n_s_cl, __pyx_k_cl, sizeof(__pyx_k_cl), 0, 0, 1, 1},
18947  {&__pyx_kp_u_clifford___add___line_739, __pyx_k_clifford___add___line_739, sizeof(__pyx_k_clifford___add___line_739), 0, 1, 0, 0},
18948  {&__pyx_kp_u_clifford___and___line_835, __pyx_k_clifford___and___line_835, sizeof(__pyx_k_clifford___and___line_835), 0, 1, 0, 0},
18949  {&__pyx_kp_u_clifford___call___line_1019, __pyx_k_clifford___call___line_1019, sizeof(__pyx_k_clifford___call___line_1019), 0, 1, 0, 0},
18950  {&__pyx_kp_u_clifford___div___line_895, __pyx_k_clifford___div___line_895, sizeof(__pyx_k_clifford___div___line_895), 0, 1, 0, 0},
18951  {&__pyx_kp_u_clifford___getitem___line_706, __pyx_k_clifford___getitem___line_706, sizeof(__pyx_k_clifford___getitem___line_706), 0, 1, 0, 0},
18952  {&__pyx_kp_u_clifford___iadd___line_750, __pyx_k_clifford___iadd___line_750, sizeof(__pyx_k_clifford___iadd___line_750), 0, 1, 0, 0},
18953  {&__pyx_kp_u_clifford___iand___line_850, __pyx_k_clifford___iand___line_850, sizeof(__pyx_k_clifford___iand___line_850), 0, 1, 0, 0},
18954  {&__pyx_kp_u_clifford___idiv___line_910, __pyx_k_clifford___idiv___line_910, sizeof(__pyx_k_clifford___idiv___line_910), 0, 1, 0, 0},
18955  {&__pyx_kp_u_clifford___imod___line_820, __pyx_k_clifford___imod___line_820, sizeof(__pyx_k_clifford___imod___line_820), 0, 1, 0, 0},
18956  {&__pyx_kp_u_clifford___imul___line_792, __pyx_k_clifford___imul___line_792, sizeof(__pyx_k_clifford___imul___line_792), 0, 1, 0, 0},
18957  {&__pyx_kp_u_clifford___ior___line_949, __pyx_k_clifford___ior___line_949, sizeof(__pyx_k_clifford___ior___line_949), 0, 1, 0, 0},
18958  {&__pyx_kp_u_clifford___isub___line_770, __pyx_k_clifford___isub___line_770, sizeof(__pyx_k_clifford___isub___line_770), 0, 1, 0, 0},
18959  {&__pyx_kp_u_clifford___iter___line_637, __pyx_k_clifford___iter___line_637, sizeof(__pyx_k_clifford___iter___line_637), 0, 1, 0, 0},
18960  {&__pyx_kp_u_clifford___ixor___line_880, __pyx_k_clifford___ixor___line_880, sizeof(__pyx_k_clifford___ixor___line_880), 0, 1, 0, 0},
18961  {&__pyx_kp_u_clifford___mod___line_805, __pyx_k_clifford___mod___line_805, sizeof(__pyx_k_clifford___mod___line_805), 0, 1, 0, 0},
18962  {&__pyx_kp_u_clifford___mul___line_779, __pyx_k_clifford___mul___line_779, sizeof(__pyx_k_clifford___mul___line_779), 0, 1, 0, 0},
18963  {&__pyx_kp_u_clifford___neg___line_721, __pyx_k_clifford___neg___line_721, sizeof(__pyx_k_clifford___neg___line_721), 0, 1, 0, 0},
18964  {&__pyx_kp_u_clifford___or___line_938, __pyx_k_clifford___or___line_938, sizeof(__pyx_k_clifford___or___line_938), 0, 1, 0, 0},
18965  {&__pyx_kp_u_clifford___pos___line_730, __pyx_k_clifford___pos___line_730, sizeof(__pyx_k_clifford___pos___line_730), 0, 1, 0, 0},
18966  {&__pyx_kp_u_clifford___pow___line_960, __pyx_k_clifford___pow___line_960, sizeof(__pyx_k_clifford___pow___line_960), 0, 1, 0, 0},
18967  {&__pyx_kp_u_clifford___repr___line_1225, __pyx_k_clifford___repr___line_1225, sizeof(__pyx_k_clifford___repr___line_1225), 0, 1, 0, 0},
18968  {&__pyx_kp_u_clifford___str___line_1234, __pyx_k_clifford___str___line_1234, sizeof(__pyx_k_clifford___str___line_1234), 0, 1, 0, 0},
18969  {&__pyx_kp_u_clifford___sub___line_759, __pyx_k_clifford___sub___line_759, sizeof(__pyx_k_clifford___sub___line_759), 0, 1, 0, 0},
18970  {&__pyx_kp_u_clifford___xor___line_865, __pyx_k_clifford___xor___line_865, sizeof(__pyx_k_clifford___xor___line_865), 0, 1, 0, 0},
18971  {&__pyx_kp_u_clifford_abs_line_1174, __pyx_k_clifford_abs_line_1174, sizeof(__pyx_k_clifford_abs_line_1174), 0, 1, 0, 0},
18972  {&__pyx_kp_u_clifford_conj_line_1137, __pyx_k_clifford_conj_line_1137, sizeof(__pyx_k_clifford_conj_line_1137), 0, 1, 0, 0},
18973  {&__pyx_kp_u_clifford_copy_line_554, __pyx_k_clifford_copy_line_554, sizeof(__pyx_k_clifford_copy_line_554), 0, 1, 0, 0},
18974  {&__pyx_kp_u_clifford_even_line_1060, __pyx_k_clifford_even_line_1060, sizeof(__pyx_k_clifford_even_line_1060), 0, 1, 0, 0},
18975  {&__pyx_kp_u_clifford_frame_line_1214, __pyx_k_clifford_frame_line_1214, sizeof(__pyx_k_clifford_frame_line_1214), 0, 1, 0, 0},
18976  {&__pyx_n_s_clifford_hidden_doctests, __pyx_k_clifford_hidden_doctests, sizeof(__pyx_k_clifford_hidden_doctests), 0, 0, 1, 1},
18977  {&__pyx_kp_u_clifford_hidden_doctests_line_12, __pyx_k_clifford_hidden_doctests_line_12, sizeof(__pyx_k_clifford_hidden_doctests_line_12), 0, 1, 0, 0},
18978  {&__pyx_kp_u_clifford_inv_line_925, __pyx_k_clifford_inv_line_925, sizeof(__pyx_k_clifford_inv_line_925), 0, 1, 0, 0},
18979  {&__pyx_kp_u_clifford_involute_line_1106, __pyx_k_clifford_involute_line_1106, sizeof(__pyx_k_clifford_involute_line_1106), 0, 1, 0, 0},
18980  {&__pyx_kp_u_clifford_isnan_line_1205, __pyx_k_clifford_isnan_line_1205, sizeof(__pyx_k_clifford_isnan_line_1205), 0, 1, 0, 0},
18981  {&__pyx_kp_u_clifford_max_abs_line_1183, __pyx_k_clifford_max_abs_line_1183, sizeof(__pyx_k_clifford_max_abs_line_1183), 0, 1, 0, 0},
18982  {&__pyx_kp_u_clifford_norm_line_1163, __pyx_k_clifford_norm_line_1163, sizeof(__pyx_k_clifford_norm_line_1163), 0, 1, 0, 0},
18983  {&__pyx_kp_u_clifford_odd_line_1069, __pyx_k_clifford_odd_line_1069, sizeof(__pyx_k_clifford_odd_line_1069), 0, 1, 0, 0},
18984  {&__pyx_kp_u_clifford_outer_pow_line_1003, __pyx_k_clifford_outer_pow_line_1003, sizeof(__pyx_k_clifford_outer_pow_line_1003), 0, 1, 0, 0},
18985  {&__pyx_kp_u_clifford_pow_line_979, __pyx_k_clifford_pow_line_979, sizeof(__pyx_k_clifford_pow_line_979), 0, 1, 0, 0},
18986  {&__pyx_kp_u_clifford_pure_line_1049, __pyx_k_clifford_pure_line_1049, sizeof(__pyx_k_clifford_pure_line_1049), 0, 1, 0, 0},
18987  {&__pyx_kp_u_clifford_quad_line_1152, __pyx_k_clifford_quad_line_1152, sizeof(__pyx_k_clifford_quad_line_1152), 0, 1, 0, 0},
18988  {&__pyx_kp_u_clifford_reframe_line_648, __pyx_k_clifford_reframe_line_648, sizeof(__pyx_k_clifford_reframe_line_648), 0, 1, 0, 0},
18989  {&__pyx_kp_u_clifford_reverse_line_1122, __pyx_k_clifford_reverse_line_1122, sizeof(__pyx_k_clifford_reverse_line_1122), 0, 1, 0, 0},
18990  {&__pyx_kp_u_clifford_scalar_line_1038, __pyx_k_clifford_scalar_line_1038, sizeof(__pyx_k_clifford_scalar_line_1038), 0, 1, 0, 0},
18991  {&__pyx_kp_u_clifford_truncated_line_1194, __pyx_k_clifford_truncated_line_1194, sizeof(__pyx_k_clifford_truncated_line_1194), 0, 1, 0, 0},
18992  {&__pyx_kp_u_clifford_vector_part_line_1078, __pyx_k_clifford_vector_part_line_1078, sizeof(__pyx_k_clifford_vector_part_line_1078), 0, 1, 0, 0},
18993  {&__pyx_n_s_close, __pyx_k_close, sizeof(__pyx_k_close), 0, 0, 1, 1},
18994  {&__pyx_n_s_collections, __pyx_k_collections, sizeof(__pyx_k_collections), 0, 0, 1, 1},
18995  {&__pyx_kp_u_compare_line_490, __pyx_k_compare_line_490, sizeof(__pyx_k_compare_line_490), 0, 1, 0, 0},
18996  {&__pyx_kp_u_complexifier_line_1527, __pyx_k_complexifier_line_1527, sizeof(__pyx_k_complexifier_line_1527), 0, 1, 0, 0},
18997  {&__pyx_n_s_conj, __pyx_k_conj, sizeof(__pyx_k_conj), 0, 0, 1, 1},
18998  {&__pyx_kp_u_conj_line_1436, __pyx_k_conj_line_1436, sizeof(__pyx_k_conj_line_1436), 0, 1, 0, 0},
18999  {&__pyx_n_s_copy, __pyx_k_copy, sizeof(__pyx_k_copy), 0, 0, 1, 1},
19000  {&__pyx_n_s_cos, __pyx_k_cos, sizeof(__pyx_k_cos), 0, 0, 1, 1},
19001  {&__pyx_kp_u_cos_line_1602, __pyx_k_cos_line_1602, sizeof(__pyx_k_cos_line_1602), 0, 1, 0, 0},
19002  {&__pyx_n_s_cosh, __pyx_k_cosh, sizeof(__pyx_k_cosh), 0, 0, 1, 1},
19003  {&__pyx_kp_u_cosh_line_1640, __pyx_k_cosh_line_1640, sizeof(__pyx_k_cosh_line_1640), 0, 1, 0, 0},
19004  {&__pyx_n_s_doctest, __pyx_k_doctest, sizeof(__pyx_k_doctest), 0, 0, 1, 1},
19005  {&__pyx_n_s_e, __pyx_k_e, sizeof(__pyx_k_e), 0, 0, 1, 1},
19006  {&__pyx_kp_u_e_line_1887, __pyx_k_e_line_1887, sizeof(__pyx_k_e_line_1887), 0, 1, 0, 0},
19007  {&__pyx_n_s_even, __pyx_k_even, sizeof(__pyx_k_even), 0, 0, 1, 1},
19008  {&__pyx_kp_u_even_line_1388, __pyx_k_even_line_1388, sizeof(__pyx_k_even_line_1388), 0, 1, 0, 0},
19009  {&__pyx_n_s_exp, __pyx_k_exp, sizeof(__pyx_k_exp), 0, 0, 1, 1},
19010  {&__pyx_kp_u_exp_line_1565, __pyx_k_exp_line_1565, sizeof(__pyx_k_exp_line_1565), 0, 1, 0, 0},
19011  {&__pyx_n_s_fill, __pyx_k_fill, sizeof(__pyx_k_fill), 0, 0, 1, 1},
19012  {&__pyx_n_s_frm, __pyx_k_frm, sizeof(__pyx_k_frm), 0, 0, 1, 1},
19013  {&__pyx_kp_s_from, __pyx_k_from, sizeof(__pyx_k_from), 0, 0, 1, 0},
19014  {&__pyx_n_s_grade, __pyx_k_grade, sizeof(__pyx_k_grade), 0, 0, 1, 1},
19015  {&__pyx_kp_s_home_leopardi_sync_src_glucat_g, __pyx_k_home_leopardi_sync_src_glucat_g, sizeof(__pyx_k_home_leopardi_sync_src_glucat_g), 0, 0, 1, 0},
19016  {&__pyx_n_s_i, __pyx_k_i, sizeof(__pyx_k_i), 0, 0, 1, 1},
19017  {&__pyx_kp_u_imag_line_1366, __pyx_k_imag_line_1366, sizeof(__pyx_k_imag_line_1366), 0, 1, 0, 0},
19018  {&__pyx_n_s_import, __pyx_k_import, sizeof(__pyx_k_import), 0, 0, 1, 1},
19019  {&__pyx_kp_u_index_set___and___line_269, __pyx_k_index_set___and___line_269, sizeof(__pyx_k_index_set___and___line_269), 0, 1, 0, 0},
19020  {&__pyx_kp_u_index_set___getitem___line_189, __pyx_k_index_set___getitem___line_189, sizeof(__pyx_k_index_set___getitem___line_189), 0, 1, 0, 0},
19021  {&__pyx_kp_u_index_set___iand___line_280, __pyx_k_index_set___iand___line_280, sizeof(__pyx_k_index_set___iand___line_280), 0, 1, 0, 0},
19022  {&__pyx_kp_u_index_set___invert___line_238, __pyx_k_index_set___invert___line_238, sizeof(__pyx_k_index_set___invert___line_238), 0, 1, 0, 0},
19023  {&__pyx_kp_u_index_set___ior___line_302, __pyx_k_index_set___ior___line_302, sizeof(__pyx_k_index_set___ior___line_302), 0, 1, 0, 0},
19024  {&__pyx_n_s_index_set___iter, __pyx_k_index_set___iter, sizeof(__pyx_k_index_set___iter), 0, 0, 1, 1},
19025  {&__pyx_kp_u_index_set___iter___line_227, __pyx_k_index_set___iter___line_227, sizeof(__pyx_k_index_set___iter___line_227), 0, 1, 0, 0},
19026  {&__pyx_kp_u_index_set___ixor___line_258, __pyx_k_index_set___ixor___line_258, sizeof(__pyx_k_index_set___ixor___line_258), 0, 1, 0, 0},
19027  {&__pyx_kp_u_index_set___or___line_291, __pyx_k_index_set___or___line_291, sizeof(__pyx_k_index_set___or___line_291), 0, 1, 0, 0},
19028  {&__pyx_kp_u_index_set___repr___line_382, __pyx_k_index_set___repr___line_382, sizeof(__pyx_k_index_set___repr___line_382), 0, 1, 0, 0},
19029  {&__pyx_kp_u_index_set___setitem___line_177, __pyx_k_index_set___setitem___line_177, sizeof(__pyx_k_index_set___setitem___line_177), 0, 1, 0, 0},
19030  {&__pyx_kp_u_index_set___str___line_393, __pyx_k_index_set___str___line_393, sizeof(__pyx_k_index_set___str___line_393), 0, 1, 0, 0},
19031  {&__pyx_kp_u_index_set___xor___line_247, __pyx_k_index_set___xor___line_247, sizeof(__pyx_k_index_set___xor___line_247), 0, 1, 0, 0},
19032  {&__pyx_kp_u_index_set_copy_line_64, __pyx_k_index_set_copy_line_64, sizeof(__pyx_k_index_set_copy_line_64), 0, 1, 0, 0},
19033  {&__pyx_kp_u_index_set_count_line_313, __pyx_k_index_set_count_line_313, sizeof(__pyx_k_index_set_count_line_313), 0, 1, 0, 0},
19034  {&__pyx_kp_u_index_set_count_neg_line_322, __pyx_k_index_set_count_neg_line_322, sizeof(__pyx_k_index_set_count_neg_line_322), 0, 1, 0, 0},
19035  {&__pyx_kp_u_index_set_count_pos_line_331, __pyx_k_index_set_count_pos_line_331, sizeof(__pyx_k_index_set_count_pos_line_331), 0, 1, 0, 0},
19036  {&__pyx_n_s_index_set_hidden_doctests, __pyx_k_index_set_hidden_doctests, sizeof(__pyx_k_index_set_hidden_doctests), 0, 0, 1, 1},
19037  {&__pyx_kp_u_index_set_hidden_doctests_line_4, __pyx_k_index_set_hidden_doctests_line_4, sizeof(__pyx_k_index_set_hidden_doctests_line_4), 0, 1, 0, 0},
19038  {&__pyx_kp_u_index_set_max_line_349, __pyx_k_index_set_max_line_349, sizeof(__pyx_k_index_set_max_line_349), 0, 1, 0, 0},
19039  {&__pyx_kp_u_index_set_min_line_340, __pyx_k_index_set_min_line_340, sizeof(__pyx_k_index_set_min_line_340), 0, 1, 0, 0},
19040  {&__pyx_kp_u_index_set_sign_of_mult_line_364, __pyx_k_index_set_sign_of_mult_line_364, sizeof(__pyx_k_index_set_sign_of_mult_line_364), 0, 1, 0, 0},
19041  {&__pyx_kp_u_index_set_sign_of_square_line_37, __pyx_k_index_set_sign_of_square_line_37, sizeof(__pyx_k_index_set_sign_of_square_line_37), 0, 1, 0, 0},
19042  {&__pyx_n_s_inv, __pyx_k_inv, sizeof(__pyx_k_inv), 0, 0, 1, 1},
19043  {&__pyx_kp_u_inv_line_1329, __pyx_k_inv_line_1329, sizeof(__pyx_k_inv_line_1329), 0, 1, 0, 0},
19044  {&__pyx_kp_s_invalid, __pyx_k_invalid, sizeof(__pyx_k_invalid), 0, 0, 1, 0},
19045  {&__pyx_kp_s_invalid_string, __pyx_k_invalid_string, sizeof(__pyx_k_invalid_string), 0, 0, 1, 0},
19046  {&__pyx_n_s_involute, __pyx_k_involute, sizeof(__pyx_k_involute), 0, 0, 1, 1},
19047  {&__pyx_kp_u_involute_line_1406, __pyx_k_involute_line_1406, sizeof(__pyx_k_involute_line_1406), 0, 1, 0, 0},
19048  {&__pyx_n_s_ist, __pyx_k_ist, sizeof(__pyx_k_ist), 0, 0, 1, 1},
19049  {&__pyx_n_s_istpq, __pyx_k_istpq, sizeof(__pyx_k_istpq), 0, 0, 1, 1},
19050  {&__pyx_kp_u_istpq_line_1900, __pyx_k_istpq_line_1900, sizeof(__pyx_k_istpq_line_1900), 0, 1, 0, 0},
19051  {&__pyx_n_s_iter, __pyx_k_iter, sizeof(__pyx_k_iter), 0, 0, 1, 1},
19052  {&__pyx_n_s_ixt, __pyx_k_ixt, sizeof(__pyx_k_ixt), 0, 0, 1, 1},
19053  {&__pyx_kp_u_lexicographic_compare_eg_3_4_5, __pyx_k_lexicographic_compare_eg_3_4_5, sizeof(__pyx_k_lexicographic_compare_eg_3_4_5), 0, 1, 0, 0},
19054  {&__pyx_n_s_lhs, __pyx_k_lhs, sizeof(__pyx_k_lhs), 0, 0, 1, 1},
19055  {&__pyx_n_s_log, __pyx_k_log, sizeof(__pyx_k_log), 0, 0, 1, 1},
19056  {&__pyx_kp_u_log_line_1579, __pyx_k_log_line_1579, sizeof(__pyx_k_log_line_1579), 0, 1, 0, 0},
19057  {&__pyx_n_s_m, __pyx_k_m, sizeof(__pyx_k_m), 0, 0, 1, 1},
19058  {&__pyx_n_s_main, __pyx_k_main, sizeof(__pyx_k_main), 0, 0, 1, 1},
19059  {&__pyx_n_s_math, __pyx_k_math, sizeof(__pyx_k_math), 0, 0, 1, 1},
19060  {&__pyx_n_s_max, __pyx_k_max, sizeof(__pyx_k_max), 0, 0, 1, 1},
19061  {&__pyx_kp_u_max_abs_line_1482, __pyx_k_max_abs_line_1482, sizeof(__pyx_k_max_abs_line_1482), 0, 1, 0, 0},
19062  {&__pyx_kp_u_max_pos_line_511, __pyx_k_max_pos_line_511, sizeof(__pyx_k_max_pos_line_511), 0, 1, 0, 0},
19063  {&__pyx_n_s_min, __pyx_k_min, sizeof(__pyx_k_min), 0, 0, 1, 1},
19064  {&__pyx_kp_u_min_neg_line_502, __pyx_k_min_neg_line_502, sizeof(__pyx_k_min_neg_line_502), 0, 1, 0, 0},
19065  {&__pyx_n_s_name, __pyx_k_name, sizeof(__pyx_k_name), 0, 0, 1, 1},
19066  {&__pyx_n_s_nbar3, __pyx_k_nbar3, sizeof(__pyx_k_nbar3), 0, 0, 1, 1},
19067  {&__pyx_n_s_ninf3, __pyx_k_ninf3, sizeof(__pyx_k_ninf3), 0, 0, 1, 1},
19068  {&__pyx_n_s_norm, __pyx_k_norm, sizeof(__pyx_k_norm), 0, 0, 1, 1},
19069  {&__pyx_kp_u_norm_line_1462, __pyx_k_norm_line_1462, sizeof(__pyx_k_norm_line_1462), 0, 1, 0, 0},
19070  {&__pyx_kp_u_norm_sum_of_squares_of_coordina, __pyx_k_norm_sum_of_squares_of_coordina, sizeof(__pyx_k_norm_sum_of_squares_of_coordina), 0, 1, 0, 0},
19071  {&__pyx_n_s_numbers, __pyx_k_numbers, sizeof(__pyx_k_numbers), 0, 0, 1, 1},
19072  {&__pyx_n_s_obj, __pyx_k_obj, sizeof(__pyx_k_obj), 0, 0, 1, 1},
19073  {&__pyx_n_s_odd, __pyx_k_odd, sizeof(__pyx_k_odd), 0, 0, 1, 1},
19074  {&__pyx_kp_u_odd_line_1397, __pyx_k_odd_line_1397, sizeof(__pyx_k_odd_line_1397), 0, 1, 0, 0},
19075  {&__pyx_n_s_other, __pyx_k_other, sizeof(__pyx_k_other), 0, 0, 1, 1},
19076  {&__pyx_n_s_outer_pow, __pyx_k_outer_pow, sizeof(__pyx_k_outer_pow), 0, 0, 1, 1},
19077  {&__pyx_kp_u_outer_pow_line_1518, __pyx_k_outer_pow_line_1518, sizeof(__pyx_k_outer_pow_line_1518), 0, 1, 0, 0},
19078  {&__pyx_n_s_p, __pyx_k_p, sizeof(__pyx_k_p), 0, 0, 1, 1},
19079  {&__pyx_n_s_pi, __pyx_k_pi, sizeof(__pyx_k_pi), 0, 0, 1, 1},
19080  {&__pyx_n_s_pow, __pyx_k_pow, sizeof(__pyx_k_pow), 0, 0, 1, 1},
19081  {&__pyx_kp_u_pow_line_1494, __pyx_k_pow_line_1494, sizeof(__pyx_k_pow_line_1494), 0, 1, 0, 0},
19082  {&__pyx_n_s_pure, __pyx_k_pure, sizeof(__pyx_k_pure), 0, 0, 1, 1},
19083  {&__pyx_kp_u_pure_line_1377, __pyx_k_pure_line_1377, sizeof(__pyx_k_pure_line_1377), 0, 1, 0, 0},
19084  {&__pyx_n_s_pyx_vtable, __pyx_k_pyx_vtable, sizeof(__pyx_k_pyx_vtable), 0, 0, 1, 1},
19085  {&__pyx_n_s_q, __pyx_k_q, sizeof(__pyx_k_q), 0, 0, 1, 1},
19086  {&__pyx_n_s_quad, __pyx_k_quad, sizeof(__pyx_k_quad), 0, 0, 1, 1},
19087  {&__pyx_kp_u_quad_line_1451, __pyx_k_quad_line_1451, sizeof(__pyx_k_quad_line_1451), 0, 1, 0, 0},
19088  {&__pyx_kp_u_random_clifford_line_1815, __pyx_k_random_clifford_line_1815, sizeof(__pyx_k_random_clifford_line_1815), 0, 1, 0, 0},
19089  {&__pyx_n_s_range, __pyx_k_range, sizeof(__pyx_k_range), 0, 0, 1, 1},
19090  {&__pyx_kp_u_real_line_1355, __pyx_k_real_line_1355, sizeof(__pyx_k_real_line_1355), 0, 1, 0, 0},
19091  {&__pyx_n_s_reverse, __pyx_k_reverse, sizeof(__pyx_k_reverse), 0, 0, 1, 1},
19092  {&__pyx_kp_u_reverse_line_1421, __pyx_k_reverse_line_1421, sizeof(__pyx_k_reverse_line_1421), 0, 1, 0, 0},
19093  {&__pyx_n_s_rhs, __pyx_k_rhs, sizeof(__pyx_k_rhs), 0, 0, 1, 1},
19094  {&__pyx_n_s_scalar, __pyx_k_scalar, sizeof(__pyx_k_scalar), 0, 0, 1, 1},
19095  {&__pyx_kp_u_scalar_line_1344, __pyx_k_scalar_line_1344, sizeof(__pyx_k_scalar_line_1344), 0, 1, 0, 0},
19096  {&__pyx_n_s_send, __pyx_k_send, sizeof(__pyx_k_send), 0, 0, 1, 1},
19097  {&__pyx_n_s_sin, __pyx_k_sin, sizeof(__pyx_k_sin), 0, 0, 1, 1},
19098  {&__pyx_kp_u_sin_line_1679, __pyx_k_sin_line_1679, sizeof(__pyx_k_sin_line_1679), 0, 1, 0, 0},
19099  {&__pyx_n_s_sinh, __pyx_k_sinh, sizeof(__pyx_k_sinh), 0, 0, 1, 1},
19100  {&__pyx_kp_u_sinh_line_1719, __pyx_k_sinh_line_1719, sizeof(__pyx_k_sinh_line_1719), 0, 1, 0, 0},
19101  {&__pyx_n_s_sqrt, __pyx_k_sqrt, sizeof(__pyx_k_sqrt), 0, 0, 1, 1},
19102  {&__pyx_kp_u_sqrt_line_1542, __pyx_k_sqrt_line_1542, sizeof(__pyx_k_sqrt_line_1542), 0, 1, 0, 0},
19103  {&__pyx_n_s_tan, __pyx_k_tan, sizeof(__pyx_k_tan), 0, 0, 1, 1},
19104  {&__pyx_kp_u_tan_line_1752, __pyx_k_tan_line_1752, sizeof(__pyx_k_tan_line_1752), 0, 1, 0, 0},
19105  {&__pyx_n_s_tanh, __pyx_k_tanh, sizeof(__pyx_k_tanh), 0, 0, 1, 1},
19106  {&__pyx_kp_u_tanh_line_1786, __pyx_k_tanh_line_1786, sizeof(__pyx_k_tanh_line_1786), 0, 1, 0, 0},
19107  {&__pyx_n_s_tau, __pyx_k_tau, sizeof(__pyx_k_tau), 0, 0, 1, 1},
19108  {&__pyx_n_s_test, __pyx_k_test, sizeof(__pyx_k_test), 0, 0, 1, 1},
19109  {&__pyx_n_s_test_2, __pyx_k_test_2, sizeof(__pyx_k_test_2), 0, 0, 1, 1},
19110  {&__pyx_n_s_testmod, __pyx_k_testmod, sizeof(__pyx_k_testmod), 0, 0, 1, 1},
19111  {&__pyx_n_s_throw, __pyx_k_throw, sizeof(__pyx_k_throw), 0, 0, 1, 1},
19112  {&__pyx_kp_s_to_frame, __pyx_k_to_frame, sizeof(__pyx_k_to_frame), 0, 0, 1, 0},
19113  {&__pyx_kp_s_using, __pyx_k_using, sizeof(__pyx_k_using), 0, 0, 1, 0},
19114  {&__pyx_kp_s_using_invalid, __pyx_k_using_invalid, sizeof(__pyx_k_using_invalid), 0, 0, 1, 0},
19115  {&__pyx_kp_s_value, __pyx_k_value, sizeof(__pyx_k_value), 0, 0, 1, 0},
19116  {&__pyx_n_s_version, __pyx_k_version, sizeof(__pyx_k_version), 0, 0, 1, 1},
19117  {&__pyx_n_s_xrange, __pyx_k_xrange, sizeof(__pyx_k_xrange), 0, 0, 1, 1},
19118  {0, 0, 0, 0, 0, 0, 0}
19119 };
19120 static int __Pyx_InitCachedBuiltins(void) {
19121  __pyx_builtin_IndexError = __Pyx_GetBuiltinName(__pyx_n_s_IndexError); if (!__pyx_builtin_IndexError) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 102; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19122  __pyx_builtin_RuntimeError = __Pyx_GetBuiltinName(__pyx_n_s_RuntimeError); if (!__pyx_builtin_RuntimeError) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 104; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19123  __pyx_builtin_TypeError = __Pyx_GetBuiltinName(__pyx_n_s_TypeError); if (!__pyx_builtin_TypeError) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 104; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19124  __pyx_builtin_ValueError = __Pyx_GetBuiltinName(__pyx_n_s_ValueError); if (!__pyx_builtin_ValueError) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 105; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19125  __pyx_builtin_NotImplemented = __Pyx_GetBuiltinName(__pyx_n_s_NotImplemented); if (!__pyx_builtin_NotImplemented) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 157; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19126  __pyx_builtin_range = __Pyx_GetBuiltinName(__pyx_n_s_range); if (!__pyx_builtin_range) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 234; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19127  #if PY_MAJOR_VERSION >= 3
19128  __pyx_builtin_xrange = __Pyx_GetBuiltinName(__pyx_n_s_range); if (!__pyx_builtin_xrange) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1098; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19129  #else
19130  __pyx_builtin_xrange = __Pyx_GetBuiltinName(__pyx_n_s_xrange); if (!__pyx_builtin_xrange) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1098; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19131  #endif
19132  return 0;
19133  __pyx_L1_error:;
19134  return -1;
19135 }
19136 
19137 static int __Pyx_InitCachedConstants(void) {
19138  __Pyx_RefNannyDeclarations
19139  __Pyx_RefNannySetupContext("__Pyx_InitCachedConstants", 0);
19140 
19141  /* "PyClical.pyx":635
19142  * TypeError: Not applicable.
19143  * """
19144  * raise TypeError("Not applicable.") # <<<<<<<<<<<<<<
19145  *
19146  * def __iter__(self):
19147  */
19148  __pyx_tuple__8 = PyTuple_Pack(1, __pyx_kp_s_Not_applicable); if (unlikely(!__pyx_tuple__8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 635; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19149  __Pyx_GOTREF(__pyx_tuple__8);
19150  __Pyx_GIVEREF(__pyx_tuple__8);
19151 
19152  /* "PyClical.pyx":646
19153  * TypeError: Not applicable.
19154  * """
19155  * raise TypeError("Not applicable.") # <<<<<<<<<<<<<<
19156  *
19157  * def reframe(self, ixt):
19158  */
19159  __pyx_tuple__9 = PyTuple_Pack(1, __pyx_kp_s_Not_applicable); if (unlikely(!__pyx_tuple__9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 646; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19160  __Pyx_GOTREF(__pyx_tuple__9);
19161  __Pyx_GIVEREF(__pyx_tuple__9);
19162 
19163  /* "PyClical.pyx":404
19164  * return index_set_to_str( self.unwrap() ).c_str()
19165  *
19166  * def index_set_hidden_doctests(): # <<<<<<<<<<<<<<
19167  * """
19168  * Tests for functions that Doctest cannot see.
19169  */
19170  __pyx_codeobj__10 = (PyObject*)__Pyx_PyCode_New(0, 0, 0, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_leopardi_sync_src_glucat_g, __pyx_n_s_index_set_hidden_doctests, 404, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 404; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19171 
19172  /* "PyClical.pyx":1243
19173  * return clifford_to_str( self.unwrap() ).c_str()
19174  *
19175  * def clifford_hidden_doctests(): # <<<<<<<<<<<<<<
19176  * """
19177  * Tests for functions that Doctest cannot see.
19178  */
19179  __pyx_codeobj__11 = (PyObject*)__Pyx_PyCode_New(0, 0, 0, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_leopardi_sync_src_glucat_g, __pyx_n_s_clifford_hidden_doctests, 1243, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19180 
19181  /* "PyClical.pyx":1856
19182  *
19183  * # Some abbreviations.
19184  * tau = atan(clifford(1.0)) * 8.0 # <<<<<<<<<<<<<<
19185  * pi = tau / 2.0
19186  *
19187  */
19188  __pyx_tuple__12 = PyTuple_Pack(1, __pyx_float_1_0); if (unlikely(!__pyx_tuple__12)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1856; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19189  __Pyx_GOTREF(__pyx_tuple__12);
19190  __Pyx_GIVEREF(__pyx_tuple__12);
19191 
19192  /* "PyClical.pyx":1887
19193  * """
19194  *
19195  * def e(obj): # <<<<<<<<<<<<<<
19196  * """
19197  * Abbreviation for clifford(index_set(obj)).
19198  */
19199  __pyx_tuple__13 = PyTuple_Pack(1, __pyx_n_s_obj); if (unlikely(!__pyx_tuple__13)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1887; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19200  __Pyx_GOTREF(__pyx_tuple__13);
19201  __Pyx_GIVEREF(__pyx_tuple__13);
19202  __pyx_codeobj__14 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__13, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_leopardi_sync_src_glucat_g, __pyx_n_s_e, 1887, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__14)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1887; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19203 
19204  /* "PyClical.pyx":1900
19205  * return clifford(index_set(obj))
19206  *
19207  * def istpq(p, q): # <<<<<<<<<<<<<<
19208  * """
19209  * Abbreviation for index_set({-q,...p}).
19210  */
19211  __pyx_tuple__15 = PyTuple_Pack(2, __pyx_n_s_p, __pyx_n_s_q); if (unlikely(!__pyx_tuple__15)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1900; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19212  __Pyx_GOTREF(__pyx_tuple__15);
19213  __Pyx_GIVEREF(__pyx_tuple__15);
19214  __pyx_codeobj__16 = (PyObject*)__Pyx_PyCode_New(2, 0, 2, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__15, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_leopardi_sync_src_glucat_g, __pyx_n_s_istpq, 1900, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__16)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1900; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19215 
19216  /* "PyClical.pyx":1909
19217  * return index_set(set(range(-q,p+1)))
19218  *
19219  * ninf3 = e(4) + e(-1) # Null infinity point in 3D Conformal Geometric Algebra [DL]. # <<<<<<<<<<<<<<
19220  * nbar3 = e(4) - e(-1) # Null bar point in 3D Conformal Geometric Algebra [DL].
19221  *
19222  */
19223  __pyx_tuple__17 = PyTuple_Pack(1, __pyx_int_4); if (unlikely(!__pyx_tuple__17)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1909; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19224  __Pyx_GOTREF(__pyx_tuple__17);
19225  __Pyx_GIVEREF(__pyx_tuple__17);
19226  __pyx_tuple__18 = PyTuple_Pack(1, __pyx_int_neg_1); if (unlikely(!__pyx_tuple__18)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1909; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19227  __Pyx_GOTREF(__pyx_tuple__18);
19228  __Pyx_GIVEREF(__pyx_tuple__18);
19229 
19230  /* "PyClical.pyx":1910
19231  *
19232  * ninf3 = e(4) + e(-1) # Null infinity point in 3D Conformal Geometric Algebra [DL].
19233  * nbar3 = e(4) - e(-1) # Null bar point in 3D Conformal Geometric Algebra [DL]. # <<<<<<<<<<<<<<
19234  *
19235  * # Doctest interface.
19236  */
19237  __pyx_tuple__19 = PyTuple_Pack(1, __pyx_int_4); if (unlikely(!__pyx_tuple__19)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1910; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19238  __Pyx_GOTREF(__pyx_tuple__19);
19239  __Pyx_GIVEREF(__pyx_tuple__19);
19240  __pyx_tuple__20 = PyTuple_Pack(1, __pyx_int_neg_1); if (unlikely(!__pyx_tuple__20)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1910; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19241  __Pyx_GOTREF(__pyx_tuple__20);
19242  __Pyx_GIVEREF(__pyx_tuple__20);
19243 
19244  /* "PyClical.pyx":1913
19245  *
19246  * # Doctest interface.
19247  * def _test(): # <<<<<<<<<<<<<<
19248  * import PyClical, doctest
19249  * return doctest.testmod(PyClical)
19250  */
19251  __pyx_tuple__21 = PyTuple_Pack(2, __pyx_n_s_PyClical, __pyx_n_s_doctest); if (unlikely(!__pyx_tuple__21)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1913; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19252  __Pyx_GOTREF(__pyx_tuple__21);
19253  __Pyx_GIVEREF(__pyx_tuple__21);
19254  __pyx_codeobj__22 = (PyObject*)__Pyx_PyCode_New(0, 0, 2, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__21, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_leopardi_sync_src_glucat_g, __pyx_n_s_test, 1913, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__22)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1913; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19255  __Pyx_RefNannyFinishContext();
19256  return 0;
19257  __pyx_L1_error:;
19258  __Pyx_RefNannyFinishContext();
19259  return -1;
19260 }
19261 
19262 static int __Pyx_InitGlobals(void) {
19263  if (__Pyx_InitStrings(__pyx_string_tab) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
19264  __pyx_float_0_0 = PyFloat_FromDouble(0.0); if (unlikely(!__pyx_float_0_0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19265  __pyx_float_1_0 = PyFloat_FromDouble(1.0); if (unlikely(!__pyx_float_1_0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19266  __pyx_float_2_0 = PyFloat_FromDouble(2.0); if (unlikely(!__pyx_float_2_0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19267  __pyx_float_8_0 = PyFloat_FromDouble(8.0); if (unlikely(!__pyx_float_8_0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19268  __pyx_int_0 = PyInt_FromLong(0); if (unlikely(!__pyx_int_0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19269  __pyx_int_1 = PyInt_FromLong(1); if (unlikely(!__pyx_int_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19270  __pyx_int_4 = PyInt_FromLong(4); if (unlikely(!__pyx_int_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19271  __pyx_int_neg_1 = PyInt_FromLong(-1); if (unlikely(!__pyx_int_neg_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19272  return 0;
19273  __pyx_L1_error:;
19274  return -1;
19275 }
19276 
19277 #if PY_MAJOR_VERSION < 3
19278 PyMODINIT_FUNC initPyClical(void); /*proto*/
19279 PyMODINIT_FUNC initPyClical(void)
19280 #else
19281 PyMODINIT_FUNC PyInit_PyClical(void); /*proto*/
19282 PyMODINIT_FUNC PyInit_PyClical(void)
19283 #endif
19284 {
19285  PyObject *__pyx_t_1 = NULL;
19286  PyObject *__pyx_t_2 = NULL;
19287  PyObject *__pyx_t_3 = NULL;
19288  int __pyx_t_4;
19289  int __pyx_lineno = 0;
19290  const char *__pyx_filename = NULL;
19291  int __pyx_clineno = 0;
19292  __Pyx_RefNannyDeclarations
19293  #if CYTHON_REFNANNY
19294  __Pyx_RefNanny = __Pyx_RefNannyImportAPI("refnanny");
19295  if (!__Pyx_RefNanny) {
19296  PyErr_Clear();
19297  __Pyx_RefNanny = __Pyx_RefNannyImportAPI("Cython.Runtime.refnanny");
19298  if (!__Pyx_RefNanny)
19299  Py_FatalError("failed to import 'refnanny' module");
19300  }
19301  #endif
19302  __Pyx_RefNannySetupContext("PyMODINIT_FUNC PyInit_PyClical(void)", 0);
19303  if (__Pyx_check_binary_version() < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19304  __pyx_empty_tuple = PyTuple_New(0); if (unlikely(!__pyx_empty_tuple)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19305  __pyx_empty_bytes = PyBytes_FromStringAndSize("", 0); if (unlikely(!__pyx_empty_bytes)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19306  #ifdef __Pyx_CyFunction_USED
19307  if (__pyx_CyFunction_init() < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19308  #endif
19309  #ifdef __Pyx_FusedFunction_USED
19310  if (__pyx_FusedFunction_init() < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19311  #endif
19312  #ifdef __Pyx_Coroutine_USED
19313  if (__pyx_Coroutine_init() < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19314  #endif
19315  #ifdef __Pyx_Generator_USED
19316  if (__pyx_Generator_init() < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19317  #endif
19318  #ifdef __Pyx_StopAsyncIteration_USED
19319  if (__pyx_StopAsyncIteration_init() < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19320  #endif
19321  /*--- Library function declarations ---*/
19322  /*--- Threads initialization code ---*/
19323  #if defined(__PYX_FORCE_INIT_THREADS) && __PYX_FORCE_INIT_THREADS
19324  #ifdef WITH_THREAD /* Python build with threading support? */
19325  PyEval_InitThreads();
19326  #endif
19327  #endif
19328  /*--- Module creation code ---*/
19329  #if PY_MAJOR_VERSION < 3
19330  __pyx_m = Py_InitModule4("PyClical", __pyx_methods, 0, 0, PYTHON_API_VERSION); Py_XINCREF(__pyx_m);
19331  #else
19332  __pyx_m = PyModule_Create(&__pyx_moduledef);
19333  #endif
19334  if (unlikely(!__pyx_m)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19335  __pyx_d = PyModule_GetDict(__pyx_m); if (unlikely(!__pyx_d)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19336  Py_INCREF(__pyx_d);
19337  __pyx_b = PyImport_AddModule(__Pyx_BUILTIN_MODULE_NAME); if (unlikely(!__pyx_b)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19338  #if CYTHON_COMPILING_IN_PYPY
19339  Py_INCREF(__pyx_b);
19340  #endif
19341  if (PyObject_SetAttrString(__pyx_m, "__builtins__", __pyx_b) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
19342  /*--- Initialize various global constants etc. ---*/
19343  if (__Pyx_InitGlobals() < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19344  #if PY_MAJOR_VERSION < 3 && (__PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT)
19345  if (__Pyx_init_sys_getdefaultencoding_params() < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19346  #endif
19347  if (__pyx_module_is_main_PyClical) {
19348  if (PyObject_SetAttrString(__pyx_m, "__name__", __pyx_n_s_main) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19349  }
19350  #if PY_MAJOR_VERSION >= 3
19351  {
19352  PyObject *modules = PyImport_GetModuleDict(); if (unlikely(!modules)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19353  if (!PyDict_GetItemString(modules, "PyClical")) {
19354  if (unlikely(PyDict_SetItemString(modules, "PyClical", __pyx_m) < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19355  }
19356  }
19357  #endif
19358  /*--- Builtin init code ---*/
19359  if (__Pyx_InitCachedBuiltins() < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19360  /*--- Constants init code ---*/
19361  if (__Pyx_InitCachedConstants() < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19362  /*--- Global init code ---*/
19363  /*--- Variable export code ---*/
19364  /*--- Function export code ---*/
19365  /*--- Type init code ---*/
19366  __pyx_vtabptr_8PyClical_index_set = &__pyx_vtable_8PyClical_index_set;
19367  __pyx_vtable_8PyClical_index_set.wrap = (PyObject *(*)(struct __pyx_obj_8PyClical_index_set *, IndexSet))__pyx_f_8PyClical_9index_set_wrap;
19368  __pyx_vtable_8PyClical_index_set.unwrap = (IndexSet (*)(struct __pyx_obj_8PyClical_index_set *))__pyx_f_8PyClical_9index_set_unwrap;
19369  __pyx_vtable_8PyClical_index_set.copy = (PyObject *(*)(struct __pyx_obj_8PyClical_index_set *, int __pyx_skip_dispatch))__pyx_f_8PyClical_9index_set_copy;
19370  if (PyType_Ready(&__pyx_type_8PyClical_index_set) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 45; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19371  __pyx_type_8PyClical_index_set.tp_print = 0;
19372  #if CYTHON_COMPILING_IN_CPYTHON
19373  {
19374  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_index_set, "__setitem__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 45; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19375  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19376  __pyx_wrapperbase_8PyClical_9index_set_8__setitem__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19377  __pyx_wrapperbase_8PyClical_9index_set_8__setitem__.doc = __pyx_doc_8PyClical_9index_set_8__setitem__;
19378  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_9index_set_8__setitem__;
19379  }
19380  }
19381  #endif
19382  #if CYTHON_COMPILING_IN_CPYTHON
19383  {
19384  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_index_set, "__getitem__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 45; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19385  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19386  __pyx_wrapperbase_8PyClical_9index_set_10__getitem__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19387  __pyx_wrapperbase_8PyClical_9index_set_10__getitem__.doc = __pyx_doc_8PyClical_9index_set_10__getitem__;
19388  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_9index_set_10__getitem__;
19389  }
19390  }
19391  #endif
19392  #if CYTHON_COMPILING_IN_CPYTHON
19393  {
19394  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_index_set, "__contains__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 45; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19395  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19396  __pyx_wrapperbase_8PyClical_9index_set_12__contains__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19397  __pyx_wrapperbase_8PyClical_9index_set_12__contains__.doc = __pyx_doc_8PyClical_9index_set_12__contains__;
19398  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_9index_set_12__contains__;
19399  }
19400  }
19401  #endif
19402  #if CYTHON_COMPILING_IN_CPYTHON
19403  {
19404  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_index_set, "__iter__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 45; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19405  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19406  __pyx_wrapperbase_8PyClical_9index_set_14__iter__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19407  __pyx_wrapperbase_8PyClical_9index_set_14__iter__.doc = __pyx_doc_8PyClical_9index_set_14__iter__;
19408  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_9index_set_14__iter__;
19409  }
19410  }
19411  #endif
19412  #if CYTHON_COMPILING_IN_CPYTHON
19413  {
19414  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_index_set, "__invert__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 45; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19415  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19416  __pyx_wrapperbase_8PyClical_9index_set_17__invert__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19417  __pyx_wrapperbase_8PyClical_9index_set_17__invert__.doc = __pyx_doc_8PyClical_9index_set_17__invert__;
19418  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_9index_set_17__invert__;
19419  }
19420  }
19421  #endif
19422  #if CYTHON_COMPILING_IN_CPYTHON
19423  {
19424  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_index_set, "__xor__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 45; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19425  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19426  __pyx_wrapperbase_8PyClical_9index_set_19__xor__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19427  __pyx_wrapperbase_8PyClical_9index_set_19__xor__.doc = __pyx_doc_8PyClical_9index_set_19__xor__;
19428  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_9index_set_19__xor__;
19429  }
19430  }
19431  #endif
19432  #if CYTHON_COMPILING_IN_CPYTHON
19433  {
19434  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_index_set, "__ixor__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 45; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19435  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19436  __pyx_wrapperbase_8PyClical_9index_set_21__ixor__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19437  __pyx_wrapperbase_8PyClical_9index_set_21__ixor__.doc = __pyx_doc_8PyClical_9index_set_21__ixor__;
19438  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_9index_set_21__ixor__;
19439  }
19440  }
19441  #endif
19442  #if CYTHON_COMPILING_IN_CPYTHON
19443  {
19444  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_index_set, "__and__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 45; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19445  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19446  __pyx_wrapperbase_8PyClical_9index_set_23__and__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19447  __pyx_wrapperbase_8PyClical_9index_set_23__and__.doc = __pyx_doc_8PyClical_9index_set_23__and__;
19448  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_9index_set_23__and__;
19449  }
19450  }
19451  #endif
19452  #if CYTHON_COMPILING_IN_CPYTHON
19453  {
19454  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_index_set, "__iand__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 45; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19455  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19456  __pyx_wrapperbase_8PyClical_9index_set_25__iand__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19457  __pyx_wrapperbase_8PyClical_9index_set_25__iand__.doc = __pyx_doc_8PyClical_9index_set_25__iand__;
19458  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_9index_set_25__iand__;
19459  }
19460  }
19461  #endif
19462  #if CYTHON_COMPILING_IN_CPYTHON
19463  {
19464  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_index_set, "__or__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 45; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19465  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19466  __pyx_wrapperbase_8PyClical_9index_set_27__or__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19467  __pyx_wrapperbase_8PyClical_9index_set_27__or__.doc = __pyx_doc_8PyClical_9index_set_27__or__;
19468  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_9index_set_27__or__;
19469  }
19470  }
19471  #endif
19472  #if CYTHON_COMPILING_IN_CPYTHON
19473  {
19474  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_index_set, "__ior__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 45; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19475  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19476  __pyx_wrapperbase_8PyClical_9index_set_29__ior__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19477  __pyx_wrapperbase_8PyClical_9index_set_29__ior__.doc = __pyx_doc_8PyClical_9index_set_29__ior__;
19478  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_9index_set_29__ior__;
19479  }
19480  }
19481  #endif
19482  #if CYTHON_COMPILING_IN_CPYTHON
19483  {
19484  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_index_set, "__repr__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 45; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19485  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19486  __pyx_wrapperbase_8PyClical_9index_set_47__repr__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19487  __pyx_wrapperbase_8PyClical_9index_set_47__repr__.doc = __pyx_doc_8PyClical_9index_set_47__repr__;
19488  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_9index_set_47__repr__;
19489  }
19490  }
19491  #endif
19492  #if CYTHON_COMPILING_IN_CPYTHON
19493  {
19494  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_index_set, "__str__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 45; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19495  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19496  __pyx_wrapperbase_8PyClical_9index_set_49__str__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19497  __pyx_wrapperbase_8PyClical_9index_set_49__str__.doc = __pyx_doc_8PyClical_9index_set_49__str__;
19498  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_9index_set_49__str__;
19499  }
19500  }
19501  #endif
19502  if (__Pyx_SetVtable(__pyx_type_8PyClical_index_set.tp_dict, __pyx_vtabptr_8PyClical_index_set) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 45; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19503  if (PyObject_SetAttrString(__pyx_m, "index_set", (PyObject *)&__pyx_type_8PyClical_index_set) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 45; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19504  __pyx_ptype_8PyClical_index_set = &__pyx_type_8PyClical_index_set;
19505  __pyx_vtabptr_8PyClical_clifford = &__pyx_vtable_8PyClical_clifford;
19506  __pyx_vtable_8PyClical_clifford.wrap = (PyObject *(*)(struct __pyx_obj_8PyClical_clifford *, Clifford))__pyx_f_8PyClical_8clifford_wrap;
19507  __pyx_vtable_8PyClical_clifford.unwrap = (Clifford (*)(struct __pyx_obj_8PyClical_clifford *))__pyx_f_8PyClical_8clifford_unwrap;
19508  __pyx_vtable_8PyClical_clifford.copy = (PyObject *(*)(struct __pyx_obj_8PyClical_clifford *, int __pyx_skip_dispatch))__pyx_f_8PyClical_8clifford_copy;
19509  if (PyType_Ready(&__pyx_type_8PyClical_clifford) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19510  __pyx_type_8PyClical_clifford.tp_print = 0;
19511  #if CYTHON_COMPILING_IN_CPYTHON
19512  {
19513  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__contains__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19514  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19515  __pyx_wrapperbase_8PyClical_8clifford_6__contains__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19516  __pyx_wrapperbase_8PyClical_8clifford_6__contains__.doc = __pyx_doc_8PyClical_8clifford_6__contains__;
19517  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_6__contains__;
19518  }
19519  }
19520  #endif
19521  #if CYTHON_COMPILING_IN_CPYTHON
19522  {
19523  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__iter__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19524  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19525  __pyx_wrapperbase_8PyClical_8clifford_8__iter__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19526  __pyx_wrapperbase_8PyClical_8clifford_8__iter__.doc = __pyx_doc_8PyClical_8clifford_8__iter__;
19527  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_8__iter__;
19528  }
19529  }
19530  #endif
19531  #if CYTHON_COMPILING_IN_CPYTHON
19532  {
19533  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__getitem__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19534  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19535  __pyx_wrapperbase_8PyClical_8clifford_14__getitem__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19536  __pyx_wrapperbase_8PyClical_8clifford_14__getitem__.doc = __pyx_doc_8PyClical_8clifford_14__getitem__;
19537  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_14__getitem__;
19538  }
19539  }
19540  #endif
19541  #if CYTHON_COMPILING_IN_CPYTHON
19542  {
19543  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__neg__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19544  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19545  __pyx_wrapperbase_8PyClical_8clifford_16__neg__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19546  __pyx_wrapperbase_8PyClical_8clifford_16__neg__.doc = __pyx_doc_8PyClical_8clifford_16__neg__;
19547  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_16__neg__;
19548  }
19549  }
19550  #endif
19551  #if CYTHON_COMPILING_IN_CPYTHON
19552  {
19553  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__pos__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19554  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19555  __pyx_wrapperbase_8PyClical_8clifford_18__pos__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19556  __pyx_wrapperbase_8PyClical_8clifford_18__pos__.doc = __pyx_doc_8PyClical_8clifford_18__pos__;
19557  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_18__pos__;
19558  }
19559  }
19560  #endif
19561  #if CYTHON_COMPILING_IN_CPYTHON
19562  {
19563  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__add__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19564  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19565  __pyx_wrapperbase_8PyClical_8clifford_20__add__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19566  __pyx_wrapperbase_8PyClical_8clifford_20__add__.doc = __pyx_doc_8PyClical_8clifford_20__add__;
19567  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_20__add__;
19568  }
19569  }
19570  #endif
19571  #if CYTHON_COMPILING_IN_CPYTHON
19572  {
19573  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__iadd__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19574  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19575  __pyx_wrapperbase_8PyClical_8clifford_22__iadd__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19576  __pyx_wrapperbase_8PyClical_8clifford_22__iadd__.doc = __pyx_doc_8PyClical_8clifford_22__iadd__;
19577  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_22__iadd__;
19578  }
19579  }
19580  #endif
19581  #if CYTHON_COMPILING_IN_CPYTHON
19582  {
19583  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__sub__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19584  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19585  __pyx_wrapperbase_8PyClical_8clifford_24__sub__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19586  __pyx_wrapperbase_8PyClical_8clifford_24__sub__.doc = __pyx_doc_8PyClical_8clifford_24__sub__;
19587  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_24__sub__;
19588  }
19589  }
19590  #endif
19591  #if CYTHON_COMPILING_IN_CPYTHON
19592  {
19593  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__isub__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19594  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19595  __pyx_wrapperbase_8PyClical_8clifford_26__isub__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19596  __pyx_wrapperbase_8PyClical_8clifford_26__isub__.doc = __pyx_doc_8PyClical_8clifford_26__isub__;
19597  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_26__isub__;
19598  }
19599  }
19600  #endif
19601  #if CYTHON_COMPILING_IN_CPYTHON
19602  {
19603  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__mul__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19604  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19605  __pyx_wrapperbase_8PyClical_8clifford_28__mul__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19606  __pyx_wrapperbase_8PyClical_8clifford_28__mul__.doc = __pyx_doc_8PyClical_8clifford_28__mul__;
19607  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_28__mul__;
19608  }
19609  }
19610  #endif
19611  #if CYTHON_COMPILING_IN_CPYTHON
19612  {
19613  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__imul__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19614  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19615  __pyx_wrapperbase_8PyClical_8clifford_30__imul__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19616  __pyx_wrapperbase_8PyClical_8clifford_30__imul__.doc = __pyx_doc_8PyClical_8clifford_30__imul__;
19617  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_30__imul__;
19618  }
19619  }
19620  #endif
19621  #if CYTHON_COMPILING_IN_CPYTHON
19622  {
19623  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__mod__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19624  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19625  __pyx_wrapperbase_8PyClical_8clifford_32__mod__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19626  __pyx_wrapperbase_8PyClical_8clifford_32__mod__.doc = __pyx_doc_8PyClical_8clifford_32__mod__;
19627  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_32__mod__;
19628  }
19629  }
19630  #endif
19631  #if CYTHON_COMPILING_IN_CPYTHON
19632  {
19633  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__imod__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19634  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19635  __pyx_wrapperbase_8PyClical_8clifford_34__imod__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19636  __pyx_wrapperbase_8PyClical_8clifford_34__imod__.doc = __pyx_doc_8PyClical_8clifford_34__imod__;
19637  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_34__imod__;
19638  }
19639  }
19640  #endif
19641  #if CYTHON_COMPILING_IN_CPYTHON
19642  {
19643  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__and__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19644  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19645  __pyx_wrapperbase_8PyClical_8clifford_36__and__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19646  __pyx_wrapperbase_8PyClical_8clifford_36__and__.doc = __pyx_doc_8PyClical_8clifford_36__and__;
19647  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_36__and__;
19648  }
19649  }
19650  #endif
19651  #if CYTHON_COMPILING_IN_CPYTHON
19652  {
19653  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__iand__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19654  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19655  __pyx_wrapperbase_8PyClical_8clifford_38__iand__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19656  __pyx_wrapperbase_8PyClical_8clifford_38__iand__.doc = __pyx_doc_8PyClical_8clifford_38__iand__;
19657  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_38__iand__;
19658  }
19659  }
19660  #endif
19661  #if CYTHON_COMPILING_IN_CPYTHON
19662  {
19663  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__xor__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19664  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19665  __pyx_wrapperbase_8PyClical_8clifford_40__xor__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19666  __pyx_wrapperbase_8PyClical_8clifford_40__xor__.doc = __pyx_doc_8PyClical_8clifford_40__xor__;
19667  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_40__xor__;
19668  }
19669  }
19670  #endif
19671  #if CYTHON_COMPILING_IN_CPYTHON
19672  {
19673  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__ixor__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19674  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19675  __pyx_wrapperbase_8PyClical_8clifford_42__ixor__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19676  __pyx_wrapperbase_8PyClical_8clifford_42__ixor__.doc = __pyx_doc_8PyClical_8clifford_42__ixor__;
19677  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_42__ixor__;
19678  }
19679  }
19680  #endif
19681  #if PY_MAJOR_VERSION < 3 || CYTHON_COMPILING_IN_PYPY
19682  #if CYTHON_COMPILING_IN_CPYTHON
19683  {
19684  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__div__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19685  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19686  __pyx_wrapperbase_8PyClical_8clifford_44__div__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19687  __pyx_wrapperbase_8PyClical_8clifford_44__div__.doc = __pyx_doc_8PyClical_8clifford_44__div__;
19688  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_44__div__;
19689  }
19690  }
19691  #endif
19692  #endif
19693  #if PY_MAJOR_VERSION < 3 || CYTHON_COMPILING_IN_PYPY
19694  #if CYTHON_COMPILING_IN_CPYTHON
19695  {
19696  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__idiv__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19697  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19698  __pyx_wrapperbase_8PyClical_8clifford_46__idiv__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19699  __pyx_wrapperbase_8PyClical_8clifford_46__idiv__.doc = __pyx_doc_8PyClical_8clifford_46__idiv__;
19700  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_46__idiv__;
19701  }
19702  }
19703  #endif
19704  #endif
19705  #if CYTHON_COMPILING_IN_CPYTHON
19706  {
19707  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__or__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19708  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19709  __pyx_wrapperbase_8PyClical_8clifford_50__or__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19710  __pyx_wrapperbase_8PyClical_8clifford_50__or__.doc = __pyx_doc_8PyClical_8clifford_50__or__;
19711  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_50__or__;
19712  }
19713  }
19714  #endif
19715  #if CYTHON_COMPILING_IN_CPYTHON
19716  {
19717  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__ior__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19718  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19719  __pyx_wrapperbase_8PyClical_8clifford_52__ior__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19720  __pyx_wrapperbase_8PyClical_8clifford_52__ior__.doc = __pyx_doc_8PyClical_8clifford_52__ior__;
19721  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_52__ior__;
19722  }
19723  }
19724  #endif
19725  #if CYTHON_COMPILING_IN_CPYTHON
19726  {
19727  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__pow__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19728  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19729  __pyx_wrapperbase_8PyClical_8clifford_54__pow__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19730  __pyx_wrapperbase_8PyClical_8clifford_54__pow__.doc = __pyx_doc_8PyClical_8clifford_54__pow__;
19731  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_54__pow__;
19732  }
19733  }
19734  #endif
19735  #if CYTHON_COMPILING_IN_CPYTHON
19736  {
19737  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__call__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19738  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19739  __pyx_wrapperbase_8PyClical_8clifford_60__call__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19740  __pyx_wrapperbase_8PyClical_8clifford_60__call__.doc = __pyx_doc_8PyClical_8clifford_60__call__;
19741  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_60__call__;
19742  }
19743  }
19744  #endif
19745  #if CYTHON_COMPILING_IN_CPYTHON
19746  {
19747  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__repr__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19748  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19749  __pyx_wrapperbase_8PyClical_8clifford_92__repr__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19750  __pyx_wrapperbase_8PyClical_8clifford_92__repr__.doc = __pyx_doc_8PyClical_8clifford_92__repr__;
19751  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_92__repr__;
19752  }
19753  }
19754  #endif
19755  #if CYTHON_COMPILING_IN_CPYTHON
19756  {
19757  PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_8PyClical_clifford, "__str__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19758  if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
19759  __pyx_wrapperbase_8PyClical_8clifford_94__str__ = *((PyWrapperDescrObject *)wrapper)->d_base;
19760  __pyx_wrapperbase_8PyClical_8clifford_94__str__.doc = __pyx_doc_8PyClical_8clifford_94__str__;
19761  ((PyWrapperDescrObject *)wrapper)->d_base = &__pyx_wrapperbase_8PyClical_8clifford_94__str__;
19762  }
19763  }
19764  #endif
19765  if (__Pyx_SetVtable(__pyx_type_8PyClical_clifford.tp_dict, __pyx_vtabptr_8PyClical_clifford) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19766  if (PyObject_SetAttrString(__pyx_m, "clifford", (PyObject *)&__pyx_type_8PyClical_clifford) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19767  __pyx_ptype_8PyClical_clifford = &__pyx_type_8PyClical_clifford;
19768  if (PyType_Ready(&__pyx_type_8PyClical___pyx_scope_struct____iter__) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19769  __pyx_type_8PyClical___pyx_scope_struct____iter__.tp_print = 0;
19770  __pyx_ptype_8PyClical___pyx_scope_struct____iter__ = &__pyx_type_8PyClical___pyx_scope_struct____iter__;
19771  /*--- Type import code ---*/
19772  /*--- Variable import code ---*/
19773  /*--- Function import code ---*/
19774  /*--- Execution code ---*/
19775  #if defined(__Pyx_Generator_USED) || defined(__Pyx_Coroutine_USED)
19776  if (__Pyx_patch_abc() < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19777  #endif
19778 
19779  /* "PyClical.pyx":28
19780  * # C. Doran and A. Lasenby, "Geometric algebra for physicists", Cambridge, 2003.
19781  *
19782  * import math # <<<<<<<<<<<<<<
19783  * import numbers
19784  * import collections
19785  */
19786  __pyx_t_1 = __Pyx_Import(__pyx_n_s_math, 0, -1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19787  __Pyx_GOTREF(__pyx_t_1);
19788  if (PyDict_SetItem(__pyx_d, __pyx_n_s_math, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19789  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
19790 
19791  /* "PyClical.pyx":29
19792  *
19793  * import math
19794  * import numbers # <<<<<<<<<<<<<<
19795  * import collections
19796  *
19797  */
19798  __pyx_t_1 = __Pyx_Import(__pyx_n_s_numbers, 0, -1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 29; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19799  __Pyx_GOTREF(__pyx_t_1);
19800  if (PyDict_SetItem(__pyx_d, __pyx_n_s_numbers, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 29; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19801  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
19802 
19803  /* "PyClical.pyx":30
19804  * import math
19805  * import numbers
19806  * import collections # <<<<<<<<<<<<<<
19807  *
19808  * __version__ = "0.8.2"
19809  */
19810  __pyx_t_1 = __Pyx_Import(__pyx_n_s_collections, 0, -1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 30; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19811  __Pyx_GOTREF(__pyx_t_1);
19812  if (PyDict_SetItem(__pyx_d, __pyx_n_s_collections, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 30; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19813  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
19814 
19815  /* "PyClical.pyx":32
19816  * import collections
19817  *
19818  * __version__ = "0.8.2" # <<<<<<<<<<<<<<
19819  *
19820  * from PyClical cimport *
19821  */
19822  if (PyDict_SetItem(__pyx_d, __pyx_n_s_version, __pyx_kp_s_0_8_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 32; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19823 
19824  /* "PyClical.pyx":404
19825  * return index_set_to_str( self.unwrap() ).c_str()
19826  *
19827  * def index_set_hidden_doctests(): # <<<<<<<<<<<<<<
19828  * """
19829  * Tests for functions that Doctest cannot see.
19830  */
19831  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_8PyClical_1index_set_hidden_doctests, NULL, __pyx_n_s_PyClical); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 404; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19832  __Pyx_GOTREF(__pyx_t_1);
19833  if (PyDict_SetItem(__pyx_d, __pyx_n_s_index_set_hidden_doctests, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 404; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19834  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
19835 
19836  /* "PyClical.pyx":1243
19837  * return clifford_to_str( self.unwrap() ).c_str()
19838  *
19839  * def clifford_hidden_doctests(): # <<<<<<<<<<<<<<
19840  * """
19841  * Tests for functions that Doctest cannot see.
19842  */
19843  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_8PyClical_9clifford_hidden_doctests, NULL, __pyx_n_s_PyClical); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19844  __Pyx_GOTREF(__pyx_t_1);
19845  if (PyDict_SetItem(__pyx_d, __pyx_n_s_clifford_hidden_doctests, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19846  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
19847 
19848  /* "PyClical.pyx":1856
19849  *
19850  * # Some abbreviations.
19851  * tau = atan(clifford(1.0)) * 8.0 # <<<<<<<<<<<<<<
19852  * pi = tau / 2.0
19853  *
19854  */
19855  __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_8PyClical_clifford), __pyx_tuple__12, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1856; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19856  __Pyx_GOTREF(__pyx_t_1);
19857  __pyx_t_2 = __pyx_f_8PyClical_atan(__pyx_t_1, 0, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1856; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19858  __Pyx_GOTREF(__pyx_t_2);
19859  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
19860  __pyx_t_1 = PyNumber_Multiply(__pyx_t_2, __pyx_float_8_0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1856; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19861  __Pyx_GOTREF(__pyx_t_1);
19862  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
19863  if (PyDict_SetItem(__pyx_d, __pyx_n_s_tau, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1856; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19864  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
19865 
19866  /* "PyClical.pyx":1857
19867  * # Some abbreviations.
19868  * tau = atan(clifford(1.0)) * 8.0
19869  * pi = tau / 2.0 # <<<<<<<<<<<<<<
19870  *
19871  * cl = clifford
19872  */
19873  __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_tau); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1857; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19874  __Pyx_GOTREF(__pyx_t_1);
19875  __pyx_t_2 = __Pyx_PyFloat_DivideObjC(__pyx_t_1, __pyx_float_2_0, 2.0, 0); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1857; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19876  __Pyx_GOTREF(__pyx_t_2);
19877  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
19878  if (PyDict_SetItem(__pyx_d, __pyx_n_s_pi, __pyx_t_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1857; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19879  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
19880 
19881  /* "PyClical.pyx":1859
19882  * pi = tau / 2.0
19883  *
19884  * cl = clifford # <<<<<<<<<<<<<<
19885  * """
19886  * Abbreviation for clifford.
19887  */
19888  if (PyDict_SetItem(__pyx_d, __pyx_n_s_cl, ((PyObject *)__pyx_ptype_8PyClical_clifford)) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1859; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19889 
19890  /* "PyClical.pyx":1879
19891  * """
19892  *
19893  * ist = index_set # <<<<<<<<<<<<<<
19894  * """
19895  * Abbreviation for index_set.
19896  */
19897  if (PyDict_SetItem(__pyx_d, __pyx_n_s_ist, ((PyObject *)__pyx_ptype_8PyClical_index_set)) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1879; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19898 
19899  /* "PyClical.pyx":1887
19900  * """
19901  *
19902  * def e(obj): # <<<<<<<<<<<<<<
19903  * """
19904  * Abbreviation for clifford(index_set(obj)).
19905  */
19906  __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_8PyClical_83e, NULL, __pyx_n_s_PyClical); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1887; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19907  __Pyx_GOTREF(__pyx_t_2);
19908  if (PyDict_SetItem(__pyx_d, __pyx_n_s_e, __pyx_t_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1887; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19909  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
19910 
19911  /* "PyClical.pyx":1900
19912  * return clifford(index_set(obj))
19913  *
19914  * def istpq(p, q): # <<<<<<<<<<<<<<
19915  * """
19916  * Abbreviation for index_set({-q,...p}).
19917  */
19918  __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_8PyClical_85istpq, NULL, __pyx_n_s_PyClical); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1900; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19919  __Pyx_GOTREF(__pyx_t_2);
19920  if (PyDict_SetItem(__pyx_d, __pyx_n_s_istpq, __pyx_t_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1900; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19921  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
19922 
19923  /* "PyClical.pyx":1909
19924  * return index_set(set(range(-q,p+1)))
19925  *
19926  * ninf3 = e(4) + e(-1) # Null infinity point in 3D Conformal Geometric Algebra [DL]. # <<<<<<<<<<<<<<
19927  * nbar3 = e(4) - e(-1) # Null bar point in 3D Conformal Geometric Algebra [DL].
19928  *
19929  */
19930  __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_e); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1909; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19931  __Pyx_GOTREF(__pyx_t_2);
19932  __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__17, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1909; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19933  __Pyx_GOTREF(__pyx_t_1);
19934  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
19935  __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_e); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1909; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19936  __Pyx_GOTREF(__pyx_t_2);
19937  __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__18, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1909; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19938  __Pyx_GOTREF(__pyx_t_3);
19939  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
19940  __pyx_t_2 = PyNumber_Add(__pyx_t_1, __pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1909; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19941  __Pyx_GOTREF(__pyx_t_2);
19942  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
19943  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
19944  if (PyDict_SetItem(__pyx_d, __pyx_n_s_ninf3, __pyx_t_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1909; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19945  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
19946 
19947  /* "PyClical.pyx":1910
19948  *
19949  * ninf3 = e(4) + e(-1) # Null infinity point in 3D Conformal Geometric Algebra [DL].
19950  * nbar3 = e(4) - e(-1) # Null bar point in 3D Conformal Geometric Algebra [DL]. # <<<<<<<<<<<<<<
19951  *
19952  * # Doctest interface.
19953  */
19954  __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_e); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1910; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19955  __Pyx_GOTREF(__pyx_t_2);
19956  __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__19, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1910; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19957  __Pyx_GOTREF(__pyx_t_3);
19958  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
19959  __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_e); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1910; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19960  __Pyx_GOTREF(__pyx_t_2);
19961  __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__20, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1910; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19962  __Pyx_GOTREF(__pyx_t_1);
19963  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
19964  __pyx_t_2 = PyNumber_Subtract(__pyx_t_3, __pyx_t_1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1910; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19965  __Pyx_GOTREF(__pyx_t_2);
19966  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
19967  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
19968  if (PyDict_SetItem(__pyx_d, __pyx_n_s_nbar3, __pyx_t_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1910; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19969  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
19970 
19971  /* "PyClical.pyx":1913
19972  *
19973  * # Doctest interface.
19974  * def _test(): # <<<<<<<<<<<<<<
19975  * import PyClical, doctest
19976  * return doctest.testmod(PyClical)
19977  */
19978  __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_8PyClical_87_test, NULL, __pyx_n_s_PyClical); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1913; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19979  __Pyx_GOTREF(__pyx_t_2);
19980  if (PyDict_SetItem(__pyx_d, __pyx_n_s_test, __pyx_t_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1913; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19981  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
19982 
19983  /* "PyClical.pyx":1917
19984  * return doctest.testmod(PyClical)
19985  *
19986  * if __name__ == "__main__": # <<<<<<<<<<<<<<
19987  * _test()
19988  */
19989  __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_name); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1917; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19990  __Pyx_GOTREF(__pyx_t_2);
19991  __pyx_t_4 = (__Pyx_PyString_Equals(__pyx_t_2, __pyx_n_s_main, Py_EQ)); if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1917; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
19992  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
19993  if (__pyx_t_4) {
19994 
19995  /* "PyClical.pyx":1918
19996  *
19997  * if __name__ == "__main__":
19998  * _test() # <<<<<<<<<<<<<<
19999  */
20000  __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_test); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1918; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20001  __Pyx_GOTREF(__pyx_t_1);
20002  __pyx_t_3 = NULL;
20003  if (CYTHON_COMPILING_IN_CPYTHON && unlikely(PyMethod_Check(__pyx_t_1))) {
20004  __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_1);
20005  if (likely(__pyx_t_3)) {
20006  PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
20007  __Pyx_INCREF(__pyx_t_3);
20008  __Pyx_INCREF(function);
20009  __Pyx_DECREF_SET(__pyx_t_1, function);
20010  }
20011  }
20012  if (__pyx_t_3) {
20013  __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1918; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20014  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
20015  } else {
20016  __pyx_t_2 = __Pyx_PyObject_CallNoArg(__pyx_t_1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1918; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20017  }
20018  __Pyx_GOTREF(__pyx_t_2);
20019  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
20020  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
20021 
20022  /* "PyClical.pyx":1917
20023  * return doctest.testmod(PyClical)
20024  *
20025  * if __name__ == "__main__": # <<<<<<<<<<<<<<
20026  * _test()
20027  */
20028  }
20029 
20030  /* "PyClical.pyx":1
20031  * # -*- coding: utf-8 -*- # <<<<<<<<<<<<<<
20032  * # distutils: language = c++
20033  * #
20034  */
20035  __pyx_t_2 = PyDict_New(); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20036  __Pyx_GOTREF(__pyx_t_2);
20037  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_index_set_copy_line_64, __pyx_kp_u_Copy_this_index_set_object_s_in) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20038  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_index_set___setitem___line_177, __pyx_kp_u_Set_the_value_of_an_index_set_o) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20039  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_index_set___getitem___line_189, __pyx_kp_u_Get_the_value_of_an_index_set_o) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20040  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_index_set___iter___line_227, __pyx_kp_u_Iterate_over_the_indices_of_an) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20041  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_index_set___invert___line_238, __pyx_kp_u_Set_complement_not_print_index) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20042  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_index_set___xor___line_247, __pyx_kp_u_Symmetric_set_difference_exclus) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20043  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_index_set___ixor___line_258, __pyx_kp_u_Symmetric_set_difference_exclus_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20044  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_index_set___and___line_269, __pyx_kp_u_Set_intersection_and_print_inde) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20045  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_index_set___iand___line_280, __pyx_kp_u_Set_intersection_and_x_index_se) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20046  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_index_set___or___line_291, __pyx_kp_u_Set_union_or_print_index_set_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20047  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_index_set___ior___line_302, __pyx_kp_u_Set_union_or_x_index_set_1_x_in) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20048  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_index_set_count_line_313, __pyx_kp_u_Cardinality_Number_of_indices_i) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20049  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_index_set_count_neg_line_322, __pyx_kp_u_Number_of_negative_indices_incl) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20050  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_index_set_count_pos_line_331, __pyx_kp_u_Number_of_positive_indices_incl) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20051  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_index_set_min_line_340, __pyx_kp_u_Minimum_member_index_set_1_1_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20052  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_index_set_max_line_349, __pyx_kp_u_Maximum_member_index_set_1_1_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20053  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_index_set_sign_of_mult_line_364, __pyx_kp_u_Sign_of_geometric_product_of_tw) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20054  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_index_set_sign_of_square_line_37, __pyx_kp_u_Sign_of_geometric_square_of_a_C) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20055  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_index_set___repr___line_382, __pyx_kp_u_The_official_string_representat) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20056  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_index_set___str___line_393, __pyx_kp_u_The_informal_string_representat) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20057  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_index_set_hidden_doctests_line_4, __pyx_kp_u_Tests_for_functions_that_Doctes) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20058  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_compare_line_490, __pyx_kp_u_lexicographic_compare_eg_3_4_5) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20059  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_min_neg_line_502, __pyx_kp_u_Minimum_negative_index_or_0_if) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20060  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_max_pos_line_511, __pyx_kp_u_Maximum_positive_index_or_0_if) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20061  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford_copy_line_554, __pyx_kp_u_Copy_this_clifford_object_x_cli) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20062  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___iter___line_637, __pyx_kp_u_Not_applicable_for_a_in_cliffor) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20063  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford_reframe_line_648, __pyx_kp_u_Put_self_into_a_larger_frame_co) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20064  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___getitem___line_706, __pyx_kp_u_Subscripting_map_from_index_set) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20065  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___neg___line_721, __pyx_kp_u_Unary_print_clifford_1_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20066  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___pos___line_730, __pyx_kp_u_Unary_print_clifford_1_1_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20067  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___add___line_739, __pyx_kp_u_Geometric_sum_print_clifford_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20068  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___iadd___line_750, __pyx_kp_u_Geometric_sum_x_clifford_1_x_cl) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20069  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___sub___line_759, __pyx_kp_u_Geometric_difference_print_clif) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20070  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___isub___line_770, __pyx_kp_u_Geometric_difference_x_clifford) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20071  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___mul___line_779, __pyx_kp_u_Geometric_product_print_cliffor) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20072  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___imul___line_792, __pyx_kp_u_Geometric_product_x_clifford_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20073  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___mod___line_805, __pyx_kp_u_Contraction_print_clifford_1_cl) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20074  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___imod___line_820, __pyx_kp_u_Contraction_x_clifford_1_x_clif) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20075  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___and___line_835, __pyx_kp_u_Inner_product_print_clifford_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20076  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___iand___line_850, __pyx_kp_u_Inner_product_x_clifford_1_x_cl) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20077  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___xor___line_865, __pyx_kp_u_Outer_product_print_clifford_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20078  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___ixor___line_880, __pyx_kp_u_Outer_product_x_clifford_1_x_cl) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20079  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___div___line_895, __pyx_kp_u_Geometric_quotient_print_cliffo) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20080  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___idiv___line_910, __pyx_kp_u_Geometric_quotient_x_clifford_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20081  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford_inv_line_925, __pyx_kp_u_Geometric_multiplicative_invers) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20082  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___or___line_938, __pyx_kp_u_Transform_left_hand_side_using) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20083  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___ior___line_949, __pyx_kp_u_Transform_left_hand_side_using_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20084  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___pow___line_960, __pyx_kp_u_Power_self_to_the_m_x_clifford) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20085  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford_pow_line_979, __pyx_kp_u_Power_self_to_the_m_x_clifford_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20086  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford_outer_pow_line_1003, __pyx_kp_u_Outer_product_power_x_clifford) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20087  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___call___line_1019, __pyx_kp_u_Pure_grade_vector_part_print_cl) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20088  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford_scalar_line_1038, __pyx_kp_u_Scalar_part_clifford_1_1_1_2_sc) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20089  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford_pure_line_1049, __pyx_kp_u_Pure_part_print_clifford_1_1_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20090  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford_even_line_1060, __pyx_kp_u_Even_part_of_multivector_sum_of) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20091  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford_odd_line_1069, __pyx_kp_u_Odd_part_of_multivector_sum_of) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20092  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford_vector_part_line_1078, __pyx_kp_u_Vector_part_of_multivector_as_a) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20093  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford_involute_line_1106, __pyx_kp_u_Main_involution_each_i_is_repla) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20094  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford_reverse_line_1122, __pyx_kp_u_Reversion_eg_clifford_1_cliffor) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20095  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford_conj_line_1137, __pyx_kp_u_Conjugation_reverse_o_involute) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20096  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford_quad_line_1152, __pyx_kp_u_Quadratic_form_rev_x_x_0_print) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20097  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford_norm_line_1163, __pyx_kp_u_Norm_sum_of_squares_of_coordina) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20098  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford_abs_line_1174, __pyx_kp_u_Absolute_value_square_root_of_n) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20099  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford_max_abs_line_1183, __pyx_kp_u_Maximum_of_absolute_values_of_c) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20100  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford_truncated_line_1194, __pyx_kp_u_Remove_all_terms_of_self_with_r) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20101  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford_isnan_line_1205, __pyx_kp_u_Check_if_a_multivector_contains) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20102  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford_frame_line_1214, __pyx_kp_u_Subalgebra_generated_by_all_gen) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20103  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___repr___line_1225, __pyx_kp_u_The_official_string_representat_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20104  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford___str___line_1234, __pyx_kp_u_The_informal_string_representat_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20105  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_clifford_hidden_doctests_line_12, __pyx_kp_u_Tests_for_functions_that_Doctes_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20106  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_inv_line_1329, __pyx_kp_u_Geometric_multiplicative_invers_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20107  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_scalar_line_1344, __pyx_kp_u_Scalar_part_scalar_clifford_1_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20108  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_real_line_1355, __pyx_kp_u_Real_part_synonym_for_scalar_pa) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20109  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_imag_line_1366, __pyx_kp_u_Imaginary_part_deprecated_alway) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20110  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_pure_line_1377, __pyx_kp_u_Pure_part_print_pure_clifford_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20111  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_even_line_1388, __pyx_kp_u_Even_part_of_multivector_sum_of_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20112  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_odd_line_1397, __pyx_kp_u_Odd_part_of_multivector_sum_of_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20113  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_involute_line_1406, __pyx_kp_u_Main_involution_each_i_is_repla_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20114  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_reverse_line_1421, __pyx_kp_u_Reversion_eg_1_2_2_1_print_reve) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20115  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_conj_line_1436, __pyx_kp_u_Conjugation_reverse_o_involute_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20116  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_quad_line_1451, __pyx_kp_u_Quadratic_form_rev_x_x_0_print_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20117  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_norm_line_1462, __pyx_kp_u_norm_sum_of_squares_of_coordina) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20118  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_abs_line_1473, __pyx_kp_u_Absolute_value_of_multivector_m) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20119  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_max_abs_line_1482, __pyx_kp_u_Maximum_absolute_value_of_coord) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20120  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_pow_line_1494, __pyx_kp_u_Integer_power_of_multivector_ob) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20121  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_outer_pow_line_1518, __pyx_kp_u_Outer_product_power_of_multivec) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20122  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_complexifier_line_1527, __pyx_kp_u_Square_root_of_1_which_commutes) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20123  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_sqrt_line_1542, __pyx_kp_u_Square_root_of_multivector_with) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20124  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_exp_line_1565, __pyx_kp_u_Exponential_of_multivector_x_cl) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20125  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_log_line_1579, __pyx_kp_u_Natural_logarithm_of_multivecto) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20126  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_cos_line_1602, __pyx_kp_u_Cosine_of_multivector_with_opti) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20127  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_acos_line_1619, __pyx_kp_u_Inverse_cosine_of_multivector_w) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20128  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_cosh_line_1640, __pyx_kp_u_Hyperbolic_cosine_of_multivecto) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20129  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_acosh_line_1656, __pyx_kp_u_Inverse_hyperbolic_cosine_of_mu) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20130  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_sin_line_1679, __pyx_kp_u_Sine_of_multivector_with_option) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20131  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_asin_line_1698, __pyx_kp_u_Inverse_sine_of_multivector_wit) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20132  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_sinh_line_1719, __pyx_kp_u_Hyperbolic_sine_of_multivector) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20133  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_asinh_line_1733, __pyx_kp_u_Inverse_hyperbolic_sine_of_mult) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20134  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_tan_line_1752, __pyx_kp_u_Tangent_of_multivector_with_opt) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20135  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_atan_line_1769, __pyx_kp_u_Inverse_tangent_of_multivector) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20136  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_tanh_line_1786, __pyx_kp_u_Hyperbolic_tangent_of_multivect) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20137  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_atanh_line_1798, __pyx_kp_u_Inverse_hyperbolic_tangent_of_m) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20138  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_random_clifford_line_1815, __pyx_kp_u_Random_multivector_within_a_fra) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20139  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_cga3_line_1824, __pyx_kp_u_Convert_Euclidean_3D_multivecto) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20140  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_cga3std_line_1833, __pyx_kp_u_Convert_CGA3_null_vector_to_sta) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20141  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_agc3_line_1844, __pyx_kp_u_Convert_CGA3_null_vector_to_Euc) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20142  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_e_line_1887, __pyx_kp_u_Abbreviation_for_clifford_index) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20143  if (PyDict_SetItem(__pyx_t_2, __pyx_kp_u_istpq_line_1900, __pyx_kp_u_Abbreviation_for_index_set_q_p) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20144  if (PyDict_SetItem(__pyx_d, __pyx_n_s_test_2, __pyx_t_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
20145  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
20146 
20147  /*--- Wrapped vars code ---*/
20148 
20149  goto __pyx_L0;
20150  __pyx_L1_error:;
20151  __Pyx_XDECREF(__pyx_t_1);
20152  __Pyx_XDECREF(__pyx_t_2);
20153  __Pyx_XDECREF(__pyx_t_3);
20154  if (__pyx_m) {
20155  if (__pyx_d) {
20156  __Pyx_AddTraceback("init PyClical", __pyx_clineno, __pyx_lineno, __pyx_filename);
20157  }
20158  Py_DECREF(__pyx_m); __pyx_m = 0;
20159  } else if (!PyErr_Occurred()) {
20160  PyErr_SetString(PyExc_ImportError, "init PyClical");
20161  }
20162  __pyx_L0:;
20163  __Pyx_RefNannyFinishContext();
20164  #if PY_MAJOR_VERSION < 3
20165  return;
20166  #else
20167  return __pyx_m;
20168  #endif
20169 }
20170 
20171 /* --- Runtime support code --- */
20172 #if CYTHON_REFNANNY
20173 static __Pyx_RefNannyAPIStruct *__Pyx_RefNannyImportAPI(const char *modname) {
20174  PyObject *m = NULL, *p = NULL;
20175  void *r = NULL;
20176  m = PyImport_ImportModule((char *)modname);
20177  if (!m) goto end;
20178  p = PyObject_GetAttrString(m, (char *)"RefNannyAPI");
20179  if (!p) goto end;
20180  r = PyLong_AsVoidPtr(p);
20181 end:
20182  Py_XDECREF(p);
20183  Py_XDECREF(m);
20184  return (__Pyx_RefNannyAPIStruct *)r;
20185 }
20186 #endif
20187 
20188 static PyObject *__Pyx_GetBuiltinName(PyObject *name) {
20189  PyObject* result = __Pyx_PyObject_GetAttrStr(__pyx_b, name);
20190  if (unlikely(!result)) {
20191  PyErr_Format(PyExc_NameError,
20192 #if PY_MAJOR_VERSION >= 3
20193  "name '%U' is not defined", name);
20194 #else
20195  "name '%.200s' is not defined", PyString_AS_STRING(name));
20196 #endif
20197  }
20198  return result;
20199 }
20200 
20201 #if CYTHON_COMPILING_IN_CPYTHON
20202 static CYTHON_INLINE PyObject* __Pyx_PyObject_Call(PyObject *func, PyObject *arg, PyObject *kw) {
20203  PyObject *result;
20204  ternaryfunc call = func->ob_type->tp_call;
20205  if (unlikely(!call))
20206  return PyObject_Call(func, arg, kw);
20207  if (unlikely(Py_EnterRecursiveCall((char*)" while calling a Python object")))
20208  return NULL;
20209  result = (*call)(func, arg, kw);
20210  Py_LeaveRecursiveCall();
20211  if (unlikely(!result) && unlikely(!PyErr_Occurred())) {
20212  PyErr_SetString(
20213  PyExc_SystemError,
20214  "NULL result without error in PyObject_Call");
20215  }
20216  return result;
20217 }
20218 #endif
20219 
20220 static CYTHON_INLINE void __Pyx_ErrRestore(PyObject *type, PyObject *value, PyObject *tb) {
20221 #if CYTHON_COMPILING_IN_CPYTHON
20222  PyObject *tmp_type, *tmp_value, *tmp_tb;
20223  PyThreadState *tstate = PyThreadState_GET();
20224  tmp_type = tstate->curexc_type;
20225  tmp_value = tstate->curexc_value;
20226  tmp_tb = tstate->curexc_traceback;
20227  tstate->curexc_type = type;
20228  tstate->curexc_value = value;
20229  tstate->curexc_traceback = tb;
20230  Py_XDECREF(tmp_type);
20231  Py_XDECREF(tmp_value);
20232  Py_XDECREF(tmp_tb);
20233 #else
20234  PyErr_Restore(type, value, tb);
20235 #endif
20236 }
20237 static CYTHON_INLINE void __Pyx_ErrFetch(PyObject **type, PyObject **value, PyObject **tb) {
20238 #if CYTHON_COMPILING_IN_CPYTHON
20239  PyThreadState *tstate = PyThreadState_GET();
20240  *type = tstate->curexc_type;
20241  *value = tstate->curexc_value;
20242  *tb = tstate->curexc_traceback;
20243  tstate->curexc_type = 0;
20244  tstate->curexc_value = 0;
20245  tstate->curexc_traceback = 0;
20246 #else
20247  PyErr_Fetch(type, value, tb);
20248 #endif
20249 }
20250 
20251 static void __Pyx_WriteUnraisable(const char *name, CYTHON_UNUSED int clineno,
20252  CYTHON_UNUSED int lineno, CYTHON_UNUSED const char *filename,
20253  int full_traceback, CYTHON_UNUSED int nogil) {
20254  PyObject *old_exc, *old_val, *old_tb;
20255  PyObject *ctx;
20256 #ifdef WITH_THREAD
20257  PyGILState_STATE state;
20258  if (nogil)
20259  state = PyGILState_Ensure();
20260 #endif
20261  __Pyx_ErrFetch(&old_exc, &old_val, &old_tb);
20262  if (full_traceback) {
20263  Py_XINCREF(old_exc);
20264  Py_XINCREF(old_val);
20265  Py_XINCREF(old_tb);
20266  __Pyx_ErrRestore(old_exc, old_val, old_tb);
20267  PyErr_PrintEx(1);
20268  }
20269  #if PY_MAJOR_VERSION < 3
20270  ctx = PyString_FromString(name);
20271  #else
20272  ctx = PyUnicode_FromString(name);
20273  #endif
20274  __Pyx_ErrRestore(old_exc, old_val, old_tb);
20275  if (!ctx) {
20276  PyErr_WriteUnraisable(Py_None);
20277  } else {
20278  PyErr_WriteUnraisable(ctx);
20279  Py_DECREF(ctx);
20280  }
20281 #ifdef WITH_THREAD
20282  if (nogil)
20283  PyGILState_Release(state);
20284 #endif
20285 }
20286 
20287 #if CYTHON_COMPILING_IN_CPYTHON
20288 static CYTHON_INLINE PyObject* __Pyx_PyObject_CallMethO(PyObject *func, PyObject *arg) {
20289  PyObject *self, *result;
20290  PyCFunction cfunc;
20291  cfunc = PyCFunction_GET_FUNCTION(func);
20292  self = PyCFunction_GET_SELF(func);
20293  if (unlikely(Py_EnterRecursiveCall((char*)" while calling a Python object")))
20294  return NULL;
20295  result = cfunc(self, arg);
20296  Py_LeaveRecursiveCall();
20297  if (unlikely(!result) && unlikely(!PyErr_Occurred())) {
20298  PyErr_SetString(
20299  PyExc_SystemError,
20300  "NULL result without error in PyObject_Call");
20301  }
20302  return result;
20303 }
20304 #endif
20305 
20306 #if CYTHON_COMPILING_IN_CPYTHON
20307 static PyObject* __Pyx__PyObject_CallOneArg(PyObject *func, PyObject *arg) {
20308  PyObject *result;
20309  PyObject *args = PyTuple_New(1);
20310  if (unlikely(!args)) return NULL;
20311  Py_INCREF(arg);
20312  PyTuple_SET_ITEM(args, 0, arg);
20313  result = __Pyx_PyObject_Call(func, args, NULL);
20314  Py_DECREF(args);
20315  return result;
20316 }
20317 static CYTHON_INLINE PyObject* __Pyx_PyObject_CallOneArg(PyObject *func, PyObject *arg) {
20318 #ifdef __Pyx_CyFunction_USED
20319  if (likely(PyCFunction_Check(func) || PyObject_TypeCheck(func, __pyx_CyFunctionType))) {
20320 #else
20321  if (likely(PyCFunction_Check(func))) {
20322 #endif
20323  if (likely(PyCFunction_GET_FLAGS(func) & METH_O)) {
20324  return __Pyx_PyObject_CallMethO(func, arg);
20325  }
20326  }
20327  return __Pyx__PyObject_CallOneArg(func, arg);
20328 }
20329 #else
20330 static CYTHON_INLINE PyObject* __Pyx_PyObject_CallOneArg(PyObject *func, PyObject *arg) {
20331  PyObject *result;
20332  PyObject *args = PyTuple_Pack(1, arg);
20333  if (unlikely(!args)) return NULL;
20334  result = __Pyx_PyObject_Call(func, args, NULL);
20335  Py_DECREF(args);
20336  return result;
20337 }
20338 #endif
20339 
20340 #if CYTHON_COMPILING_IN_CPYTHON
20341 static CYTHON_INLINE PyObject* __Pyx_PyObject_CallNoArg(PyObject *func) {
20342 #ifdef __Pyx_CyFunction_USED
20343  if (likely(PyCFunction_Check(func) || PyObject_TypeCheck(func, __pyx_CyFunctionType))) {
20344 #else
20345  if (likely(PyCFunction_Check(func))) {
20346 #endif
20347  if (likely(PyCFunction_GET_FLAGS(func) & METH_NOARGS)) {
20348  return __Pyx_PyObject_CallMethO(func, NULL);
20349  }
20350  }
20351  return __Pyx_PyObject_Call(func, __pyx_empty_tuple, NULL);
20352 }
20353 #endif
20354 
20355 static void __Pyx_RaiseDoubleKeywordsError(
20356  const char* func_name,
20357  PyObject* kw_name)
20358 {
20359  PyErr_Format(PyExc_TypeError,
20360  #if PY_MAJOR_VERSION >= 3
20361  "%s() got multiple values for keyword argument '%U'", func_name, kw_name);
20362  #else
20363  "%s() got multiple values for keyword argument '%s'", func_name,
20364  PyString_AsString(kw_name));
20365  #endif
20366 }
20367 
20368 static int __Pyx_ParseOptionalKeywords(
20369  PyObject *kwds,
20370  PyObject **argnames[],
20371  PyObject *kwds2,
20372  PyObject *values[],
20373  Py_ssize_t num_pos_args,
20374  const char* function_name)
20375 {
20376  PyObject *key = 0, *value = 0;
20377  Py_ssize_t pos = 0;
20378  PyObject*** name;
20379  PyObject*** first_kw_arg = argnames + num_pos_args;
20380  while (PyDict_Next(kwds, &pos, &key, &value)) {
20381  name = first_kw_arg;
20382  while (*name && (**name != key)) name++;
20383  if (*name) {
20384  values[name-argnames] = value;
20385  continue;
20386  }
20387  name = first_kw_arg;
20388  #if PY_MAJOR_VERSION < 3
20389  if (likely(PyString_CheckExact(key)) || likely(PyString_Check(key))) {
20390  while (*name) {
20391  if ((CYTHON_COMPILING_IN_PYPY || PyString_GET_SIZE(**name) == PyString_GET_SIZE(key))
20392  && _PyString_Eq(**name, key)) {
20393  values[name-argnames] = value;
20394  break;
20395  }
20396  name++;
20397  }
20398  if (*name) continue;
20399  else {
20400  PyObject*** argname = argnames;
20401  while (argname != first_kw_arg) {
20402  if ((**argname == key) || (
20403  (CYTHON_COMPILING_IN_PYPY || PyString_GET_SIZE(**argname) == PyString_GET_SIZE(key))
20404  && _PyString_Eq(**argname, key))) {
20405  goto arg_passed_twice;
20406  }
20407  argname++;
20408  }
20409  }
20410  } else
20411  #endif
20412  if (likely(PyUnicode_Check(key))) {
20413  while (*name) {
20414  int cmp = (**name == key) ? 0 :
20415  #if !CYTHON_COMPILING_IN_PYPY && PY_MAJOR_VERSION >= 3
20416  (PyUnicode_GET_SIZE(**name) != PyUnicode_GET_SIZE(key)) ? 1 :
20417  #endif
20418  PyUnicode_Compare(**name, key);
20419  if (cmp < 0 && unlikely(PyErr_Occurred())) goto bad;
20420  if (cmp == 0) {
20421  values[name-argnames] = value;
20422  break;
20423  }
20424  name++;
20425  }
20426  if (*name) continue;
20427  else {
20428  PyObject*** argname = argnames;
20429  while (argname != first_kw_arg) {
20430  int cmp = (**argname == key) ? 0 :
20431  #if !CYTHON_COMPILING_IN_PYPY && PY_MAJOR_VERSION >= 3
20432  (PyUnicode_GET_SIZE(**argname) != PyUnicode_GET_SIZE(key)) ? 1 :
20433  #endif
20434  PyUnicode_Compare(**argname, key);
20435  if (cmp < 0 && unlikely(PyErr_Occurred())) goto bad;
20436  if (cmp == 0) goto arg_passed_twice;
20437  argname++;
20438  }
20439  }
20440  } else
20441  goto invalid_keyword_type;
20442  if (kwds2) {
20443  if (unlikely(PyDict_SetItem(kwds2, key, value))) goto bad;
20444  } else {
20445  goto invalid_keyword;
20446  }
20447  }
20448  return 0;
20449 arg_passed_twice:
20450  __Pyx_RaiseDoubleKeywordsError(function_name, key);
20451  goto bad;
20452 invalid_keyword_type:
20453  PyErr_Format(PyExc_TypeError,
20454  "%.200s() keywords must be strings", function_name);
20455  goto bad;
20456 invalid_keyword:
20457  PyErr_Format(PyExc_TypeError,
20458  #if PY_MAJOR_VERSION < 3
20459  "%.200s() got an unexpected keyword argument '%.200s'",
20460  function_name, PyString_AsString(key));
20461  #else
20462  "%s() got an unexpected keyword argument '%U'",
20463  function_name, key);
20464  #endif
20465 bad:
20466  return -1;
20467 }
20468 
20469 static void __Pyx_RaiseArgtupleInvalid(
20470  const char* func_name,
20471  int exact,
20472  Py_ssize_t num_min,
20473  Py_ssize_t num_max,
20474  Py_ssize_t num_found)
20475 {
20476  Py_ssize_t num_expected;
20477  const char *more_or_less;
20478  if (num_found < num_min) {
20479  num_expected = num_min;
20480  more_or_less = "at least";
20481  } else {
20482  num_expected = num_max;
20483  more_or_less = "at most";
20484  }
20485  if (exact) {
20486  more_or_less = "exactly";
20487  }
20488  PyErr_Format(PyExc_TypeError,
20489  "%.200s() takes %.8s %" CYTHON_FORMAT_SSIZE_T "d positional argument%.1s (%" CYTHON_FORMAT_SSIZE_T "d given)",
20490  func_name, more_or_less, num_expected,
20491  (num_expected == 1) ? "" : "s", num_found);
20492 }
20493 
20494 static CYTHON_INLINE PyObject *__Pyx_GetModuleGlobalName(PyObject *name) {
20495  PyObject *result;
20496 #if CYTHON_COMPILING_IN_CPYTHON
20497  result = PyDict_GetItem(__pyx_d, name);
20498  if (likely(result)) {
20499  Py_INCREF(result);
20500  } else {
20501 #else
20502  result = PyObject_GetItem(__pyx_d, name);
20503  if (!result) {
20504  PyErr_Clear();
20505 #endif
20506  result = __Pyx_GetBuiltinName(name);
20507  }
20508  return result;
20509 }
20510 
20511 static CYTHON_INLINE void __Pyx_ExceptionSave(PyObject **type, PyObject **value, PyObject **tb) {
20512 #if CYTHON_COMPILING_IN_CPYTHON
20513  PyThreadState *tstate = PyThreadState_GET();
20514  *type = tstate->exc_type;
20515  *value = tstate->exc_value;
20516  *tb = tstate->exc_traceback;
20517  Py_XINCREF(*type);
20518  Py_XINCREF(*value);
20519  Py_XINCREF(*tb);
20520 #else
20521  PyErr_GetExcInfo(type, value, tb);
20522 #endif
20523 }
20524 static void __Pyx_ExceptionReset(PyObject *type, PyObject *value, PyObject *tb) {
20525 #if CYTHON_COMPILING_IN_CPYTHON
20526  PyObject *tmp_type, *tmp_value, *tmp_tb;
20527  PyThreadState *tstate = PyThreadState_GET();
20528  tmp_type = tstate->exc_type;
20529  tmp_value = tstate->exc_value;
20530  tmp_tb = tstate->exc_traceback;
20531  tstate->exc_type = type;
20532  tstate->exc_value = value;
20533  tstate->exc_traceback = tb;
20534  Py_XDECREF(tmp_type);
20535  Py_XDECREF(tmp_value);
20536  Py_XDECREF(tmp_tb);
20537 #else
20538  PyErr_SetExcInfo(type, value, tb);
20539 #endif
20540 }
20541 
20542 static int __Pyx_GetException(PyObject **type, PyObject **value, PyObject **tb) {
20543  PyObject *local_type, *local_value, *local_tb;
20544 #if CYTHON_COMPILING_IN_CPYTHON
20545  PyObject *tmp_type, *tmp_value, *tmp_tb;
20546  PyThreadState *tstate = PyThreadState_GET();
20547  local_type = tstate->curexc_type;
20548  local_value = tstate->curexc_value;
20549  local_tb = tstate->curexc_traceback;
20550  tstate->curexc_type = 0;
20551  tstate->curexc_value = 0;
20552  tstate->curexc_traceback = 0;
20553 #else
20554  PyErr_Fetch(&local_type, &local_value, &local_tb);
20555 #endif
20556  PyErr_NormalizeException(&local_type, &local_value, &local_tb);
20557 #if CYTHON_COMPILING_IN_CPYTHON
20558  if (unlikely(tstate->curexc_type))
20559 #else
20560  if (unlikely(PyErr_Occurred()))
20561 #endif
20562  goto bad;
20563  #if PY_MAJOR_VERSION >= 3
20564  if (local_tb) {
20565  if (unlikely(PyException_SetTraceback(local_value, local_tb) < 0))
20566  goto bad;
20567  }
20568  #endif
20569  Py_XINCREF(local_tb);
20570  Py_XINCREF(local_type);
20571  Py_XINCREF(local_value);
20572  *type = local_type;
20573  *value = local_value;
20574  *tb = local_tb;
20575 #if CYTHON_COMPILING_IN_CPYTHON
20576  tmp_type = tstate->exc_type;
20577  tmp_value = tstate->exc_value;
20578  tmp_tb = tstate->exc_traceback;
20579  tstate->exc_type = local_type;
20580  tstate->exc_value = local_value;
20581  tstate->exc_traceback = local_tb;
20582  Py_XDECREF(tmp_type);
20583  Py_XDECREF(tmp_value);
20584  Py_XDECREF(tmp_tb);
20585 #else
20586  PyErr_SetExcInfo(local_type, local_value, local_tb);
20587 #endif
20588  return 0;
20589 bad:
20590  *type = 0;
20591  *value = 0;
20592  *tb = 0;
20593  Py_XDECREF(local_type);
20594  Py_XDECREF(local_value);
20595  Py_XDECREF(local_tb);
20596  return -1;
20597 }
20598 
20599 #if PY_MAJOR_VERSION < 3
20600 static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb,
20601  CYTHON_UNUSED PyObject *cause) {
20602  Py_XINCREF(type);
20603  if (!value || value == Py_None)
20604  value = NULL;
20605  else
20606  Py_INCREF(value);
20607  if (!tb || tb == Py_None)
20608  tb = NULL;
20609  else {
20610  Py_INCREF(tb);
20611  if (!PyTraceBack_Check(tb)) {
20612  PyErr_SetString(PyExc_TypeError,
20613  "raise: arg 3 must be a traceback or None");
20614  goto raise_error;
20615  }
20616  }
20617  if (PyType_Check(type)) {
20618 #if CYTHON_COMPILING_IN_PYPY
20619  if (!value) {
20620  Py_INCREF(Py_None);
20621  value = Py_None;
20622  }
20623 #endif
20624  PyErr_NormalizeException(&type, &value, &tb);
20625  } else {
20626  if (value) {
20627  PyErr_SetString(PyExc_TypeError,
20628  "instance exception may not have a separate value");
20629  goto raise_error;
20630  }
20631  value = type;
20632  type = (PyObject*) Py_TYPE(type);
20633  Py_INCREF(type);
20634  if (!PyType_IsSubtype((PyTypeObject *)type, (PyTypeObject *)PyExc_BaseException)) {
20635  PyErr_SetString(PyExc_TypeError,
20636  "raise: exception class must be a subclass of BaseException");
20637  goto raise_error;
20638  }
20639  }
20640  __Pyx_ErrRestore(type, value, tb);
20641  return;
20642 raise_error:
20643  Py_XDECREF(value);
20644  Py_XDECREF(type);
20645  Py_XDECREF(tb);
20646  return;
20647 }
20648 #else
20649 static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb, PyObject *cause) {
20650  PyObject* owned_instance = NULL;
20651  if (tb == Py_None) {
20652  tb = 0;
20653  } else if (tb && !PyTraceBack_Check(tb)) {
20654  PyErr_SetString(PyExc_TypeError,
20655  "raise: arg 3 must be a traceback or None");
20656  goto bad;
20657  }
20658  if (value == Py_None)
20659  value = 0;
20660  if (PyExceptionInstance_Check(type)) {
20661  if (value) {
20662  PyErr_SetString(PyExc_TypeError,
20663  "instance exception may not have a separate value");
20664  goto bad;
20665  }
20666  value = type;
20667  type = (PyObject*) Py_TYPE(value);
20668  } else if (PyExceptionClass_Check(type)) {
20669  PyObject *instance_class = NULL;
20670  if (value && PyExceptionInstance_Check(value)) {
20671  instance_class = (PyObject*) Py_TYPE(value);
20672  if (instance_class != type) {
20673  int is_subclass = PyObject_IsSubclass(instance_class, type);
20674  if (!is_subclass) {
20675  instance_class = NULL;
20676  } else if (unlikely(is_subclass == -1)) {
20677  goto bad;
20678  } else {
20679  type = instance_class;
20680  }
20681  }
20682  }
20683  if (!instance_class) {
20684  PyObject *args;
20685  if (!value)
20686  args = PyTuple_New(0);
20687  else if (PyTuple_Check(value)) {
20688  Py_INCREF(value);
20689  args = value;
20690  } else
20691  args = PyTuple_Pack(1, value);
20692  if (!args)
20693  goto bad;
20694  owned_instance = PyObject_Call(type, args, NULL);
20695  Py_DECREF(args);
20696  if (!owned_instance)
20697  goto bad;
20698  value = owned_instance;
20699  if (!PyExceptionInstance_Check(value)) {
20700  PyErr_Format(PyExc_TypeError,
20701  "calling %R should have returned an instance of "
20702  "BaseException, not %R",
20703  type, Py_TYPE(value));
20704  goto bad;
20705  }
20706  }
20707  } else {
20708  PyErr_SetString(PyExc_TypeError,
20709  "raise: exception class must be a subclass of BaseException");
20710  goto bad;
20711  }
20712 #if PY_VERSION_HEX >= 0x03030000
20713  if (cause) {
20714 #else
20715  if (cause && cause != Py_None) {
20716 #endif
20717  PyObject *fixed_cause;
20718  if (cause == Py_None) {
20719  fixed_cause = NULL;
20720  } else if (PyExceptionClass_Check(cause)) {
20721  fixed_cause = PyObject_CallObject(cause, NULL);
20722  if (fixed_cause == NULL)
20723  goto bad;
20724  } else if (PyExceptionInstance_Check(cause)) {
20725  fixed_cause = cause;
20726  Py_INCREF(fixed_cause);
20727  } else {
20728  PyErr_SetString(PyExc_TypeError,
20729  "exception causes must derive from "
20730  "BaseException");
20731  goto bad;
20732  }
20733  PyException_SetCause(value, fixed_cause);
20734  }
20735  PyErr_SetObject(type, value);
20736  if (tb) {
20737 #if CYTHON_COMPILING_IN_PYPY
20738  PyObject *tmp_type, *tmp_value, *tmp_tb;
20739  PyErr_Fetch(&tmp_type, &tmp_value, &tmp_tb);
20740  Py_INCREF(tb);
20741  PyErr_Restore(tmp_type, tmp_value, tb);
20742  Py_XDECREF(tmp_tb);
20743 #else
20744  PyThreadState *tstate = PyThreadState_GET();
20745  PyObject* tmp_tb = tstate->curexc_traceback;
20746  if (tb != tmp_tb) {
20747  Py_INCREF(tb);
20748  tstate->curexc_traceback = tb;
20749  Py_XDECREF(tmp_tb);
20750  }
20751 #endif
20752  }
20753 bad:
20754  Py_XDECREF(owned_instance);
20755  return;
20756 }
20757 #endif
20758 
20759 #if CYTHON_USE_PYLONG_INTERNALS
20760  #include "longintrepr.h"
20761 #endif
20762 
20763 #if CYTHON_COMPILING_IN_CPYTHON
20764 static PyObject* __Pyx_PyInt_AddObjC(PyObject *op1, PyObject *op2, CYTHON_UNUSED long intval, CYTHON_UNUSED int inplace) {
20765  #if PY_MAJOR_VERSION < 3
20766  if (likely(PyInt_CheckExact(op1))) {
20767  const long b = intval;
20768  long x;
20769  long a = PyInt_AS_LONG(op1);
20770  x = (long)((unsigned long)a + b);
20771  if (likely((x^a) >= 0 || (x^b) >= 0))
20772  return PyInt_FromLong(x);
20773  return PyLong_Type.tp_as_number->nb_add(op1, op2);
20774  }
20775  #endif
20776  #if CYTHON_USE_PYLONG_INTERNALS && PY_MAJOR_VERSION >= 3
20777  if (likely(PyLong_CheckExact(op1))) {
20778  const long b = intval;
20779  long a, x;
20780  const PY_LONG_LONG llb = intval;
20781  PY_LONG_LONG lla, llx;
20782  const digit* digits = ((PyLongObject*)op1)->ob_digit;
20783  const Py_ssize_t size = Py_SIZE(op1);
20784  if (likely(__Pyx_sst_abs(size) <= 1)) {
20785  a = likely(size) ? digits[0] : 0;
20786  if (size == -1) a = -a;
20787  } else {
20788  switch (size) {
20789  case -2:
20790  if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) {
20791  a = -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]));
20792  break;
20793  } else if (8 * sizeof(PY_LONG_LONG) - 1 > 2 * PyLong_SHIFT) {
20794  lla = -(PY_LONG_LONG) (((((unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[0]));
20795  goto long_long;
20796  }
20797  case 2:
20798  if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) {
20799  a = (long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]));
20800  break;
20801  } else if (8 * sizeof(PY_LONG_LONG) - 1 > 2 * PyLong_SHIFT) {
20802  lla = (PY_LONG_LONG) (((((unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[0]));
20803  goto long_long;
20804  }
20805  case -3:
20806  if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) {
20807  a = -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]));
20808  break;
20809  } else if (8 * sizeof(PY_LONG_LONG) - 1 > 3 * PyLong_SHIFT) {
20810  lla = -(PY_LONG_LONG) (((((((unsigned PY_LONG_LONG)digits[2]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[0]));
20811  goto long_long;
20812  }
20813  case 3:
20814  if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) {
20815  a = (long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]));
20816  break;
20817  } else if (8 * sizeof(PY_LONG_LONG) - 1 > 3 * PyLong_SHIFT) {
20818  lla = (PY_LONG_LONG) (((((((unsigned PY_LONG_LONG)digits[2]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[0]));
20819  goto long_long;
20820  }
20821  case -4:
20822  if (8 * sizeof(long) - 1 > 4 * PyLong_SHIFT) {
20823  a = -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]));
20824  break;
20825  } else if (8 * sizeof(PY_LONG_LONG) - 1 > 4 * PyLong_SHIFT) {
20826  lla = -(PY_LONG_LONG) (((((((((unsigned PY_LONG_LONG)digits[3]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[2]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[0]));
20827  goto long_long;
20828  }
20829  case 4:
20830  if (8 * sizeof(long) - 1 > 4 * PyLong_SHIFT) {
20831  a = (long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]));
20832  break;
20833  } else if (8 * sizeof(PY_LONG_LONG) - 1 > 4 * PyLong_SHIFT) {
20834  lla = (PY_LONG_LONG) (((((((((unsigned PY_LONG_LONG)digits[3]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[2]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[0]));
20835  goto long_long;
20836  }
20837  default: return PyLong_Type.tp_as_number->nb_add(op1, op2);
20838  }
20839  }
20840  x = a + b;
20841  return PyLong_FromLong(x);
20842  long_long:
20843  llx = lla + llb;
20844  return PyLong_FromLongLong(llx);
20845  }
20846  #endif
20847  if (PyFloat_CheckExact(op1)) {
20848  const long b = intval;
20849  double a = PyFloat_AS_DOUBLE(op1);
20850  double result;
20851  PyFPE_START_PROTECT("add", return NULL)
20852  result = ((double)a) + (double)b;
20853  PyFPE_END_PROTECT(result)
20854  return PyFloat_FromDouble(result);
20855  }
20856  return (inplace ? PyNumber_InPlaceAdd : PyNumber_Add)(op1, op2);
20857 }
20858 #endif
20859 
20860 static CYTHON_INLINE int __Pyx_SetItemInt_Generic(PyObject *o, PyObject *j, PyObject *v) {
20861  int r;
20862  if (!j) return -1;
20863  r = PyObject_SetItem(o, j, v);
20864  Py_DECREF(j);
20865  return r;
20866 }
20867 static CYTHON_INLINE int __Pyx_SetItemInt_Fast(PyObject *o, Py_ssize_t i, PyObject *v, int is_list,
20868  CYTHON_NCP_UNUSED int wraparound, CYTHON_NCP_UNUSED int boundscheck) {
20869 #if CYTHON_COMPILING_IN_CPYTHON
20870  if (is_list || PyList_CheckExact(o)) {
20871  Py_ssize_t n = (!wraparound) ? i : ((likely(i >= 0)) ? i : i + PyList_GET_SIZE(o));
20872  if ((!boundscheck) || likely((n >= 0) & (n < PyList_GET_SIZE(o)))) {
20873  PyObject* old = PyList_GET_ITEM(o, n);
20874  Py_INCREF(v);
20875  PyList_SET_ITEM(o, n, v);
20876  Py_DECREF(old);
20877  return 1;
20878  }
20879  } else {
20880  PySequenceMethods *m = Py_TYPE(o)->tp_as_sequence;
20881  if (likely(m && m->sq_ass_item)) {
20882  if (wraparound && unlikely(i < 0) && likely(m->sq_length)) {
20883  Py_ssize_t l = m->sq_length(o);
20884  if (likely(l >= 0)) {
20885  i += l;
20886  } else {
20887  if (PyErr_ExceptionMatches(PyExc_OverflowError))
20888  PyErr_Clear();
20889  else
20890  return -1;
20891  }
20892  }
20893  return m->sq_ass_item(o, i, v);
20894  }
20895  }
20896 #else
20897 #if CYTHON_COMPILING_IN_PYPY
20898  if (is_list || (PySequence_Check(o) && !PyDict_Check(o))) {
20899 #else
20900  if (is_list || PySequence_Check(o)) {
20901 #endif
20902  return PySequence_SetItem(o, i, v);
20903  }
20904 #endif
20905  return __Pyx_SetItemInt_Generic(o, PyInt_FromSsize_t(i), v);
20906 }
20907 
20908 static void __Pyx_RaiseArgumentTypeInvalid(const char* name, PyObject *obj, PyTypeObject *type) {
20909  PyErr_Format(PyExc_TypeError,
20910  "Argument '%.200s' has incorrect type (expected %.200s, got %.200s)",
20911  name, type->tp_name, Py_TYPE(obj)->tp_name);
20912 }
20913 static CYTHON_INLINE int __Pyx_ArgTypeTest(PyObject *obj, PyTypeObject *type, int none_allowed,
20914  const char *name, int exact)
20915 {
20916  if (unlikely(!type)) {
20917  PyErr_SetString(PyExc_SystemError, "Missing type object");
20918  return 0;
20919  }
20920  if (none_allowed && obj == Py_None) return 1;
20921  else if (exact) {
20922  if (likely(Py_TYPE(obj) == type)) return 1;
20923  #if PY_MAJOR_VERSION == 2
20924  else if ((type == &PyBaseString_Type) && likely(__Pyx_PyBaseString_CheckExact(obj))) return 1;
20925  #endif
20926  }
20927  else {
20928  if (likely(PyObject_TypeCheck(obj, type))) return 1;
20929  }
20930  __Pyx_RaiseArgumentTypeInvalid(name, obj, type);
20931  return 0;
20932 }
20933 
20934 static PyObject *__Pyx_Import(PyObject *name, PyObject *from_list, int level) {
20935  PyObject *empty_list = 0;
20936  PyObject *module = 0;
20937  PyObject *global_dict = 0;
20938  PyObject *empty_dict = 0;
20939  PyObject *list;
20940  #if PY_VERSION_HEX < 0x03030000
20941  PyObject *py_import;
20942  py_import = __Pyx_PyObject_GetAttrStr(__pyx_b, __pyx_n_s_import);
20943  if (!py_import)
20944  goto bad;
20945  #endif
20946  if (from_list)
20947  list = from_list;
20948  else {
20949  empty_list = PyList_New(0);
20950  if (!empty_list)
20951  goto bad;
20952  list = empty_list;
20953  }
20954  global_dict = PyModule_GetDict(__pyx_m);
20955  if (!global_dict)
20956  goto bad;
20957  empty_dict = PyDict_New();
20958  if (!empty_dict)
20959  goto bad;
20960  {
20961  #if PY_MAJOR_VERSION >= 3
20962  if (level == -1) {
20963  if (strchr(__Pyx_MODULE_NAME, '.')) {
20964  #if PY_VERSION_HEX < 0x03030000
20965  PyObject *py_level = PyInt_FromLong(1);
20966  if (!py_level)
20967  goto bad;
20968  module = PyObject_CallFunctionObjArgs(py_import,
20969  name, global_dict, empty_dict, list, py_level, NULL);
20970  Py_DECREF(py_level);
20971  #else
20972  module = PyImport_ImportModuleLevelObject(
20973  name, global_dict, empty_dict, list, 1);
20974  #endif
20975  if (!module) {
20976  if (!PyErr_ExceptionMatches(PyExc_ImportError))
20977  goto bad;
20978  PyErr_Clear();
20979  }
20980  }
20981  level = 0;
20982  }
20983  #endif
20984  if (!module) {
20985  #if PY_VERSION_HEX < 0x03030000
20986  PyObject *py_level = PyInt_FromLong(level);
20987  if (!py_level)
20988  goto bad;
20989  module = PyObject_CallFunctionObjArgs(py_import,
20990  name, global_dict, empty_dict, list, py_level, NULL);
20991  Py_DECREF(py_level);
20992  #else
20993  module = PyImport_ImportModuleLevelObject(
20994  name, global_dict, empty_dict, list, level);
20995  #endif
20996  }
20997  }
20998 bad:
20999  #if PY_VERSION_HEX < 0x03030000
21000  Py_XDECREF(py_import);
21001  #endif
21002  Py_XDECREF(empty_list);
21003  Py_XDECREF(empty_dict);
21004  return module;
21005 }
21006 
21007 static int __Pyx_SetVtable(PyObject *dict, void *vtable) {
21008 #if PY_VERSION_HEX >= 0x02070000
21009  PyObject *ob = PyCapsule_New(vtable, 0, 0);
21010 #else
21011  PyObject *ob = PyCObject_FromVoidPtr(vtable, 0);
21012 #endif
21013  if (!ob)
21014  goto bad;
21015  if (PyDict_SetItem(dict, __pyx_n_s_pyx_vtable, ob) < 0)
21016  goto bad;
21017  Py_DECREF(ob);
21018  return 0;
21019 bad:
21020  Py_XDECREF(ob);
21021  return -1;
21022 }
21023 
21024 #if CYTHON_COMPILING_IN_CPYTHON
21025 static PyObject* __Pyx_PyFloat_DivideObjC(PyObject *op1, PyObject *op2, double floatval, CYTHON_UNUSED int inplace) {
21026  const double b = floatval;
21027  double a, result;
21028  if (likely(PyFloat_CheckExact(op1))) {
21029  a = PyFloat_AS_DOUBLE(op1);
21030  } else
21031  #if PY_MAJOR_VERSION < 3
21032  if (likely(PyInt_CheckExact(op1))) {
21033  a = (double) PyInt_AS_LONG(op1);
21034  } else
21035  #endif
21036  if (likely(PyLong_CheckExact(op1))) {
21037  #if CYTHON_USE_PYLONG_INTERNALS && PY_MAJOR_VERSION >= 3
21038  const digit* digits = ((PyLongObject*)op1)->ob_digit;
21039  const Py_ssize_t size = Py_SIZE(op1);
21040  switch (size) {
21041  case 0: a = 0.0; break;
21042  case -1: a = -(double) digits[0]; break;
21043  case 1: a = (double) digits[0]; break;
21044  case -2:
21045  case 2:
21046  if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT && ((8 * sizeof(unsigned long) < 53) || (1 * PyLong_SHIFT < 53))) {
21047  a = (double) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]));
21048  if ((8 * sizeof(unsigned long) < 53) || (2 * PyLong_SHIFT < 53) || (a < (double) (1L<<53))) {
21049  if (size == -2)
21050  a = -a;
21051  break;
21052  }
21053  }
21054  case -3:
21055  case 3:
21056  if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT && ((8 * sizeof(unsigned long) < 53) || (2 * PyLong_SHIFT < 53))) {
21057  a = (double) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]));
21058  if ((8 * sizeof(unsigned long) < 53) || (3 * PyLong_SHIFT < 53) || (a < (double) (1L<<53))) {
21059  if (size == -3)
21060  a = -a;
21061  break;
21062  }
21063  }
21064  case -4:
21065  case 4:
21066  if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT && ((8 * sizeof(unsigned long) < 53) || (3 * PyLong_SHIFT < 53))) {
21067  a = (double) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]));
21068  if ((8 * sizeof(unsigned long) < 53) || (4 * PyLong_SHIFT < 53) || (a < (double) (1L<<53))) {
21069  if (size == -4)
21070  a = -a;
21071  break;
21072  }
21073  }
21074  default:
21075  #else
21076  {
21077  #endif
21078  a = PyLong_AsDouble(op1);
21079  if (unlikely(a == -1.0 && PyErr_Occurred())) return NULL;
21080  }
21081  } else {
21082  return (inplace ? __Pyx_PyNumber_InPlaceDivide(op1, op2) : __Pyx_PyNumber_Divide(op1, op2));
21083  }
21084  PyFPE_START_PROTECT("divide", return NULL)
21085  result = a / b;
21086  PyFPE_END_PROTECT(result)
21087  return PyFloat_FromDouble(result);
21088 }
21089 #endif
21090 
21091 static CYTHON_INLINE int __Pyx_PyBytes_Equals(PyObject* s1, PyObject* s2, int equals) {
21092 #if CYTHON_COMPILING_IN_PYPY
21093  return PyObject_RichCompareBool(s1, s2, equals);
21094 #else
21095  if (s1 == s2) {
21096  return (equals == Py_EQ);
21097  } else if (PyBytes_CheckExact(s1) & PyBytes_CheckExact(s2)) {
21098  const char *ps1, *ps2;
21099  Py_ssize_t length = PyBytes_GET_SIZE(s1);
21100  if (length != PyBytes_GET_SIZE(s2))
21101  return (equals == Py_NE);
21102  ps1 = PyBytes_AS_STRING(s1);
21103  ps2 = PyBytes_AS_STRING(s2);
21104  if (ps1[0] != ps2[0]) {
21105  return (equals == Py_NE);
21106  } else if (length == 1) {
21107  return (equals == Py_EQ);
21108  } else {
21109  int result = memcmp(ps1, ps2, (size_t)length);
21110  return (equals == Py_EQ) ? (result == 0) : (result != 0);
21111  }
21112  } else if ((s1 == Py_None) & PyBytes_CheckExact(s2)) {
21113  return (equals == Py_NE);
21114  } else if ((s2 == Py_None) & PyBytes_CheckExact(s1)) {
21115  return (equals == Py_NE);
21116  } else {
21117  int result;
21118  PyObject* py_result = PyObject_RichCompare(s1, s2, equals);
21119  if (!py_result)
21120  return -1;
21121  result = __Pyx_PyObject_IsTrue(py_result);
21122  Py_DECREF(py_result);
21123  return result;
21124  }
21125 #endif
21126 }
21127 
21128 static CYTHON_INLINE int __Pyx_PyUnicode_Equals(PyObject* s1, PyObject* s2, int equals) {
21129 #if CYTHON_COMPILING_IN_PYPY
21130  return PyObject_RichCompareBool(s1, s2, equals);
21131 #else
21132 #if PY_MAJOR_VERSION < 3
21133  PyObject* owned_ref = NULL;
21134 #endif
21135  int s1_is_unicode, s2_is_unicode;
21136  if (s1 == s2) {
21137  goto return_eq;
21138  }
21139  s1_is_unicode = PyUnicode_CheckExact(s1);
21140  s2_is_unicode = PyUnicode_CheckExact(s2);
21141 #if PY_MAJOR_VERSION < 3
21142  if ((s1_is_unicode & (!s2_is_unicode)) && PyString_CheckExact(s2)) {
21143  owned_ref = PyUnicode_FromObject(s2);
21144  if (unlikely(!owned_ref))
21145  return -1;
21146  s2 = owned_ref;
21147  s2_is_unicode = 1;
21148  } else if ((s2_is_unicode & (!s1_is_unicode)) && PyString_CheckExact(s1)) {
21149  owned_ref = PyUnicode_FromObject(s1);
21150  if (unlikely(!owned_ref))
21151  return -1;
21152  s1 = owned_ref;
21153  s1_is_unicode = 1;
21154  } else if (((!s2_is_unicode) & (!s1_is_unicode))) {
21155  return __Pyx_PyBytes_Equals(s1, s2, equals);
21156  }
21157 #endif
21158  if (s1_is_unicode & s2_is_unicode) {
21159  Py_ssize_t length;
21160  int kind;
21161  void *data1, *data2;
21162  if (unlikely(__Pyx_PyUnicode_READY(s1) < 0) || unlikely(__Pyx_PyUnicode_READY(s2) < 0))
21163  return -1;
21164  length = __Pyx_PyUnicode_GET_LENGTH(s1);
21165  if (length != __Pyx_PyUnicode_GET_LENGTH(s2)) {
21166  goto return_ne;
21167  }
21168  kind = __Pyx_PyUnicode_KIND(s1);
21169  if (kind != __Pyx_PyUnicode_KIND(s2)) {
21170  goto return_ne;
21171  }
21172  data1 = __Pyx_PyUnicode_DATA(s1);
21173  data2 = __Pyx_PyUnicode_DATA(s2);
21174  if (__Pyx_PyUnicode_READ(kind, data1, 0) != __Pyx_PyUnicode_READ(kind, data2, 0)) {
21175  goto return_ne;
21176  } else if (length == 1) {
21177  goto return_eq;
21178  } else {
21179  int result = memcmp(data1, data2, (size_t)(length * kind));
21180  #if PY_MAJOR_VERSION < 3
21181  Py_XDECREF(owned_ref);
21182  #endif
21183  return (equals == Py_EQ) ? (result == 0) : (result != 0);
21184  }
21185  } else if ((s1 == Py_None) & s2_is_unicode) {
21186  goto return_ne;
21187  } else if ((s2 == Py_None) & s1_is_unicode) {
21188  goto return_ne;
21189  } else {
21190  int result;
21191  PyObject* py_result = PyObject_RichCompare(s1, s2, equals);
21192  if (!py_result)
21193  return -1;
21194  result = __Pyx_PyObject_IsTrue(py_result);
21195  Py_DECREF(py_result);
21196  return result;
21197  }
21198 return_eq:
21199  #if PY_MAJOR_VERSION < 3
21200  Py_XDECREF(owned_ref);
21201  #endif
21202  return (equals == Py_EQ);
21203 return_ne:
21204  #if PY_MAJOR_VERSION < 3
21205  Py_XDECREF(owned_ref);
21206  #endif
21207  return (equals == Py_NE);
21208 #endif
21209 }
21210 
21211 static int __pyx_bisect_code_objects(__Pyx_CodeObjectCacheEntry* entries, int count, int code_line) {
21212  int start = 0, mid = 0, end = count - 1;
21213  if (end >= 0 && code_line > entries[end].code_line) {
21214  return count;
21215  }
21216  while (start < end) {
21217  mid = start + (end - start) / 2;
21218  if (code_line < entries[mid].code_line) {
21219  end = mid;
21220  } else if (code_line > entries[mid].code_line) {
21221  start = mid + 1;
21222  } else {
21223  return mid;
21224  }
21225  }
21226  if (code_line <= entries[mid].code_line) {
21227  return mid;
21228  } else {
21229  return mid + 1;
21230  }
21231 }
21232 static PyCodeObject *__pyx_find_code_object(int code_line) {
21233  PyCodeObject* code_object;
21234  int pos;
21235  if (unlikely(!code_line) || unlikely(!__pyx_code_cache.entries)) {
21236  return NULL;
21237  }
21238  pos = __pyx_bisect_code_objects(__pyx_code_cache.entries, __pyx_code_cache.count, code_line);
21239  if (unlikely(pos >= __pyx_code_cache.count) || unlikely(__pyx_code_cache.entries[pos].code_line != code_line)) {
21240  return NULL;
21241  }
21242  code_object = __pyx_code_cache.entries[pos].code_object;
21243  Py_INCREF(code_object);
21244  return code_object;
21245 }
21246 static void __pyx_insert_code_object(int code_line, PyCodeObject* code_object) {
21247  int pos, i;
21248  __Pyx_CodeObjectCacheEntry* entries = __pyx_code_cache.entries;
21249  if (unlikely(!code_line)) {
21250  return;
21251  }
21252  if (unlikely(!entries)) {
21253  entries = (__Pyx_CodeObjectCacheEntry*)PyMem_Malloc(64*sizeof(__Pyx_CodeObjectCacheEntry));
21254  if (likely(entries)) {
21255  __pyx_code_cache.entries = entries;
21256  __pyx_code_cache.max_count = 64;
21257  __pyx_code_cache.count = 1;
21258  entries[0].code_line = code_line;
21259  entries[0].code_object = code_object;
21260  Py_INCREF(code_object);
21261  }
21262  return;
21263  }
21264  pos = __pyx_bisect_code_objects(__pyx_code_cache.entries, __pyx_code_cache.count, code_line);
21265  if ((pos < __pyx_code_cache.count) && unlikely(__pyx_code_cache.entries[pos].code_line == code_line)) {
21266  PyCodeObject* tmp = entries[pos].code_object;
21267  entries[pos].code_object = code_object;
21268  Py_DECREF(tmp);
21269  return;
21270  }
21271  if (__pyx_code_cache.count == __pyx_code_cache.max_count) {
21272  int new_max = __pyx_code_cache.max_count + 64;
21273  entries = (__Pyx_CodeObjectCacheEntry*)PyMem_Realloc(
21274  __pyx_code_cache.entries, (size_t)new_max*sizeof(__Pyx_CodeObjectCacheEntry));
21275  if (unlikely(!entries)) {
21276  return;
21277  }
21278  __pyx_code_cache.entries = entries;
21279  __pyx_code_cache.max_count = new_max;
21280  }
21281  for (i=__pyx_code_cache.count; i>pos; i--) {
21282  entries[i] = entries[i-1];
21283  }
21284  entries[pos].code_line = code_line;
21285  entries[pos].code_object = code_object;
21286  __pyx_code_cache.count++;
21287  Py_INCREF(code_object);
21288 }
21289 
21290 #include "compile.h"
21291 #include "frameobject.h"
21292 #include "traceback.h"
21293 static PyCodeObject* __Pyx_CreateCodeObjectForTraceback(
21294  const char *funcname, int c_line,
21295  int py_line, const char *filename) {
21296  PyCodeObject *py_code = 0;
21297  PyObject *py_srcfile = 0;
21298  PyObject *py_funcname = 0;
21299  #if PY_MAJOR_VERSION < 3
21300  py_srcfile = PyString_FromString(filename);
21301  #else
21302  py_srcfile = PyUnicode_FromString(filename);
21303  #endif
21304  if (!py_srcfile) goto bad;
21305  if (c_line) {
21306  #if PY_MAJOR_VERSION < 3
21307  py_funcname = PyString_FromFormat( "%s (%s:%d)", funcname, __pyx_cfilenm, c_line);
21308  #else
21309  py_funcname = PyUnicode_FromFormat( "%s (%s:%d)", funcname, __pyx_cfilenm, c_line);
21310  #endif
21311  }
21312  else {
21313  #if PY_MAJOR_VERSION < 3
21314  py_funcname = PyString_FromString(funcname);
21315  #else
21316  py_funcname = PyUnicode_FromString(funcname);
21317  #endif
21318  }
21319  if (!py_funcname) goto bad;
21320  py_code = __Pyx_PyCode_New(
21321  0,
21322  0,
21323  0,
21324  0,
21325  0,
21326  __pyx_empty_bytes, /*PyObject *code,*/
21327  __pyx_empty_tuple, /*PyObject *consts,*/
21328  __pyx_empty_tuple, /*PyObject *names,*/
21329  __pyx_empty_tuple, /*PyObject *varnames,*/
21330  __pyx_empty_tuple, /*PyObject *freevars,*/
21331  __pyx_empty_tuple, /*PyObject *cellvars,*/
21332  py_srcfile, /*PyObject *filename,*/
21333  py_funcname, /*PyObject *name,*/
21334  py_line,
21335  __pyx_empty_bytes /*PyObject *lnotab*/
21336  );
21337  Py_DECREF(py_srcfile);
21338  Py_DECREF(py_funcname);
21339  return py_code;
21340 bad:
21341  Py_XDECREF(py_srcfile);
21342  Py_XDECREF(py_funcname);
21343  return NULL;
21344 }
21345 static void __Pyx_AddTraceback(const char *funcname, int c_line,
21346  int py_line, const char *filename) {
21347  PyCodeObject *py_code = 0;
21348  PyFrameObject *py_frame = 0;
21349  py_code = __pyx_find_code_object(c_line ? c_line : py_line);
21350  if (!py_code) {
21351  py_code = __Pyx_CreateCodeObjectForTraceback(
21352  funcname, c_line, py_line, filename);
21353  if (!py_code) goto bad;
21354  __pyx_insert_code_object(c_line ? c_line : py_line, py_code);
21355  }
21356  py_frame = PyFrame_New(
21357  PyThreadState_GET(), /*PyThreadState *tstate,*/
21358  py_code, /*PyCodeObject *code,*/
21359  __pyx_d, /*PyObject *globals,*/
21360  0 /*PyObject *locals*/
21361  );
21362  if (!py_frame) goto bad;
21363  py_frame->f_lineno = py_line;
21364  PyTraceBack_Here(py_frame);
21365 bad:
21366  Py_XDECREF(py_code);
21367  Py_XDECREF(py_frame);
21368 }
21369 
21370 #define __PYX_VERIFY_RETURN_INT(target_type, func_type, func_value)\
21371  __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, 0)
21372 #define __PYX_VERIFY_RETURN_INT_EXC(target_type, func_type, func_value)\
21373  __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, 1)
21374 #define __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, exc)\
21375  {\
21376  func_type value = func_value;\
21377  if (sizeof(target_type) < sizeof(func_type)) {\
21378  if (unlikely(value != (func_type) (target_type) value)) {\
21379  func_type zero = 0;\
21380  if (exc && unlikely(value == (func_type)-1 && PyErr_Occurred()))\
21381  return (target_type) -1;\
21382  if (is_unsigned && unlikely(value < zero))\
21383  goto raise_neg_overflow;\
21384  else\
21385  goto raise_overflow;\
21386  }\
21387  }\
21388  return (target_type) value;\
21389  }
21390 
21391 static CYTHON_INLINE int __Pyx_PyInt_As_int(PyObject *x) {
21392  const int neg_one = (int) -1, const_zero = (int) 0;
21393  const int is_unsigned = neg_one > const_zero;
21394 #if PY_MAJOR_VERSION < 3
21395  if (likely(PyInt_Check(x))) {
21396  if (sizeof(int) < sizeof(long)) {
21397  __PYX_VERIFY_RETURN_INT(int, long, PyInt_AS_LONG(x))
21398  } else {
21399  long val = PyInt_AS_LONG(x);
21400  if (is_unsigned && unlikely(val < 0)) {
21401  goto raise_neg_overflow;
21402  }
21403  return (int) val;
21404  }
21405  } else
21406 #endif
21407  if (likely(PyLong_Check(x))) {
21408  if (is_unsigned) {
21409 #if CYTHON_USE_PYLONG_INTERNALS
21410  const digit* digits = ((PyLongObject*)x)->ob_digit;
21411  switch (Py_SIZE(x)) {
21412  case 0: return (int) 0;
21413  case 1: __PYX_VERIFY_RETURN_INT(int, digit, digits[0])
21414  case 2:
21415  if (8 * sizeof(int) > 1 * PyLong_SHIFT) {
21416  if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
21417  __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
21418  } else if (8 * sizeof(int) >= 2 * PyLong_SHIFT) {
21419  return (int) (((((int)digits[1]) << PyLong_SHIFT) | (int)digits[0]));
21420  }
21421  }
21422  break;
21423  case 3:
21424  if (8 * sizeof(int) > 2 * PyLong_SHIFT) {
21425  if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
21426  __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
21427  } else if (8 * sizeof(int) >= 3 * PyLong_SHIFT) {
21428  return (int) (((((((int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0]));
21429  }
21430  }
21431  break;
21432  case 4:
21433  if (8 * sizeof(int) > 3 * PyLong_SHIFT) {
21434  if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
21435  __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
21436  } else if (8 * sizeof(int) >= 4 * PyLong_SHIFT) {
21437  return (int) (((((((((int)digits[3]) << PyLong_SHIFT) | (int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0]));
21438  }
21439  }
21440  break;
21441  }
21442 #endif
21443 #if CYTHON_COMPILING_IN_CPYTHON
21444  if (unlikely(Py_SIZE(x) < 0)) {
21445  goto raise_neg_overflow;
21446  }
21447 #else
21448  {
21449  int result = PyObject_RichCompareBool(x, Py_False, Py_LT);
21450  if (unlikely(result < 0))
21451  return (int) -1;
21452  if (unlikely(result == 1))
21453  goto raise_neg_overflow;
21454  }
21455 #endif
21456  if (sizeof(int) <= sizeof(unsigned long)) {
21457  __PYX_VERIFY_RETURN_INT_EXC(int, unsigned long, PyLong_AsUnsignedLong(x))
21458  } else if (sizeof(int) <= sizeof(unsigned PY_LONG_LONG)) {
21459  __PYX_VERIFY_RETURN_INT_EXC(int, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x))
21460  }
21461  } else {
21462 #if CYTHON_USE_PYLONG_INTERNALS
21463  const digit* digits = ((PyLongObject*)x)->ob_digit;
21464  switch (Py_SIZE(x)) {
21465  case 0: return (int) 0;
21466  case -1: __PYX_VERIFY_RETURN_INT(int, sdigit, -(sdigit) digits[0])
21467  case 1: __PYX_VERIFY_RETURN_INT(int, digit, +digits[0])
21468  case -2:
21469  if (8 * sizeof(int) - 1 > 1 * PyLong_SHIFT) {
21470  if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
21471  __PYX_VERIFY_RETURN_INT(int, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
21472  } else if (8 * sizeof(int) - 1 > 2 * PyLong_SHIFT) {
21473  return (int) (((int)-1)*(((((int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
21474  }
21475  }
21476  break;
21477  case 2:
21478  if (8 * sizeof(int) > 1 * PyLong_SHIFT) {
21479  if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
21480  __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
21481  } else if (8 * sizeof(int) - 1 > 2 * PyLong_SHIFT) {
21482  return (int) ((((((int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
21483  }
21484  }
21485  break;
21486  case -3:
21487  if (8 * sizeof(int) - 1 > 2 * PyLong_SHIFT) {
21488  if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
21489  __PYX_VERIFY_RETURN_INT(int, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
21490  } else if (8 * sizeof(int) - 1 > 3 * PyLong_SHIFT) {
21491  return (int) (((int)-1)*(((((((int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
21492  }
21493  }
21494  break;
21495  case 3:
21496  if (8 * sizeof(int) > 2 * PyLong_SHIFT) {
21497  if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
21498  __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
21499  } else if (8 * sizeof(int) - 1 > 3 * PyLong_SHIFT) {
21500  return (int) ((((((((int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
21501  }
21502  }
21503  break;
21504  case -4:
21505  if (8 * sizeof(int) - 1 > 3 * PyLong_SHIFT) {
21506  if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
21507  __PYX_VERIFY_RETURN_INT(int, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
21508  } else if (8 * sizeof(int) - 1 > 4 * PyLong_SHIFT) {
21509  return (int) (((int)-1)*(((((((((int)digits[3]) << PyLong_SHIFT) | (int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
21510  }
21511  }
21512  break;
21513  case 4:
21514  if (8 * sizeof(int) > 3 * PyLong_SHIFT) {
21515  if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
21516  __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
21517  } else if (8 * sizeof(int) - 1 > 4 * PyLong_SHIFT) {
21518  return (int) ((((((((((int)digits[3]) << PyLong_SHIFT) | (int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
21519  }
21520  }
21521  break;
21522  }
21523 #endif
21524  if (sizeof(int) <= sizeof(long)) {
21525  __PYX_VERIFY_RETURN_INT_EXC(int, long, PyLong_AsLong(x))
21526  } else if (sizeof(int) <= sizeof(PY_LONG_LONG)) {
21527  __PYX_VERIFY_RETURN_INT_EXC(int, PY_LONG_LONG, PyLong_AsLongLong(x))
21528  }
21529  }
21530  {
21531 #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray)
21532  PyErr_SetString(PyExc_RuntimeError,
21533  "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers");
21534 #else
21535  int val;
21536  PyObject *v = __Pyx_PyNumber_Int(x);
21537  #if PY_MAJOR_VERSION < 3
21538  if (likely(v) && !PyLong_Check(v)) {
21539  PyObject *tmp = v;
21540  v = PyNumber_Long(tmp);
21541  Py_DECREF(tmp);
21542  }
21543  #endif
21544  if (likely(v)) {
21545  int one = 1; int is_little = (int)*(unsigned char *)&one;
21546  unsigned char *bytes = (unsigned char *)&val;
21547  int ret = _PyLong_AsByteArray((PyLongObject *)v,
21548  bytes, sizeof(val),
21549  is_little, !is_unsigned);
21550  Py_DECREF(v);
21551  if (likely(!ret))
21552  return val;
21553  }
21554 #endif
21555  return (int) -1;
21556  }
21557  } else {
21558  int val;
21559  PyObject *tmp = __Pyx_PyNumber_Int(x);
21560  if (!tmp) return (int) -1;
21561  val = __Pyx_PyInt_As_int(tmp);
21562  Py_DECREF(tmp);
21563  return val;
21564  }
21565 raise_overflow:
21566  PyErr_SetString(PyExc_OverflowError,
21567  "value too large to convert to int");
21568  return (int) -1;
21569 raise_neg_overflow:
21570  PyErr_SetString(PyExc_OverflowError,
21571  "can't convert negative value to int");
21572  return (int) -1;
21573 }
21574 
21575 static CYTHON_INLINE PyObject* __Pyx_PyInt_From_int(int value) {
21576  const int neg_one = (int) -1, const_zero = (int) 0;
21577  const int is_unsigned = neg_one > const_zero;
21578  if (is_unsigned) {
21579  if (sizeof(int) < sizeof(long)) {
21580  return PyInt_FromLong((long) value);
21581  } else if (sizeof(int) <= sizeof(unsigned long)) {
21582  return PyLong_FromUnsignedLong((unsigned long) value);
21583  } else if (sizeof(int) <= sizeof(unsigned PY_LONG_LONG)) {
21584  return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value);
21585  }
21586  } else {
21587  if (sizeof(int) <= sizeof(long)) {
21588  return PyInt_FromLong((long) value);
21589  } else if (sizeof(int) <= sizeof(PY_LONG_LONG)) {
21590  return PyLong_FromLongLong((PY_LONG_LONG) value);
21591  }
21592  }
21593  {
21594  int one = 1; int little = (int)*(unsigned char *)&one;
21595  unsigned char *bytes = (unsigned char *)&value;
21596  return _PyLong_FromByteArray(bytes, sizeof(int),
21597  little, !is_unsigned);
21598  }
21599 }
21600 
21601 static CYTHON_INLINE PyObject* __Pyx_PyInt_From_long(long value) {
21602  const long neg_one = (long) -1, const_zero = (long) 0;
21603  const int is_unsigned = neg_one > const_zero;
21604  if (is_unsigned) {
21605  if (sizeof(long) < sizeof(long)) {
21606  return PyInt_FromLong((long) value);
21607  } else if (sizeof(long) <= sizeof(unsigned long)) {
21608  return PyLong_FromUnsignedLong((unsigned long) value);
21609  } else if (sizeof(long) <= sizeof(unsigned PY_LONG_LONG)) {
21610  return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value);
21611  }
21612  } else {
21613  if (sizeof(long) <= sizeof(long)) {
21614  return PyInt_FromLong((long) value);
21615  } else if (sizeof(long) <= sizeof(PY_LONG_LONG)) {
21616  return PyLong_FromLongLong((PY_LONG_LONG) value);
21617  }
21618  }
21619  {
21620  int one = 1; int little = (int)*(unsigned char *)&one;
21621  unsigned char *bytes = (unsigned char *)&value;
21622  return _PyLong_FromByteArray(bytes, sizeof(long),
21623  little, !is_unsigned);
21624  }
21625 }
21626 
21627 static CYTHON_INLINE long __Pyx_PyInt_As_long(PyObject *x) {
21628  const long neg_one = (long) -1, const_zero = (long) 0;
21629  const int is_unsigned = neg_one > const_zero;
21630 #if PY_MAJOR_VERSION < 3
21631  if (likely(PyInt_Check(x))) {
21632  if (sizeof(long) < sizeof(long)) {
21633  __PYX_VERIFY_RETURN_INT(long, long, PyInt_AS_LONG(x))
21634  } else {
21635  long val = PyInt_AS_LONG(x);
21636  if (is_unsigned && unlikely(val < 0)) {
21637  goto raise_neg_overflow;
21638  }
21639  return (long) val;
21640  }
21641  } else
21642 #endif
21643  if (likely(PyLong_Check(x))) {
21644  if (is_unsigned) {
21645 #if CYTHON_USE_PYLONG_INTERNALS
21646  const digit* digits = ((PyLongObject*)x)->ob_digit;
21647  switch (Py_SIZE(x)) {
21648  case 0: return (long) 0;
21649  case 1: __PYX_VERIFY_RETURN_INT(long, digit, digits[0])
21650  case 2:
21651  if (8 * sizeof(long) > 1 * PyLong_SHIFT) {
21652  if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
21653  __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
21654  } else if (8 * sizeof(long) >= 2 * PyLong_SHIFT) {
21655  return (long) (((((long)digits[1]) << PyLong_SHIFT) | (long)digits[0]));
21656  }
21657  }
21658  break;
21659  case 3:
21660  if (8 * sizeof(long) > 2 * PyLong_SHIFT) {
21661  if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
21662  __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
21663  } else if (8 * sizeof(long) >= 3 * PyLong_SHIFT) {
21664  return (long) (((((((long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0]));
21665  }
21666  }
21667  break;
21668  case 4:
21669  if (8 * sizeof(long) > 3 * PyLong_SHIFT) {
21670  if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
21671  __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
21672  } else if (8 * sizeof(long) >= 4 * PyLong_SHIFT) {
21673  return (long) (((((((((long)digits[3]) << PyLong_SHIFT) | (long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0]));
21674  }
21675  }
21676  break;
21677  }
21678 #endif
21679 #if CYTHON_COMPILING_IN_CPYTHON
21680  if (unlikely(Py_SIZE(x) < 0)) {
21681  goto raise_neg_overflow;
21682  }
21683 #else
21684  {
21685  int result = PyObject_RichCompareBool(x, Py_False, Py_LT);
21686  if (unlikely(result < 0))
21687  return (long) -1;
21688  if (unlikely(result == 1))
21689  goto raise_neg_overflow;
21690  }
21691 #endif
21692  if (sizeof(long) <= sizeof(unsigned long)) {
21693  __PYX_VERIFY_RETURN_INT_EXC(long, unsigned long, PyLong_AsUnsignedLong(x))
21694  } else if (sizeof(long) <= sizeof(unsigned PY_LONG_LONG)) {
21695  __PYX_VERIFY_RETURN_INT_EXC(long, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x))
21696  }
21697  } else {
21698 #if CYTHON_USE_PYLONG_INTERNALS
21699  const digit* digits = ((PyLongObject*)x)->ob_digit;
21700  switch (Py_SIZE(x)) {
21701  case 0: return (long) 0;
21702  case -1: __PYX_VERIFY_RETURN_INT(long, sdigit, -(sdigit) digits[0])
21703  case 1: __PYX_VERIFY_RETURN_INT(long, digit, +digits[0])
21704  case -2:
21705  if (8 * sizeof(long) - 1 > 1 * PyLong_SHIFT) {
21706  if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
21707  __PYX_VERIFY_RETURN_INT(long, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
21708  } else if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) {
21709  return (long) (((long)-1)*(((((long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
21710  }
21711  }
21712  break;
21713  case 2:
21714  if (8 * sizeof(long) > 1 * PyLong_SHIFT) {
21715  if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
21716  __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
21717  } else if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) {
21718  return (long) ((((((long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
21719  }
21720  }
21721  break;
21722  case -3:
21723  if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) {
21724  if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
21725  __PYX_VERIFY_RETURN_INT(long, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
21726  } else if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) {
21727  return (long) (((long)-1)*(((((((long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
21728  }
21729  }
21730  break;
21731  case 3:
21732  if (8 * sizeof(long) > 2 * PyLong_SHIFT) {
21733  if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
21734  __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
21735  } else if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) {
21736  return (long) ((((((((long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
21737  }
21738  }
21739  break;
21740  case -4:
21741  if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) {
21742  if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
21743  __PYX_VERIFY_RETURN_INT(long, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
21744  } else if (8 * sizeof(long) - 1 > 4 * PyLong_SHIFT) {
21745  return (long) (((long)-1)*(((((((((long)digits[3]) << PyLong_SHIFT) | (long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
21746  }
21747  }
21748  break;
21749  case 4:
21750  if (8 * sizeof(long) > 3 * PyLong_SHIFT) {
21751  if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
21752  __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
21753  } else if (8 * sizeof(long) - 1 > 4 * PyLong_SHIFT) {
21754  return (long) ((((((((((long)digits[3]) << PyLong_SHIFT) | (long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
21755  }
21756  }
21757  break;
21758  }
21759 #endif
21760  if (sizeof(long) <= sizeof(long)) {
21761  __PYX_VERIFY_RETURN_INT_EXC(long, long, PyLong_AsLong(x))
21762  } else if (sizeof(long) <= sizeof(PY_LONG_LONG)) {
21763  __PYX_VERIFY_RETURN_INT_EXC(long, PY_LONG_LONG, PyLong_AsLongLong(x))
21764  }
21765  }
21766  {
21767 #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray)
21768  PyErr_SetString(PyExc_RuntimeError,
21769  "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers");
21770 #else
21771  long val;
21772  PyObject *v = __Pyx_PyNumber_Int(x);
21773  #if PY_MAJOR_VERSION < 3
21774  if (likely(v) && !PyLong_Check(v)) {
21775  PyObject *tmp = v;
21776  v = PyNumber_Long(tmp);
21777  Py_DECREF(tmp);
21778  }
21779  #endif
21780  if (likely(v)) {
21781  int one = 1; int is_little = (int)*(unsigned char *)&one;
21782  unsigned char *bytes = (unsigned char *)&val;
21783  int ret = _PyLong_AsByteArray((PyLongObject *)v,
21784  bytes, sizeof(val),
21785  is_little, !is_unsigned);
21786  Py_DECREF(v);
21787  if (likely(!ret))
21788  return val;
21789  }
21790 #endif
21791  return (long) -1;
21792  }
21793  } else {
21794  long val;
21795  PyObject *tmp = __Pyx_PyNumber_Int(x);
21796  if (!tmp) return (long) -1;
21797  val = __Pyx_PyInt_As_long(tmp);
21798  Py_DECREF(tmp);
21799  return val;
21800  }
21801 raise_overflow:
21802  PyErr_SetString(PyExc_OverflowError,
21803  "value too large to convert to long");
21804  return (long) -1;
21805 raise_neg_overflow:
21806  PyErr_SetString(PyExc_OverflowError,
21807  "can't convert negative value to long");
21808  return (long) -1;
21809 }
21810 
21811 static PyTypeObject* __Pyx_FetchCommonType(PyTypeObject* type) {
21812  PyObject* fake_module;
21813  PyTypeObject* cached_type = NULL;
21814  fake_module = PyImport_AddModule((char*) "_cython_" CYTHON_ABI);
21815  if (!fake_module) return NULL;
21816  Py_INCREF(fake_module);
21817  cached_type = (PyTypeObject*) PyObject_GetAttrString(fake_module, type->tp_name);
21818  if (cached_type) {
21819  if (!PyType_Check((PyObject*)cached_type)) {
21820  PyErr_Format(PyExc_TypeError,
21821  "Shared Cython type %.200s is not a type object",
21822  type->tp_name);
21823  goto bad;
21824  }
21825  if (cached_type->tp_basicsize != type->tp_basicsize) {
21826  PyErr_Format(PyExc_TypeError,
21827  "Shared Cython type %.200s has the wrong size, try recompiling",
21828  type->tp_name);
21829  goto bad;
21830  }
21831  } else {
21832  if (!PyErr_ExceptionMatches(PyExc_AttributeError)) goto bad;
21833  PyErr_Clear();
21834  if (PyType_Ready(type) < 0) goto bad;
21835  if (PyObject_SetAttrString(fake_module, type->tp_name, (PyObject*) type) < 0)
21836  goto bad;
21837  Py_INCREF(type);
21838  cached_type = type;
21839  }
21840 done:
21841  Py_DECREF(fake_module);
21842  return cached_type;
21843 bad:
21844  Py_XDECREF(cached_type);
21845  cached_type = NULL;
21846  goto done;
21847 }
21848 
21849 static CYTHON_INLINE void __Pyx_ExceptionSwap(PyObject **type, PyObject **value, PyObject **tb) {
21850  PyObject *tmp_type, *tmp_value, *tmp_tb;
21851 #if CYTHON_COMPILING_IN_CPYTHON
21852  PyThreadState *tstate = PyThreadState_GET();
21853  tmp_type = tstate->exc_type;
21854  tmp_value = tstate->exc_value;
21855  tmp_tb = tstate->exc_traceback;
21856  tstate->exc_type = *type;
21857  tstate->exc_value = *value;
21858  tstate->exc_traceback = *tb;
21859 #else
21860  PyErr_GetExcInfo(&tmp_type, &tmp_value, &tmp_tb);
21861  PyErr_SetExcInfo(*type, *value, *tb);
21862 #endif
21863  *type = tmp_type;
21864  *value = tmp_value;
21865  *tb = tmp_tb;
21866 }
21867 
21868 static PyObject* __Pyx_PyObject_CallMethod1(PyObject* obj, PyObject* method_name, PyObject* arg) {
21869  PyObject *method, *result = NULL;
21870  method = __Pyx_PyObject_GetAttrStr(obj, method_name);
21871  if (unlikely(!method)) goto bad;
21872 #if CYTHON_COMPILING_IN_CPYTHON
21873  if (likely(PyMethod_Check(method))) {
21874  PyObject *self = PyMethod_GET_SELF(method);
21875  if (likely(self)) {
21876  PyObject *args;
21877  PyObject *function = PyMethod_GET_FUNCTION(method);
21878  args = PyTuple_New(2);
21879  if (unlikely(!args)) goto bad;
21880  Py_INCREF(self);
21881  PyTuple_SET_ITEM(args, 0, self);
21882  Py_INCREF(arg);
21883  PyTuple_SET_ITEM(args, 1, arg);
21884  Py_INCREF(function);
21885  Py_DECREF(method); method = NULL;
21886  result = __Pyx_PyObject_Call(function, args, NULL);
21887  Py_DECREF(args);
21888  Py_DECREF(function);
21889  return result;
21890  }
21891  }
21892 #endif
21893  result = __Pyx_PyObject_CallOneArg(method, arg);
21894 bad:
21895  Py_XDECREF(method);
21896  return result;
21897 }
21898 
21899 #include <structmember.h>
21900 #include <frameobject.h>
21901 static PyObject *__Pyx_Coroutine_Send(PyObject *self, PyObject *value);
21902 static PyObject *__Pyx_Coroutine_Close(PyObject *self);
21903 static PyObject *__Pyx_Coroutine_Throw(PyObject *gen, PyObject *args);
21904 #define __Pyx_Coroutine_Undelegate(gen) Py_CLEAR((gen)->yieldfrom)
21905 #if 1 || PY_VERSION_HEX < 0x030300B0
21906 static int __Pyx_PyGen_FetchStopIterationValue(PyObject **pvalue) {
21907  PyObject *et, *ev, *tb;
21908  PyObject *value = NULL;
21909  __Pyx_ErrFetch(&et, &ev, &tb);
21910  if (!et) {
21911  Py_XDECREF(tb);
21912  Py_XDECREF(ev);
21913  Py_INCREF(Py_None);
21914  *pvalue = Py_None;
21915  return 0;
21916  }
21917  if (likely(et == PyExc_StopIteration)) {
21918 #if PY_VERSION_HEX >= 0x030300A0
21919  if (ev && Py_TYPE(ev) == (PyTypeObject*)PyExc_StopIteration) {
21920  value = ((PyStopIterationObject *)ev)->value;
21921  Py_INCREF(value);
21922  Py_DECREF(ev);
21923  Py_XDECREF(tb);
21924  Py_DECREF(et);
21925  *pvalue = value;
21926  return 0;
21927  }
21928 #endif
21929  if (!ev || !PyObject_TypeCheck(ev, (PyTypeObject*)PyExc_StopIteration)) {
21930  if (!ev) {
21931  Py_INCREF(Py_None);
21932  ev = Py_None;
21933  } else if (PyTuple_Check(ev)) {
21934  if (PyTuple_GET_SIZE(ev) >= 1) {
21935  PyObject *value;
21936 #if CYTHON_COMPILING_IN_CPYTHON
21937  value = PySequence_ITEM(ev, 0);
21938 #else
21939  value = PyTuple_GET_ITEM(ev, 0);
21940  Py_INCREF(value);
21941 #endif
21942  Py_DECREF(ev);
21943  ev = value;
21944  } else {
21945  Py_INCREF(Py_None);
21946  Py_DECREF(ev);
21947  ev = Py_None;
21948  }
21949  }
21950  Py_XDECREF(tb);
21951  Py_DECREF(et);
21952  *pvalue = ev;
21953  return 0;
21954  }
21955  } else if (!PyErr_GivenExceptionMatches(et, PyExc_StopIteration)) {
21956  __Pyx_ErrRestore(et, ev, tb);
21957  return -1;
21958  }
21959  PyErr_NormalizeException(&et, &ev, &tb);
21960  if (unlikely(!PyObject_TypeCheck(ev, (PyTypeObject*)PyExc_StopIteration))) {
21961  __Pyx_ErrRestore(et, ev, tb);
21962  return -1;
21963  }
21964  Py_XDECREF(tb);
21965  Py_DECREF(et);
21966 #if PY_VERSION_HEX >= 0x030300A0
21967  value = ((PyStopIterationObject *)ev)->value;
21968  Py_INCREF(value);
21969  Py_DECREF(ev);
21970 #else
21971  {
21972  PyObject* args = __Pyx_PyObject_GetAttrStr(ev, __pyx_n_s_args);
21973  Py_DECREF(ev);
21974  if (likely(args)) {
21975  value = PySequence_GetItem(args, 0);
21976  Py_DECREF(args);
21977  }
21978  if (unlikely(!value)) {
21979  __Pyx_ErrRestore(NULL, NULL, NULL);
21980  Py_INCREF(Py_None);
21981  value = Py_None;
21982  }
21983  }
21984 #endif
21985  *pvalue = value;
21986  return 0;
21987 }
21988 #endif
21989 static CYTHON_INLINE
21990 void __Pyx_Coroutine_ExceptionClear(__pyx_CoroutineObject *self) {
21991  PyObject *exc_type = self->exc_type;
21992  PyObject *exc_value = self->exc_value;
21993  PyObject *exc_traceback = self->exc_traceback;
21994  self->exc_type = NULL;
21995  self->exc_value = NULL;
21996  self->exc_traceback = NULL;
21997  Py_XDECREF(exc_type);
21998  Py_XDECREF(exc_value);
21999  Py_XDECREF(exc_traceback);
22000 }
22001 static CYTHON_INLINE
22002 int __Pyx_Coroutine_CheckRunning(__pyx_CoroutineObject *gen) {
22003  if (unlikely(gen->is_running)) {
22004  PyErr_SetString(PyExc_ValueError,
22005  "generator already executing");
22006  return 1;
22007  }
22008  return 0;
22009 }
22010 static CYTHON_INLINE
22011 PyObject *__Pyx_Coroutine_SendEx(__pyx_CoroutineObject *self, PyObject *value) {
22012  PyObject *retval;
22013  assert(!self->is_running);
22014  if (unlikely(self->resume_label == 0)) {
22015  if (unlikely(value && value != Py_None)) {
22016  PyErr_SetString(PyExc_TypeError,
22017  "can't send non-None value to a "
22018  "just-started generator");
22019  return NULL;
22020  }
22021  }
22022  if (unlikely(self->resume_label == -1)) {
22023  PyErr_SetNone(PyExc_StopIteration);
22024  return NULL;
22025  }
22026  if (value) {
22027 #if CYTHON_COMPILING_IN_PYPY
22028 #else
22029  if (self->exc_traceback) {
22030  PyThreadState *tstate = PyThreadState_GET();
22031  PyTracebackObject *tb = (PyTracebackObject *) self->exc_traceback;
22032  PyFrameObject *f = tb->tb_frame;
22033  Py_XINCREF(tstate->frame);
22034  assert(f->f_back == NULL);
22035  f->f_back = tstate->frame;
22036  }
22037 #endif
22038  __Pyx_ExceptionSwap(&self->exc_type, &self->exc_value,
22039  &self->exc_traceback);
22040  } else {
22041  __Pyx_Coroutine_ExceptionClear(self);
22042  }
22043  self->is_running = 1;
22044  retval = self->body((PyObject *) self, value);
22045  self->is_running = 0;
22046  if (retval) {
22047  __Pyx_ExceptionSwap(&self->exc_type, &self->exc_value,
22048  &self->exc_traceback);
22049 #if CYTHON_COMPILING_IN_PYPY
22050 #else
22051  if (self->exc_traceback) {
22052  PyTracebackObject *tb = (PyTracebackObject *) self->exc_traceback;
22053  PyFrameObject *f = tb->tb_frame;
22054  Py_CLEAR(f->f_back);
22055  }
22056 #endif
22057  } else {
22058  __Pyx_Coroutine_ExceptionClear(self);
22059  }
22060  return retval;
22061 }
22062 static CYTHON_INLINE
22063 PyObject *__Pyx_Coroutine_MethodReturn(PyObject *retval) {
22064  if (unlikely(!retval && !PyErr_Occurred())) {
22065  PyErr_SetNone(PyExc_StopIteration);
22066  }
22067  return retval;
22068 }
22069 static CYTHON_INLINE
22070 PyObject *__Pyx_Coroutine_FinishDelegation(__pyx_CoroutineObject *gen) {
22071  PyObject *ret;
22072  PyObject *val = NULL;
22073  __Pyx_Coroutine_Undelegate(gen);
22074  __Pyx_PyGen_FetchStopIterationValue(&val);
22075  ret = __Pyx_Coroutine_SendEx(gen, val);
22076  Py_XDECREF(val);
22077  return ret;
22078 }
22079 static PyObject *__Pyx_Coroutine_Send(PyObject *self, PyObject *value) {
22080  PyObject *retval;
22081  __pyx_CoroutineObject *gen = (__pyx_CoroutineObject*) self;
22082  PyObject *yf = gen->yieldfrom;
22083  if (unlikely(__Pyx_Coroutine_CheckRunning(gen)))
22084  return NULL;
22085  if (yf) {
22086  PyObject *ret;
22087  gen->is_running = 1;
22088  #ifdef __Pyx_Generator_USED
22089  if (__Pyx_Generator_CheckExact(yf)) {
22090  ret = __Pyx_Coroutine_Send(yf, value);
22091  } else
22092  #endif
22093  #ifdef __Pyx_Coroutine_USED
22094  if (__Pyx_Coroutine_CheckExact(yf)) {
22095  ret = __Pyx_Coroutine_Send(yf, value);
22096  } else
22097  #endif
22098  {
22099  if (value == Py_None)
22100  ret = Py_TYPE(yf)->tp_iternext(yf);
22101  else
22102  ret = __Pyx_PyObject_CallMethod1(yf, __pyx_n_s_send, value);
22103  }
22104  gen->is_running = 0;
22105  if (likely(ret)) {
22106  return ret;
22107  }
22108  retval = __Pyx_Coroutine_FinishDelegation(gen);
22109  } else {
22110  retval = __Pyx_Coroutine_SendEx(gen, value);
22111  }
22112  return __Pyx_Coroutine_MethodReturn(retval);
22113 }
22114 static int __Pyx_Coroutine_CloseIter(__pyx_CoroutineObject *gen, PyObject *yf) {
22115  PyObject *retval = NULL;
22116  int err = 0;
22117  #ifdef __Pyx_Generator_USED
22118  if (__Pyx_Generator_CheckExact(yf)) {
22119  retval = __Pyx_Coroutine_Close(yf);
22120  if (!retval)
22121  return -1;
22122  } else
22123  #endif
22124  #ifdef __Pyx_Coroutine_USED
22125  if (__Pyx_Coroutine_CheckExact(yf)) {
22126  retval = __Pyx_Coroutine_Close(yf);
22127  if (!retval)
22128  return -1;
22129  } else
22130  #endif
22131  {
22132  PyObject *meth;
22133  gen->is_running = 1;
22134  meth = __Pyx_PyObject_GetAttrStr(yf, __pyx_n_s_close);
22135  if (unlikely(!meth)) {
22136  if (!PyErr_ExceptionMatches(PyExc_AttributeError)) {
22137  PyErr_WriteUnraisable(yf);
22138  }
22139  PyErr_Clear();
22140  } else {
22141  retval = PyObject_CallFunction(meth, NULL);
22142  Py_DECREF(meth);
22143  if (!retval)
22144  err = -1;
22145  }
22146  gen->is_running = 0;
22147  }
22148  Py_XDECREF(retval);
22149  return err;
22150 }
22151 static PyObject *__Pyx_Generator_Next(PyObject *self) {
22152  __pyx_CoroutineObject *gen = (__pyx_CoroutineObject*) self;
22153  PyObject *yf = gen->yieldfrom;
22154  if (unlikely(__Pyx_Coroutine_CheckRunning(gen)))
22155  return NULL;
22156  if (yf) {
22157  PyObject *ret;
22158  gen->is_running = 1;
22159  ret = Py_TYPE(yf)->tp_iternext(yf);
22160  gen->is_running = 0;
22161  if (likely(ret)) {
22162  return ret;
22163  }
22164  return __Pyx_Coroutine_FinishDelegation(gen);
22165  }
22166  return __Pyx_Coroutine_SendEx(gen, Py_None);
22167 }
22168 static PyObject *__Pyx_Coroutine_Close(PyObject *self) {
22169  __pyx_CoroutineObject *gen = (__pyx_CoroutineObject *) self;
22170  PyObject *retval, *raised_exception;
22171  PyObject *yf = gen->yieldfrom;
22172  int err = 0;
22173  if (unlikely(__Pyx_Coroutine_CheckRunning(gen)))
22174  return NULL;
22175  if (yf) {
22176  Py_INCREF(yf);
22177  err = __Pyx_Coroutine_CloseIter(gen, yf);
22178  __Pyx_Coroutine_Undelegate(gen);
22179  Py_DECREF(yf);
22180  }
22181  if (err == 0)
22182  PyErr_SetNone(PyExc_GeneratorExit);
22183  retval = __Pyx_Coroutine_SendEx(gen, NULL);
22184  if (retval) {
22185  Py_DECREF(retval);
22186  PyErr_SetString(PyExc_RuntimeError,
22187  "generator ignored GeneratorExit");
22188  return NULL;
22189  }
22190  raised_exception = PyErr_Occurred();
22191  if (!raised_exception
22192  || raised_exception == PyExc_StopIteration
22193  || raised_exception == PyExc_GeneratorExit
22194  || PyErr_GivenExceptionMatches(raised_exception, PyExc_GeneratorExit)
22195  || PyErr_GivenExceptionMatches(raised_exception, PyExc_StopIteration))
22196  {
22197  if (raised_exception) PyErr_Clear();
22198  Py_INCREF(Py_None);
22199  return Py_None;
22200  }
22201  return NULL;
22202 }
22203 static PyObject *__Pyx_Coroutine_Throw(PyObject *self, PyObject *args) {
22204  __pyx_CoroutineObject *gen = (__pyx_CoroutineObject *) self;
22205  PyObject *typ;
22206  PyObject *tb = NULL;
22207  PyObject *val = NULL;
22208  PyObject *yf = gen->yieldfrom;
22209  if (!PyArg_UnpackTuple(args, (char *)"throw", 1, 3, &typ, &val, &tb))
22210  return NULL;
22211  if (unlikely(__Pyx_Coroutine_CheckRunning(gen)))
22212  return NULL;
22213  if (yf) {
22214  PyObject *ret;
22215  Py_INCREF(yf);
22216  if (PyErr_GivenExceptionMatches(typ, PyExc_GeneratorExit)) {
22217  int err = __Pyx_Coroutine_CloseIter(gen, yf);
22218  Py_DECREF(yf);
22219  __Pyx_Coroutine_Undelegate(gen);
22220  if (err < 0)
22221  return __Pyx_Coroutine_MethodReturn(__Pyx_Coroutine_SendEx(gen, NULL));
22222  goto throw_here;
22223  }
22224  gen->is_running = 1;
22225  #ifdef __Pyx_Generator_USED
22226  if (__Pyx_Generator_CheckExact(yf)) {
22227  ret = __Pyx_Coroutine_Throw(yf, args);
22228  } else
22229  #endif
22230  #ifdef __Pyx_Coroutine_USED
22231  if (__Pyx_Coroutine_CheckExact(yf)) {
22232  ret = __Pyx_Coroutine_Throw(yf, args);
22233  } else
22234  #endif
22235  {
22236  PyObject *meth = __Pyx_PyObject_GetAttrStr(yf, __pyx_n_s_throw);
22237  if (unlikely(!meth)) {
22238  Py_DECREF(yf);
22239  if (!PyErr_ExceptionMatches(PyExc_AttributeError)) {
22240  gen->is_running = 0;
22241  return NULL;
22242  }
22243  PyErr_Clear();
22244  __Pyx_Coroutine_Undelegate(gen);
22245  gen->is_running = 0;
22246  goto throw_here;
22247  }
22248  ret = PyObject_CallObject(meth, args);
22249  Py_DECREF(meth);
22250  }
22251  gen->is_running = 0;
22252  Py_DECREF(yf);
22253  if (!ret) {
22254  ret = __Pyx_Coroutine_FinishDelegation(gen);
22255  }
22256  return __Pyx_Coroutine_MethodReturn(ret);
22257  }
22258 throw_here:
22259  __Pyx_Raise(typ, val, tb, NULL);
22260  return __Pyx_Coroutine_MethodReturn(__Pyx_Coroutine_SendEx(gen, NULL));
22261 }
22262 static int __Pyx_Coroutine_traverse(PyObject *self, visitproc visit, void *arg) {
22263  __pyx_CoroutineObject *gen = (__pyx_CoroutineObject *) self;
22264  Py_VISIT(gen->closure);
22265  Py_VISIT(gen->classobj);
22266  Py_VISIT(gen->yieldfrom);
22267  Py_VISIT(gen->exc_type);
22268  Py_VISIT(gen->exc_value);
22269  Py_VISIT(gen->exc_traceback);
22270  return 0;
22271 }
22272 static int __Pyx_Coroutine_clear(PyObject *self) {
22273  __pyx_CoroutineObject *gen = (__pyx_CoroutineObject *) self;
22274  Py_CLEAR(gen->closure);
22275  Py_CLEAR(gen->classobj);
22276  Py_CLEAR(gen->yieldfrom);
22277  Py_CLEAR(gen->exc_type);
22278  Py_CLEAR(gen->exc_value);
22279  Py_CLEAR(gen->exc_traceback);
22280  Py_CLEAR(gen->gi_name);
22281  Py_CLEAR(gen->gi_qualname);
22282  return 0;
22283 }
22284 static void __Pyx_Coroutine_dealloc(PyObject *self) {
22285  __pyx_CoroutineObject *gen = (__pyx_CoroutineObject *) self;
22286  PyObject_GC_UnTrack(gen);
22287  if (gen->gi_weakreflist != NULL)
22288  PyObject_ClearWeakRefs(self);
22289  if (gen->resume_label > 0) {
22290  PyObject_GC_Track(self);
22291 #if PY_VERSION_HEX >= 0x030400a1
22292  if (PyObject_CallFinalizerFromDealloc(self))
22293 #else
22294  Py_TYPE(gen)->tp_del(self);
22295  if (self->ob_refcnt > 0)
22296 #endif
22297  {
22298  return;
22299  }
22300  PyObject_GC_UnTrack(self);
22301  }
22302  __Pyx_Coroutine_clear(self);
22303  PyObject_GC_Del(gen);
22304 }
22305 static void __Pyx_Coroutine_del(PyObject *self) {
22306  PyObject *res;
22307  PyObject *error_type, *error_value, *error_traceback;
22308  __pyx_CoroutineObject *gen = (__pyx_CoroutineObject *) self;
22309  if (gen->resume_label <= 0)
22310  return ;
22311 #if PY_VERSION_HEX < 0x030400a1
22312  assert(self->ob_refcnt == 0);
22313  self->ob_refcnt = 1;
22314 #endif
22315  __Pyx_ErrFetch(&error_type, &error_value, &error_traceback);
22316  res = __Pyx_Coroutine_Close(self);
22317  if (res == NULL)
22318  PyErr_WriteUnraisable(self);
22319  else
22320  Py_DECREF(res);
22321  __Pyx_ErrRestore(error_type, error_value, error_traceback);
22322 #if PY_VERSION_HEX < 0x030400a1
22323  assert(self->ob_refcnt > 0);
22324  if (--self->ob_refcnt == 0) {
22325  return;
22326  }
22327  {
22328  Py_ssize_t refcnt = self->ob_refcnt;
22329  _Py_NewReference(self);
22330  self->ob_refcnt = refcnt;
22331  }
22332 #if CYTHON_COMPILING_IN_CPYTHON
22333  assert(PyType_IS_GC(self->ob_type) &&
22334  _Py_AS_GC(self)->gc.gc_refs != _PyGC_REFS_UNTRACKED);
22335  _Py_DEC_REFTOTAL;
22336 #endif
22337 #ifdef COUNT_ALLOCS
22338  --Py_TYPE(self)->tp_frees;
22339  --Py_TYPE(self)->tp_allocs;
22340 #endif
22341 #endif
22342 }
22343 static PyObject *
22344 __Pyx_Coroutine_get_name(__pyx_CoroutineObject *self)
22345 {
22346  Py_INCREF(self->gi_name);
22347  return self->gi_name;
22348 }
22349 static int
22350 __Pyx_Coroutine_set_name(__pyx_CoroutineObject *self, PyObject *value)
22351 {
22352  PyObject *tmp;
22353 #if PY_MAJOR_VERSION >= 3
22354  if (unlikely(value == NULL || !PyUnicode_Check(value))) {
22355 #else
22356  if (unlikely(value == NULL || !PyString_Check(value))) {
22357 #endif
22358  PyErr_SetString(PyExc_TypeError,
22359  "__name__ must be set to a string object");
22360  return -1;
22361  }
22362  tmp = self->gi_name;
22363  Py_INCREF(value);
22364  self->gi_name = value;
22365  Py_XDECREF(tmp);
22366  return 0;
22367 }
22368 static PyObject *
22369 __Pyx_Coroutine_get_qualname(__pyx_CoroutineObject *self)
22370 {
22371  Py_INCREF(self->gi_qualname);
22372  return self->gi_qualname;
22373 }
22374 static int
22375 __Pyx_Coroutine_set_qualname(__pyx_CoroutineObject *self, PyObject *value)
22376 {
22377  PyObject *tmp;
22378 #if PY_MAJOR_VERSION >= 3
22379  if (unlikely(value == NULL || !PyUnicode_Check(value))) {
22380 #else
22381  if (unlikely(value == NULL || !PyString_Check(value))) {
22382 #endif
22383  PyErr_SetString(PyExc_TypeError,
22384  "__qualname__ must be set to a string object");
22385  return -1;
22386  }
22387  tmp = self->gi_qualname;
22388  Py_INCREF(value);
22389  self->gi_qualname = value;
22390  Py_XDECREF(tmp);
22391  return 0;
22392 }
22393 static __pyx_CoroutineObject *__Pyx__Coroutine_New(PyTypeObject* type, __pyx_coroutine_body_t body,
22394  PyObject *closure, PyObject *name, PyObject *qualname) {
22395  __pyx_CoroutineObject *gen = PyObject_GC_New(__pyx_CoroutineObject, type);
22396  if (gen == NULL)
22397  return NULL;
22398  gen->body = body;
22399  gen->closure = closure;
22400  Py_XINCREF(closure);
22401  gen->is_running = 0;
22402  gen->resume_label = 0;
22403  gen->classobj = NULL;
22404  gen->yieldfrom = NULL;
22405  gen->exc_type = NULL;
22406  gen->exc_value = NULL;
22407  gen->exc_traceback = NULL;
22408  gen->gi_weakreflist = NULL;
22409  Py_XINCREF(qualname);
22410  gen->gi_qualname = qualname;
22411  Py_XINCREF(name);
22412  gen->gi_name = name;
22413  PyObject_GC_Track(gen);
22414  return gen;
22415 }
22416 
22417 static PyObject* __Pyx_Coroutine_patch_module(PyObject* module, const char* py_code) {
22418 #if defined(__Pyx_Generator_USED) || defined(__Pyx_Coroutine_USED)
22419  int result;
22420  PyObject *globals, *result_obj;
22421  globals = PyDict_New(); if (unlikely(!globals)) goto ignore;
22422  result = PyDict_SetItemString(globals, "_cython_coroutine_type",
22423  #ifdef __Pyx_Coroutine_USED
22424  (PyObject*)__pyx_CoroutineType);
22425  #else
22426  Py_None);
22427  #endif
22428  if (unlikely(result < 0)) goto ignore;
22429  result = PyDict_SetItemString(globals, "_cython_generator_type",
22430  #ifdef __Pyx_Generator_USED
22431  (PyObject*)__pyx_GeneratorType);
22432  #else
22433  Py_None);
22434  #endif
22435  if (unlikely(result < 0)) goto ignore;
22436  if (unlikely(PyDict_SetItemString(globals, "_module", module) < 0)) goto ignore;
22437  if (unlikely(PyDict_SetItemString(globals, "__builtins__", __pyx_b) < 0)) goto ignore;
22438  result_obj = PyRun_String(py_code, Py_file_input, globals, globals);
22439  if (unlikely(!result_obj)) goto ignore;
22440  Py_DECREF(result_obj);
22441  Py_DECREF(globals);
22442  return module;
22443 ignore:
22444  Py_XDECREF(globals);
22445  PyErr_WriteUnraisable(module);
22446  if (unlikely(PyErr_WarnEx(PyExc_RuntimeWarning, "Cython module failed to patch module with custom type", 1) < 0)) {
22447  Py_DECREF(module);
22448  module = NULL;
22449  }
22450 #else
22451  py_code++;
22452 #endif
22453  return module;
22454 }
22455 
22456 #if defined(__Pyx_Generator_USED) || defined(__Pyx_Coroutine_USED)
22457 static PyObject* __Pyx_patch_abc_module(PyObject *module);
22458 static PyObject* __Pyx_patch_abc_module(PyObject *module) {
22459  module = __Pyx_Coroutine_patch_module(
22460  module, ""
22461 "if _cython_generator_type is not None:\n"
22462 " try: Generator = _module.Generator\n"
22463 " except AttributeError: pass\n"
22464 " else: Generator.register(_cython_generator_type)\n"
22465 "if _cython_coroutine_type is not None:\n"
22466 " try: Coroutine = _module.Coroutine\n"
22467 " except AttributeError: pass\n"
22468 " else: Coroutine.register(_cython_coroutine_type)\n"
22469  );
22470  return module;
22471 }
22472 #endif
22473 static int __Pyx_patch_abc(void) {
22474 #if defined(__Pyx_Generator_USED) || defined(__Pyx_Coroutine_USED)
22475  static int abc_patched = 0;
22476  if (!abc_patched) {
22477  PyObject *module;
22478  module = PyImport_ImportModule((PY_VERSION_HEX >= 0x03030000) ? "collections.abc" : "collections");
22479  if (!module) {
22480  PyErr_WriteUnraisable(NULL);
22481  if (unlikely(PyErr_WarnEx(PyExc_RuntimeWarning,
22482  ((PY_VERSION_HEX >= 0x03030000) ?
22483  "Cython module failed to register with collections.abc module" :
22484  "Cython module failed to register with collections module"), 1) < 0)) {
22485  return -1;
22486  }
22487  } else {
22488  module = __Pyx_patch_abc_module(module);
22489  abc_patched = 1;
22490  if (unlikely(!module))
22491  return -1;
22492  Py_DECREF(module);
22493  }
22494  module = PyImport_ImportModule("backports_abc");
22495  if (module) {
22496  module = __Pyx_patch_abc_module(module);
22497  Py_XDECREF(module);
22498  }
22499  if (!module) {
22500  PyErr_Clear();
22501  }
22502  }
22503 #else
22504  if (0) __Pyx_Coroutine_patch_module(NULL, NULL);
22505 #endif
22506  return 0;
22507 }
22508 
22509 static PyMethodDef __pyx_Generator_methods[] = {
22510  {"send", (PyCFunction) __Pyx_Coroutine_Send, METH_O,
22511  (char*) PyDoc_STR("send(arg) -> send 'arg' into generator,\nreturn next yielded value or raise StopIteration.")},
22512  {"throw", (PyCFunction) __Pyx_Coroutine_Throw, METH_VARARGS,
22513  (char*) PyDoc_STR("throw(typ[,val[,tb]]) -> raise exception in generator,\nreturn next yielded value or raise StopIteration.")},
22514  {"close", (PyCFunction) __Pyx_Coroutine_Close, METH_NOARGS,
22515  (char*) PyDoc_STR("close() -> raise GeneratorExit inside generator.")},
22516  {0, 0, 0, 0}
22517 };
22518 static PyMemberDef __pyx_Generator_memberlist[] = {
22519  {(char *) "gi_running", T_BOOL, offsetof(__pyx_CoroutineObject, is_running), READONLY, NULL},
22520  {(char*) "gi_yieldfrom", T_OBJECT, offsetof(__pyx_CoroutineObject, yieldfrom), READONLY,
22521  (char*) PyDoc_STR("object being iterated by 'yield from', or None")},
22522  {0, 0, 0, 0, 0}
22523 };
22524 static PyGetSetDef __pyx_Generator_getsets[] = {
22525  {(char *) "__name__", (getter)__Pyx_Coroutine_get_name, (setter)__Pyx_Coroutine_set_name,
22526  (char*) PyDoc_STR("name of the generator"), 0},
22527  {(char *) "__qualname__", (getter)__Pyx_Coroutine_get_qualname, (setter)__Pyx_Coroutine_set_qualname,
22528  (char*) PyDoc_STR("qualified name of the generator"), 0},
22529  {0, 0, 0, 0, 0}
22530 };
22531 static PyTypeObject __pyx_GeneratorType_type = {
22532  PyVarObject_HEAD_INIT(0, 0)
22533  "generator",
22534  sizeof(__pyx_CoroutineObject),
22535  0,
22536  (destructor) __Pyx_Coroutine_dealloc,
22537  0,
22538  0,
22539  0,
22540  0,
22541  0,
22542  0,
22543  0,
22544  0,
22545  0,
22546  0,
22547  0,
22548  0,
22549  0,
22550  0,
22551  Py_TPFLAGS_DEFAULT | Py_TPFLAGS_HAVE_GC | Py_TPFLAGS_HAVE_FINALIZE,
22552  0,
22553  (traverseproc) __Pyx_Coroutine_traverse,
22554  0,
22555  0,
22556  offsetof(__pyx_CoroutineObject, gi_weakreflist),
22557  0,
22558  (iternextfunc) __Pyx_Generator_Next,
22559  __pyx_Generator_methods,
22560  __pyx_Generator_memberlist,
22561  __pyx_Generator_getsets,
22562  0,
22563  0,
22564  0,
22565  0,
22566  0,
22567  0,
22568  0,
22569  0,
22570  0,
22571  0,
22572  0,
22573  0,
22574  0,
22575  0,
22576  0,
22577 #if PY_VERSION_HEX >= 0x030400a1
22578  0,
22579 #else
22580  __Pyx_Coroutine_del,
22581 #endif
22582  0,
22583 #if PY_VERSION_HEX >= 0x030400a1
22584  __Pyx_Coroutine_del,
22585 #endif
22586 };
22587 static int __pyx_Generator_init(void) {
22588  __pyx_GeneratorType_type.tp_getattro = PyObject_GenericGetAttr;
22589  __pyx_GeneratorType_type.tp_iter = PyObject_SelfIter;
22590  __pyx_GeneratorType = __Pyx_FetchCommonType(&__pyx_GeneratorType_type);
22591  if (unlikely(!__pyx_GeneratorType)) {
22592  return -1;
22593  }
22594  return 0;
22595 }
22596 
22597 static int __Pyx_check_binary_version(void) {
22598  char ctversion[4], rtversion[4];
22599  PyOS_snprintf(ctversion, 4, "%d.%d", PY_MAJOR_VERSION, PY_MINOR_VERSION);
22600  PyOS_snprintf(rtversion, 4, "%s", Py_GetVersion());
22601  if (ctversion[0] != rtversion[0] || ctversion[2] != rtversion[2]) {
22602  char message[200];
22603  PyOS_snprintf(message, sizeof(message),
22604  "compiletime version %s of module '%.100s' "
22605  "does not match runtime version %s",
22606  ctversion, __Pyx_MODULE_NAME, rtversion);
22607  return PyErr_WarnEx(NULL, message, 1);
22608  }
22609  return 0;
22610 }
22611 
22612 static int __Pyx_InitStrings(__Pyx_StringTabEntry *t) {
22613  while (t->p) {
22614  #if PY_MAJOR_VERSION < 3
22615  if (t->is_unicode) {
22616  *t->p = PyUnicode_DecodeUTF8(t->s, t->n - 1, NULL);
22617  } else if (t->intern) {
22618  *t->p = PyString_InternFromString(t->s);
22619  } else {
22620  *t->p = PyString_FromStringAndSize(t->s, t->n - 1);
22621  }
22622  #else
22623  if (t->is_unicode | t->is_str) {
22624  if (t->intern) {
22625  *t->p = PyUnicode_InternFromString(t->s);
22626  } else if (t->encoding) {
22627  *t->p = PyUnicode_Decode(t->s, t->n - 1, t->encoding, NULL);
22628  } else {
22629  *t->p = PyUnicode_FromStringAndSize(t->s, t->n - 1);
22630  }
22631  } else {
22632  *t->p = PyBytes_FromStringAndSize(t->s, t->n - 1);
22633  }
22634  #endif
22635  if (!*t->p)
22636  return -1;
22637  ++t;
22638  }
22639  return 0;
22640 }
22641 
22642 static CYTHON_INLINE PyObject* __Pyx_PyUnicode_FromString(const char* c_str) {
22643  return __Pyx_PyUnicode_FromStringAndSize(c_str, (Py_ssize_t)strlen(c_str));
22644 }
22645 static CYTHON_INLINE char* __Pyx_PyObject_AsString(PyObject* o) {
22646  Py_ssize_t ignore;
22647  return __Pyx_PyObject_AsStringAndSize(o, &ignore);
22648 }
22649 static CYTHON_INLINE char* __Pyx_PyObject_AsStringAndSize(PyObject* o, Py_ssize_t *length) {
22650 #if CYTHON_COMPILING_IN_CPYTHON && (__PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT)
22651  if (
22652 #if PY_MAJOR_VERSION < 3 && __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
22653  __Pyx_sys_getdefaultencoding_not_ascii &&
22654 #endif
22655  PyUnicode_Check(o)) {
22656 #if PY_VERSION_HEX < 0x03030000
22657  char* defenc_c;
22658  PyObject* defenc = _PyUnicode_AsDefaultEncodedString(o, NULL);
22659  if (!defenc) return NULL;
22660  defenc_c = PyBytes_AS_STRING(defenc);
22661 #if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
22662  {
22663  char* end = defenc_c + PyBytes_GET_SIZE(defenc);
22664  char* c;
22665  for (c = defenc_c; c < end; c++) {
22666  if ((unsigned char) (*c) >= 128) {
22667  PyUnicode_AsASCIIString(o);
22668  return NULL;
22669  }
22670  }
22671  }
22672 #endif
22673  *length = PyBytes_GET_SIZE(defenc);
22674  return defenc_c;
22675 #else
22676  if (__Pyx_PyUnicode_READY(o) == -1) return NULL;
22677 #if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
22678  if (PyUnicode_IS_ASCII(o)) {
22679  *length = PyUnicode_GET_LENGTH(o);
22680  return PyUnicode_AsUTF8(o);
22681  } else {
22682  PyUnicode_AsASCIIString(o);
22683  return NULL;
22684  }
22685 #else
22686  return PyUnicode_AsUTF8AndSize(o, length);
22687 #endif
22688 #endif
22689  } else
22690 #endif
22691 #if (!CYTHON_COMPILING_IN_PYPY) || (defined(PyByteArray_AS_STRING) && defined(PyByteArray_GET_SIZE))
22692  if (PyByteArray_Check(o)) {
22693  *length = PyByteArray_GET_SIZE(o);
22694  return PyByteArray_AS_STRING(o);
22695  } else
22696 #endif
22697  {
22698  char* result;
22699  int r = PyBytes_AsStringAndSize(o, &result, length);
22700  if (unlikely(r < 0)) {
22701  return NULL;
22702  } else {
22703  return result;
22704  }
22705  }
22706 }
22707 static CYTHON_INLINE int __Pyx_PyObject_IsTrue(PyObject* x) {
22708  int is_true = x == Py_True;
22709  if (is_true | (x == Py_False) | (x == Py_None)) return is_true;
22710  else return PyObject_IsTrue(x);
22711 }
22712 static CYTHON_INLINE PyObject* __Pyx_PyNumber_Int(PyObject* x) {
22713  PyNumberMethods *m;
22714  const char *name = NULL;
22715  PyObject *res = NULL;
22716 #if PY_MAJOR_VERSION < 3
22717  if (PyInt_Check(x) || PyLong_Check(x))
22718 #else
22719  if (PyLong_Check(x))
22720 #endif
22721  return __Pyx_NewRef(x);
22722  m = Py_TYPE(x)->tp_as_number;
22723 #if PY_MAJOR_VERSION < 3
22724  if (m && m->nb_int) {
22725  name = "int";
22726  res = PyNumber_Int(x);
22727  }
22728  else if (m && m->nb_long) {
22729  name = "long";
22730  res = PyNumber_Long(x);
22731  }
22732 #else
22733  if (m && m->nb_int) {
22734  name = "int";
22735  res = PyNumber_Long(x);
22736  }
22737 #endif
22738  if (res) {
22739 #if PY_MAJOR_VERSION < 3
22740  if (!PyInt_Check(res) && !PyLong_Check(res)) {
22741 #else
22742  if (!PyLong_Check(res)) {
22743 #endif
22744  PyErr_Format(PyExc_TypeError,
22745  "__%.4s__ returned non-%.4s (type %.200s)",
22746  name, name, Py_TYPE(res)->tp_name);
22747  Py_DECREF(res);
22748  return NULL;
22749  }
22750  }
22751  else if (!PyErr_Occurred()) {
22752  PyErr_SetString(PyExc_TypeError,
22753  "an integer is required");
22754  }
22755  return res;
22756 }
22757 static CYTHON_INLINE Py_ssize_t __Pyx_PyIndex_AsSsize_t(PyObject* b) {
22758  Py_ssize_t ival;
22759  PyObject *x;
22760 #if PY_MAJOR_VERSION < 3
22761  if (likely(PyInt_CheckExact(b))) {
22762  if (sizeof(Py_ssize_t) >= sizeof(long))
22763  return PyInt_AS_LONG(b);
22764  else
22765  return PyInt_AsSsize_t(x);
22766  }
22767 #endif
22768  if (likely(PyLong_CheckExact(b))) {
22769  #if CYTHON_USE_PYLONG_INTERNALS
22770  const digit* digits = ((PyLongObject*)b)->ob_digit;
22771  const Py_ssize_t size = Py_SIZE(b);
22772  if (likely(__Pyx_sst_abs(size) <= 1)) {
22773  ival = likely(size) ? digits[0] : 0;
22774  if (size == -1) ival = -ival;
22775  return ival;
22776  } else {
22777  switch (size) {
22778  case 2:
22779  if (8 * sizeof(Py_ssize_t) > 2 * PyLong_SHIFT) {
22780  return (Py_ssize_t) (((((size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
22781  }
22782  break;
22783  case -2:
22784  if (8 * sizeof(Py_ssize_t) > 2 * PyLong_SHIFT) {
22785  return -(Py_ssize_t) (((((size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
22786  }
22787  break;
22788  case 3:
22789  if (8 * sizeof(Py_ssize_t) > 3 * PyLong_SHIFT) {
22790  return (Py_ssize_t) (((((((size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
22791  }
22792  break;
22793  case -3:
22794  if (8 * sizeof(Py_ssize_t) > 3 * PyLong_SHIFT) {
22795  return -(Py_ssize_t) (((((((size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
22796  }
22797  break;
22798  case 4:
22799  if (8 * sizeof(Py_ssize_t) > 4 * PyLong_SHIFT) {
22800  return (Py_ssize_t) (((((((((size_t)digits[3]) << PyLong_SHIFT) | (size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
22801  }
22802  break;
22803  case -4:
22804  if (8 * sizeof(Py_ssize_t) > 4 * PyLong_SHIFT) {
22805  return -(Py_ssize_t) (((((((((size_t)digits[3]) << PyLong_SHIFT) | (size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
22806  }
22807  break;
22808  }
22809  }
22810  #endif
22811  return PyLong_AsSsize_t(b);
22812  }
22813  x = PyNumber_Index(b);
22814  if (!x) return -1;
22815  ival = PyInt_AsSsize_t(x);
22816  Py_DECREF(x);
22817  return ival;
22818 }
22819 static CYTHON_INLINE PyObject * __Pyx_PyInt_FromSize_t(size_t ival) {
22820  return PyInt_FromSize_t(ival);
22821 }
22822 
22823 
22824 #endif /* Py_PYTHON_H */
int compare(const index_set< LO, HI > &a, const index_set< LO, HI > &b)
"lexicographic compare" eg. {3,4,5} is less than {3,7,8}
const Multivector< Scalar_T, LO, HI > sqrt(const Multivector< Scalar_T, LO, HI > &val, const Multivector< Scalar_T, LO, HI > &i, const bool prechecked=false)
Square root of multivector with specified complexifier.
String clifford_to_str(const Multivector_T &mv)
The "informal" string representation of Multivector_T mv.
Definition: PyClical.h:98
const Multivector< Scalar_T, LO, HI > acosh(const Multivector< Scalar_T, LO, HI > &val, const Multivector< Scalar_T, LO, HI > &i, const bool prechecked=false)
Inverse hyperbolic cosine of multivector with specified complexifier.
String index_set_to_repr(const Index_Set_T &ist)
The “official” string representation of Index_Set_T ist.
Definition: PyClical.h:69
const Multivector< Scalar_T, LO, HI > sinh(const Multivector< Scalar_T, LO, HI > &val)
Hyperbolic sine of multivector.
index_set< lo_ndx, hi_ndx > IndexSet
Definition: PyClical.h:157
Scalar_T abs(const Multivector< Scalar_T, LO, HI > &val)
Absolute value == sqrt(norm)
const Multivector< Scalar_T, LO, HI > log(const Multivector< Scalar_T, LO, HI > &val, const Multivector< Scalar_T, LO, HI > &i, const bool prechecked=false)
Natural logarithm of multivector with specified complexifier.
String clifford_to_repr(const Multivector_T &mv)
The “official” string representation of Multivector_T mv.
Definition: PyClical.h:87
Multivector_T cga3(const Multivector_T &x)
Convert Euclidean 3D vector to Conformal Geometric Algebra null vector [DL (10.50)].
Definition: PyClical.h:115
const Multivector< Scalar_T, LO, HI > sin(const Multivector< Scalar_T, LO, HI > &val, const Multivector< Scalar_T, LO, HI > &i, const bool prechecked=false)
Sine of multivector with specified complexifier.
const Multivector< Scalar_T, LO, HI > atanh(const Multivector< Scalar_T, LO, HI > &val, const Multivector< Scalar_T, LO, HI > &i, const bool prechecked=false)
Inverse hyperbolic tangent of multivector with specified complexifier.
const framed_multi< Scalar_T, LO, HI > exp(const framed_multi< Scalar_T, LO, HI > &val)
Exponential of multivector.
const Multivector< Scalar_T, LO, HI > cos(const Multivector< Scalar_T, LO, HI > &val, const Multivector< Scalar_T, LO, HI > &i, const bool prechecked=false)
Cosine of multivector with specified complexifier.
const Multivector< Scalar_T, LO, HI > tanh(const Multivector< Scalar_T, LO, HI > &val)
Hyperbolic tangent of multivector.
index_t min_neg(const index_set< LO, HI > &ist)
Minimum negative index, or 0 if none.
const Multivector< Scalar_T, LO, HI > asin(const Multivector< Scalar_T, LO, HI > &val, const Multivector< Scalar_T, LO, HI > &i, const bool prechecked=false)
Inverse sine of multivector with specified complexifier.
matrix_multi< scalar_t > Clifford
Definition: PyClical.h:160
const Multivector< Scalar_T, LO, HI > complexifier(const Multivector< Scalar_T, LO, HI > &val)
Square root of -1 which commutes with all members of the frame of the given multivector.
PyObject * PyFloat_FromDouble(Scalar_T v)
Definition: PyClical.h:59
const Multivector< Scalar_T, LO, HI > atan(const Multivector< Scalar_T, LO, HI > &val, const Multivector< Scalar_T, LO, HI > &i, const bool prechecked=false)
Inverse tangent of multivector with specified complexifier.
double scalar_t
Definition: PyClical.h:159
const Multivector< Scalar_T, LO, HI > tan(const Multivector< Scalar_T, LO, HI > &val, const Multivector< Scalar_T, LO, HI > &i, const bool prechecked=false)
Tangent of multivector with specified complexifier.
const Multivector< Scalar_T, LO, HI > acos(const Multivector< Scalar_T, LO, HI > &val, const Multivector< Scalar_T, LO, HI > &i, const bool prechecked=false)
Inverse cosine of multivector with specified complexifier.
String index_set_to_str(const Index_Set_T &ist)
The "informal" string representation of Index_Set_T ist.
Definition: PyClical.h:78
index_t max_pos(const index_set< LO, HI > &ist)
Maximum positive index, or 0 if none.
const Multivector< Scalar_T, LO, HI > asinh(const Multivector< Scalar_T, LO, HI > &val, const Multivector< Scalar_T, LO, HI > &i, const bool prechecked=false)
Inverse hyperbolic sine of multivector with specified complexifier.
Scalar_T max_abs(const Multivector< Scalar_T, LO, HI > &val)
Maximum of absolute values of components of multivector: multivector infinity norm.
def e(obj)
Definition: PyClical.pyx:1887
const Multivector< Scalar_T, LO, HI > cosh(const Multivector< Scalar_T, LO, HI > &val)
Hyperbolic cosine of multivector.
Multivector_T cga3std(const Multivector_T &X)
Convert CGA3 null vector to standard Conformal Geometric Algebra null vector [DL (10.52)].
Definition: PyClical.h:126
Multivector_T agc3(const Multivector_T &X)
Convert CGA3 null vector to Euclidean 3D vector [DL (10.50)].
Definition: PyClical.h:138