3 #ifndef PY_SSIZE_T_CLEAN
4 #define PY_SSIZE_T_CLEAN
8 #error Python headers needed to compile C extensions, please install development version of Python.
9 #elif PY_VERSION_HEX < 0x02060000 || (0x03000000 <= PY_VERSION_HEX && PY_VERSION_HEX < 0x03030000)
10 #error Cython requires Python 2.6+ or Python 3.3+.
12 #define CYTHON_ABI "0_29_30"
13 #define CYTHON_HEX_VERSION 0x001D1EF0
14 #define CYTHON_FUTURE_DIVISION 0
17 #define offsetof(type, member) ( (size_t) & ((type*)0) -> member )
19 #if !defined(WIN32) && !defined(MS_WINDOWS)
31 #define DL_IMPORT(t) t
34 #define DL_EXPORT(t) t
37 #ifndef HAVE_LONG_LONG
38 #if PY_VERSION_HEX >= 0x02070000
39 #define HAVE_LONG_LONG
43 #define PY_LONG_LONG LONG_LONG
46 #define Py_HUGE_VAL HUGE_VAL
49 #define CYTHON_COMPILING_IN_PYPY 1
50 #define CYTHON_COMPILING_IN_PYSTON 0
51 #define CYTHON_COMPILING_IN_CPYTHON 0
52 #undef CYTHON_USE_TYPE_SLOTS
53 #define CYTHON_USE_TYPE_SLOTS 0
54 #undef CYTHON_USE_PYTYPE_LOOKUP
55 #define CYTHON_USE_PYTYPE_LOOKUP 0
56 #if PY_VERSION_HEX < 0x03050000
57 #undef CYTHON_USE_ASYNC_SLOTS
58 #define CYTHON_USE_ASYNC_SLOTS 0
59 #elif !defined(CYTHON_USE_ASYNC_SLOTS)
60 #define CYTHON_USE_ASYNC_SLOTS 1
62 #undef CYTHON_USE_PYLIST_INTERNALS
63 #define CYTHON_USE_PYLIST_INTERNALS 0
64 #undef CYTHON_USE_UNICODE_INTERNALS
65 #define CYTHON_USE_UNICODE_INTERNALS 0
66 #undef CYTHON_USE_UNICODE_WRITER
67 #define CYTHON_USE_UNICODE_WRITER 0
68 #undef CYTHON_USE_PYLONG_INTERNALS
69 #define CYTHON_USE_PYLONG_INTERNALS 0
70 #undef CYTHON_AVOID_BORROWED_REFS
71 #define CYTHON_AVOID_BORROWED_REFS 1
72 #undef CYTHON_ASSUME_SAFE_MACROS
73 #define CYTHON_ASSUME_SAFE_MACROS 0
74 #undef CYTHON_UNPACK_METHODS
75 #define CYTHON_UNPACK_METHODS 0
76 #undef CYTHON_FAST_THREAD_STATE
77 #define CYTHON_FAST_THREAD_STATE 0
78 #undef CYTHON_FAST_PYCALL
79 #define CYTHON_FAST_PYCALL 0
80 #undef CYTHON_PEP489_MULTI_PHASE_INIT
81 #define CYTHON_PEP489_MULTI_PHASE_INIT 0
82 #undef CYTHON_USE_TP_FINALIZE
83 #define CYTHON_USE_TP_FINALIZE 0
84 #undef CYTHON_USE_DICT_VERSIONS
85 #define CYTHON_USE_DICT_VERSIONS 0
86 #undef CYTHON_USE_EXC_INFO_STACK
87 #define CYTHON_USE_EXC_INFO_STACK 0
88 #ifndef CYTHON_UPDATE_DESCRIPTOR_DOC
89 #define CYTHON_UPDATE_DESCRIPTOR_DOC (PYPY_VERSION_HEX >= 0x07030900)
91 #elif defined(PYSTON_VERSION)
92 #define CYTHON_COMPILING_IN_PYPY 0
93 #define CYTHON_COMPILING_IN_PYSTON 1
94 #define CYTHON_COMPILING_IN_CPYTHON 0
95 #ifndef CYTHON_USE_TYPE_SLOTS
96 #define CYTHON_USE_TYPE_SLOTS 1
98 #undef CYTHON_USE_PYTYPE_LOOKUP
99 #define CYTHON_USE_PYTYPE_LOOKUP 0
100 #undef CYTHON_USE_ASYNC_SLOTS
101 #define CYTHON_USE_ASYNC_SLOTS 0
102 #undef CYTHON_USE_PYLIST_INTERNALS
103 #define CYTHON_USE_PYLIST_INTERNALS 0
104 #ifndef CYTHON_USE_UNICODE_INTERNALS
105 #define CYTHON_USE_UNICODE_INTERNALS 1
107 #undef CYTHON_USE_UNICODE_WRITER
108 #define CYTHON_USE_UNICODE_WRITER 0
109 #undef CYTHON_USE_PYLONG_INTERNALS
110 #define CYTHON_USE_PYLONG_INTERNALS 0
111 #ifndef CYTHON_AVOID_BORROWED_REFS
112 #define CYTHON_AVOID_BORROWED_REFS 0
114 #ifndef CYTHON_ASSUME_SAFE_MACROS
115 #define CYTHON_ASSUME_SAFE_MACROS 1
117 #ifndef CYTHON_UNPACK_METHODS
118 #define CYTHON_UNPACK_METHODS 1
120 #undef CYTHON_FAST_THREAD_STATE
121 #define CYTHON_FAST_THREAD_STATE 0
122 #undef CYTHON_FAST_PYCALL
123 #define CYTHON_FAST_PYCALL 0
124 #undef CYTHON_PEP489_MULTI_PHASE_INIT
125 #define CYTHON_PEP489_MULTI_PHASE_INIT 0
126 #undef CYTHON_USE_TP_FINALIZE
127 #define CYTHON_USE_TP_FINALIZE 0
128 #undef CYTHON_USE_DICT_VERSIONS
129 #define CYTHON_USE_DICT_VERSIONS 0
130 #undef CYTHON_USE_EXC_INFO_STACK
131 #define CYTHON_USE_EXC_INFO_STACK 0
132 #ifndef CYTHON_UPDATE_DESCRIPTOR_DOC
133 #define CYTHON_UPDATE_DESCRIPTOR_DOC 0
136 #define CYTHON_COMPILING_IN_PYPY 0
137 #define CYTHON_COMPILING_IN_PYSTON 0
138 #define CYTHON_COMPILING_IN_CPYTHON 1
139 #ifndef CYTHON_USE_TYPE_SLOTS
140 #define CYTHON_USE_TYPE_SLOTS 1
142 #if PY_VERSION_HEX < 0x02070000
143 #undef CYTHON_USE_PYTYPE_LOOKUP
144 #define CYTHON_USE_PYTYPE_LOOKUP 0
145 #elif !defined(CYTHON_USE_PYTYPE_LOOKUP)
146 #define CYTHON_USE_PYTYPE_LOOKUP 1
148 #if PY_MAJOR_VERSION < 3
149 #undef CYTHON_USE_ASYNC_SLOTS
150 #define CYTHON_USE_ASYNC_SLOTS 0
151 #elif !defined(CYTHON_USE_ASYNC_SLOTS)
152 #define CYTHON_USE_ASYNC_SLOTS 1
154 #if PY_VERSION_HEX < 0x02070000
155 #undef CYTHON_USE_PYLONG_INTERNALS
156 #define CYTHON_USE_PYLONG_INTERNALS 0
157 #elif !defined(CYTHON_USE_PYLONG_INTERNALS)
158 #define CYTHON_USE_PYLONG_INTERNALS 1
160 #ifndef CYTHON_USE_PYLIST_INTERNALS
161 #define CYTHON_USE_PYLIST_INTERNALS 1
163 #ifndef CYTHON_USE_UNICODE_INTERNALS
164 #define CYTHON_USE_UNICODE_INTERNALS 1
166 #if PY_VERSION_HEX < 0x030300F0 || PY_VERSION_HEX >= 0x030B00A2
167 #undef CYTHON_USE_UNICODE_WRITER
168 #define CYTHON_USE_UNICODE_WRITER 0
169 #elif !defined(CYTHON_USE_UNICODE_WRITER)
170 #define CYTHON_USE_UNICODE_WRITER 1
172 #ifndef CYTHON_AVOID_BORROWED_REFS
173 #define CYTHON_AVOID_BORROWED_REFS 0
175 #ifndef CYTHON_ASSUME_SAFE_MACROS
176 #define CYTHON_ASSUME_SAFE_MACROS 1
178 #ifndef CYTHON_UNPACK_METHODS
179 #define CYTHON_UNPACK_METHODS 1
181 #if PY_VERSION_HEX >= 0x030B00A4
182 #undef CYTHON_FAST_THREAD_STATE
183 #define CYTHON_FAST_THREAD_STATE 0
184 #elif !defined(CYTHON_FAST_THREAD_STATE)
185 #define CYTHON_FAST_THREAD_STATE 1
187 #ifndef CYTHON_FAST_PYCALL
188 #define CYTHON_FAST_PYCALL (PY_VERSION_HEX < 0x030A0000)
190 #ifndef CYTHON_PEP489_MULTI_PHASE_INIT
191 #define CYTHON_PEP489_MULTI_PHASE_INIT (PY_VERSION_HEX >= 0x03050000)
193 #ifndef CYTHON_USE_TP_FINALIZE
194 #define CYTHON_USE_TP_FINALIZE (PY_VERSION_HEX >= 0x030400a1)
196 #ifndef CYTHON_USE_DICT_VERSIONS
197 #define CYTHON_USE_DICT_VERSIONS (PY_VERSION_HEX >= 0x030600B1)
199 #if PY_VERSION_HEX >= 0x030B00A4
200 #undef CYTHON_USE_EXC_INFO_STACK
201 #define CYTHON_USE_EXC_INFO_STACK 0
202 #elif !defined(CYTHON_USE_EXC_INFO_STACK)
203 #define CYTHON_USE_EXC_INFO_STACK (PY_VERSION_HEX >= 0x030700A3)
205 #ifndef CYTHON_UPDATE_DESCRIPTOR_DOC
206 #define CYTHON_UPDATE_DESCRIPTOR_DOC 1
209 #if !defined(CYTHON_FAST_PYCCALL)
210 #define CYTHON_FAST_PYCCALL (CYTHON_FAST_PYCALL && PY_VERSION_HEX >= 0x030600B1)
212 #if CYTHON_USE_PYLONG_INTERNALS
213 #if PY_MAJOR_VERSION < 3
214 #include "longintrepr.h"
220 enum { __pyx_check_sizeof_voidp = 1 / (int)(SIZEOF_VOID_P ==
sizeof(
void*)) };
223 #ifndef __has_attribute
224 #define __has_attribute(x) 0
226 #ifndef __has_cpp_attribute
227 #define __has_cpp_attribute(x) 0
229 #ifndef CYTHON_RESTRICT
230 #if defined(__GNUC__)
231 #define CYTHON_RESTRICT __restrict__
232 #elif defined(_MSC_VER) && _MSC_VER >= 1400
233 #define CYTHON_RESTRICT __restrict
234 #elif defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
235 #define CYTHON_RESTRICT restrict
237 #define CYTHON_RESTRICT
240 #ifndef CYTHON_UNUSED
241 # if defined(__GNUC__)
242 # if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
243 # define CYTHON_UNUSED __attribute__ ((__unused__))
245 # define CYTHON_UNUSED
247 # elif defined(__ICC) || (defined(__INTEL_COMPILER) && !defined(_MSC_VER))
248 # define CYTHON_UNUSED __attribute__ ((__unused__))
250 # define CYTHON_UNUSED
253 #ifndef CYTHON_MAYBE_UNUSED_VAR
254 # if defined(__cplusplus)
255 template<
class T>
void CYTHON_MAYBE_UNUSED_VAR(
const T& ) { }
257 # define CYTHON_MAYBE_UNUSED_VAR(x) (void)(x)
260 #ifndef CYTHON_NCP_UNUSED
261 # if CYTHON_COMPILING_IN_CPYTHON
262 # define CYTHON_NCP_UNUSED
264 # define CYTHON_NCP_UNUSED CYTHON_UNUSED
267 #define __Pyx_void_to_None(void_result) ((void)(void_result), Py_INCREF(Py_None), Py_None)
269 #ifndef _MSC_STDINT_H_
271 typedef unsigned char uint8_t;
272 typedef unsigned int uint32_t;
274 typedef unsigned __int8 uint8_t;
275 typedef unsigned __int32 uint32_t;
281 #ifndef CYTHON_FALLTHROUGH
282 #if defined(__cplusplus) && __cplusplus >= 201103L
283 #if __has_cpp_attribute(fallthrough)
284 #define CYTHON_FALLTHROUGH [[fallthrough]]
285 #elif __has_cpp_attribute(clang::fallthrough)
286 #define CYTHON_FALLTHROUGH [[clang::fallthrough]]
287 #elif __has_cpp_attribute(gnu::fallthrough)
288 #define CYTHON_FALLTHROUGH [[gnu::fallthrough]]
291 #ifndef CYTHON_FALLTHROUGH
292 #if __has_attribute(fallthrough)
293 #define CYTHON_FALLTHROUGH __attribute__((fallthrough))
295 #define CYTHON_FALLTHROUGH
298 #if defined(__clang__ ) && defined(__apple_build_version__)
299 #if __apple_build_version__ < 7000000
300 #undef CYTHON_FALLTHROUGH
301 #define CYTHON_FALLTHROUGH
306 #ifndef CYTHON_INLINE
307 #if defined(__clang__)
308 #define CYTHON_INLINE __inline__ __attribute__ ((__unused__))
309 #elif defined(__GNUC__)
310 #define CYTHON_INLINE __inline__
311 #elif defined(_MSC_VER)
312 #define CYTHON_INLINE __inline
313 #elif defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
314 #define CYTHON_INLINE inline
316 #define CYTHON_INLINE
320 #if CYTHON_COMPILING_IN_PYPY && PY_VERSION_HEX < 0x02070600 && !defined(Py_OptimizeFlag)
321 #define Py_OptimizeFlag 0
323 #define __PYX_BUILD_PY_SSIZE_T "n"
324 #define CYTHON_FORMAT_SSIZE_T "z"
325 #if PY_MAJOR_VERSION < 3
326 #define __Pyx_BUILTIN_MODULE_NAME "__builtin__"
327 #define __Pyx_PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)\
328 PyCode_New(a+k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)
329 #define __Pyx_DefaultClassType PyClass_Type
331 #define __Pyx_BUILTIN_MODULE_NAME "builtins"
332 #define __Pyx_DefaultClassType PyType_Type
333 #if PY_VERSION_HEX >= 0x030B00A1
334 static CYTHON_INLINE PyCodeObject* __Pyx_PyCode_New(
int a,
int k,
int l,
int s,
int f,
335 PyObject *code, PyObject *
c, PyObject*
n, PyObject *
v,
336 PyObject *fv, PyObject *cell, PyObject* fn,
337 PyObject *name,
int fline, PyObject *lnos) {
338 PyObject *kwds=NULL, *argcount=NULL, *posonlyargcount=NULL, *kwonlyargcount=NULL;
339 PyObject *nlocals=NULL, *stacksize=NULL, *flags=NULL, *replace=NULL, *call_result=NULL, *empty=NULL;
340 const char *fn_cstr=NULL;
341 const char *name_cstr=NULL;
342 PyCodeObject* co=NULL;
343 PyObject *type, *value, *traceback;
344 PyErr_Fetch(&type, &value, &traceback);
345 if (!(kwds=PyDict_New()))
goto end;
346 if (!(argcount=PyLong_FromLong(a)))
goto end;
347 if (PyDict_SetItemString(kwds,
"co_argcount", argcount) != 0)
goto end;
348 if (!(posonlyargcount=PyLong_FromLong(0)))
goto end;
349 if (PyDict_SetItemString(kwds,
"co_posonlyargcount", posonlyargcount) != 0)
goto end;
350 if (!(kwonlyargcount=PyLong_FromLong(k)))
goto end;
351 if (PyDict_SetItemString(kwds,
"co_kwonlyargcount", kwonlyargcount) != 0)
goto end;
352 if (!(nlocals=PyLong_FromLong(l)))
goto end;
353 if (PyDict_SetItemString(kwds,
"co_nlocals", nlocals) != 0)
goto end;
354 if (!(stacksize=PyLong_FromLong(
s)))
goto end;
355 if (PyDict_SetItemString(kwds,
"co_stacksize", stacksize) != 0)
goto end;
356 if (!(flags=PyLong_FromLong(
f)))
goto end;
357 if (PyDict_SetItemString(kwds,
"co_flags", flags) != 0)
goto end;
358 if (PyDict_SetItemString(kwds,
"co_code", code) != 0)
goto end;
359 if (PyDict_SetItemString(kwds,
"co_consts",
c) != 0)
goto end;
360 if (PyDict_SetItemString(kwds,
"co_names",
n) != 0)
goto end;
361 if (PyDict_SetItemString(kwds,
"co_varnames",
v) != 0)
goto end;
362 if (PyDict_SetItemString(kwds,
"co_freevars", fv) != 0)
goto end;
363 if (PyDict_SetItemString(kwds,
"co_cellvars", cell) != 0)
goto end;
364 if (PyDict_SetItemString(kwds,
"co_linetable", lnos) != 0)
goto end;
365 if (!(fn_cstr=PyUnicode_AsUTF8AndSize(fn, NULL)))
goto end;
366 if (!(name_cstr=PyUnicode_AsUTF8AndSize(name, NULL)))
goto end;
367 if (!(co = PyCode_NewEmpty(fn_cstr, name_cstr, fline)))
goto end;
368 if (!(replace = PyObject_GetAttrString((PyObject*)co,
"replace")))
goto cleanup_code_too;
369 if (!(empty = PyTuple_New(0)))
goto cleanup_code_too;
370 if (!(call_result = PyObject_Call(replace, empty, kwds)))
goto cleanup_code_too;
371 Py_XDECREF((PyObject*)co);
372 co = (PyCodeObject*)call_result;
376 Py_XDECREF((PyObject*)co);
381 Py_XDECREF(argcount);
382 Py_XDECREF(posonlyargcount);
383 Py_XDECREF(kwonlyargcount);
385 Py_XDECREF(stacksize);
387 Py_XDECREF(call_result);
390 PyErr_Restore(type, value, traceback);
395 #define __Pyx_PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)\
396 PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)
398 #define __Pyx_DefaultClassType PyType_Type
400 #ifndef Py_TPFLAGS_CHECKTYPES
401 #define Py_TPFLAGS_CHECKTYPES 0
403 #ifndef Py_TPFLAGS_HAVE_INDEX
404 #define Py_TPFLAGS_HAVE_INDEX 0
406 #ifndef Py_TPFLAGS_HAVE_NEWBUFFER
407 #define Py_TPFLAGS_HAVE_NEWBUFFER 0
409 #ifndef Py_TPFLAGS_HAVE_FINALIZE
410 #define Py_TPFLAGS_HAVE_FINALIZE 0
412 #ifndef METH_STACKLESS
413 #define METH_STACKLESS 0
415 #if PY_VERSION_HEX <= 0x030700A3 || !defined(METH_FASTCALL)
416 #ifndef METH_FASTCALL
417 #define METH_FASTCALL 0x80
419 typedef PyObject *(*__Pyx_PyCFunctionFast) (PyObject *
self, PyObject *
const *args, Py_ssize_t nargs);
420 typedef PyObject *(*__Pyx_PyCFunctionFastWithKeywords) (PyObject *
self, PyObject *
const *args,
421 Py_ssize_t nargs, PyObject *kwnames);
423 #define __Pyx_PyCFunctionFast _PyCFunctionFast
424 #define __Pyx_PyCFunctionFastWithKeywords _PyCFunctionFastWithKeywords
426 #if CYTHON_FAST_PYCCALL
427 #define __Pyx_PyFastCFunction_Check(func)\
428 ((PyCFunction_Check(func) && (METH_FASTCALL == (PyCFunction_GET_FLAGS(func) & ~(METH_CLASS | METH_STATIC | METH_COEXIST | METH_KEYWORDS | METH_STACKLESS)))))
430 #define __Pyx_PyFastCFunction_Check(func) 0
432 #if CYTHON_COMPILING_IN_PYPY && !defined(PyObject_Malloc)
433 #define PyObject_Malloc(s) PyMem_Malloc(s)
434 #define PyObject_Free(p) PyMem_Free(p)
435 #define PyObject_Realloc(p) PyMem_Realloc(p)
437 #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX < 0x030400A1
438 #define PyMem_RawMalloc(n) PyMem_Malloc(n)
439 #define PyMem_RawRealloc(p, n) PyMem_Realloc(p, n)
440 #define PyMem_RawFree(p) PyMem_Free(p)
442 #if CYTHON_COMPILING_IN_PYSTON
443 #define __Pyx_PyCode_HasFreeVars(co) PyCode_HasFreeVars(co)
444 #define __Pyx_PyFrame_SetLineNumber(frame, lineno) PyFrame_SetLineNumber(frame, lineno)
446 #define __Pyx_PyCode_HasFreeVars(co) (PyCode_GetNumFree(co) > 0)
447 #define __Pyx_PyFrame_SetLineNumber(frame, lineno) (frame)->f_lineno = (lineno)
449 #if !CYTHON_FAST_THREAD_STATE || PY_VERSION_HEX < 0x02070000
450 #define __Pyx_PyThreadState_Current PyThreadState_GET()
451 #elif PY_VERSION_HEX >= 0x03060000
452 #define __Pyx_PyThreadState_Current _PyThreadState_UncheckedGet()
453 #elif PY_VERSION_HEX >= 0x03000000
454 #define __Pyx_PyThreadState_Current PyThreadState_GET()
456 #define __Pyx_PyThreadState_Current _PyThreadState_Current
458 #if PY_VERSION_HEX < 0x030700A2 && !defined(PyThread_tss_create) && !defined(Py_tss_NEEDS_INIT)
459 #include "pythread.h"
460 #define Py_tss_NEEDS_INIT 0
461 typedef int Py_tss_t;
462 static CYTHON_INLINE
int PyThread_tss_create(Py_tss_t *key) {
463 *key = PyThread_create_key();
466 static CYTHON_INLINE Py_tss_t * PyThread_tss_alloc(
void) {
467 Py_tss_t *key = (Py_tss_t *)PyObject_Malloc(
sizeof(Py_tss_t));
468 *key = Py_tss_NEEDS_INIT;
471 static CYTHON_INLINE
void PyThread_tss_free(Py_tss_t *key) {
474 static CYTHON_INLINE
int PyThread_tss_is_created(Py_tss_t *key) {
475 return *key != Py_tss_NEEDS_INIT;
477 static CYTHON_INLINE
void PyThread_tss_delete(Py_tss_t *key) {
478 PyThread_delete_key(*key);
479 *key = Py_tss_NEEDS_INIT;
481 static CYTHON_INLINE
int PyThread_tss_set(Py_tss_t *key,
void *value) {
482 return PyThread_set_key_value(*key, value);
484 static CYTHON_INLINE
void * PyThread_tss_get(Py_tss_t *key) {
485 return PyThread_get_key_value(*key);
488 #if CYTHON_COMPILING_IN_CPYTHON || defined(_PyDict_NewPresized)
489 #define __Pyx_PyDict_NewPresized(n) ((n <= 8) ? PyDict_New() : _PyDict_NewPresized(n))
491 #define __Pyx_PyDict_NewPresized(n) PyDict_New()
493 #if PY_MAJOR_VERSION >= 3 || CYTHON_FUTURE_DIVISION
494 #define __Pyx_PyNumber_Divide(x,y) PyNumber_TrueDivide(x,y)
495 #define __Pyx_PyNumber_InPlaceDivide(x,y) PyNumber_InPlaceTrueDivide(x,y)
497 #define __Pyx_PyNumber_Divide(x,y) PyNumber_Divide(x,y)
498 #define __Pyx_PyNumber_InPlaceDivide(x,y) PyNumber_InPlaceDivide(x,y)
500 #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x030500A1 && CYTHON_USE_UNICODE_INTERNALS
501 #define __Pyx_PyDict_GetItemStr(dict, name) _PyDict_GetItem_KnownHash(dict, name, ((PyASCIIObject *) name)->hash)
503 #define __Pyx_PyDict_GetItemStr(dict, name) PyDict_GetItem(dict, name)
505 #if PY_VERSION_HEX > 0x03030000 && defined(PyUnicode_KIND)
506 #define CYTHON_PEP393_ENABLED 1
507 #if defined(PyUnicode_IS_READY)
508 #define __Pyx_PyUnicode_READY(op) (likely(PyUnicode_IS_READY(op)) ?\
509 0 : _PyUnicode_Ready((PyObject *)(op)))
511 #define __Pyx_PyUnicode_READY(op) (0)
513 #define __Pyx_PyUnicode_GET_LENGTH(u) PyUnicode_GET_LENGTH(u)
514 #define __Pyx_PyUnicode_READ_CHAR(u, i) PyUnicode_READ_CHAR(u, i)
515 #define __Pyx_PyUnicode_MAX_CHAR_VALUE(u) PyUnicode_MAX_CHAR_VALUE(u)
516 #define __Pyx_PyUnicode_KIND(u) PyUnicode_KIND(u)
517 #define __Pyx_PyUnicode_DATA(u) PyUnicode_DATA(u)
518 #define __Pyx_PyUnicode_READ(k, d, i) PyUnicode_READ(k, d, i)
519 #define __Pyx_PyUnicode_WRITE(k, d, i, ch) PyUnicode_WRITE(k, d, i, ch)
520 #if defined(PyUnicode_IS_READY) && defined(PyUnicode_GET_SIZE)
521 #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x03090000
522 #define __Pyx_PyUnicode_IS_TRUE(u) (0 != (likely(PyUnicode_IS_READY(u)) ? PyUnicode_GET_LENGTH(u) : ((PyCompactUnicodeObject *)(u))->wstr_length))
524 #define __Pyx_PyUnicode_IS_TRUE(u) (0 != (likely(PyUnicode_IS_READY(u)) ? PyUnicode_GET_LENGTH(u) : PyUnicode_GET_SIZE(u)))
527 #define __Pyx_PyUnicode_IS_TRUE(u) (0 != PyUnicode_GET_LENGTH(u))
530 #define CYTHON_PEP393_ENABLED 0
531 #define PyUnicode_1BYTE_KIND 1
532 #define PyUnicode_2BYTE_KIND 2
533 #define PyUnicode_4BYTE_KIND 4
534 #define __Pyx_PyUnicode_READY(op) (0)
535 #define __Pyx_PyUnicode_GET_LENGTH(u) PyUnicode_GET_SIZE(u)
536 #define __Pyx_PyUnicode_READ_CHAR(u, i) ((Py_UCS4)(PyUnicode_AS_UNICODE(u)[i]))
537 #define __Pyx_PyUnicode_MAX_CHAR_VALUE(u) ((sizeof(Py_UNICODE) == 2) ? 65535 : 1114111)
538 #define __Pyx_PyUnicode_KIND(u) (sizeof(Py_UNICODE))
539 #define __Pyx_PyUnicode_DATA(u) ((void*)PyUnicode_AS_UNICODE(u))
540 #define __Pyx_PyUnicode_READ(k, d, i) ((void)(k), (Py_UCS4)(((Py_UNICODE*)d)[i]))
541 #define __Pyx_PyUnicode_WRITE(k, d, i, ch) (((void)(k)), ((Py_UNICODE*)d)[i] = ch)
542 #define __Pyx_PyUnicode_IS_TRUE(u) (0 != PyUnicode_GET_SIZE(u))
544 #if CYTHON_COMPILING_IN_PYPY
545 #define __Pyx_PyUnicode_Concat(a, b) PyNumber_Add(a, b)
546 #define __Pyx_PyUnicode_ConcatSafe(a, b) PyNumber_Add(a, b)
548 #define __Pyx_PyUnicode_Concat(a, b) PyUnicode_Concat(a, b)
549 #define __Pyx_PyUnicode_ConcatSafe(a, b) ((unlikely((a) == Py_None) || unlikely((b) == Py_None)) ?\
550 PyNumber_Add(a, b) : __Pyx_PyUnicode_Concat(a, b))
552 #if CYTHON_COMPILING_IN_PYPY && !defined(PyUnicode_Contains)
553 #define PyUnicode_Contains(u, s) PySequence_Contains(u, s)
555 #if CYTHON_COMPILING_IN_PYPY && !defined(PyByteArray_Check)
556 #define PyByteArray_Check(obj) PyObject_TypeCheck(obj, &PyByteArray_Type)
558 #if CYTHON_COMPILING_IN_PYPY && !defined(PyObject_Format)
559 #define PyObject_Format(obj, fmt) PyObject_CallMethod(obj, "__format__", "O", fmt)
561 #define __Pyx_PyString_FormatSafe(a, b) ((unlikely((a) == Py_None || (PyString_Check(b) && !PyString_CheckExact(b)))) ? PyNumber_Remainder(a, b) : __Pyx_PyString_Format(a, b))
562 #define __Pyx_PyUnicode_FormatSafe(a, b) ((unlikely((a) == Py_None || (PyUnicode_Check(b) && !PyUnicode_CheckExact(b)))) ? PyNumber_Remainder(a, b) : PyUnicode_Format(a, b))
563 #if PY_MAJOR_VERSION >= 3
564 #define __Pyx_PyString_Format(a, b) PyUnicode_Format(a, b)
566 #define __Pyx_PyString_Format(a, b) PyString_Format(a, b)
568 #if PY_MAJOR_VERSION < 3 && !defined(PyObject_ASCII)
569 #define PyObject_ASCII(o) PyObject_Repr(o)
571 #if PY_MAJOR_VERSION >= 3
572 #define PyBaseString_Type PyUnicode_Type
573 #define PyStringObject PyUnicodeObject
574 #define PyString_Type PyUnicode_Type
575 #define PyString_Check PyUnicode_Check
576 #define PyString_CheckExact PyUnicode_CheckExact
577 #ifndef PyObject_Unicode
578 #define PyObject_Unicode PyObject_Str
581 #if PY_MAJOR_VERSION >= 3
582 #define __Pyx_PyBaseString_Check(obj) PyUnicode_Check(obj)
583 #define __Pyx_PyBaseString_CheckExact(obj) PyUnicode_CheckExact(obj)
585 #define __Pyx_PyBaseString_Check(obj) (PyString_Check(obj) || PyUnicode_Check(obj))
586 #define __Pyx_PyBaseString_CheckExact(obj) (PyString_CheckExact(obj) || PyUnicode_CheckExact(obj))
588 #ifndef PySet_CheckExact
589 #define PySet_CheckExact(obj) (Py_TYPE(obj) == &PySet_Type)
591 #if PY_VERSION_HEX >= 0x030900A4
592 #define __Pyx_SET_REFCNT(obj, refcnt) Py_SET_REFCNT(obj, refcnt)
593 #define __Pyx_SET_SIZE(obj, size) Py_SET_SIZE(obj, size)
595 #define __Pyx_SET_REFCNT(obj, refcnt) Py_REFCNT(obj) = (refcnt)
596 #define __Pyx_SET_SIZE(obj, size) Py_SIZE(obj) = (size)
598 #if CYTHON_ASSUME_SAFE_MACROS
599 #define __Pyx_PySequence_SIZE(seq) Py_SIZE(seq)
601 #define __Pyx_PySequence_SIZE(seq) PySequence_Size(seq)
603 #if PY_MAJOR_VERSION >= 3
604 #define PyIntObject PyLongObject
605 #define PyInt_Type PyLong_Type
606 #define PyInt_Check(op) PyLong_Check(op)
607 #define PyInt_CheckExact(op) PyLong_CheckExact(op)
608 #define PyInt_FromString PyLong_FromString
609 #define PyInt_FromUnicode PyLong_FromUnicode
610 #define PyInt_FromLong PyLong_FromLong
611 #define PyInt_FromSize_t PyLong_FromSize_t
612 #define PyInt_FromSsize_t PyLong_FromSsize_t
613 #define PyInt_AsLong PyLong_AsLong
614 #define PyInt_AS_LONG PyLong_AS_LONG
615 #define PyInt_AsSsize_t PyLong_AsSsize_t
616 #define PyInt_AsUnsignedLongMask PyLong_AsUnsignedLongMask
617 #define PyInt_AsUnsignedLongLongMask PyLong_AsUnsignedLongLongMask
618 #define PyNumber_Int PyNumber_Long
620 #if PY_MAJOR_VERSION >= 3
621 #define PyBoolObject PyLongObject
623 #if PY_MAJOR_VERSION >= 3 && CYTHON_COMPILING_IN_PYPY
624 #ifndef PyUnicode_InternFromString
625 #define PyUnicode_InternFromString(s) PyUnicode_FromString(s)
628 #if PY_VERSION_HEX < 0x030200A4
629 typedef long Py_hash_t;
630 #define __Pyx_PyInt_FromHash_t PyInt_FromLong
631 #define __Pyx_PyInt_AsHash_t __Pyx_PyIndex_AsHash_t
633 #define __Pyx_PyInt_FromHash_t PyInt_FromSsize_t
634 #define __Pyx_PyInt_AsHash_t __Pyx_PyIndex_AsSsize_t
636 #if PY_MAJOR_VERSION >= 3
637 #define __Pyx_PyMethod_New(func, self, klass) ((self) ? ((void)(klass), PyMethod_New(func, self)) : __Pyx_NewRef(func))
639 #define __Pyx_PyMethod_New(func, self, klass) PyMethod_New(func, self, klass)
641 #if CYTHON_USE_ASYNC_SLOTS
642 #if PY_VERSION_HEX >= 0x030500B1
643 #define __Pyx_PyAsyncMethodsStruct PyAsyncMethods
644 #define __Pyx_PyType_AsAsync(obj) (Py_TYPE(obj)->tp_as_async)
646 #define __Pyx_PyType_AsAsync(obj) ((__Pyx_PyAsyncMethodsStruct*) (Py_TYPE(obj)->tp_reserved))
649 #define __Pyx_PyType_AsAsync(obj) NULL
651 #ifndef __Pyx_PyAsyncMethodsStruct
656 } __Pyx_PyAsyncMethodsStruct;
659 #if defined(_WIN32) || defined(WIN32) || defined(MS_WINDOWS)
660 #if !defined(_USE_MATH_DEFINES)
661 #define _USE_MATH_DEFINES
666 #define __PYX_NAN() ((float) NAN)
668 static CYTHON_INLINE
float __PYX_NAN() {
670 memset(&value, 0xFF,
sizeof(value));
674 #if defined(__CYGWIN__) && defined(_LDBL_EQ_DBL)
675 #define __Pyx_truncl trunc
677 #define __Pyx_truncl truncl
680 #define __PYX_MARK_ERR_POS(f_index, lineno) \
681 { __pyx_filename = __pyx_f[f_index]; (void)__pyx_filename; __pyx_lineno = lineno; (void)__pyx_lineno; __pyx_clineno = __LINE__; (void)__pyx_clineno; }
682 #define __PYX_ERR(f_index, lineno, Ln_error) \
683 { __PYX_MARK_ERR_POS(f_index, lineno) goto Ln_error; }
685 #ifndef __PYX_EXTERN_C
687 #define __PYX_EXTERN_C extern "C"
689 #define __PYX_EXTERN_C extern
693 #define __PYX_HAVE__canalyticalSolutions
694 #define __PYX_HAVE_API__canalyticalSolutions
698 #include "numpy/arrayobject.h"
699 #include "numpy/ndarrayobject.h"
700 #include "numpy/ndarraytypes.h"
701 #include "numpy/arrayscalars.h"
702 #include "numpy/ufuncobject.h"
711 #if defined(PYREX_WITHOUT_ASSERTIONS) && !defined(CYTHON_WITHOUT_ASSERTIONS)
712 #define CYTHON_WITHOUT_ASSERTIONS
715 typedef struct {PyObject **p;
const char *
s;
const Py_ssize_t
n;
const char* encoding;
716 const char is_unicode;
const char is_str;
const char intern; } __Pyx_StringTabEntry;
718 #define __PYX_DEFAULT_STRING_ENCODING_IS_ASCII 0
719 #define __PYX_DEFAULT_STRING_ENCODING_IS_UTF8 0
720 #define __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT (PY_MAJOR_VERSION >= 3 && __PYX_DEFAULT_STRING_ENCODING_IS_UTF8)
721 #define __PYX_DEFAULT_STRING_ENCODING ""
722 #define __Pyx_PyObject_FromString __Pyx_PyBytes_FromString
723 #define __Pyx_PyObject_FromStringAndSize __Pyx_PyBytes_FromStringAndSize
724 #define __Pyx_uchar_cast(c) ((unsigned char)c)
725 #define __Pyx_long_cast(x) ((long)x)
726 #define __Pyx_fits_Py_ssize_t(v, type, is_signed) (\
727 (sizeof(type) < sizeof(Py_ssize_t)) ||\
728 (sizeof(type) > sizeof(Py_ssize_t) &&\
729 likely(v < (type)PY_SSIZE_T_MAX ||\
730 v == (type)PY_SSIZE_T_MAX) &&\
731 (!is_signed || likely(v > (type)PY_SSIZE_T_MIN ||\
732 v == (type)PY_SSIZE_T_MIN))) ||\
733 (sizeof(type) == sizeof(Py_ssize_t) &&\
734 (is_signed || likely(v < (type)PY_SSIZE_T_MAX ||\
735 v == (type)PY_SSIZE_T_MAX))) )
736 static CYTHON_INLINE
int __Pyx_is_valid_index(Py_ssize_t i, Py_ssize_t limit) {
737 return (
size_t) i < (size_t) limit;
739 #if defined (__cplusplus) && __cplusplus >= 201103L
741 #define __Pyx_sst_abs(value) std::abs(value)
742 #elif SIZEOF_INT >= SIZEOF_SIZE_T
743 #define __Pyx_sst_abs(value) abs(value)
744 #elif SIZEOF_LONG >= SIZEOF_SIZE_T
745 #define __Pyx_sst_abs(value) labs(value)
746 #elif defined (_MSC_VER)
747 #define __Pyx_sst_abs(value) ((Py_ssize_t)_abs64(value))
748 #elif defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
749 #define __Pyx_sst_abs(value) llabs(value)
750 #elif defined (__GNUC__)
751 #define __Pyx_sst_abs(value) __builtin_llabs(value)
753 #define __Pyx_sst_abs(value) ((value<0) ? -value : value)
755 static CYTHON_INLINE
const char* __Pyx_PyObject_AsString(PyObject*);
756 static CYTHON_INLINE
const char* __Pyx_PyObject_AsStringAndSize(PyObject*, Py_ssize_t* length);
757 #define __Pyx_PyByteArray_FromString(s) PyByteArray_FromStringAndSize((const char*)s, strlen((const char*)s))
758 #define __Pyx_PyByteArray_FromStringAndSize(s, l) PyByteArray_FromStringAndSize((const char*)s, l)
759 #define __Pyx_PyBytes_FromString PyBytes_FromString
760 #define __Pyx_PyBytes_FromStringAndSize PyBytes_FromStringAndSize
761 static CYTHON_INLINE PyObject* __Pyx_PyUnicode_FromString(
const char*);
762 #if PY_MAJOR_VERSION < 3
763 #define __Pyx_PyStr_FromString __Pyx_PyBytes_FromString
764 #define __Pyx_PyStr_FromStringAndSize __Pyx_PyBytes_FromStringAndSize
766 #define __Pyx_PyStr_FromString __Pyx_PyUnicode_FromString
767 #define __Pyx_PyStr_FromStringAndSize __Pyx_PyUnicode_FromStringAndSize
769 #define __Pyx_PyBytes_AsWritableString(s) ((char*) PyBytes_AS_STRING(s))
770 #define __Pyx_PyBytes_AsWritableSString(s) ((signed char*) PyBytes_AS_STRING(s))
771 #define __Pyx_PyBytes_AsWritableUString(s) ((unsigned char*) PyBytes_AS_STRING(s))
772 #define __Pyx_PyBytes_AsString(s) ((const char*) PyBytes_AS_STRING(s))
773 #define __Pyx_PyBytes_AsSString(s) ((const signed char*) PyBytes_AS_STRING(s))
774 #define __Pyx_PyBytes_AsUString(s) ((const unsigned char*) PyBytes_AS_STRING(s))
775 #define __Pyx_PyObject_AsWritableString(s) ((char*) __Pyx_PyObject_AsString(s))
776 #define __Pyx_PyObject_AsWritableSString(s) ((signed char*) __Pyx_PyObject_AsString(s))
777 #define __Pyx_PyObject_AsWritableUString(s) ((unsigned char*) __Pyx_PyObject_AsString(s))
778 #define __Pyx_PyObject_AsSString(s) ((const signed char*) __Pyx_PyObject_AsString(s))
779 #define __Pyx_PyObject_AsUString(s) ((const unsigned char*) __Pyx_PyObject_AsString(s))
780 #define __Pyx_PyObject_FromCString(s) __Pyx_PyObject_FromString((const char*)s)
781 #define __Pyx_PyBytes_FromCString(s) __Pyx_PyBytes_FromString((const char*)s)
782 #define __Pyx_PyByteArray_FromCString(s) __Pyx_PyByteArray_FromString((const char*)s)
783 #define __Pyx_PyStr_FromCString(s) __Pyx_PyStr_FromString((const char*)s)
784 #define __Pyx_PyUnicode_FromCString(s) __Pyx_PyUnicode_FromString((const char*)s)
785 static CYTHON_INLINE
size_t __Pyx_Py_UNICODE_strlen(
const Py_UNICODE *
u) {
786 const Py_UNICODE *u_end =
u;
788 return (
size_t)(u_end -
u - 1);
790 #define __Pyx_PyUnicode_FromUnicode(u) PyUnicode_FromUnicode(u, __Pyx_Py_UNICODE_strlen(u))
791 #define __Pyx_PyUnicode_FromUnicodeAndLength PyUnicode_FromUnicode
792 #define __Pyx_PyUnicode_AsUnicode PyUnicode_AsUnicode
793 #define __Pyx_NewRef(obj) (Py_INCREF(obj), obj)
794 #define __Pyx_Owned_Py_None(b) __Pyx_NewRef(Py_None)
795 static CYTHON_INLINE PyObject * __Pyx_PyBool_FromLong(
long b);
796 static CYTHON_INLINE
int __Pyx_PyObject_IsTrue(PyObject*);
797 static CYTHON_INLINE
int __Pyx_PyObject_IsTrueAndDecref(PyObject*);
798 static CYTHON_INLINE PyObject* __Pyx_PyNumber_IntOrLong(PyObject* x);
799 #define __Pyx_PySequence_Tuple(obj)\
800 (likely(PyTuple_CheckExact(obj)) ? __Pyx_NewRef(obj) : PySequence_Tuple(obj))
801 static CYTHON_INLINE Py_ssize_t __Pyx_PyIndex_AsSsize_t(PyObject*);
802 static CYTHON_INLINE PyObject * __Pyx_PyInt_FromSize_t(
size_t);
803 static CYTHON_INLINE Py_hash_t __Pyx_PyIndex_AsHash_t(PyObject*);
804 #if CYTHON_ASSUME_SAFE_MACROS
805 #define __pyx_PyFloat_AsDouble(x) (PyFloat_CheckExact(x) ? PyFloat_AS_DOUBLE(x) : PyFloat_AsDouble(x))
807 #define __pyx_PyFloat_AsDouble(x) PyFloat_AsDouble(x)
809 #define __pyx_PyFloat_AsFloat(x) ((float) __pyx_PyFloat_AsDouble(x))
810 #if PY_MAJOR_VERSION >= 3
811 #define __Pyx_PyNumber_Int(x) (PyLong_CheckExact(x) ? __Pyx_NewRef(x) : PyNumber_Long(x))
813 #define __Pyx_PyNumber_Int(x) (PyInt_CheckExact(x) ? __Pyx_NewRef(x) : PyNumber_Int(x))
815 #define __Pyx_PyNumber_Float(x) (PyFloat_CheckExact(x) ? __Pyx_NewRef(x) : PyNumber_Float(x))
816 #if PY_MAJOR_VERSION < 3 && __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
817 static int __Pyx_sys_getdefaultencoding_not_ascii;
818 static int __Pyx_init_sys_getdefaultencoding_params(
void) {
820 PyObject* default_encoding = NULL;
821 PyObject* ascii_chars_u = NULL;
822 PyObject* ascii_chars_b = NULL;
823 const char* default_encoding_c;
824 sys = PyImport_ImportModule(
"sys");
826 default_encoding = PyObject_CallMethod(sys, (
char*)
"getdefaultencoding", NULL);
828 if (!default_encoding)
goto bad;
829 default_encoding_c = PyBytes_AsString(default_encoding);
830 if (!default_encoding_c)
goto bad;
831 if (strcmp(default_encoding_c,
"ascii") == 0) {
832 __Pyx_sys_getdefaultencoding_not_ascii = 0;
834 char ascii_chars[128];
836 for (
c = 0;
c < 128;
c++) {
839 __Pyx_sys_getdefaultencoding_not_ascii = 1;
840 ascii_chars_u = PyUnicode_DecodeASCII(ascii_chars, 128, NULL);
841 if (!ascii_chars_u)
goto bad;
842 ascii_chars_b = PyUnicode_AsEncodedString(ascii_chars_u, default_encoding_c, NULL);
843 if (!ascii_chars_b || !PyBytes_Check(ascii_chars_b) || memcmp(ascii_chars, PyBytes_AS_STRING(ascii_chars_b), 128) != 0) {
846 "This module compiled with c_string_encoding=ascii, but default encoding '%.200s' is not a superset of ascii.",
850 Py_DECREF(ascii_chars_u);
851 Py_DECREF(ascii_chars_b);
853 Py_DECREF(default_encoding);
856 Py_XDECREF(default_encoding);
857 Py_XDECREF(ascii_chars_u);
858 Py_XDECREF(ascii_chars_b);
862 #if __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT && PY_MAJOR_VERSION >= 3
863 #define __Pyx_PyUnicode_FromStringAndSize(c_str, size) PyUnicode_DecodeUTF8(c_str, size, NULL)
865 #define __Pyx_PyUnicode_FromStringAndSize(c_str, size) PyUnicode_Decode(c_str, size, __PYX_DEFAULT_STRING_ENCODING, NULL)
866 #if __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT
867 static char* __PYX_DEFAULT_STRING_ENCODING;
868 static int __Pyx_init_sys_getdefaultencoding_params(
void) {
870 PyObject* default_encoding = NULL;
871 char* default_encoding_c;
872 sys = PyImport_ImportModule(
"sys");
874 default_encoding = PyObject_CallMethod(sys, (
char*) (
const char*)
"getdefaultencoding", NULL);
876 if (!default_encoding)
goto bad;
877 default_encoding_c = PyBytes_AsString(default_encoding);
878 if (!default_encoding_c)
goto bad;
879 __PYX_DEFAULT_STRING_ENCODING = (
char*) malloc(strlen(default_encoding_c) + 1);
880 if (!__PYX_DEFAULT_STRING_ENCODING)
goto bad;
881 strcpy(__PYX_DEFAULT_STRING_ENCODING, default_encoding_c);
882 Py_DECREF(default_encoding);
885 Py_XDECREF(default_encoding);
893 #if defined(__GNUC__) && (__GNUC__ > 2 || (__GNUC__ == 2 && (__GNUC_MINOR__ > 95)))
894 #define likely(x) __builtin_expect(!!(x), 1)
895 #define unlikely(x) __builtin_expect(!!(x), 0)
897 #define likely(x) (x)
898 #define unlikely(x) (x)
900 static CYTHON_INLINE
void __Pyx_pretend_to_initialize(
void* ptr) { (void)ptr; }
902 static PyObject *__pyx_m = NULL;
903 static PyObject *__pyx_d;
904 static PyObject *__pyx_b;
905 static PyObject *__pyx_cython_runtime = NULL;
906 static PyObject *__pyx_empty_tuple;
907 static PyObject *__pyx_empty_bytes;
908 static PyObject *__pyx_empty_unicode;
909 static int __pyx_lineno;
910 static int __pyx_clineno = 0;
911 static const char * __pyx_cfilenm= __FILE__;
912 static const char *__pyx_filename;
915 #if !defined(CYTHON_CCOMPLEX)
916 #if defined(__cplusplus)
917 #define CYTHON_CCOMPLEX 1
918 #elif defined(_Complex_I)
919 #define CYTHON_CCOMPLEX 1
921 #define CYTHON_CCOMPLEX 0
931 #if CYTHON_CCOMPLEX && !defined(__cplusplus) && defined(__sun__) && defined(__GNUC__)
933 #define _Complex_I 1.0fj
937 static const char *__pyx_f[] = {
938 "proteus/canalyticalSolutions.pyx",
950 typedef npy_int8 __pyx_t_5numpy_int8_t;
959 typedef npy_int16 __pyx_t_5numpy_int16_t;
968 typedef npy_int32 __pyx_t_5numpy_int32_t;
977 typedef npy_int64 __pyx_t_5numpy_int64_t;
986 typedef npy_uint8 __pyx_t_5numpy_uint8_t;
995 typedef npy_uint16 __pyx_t_5numpy_uint16_t;
1004 typedef npy_uint32 __pyx_t_5numpy_uint32_t;
1013 typedef npy_uint64 __pyx_t_5numpy_uint64_t;
1022 typedef npy_float32 __pyx_t_5numpy_float32_t;
1031 typedef npy_float64 __pyx_t_5numpy_float64_t;
1040 typedef npy_long __pyx_t_5numpy_int_t;
1049 typedef npy_longlong __pyx_t_5numpy_long_t;
1058 typedef npy_longlong __pyx_t_5numpy_longlong_t;
1067 typedef npy_ulong __pyx_t_5numpy_uint_t;
1076 typedef npy_ulonglong __pyx_t_5numpy_ulong_t;
1085 typedef npy_ulonglong __pyx_t_5numpy_ulonglong_t;
1094 typedef npy_intp __pyx_t_5numpy_intp_t;
1103 typedef npy_uintp __pyx_t_5numpy_uintp_t;
1112 typedef npy_double __pyx_t_5numpy_float_t;
1121 typedef npy_double __pyx_t_5numpy_double_t;
1130 typedef npy_longdouble __pyx_t_5numpy_longdouble_t;
1134 typedef ::std::complex< float > __pyx_t_float_complex;
1136 typedef float _Complex __pyx_t_float_complex;
1139 typedef struct {
float real, imag; } __pyx_t_float_complex;
1141 static CYTHON_INLINE __pyx_t_float_complex __pyx_t_float_complex_from_parts(
float,
float);
1146 typedef ::std::complex< double > __pyx_t_double_complex;
1148 typedef double _Complex __pyx_t_double_complex;
1151 typedef struct {
double real, imag; } __pyx_t_double_complex;
1153 static CYTHON_INLINE __pyx_t_double_complex __pyx_t_double_complex_from_parts(
double,
double);
1165 typedef npy_cfloat __pyx_t_5numpy_cfloat_t;
1174 typedef npy_cdouble __pyx_t_5numpy_cdouble_t;
1183 typedef npy_clongdouble __pyx_t_5numpy_clongdouble_t;
1192 typedef npy_cdouble __pyx_t_5numpy_complex_t;
1196 #ifndef CYTHON_REFNANNY
1197 #define CYTHON_REFNANNY 0
1201 void (*INCREF)(
void*, PyObject*, int);
1202 void (*DECREF)(
void*, PyObject*, int);
1203 void (*GOTREF)(
void*, PyObject*, int);
1204 void (*GIVEREF)(
void*, PyObject*, int);
1205 void* (*SetupContext)(
const char*, int,
const char*);
1206 void (*FinishContext)(
void**);
1207 } __Pyx_RefNannyAPIStruct;
1208 static __Pyx_RefNannyAPIStruct *__Pyx_RefNanny = NULL;
1209 static __Pyx_RefNannyAPIStruct *__Pyx_RefNannyImportAPI(
const char *modname);
1210 #define __Pyx_RefNannyDeclarations void *__pyx_refnanny = NULL;
1212 #define __Pyx_RefNannySetupContext(name, acquire_gil)\
1214 PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure();\
1215 __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__);\
1216 PyGILState_Release(__pyx_gilstate_save);\
1218 __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__);\
1221 #define __Pyx_RefNannySetupContext(name, acquire_gil)\
1222 __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__)
1224 #define __Pyx_RefNannyFinishContext()\
1225 __Pyx_RefNanny->FinishContext(&__pyx_refnanny)
1226 #define __Pyx_INCREF(r) __Pyx_RefNanny->INCREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
1227 #define __Pyx_DECREF(r) __Pyx_RefNanny->DECREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
1228 #define __Pyx_GOTREF(r) __Pyx_RefNanny->GOTREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
1229 #define __Pyx_GIVEREF(r) __Pyx_RefNanny->GIVEREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
1230 #define __Pyx_XINCREF(r) do { if((r) != NULL) {__Pyx_INCREF(r); }} while(0)
1231 #define __Pyx_XDECREF(r) do { if((r) != NULL) {__Pyx_DECREF(r); }} while(0)
1232 #define __Pyx_XGOTREF(r) do { if((r) != NULL) {__Pyx_GOTREF(r); }} while(0)
1233 #define __Pyx_XGIVEREF(r) do { if((r) != NULL) {__Pyx_GIVEREF(r);}} while(0)
1235 #define __Pyx_RefNannyDeclarations
1236 #define __Pyx_RefNannySetupContext(name, acquire_gil)
1237 #define __Pyx_RefNannyFinishContext()
1238 #define __Pyx_INCREF(r) Py_INCREF(r)
1239 #define __Pyx_DECREF(r) Py_DECREF(r)
1240 #define __Pyx_GOTREF(r)
1241 #define __Pyx_GIVEREF(r)
1242 #define __Pyx_XINCREF(r) Py_XINCREF(r)
1243 #define __Pyx_XDECREF(r) Py_XDECREF(r)
1244 #define __Pyx_XGOTREF(r)
1245 #define __Pyx_XGIVEREF(r)
1247 #define __Pyx_XDECREF_SET(r, v) do {\
1248 PyObject *tmp = (PyObject *) r;\
1249 r = v; __Pyx_XDECREF(tmp);\
1251 #define __Pyx_DECREF_SET(r, v) do {\
1252 PyObject *tmp = (PyObject *) r;\
1253 r = v; __Pyx_DECREF(tmp);\
1255 #define __Pyx_CLEAR(r) do { PyObject* tmp = ((PyObject*)(r)); r = NULL; __Pyx_DECREF(tmp);} while(0)
1256 #define __Pyx_XCLEAR(r) do { if((r) != NULL) {PyObject* tmp = ((PyObject*)(r)); r = NULL; __Pyx_DECREF(tmp);}} while(0)
1259 static void __Pyx_RaiseArgtupleInvalid(
const char* func_name,
int exact,
1260 Py_ssize_t num_min, Py_ssize_t num_max, Py_ssize_t num_found);
1263 static void __Pyx_RaiseDoubleKeywordsError(
const char* func_name, PyObject* kw_name);
1266 static int __Pyx_ParseOptionalKeywords(PyObject *kwds, PyObject **argnames[],\
1267 PyObject *kwds2, PyObject *values[], Py_ssize_t num_pos_args,\
1268 const char* function_name);
1271 #define __Pyx_ArgTypeTest(obj, type, none_allowed, name, exact)\
1272 ((likely((Py_TYPE(obj) == type) | (none_allowed && (obj == Py_None)))) ? 1 :\
1273 __Pyx__ArgTypeTest(obj, type, name, exact))
1274 static int __Pyx__ArgTypeTest(PyObject *obj, PyTypeObject *type,
const char *name,
int exact);
1277 #if CYTHON_USE_TYPE_SLOTS
1278 static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStr(PyObject* obj, PyObject* attr_name);
1280 #define __Pyx_PyObject_GetAttrStr(o,n) PyObject_GetAttr(o,n)
1284 static PyObject *__Pyx_GetBuiltinName(PyObject *name);
1287 #if CYTHON_USE_EXC_INFO_STACK
1288 static _PyErr_StackItem * __Pyx_PyErr_GetTopmostException(PyThreadState *tstate);
1292 #if CYTHON_FAST_THREAD_STATE
1293 #define __Pyx_PyThreadState_declare PyThreadState *__pyx_tstate;
1294 #define __Pyx_PyThreadState_assign __pyx_tstate = __Pyx_PyThreadState_Current;
1295 #define __Pyx_PyErr_Occurred() __pyx_tstate->curexc_type
1297 #define __Pyx_PyThreadState_declare
1298 #define __Pyx_PyThreadState_assign
1299 #define __Pyx_PyErr_Occurred() PyErr_Occurred()
1303 #if CYTHON_FAST_THREAD_STATE
1304 #define __Pyx_ExceptionSave(type, value, tb) __Pyx__ExceptionSave(__pyx_tstate, type, value, tb)
1305 static CYTHON_INLINE
void __Pyx__ExceptionSave(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb);
1306 #define __Pyx_ExceptionReset(type, value, tb) __Pyx__ExceptionReset(__pyx_tstate, type, value, tb)
1307 static CYTHON_INLINE
void __Pyx__ExceptionReset(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb);
1309 #define __Pyx_ExceptionSave(type, value, tb) PyErr_GetExcInfo(type, value, tb)
1310 #define __Pyx_ExceptionReset(type, value, tb) PyErr_SetExcInfo(type, value, tb)
1314 #if CYTHON_FAST_THREAD_STATE
1315 #define __Pyx_PyErr_ExceptionMatches(err) __Pyx_PyErr_ExceptionMatchesInState(__pyx_tstate, err)
1316 static CYTHON_INLINE
int __Pyx_PyErr_ExceptionMatchesInState(PyThreadState* tstate, PyObject* err);
1318 #define __Pyx_PyErr_ExceptionMatches(err) PyErr_ExceptionMatches(err)
1322 #if CYTHON_FAST_THREAD_STATE
1323 #define __Pyx_GetException(type, value, tb) __Pyx__GetException(__pyx_tstate, type, value, tb)
1324 static int __Pyx__GetException(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb);
1326 static int __Pyx_GetException(PyObject **type, PyObject **value, PyObject **tb);
1330 #if CYTHON_COMPILING_IN_CPYTHON
1331 static CYTHON_INLINE PyObject* __Pyx_PyObject_Call(PyObject *func, PyObject *arg, PyObject *kw);
1333 #define __Pyx_PyObject_Call(func, arg, kw) PyObject_Call(func, arg, kw)
1337 #if CYTHON_FAST_THREAD_STATE
1338 #define __Pyx_PyErr_Clear() __Pyx_ErrRestore(NULL, NULL, NULL)
1339 #define __Pyx_ErrRestoreWithState(type, value, tb) __Pyx_ErrRestoreInState(PyThreadState_GET(), type, value, tb)
1340 #define __Pyx_ErrFetchWithState(type, value, tb) __Pyx_ErrFetchInState(PyThreadState_GET(), type, value, tb)
1341 #define __Pyx_ErrRestore(type, value, tb) __Pyx_ErrRestoreInState(__pyx_tstate, type, value, tb)
1342 #define __Pyx_ErrFetch(type, value, tb) __Pyx_ErrFetchInState(__pyx_tstate, type, value, tb)
1343 static CYTHON_INLINE
void __Pyx_ErrRestoreInState(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb);
1344 static CYTHON_INLINE
void __Pyx_ErrFetchInState(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb);
1345 #if CYTHON_COMPILING_IN_CPYTHON
1346 #define __Pyx_PyErr_SetNone(exc) (Py_INCREF(exc), __Pyx_ErrRestore((exc), NULL, NULL))
1348 #define __Pyx_PyErr_SetNone(exc) PyErr_SetNone(exc)
1351 #define __Pyx_PyErr_Clear() PyErr_Clear()
1352 #define __Pyx_PyErr_SetNone(exc) PyErr_SetNone(exc)
1353 #define __Pyx_ErrRestoreWithState(type, value, tb) PyErr_Restore(type, value, tb)
1354 #define __Pyx_ErrFetchWithState(type, value, tb) PyErr_Fetch(type, value, tb)
1355 #define __Pyx_ErrRestoreInState(tstate, type, value, tb) PyErr_Restore(type, value, tb)
1356 #define __Pyx_ErrFetchInState(tstate, type, value, tb) PyErr_Fetch(type, value, tb)
1357 #define __Pyx_ErrRestore(type, value, tb) PyErr_Restore(type, value, tb)
1358 #define __Pyx_ErrFetch(type, value, tb) PyErr_Fetch(type, value, tb)
1362 static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb, PyObject *cause);
1365 #ifndef __PYX_HAVE_RT_ImportType_proto
1366 #define __PYX_HAVE_RT_ImportType_proto
1367 enum __Pyx_ImportType_CheckSize {
1368 __Pyx_ImportType_CheckSize_Error = 0,
1369 __Pyx_ImportType_CheckSize_Warn = 1,
1370 __Pyx_ImportType_CheckSize_Ignore = 2
1372 static PyTypeObject *__Pyx_ImportType(PyObject* module,
const char *module_name,
const char *class_name,
size_t size,
enum __Pyx_ImportType_CheckSize check_size);
1376 static PyObject *__Pyx_Import(PyObject *name, PyObject *from_list,
int level);
1379 #if CYTHON_USE_DICT_VERSIONS && CYTHON_USE_TYPE_SLOTS
1380 #define __PYX_DICT_VERSION_INIT ((PY_UINT64_T) -1)
1381 #define __PYX_GET_DICT_VERSION(dict) (((PyDictObject*)(dict))->ma_version_tag)
1382 #define __PYX_UPDATE_DICT_CACHE(dict, value, cache_var, version_var)\
1383 (version_var) = __PYX_GET_DICT_VERSION(dict);\
1384 (cache_var) = (value);
1385 #define __PYX_PY_DICT_LOOKUP_IF_MODIFIED(VAR, DICT, LOOKUP) {\
1386 static PY_UINT64_T __pyx_dict_version = 0;\
1387 static PyObject *__pyx_dict_cached_value = NULL;\
1388 if (likely(__PYX_GET_DICT_VERSION(DICT) == __pyx_dict_version)) {\
1389 (VAR) = __pyx_dict_cached_value;\
1391 (VAR) = __pyx_dict_cached_value = (LOOKUP);\
1392 __pyx_dict_version = __PYX_GET_DICT_VERSION(DICT);\
1395 static CYTHON_INLINE PY_UINT64_T __Pyx_get_tp_dict_version(PyObject *obj);
1396 static CYTHON_INLINE PY_UINT64_T __Pyx_get_object_dict_version(PyObject *obj);
1397 static CYTHON_INLINE
int __Pyx_object_dict_version_matches(PyObject* obj, PY_UINT64_T tp_dict_version, PY_UINT64_T obj_dict_version);
1399 #define __PYX_GET_DICT_VERSION(dict) (0)
1400 #define __PYX_UPDATE_DICT_CACHE(dict, value, cache_var, version_var)
1401 #define __PYX_PY_DICT_LOOKUP_IF_MODIFIED(VAR, DICT, LOOKUP) (VAR) = (LOOKUP);
1405 #ifdef CYTHON_CLINE_IN_TRACEBACK
1406 #define __Pyx_CLineForTraceback(tstate, c_line) (((CYTHON_CLINE_IN_TRACEBACK)) ? c_line : 0)
1408 static int __Pyx_CLineForTraceback(PyThreadState *tstate,
int c_line);
1413 PyCodeObject* code_object;
1415 } __Pyx_CodeObjectCacheEntry;
1416 struct __Pyx_CodeObjectCache {
1419 __Pyx_CodeObjectCacheEntry* entries;
1421 static struct __Pyx_CodeObjectCache __pyx_code_cache = {0,0,NULL};
1422 static int __pyx_bisect_code_objects(__Pyx_CodeObjectCacheEntry* entries,
int count,
int code_line);
1423 static PyCodeObject *__pyx_find_code_object(
int code_line);
1424 static void __pyx_insert_code_object(
int code_line, PyCodeObject* code_object);
1427 static void __Pyx_AddTraceback(
const char *funcname,
int c_line,
1428 int py_line,
const char *filename);
1431 #if defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 6))
1432 #define __Pyx_HAS_GCC_DIAGNOSTIC
1438 #define __Pyx_CREAL(z) ((z).real())
1439 #define __Pyx_CIMAG(z) ((z).imag())
1441 #define __Pyx_CREAL(z) (__real__(z))
1442 #define __Pyx_CIMAG(z) (__imag__(z))
1445 #define __Pyx_CREAL(z) ((z).real)
1446 #define __Pyx_CIMAG(z) ((z).imag)
1448 #if defined(__cplusplus) && CYTHON_CCOMPLEX\
1449 && (defined(_WIN32) || defined(__clang__) || (defined(__GNUC__) && (__GNUC__ >= 5 || __GNUC__ == 4 && __GNUC_MINOR__ >= 4 )) || __cplusplus >= 201103)
1450 #define __Pyx_SET_CREAL(z,x) ((z).real(x))
1451 #define __Pyx_SET_CIMAG(z,y) ((z).imag(y))
1453 #define __Pyx_SET_CREAL(z,x) __Pyx_CREAL(z) = (x)
1454 #define __Pyx_SET_CIMAG(z,y) __Pyx_CIMAG(z) = (y)
1459 #define __Pyx_c_eq_float(a, b) ((a)==(b))
1460 #define __Pyx_c_sum_float(a, b) ((a)+(b))
1461 #define __Pyx_c_diff_float(a, b) ((a)-(b))
1462 #define __Pyx_c_prod_float(a, b) ((a)*(b))
1463 #define __Pyx_c_quot_float(a, b) ((a)/(b))
1464 #define __Pyx_c_neg_float(a) (-(a))
1466 #define __Pyx_c_is_zero_float(z) ((z)==(float)0)
1467 #define __Pyx_c_conj_float(z) (::std::conj(z))
1469 #define __Pyx_c_abs_float(z) (::std::abs(z))
1470 #define __Pyx_c_pow_float(a, b) (::std::pow(a, b))
1473 #define __Pyx_c_is_zero_float(z) ((z)==0)
1474 #define __Pyx_c_conj_float(z) (conjf(z))
1476 #define __Pyx_c_abs_float(z) (cabsf(z))
1477 #define __Pyx_c_pow_float(a, b) (cpowf(a, b))
1481 static CYTHON_INLINE
int __Pyx_c_eq_float(__pyx_t_float_complex, __pyx_t_float_complex);
1482 static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_sum_float(__pyx_t_float_complex, __pyx_t_float_complex);
1483 static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_diff_float(__pyx_t_float_complex, __pyx_t_float_complex);
1484 static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_prod_float(__pyx_t_float_complex, __pyx_t_float_complex);
1485 static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_quot_float(__pyx_t_float_complex, __pyx_t_float_complex);
1486 static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_neg_float(__pyx_t_float_complex);
1487 static CYTHON_INLINE
int __Pyx_c_is_zero_float(__pyx_t_float_complex);
1488 static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_conj_float(__pyx_t_float_complex);
1490 static CYTHON_INLINE
float __Pyx_c_abs_float(__pyx_t_float_complex);
1491 static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_pow_float(__pyx_t_float_complex, __pyx_t_float_complex);
1497 #define __Pyx_c_eq_double(a, b) ((a)==(b))
1498 #define __Pyx_c_sum_double(a, b) ((a)+(b))
1499 #define __Pyx_c_diff_double(a, b) ((a)-(b))
1500 #define __Pyx_c_prod_double(a, b) ((a)*(b))
1501 #define __Pyx_c_quot_double(a, b) ((a)/(b))
1502 #define __Pyx_c_neg_double(a) (-(a))
1504 #define __Pyx_c_is_zero_double(z) ((z)==(double)0)
1505 #define __Pyx_c_conj_double(z) (::std::conj(z))
1507 #define __Pyx_c_abs_double(z) (::std::abs(z))
1508 #define __Pyx_c_pow_double(a, b) (::std::pow(a, b))
1511 #define __Pyx_c_is_zero_double(z) ((z)==0)
1512 #define __Pyx_c_conj_double(z) (conj(z))
1514 #define __Pyx_c_abs_double(z) (cabs(z))
1515 #define __Pyx_c_pow_double(a, b) (cpow(a, b))
1519 static CYTHON_INLINE
int __Pyx_c_eq_double(__pyx_t_double_complex, __pyx_t_double_complex);
1520 static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_sum_double(__pyx_t_double_complex, __pyx_t_double_complex);
1521 static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_diff_double(__pyx_t_double_complex, __pyx_t_double_complex);
1522 static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_prod_double(__pyx_t_double_complex, __pyx_t_double_complex);
1523 static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_quot_double(__pyx_t_double_complex, __pyx_t_double_complex);
1524 static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_neg_double(__pyx_t_double_complex);
1525 static CYTHON_INLINE
int __Pyx_c_is_zero_double(__pyx_t_double_complex);
1526 static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_conj_double(__pyx_t_double_complex);
1528 static CYTHON_INLINE
double __Pyx_c_abs_double(__pyx_t_double_complex);
1529 static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_pow_double(__pyx_t_double_complex, __pyx_t_double_complex);
1534 static CYTHON_INLINE PyObject* __Pyx_PyInt_From_Py_intptr_t(Py_intptr_t value);
1537 static CYTHON_INLINE
int __Pyx_PyInt_As_int(PyObject *);
1540 static CYTHON_INLINE PyObject* __Pyx_PyInt_From_int(
int value);
1543 static CYTHON_INLINE PyObject* __Pyx_PyInt_From_long(
long value);
1546 static CYTHON_INLINE
long __Pyx_PyInt_As_long(PyObject *);
1549 #if CYTHON_COMPILING_IN_CPYTHON
1550 #define __Pyx_TypeCheck(obj, type) __Pyx_IsSubtype(Py_TYPE(obj), (PyTypeObject *)type)
1551 static CYTHON_INLINE
int __Pyx_IsSubtype(PyTypeObject *a, PyTypeObject *b);
1552 static CYTHON_INLINE
int __Pyx_PyErr_GivenExceptionMatches(PyObject *err, PyObject *type);
1553 static CYTHON_INLINE
int __Pyx_PyErr_GivenExceptionMatches2(PyObject *err, PyObject *type1, PyObject *type2);
1555 #define __Pyx_TypeCheck(obj, type) PyObject_TypeCheck(obj, (PyTypeObject *)type)
1556 #define __Pyx_PyErr_GivenExceptionMatches(err, type) PyErr_GivenExceptionMatches(err, type)
1557 #define __Pyx_PyErr_GivenExceptionMatches2(err, type1, type2) (PyErr_GivenExceptionMatches(err, type1) || PyErr_GivenExceptionMatches(err, type2))
1559 #define __Pyx_PyException_Check(obj) __Pyx_TypeCheck(obj, PyExc_Exception)
1562 static int __Pyx_check_binary_version(
void);
1565 static int __Pyx_InitStrings(__Pyx_StringTabEntry *t);
1577 static PyTypeObject *__pyx_ptype_7cpython_4type_type = 0;
1590 static PyTypeObject *__pyx_ptype_5numpy_dtype = 0;
1591 static PyTypeObject *__pyx_ptype_5numpy_flatiter = 0;
1592 static PyTypeObject *__pyx_ptype_5numpy_broadcast = 0;
1593 static PyTypeObject *__pyx_ptype_5numpy_ndarray = 0;
1594 static PyTypeObject *__pyx_ptype_5numpy_generic = 0;
1595 static PyTypeObject *__pyx_ptype_5numpy_number = 0;
1596 static PyTypeObject *__pyx_ptype_5numpy_integer = 0;
1597 static PyTypeObject *__pyx_ptype_5numpy_signedinteger = 0;
1598 static PyTypeObject *__pyx_ptype_5numpy_unsignedinteger = 0;
1599 static PyTypeObject *__pyx_ptype_5numpy_inexact = 0;
1600 static PyTypeObject *__pyx_ptype_5numpy_floating = 0;
1601 static PyTypeObject *__pyx_ptype_5numpy_complexfloating = 0;
1602 static PyTypeObject *__pyx_ptype_5numpy_flexible = 0;
1603 static PyTypeObject *__pyx_ptype_5numpy_character = 0;
1604 static PyTypeObject *__pyx_ptype_5numpy_ufunc = 0;
1607 #define __Pyx_MODULE_NAME "canalyticalSolutions"
1608 extern int __pyx_module_is_main_canalyticalSolutions;
1609 int __pyx_module_is_main_canalyticalSolutions = 0;
1612 static PyObject *__pyx_builtin_ImportError;
1613 static const char __pyx_k_f[] =
"f";
1614 static const char __pyx_k_r[] =
"r";
1615 static const char __pyx_k_t[] =
"t";
1616 static const char __pyx_k_u[] =
"u";
1617 static const char __pyx_k_x[] =
"x";
1618 static const char __pyx_k_dr[] =
"dr";
1619 static const char __pyx_k_du[] =
"du";
1620 static const char __pyx_k_np[] =
"np";
1621 static const char __pyx_k_main[] =
"__main__";
1622 static const char __pyx_k_name[] =
"__name__";
1623 static const char __pyx_k_size[] =
"size";
1624 static const char __pyx_k_test[] =
"__test__";
1625 static const char __pyx_k_iwork[] =
"iwork";
1626 static const char __pyx_k_numpy[] =
"numpy";
1627 static const char __pyx_k_rwork[] =
"rwork";
1628 static const char __pyx_k_import[] =
"__import__";
1629 static const char __pyx_k_ImportError[] =
"ImportError";
1630 static const char __pyx_k_NonlinearDAE[] =
"NonlinearDAE";
1631 static const char __pyx_k_LinearADR_Sine[] =
"LinearADR_Sine";
1632 static const char __pyx_k_NonlinearDAE_f[] =
"NonlinearDAE_f";
1633 static const char __pyx_k_STflowSphere_P[] =
"STflowSphere_P";
1634 static const char __pyx_k_diffusionSin1D[] =
"diffusionSin1D";
1635 static const char __pyx_k_diffusionSin2D[] =
"diffusionSin2D";
1636 static const char __pyx_k_diffusionSin3D[] =
"diffusionSin3D";
1637 static const char __pyx_k_STflowSphere_Vx[] =
"STflowSphere_Vx";
1638 static const char __pyx_k_STflowSphere_Vy[] =
"STflowSphere_Vy";
1639 static const char __pyx_k_STflowSphere_Vz[] =
"STflowSphere_Vz";
1640 static const char __pyx_k_LinearADR_Sine_r[] =
"LinearADR_Sine_r";
1641 static const char __pyx_k_LinearAD_DiracIC[] =
"LinearAD_DiracIC";
1642 static const char __pyx_k_diffusionSin1D_r[] =
"diffusionSin1D_r";
1643 static const char __pyx_k_diffusionSin2D_r[] =
"diffusionSin2D_r";
1644 static const char __pyx_k_diffusionSin3D_r[] =
"diffusionSin3D_r";
1645 static const char __pyx_k_LinearADR_Sine_dr[] =
"LinearADR_Sine_dr";
1646 static const char __pyx_k_LinearADR_Sine_du[] =
"LinearADR_Sine_du";
1647 static const char __pyx_k_PlaneCouetteFlow_u[] =
"PlaneCouetteFlow_u";
1648 static const char __pyx_k_PoiseuillePipeFlow[] =
"PoiseuillePipeFlow";
1649 static const char __pyx_k_cline_in_traceback[] =
"cline_in_traceback";
1650 static const char __pyx_k_LinearAD_DiracIC_du[] =
"LinearAD_DiracIC_du";
1651 static const char __pyx_k_LinearAD_SteadyState[] =
"LinearAD_SteadyState";
1652 static const char __pyx_k_PoiseuillePipeFlow_P[] =
"PoiseuillePipeFlow_P";
1653 static const char __pyx_k_canalyticalSolutions[] =
"canalyticalSolutions";
1654 static const char __pyx_k_PlanePoiseuilleFlow_u[] =
"PlanePoiseuilleFlow_u";
1655 static const char __pyx_k_poissonsEquationExp1D[] =
"poissonsEquationExp1D";
1656 static const char __pyx_k_poissonsEquationExp2D[] =
"poissonsEquationExp2D";
1657 static const char __pyx_k_poissonsEquationExp3D[] =
"poissonsEquationExp3D";
1658 static const char __pyx_k_LinearADR_Decay_DiracIC[] =
"LinearADR_Decay_DiracIC";
1659 static const char __pyx_k_NonlinearAD_SteadyState[] =
"NonlinearAD_SteadyState";
1660 static const char __pyx_k_poissonsEquationExp1D_r[] =
"poissonsEquationExp1D_r";
1661 static const char __pyx_k_poissonsEquationExp2D_r[] =
"poissonsEquationExp2D_r";
1662 static const char __pyx_k_poissonsEquationExp3D_r[] =
"poissonsEquationExp3D_r";
1663 static const char __pyx_k_poissonsEquationExp3D_dr[] =
"poissonsEquationExp3D_dr";
1664 static const char __pyx_k_LinearADR_Decay_DiracIC_r[] =
"LinearADR_Decay_DiracIC_r";
1665 static const char __pyx_k_LinearADR_Decay_DiracIC_dr[] =
"LinearADR_Decay_DiracIC_dr";
1666 static const char __pyx_k_NonlinearADR_Decay_DiracIC[] =
"NonlinearADR_Decay_DiracIC";
1667 static const char __pyx_k_LinearADR_Sine_totalVelocity[] =
"LinearADR_Sine_totalVelocity";
1668 static const char __pyx_k_NonlinearADR_Decay_DiracIC_r[] =
"NonlinearADR_Decay_DiracIC_r";
1669 static const char __pyx_k_NonlinearADR_Decay_DiracIC_dr[] =
"NonlinearADR_Decay_DiracIC_dr";
1670 static const char __pyx_k_LinearAD_DiracIC_totalVelocity[] =
"LinearAD_DiracIC_totalVelocity";
1671 static const char __pyx_k_numpy_core_multiarray_failed_to[] =
"numpy.core.multiarray failed to import";
1672 static const char __pyx_k_LinearADR_Sine_advectiveVelocity[] =
"LinearADR_Sine_advectiveVelocity";
1673 static const char __pyx_k_LinearADR_Sine_diffusiveVelocity[] =
"LinearADR_Sine_diffusiveVelocity";
1674 static const char __pyx_k_LinearAD_DiracIC_advectiveVeloci[] =
"LinearAD_DiracIC_advectiveVelocity";
1675 static const char __pyx_k_LinearAD_DiracIC_diffusiveVeloci[] =
"LinearAD_DiracIC_diffusiveVelocity";
1676 static const char __pyx_k_numpy_core_umath_failed_to_impor[] =
"numpy.core.umath failed to import";
1677 static const char __pyx_k_proteus_canalyticalSolutions_pyx[] =
"proteus/canalyticalSolutions.pyx";
1678 static PyObject *__pyx_n_s_ImportError;
1679 static PyObject *__pyx_n_s_LinearADR_Decay_DiracIC;
1680 static PyObject *__pyx_n_s_LinearADR_Decay_DiracIC_dr;
1681 static PyObject *__pyx_n_s_LinearADR_Decay_DiracIC_r;
1682 static PyObject *__pyx_n_s_LinearADR_Sine;
1683 static PyObject *__pyx_n_s_LinearADR_Sine_advectiveVelocity;
1684 static PyObject *__pyx_n_s_LinearADR_Sine_diffusiveVelocity;
1685 static PyObject *__pyx_n_s_LinearADR_Sine_dr;
1686 static PyObject *__pyx_n_s_LinearADR_Sine_du;
1687 static PyObject *__pyx_n_s_LinearADR_Sine_r;
1688 static PyObject *__pyx_n_s_LinearADR_Sine_totalVelocity;
1689 static PyObject *__pyx_n_s_LinearAD_DiracIC;
1690 static PyObject *__pyx_n_s_LinearAD_DiracIC_advectiveVeloci;
1691 static PyObject *__pyx_n_s_LinearAD_DiracIC_diffusiveVeloci;
1692 static PyObject *__pyx_n_s_LinearAD_DiracIC_du;
1693 static PyObject *__pyx_n_s_LinearAD_DiracIC_totalVelocity;
1694 static PyObject *__pyx_n_s_LinearAD_SteadyState;
1695 static PyObject *__pyx_n_s_NonlinearADR_Decay_DiracIC;
1696 static PyObject *__pyx_n_s_NonlinearADR_Decay_DiracIC_dr;
1697 static PyObject *__pyx_n_s_NonlinearADR_Decay_DiracIC_r;
1698 static PyObject *__pyx_n_s_NonlinearAD_SteadyState;
1699 static PyObject *__pyx_n_s_NonlinearDAE;
1700 static PyObject *__pyx_n_s_NonlinearDAE_f;
1701 static PyObject *__pyx_n_s_PlaneCouetteFlow_u;
1702 static PyObject *__pyx_n_s_PlanePoiseuilleFlow_u;
1703 static PyObject *__pyx_n_s_PoiseuillePipeFlow;
1704 static PyObject *__pyx_n_s_PoiseuillePipeFlow_P;
1705 static PyObject *__pyx_n_s_STflowSphere_P;
1706 static PyObject *__pyx_n_s_STflowSphere_Vx;
1707 static PyObject *__pyx_n_s_STflowSphere_Vy;
1708 static PyObject *__pyx_n_s_STflowSphere_Vz;
1709 static PyObject *__pyx_n_s_canalyticalSolutions;
1710 static PyObject *__pyx_n_s_cline_in_traceback;
1711 static PyObject *__pyx_n_s_diffusionSin1D;
1712 static PyObject *__pyx_n_s_diffusionSin1D_r;
1713 static PyObject *__pyx_n_s_diffusionSin2D;
1714 static PyObject *__pyx_n_s_diffusionSin2D_r;
1715 static PyObject *__pyx_n_s_diffusionSin3D;
1716 static PyObject *__pyx_n_s_diffusionSin3D_r;
1717 static PyObject *__pyx_n_s_dr;
1718 static PyObject *__pyx_n_s_du;
1719 static PyObject *__pyx_n_s_f;
1720 static PyObject *__pyx_n_s_import;
1721 static PyObject *__pyx_n_s_iwork;
1722 static PyObject *__pyx_n_s_main;
1723 static PyObject *__pyx_n_s_name;
1724 static PyObject *__pyx_n_s_np;
1725 static PyObject *__pyx_n_s_numpy;
1726 static PyObject *__pyx_kp_s_numpy_core_multiarray_failed_to;
1727 static PyObject *__pyx_kp_s_numpy_core_umath_failed_to_impor;
1728 static PyObject *__pyx_n_s_poissonsEquationExp1D;
1729 static PyObject *__pyx_n_s_poissonsEquationExp1D_r;
1730 static PyObject *__pyx_n_s_poissonsEquationExp2D;
1731 static PyObject *__pyx_n_s_poissonsEquationExp2D_r;
1732 static PyObject *__pyx_n_s_poissonsEquationExp3D;
1733 static PyObject *__pyx_n_s_poissonsEquationExp3D_dr;
1734 static PyObject *__pyx_n_s_poissonsEquationExp3D_r;
1735 static PyObject *__pyx_kp_s_proteus_canalyticalSolutions_pyx;
1736 static PyObject *__pyx_n_s_r;
1737 static PyObject *__pyx_n_s_rwork;
1738 static PyObject *__pyx_n_s_size;
1739 static PyObject *__pyx_n_s_t;
1740 static PyObject *__pyx_n_s_test;
1741 static PyObject *__pyx_n_s_u;
1742 static PyObject *__pyx_n_s_x;
1743 static PyObject *__pyx_pf_20canalyticalSolutions_PlaneCouetteFlow_u(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1744 static PyObject *__pyx_pf_20canalyticalSolutions_2diffusionSin1D(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1745 static PyObject *__pyx_pf_20canalyticalSolutions_4diffusionSin2D(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1746 static PyObject *__pyx_pf_20canalyticalSolutions_6diffusionSin3D(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1747 static PyObject *__pyx_pf_20canalyticalSolutions_8diffusionSin1D_r(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_r);
1748 static PyObject *__pyx_pf_20canalyticalSolutions_10diffusionSin2D_r(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_r);
1749 static PyObject *__pyx_pf_20canalyticalSolutions_12diffusionSin3D_r(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_r);
1750 static PyObject *__pyx_pf_20canalyticalSolutions_14LinearAD_DiracIC(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1751 static PyObject *__pyx_pf_20canalyticalSolutions_16LinearAD_DiracIC_advectiveVelocity(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_f);
1752 static PyObject *__pyx_pf_20canalyticalSolutions_18LinearAD_DiracIC_diffusiveVelocity(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_f);
1753 static PyObject *__pyx_pf_20canalyticalSolutions_20LinearAD_DiracIC_du(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_du);
1754 static PyObject *__pyx_pf_20canalyticalSolutions_22LinearAD_DiracIC_totalVelocity(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1755 static PyObject *__pyx_pf_20canalyticalSolutions_24LinearAD_SteadyState(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1756 static PyObject *__pyx_pf_20canalyticalSolutions_26LinearADR_Decay_DiracIC(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1757 static PyObject *__pyx_pf_20canalyticalSolutions_28LinearADR_Decay_DiracIC_dr(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_dr);
1758 static PyObject *__pyx_pf_20canalyticalSolutions_30LinearADR_Decay_DiracIC_r(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_r);
1759 static PyObject *__pyx_pf_20canalyticalSolutions_32LinearADR_Sine(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1760 static PyObject *__pyx_pf_20canalyticalSolutions_34LinearADR_Sine_advectiveVelocity(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_f);
1761 static PyObject *__pyx_pf_20canalyticalSolutions_36LinearADR_Sine_diffusiveVelocity(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_f);
1762 static PyObject *__pyx_pf_20canalyticalSolutions_38LinearADR_Sine_dr(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_dr);
1763 static PyObject *__pyx_pf_20canalyticalSolutions_40LinearADR_Sine_du(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_du);
1764 static PyObject *__pyx_pf_20canalyticalSolutions_42LinearADR_Sine_r(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_r);
1765 static PyObject *__pyx_pf_20canalyticalSolutions_44LinearADR_Sine_totalVelocity(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1766 static PyObject *__pyx_pf_20canalyticalSolutions_46NonlinearAD_SteadyState(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1767 static PyObject *__pyx_pf_20canalyticalSolutions_48NonlinearADR_Decay_DiracIC(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1768 static PyObject *__pyx_pf_20canalyticalSolutions_50NonlinearADR_Decay_DiracIC_dr(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_dr);
1769 static PyObject *__pyx_pf_20canalyticalSolutions_52NonlinearADR_Decay_DiracIC_r(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_r);
1770 static PyObject *__pyx_pf_20canalyticalSolutions_54NonlinearDAE(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1771 static PyObject *__pyx_pf_20canalyticalSolutions_56NonlinearDAE_f(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1772 static PyObject *__pyx_pf_20canalyticalSolutions_58PlanePoiseuilleFlow_u(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1773 static PyObject *__pyx_pf_20canalyticalSolutions_60PoiseuillePipeFlow(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1774 static PyObject *__pyx_pf_20canalyticalSolutions_62PoiseuillePipeFlow_P(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1775 static PyObject *__pyx_pf_20canalyticalSolutions_64poissonsEquationExp1D(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1776 static PyObject *__pyx_pf_20canalyticalSolutions_66poissonsEquationExp2D(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1777 static PyObject *__pyx_pf_20canalyticalSolutions_68poissonsEquationExp3D(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1778 static PyObject *__pyx_pf_20canalyticalSolutions_70poissonsEquationExp3D_dr(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_dr);
1779 static PyObject *__pyx_pf_20canalyticalSolutions_72poissonsEquationExp1D_r(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_r);
1780 static PyObject *__pyx_pf_20canalyticalSolutions_74poissonsEquationExp2D_r(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_r);
1781 static PyObject *__pyx_pf_20canalyticalSolutions_76poissonsEquationExp3D_r(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_r);
1782 static PyObject *__pyx_pf_20canalyticalSolutions_78STflowSphere_P(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1783 static PyObject *__pyx_pf_20canalyticalSolutions_80STflowSphere_Vx(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1784 static PyObject *__pyx_pf_20canalyticalSolutions_82STflowSphere_Vy(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1785 static PyObject *__pyx_pf_20canalyticalSolutions_84STflowSphere_Vz(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u);
1786 static PyObject *__pyx_tuple_;
1787 static PyObject *__pyx_tuple__2;
1788 static PyObject *__pyx_tuple__3;
1789 static PyObject *__pyx_tuple__5;
1790 static PyObject *__pyx_tuple__7;
1791 static PyObject *__pyx_tuple__9;
1792 static PyObject *__pyx_tuple__11;
1793 static PyObject *__pyx_tuple__13;
1794 static PyObject *__pyx_tuple__15;
1795 static PyObject *__pyx_tuple__17;
1796 static PyObject *__pyx_tuple__19;
1797 static PyObject *__pyx_tuple__21;
1798 static PyObject *__pyx_tuple__23;
1799 static PyObject *__pyx_tuple__25;
1800 static PyObject *__pyx_tuple__27;
1801 static PyObject *__pyx_tuple__29;
1802 static PyObject *__pyx_tuple__31;
1803 static PyObject *__pyx_tuple__33;
1804 static PyObject *__pyx_tuple__35;
1805 static PyObject *__pyx_tuple__37;
1806 static PyObject *__pyx_tuple__39;
1807 static PyObject *__pyx_tuple__41;
1808 static PyObject *__pyx_tuple__43;
1809 static PyObject *__pyx_tuple__45;
1810 static PyObject *__pyx_tuple__47;
1811 static PyObject *__pyx_tuple__49;
1812 static PyObject *__pyx_tuple__51;
1813 static PyObject *__pyx_tuple__53;
1814 static PyObject *__pyx_tuple__55;
1815 static PyObject *__pyx_tuple__57;
1816 static PyObject *__pyx_tuple__59;
1817 static PyObject *__pyx_tuple__61;
1818 static PyObject *__pyx_tuple__63;
1819 static PyObject *__pyx_tuple__65;
1820 static PyObject *__pyx_tuple__67;
1821 static PyObject *__pyx_tuple__69;
1822 static PyObject *__pyx_tuple__71;
1823 static PyObject *__pyx_tuple__73;
1824 static PyObject *__pyx_tuple__75;
1825 static PyObject *__pyx_tuple__77;
1826 static PyObject *__pyx_tuple__79;
1827 static PyObject *__pyx_tuple__81;
1828 static PyObject *__pyx_tuple__83;
1829 static PyObject *__pyx_tuple__85;
1830 static PyObject *__pyx_tuple__87;
1831 static PyObject *__pyx_codeobj__4;
1832 static PyObject *__pyx_codeobj__6;
1833 static PyObject *__pyx_codeobj__8;
1834 static PyObject *__pyx_codeobj__10;
1835 static PyObject *__pyx_codeobj__12;
1836 static PyObject *__pyx_codeobj__14;
1837 static PyObject *__pyx_codeobj__16;
1838 static PyObject *__pyx_codeobj__18;
1839 static PyObject *__pyx_codeobj__20;
1840 static PyObject *__pyx_codeobj__22;
1841 static PyObject *__pyx_codeobj__24;
1842 static PyObject *__pyx_codeobj__26;
1843 static PyObject *__pyx_codeobj__28;
1844 static PyObject *__pyx_codeobj__30;
1845 static PyObject *__pyx_codeobj__32;
1846 static PyObject *__pyx_codeobj__34;
1847 static PyObject *__pyx_codeobj__36;
1848 static PyObject *__pyx_codeobj__38;
1849 static PyObject *__pyx_codeobj__40;
1850 static PyObject *__pyx_codeobj__42;
1851 static PyObject *__pyx_codeobj__44;
1852 static PyObject *__pyx_codeobj__46;
1853 static PyObject *__pyx_codeobj__48;
1854 static PyObject *__pyx_codeobj__50;
1855 static PyObject *__pyx_codeobj__52;
1856 static PyObject *__pyx_codeobj__54;
1857 static PyObject *__pyx_codeobj__56;
1858 static PyObject *__pyx_codeobj__58;
1859 static PyObject *__pyx_codeobj__60;
1860 static PyObject *__pyx_codeobj__62;
1861 static PyObject *__pyx_codeobj__64;
1862 static PyObject *__pyx_codeobj__66;
1863 static PyObject *__pyx_codeobj__68;
1864 static PyObject *__pyx_codeobj__70;
1865 static PyObject *__pyx_codeobj__72;
1866 static PyObject *__pyx_codeobj__74;
1867 static PyObject *__pyx_codeobj__76;
1868 static PyObject *__pyx_codeobj__78;
1869 static PyObject *__pyx_codeobj__80;
1870 static PyObject *__pyx_codeobj__82;
1871 static PyObject *__pyx_codeobj__84;
1872 static PyObject *__pyx_codeobj__86;
1873 static PyObject *__pyx_codeobj__88;
1885 static PyObject *__pyx_pw_20canalyticalSolutions_1PlaneCouetteFlow_u(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
1886 static PyMethodDef __pyx_mdef_20canalyticalSolutions_1PlaneCouetteFlow_u = {
"PlaneCouetteFlow_u", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_1PlaneCouetteFlow_u, METH_VARARGS|METH_KEYWORDS, 0};
1887 static PyObject *__pyx_pw_20canalyticalSolutions_1PlaneCouetteFlow_u(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
1888 PyArrayObject *__pyx_v_iwork = 0;
1889 PyArrayObject *__pyx_v_rwork = 0;
1891 PyArrayObject *__pyx_v_x = 0;
1892 PyArrayObject *__pyx_v_u = 0;
1893 int __pyx_lineno = 0;
1894 const char *__pyx_filename = NULL;
1895 int __pyx_clineno = 0;
1896 PyObject *__pyx_r = 0;
1897 __Pyx_RefNannyDeclarations
1898 __Pyx_RefNannySetupContext(
"PlaneCouetteFlow_u (wrapper)", 0);
1900 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_u,0};
1901 PyObject* values[5] = {0,0,0,0,0};
1902 if (unlikely(__pyx_kwds)) {
1904 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
1906 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
1908 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
1910 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
1912 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
1914 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
1917 default:
goto __pyx_L5_argtuple_error;
1919 kw_args = PyDict_Size(__pyx_kwds);
1922 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
1923 else goto __pyx_L5_argtuple_error;
1926 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
1928 __Pyx_RaiseArgtupleInvalid(
"PlaneCouetteFlow_u", 1, 5, 5, 1); __PYX_ERR(0, 50, __pyx_L3_error)
1932 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
1934 __Pyx_RaiseArgtupleInvalid(
"PlaneCouetteFlow_u", 1, 5, 5, 2); __PYX_ERR(0, 50, __pyx_L3_error)
1938 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
1940 __Pyx_RaiseArgtupleInvalid(
"PlaneCouetteFlow_u", 1, 5, 5, 3); __PYX_ERR(0, 50, __pyx_L3_error)
1944 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
1946 __Pyx_RaiseArgtupleInvalid(
"PlaneCouetteFlow_u", 1, 5, 5, 4); __PYX_ERR(0, 50, __pyx_L3_error)
1949 if (unlikely(kw_args > 0)) {
1950 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"PlaneCouetteFlow_u") < 0)) __PYX_ERR(0, 50, __pyx_L3_error)
1952 }
else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
1953 goto __pyx_L5_argtuple_error;
1955 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
1956 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
1957 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
1958 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
1959 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
1961 __pyx_v_iwork = ((PyArrayObject *)values[0]);
1962 __pyx_v_rwork = ((PyArrayObject *)values[1]);
1963 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 50, __pyx_L3_error)
1964 __pyx_v_x = ((PyArrayObject *)values[3]);
1965 __pyx_v_u = ((PyArrayObject *)values[4]);
1967 goto __pyx_L4_argument_unpacking_done;
1968 __pyx_L5_argtuple_error:;
1969 __Pyx_RaiseArgtupleInvalid(
"PlaneCouetteFlow_u", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 50, __pyx_L3_error)
1971 __Pyx_AddTraceback(
"canalyticalSolutions.PlaneCouetteFlow_u", __pyx_clineno, __pyx_lineno, __pyx_filename);
1972 __Pyx_RefNannyFinishContext();
1974 __pyx_L4_argument_unpacking_done:;
1975 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 50, __pyx_L1_error)
1976 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 50, __pyx_L1_error)
1977 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 50, __pyx_L1_error)
1978 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1,
"u", 0))) __PYX_ERR(0, 50, __pyx_L1_error)
1979 __pyx_r = __pyx_pf_20canalyticalSolutions_PlaneCouetteFlow_u(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_u);
1986 __Pyx_RefNannyFinishContext();
1990 static PyObject *__pyx_pf_20canalyticalSolutions_PlaneCouetteFlow_u(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u) {
1991 PyObject *__pyx_r = NULL;
1992 __Pyx_RefNannyDeclarations
1993 PyObject *__pyx_t_1 = NULL;
1994 PyObject *__pyx_t_2 = NULL;
1995 PyObject *__pyx_t_3 = NULL;
1997 int __pyx_lineno = 0;
1998 const char *__pyx_filename = NULL;
1999 int __pyx_clineno = 0;
2000 __Pyx_RefNannySetupContext(
"PlaneCouetteFlow_u", 0);
2009 __Pyx_XDECREF(__pyx_r);
2010 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 51, __pyx_L1_error)
2011 __Pyx_GOTREF(__pyx_t_1);
2012 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 51, __pyx_L1_error)
2013 __Pyx_GOTREF(__pyx_t_2);
2014 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 51, __pyx_L1_error)
2015 __Pyx_GOTREF(__pyx_t_3);
2016 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
2017 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
2018 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 51, __pyx_L1_error)
2019 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
2020 __pyx_t_3 = __Pyx_PyInt_From_int(
PlaneCouetteFlow_u(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_u->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 51, __pyx_L1_error)
2021 __Pyx_GOTREF(__pyx_t_3);
2022 __pyx_r = __pyx_t_3;
2036 __Pyx_XDECREF(__pyx_t_1);
2037 __Pyx_XDECREF(__pyx_t_2);
2038 __Pyx_XDECREF(__pyx_t_3);
2039 __Pyx_AddTraceback(
"canalyticalSolutions.PlaneCouetteFlow_u", __pyx_clineno, __pyx_lineno, __pyx_filename);
2042 __Pyx_XGIVEREF(__pyx_r);
2043 __Pyx_RefNannyFinishContext();
2056 static PyObject *__pyx_pw_20canalyticalSolutions_3diffusionSin1D(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
2057 static PyMethodDef __pyx_mdef_20canalyticalSolutions_3diffusionSin1D = {
"diffusionSin1D", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_3diffusionSin1D, METH_VARARGS|METH_KEYWORDS, 0};
2058 static PyObject *__pyx_pw_20canalyticalSolutions_3diffusionSin1D(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
2059 PyArrayObject *__pyx_v_iwork = 0;
2060 PyArrayObject *__pyx_v_rwork = 0;
2062 PyArrayObject *__pyx_v_x = 0;
2063 PyArrayObject *__pyx_v_u = 0;
2064 int __pyx_lineno = 0;
2065 const char *__pyx_filename = NULL;
2066 int __pyx_clineno = 0;
2067 PyObject *__pyx_r = 0;
2068 __Pyx_RefNannyDeclarations
2069 __Pyx_RefNannySetupContext(
"diffusionSin1D (wrapper)", 0);
2071 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_u,0};
2072 PyObject* values[5] = {0,0,0,0,0};
2073 if (unlikely(__pyx_kwds)) {
2075 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
2077 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
2079 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
2081 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
2083 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
2085 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
2088 default:
goto __pyx_L5_argtuple_error;
2090 kw_args = PyDict_Size(__pyx_kwds);
2093 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
2094 else goto __pyx_L5_argtuple_error;
2097 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
2099 __Pyx_RaiseArgtupleInvalid(
"diffusionSin1D", 1, 5, 5, 1); __PYX_ERR(0, 54, __pyx_L3_error)
2103 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
2105 __Pyx_RaiseArgtupleInvalid(
"diffusionSin1D", 1, 5, 5, 2); __PYX_ERR(0, 54, __pyx_L3_error)
2109 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
2111 __Pyx_RaiseArgtupleInvalid(
"diffusionSin1D", 1, 5, 5, 3); __PYX_ERR(0, 54, __pyx_L3_error)
2115 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
2117 __Pyx_RaiseArgtupleInvalid(
"diffusionSin1D", 1, 5, 5, 4); __PYX_ERR(0, 54, __pyx_L3_error)
2120 if (unlikely(kw_args > 0)) {
2121 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"diffusionSin1D") < 0)) __PYX_ERR(0, 54, __pyx_L3_error)
2123 }
else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
2124 goto __pyx_L5_argtuple_error;
2126 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
2127 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
2128 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
2129 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
2130 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
2132 __pyx_v_iwork = ((PyArrayObject *)values[0]);
2133 __pyx_v_rwork = ((PyArrayObject *)values[1]);
2134 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 54, __pyx_L3_error)
2135 __pyx_v_x = ((PyArrayObject *)values[3]);
2136 __pyx_v_u = ((PyArrayObject *)values[4]);
2138 goto __pyx_L4_argument_unpacking_done;
2139 __pyx_L5_argtuple_error:;
2140 __Pyx_RaiseArgtupleInvalid(
"diffusionSin1D", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 54, __pyx_L3_error)
2142 __Pyx_AddTraceback(
"canalyticalSolutions.diffusionSin1D", __pyx_clineno, __pyx_lineno, __pyx_filename);
2143 __Pyx_RefNannyFinishContext();
2145 __pyx_L4_argument_unpacking_done:;
2146 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 54, __pyx_L1_error)
2147 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 54, __pyx_L1_error)
2148 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 54, __pyx_L1_error)
2149 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1,
"u", 0))) __PYX_ERR(0, 54, __pyx_L1_error)
2150 __pyx_r = __pyx_pf_20canalyticalSolutions_2diffusionSin1D(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_u);
2157 __Pyx_RefNannyFinishContext();
2161 static PyObject *__pyx_pf_20canalyticalSolutions_2diffusionSin1D(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u) {
2162 PyObject *__pyx_r = NULL;
2163 __Pyx_RefNannyDeclarations
2164 PyObject *__pyx_t_1 = NULL;
2165 PyObject *__pyx_t_2 = NULL;
2166 PyObject *__pyx_t_3 = NULL;
2168 int __pyx_lineno = 0;
2169 const char *__pyx_filename = NULL;
2170 int __pyx_clineno = 0;
2171 __Pyx_RefNannySetupContext(
"diffusionSin1D", 0);
2180 __Pyx_XDECREF(__pyx_r);
2181 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 55, __pyx_L1_error)
2182 __Pyx_GOTREF(__pyx_t_1);
2183 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 55, __pyx_L1_error)
2184 __Pyx_GOTREF(__pyx_t_2);
2185 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 55, __pyx_L1_error)
2186 __Pyx_GOTREF(__pyx_t_3);
2187 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
2188 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
2189 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 55, __pyx_L1_error)
2190 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
2191 __pyx_t_3 = __Pyx_PyInt_From_int(
diffusionSin1D(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_u->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 55, __pyx_L1_error)
2192 __Pyx_GOTREF(__pyx_t_3);
2193 __pyx_r = __pyx_t_3;
2207 __Pyx_XDECREF(__pyx_t_1);
2208 __Pyx_XDECREF(__pyx_t_2);
2209 __Pyx_XDECREF(__pyx_t_3);
2210 __Pyx_AddTraceback(
"canalyticalSolutions.diffusionSin1D", __pyx_clineno, __pyx_lineno, __pyx_filename);
2213 __Pyx_XGIVEREF(__pyx_r);
2214 __Pyx_RefNannyFinishContext();
2227 static PyObject *__pyx_pw_20canalyticalSolutions_5diffusionSin2D(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
2228 static PyMethodDef __pyx_mdef_20canalyticalSolutions_5diffusionSin2D = {
"diffusionSin2D", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_5diffusionSin2D, METH_VARARGS|METH_KEYWORDS, 0};
2229 static PyObject *__pyx_pw_20canalyticalSolutions_5diffusionSin2D(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
2230 PyArrayObject *__pyx_v_iwork = 0;
2231 PyArrayObject *__pyx_v_rwork = 0;
2233 PyArrayObject *__pyx_v_x = 0;
2234 PyArrayObject *__pyx_v_u = 0;
2235 int __pyx_lineno = 0;
2236 const char *__pyx_filename = NULL;
2237 int __pyx_clineno = 0;
2238 PyObject *__pyx_r = 0;
2239 __Pyx_RefNannyDeclarations
2240 __Pyx_RefNannySetupContext(
"diffusionSin2D (wrapper)", 0);
2242 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_u,0};
2243 PyObject* values[5] = {0,0,0,0,0};
2244 if (unlikely(__pyx_kwds)) {
2246 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
2248 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
2250 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
2252 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
2254 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
2256 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
2259 default:
goto __pyx_L5_argtuple_error;
2261 kw_args = PyDict_Size(__pyx_kwds);
2264 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
2265 else goto __pyx_L5_argtuple_error;
2268 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
2270 __Pyx_RaiseArgtupleInvalid(
"diffusionSin2D", 1, 5, 5, 1); __PYX_ERR(0, 58, __pyx_L3_error)
2274 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
2276 __Pyx_RaiseArgtupleInvalid(
"diffusionSin2D", 1, 5, 5, 2); __PYX_ERR(0, 58, __pyx_L3_error)
2280 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
2282 __Pyx_RaiseArgtupleInvalid(
"diffusionSin2D", 1, 5, 5, 3); __PYX_ERR(0, 58, __pyx_L3_error)
2286 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
2288 __Pyx_RaiseArgtupleInvalid(
"diffusionSin2D", 1, 5, 5, 4); __PYX_ERR(0, 58, __pyx_L3_error)
2291 if (unlikely(kw_args > 0)) {
2292 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"diffusionSin2D") < 0)) __PYX_ERR(0, 58, __pyx_L3_error)
2294 }
else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
2295 goto __pyx_L5_argtuple_error;
2297 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
2298 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
2299 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
2300 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
2301 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
2303 __pyx_v_iwork = ((PyArrayObject *)values[0]);
2304 __pyx_v_rwork = ((PyArrayObject *)values[1]);
2305 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 58, __pyx_L3_error)
2306 __pyx_v_x = ((PyArrayObject *)values[3]);
2307 __pyx_v_u = ((PyArrayObject *)values[4]);
2309 goto __pyx_L4_argument_unpacking_done;
2310 __pyx_L5_argtuple_error:;
2311 __Pyx_RaiseArgtupleInvalid(
"diffusionSin2D", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 58, __pyx_L3_error)
2313 __Pyx_AddTraceback(
"canalyticalSolutions.diffusionSin2D", __pyx_clineno, __pyx_lineno, __pyx_filename);
2314 __Pyx_RefNannyFinishContext();
2316 __pyx_L4_argument_unpacking_done:;
2317 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 58, __pyx_L1_error)
2318 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 58, __pyx_L1_error)
2319 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 58, __pyx_L1_error)
2320 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1,
"u", 0))) __PYX_ERR(0, 58, __pyx_L1_error)
2321 __pyx_r = __pyx_pf_20canalyticalSolutions_4diffusionSin2D(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_u);
2328 __Pyx_RefNannyFinishContext();
2332 static PyObject *__pyx_pf_20canalyticalSolutions_4diffusionSin2D(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u) {
2333 PyObject *__pyx_r = NULL;
2334 __Pyx_RefNannyDeclarations
2335 PyObject *__pyx_t_1 = NULL;
2336 PyObject *__pyx_t_2 = NULL;
2337 PyObject *__pyx_t_3 = NULL;
2339 int __pyx_lineno = 0;
2340 const char *__pyx_filename = NULL;
2341 int __pyx_clineno = 0;
2342 __Pyx_RefNannySetupContext(
"diffusionSin2D", 0);
2351 __Pyx_XDECREF(__pyx_r);
2352 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 59, __pyx_L1_error)
2353 __Pyx_GOTREF(__pyx_t_1);
2354 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 59, __pyx_L1_error)
2355 __Pyx_GOTREF(__pyx_t_2);
2356 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 59, __pyx_L1_error)
2357 __Pyx_GOTREF(__pyx_t_3);
2358 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
2359 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
2360 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 59, __pyx_L1_error)
2361 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
2362 __pyx_t_3 = __Pyx_PyInt_From_int(
diffusionSin2D(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_u->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 59, __pyx_L1_error)
2363 __Pyx_GOTREF(__pyx_t_3);
2364 __pyx_r = __pyx_t_3;
2378 __Pyx_XDECREF(__pyx_t_1);
2379 __Pyx_XDECREF(__pyx_t_2);
2380 __Pyx_XDECREF(__pyx_t_3);
2381 __Pyx_AddTraceback(
"canalyticalSolutions.diffusionSin2D", __pyx_clineno, __pyx_lineno, __pyx_filename);
2384 __Pyx_XGIVEREF(__pyx_r);
2385 __Pyx_RefNannyFinishContext();
2398 static PyObject *__pyx_pw_20canalyticalSolutions_7diffusionSin3D(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
2399 static PyMethodDef __pyx_mdef_20canalyticalSolutions_7diffusionSin3D = {
"diffusionSin3D", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_7diffusionSin3D, METH_VARARGS|METH_KEYWORDS, 0};
2400 static PyObject *__pyx_pw_20canalyticalSolutions_7diffusionSin3D(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
2401 PyArrayObject *__pyx_v_iwork = 0;
2402 PyArrayObject *__pyx_v_rwork = 0;
2404 PyArrayObject *__pyx_v_x = 0;
2405 PyArrayObject *__pyx_v_u = 0;
2406 int __pyx_lineno = 0;
2407 const char *__pyx_filename = NULL;
2408 int __pyx_clineno = 0;
2409 PyObject *__pyx_r = 0;
2410 __Pyx_RefNannyDeclarations
2411 __Pyx_RefNannySetupContext(
"diffusionSin3D (wrapper)", 0);
2413 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_u,0};
2414 PyObject* values[5] = {0,0,0,0,0};
2415 if (unlikely(__pyx_kwds)) {
2417 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
2419 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
2421 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
2423 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
2425 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
2427 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
2430 default:
goto __pyx_L5_argtuple_error;
2432 kw_args = PyDict_Size(__pyx_kwds);
2435 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
2436 else goto __pyx_L5_argtuple_error;
2439 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
2441 __Pyx_RaiseArgtupleInvalid(
"diffusionSin3D", 1, 5, 5, 1); __PYX_ERR(0, 62, __pyx_L3_error)
2445 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
2447 __Pyx_RaiseArgtupleInvalid(
"diffusionSin3D", 1, 5, 5, 2); __PYX_ERR(0, 62, __pyx_L3_error)
2451 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
2453 __Pyx_RaiseArgtupleInvalid(
"diffusionSin3D", 1, 5, 5, 3); __PYX_ERR(0, 62, __pyx_L3_error)
2457 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
2459 __Pyx_RaiseArgtupleInvalid(
"diffusionSin3D", 1, 5, 5, 4); __PYX_ERR(0, 62, __pyx_L3_error)
2462 if (unlikely(kw_args > 0)) {
2463 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"diffusionSin3D") < 0)) __PYX_ERR(0, 62, __pyx_L3_error)
2465 }
else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
2466 goto __pyx_L5_argtuple_error;
2468 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
2469 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
2470 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
2471 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
2472 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
2474 __pyx_v_iwork = ((PyArrayObject *)values[0]);
2475 __pyx_v_rwork = ((PyArrayObject *)values[1]);
2476 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 62, __pyx_L3_error)
2477 __pyx_v_x = ((PyArrayObject *)values[3]);
2478 __pyx_v_u = ((PyArrayObject *)values[4]);
2480 goto __pyx_L4_argument_unpacking_done;
2481 __pyx_L5_argtuple_error:;
2482 __Pyx_RaiseArgtupleInvalid(
"diffusionSin3D", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 62, __pyx_L3_error)
2484 __Pyx_AddTraceback(
"canalyticalSolutions.diffusionSin3D", __pyx_clineno, __pyx_lineno, __pyx_filename);
2485 __Pyx_RefNannyFinishContext();
2487 __pyx_L4_argument_unpacking_done:;
2488 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 62, __pyx_L1_error)
2489 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 62, __pyx_L1_error)
2490 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 62, __pyx_L1_error)
2491 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1,
"u", 0))) __PYX_ERR(0, 62, __pyx_L1_error)
2492 __pyx_r = __pyx_pf_20canalyticalSolutions_6diffusionSin3D(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_u);
2499 __Pyx_RefNannyFinishContext();
2503 static PyObject *__pyx_pf_20canalyticalSolutions_6diffusionSin3D(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u) {
2504 PyObject *__pyx_r = NULL;
2505 __Pyx_RefNannyDeclarations
2506 PyObject *__pyx_t_1 = NULL;
2507 PyObject *__pyx_t_2 = NULL;
2508 PyObject *__pyx_t_3 = NULL;
2510 int __pyx_lineno = 0;
2511 const char *__pyx_filename = NULL;
2512 int __pyx_clineno = 0;
2513 __Pyx_RefNannySetupContext(
"diffusionSin3D", 0);
2522 __Pyx_XDECREF(__pyx_r);
2523 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 63, __pyx_L1_error)
2524 __Pyx_GOTREF(__pyx_t_1);
2525 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 63, __pyx_L1_error)
2526 __Pyx_GOTREF(__pyx_t_2);
2527 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 63, __pyx_L1_error)
2528 __Pyx_GOTREF(__pyx_t_3);
2529 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
2530 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
2531 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 63, __pyx_L1_error)
2532 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
2533 __pyx_t_3 = __Pyx_PyInt_From_int(
diffusionSin3D(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_u->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 63, __pyx_L1_error)
2534 __Pyx_GOTREF(__pyx_t_3);
2535 __pyx_r = __pyx_t_3;
2549 __Pyx_XDECREF(__pyx_t_1);
2550 __Pyx_XDECREF(__pyx_t_2);
2551 __Pyx_XDECREF(__pyx_t_3);
2552 __Pyx_AddTraceback(
"canalyticalSolutions.diffusionSin3D", __pyx_clineno, __pyx_lineno, __pyx_filename);
2555 __Pyx_XGIVEREF(__pyx_r);
2556 __Pyx_RefNannyFinishContext();
2569 static PyObject *__pyx_pw_20canalyticalSolutions_9diffusionSin1D_r(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
2570 static PyMethodDef __pyx_mdef_20canalyticalSolutions_9diffusionSin1D_r = {
"diffusionSin1D_r", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_9diffusionSin1D_r, METH_VARARGS|METH_KEYWORDS, 0};
2571 static PyObject *__pyx_pw_20canalyticalSolutions_9diffusionSin1D_r(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
2572 PyArrayObject *__pyx_v_iwork = 0;
2573 PyArrayObject *__pyx_v_rwork = 0;
2575 PyArrayObject *__pyx_v_x = 0;
2576 PyArrayObject *__pyx_v_u = 0;
2577 PyArrayObject *__pyx_v_r = 0;
2578 int __pyx_lineno = 0;
2579 const char *__pyx_filename = NULL;
2580 int __pyx_clineno = 0;
2581 PyObject *__pyx_r = 0;
2582 __Pyx_RefNannyDeclarations
2583 __Pyx_RefNannySetupContext(
"diffusionSin1D_r (wrapper)", 0);
2585 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_u,&__pyx_n_s_r,0};
2586 PyObject* values[6] = {0,0,0,0,0,0};
2587 if (unlikely(__pyx_kwds)) {
2589 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
2591 case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
2593 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
2595 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
2597 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
2599 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
2601 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
2604 default:
goto __pyx_L5_argtuple_error;
2606 kw_args = PyDict_Size(__pyx_kwds);
2609 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
2610 else goto __pyx_L5_argtuple_error;
2613 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
2615 __Pyx_RaiseArgtupleInvalid(
"diffusionSin1D_r", 1, 6, 6, 1); __PYX_ERR(0, 66, __pyx_L3_error)
2619 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
2621 __Pyx_RaiseArgtupleInvalid(
"diffusionSin1D_r", 1, 6, 6, 2); __PYX_ERR(0, 66, __pyx_L3_error)
2625 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
2627 __Pyx_RaiseArgtupleInvalid(
"diffusionSin1D_r", 1, 6, 6, 3); __PYX_ERR(0, 66, __pyx_L3_error)
2631 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
2633 __Pyx_RaiseArgtupleInvalid(
"diffusionSin1D_r", 1, 6, 6, 4); __PYX_ERR(0, 66, __pyx_L3_error)
2637 if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_r)) != 0)) kw_args--;
2639 __Pyx_RaiseArgtupleInvalid(
"diffusionSin1D_r", 1, 6, 6, 5); __PYX_ERR(0, 66, __pyx_L3_error)
2642 if (unlikely(kw_args > 0)) {
2643 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"diffusionSin1D_r") < 0)) __PYX_ERR(0, 66, __pyx_L3_error)
2645 }
else if (PyTuple_GET_SIZE(__pyx_args) != 6) {
2646 goto __pyx_L5_argtuple_error;
2648 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
2649 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
2650 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
2651 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
2652 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
2653 values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
2655 __pyx_v_iwork = ((PyArrayObject *)values[0]);
2656 __pyx_v_rwork = ((PyArrayObject *)values[1]);
2657 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 66, __pyx_L3_error)
2658 __pyx_v_x = ((PyArrayObject *)values[3]);
2659 __pyx_v_u = ((PyArrayObject *)values[4]);
2660 __pyx_v_r = ((PyArrayObject *)values[5]);
2662 goto __pyx_L4_argument_unpacking_done;
2663 __pyx_L5_argtuple_error:;
2664 __Pyx_RaiseArgtupleInvalid(
"diffusionSin1D_r", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 66, __pyx_L3_error)
2666 __Pyx_AddTraceback(
"canalyticalSolutions.diffusionSin1D_r", __pyx_clineno, __pyx_lineno, __pyx_filename);
2667 __Pyx_RefNannyFinishContext();
2669 __pyx_L4_argument_unpacking_done:;
2670 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 66, __pyx_L1_error)
2671 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 66, __pyx_L1_error)
2672 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 66, __pyx_L1_error)
2673 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1,
"u", 0))) __PYX_ERR(0, 66, __pyx_L1_error)
2674 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_r), __pyx_ptype_5numpy_ndarray, 1,
"r", 0))) __PYX_ERR(0, 66, __pyx_L1_error)
2675 __pyx_r = __pyx_pf_20canalyticalSolutions_8diffusionSin1D_r(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_u, __pyx_v_r);
2682 __Pyx_RefNannyFinishContext();
2686 static PyObject *__pyx_pf_20canalyticalSolutions_8diffusionSin1D_r(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_r) {
2687 PyObject *__pyx_r = NULL;
2688 __Pyx_RefNannyDeclarations
2689 PyObject *__pyx_t_1 = NULL;
2690 PyObject *__pyx_t_2 = NULL;
2691 PyObject *__pyx_t_3 = NULL;
2693 int __pyx_lineno = 0;
2694 const char *__pyx_filename = NULL;
2695 int __pyx_clineno = 0;
2696 __Pyx_RefNannySetupContext(
"diffusionSin1D_r", 0);
2705 __Pyx_XDECREF(__pyx_r);
2706 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 67, __pyx_L1_error)
2707 __Pyx_GOTREF(__pyx_t_1);
2708 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 67, __pyx_L1_error)
2709 __Pyx_GOTREF(__pyx_t_2);
2710 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 67, __pyx_L1_error)
2711 __Pyx_GOTREF(__pyx_t_3);
2712 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
2713 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
2714 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 67, __pyx_L1_error)
2715 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
2716 __pyx_t_3 = __Pyx_PyInt_From_int(
diffusionSin1D_r(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_u->data), ((
double *)__pyx_v_r->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 67, __pyx_L1_error)
2717 __Pyx_GOTREF(__pyx_t_3);
2718 __pyx_r = __pyx_t_3;
2732 __Pyx_XDECREF(__pyx_t_1);
2733 __Pyx_XDECREF(__pyx_t_2);
2734 __Pyx_XDECREF(__pyx_t_3);
2735 __Pyx_AddTraceback(
"canalyticalSolutions.diffusionSin1D_r", __pyx_clineno, __pyx_lineno, __pyx_filename);
2738 __Pyx_XGIVEREF(__pyx_r);
2739 __Pyx_RefNannyFinishContext();
2752 static PyObject *__pyx_pw_20canalyticalSolutions_11diffusionSin2D_r(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
2753 static PyMethodDef __pyx_mdef_20canalyticalSolutions_11diffusionSin2D_r = {
"diffusionSin2D_r", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_11diffusionSin2D_r, METH_VARARGS|METH_KEYWORDS, 0};
2754 static PyObject *__pyx_pw_20canalyticalSolutions_11diffusionSin2D_r(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
2755 PyArrayObject *__pyx_v_iwork = 0;
2756 PyArrayObject *__pyx_v_rwork = 0;
2758 PyArrayObject *__pyx_v_x = 0;
2759 PyArrayObject *__pyx_v_u = 0;
2760 PyArrayObject *__pyx_v_r = 0;
2761 int __pyx_lineno = 0;
2762 const char *__pyx_filename = NULL;
2763 int __pyx_clineno = 0;
2764 PyObject *__pyx_r = 0;
2765 __Pyx_RefNannyDeclarations
2766 __Pyx_RefNannySetupContext(
"diffusionSin2D_r (wrapper)", 0);
2768 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_u,&__pyx_n_s_r,0};
2769 PyObject* values[6] = {0,0,0,0,0,0};
2770 if (unlikely(__pyx_kwds)) {
2772 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
2774 case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
2776 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
2778 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
2780 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
2782 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
2784 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
2787 default:
goto __pyx_L5_argtuple_error;
2789 kw_args = PyDict_Size(__pyx_kwds);
2792 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
2793 else goto __pyx_L5_argtuple_error;
2796 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
2798 __Pyx_RaiseArgtupleInvalid(
"diffusionSin2D_r", 1, 6, 6, 1); __PYX_ERR(0, 70, __pyx_L3_error)
2802 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
2804 __Pyx_RaiseArgtupleInvalid(
"diffusionSin2D_r", 1, 6, 6, 2); __PYX_ERR(0, 70, __pyx_L3_error)
2808 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
2810 __Pyx_RaiseArgtupleInvalid(
"diffusionSin2D_r", 1, 6, 6, 3); __PYX_ERR(0, 70, __pyx_L3_error)
2814 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
2816 __Pyx_RaiseArgtupleInvalid(
"diffusionSin2D_r", 1, 6, 6, 4); __PYX_ERR(0, 70, __pyx_L3_error)
2820 if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_r)) != 0)) kw_args--;
2822 __Pyx_RaiseArgtupleInvalid(
"diffusionSin2D_r", 1, 6, 6, 5); __PYX_ERR(0, 70, __pyx_L3_error)
2825 if (unlikely(kw_args > 0)) {
2826 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"diffusionSin2D_r") < 0)) __PYX_ERR(0, 70, __pyx_L3_error)
2828 }
else if (PyTuple_GET_SIZE(__pyx_args) != 6) {
2829 goto __pyx_L5_argtuple_error;
2831 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
2832 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
2833 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
2834 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
2835 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
2836 values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
2838 __pyx_v_iwork = ((PyArrayObject *)values[0]);
2839 __pyx_v_rwork = ((PyArrayObject *)values[1]);
2840 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 70, __pyx_L3_error)
2841 __pyx_v_x = ((PyArrayObject *)values[3]);
2842 __pyx_v_u = ((PyArrayObject *)values[4]);
2843 __pyx_v_r = ((PyArrayObject *)values[5]);
2845 goto __pyx_L4_argument_unpacking_done;
2846 __pyx_L5_argtuple_error:;
2847 __Pyx_RaiseArgtupleInvalid(
"diffusionSin2D_r", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 70, __pyx_L3_error)
2849 __Pyx_AddTraceback(
"canalyticalSolutions.diffusionSin2D_r", __pyx_clineno, __pyx_lineno, __pyx_filename);
2850 __Pyx_RefNannyFinishContext();
2852 __pyx_L4_argument_unpacking_done:;
2853 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 70, __pyx_L1_error)
2854 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 70, __pyx_L1_error)
2855 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 70, __pyx_L1_error)
2856 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1,
"u", 0))) __PYX_ERR(0, 70, __pyx_L1_error)
2857 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_r), __pyx_ptype_5numpy_ndarray, 1,
"r", 0))) __PYX_ERR(0, 70, __pyx_L1_error)
2858 __pyx_r = __pyx_pf_20canalyticalSolutions_10diffusionSin2D_r(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_u, __pyx_v_r);
2865 __Pyx_RefNannyFinishContext();
2869 static PyObject *__pyx_pf_20canalyticalSolutions_10diffusionSin2D_r(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_r) {
2870 PyObject *__pyx_r = NULL;
2871 __Pyx_RefNannyDeclarations
2872 PyObject *__pyx_t_1 = NULL;
2873 PyObject *__pyx_t_2 = NULL;
2874 PyObject *__pyx_t_3 = NULL;
2876 int __pyx_lineno = 0;
2877 const char *__pyx_filename = NULL;
2878 int __pyx_clineno = 0;
2879 __Pyx_RefNannySetupContext(
"diffusionSin2D_r", 0);
2888 __Pyx_XDECREF(__pyx_r);
2889 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 71, __pyx_L1_error)
2890 __Pyx_GOTREF(__pyx_t_1);
2891 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 71, __pyx_L1_error)
2892 __Pyx_GOTREF(__pyx_t_2);
2893 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 71, __pyx_L1_error)
2894 __Pyx_GOTREF(__pyx_t_3);
2895 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
2896 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
2897 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 71, __pyx_L1_error)
2898 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
2899 __pyx_t_3 = __Pyx_PyInt_From_int(
diffusionSin2D_r(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_u->data), ((
double *)__pyx_v_r->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 71, __pyx_L1_error)
2900 __Pyx_GOTREF(__pyx_t_3);
2901 __pyx_r = __pyx_t_3;
2915 __Pyx_XDECREF(__pyx_t_1);
2916 __Pyx_XDECREF(__pyx_t_2);
2917 __Pyx_XDECREF(__pyx_t_3);
2918 __Pyx_AddTraceback(
"canalyticalSolutions.diffusionSin2D_r", __pyx_clineno, __pyx_lineno, __pyx_filename);
2921 __Pyx_XGIVEREF(__pyx_r);
2922 __Pyx_RefNannyFinishContext();
2935 static PyObject *__pyx_pw_20canalyticalSolutions_13diffusionSin3D_r(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
2936 static PyMethodDef __pyx_mdef_20canalyticalSolutions_13diffusionSin3D_r = {
"diffusionSin3D_r", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_13diffusionSin3D_r, METH_VARARGS|METH_KEYWORDS, 0};
2937 static PyObject *__pyx_pw_20canalyticalSolutions_13diffusionSin3D_r(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
2938 PyArrayObject *__pyx_v_iwork = 0;
2939 PyArrayObject *__pyx_v_rwork = 0;
2941 PyArrayObject *__pyx_v_x = 0;
2942 PyArrayObject *__pyx_v_u = 0;
2943 PyArrayObject *__pyx_v_r = 0;
2944 int __pyx_lineno = 0;
2945 const char *__pyx_filename = NULL;
2946 int __pyx_clineno = 0;
2947 PyObject *__pyx_r = 0;
2948 __Pyx_RefNannyDeclarations
2949 __Pyx_RefNannySetupContext(
"diffusionSin3D_r (wrapper)", 0);
2951 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_u,&__pyx_n_s_r,0};
2952 PyObject* values[6] = {0,0,0,0,0,0};
2953 if (unlikely(__pyx_kwds)) {
2955 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
2957 case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
2959 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
2961 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
2963 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
2965 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
2967 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
2970 default:
goto __pyx_L5_argtuple_error;
2972 kw_args = PyDict_Size(__pyx_kwds);
2975 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
2976 else goto __pyx_L5_argtuple_error;
2979 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
2981 __Pyx_RaiseArgtupleInvalid(
"diffusionSin3D_r", 1, 6, 6, 1); __PYX_ERR(0, 74, __pyx_L3_error)
2985 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
2987 __Pyx_RaiseArgtupleInvalid(
"diffusionSin3D_r", 1, 6, 6, 2); __PYX_ERR(0, 74, __pyx_L3_error)
2991 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
2993 __Pyx_RaiseArgtupleInvalid(
"diffusionSin3D_r", 1, 6, 6, 3); __PYX_ERR(0, 74, __pyx_L3_error)
2997 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
2999 __Pyx_RaiseArgtupleInvalid(
"diffusionSin3D_r", 1, 6, 6, 4); __PYX_ERR(0, 74, __pyx_L3_error)
3003 if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_r)) != 0)) kw_args--;
3005 __Pyx_RaiseArgtupleInvalid(
"diffusionSin3D_r", 1, 6, 6, 5); __PYX_ERR(0, 74, __pyx_L3_error)
3008 if (unlikely(kw_args > 0)) {
3009 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"diffusionSin3D_r") < 0)) __PYX_ERR(0, 74, __pyx_L3_error)
3011 }
else if (PyTuple_GET_SIZE(__pyx_args) != 6) {
3012 goto __pyx_L5_argtuple_error;
3014 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
3015 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
3016 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
3017 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
3018 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
3019 values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
3021 __pyx_v_iwork = ((PyArrayObject *)values[0]);
3022 __pyx_v_rwork = ((PyArrayObject *)values[1]);
3023 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 74, __pyx_L3_error)
3024 __pyx_v_x = ((PyArrayObject *)values[3]);
3025 __pyx_v_u = ((PyArrayObject *)values[4]);
3026 __pyx_v_r = ((PyArrayObject *)values[5]);
3028 goto __pyx_L4_argument_unpacking_done;
3029 __pyx_L5_argtuple_error:;
3030 __Pyx_RaiseArgtupleInvalid(
"diffusionSin3D_r", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 74, __pyx_L3_error)
3032 __Pyx_AddTraceback(
"canalyticalSolutions.diffusionSin3D_r", __pyx_clineno, __pyx_lineno, __pyx_filename);
3033 __Pyx_RefNannyFinishContext();
3035 __pyx_L4_argument_unpacking_done:;
3036 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 74, __pyx_L1_error)
3037 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 74, __pyx_L1_error)
3038 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 74, __pyx_L1_error)
3039 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1,
"u", 0))) __PYX_ERR(0, 74, __pyx_L1_error)
3040 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_r), __pyx_ptype_5numpy_ndarray, 1,
"r", 0))) __PYX_ERR(0, 74, __pyx_L1_error)
3041 __pyx_r = __pyx_pf_20canalyticalSolutions_12diffusionSin3D_r(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_u, __pyx_v_r);
3048 __Pyx_RefNannyFinishContext();
3052 static PyObject *__pyx_pf_20canalyticalSolutions_12diffusionSin3D_r(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_r) {
3053 PyObject *__pyx_r = NULL;
3054 __Pyx_RefNannyDeclarations
3055 PyObject *__pyx_t_1 = NULL;
3056 PyObject *__pyx_t_2 = NULL;
3057 PyObject *__pyx_t_3 = NULL;
3059 int __pyx_lineno = 0;
3060 const char *__pyx_filename = NULL;
3061 int __pyx_clineno = 0;
3062 __Pyx_RefNannySetupContext(
"diffusionSin3D_r", 0);
3071 __Pyx_XDECREF(__pyx_r);
3072 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 75, __pyx_L1_error)
3073 __Pyx_GOTREF(__pyx_t_1);
3074 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 75, __pyx_L1_error)
3075 __Pyx_GOTREF(__pyx_t_2);
3076 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 75, __pyx_L1_error)
3077 __Pyx_GOTREF(__pyx_t_3);
3078 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
3079 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
3080 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 75, __pyx_L1_error)
3081 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3082 __pyx_t_3 = __Pyx_PyInt_From_int(
diffusionSin3D_r(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_u->data), ((
double *)__pyx_v_r->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 75, __pyx_L1_error)
3083 __Pyx_GOTREF(__pyx_t_3);
3084 __pyx_r = __pyx_t_3;
3098 __Pyx_XDECREF(__pyx_t_1);
3099 __Pyx_XDECREF(__pyx_t_2);
3100 __Pyx_XDECREF(__pyx_t_3);
3101 __Pyx_AddTraceback(
"canalyticalSolutions.diffusionSin3D_r", __pyx_clineno, __pyx_lineno, __pyx_filename);
3104 __Pyx_XGIVEREF(__pyx_r);
3105 __Pyx_RefNannyFinishContext();
3118 static PyObject *__pyx_pw_20canalyticalSolutions_15LinearAD_DiracIC(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
3119 static PyMethodDef __pyx_mdef_20canalyticalSolutions_15LinearAD_DiracIC = {
"LinearAD_DiracIC", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_15LinearAD_DiracIC, METH_VARARGS|METH_KEYWORDS, 0};
3120 static PyObject *__pyx_pw_20canalyticalSolutions_15LinearAD_DiracIC(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
3121 PyArrayObject *__pyx_v_iwork = 0;
3122 PyArrayObject *__pyx_v_rwork = 0;
3124 PyArrayObject *__pyx_v_x = 0;
3125 PyArrayObject *__pyx_v_u = 0;
3126 int __pyx_lineno = 0;
3127 const char *__pyx_filename = NULL;
3128 int __pyx_clineno = 0;
3129 PyObject *__pyx_r = 0;
3130 __Pyx_RefNannyDeclarations
3131 __Pyx_RefNannySetupContext(
"LinearAD_DiracIC (wrapper)", 0);
3133 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_u,0};
3134 PyObject* values[5] = {0,0,0,0,0};
3135 if (unlikely(__pyx_kwds)) {
3137 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
3139 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
3141 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
3143 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
3145 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
3147 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
3150 default:
goto __pyx_L5_argtuple_error;
3152 kw_args = PyDict_Size(__pyx_kwds);
3155 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
3156 else goto __pyx_L5_argtuple_error;
3159 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
3161 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC", 1, 5, 5, 1); __PYX_ERR(0, 78, __pyx_L3_error)
3165 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
3167 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC", 1, 5, 5, 2); __PYX_ERR(0, 78, __pyx_L3_error)
3171 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
3173 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC", 1, 5, 5, 3); __PYX_ERR(0, 78, __pyx_L3_error)
3177 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
3179 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC", 1, 5, 5, 4); __PYX_ERR(0, 78, __pyx_L3_error)
3182 if (unlikely(kw_args > 0)) {
3183 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"LinearAD_DiracIC") < 0)) __PYX_ERR(0, 78, __pyx_L3_error)
3185 }
else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
3186 goto __pyx_L5_argtuple_error;
3188 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
3189 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
3190 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
3191 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
3192 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
3194 __pyx_v_iwork = ((PyArrayObject *)values[0]);
3195 __pyx_v_rwork = ((PyArrayObject *)values[1]);
3196 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 78, __pyx_L3_error)
3197 __pyx_v_x = ((PyArrayObject *)values[3]);
3198 __pyx_v_u = ((PyArrayObject *)values[4]);
3200 goto __pyx_L4_argument_unpacking_done;
3201 __pyx_L5_argtuple_error:;
3202 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 78, __pyx_L3_error)
3204 __Pyx_AddTraceback(
"canalyticalSolutions.LinearAD_DiracIC", __pyx_clineno, __pyx_lineno, __pyx_filename);
3205 __Pyx_RefNannyFinishContext();
3207 __pyx_L4_argument_unpacking_done:;
3208 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 78, __pyx_L1_error)
3209 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 78, __pyx_L1_error)
3210 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 78, __pyx_L1_error)
3211 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1,
"u", 0))) __PYX_ERR(0, 78, __pyx_L1_error)
3212 __pyx_r = __pyx_pf_20canalyticalSolutions_14LinearAD_DiracIC(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_u);
3219 __Pyx_RefNannyFinishContext();
3223 static PyObject *__pyx_pf_20canalyticalSolutions_14LinearAD_DiracIC(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u) {
3224 PyObject *__pyx_r = NULL;
3225 __Pyx_RefNannyDeclarations
3226 PyObject *__pyx_t_1 = NULL;
3227 PyObject *__pyx_t_2 = NULL;
3228 PyObject *__pyx_t_3 = NULL;
3230 int __pyx_lineno = 0;
3231 const char *__pyx_filename = NULL;
3232 int __pyx_clineno = 0;
3233 __Pyx_RefNannySetupContext(
"LinearAD_DiracIC", 0);
3242 __Pyx_XDECREF(__pyx_r);
3243 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 79, __pyx_L1_error)
3244 __Pyx_GOTREF(__pyx_t_1);
3245 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 79, __pyx_L1_error)
3246 __Pyx_GOTREF(__pyx_t_2);
3247 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 79, __pyx_L1_error)
3248 __Pyx_GOTREF(__pyx_t_3);
3249 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
3250 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
3251 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 79, __pyx_L1_error)
3252 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3253 __pyx_t_3 = __Pyx_PyInt_From_int(
LinearAD_DiracIC(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_u->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 79, __pyx_L1_error)
3254 __Pyx_GOTREF(__pyx_t_3);
3255 __pyx_r = __pyx_t_3;
3269 __Pyx_XDECREF(__pyx_t_1);
3270 __Pyx_XDECREF(__pyx_t_2);
3271 __Pyx_XDECREF(__pyx_t_3);
3272 __Pyx_AddTraceback(
"canalyticalSolutions.LinearAD_DiracIC", __pyx_clineno, __pyx_lineno, __pyx_filename);
3275 __Pyx_XGIVEREF(__pyx_r);
3276 __Pyx_RefNannyFinishContext();
3289 static PyObject *__pyx_pw_20canalyticalSolutions_17LinearAD_DiracIC_advectiveVelocity(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
3290 static PyMethodDef __pyx_mdef_20canalyticalSolutions_17LinearAD_DiracIC_advectiveVelocity = {
"LinearAD_DiracIC_advectiveVelocity", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_17LinearAD_DiracIC_advectiveVelocity, METH_VARARGS|METH_KEYWORDS, 0};
3291 static PyObject *__pyx_pw_20canalyticalSolutions_17LinearAD_DiracIC_advectiveVelocity(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
3292 PyArrayObject *__pyx_v_iwork = 0;
3293 PyArrayObject *__pyx_v_rwork = 0;
3295 PyArrayObject *__pyx_v_x = 0;
3296 PyArrayObject *__pyx_v_f = 0;
3297 int __pyx_lineno = 0;
3298 const char *__pyx_filename = NULL;
3299 int __pyx_clineno = 0;
3300 PyObject *__pyx_r = 0;
3301 __Pyx_RefNannyDeclarations
3302 __Pyx_RefNannySetupContext(
"LinearAD_DiracIC_advectiveVelocity (wrapper)", 0);
3304 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_f,0};
3305 PyObject* values[5] = {0,0,0,0,0};
3306 if (unlikely(__pyx_kwds)) {
3308 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
3310 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
3312 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
3314 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
3316 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
3318 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
3321 default:
goto __pyx_L5_argtuple_error;
3323 kw_args = PyDict_Size(__pyx_kwds);
3326 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
3327 else goto __pyx_L5_argtuple_error;
3330 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
3332 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC_advectiveVelocity", 1, 5, 5, 1); __PYX_ERR(0, 82, __pyx_L3_error)
3336 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
3338 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC_advectiveVelocity", 1, 5, 5, 2); __PYX_ERR(0, 82, __pyx_L3_error)
3342 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
3344 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC_advectiveVelocity", 1, 5, 5, 3); __PYX_ERR(0, 82, __pyx_L3_error)
3348 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_f)) != 0)) kw_args--;
3350 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC_advectiveVelocity", 1, 5, 5, 4); __PYX_ERR(0, 82, __pyx_L3_error)
3353 if (unlikely(kw_args > 0)) {
3354 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"LinearAD_DiracIC_advectiveVelocity") < 0)) __PYX_ERR(0, 82, __pyx_L3_error)
3356 }
else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
3357 goto __pyx_L5_argtuple_error;
3359 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
3360 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
3361 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
3362 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
3363 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
3365 __pyx_v_iwork = ((PyArrayObject *)values[0]);
3366 __pyx_v_rwork = ((PyArrayObject *)values[1]);
3367 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 82, __pyx_L3_error)
3368 __pyx_v_x = ((PyArrayObject *)values[3]);
3369 __pyx_v_f = ((PyArrayObject *)values[4]);
3371 goto __pyx_L4_argument_unpacking_done;
3372 __pyx_L5_argtuple_error:;
3373 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC_advectiveVelocity", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 82, __pyx_L3_error)
3375 __Pyx_AddTraceback(
"canalyticalSolutions.LinearAD_DiracIC_advectiveVelocity", __pyx_clineno, __pyx_lineno, __pyx_filename);
3376 __Pyx_RefNannyFinishContext();
3378 __pyx_L4_argument_unpacking_done:;
3379 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 82, __pyx_L1_error)
3380 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 82, __pyx_L1_error)
3381 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 82, __pyx_L1_error)
3382 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_f), __pyx_ptype_5numpy_ndarray, 1,
"f", 0))) __PYX_ERR(0, 82, __pyx_L1_error)
3383 __pyx_r = __pyx_pf_20canalyticalSolutions_16LinearAD_DiracIC_advectiveVelocity(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_f);
3390 __Pyx_RefNannyFinishContext();
3394 static PyObject *__pyx_pf_20canalyticalSolutions_16LinearAD_DiracIC_advectiveVelocity(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_f) {
3395 PyObject *__pyx_r = NULL;
3396 __Pyx_RefNannyDeclarations
3397 PyObject *__pyx_t_1 = NULL;
3398 PyObject *__pyx_t_2 = NULL;
3399 PyObject *__pyx_t_3 = NULL;
3401 int __pyx_lineno = 0;
3402 const char *__pyx_filename = NULL;
3403 int __pyx_clineno = 0;
3404 __Pyx_RefNannySetupContext(
"LinearAD_DiracIC_advectiveVelocity", 0);
3413 __Pyx_XDECREF(__pyx_r);
3414 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 83, __pyx_L1_error)
3415 __Pyx_GOTREF(__pyx_t_1);
3416 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 83, __pyx_L1_error)
3417 __Pyx_GOTREF(__pyx_t_2);
3418 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 83, __pyx_L1_error)
3419 __Pyx_GOTREF(__pyx_t_3);
3420 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
3421 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
3422 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 83, __pyx_L1_error)
3423 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3424 __pyx_t_3 = __Pyx_PyInt_From_int(
LinearAD_DiracIC_advectiveVelocity(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_f->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 83, __pyx_L1_error)
3425 __Pyx_GOTREF(__pyx_t_3);
3426 __pyx_r = __pyx_t_3;
3440 __Pyx_XDECREF(__pyx_t_1);
3441 __Pyx_XDECREF(__pyx_t_2);
3442 __Pyx_XDECREF(__pyx_t_3);
3443 __Pyx_AddTraceback(
"canalyticalSolutions.LinearAD_DiracIC_advectiveVelocity", __pyx_clineno, __pyx_lineno, __pyx_filename);
3446 __Pyx_XGIVEREF(__pyx_r);
3447 __Pyx_RefNannyFinishContext();
3460 static PyObject *__pyx_pw_20canalyticalSolutions_19LinearAD_DiracIC_diffusiveVelocity(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
3461 static PyMethodDef __pyx_mdef_20canalyticalSolutions_19LinearAD_DiracIC_diffusiveVelocity = {
"LinearAD_DiracIC_diffusiveVelocity", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_19LinearAD_DiracIC_diffusiveVelocity, METH_VARARGS|METH_KEYWORDS, 0};
3462 static PyObject *__pyx_pw_20canalyticalSolutions_19LinearAD_DiracIC_diffusiveVelocity(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
3463 PyArrayObject *__pyx_v_iwork = 0;
3464 PyArrayObject *__pyx_v_rwork = 0;
3466 PyArrayObject *__pyx_v_x = 0;
3467 PyArrayObject *__pyx_v_f = 0;
3468 int __pyx_lineno = 0;
3469 const char *__pyx_filename = NULL;
3470 int __pyx_clineno = 0;
3471 PyObject *__pyx_r = 0;
3472 __Pyx_RefNannyDeclarations
3473 __Pyx_RefNannySetupContext(
"LinearAD_DiracIC_diffusiveVelocity (wrapper)", 0);
3475 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_f,0};
3476 PyObject* values[5] = {0,0,0,0,0};
3477 if (unlikely(__pyx_kwds)) {
3479 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
3481 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
3483 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
3485 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
3487 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
3489 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
3492 default:
goto __pyx_L5_argtuple_error;
3494 kw_args = PyDict_Size(__pyx_kwds);
3497 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
3498 else goto __pyx_L5_argtuple_error;
3501 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
3503 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC_diffusiveVelocity", 1, 5, 5, 1); __PYX_ERR(0, 86, __pyx_L3_error)
3507 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
3509 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC_diffusiveVelocity", 1, 5, 5, 2); __PYX_ERR(0, 86, __pyx_L3_error)
3513 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
3515 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC_diffusiveVelocity", 1, 5, 5, 3); __PYX_ERR(0, 86, __pyx_L3_error)
3519 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_f)) != 0)) kw_args--;
3521 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC_diffusiveVelocity", 1, 5, 5, 4); __PYX_ERR(0, 86, __pyx_L3_error)
3524 if (unlikely(kw_args > 0)) {
3525 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"LinearAD_DiracIC_diffusiveVelocity") < 0)) __PYX_ERR(0, 86, __pyx_L3_error)
3527 }
else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
3528 goto __pyx_L5_argtuple_error;
3530 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
3531 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
3532 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
3533 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
3534 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
3536 __pyx_v_iwork = ((PyArrayObject *)values[0]);
3537 __pyx_v_rwork = ((PyArrayObject *)values[1]);
3538 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 86, __pyx_L3_error)
3539 __pyx_v_x = ((PyArrayObject *)values[3]);
3540 __pyx_v_f = ((PyArrayObject *)values[4]);
3542 goto __pyx_L4_argument_unpacking_done;
3543 __pyx_L5_argtuple_error:;
3544 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC_diffusiveVelocity", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 86, __pyx_L3_error)
3546 __Pyx_AddTraceback(
"canalyticalSolutions.LinearAD_DiracIC_diffusiveVelocity", __pyx_clineno, __pyx_lineno, __pyx_filename);
3547 __Pyx_RefNannyFinishContext();
3549 __pyx_L4_argument_unpacking_done:;
3550 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 86, __pyx_L1_error)
3551 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 86, __pyx_L1_error)
3552 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 86, __pyx_L1_error)
3553 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_f), __pyx_ptype_5numpy_ndarray, 1,
"f", 0))) __PYX_ERR(0, 86, __pyx_L1_error)
3554 __pyx_r = __pyx_pf_20canalyticalSolutions_18LinearAD_DiracIC_diffusiveVelocity(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_f);
3561 __Pyx_RefNannyFinishContext();
3565 static PyObject *__pyx_pf_20canalyticalSolutions_18LinearAD_DiracIC_diffusiveVelocity(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_f) {
3566 PyObject *__pyx_r = NULL;
3567 __Pyx_RefNannyDeclarations
3568 PyObject *__pyx_t_1 = NULL;
3569 PyObject *__pyx_t_2 = NULL;
3570 PyObject *__pyx_t_3 = NULL;
3572 int __pyx_lineno = 0;
3573 const char *__pyx_filename = NULL;
3574 int __pyx_clineno = 0;
3575 __Pyx_RefNannySetupContext(
"LinearAD_DiracIC_diffusiveVelocity", 0);
3584 __Pyx_XDECREF(__pyx_r);
3585 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 87, __pyx_L1_error)
3586 __Pyx_GOTREF(__pyx_t_1);
3587 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 87, __pyx_L1_error)
3588 __Pyx_GOTREF(__pyx_t_2);
3589 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 87, __pyx_L1_error)
3590 __Pyx_GOTREF(__pyx_t_3);
3591 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
3592 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
3593 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 87, __pyx_L1_error)
3594 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3595 __pyx_t_3 = __Pyx_PyInt_From_int(
LinearAD_DiracIC_diffusiveVelocity(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_f->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 87, __pyx_L1_error)
3596 __Pyx_GOTREF(__pyx_t_3);
3597 __pyx_r = __pyx_t_3;
3611 __Pyx_XDECREF(__pyx_t_1);
3612 __Pyx_XDECREF(__pyx_t_2);
3613 __Pyx_XDECREF(__pyx_t_3);
3614 __Pyx_AddTraceback(
"canalyticalSolutions.LinearAD_DiracIC_diffusiveVelocity", __pyx_clineno, __pyx_lineno, __pyx_filename);
3617 __Pyx_XGIVEREF(__pyx_r);
3618 __Pyx_RefNannyFinishContext();
3631 static PyObject *__pyx_pw_20canalyticalSolutions_21LinearAD_DiracIC_du(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
3632 static PyMethodDef __pyx_mdef_20canalyticalSolutions_21LinearAD_DiracIC_du = {
"LinearAD_DiracIC_du", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_21LinearAD_DiracIC_du, METH_VARARGS|METH_KEYWORDS, 0};
3633 static PyObject *__pyx_pw_20canalyticalSolutions_21LinearAD_DiracIC_du(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
3634 PyArrayObject *__pyx_v_iwork = 0;
3635 PyArrayObject *__pyx_v_rwork = 0;
3637 PyArrayObject *__pyx_v_x = 0;
3638 PyArrayObject *__pyx_v_du = 0;
3639 int __pyx_lineno = 0;
3640 const char *__pyx_filename = NULL;
3641 int __pyx_clineno = 0;
3642 PyObject *__pyx_r = 0;
3643 __Pyx_RefNannyDeclarations
3644 __Pyx_RefNannySetupContext(
"LinearAD_DiracIC_du (wrapper)", 0);
3646 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_du,0};
3647 PyObject* values[5] = {0,0,0,0,0};
3648 if (unlikely(__pyx_kwds)) {
3650 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
3652 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
3654 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
3656 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
3658 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
3660 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
3663 default:
goto __pyx_L5_argtuple_error;
3665 kw_args = PyDict_Size(__pyx_kwds);
3668 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
3669 else goto __pyx_L5_argtuple_error;
3672 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
3674 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC_du", 1, 5, 5, 1); __PYX_ERR(0, 90, __pyx_L3_error)
3678 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
3680 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC_du", 1, 5, 5, 2); __PYX_ERR(0, 90, __pyx_L3_error)
3684 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
3686 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC_du", 1, 5, 5, 3); __PYX_ERR(0, 90, __pyx_L3_error)
3690 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_du)) != 0)) kw_args--;
3692 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC_du", 1, 5, 5, 4); __PYX_ERR(0, 90, __pyx_L3_error)
3695 if (unlikely(kw_args > 0)) {
3696 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"LinearAD_DiracIC_du") < 0)) __PYX_ERR(0, 90, __pyx_L3_error)
3698 }
else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
3699 goto __pyx_L5_argtuple_error;
3701 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
3702 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
3703 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
3704 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
3705 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
3707 __pyx_v_iwork = ((PyArrayObject *)values[0]);
3708 __pyx_v_rwork = ((PyArrayObject *)values[1]);
3709 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 90, __pyx_L3_error)
3710 __pyx_v_x = ((PyArrayObject *)values[3]);
3711 __pyx_v_du = ((PyArrayObject *)values[4]);
3713 goto __pyx_L4_argument_unpacking_done;
3714 __pyx_L5_argtuple_error:;
3715 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC_du", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 90, __pyx_L3_error)
3717 __Pyx_AddTraceback(
"canalyticalSolutions.LinearAD_DiracIC_du", __pyx_clineno, __pyx_lineno, __pyx_filename);
3718 __Pyx_RefNannyFinishContext();
3720 __pyx_L4_argument_unpacking_done:;
3721 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 90, __pyx_L1_error)
3722 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 90, __pyx_L1_error)
3723 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 90, __pyx_L1_error)
3724 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_du), __pyx_ptype_5numpy_ndarray, 1,
"du", 0))) __PYX_ERR(0, 90, __pyx_L1_error)
3725 __pyx_r = __pyx_pf_20canalyticalSolutions_20LinearAD_DiracIC_du(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_du);
3732 __Pyx_RefNannyFinishContext();
3736 static PyObject *__pyx_pf_20canalyticalSolutions_20LinearAD_DiracIC_du(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_du) {
3737 PyObject *__pyx_r = NULL;
3738 __Pyx_RefNannyDeclarations
3739 PyObject *__pyx_t_1 = NULL;
3740 PyObject *__pyx_t_2 = NULL;
3741 PyObject *__pyx_t_3 = NULL;
3743 int __pyx_lineno = 0;
3744 const char *__pyx_filename = NULL;
3745 int __pyx_clineno = 0;
3746 __Pyx_RefNannySetupContext(
"LinearAD_DiracIC_du", 0);
3755 __Pyx_XDECREF(__pyx_r);
3756 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 91, __pyx_L1_error)
3757 __Pyx_GOTREF(__pyx_t_1);
3758 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 91, __pyx_L1_error)
3759 __Pyx_GOTREF(__pyx_t_2);
3760 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 91, __pyx_L1_error)
3761 __Pyx_GOTREF(__pyx_t_3);
3762 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
3763 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
3764 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 91, __pyx_L1_error)
3765 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3766 __pyx_t_3 = __Pyx_PyInt_From_int(
LinearAD_DiracIC_du(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_du->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 91, __pyx_L1_error)
3767 __Pyx_GOTREF(__pyx_t_3);
3768 __pyx_r = __pyx_t_3;
3782 __Pyx_XDECREF(__pyx_t_1);
3783 __Pyx_XDECREF(__pyx_t_2);
3784 __Pyx_XDECREF(__pyx_t_3);
3785 __Pyx_AddTraceback(
"canalyticalSolutions.LinearAD_DiracIC_du", __pyx_clineno, __pyx_lineno, __pyx_filename);
3788 __Pyx_XGIVEREF(__pyx_r);
3789 __Pyx_RefNannyFinishContext();
3802 static PyObject *__pyx_pw_20canalyticalSolutions_23LinearAD_DiracIC_totalVelocity(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
3803 static PyMethodDef __pyx_mdef_20canalyticalSolutions_23LinearAD_DiracIC_totalVelocity = {
"LinearAD_DiracIC_totalVelocity", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_23LinearAD_DiracIC_totalVelocity, METH_VARARGS|METH_KEYWORDS, 0};
3804 static PyObject *__pyx_pw_20canalyticalSolutions_23LinearAD_DiracIC_totalVelocity(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
3805 PyArrayObject *__pyx_v_iwork = 0;
3806 PyArrayObject *__pyx_v_rwork = 0;
3808 PyArrayObject *__pyx_v_x = 0;
3809 PyArrayObject *__pyx_v_u = 0;
3810 int __pyx_lineno = 0;
3811 const char *__pyx_filename = NULL;
3812 int __pyx_clineno = 0;
3813 PyObject *__pyx_r = 0;
3814 __Pyx_RefNannyDeclarations
3815 __Pyx_RefNannySetupContext(
"LinearAD_DiracIC_totalVelocity (wrapper)", 0);
3817 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_u,0};
3818 PyObject* values[5] = {0,0,0,0,0};
3819 if (unlikely(__pyx_kwds)) {
3821 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
3823 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
3825 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
3827 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
3829 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
3831 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
3834 default:
goto __pyx_L5_argtuple_error;
3836 kw_args = PyDict_Size(__pyx_kwds);
3839 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
3840 else goto __pyx_L5_argtuple_error;
3843 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
3845 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC_totalVelocity", 1, 5, 5, 1); __PYX_ERR(0, 94, __pyx_L3_error)
3849 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
3851 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC_totalVelocity", 1, 5, 5, 2); __PYX_ERR(0, 94, __pyx_L3_error)
3855 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
3857 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC_totalVelocity", 1, 5, 5, 3); __PYX_ERR(0, 94, __pyx_L3_error)
3861 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
3863 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC_totalVelocity", 1, 5, 5, 4); __PYX_ERR(0, 94, __pyx_L3_error)
3866 if (unlikely(kw_args > 0)) {
3867 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"LinearAD_DiracIC_totalVelocity") < 0)) __PYX_ERR(0, 94, __pyx_L3_error)
3869 }
else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
3870 goto __pyx_L5_argtuple_error;
3872 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
3873 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
3874 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
3875 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
3876 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
3878 __pyx_v_iwork = ((PyArrayObject *)values[0]);
3879 __pyx_v_rwork = ((PyArrayObject *)values[1]);
3880 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 94, __pyx_L3_error)
3881 __pyx_v_x = ((PyArrayObject *)values[3]);
3882 __pyx_v_u = ((PyArrayObject *)values[4]);
3884 goto __pyx_L4_argument_unpacking_done;
3885 __pyx_L5_argtuple_error:;
3886 __Pyx_RaiseArgtupleInvalid(
"LinearAD_DiracIC_totalVelocity", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 94, __pyx_L3_error)
3888 __Pyx_AddTraceback(
"canalyticalSolutions.LinearAD_DiracIC_totalVelocity", __pyx_clineno, __pyx_lineno, __pyx_filename);
3889 __Pyx_RefNannyFinishContext();
3891 __pyx_L4_argument_unpacking_done:;
3892 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 94, __pyx_L1_error)
3893 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 94, __pyx_L1_error)
3894 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 94, __pyx_L1_error)
3895 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1,
"u", 0))) __PYX_ERR(0, 94, __pyx_L1_error)
3896 __pyx_r = __pyx_pf_20canalyticalSolutions_22LinearAD_DiracIC_totalVelocity(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_u);
3903 __Pyx_RefNannyFinishContext();
3907 static PyObject *__pyx_pf_20canalyticalSolutions_22LinearAD_DiracIC_totalVelocity(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u) {
3908 PyObject *__pyx_r = NULL;
3909 __Pyx_RefNannyDeclarations
3910 PyObject *__pyx_t_1 = NULL;
3911 PyObject *__pyx_t_2 = NULL;
3912 PyObject *__pyx_t_3 = NULL;
3914 int __pyx_lineno = 0;
3915 const char *__pyx_filename = NULL;
3916 int __pyx_clineno = 0;
3917 __Pyx_RefNannySetupContext(
"LinearAD_DiracIC_totalVelocity", 0);
3926 __Pyx_XDECREF(__pyx_r);
3927 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 95, __pyx_L1_error)
3928 __Pyx_GOTREF(__pyx_t_1);
3929 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 95, __pyx_L1_error)
3930 __Pyx_GOTREF(__pyx_t_2);
3931 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 95, __pyx_L1_error)
3932 __Pyx_GOTREF(__pyx_t_3);
3933 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
3934 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
3935 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 95, __pyx_L1_error)
3936 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3937 __pyx_t_3 = __Pyx_PyInt_From_int(
LinearAD_DiracIC_totalVelocity(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_u->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 95, __pyx_L1_error)
3938 __Pyx_GOTREF(__pyx_t_3);
3939 __pyx_r = __pyx_t_3;
3953 __Pyx_XDECREF(__pyx_t_1);
3954 __Pyx_XDECREF(__pyx_t_2);
3955 __Pyx_XDECREF(__pyx_t_3);
3956 __Pyx_AddTraceback(
"canalyticalSolutions.LinearAD_DiracIC_totalVelocity", __pyx_clineno, __pyx_lineno, __pyx_filename);
3959 __Pyx_XGIVEREF(__pyx_r);
3960 __Pyx_RefNannyFinishContext();
3973 static PyObject *__pyx_pw_20canalyticalSolutions_25LinearAD_SteadyState(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
3974 static PyMethodDef __pyx_mdef_20canalyticalSolutions_25LinearAD_SteadyState = {
"LinearAD_SteadyState", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_25LinearAD_SteadyState, METH_VARARGS|METH_KEYWORDS, 0};
3975 static PyObject *__pyx_pw_20canalyticalSolutions_25LinearAD_SteadyState(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
3976 PyArrayObject *__pyx_v_iwork = 0;
3977 PyArrayObject *__pyx_v_rwork = 0;
3979 PyArrayObject *__pyx_v_x = 0;
3980 PyArrayObject *__pyx_v_u = 0;
3981 int __pyx_lineno = 0;
3982 const char *__pyx_filename = NULL;
3983 int __pyx_clineno = 0;
3984 PyObject *__pyx_r = 0;
3985 __Pyx_RefNannyDeclarations
3986 __Pyx_RefNannySetupContext(
"LinearAD_SteadyState (wrapper)", 0);
3988 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_u,0};
3989 PyObject* values[5] = {0,0,0,0,0};
3990 if (unlikely(__pyx_kwds)) {
3992 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
3994 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
3996 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
3998 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
4000 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
4002 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
4005 default:
goto __pyx_L5_argtuple_error;
4007 kw_args = PyDict_Size(__pyx_kwds);
4010 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
4011 else goto __pyx_L5_argtuple_error;
4014 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
4016 __Pyx_RaiseArgtupleInvalid(
"LinearAD_SteadyState", 1, 5, 5, 1); __PYX_ERR(0, 98, __pyx_L3_error)
4020 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
4022 __Pyx_RaiseArgtupleInvalid(
"LinearAD_SteadyState", 1, 5, 5, 2); __PYX_ERR(0, 98, __pyx_L3_error)
4026 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
4028 __Pyx_RaiseArgtupleInvalid(
"LinearAD_SteadyState", 1, 5, 5, 3); __PYX_ERR(0, 98, __pyx_L3_error)
4032 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
4034 __Pyx_RaiseArgtupleInvalid(
"LinearAD_SteadyState", 1, 5, 5, 4); __PYX_ERR(0, 98, __pyx_L3_error)
4037 if (unlikely(kw_args > 0)) {
4038 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"LinearAD_SteadyState") < 0)) __PYX_ERR(0, 98, __pyx_L3_error)
4040 }
else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
4041 goto __pyx_L5_argtuple_error;
4043 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
4044 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
4045 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
4046 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
4047 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
4049 __pyx_v_iwork = ((PyArrayObject *)values[0]);
4050 __pyx_v_rwork = ((PyArrayObject *)values[1]);
4051 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 98, __pyx_L3_error)
4052 __pyx_v_x = ((PyArrayObject *)values[3]);
4053 __pyx_v_u = ((PyArrayObject *)values[4]);
4055 goto __pyx_L4_argument_unpacking_done;
4056 __pyx_L5_argtuple_error:;
4057 __Pyx_RaiseArgtupleInvalid(
"LinearAD_SteadyState", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 98, __pyx_L3_error)
4059 __Pyx_AddTraceback(
"canalyticalSolutions.LinearAD_SteadyState", __pyx_clineno, __pyx_lineno, __pyx_filename);
4060 __Pyx_RefNannyFinishContext();
4062 __pyx_L4_argument_unpacking_done:;
4063 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 98, __pyx_L1_error)
4064 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 98, __pyx_L1_error)
4065 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 98, __pyx_L1_error)
4066 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1,
"u", 0))) __PYX_ERR(0, 98, __pyx_L1_error)
4067 __pyx_r = __pyx_pf_20canalyticalSolutions_24LinearAD_SteadyState(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_u);
4074 __Pyx_RefNannyFinishContext();
4078 static PyObject *__pyx_pf_20canalyticalSolutions_24LinearAD_SteadyState(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u) {
4079 PyObject *__pyx_r = NULL;
4080 __Pyx_RefNannyDeclarations
4081 PyObject *__pyx_t_1 = NULL;
4082 PyObject *__pyx_t_2 = NULL;
4083 PyObject *__pyx_t_3 = NULL;
4085 int __pyx_lineno = 0;
4086 const char *__pyx_filename = NULL;
4087 int __pyx_clineno = 0;
4088 __Pyx_RefNannySetupContext(
"LinearAD_SteadyState", 0);
4097 __Pyx_XDECREF(__pyx_r);
4098 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 99, __pyx_L1_error)
4099 __Pyx_GOTREF(__pyx_t_1);
4100 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 99, __pyx_L1_error)
4101 __Pyx_GOTREF(__pyx_t_2);
4102 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 99, __pyx_L1_error)
4103 __Pyx_GOTREF(__pyx_t_3);
4104 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
4105 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
4106 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 99, __pyx_L1_error)
4107 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4108 __pyx_t_3 = __Pyx_PyInt_From_int(
LinearAD_SteadyState(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_u->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 99, __pyx_L1_error)
4109 __Pyx_GOTREF(__pyx_t_3);
4110 __pyx_r = __pyx_t_3;
4124 __Pyx_XDECREF(__pyx_t_1);
4125 __Pyx_XDECREF(__pyx_t_2);
4126 __Pyx_XDECREF(__pyx_t_3);
4127 __Pyx_AddTraceback(
"canalyticalSolutions.LinearAD_SteadyState", __pyx_clineno, __pyx_lineno, __pyx_filename);
4130 __Pyx_XGIVEREF(__pyx_r);
4131 __Pyx_RefNannyFinishContext();
4144 static PyObject *__pyx_pw_20canalyticalSolutions_27LinearADR_Decay_DiracIC(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
4145 static PyMethodDef __pyx_mdef_20canalyticalSolutions_27LinearADR_Decay_DiracIC = {
"LinearADR_Decay_DiracIC", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_27LinearADR_Decay_DiracIC, METH_VARARGS|METH_KEYWORDS, 0};
4146 static PyObject *__pyx_pw_20canalyticalSolutions_27LinearADR_Decay_DiracIC(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
4147 PyArrayObject *__pyx_v_iwork = 0;
4148 PyArrayObject *__pyx_v_rwork = 0;
4150 PyArrayObject *__pyx_v_x = 0;
4151 PyArrayObject *__pyx_v_u = 0;
4152 int __pyx_lineno = 0;
4153 const char *__pyx_filename = NULL;
4154 int __pyx_clineno = 0;
4155 PyObject *__pyx_r = 0;
4156 __Pyx_RefNannyDeclarations
4157 __Pyx_RefNannySetupContext(
"LinearADR_Decay_DiracIC (wrapper)", 0);
4159 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_u,0};
4160 PyObject* values[5] = {0,0,0,0,0};
4161 if (unlikely(__pyx_kwds)) {
4163 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
4165 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
4167 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
4169 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
4171 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
4173 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
4176 default:
goto __pyx_L5_argtuple_error;
4178 kw_args = PyDict_Size(__pyx_kwds);
4181 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
4182 else goto __pyx_L5_argtuple_error;
4185 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
4187 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Decay_DiracIC", 1, 5, 5, 1); __PYX_ERR(0, 102, __pyx_L3_error)
4191 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
4193 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Decay_DiracIC", 1, 5, 5, 2); __PYX_ERR(0, 102, __pyx_L3_error)
4197 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
4199 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Decay_DiracIC", 1, 5, 5, 3); __PYX_ERR(0, 102, __pyx_L3_error)
4203 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
4205 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Decay_DiracIC", 1, 5, 5, 4); __PYX_ERR(0, 102, __pyx_L3_error)
4208 if (unlikely(kw_args > 0)) {
4209 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"LinearADR_Decay_DiracIC") < 0)) __PYX_ERR(0, 102, __pyx_L3_error)
4211 }
else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
4212 goto __pyx_L5_argtuple_error;
4214 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
4215 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
4216 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
4217 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
4218 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
4220 __pyx_v_iwork = ((PyArrayObject *)values[0]);
4221 __pyx_v_rwork = ((PyArrayObject *)values[1]);
4222 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 102, __pyx_L3_error)
4223 __pyx_v_x = ((PyArrayObject *)values[3]);
4224 __pyx_v_u = ((PyArrayObject *)values[4]);
4226 goto __pyx_L4_argument_unpacking_done;
4227 __pyx_L5_argtuple_error:;
4228 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Decay_DiracIC", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 102, __pyx_L3_error)
4230 __Pyx_AddTraceback(
"canalyticalSolutions.LinearADR_Decay_DiracIC", __pyx_clineno, __pyx_lineno, __pyx_filename);
4231 __Pyx_RefNannyFinishContext();
4233 __pyx_L4_argument_unpacking_done:;
4234 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 102, __pyx_L1_error)
4235 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 102, __pyx_L1_error)
4236 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 102, __pyx_L1_error)
4237 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1,
"u", 0))) __PYX_ERR(0, 102, __pyx_L1_error)
4238 __pyx_r = __pyx_pf_20canalyticalSolutions_26LinearADR_Decay_DiracIC(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_u);
4245 __Pyx_RefNannyFinishContext();
4249 static PyObject *__pyx_pf_20canalyticalSolutions_26LinearADR_Decay_DiracIC(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u) {
4250 PyObject *__pyx_r = NULL;
4251 __Pyx_RefNannyDeclarations
4252 PyObject *__pyx_t_1 = NULL;
4253 PyObject *__pyx_t_2 = NULL;
4254 PyObject *__pyx_t_3 = NULL;
4256 int __pyx_lineno = 0;
4257 const char *__pyx_filename = NULL;
4258 int __pyx_clineno = 0;
4259 __Pyx_RefNannySetupContext(
"LinearADR_Decay_DiracIC", 0);
4268 __Pyx_XDECREF(__pyx_r);
4269 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 103, __pyx_L1_error)
4270 __Pyx_GOTREF(__pyx_t_1);
4271 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 103, __pyx_L1_error)
4272 __Pyx_GOTREF(__pyx_t_2);
4273 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 103, __pyx_L1_error)
4274 __Pyx_GOTREF(__pyx_t_3);
4275 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
4276 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
4277 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 103, __pyx_L1_error)
4278 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4279 __pyx_t_3 = __Pyx_PyInt_From_int(
LinearADR_Decay_DiracIC(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_u->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 103, __pyx_L1_error)
4280 __Pyx_GOTREF(__pyx_t_3);
4281 __pyx_r = __pyx_t_3;
4295 __Pyx_XDECREF(__pyx_t_1);
4296 __Pyx_XDECREF(__pyx_t_2);
4297 __Pyx_XDECREF(__pyx_t_3);
4298 __Pyx_AddTraceback(
"canalyticalSolutions.LinearADR_Decay_DiracIC", __pyx_clineno, __pyx_lineno, __pyx_filename);
4301 __Pyx_XGIVEREF(__pyx_r);
4302 __Pyx_RefNannyFinishContext();
4315 static PyObject *__pyx_pw_20canalyticalSolutions_29LinearADR_Decay_DiracIC_dr(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
4316 static PyMethodDef __pyx_mdef_20canalyticalSolutions_29LinearADR_Decay_DiracIC_dr = {
"LinearADR_Decay_DiracIC_dr", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_29LinearADR_Decay_DiracIC_dr, METH_VARARGS|METH_KEYWORDS, 0};
4317 static PyObject *__pyx_pw_20canalyticalSolutions_29LinearADR_Decay_DiracIC_dr(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
4318 PyArrayObject *__pyx_v_iwork = 0;
4319 PyArrayObject *__pyx_v_rwork = 0;
4321 PyArrayObject *__pyx_v_x = 0;
4322 PyArrayObject *__pyx_v_u = 0;
4323 PyArrayObject *__pyx_v_dr = 0;
4324 int __pyx_lineno = 0;
4325 const char *__pyx_filename = NULL;
4326 int __pyx_clineno = 0;
4327 PyObject *__pyx_r = 0;
4328 __Pyx_RefNannyDeclarations
4329 __Pyx_RefNannySetupContext(
"LinearADR_Decay_DiracIC_dr (wrapper)", 0);
4331 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_u,&__pyx_n_s_dr,0};
4332 PyObject* values[6] = {0,0,0,0,0,0};
4333 if (unlikely(__pyx_kwds)) {
4335 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
4337 case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
4339 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
4341 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
4343 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
4345 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
4347 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
4350 default:
goto __pyx_L5_argtuple_error;
4352 kw_args = PyDict_Size(__pyx_kwds);
4355 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
4356 else goto __pyx_L5_argtuple_error;
4359 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
4361 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Decay_DiracIC_dr", 1, 6, 6, 1); __PYX_ERR(0, 106, __pyx_L3_error)
4365 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
4367 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Decay_DiracIC_dr", 1, 6, 6, 2); __PYX_ERR(0, 106, __pyx_L3_error)
4371 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
4373 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Decay_DiracIC_dr", 1, 6, 6, 3); __PYX_ERR(0, 106, __pyx_L3_error)
4377 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
4379 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Decay_DiracIC_dr", 1, 6, 6, 4); __PYX_ERR(0, 106, __pyx_L3_error)
4383 if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_dr)) != 0)) kw_args--;
4385 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Decay_DiracIC_dr", 1, 6, 6, 5); __PYX_ERR(0, 106, __pyx_L3_error)
4388 if (unlikely(kw_args > 0)) {
4389 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"LinearADR_Decay_DiracIC_dr") < 0)) __PYX_ERR(0, 106, __pyx_L3_error)
4391 }
else if (PyTuple_GET_SIZE(__pyx_args) != 6) {
4392 goto __pyx_L5_argtuple_error;
4394 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
4395 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
4396 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
4397 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
4398 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
4399 values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
4401 __pyx_v_iwork = ((PyArrayObject *)values[0]);
4402 __pyx_v_rwork = ((PyArrayObject *)values[1]);
4403 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 106, __pyx_L3_error)
4404 __pyx_v_x = ((PyArrayObject *)values[3]);
4405 __pyx_v_u = ((PyArrayObject *)values[4]);
4406 __pyx_v_dr = ((PyArrayObject *)values[5]);
4408 goto __pyx_L4_argument_unpacking_done;
4409 __pyx_L5_argtuple_error:;
4410 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Decay_DiracIC_dr", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 106, __pyx_L3_error)
4412 __Pyx_AddTraceback(
"canalyticalSolutions.LinearADR_Decay_DiracIC_dr", __pyx_clineno, __pyx_lineno, __pyx_filename);
4413 __Pyx_RefNannyFinishContext();
4415 __pyx_L4_argument_unpacking_done:;
4416 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 106, __pyx_L1_error)
4417 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 106, __pyx_L1_error)
4418 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 106, __pyx_L1_error)
4419 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1,
"u", 0))) __PYX_ERR(0, 106, __pyx_L1_error)
4420 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dr), __pyx_ptype_5numpy_ndarray, 1,
"dr", 0))) __PYX_ERR(0, 106, __pyx_L1_error)
4421 __pyx_r = __pyx_pf_20canalyticalSolutions_28LinearADR_Decay_DiracIC_dr(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_u, __pyx_v_dr);
4428 __Pyx_RefNannyFinishContext();
4432 static PyObject *__pyx_pf_20canalyticalSolutions_28LinearADR_Decay_DiracIC_dr(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_dr) {
4433 PyObject *__pyx_r = NULL;
4434 __Pyx_RefNannyDeclarations
4435 PyObject *__pyx_t_1 = NULL;
4436 PyObject *__pyx_t_2 = NULL;
4437 PyObject *__pyx_t_3 = NULL;
4439 int __pyx_lineno = 0;
4440 const char *__pyx_filename = NULL;
4441 int __pyx_clineno = 0;
4442 __Pyx_RefNannySetupContext(
"LinearADR_Decay_DiracIC_dr", 0);
4451 __Pyx_XDECREF(__pyx_r);
4452 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 107, __pyx_L1_error)
4453 __Pyx_GOTREF(__pyx_t_1);
4454 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 107, __pyx_L1_error)
4455 __Pyx_GOTREF(__pyx_t_2);
4456 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 107, __pyx_L1_error)
4457 __Pyx_GOTREF(__pyx_t_3);
4458 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
4459 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
4460 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 107, __pyx_L1_error)
4461 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4462 __pyx_t_3 = __Pyx_PyInt_From_int(
LinearADR_Decay_DiracIC_dr(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_u->data), ((
double *)__pyx_v_dr->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 107, __pyx_L1_error)
4463 __Pyx_GOTREF(__pyx_t_3);
4464 __pyx_r = __pyx_t_3;
4478 __Pyx_XDECREF(__pyx_t_1);
4479 __Pyx_XDECREF(__pyx_t_2);
4480 __Pyx_XDECREF(__pyx_t_3);
4481 __Pyx_AddTraceback(
"canalyticalSolutions.LinearADR_Decay_DiracIC_dr", __pyx_clineno, __pyx_lineno, __pyx_filename);
4484 __Pyx_XGIVEREF(__pyx_r);
4485 __Pyx_RefNannyFinishContext();
4498 static PyObject *__pyx_pw_20canalyticalSolutions_31LinearADR_Decay_DiracIC_r(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
4499 static PyMethodDef __pyx_mdef_20canalyticalSolutions_31LinearADR_Decay_DiracIC_r = {
"LinearADR_Decay_DiracIC_r", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_31LinearADR_Decay_DiracIC_r, METH_VARARGS|METH_KEYWORDS, 0};
4500 static PyObject *__pyx_pw_20canalyticalSolutions_31LinearADR_Decay_DiracIC_r(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
4501 PyArrayObject *__pyx_v_iwork = 0;
4502 PyArrayObject *__pyx_v_rwork = 0;
4504 PyArrayObject *__pyx_v_x = 0;
4505 PyArrayObject *__pyx_v_u = 0;
4506 PyArrayObject *__pyx_v_r = 0;
4507 int __pyx_lineno = 0;
4508 const char *__pyx_filename = NULL;
4509 int __pyx_clineno = 0;
4510 PyObject *__pyx_r = 0;
4511 __Pyx_RefNannyDeclarations
4512 __Pyx_RefNannySetupContext(
"LinearADR_Decay_DiracIC_r (wrapper)", 0);
4514 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_u,&__pyx_n_s_r,0};
4515 PyObject* values[6] = {0,0,0,0,0,0};
4516 if (unlikely(__pyx_kwds)) {
4518 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
4520 case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
4522 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
4524 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
4526 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
4528 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
4530 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
4533 default:
goto __pyx_L5_argtuple_error;
4535 kw_args = PyDict_Size(__pyx_kwds);
4538 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
4539 else goto __pyx_L5_argtuple_error;
4542 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
4544 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Decay_DiracIC_r", 1, 6, 6, 1); __PYX_ERR(0, 110, __pyx_L3_error)
4548 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
4550 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Decay_DiracIC_r", 1, 6, 6, 2); __PYX_ERR(0, 110, __pyx_L3_error)
4554 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
4556 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Decay_DiracIC_r", 1, 6, 6, 3); __PYX_ERR(0, 110, __pyx_L3_error)
4560 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
4562 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Decay_DiracIC_r", 1, 6, 6, 4); __PYX_ERR(0, 110, __pyx_L3_error)
4566 if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_r)) != 0)) kw_args--;
4568 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Decay_DiracIC_r", 1, 6, 6, 5); __PYX_ERR(0, 110, __pyx_L3_error)
4571 if (unlikely(kw_args > 0)) {
4572 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"LinearADR_Decay_DiracIC_r") < 0)) __PYX_ERR(0, 110, __pyx_L3_error)
4574 }
else if (PyTuple_GET_SIZE(__pyx_args) != 6) {
4575 goto __pyx_L5_argtuple_error;
4577 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
4578 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
4579 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
4580 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
4581 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
4582 values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
4584 __pyx_v_iwork = ((PyArrayObject *)values[0]);
4585 __pyx_v_rwork = ((PyArrayObject *)values[1]);
4586 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 110, __pyx_L3_error)
4587 __pyx_v_x = ((PyArrayObject *)values[3]);
4588 __pyx_v_u = ((PyArrayObject *)values[4]);
4589 __pyx_v_r = ((PyArrayObject *)values[5]);
4591 goto __pyx_L4_argument_unpacking_done;
4592 __pyx_L5_argtuple_error:;
4593 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Decay_DiracIC_r", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 110, __pyx_L3_error)
4595 __Pyx_AddTraceback(
"canalyticalSolutions.LinearADR_Decay_DiracIC_r", __pyx_clineno, __pyx_lineno, __pyx_filename);
4596 __Pyx_RefNannyFinishContext();
4598 __pyx_L4_argument_unpacking_done:;
4599 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 110, __pyx_L1_error)
4600 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 110, __pyx_L1_error)
4601 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 110, __pyx_L1_error)
4602 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1,
"u", 0))) __PYX_ERR(0, 110, __pyx_L1_error)
4603 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_r), __pyx_ptype_5numpy_ndarray, 1,
"r", 0))) __PYX_ERR(0, 110, __pyx_L1_error)
4604 __pyx_r = __pyx_pf_20canalyticalSolutions_30LinearADR_Decay_DiracIC_r(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_u, __pyx_v_r);
4611 __Pyx_RefNannyFinishContext();
4615 static PyObject *__pyx_pf_20canalyticalSolutions_30LinearADR_Decay_DiracIC_r(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_r) {
4616 PyObject *__pyx_r = NULL;
4617 __Pyx_RefNannyDeclarations
4618 PyObject *__pyx_t_1 = NULL;
4619 PyObject *__pyx_t_2 = NULL;
4620 PyObject *__pyx_t_3 = NULL;
4622 int __pyx_lineno = 0;
4623 const char *__pyx_filename = NULL;
4624 int __pyx_clineno = 0;
4625 __Pyx_RefNannySetupContext(
"LinearADR_Decay_DiracIC_r", 0);
4634 __Pyx_XDECREF(__pyx_r);
4635 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 111, __pyx_L1_error)
4636 __Pyx_GOTREF(__pyx_t_1);
4637 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 111, __pyx_L1_error)
4638 __Pyx_GOTREF(__pyx_t_2);
4639 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 111, __pyx_L1_error)
4640 __Pyx_GOTREF(__pyx_t_3);
4641 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
4642 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
4643 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 111, __pyx_L1_error)
4644 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4645 __pyx_t_3 = __Pyx_PyInt_From_int(
LinearADR_Decay_DiracIC_r(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_u->data), ((
double *)__pyx_v_r->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 111, __pyx_L1_error)
4646 __Pyx_GOTREF(__pyx_t_3);
4647 __pyx_r = __pyx_t_3;
4661 __Pyx_XDECREF(__pyx_t_1);
4662 __Pyx_XDECREF(__pyx_t_2);
4663 __Pyx_XDECREF(__pyx_t_3);
4664 __Pyx_AddTraceback(
"canalyticalSolutions.LinearADR_Decay_DiracIC_r", __pyx_clineno, __pyx_lineno, __pyx_filename);
4667 __Pyx_XGIVEREF(__pyx_r);
4668 __Pyx_RefNannyFinishContext();
4681 static PyObject *__pyx_pw_20canalyticalSolutions_33LinearADR_Sine(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
4682 static PyMethodDef __pyx_mdef_20canalyticalSolutions_33LinearADR_Sine = {
"LinearADR_Sine", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_33LinearADR_Sine, METH_VARARGS|METH_KEYWORDS, 0};
4683 static PyObject *__pyx_pw_20canalyticalSolutions_33LinearADR_Sine(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
4684 PyArrayObject *__pyx_v_iwork = 0;
4685 PyArrayObject *__pyx_v_rwork = 0;
4687 PyArrayObject *__pyx_v_x = 0;
4688 PyArrayObject *__pyx_v_u = 0;
4689 int __pyx_lineno = 0;
4690 const char *__pyx_filename = NULL;
4691 int __pyx_clineno = 0;
4692 PyObject *__pyx_r = 0;
4693 __Pyx_RefNannyDeclarations
4694 __Pyx_RefNannySetupContext(
"LinearADR_Sine (wrapper)", 0);
4696 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_u,0};
4697 PyObject* values[5] = {0,0,0,0,0};
4698 if (unlikely(__pyx_kwds)) {
4700 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
4702 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
4704 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
4706 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
4708 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
4710 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
4713 default:
goto __pyx_L5_argtuple_error;
4715 kw_args = PyDict_Size(__pyx_kwds);
4718 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
4719 else goto __pyx_L5_argtuple_error;
4722 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
4724 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine", 1, 5, 5, 1); __PYX_ERR(0, 114, __pyx_L3_error)
4728 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
4730 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine", 1, 5, 5, 2); __PYX_ERR(0, 114, __pyx_L3_error)
4734 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
4736 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine", 1, 5, 5, 3); __PYX_ERR(0, 114, __pyx_L3_error)
4740 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
4742 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine", 1, 5, 5, 4); __PYX_ERR(0, 114, __pyx_L3_error)
4745 if (unlikely(kw_args > 0)) {
4746 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"LinearADR_Sine") < 0)) __PYX_ERR(0, 114, __pyx_L3_error)
4748 }
else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
4749 goto __pyx_L5_argtuple_error;
4751 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
4752 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
4753 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
4754 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
4755 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
4757 __pyx_v_iwork = ((PyArrayObject *)values[0]);
4758 __pyx_v_rwork = ((PyArrayObject *)values[1]);
4759 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 114, __pyx_L3_error)
4760 __pyx_v_x = ((PyArrayObject *)values[3]);
4761 __pyx_v_u = ((PyArrayObject *)values[4]);
4763 goto __pyx_L4_argument_unpacking_done;
4764 __pyx_L5_argtuple_error:;
4765 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 114, __pyx_L3_error)
4767 __Pyx_AddTraceback(
"canalyticalSolutions.LinearADR_Sine", __pyx_clineno, __pyx_lineno, __pyx_filename);
4768 __Pyx_RefNannyFinishContext();
4770 __pyx_L4_argument_unpacking_done:;
4771 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 114, __pyx_L1_error)
4772 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 114, __pyx_L1_error)
4773 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 114, __pyx_L1_error)
4774 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1,
"u", 0))) __PYX_ERR(0, 114, __pyx_L1_error)
4775 __pyx_r = __pyx_pf_20canalyticalSolutions_32LinearADR_Sine(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_u);
4782 __Pyx_RefNannyFinishContext();
4786 static PyObject *__pyx_pf_20canalyticalSolutions_32LinearADR_Sine(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u) {
4787 PyObject *__pyx_r = NULL;
4788 __Pyx_RefNannyDeclarations
4789 PyObject *__pyx_t_1 = NULL;
4790 PyObject *__pyx_t_2 = NULL;
4791 PyObject *__pyx_t_3 = NULL;
4793 int __pyx_lineno = 0;
4794 const char *__pyx_filename = NULL;
4795 int __pyx_clineno = 0;
4796 __Pyx_RefNannySetupContext(
"LinearADR_Sine", 0);
4805 __Pyx_XDECREF(__pyx_r);
4806 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 115, __pyx_L1_error)
4807 __Pyx_GOTREF(__pyx_t_1);
4808 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 115, __pyx_L1_error)
4809 __Pyx_GOTREF(__pyx_t_2);
4810 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 115, __pyx_L1_error)
4811 __Pyx_GOTREF(__pyx_t_3);
4812 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
4813 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
4814 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 115, __pyx_L1_error)
4815 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4816 __pyx_t_3 = __Pyx_PyInt_From_int(
LinearADR_Sine(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_u->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 115, __pyx_L1_error)
4817 __Pyx_GOTREF(__pyx_t_3);
4818 __pyx_r = __pyx_t_3;
4832 __Pyx_XDECREF(__pyx_t_1);
4833 __Pyx_XDECREF(__pyx_t_2);
4834 __Pyx_XDECREF(__pyx_t_3);
4835 __Pyx_AddTraceback(
"canalyticalSolutions.LinearADR_Sine", __pyx_clineno, __pyx_lineno, __pyx_filename);
4838 __Pyx_XGIVEREF(__pyx_r);
4839 __Pyx_RefNannyFinishContext();
4852 static PyObject *__pyx_pw_20canalyticalSolutions_35LinearADR_Sine_advectiveVelocity(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
4853 static PyMethodDef __pyx_mdef_20canalyticalSolutions_35LinearADR_Sine_advectiveVelocity = {
"LinearADR_Sine_advectiveVelocity", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_35LinearADR_Sine_advectiveVelocity, METH_VARARGS|METH_KEYWORDS, 0};
4854 static PyObject *__pyx_pw_20canalyticalSolutions_35LinearADR_Sine_advectiveVelocity(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
4855 PyArrayObject *__pyx_v_iwork = 0;
4856 PyArrayObject *__pyx_v_rwork = 0;
4858 PyArrayObject *__pyx_v_x = 0;
4859 PyArrayObject *__pyx_v_f = 0;
4860 int __pyx_lineno = 0;
4861 const char *__pyx_filename = NULL;
4862 int __pyx_clineno = 0;
4863 PyObject *__pyx_r = 0;
4864 __Pyx_RefNannyDeclarations
4865 __Pyx_RefNannySetupContext(
"LinearADR_Sine_advectiveVelocity (wrapper)", 0);
4867 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_f,0};
4868 PyObject* values[5] = {0,0,0,0,0};
4869 if (unlikely(__pyx_kwds)) {
4871 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
4873 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
4875 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
4877 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
4879 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
4881 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
4884 default:
goto __pyx_L5_argtuple_error;
4886 kw_args = PyDict_Size(__pyx_kwds);
4889 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
4890 else goto __pyx_L5_argtuple_error;
4893 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
4895 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_advectiveVelocity", 1, 5, 5, 1); __PYX_ERR(0, 118, __pyx_L3_error)
4899 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
4901 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_advectiveVelocity", 1, 5, 5, 2); __PYX_ERR(0, 118, __pyx_L3_error)
4905 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
4907 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_advectiveVelocity", 1, 5, 5, 3); __PYX_ERR(0, 118, __pyx_L3_error)
4911 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_f)) != 0)) kw_args--;
4913 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_advectiveVelocity", 1, 5, 5, 4); __PYX_ERR(0, 118, __pyx_L3_error)
4916 if (unlikely(kw_args > 0)) {
4917 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"LinearADR_Sine_advectiveVelocity") < 0)) __PYX_ERR(0, 118, __pyx_L3_error)
4919 }
else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
4920 goto __pyx_L5_argtuple_error;
4922 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
4923 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
4924 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
4925 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
4926 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
4928 __pyx_v_iwork = ((PyArrayObject *)values[0]);
4929 __pyx_v_rwork = ((PyArrayObject *)values[1]);
4930 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 118, __pyx_L3_error)
4931 __pyx_v_x = ((PyArrayObject *)values[3]);
4932 __pyx_v_f = ((PyArrayObject *)values[4]);
4934 goto __pyx_L4_argument_unpacking_done;
4935 __pyx_L5_argtuple_error:;
4936 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_advectiveVelocity", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 118, __pyx_L3_error)
4938 __Pyx_AddTraceback(
"canalyticalSolutions.LinearADR_Sine_advectiveVelocity", __pyx_clineno, __pyx_lineno, __pyx_filename);
4939 __Pyx_RefNannyFinishContext();
4941 __pyx_L4_argument_unpacking_done:;
4942 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 118, __pyx_L1_error)
4943 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 118, __pyx_L1_error)
4944 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 118, __pyx_L1_error)
4945 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_f), __pyx_ptype_5numpy_ndarray, 1,
"f", 0))) __PYX_ERR(0, 118, __pyx_L1_error)
4946 __pyx_r = __pyx_pf_20canalyticalSolutions_34LinearADR_Sine_advectiveVelocity(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_f);
4953 __Pyx_RefNannyFinishContext();
4957 static PyObject *__pyx_pf_20canalyticalSolutions_34LinearADR_Sine_advectiveVelocity(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_f) {
4958 PyObject *__pyx_r = NULL;
4959 __Pyx_RefNannyDeclarations
4960 PyObject *__pyx_t_1 = NULL;
4961 PyObject *__pyx_t_2 = NULL;
4962 PyObject *__pyx_t_3 = NULL;
4964 int __pyx_lineno = 0;
4965 const char *__pyx_filename = NULL;
4966 int __pyx_clineno = 0;
4967 __Pyx_RefNannySetupContext(
"LinearADR_Sine_advectiveVelocity", 0);
4976 __Pyx_XDECREF(__pyx_r);
4977 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 119, __pyx_L1_error)
4978 __Pyx_GOTREF(__pyx_t_1);
4979 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 119, __pyx_L1_error)
4980 __Pyx_GOTREF(__pyx_t_2);
4981 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 119, __pyx_L1_error)
4982 __Pyx_GOTREF(__pyx_t_3);
4983 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
4984 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
4985 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 119, __pyx_L1_error)
4986 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4987 __pyx_t_3 = __Pyx_PyInt_From_int(
LinearADR_Sine_advectiveVelocity(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_f->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 119, __pyx_L1_error)
4988 __Pyx_GOTREF(__pyx_t_3);
4989 __pyx_r = __pyx_t_3;
5003 __Pyx_XDECREF(__pyx_t_1);
5004 __Pyx_XDECREF(__pyx_t_2);
5005 __Pyx_XDECREF(__pyx_t_3);
5006 __Pyx_AddTraceback(
"canalyticalSolutions.LinearADR_Sine_advectiveVelocity", __pyx_clineno, __pyx_lineno, __pyx_filename);
5009 __Pyx_XGIVEREF(__pyx_r);
5010 __Pyx_RefNannyFinishContext();
5023 static PyObject *__pyx_pw_20canalyticalSolutions_37LinearADR_Sine_diffusiveVelocity(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
5024 static PyMethodDef __pyx_mdef_20canalyticalSolutions_37LinearADR_Sine_diffusiveVelocity = {
"LinearADR_Sine_diffusiveVelocity", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_37LinearADR_Sine_diffusiveVelocity, METH_VARARGS|METH_KEYWORDS, 0};
5025 static PyObject *__pyx_pw_20canalyticalSolutions_37LinearADR_Sine_diffusiveVelocity(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
5026 PyArrayObject *__pyx_v_iwork = 0;
5027 PyArrayObject *__pyx_v_rwork = 0;
5029 PyArrayObject *__pyx_v_x = 0;
5030 PyArrayObject *__pyx_v_f = 0;
5031 int __pyx_lineno = 0;
5032 const char *__pyx_filename = NULL;
5033 int __pyx_clineno = 0;
5034 PyObject *__pyx_r = 0;
5035 __Pyx_RefNannyDeclarations
5036 __Pyx_RefNannySetupContext(
"LinearADR_Sine_diffusiveVelocity (wrapper)", 0);
5038 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_f,0};
5039 PyObject* values[5] = {0,0,0,0,0};
5040 if (unlikely(__pyx_kwds)) {
5042 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
5044 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
5046 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
5048 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
5050 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5052 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5055 default:
goto __pyx_L5_argtuple_error;
5057 kw_args = PyDict_Size(__pyx_kwds);
5060 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
5061 else goto __pyx_L5_argtuple_error;
5064 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
5066 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_diffusiveVelocity", 1, 5, 5, 1); __PYX_ERR(0, 122, __pyx_L3_error)
5070 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
5072 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_diffusiveVelocity", 1, 5, 5, 2); __PYX_ERR(0, 122, __pyx_L3_error)
5076 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
5078 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_diffusiveVelocity", 1, 5, 5, 3); __PYX_ERR(0, 122, __pyx_L3_error)
5082 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_f)) != 0)) kw_args--;
5084 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_diffusiveVelocity", 1, 5, 5, 4); __PYX_ERR(0, 122, __pyx_L3_error)
5087 if (unlikely(kw_args > 0)) {
5088 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"LinearADR_Sine_diffusiveVelocity") < 0)) __PYX_ERR(0, 122, __pyx_L3_error)
5090 }
else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
5091 goto __pyx_L5_argtuple_error;
5093 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5094 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5095 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
5096 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
5097 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
5099 __pyx_v_iwork = ((PyArrayObject *)values[0]);
5100 __pyx_v_rwork = ((PyArrayObject *)values[1]);
5101 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 122, __pyx_L3_error)
5102 __pyx_v_x = ((PyArrayObject *)values[3]);
5103 __pyx_v_f = ((PyArrayObject *)values[4]);
5105 goto __pyx_L4_argument_unpacking_done;
5106 __pyx_L5_argtuple_error:;
5107 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_diffusiveVelocity", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 122, __pyx_L3_error)
5109 __Pyx_AddTraceback(
"canalyticalSolutions.LinearADR_Sine_diffusiveVelocity", __pyx_clineno, __pyx_lineno, __pyx_filename);
5110 __Pyx_RefNannyFinishContext();
5112 __pyx_L4_argument_unpacking_done:;
5113 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 122, __pyx_L1_error)
5114 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 122, __pyx_L1_error)
5115 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 122, __pyx_L1_error)
5116 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_f), __pyx_ptype_5numpy_ndarray, 1,
"f", 0))) __PYX_ERR(0, 122, __pyx_L1_error)
5117 __pyx_r = __pyx_pf_20canalyticalSolutions_36LinearADR_Sine_diffusiveVelocity(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_f);
5124 __Pyx_RefNannyFinishContext();
5128 static PyObject *__pyx_pf_20canalyticalSolutions_36LinearADR_Sine_diffusiveVelocity(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_f) {
5129 PyObject *__pyx_r = NULL;
5130 __Pyx_RefNannyDeclarations
5131 PyObject *__pyx_t_1 = NULL;
5132 PyObject *__pyx_t_2 = NULL;
5133 PyObject *__pyx_t_3 = NULL;
5135 int __pyx_lineno = 0;
5136 const char *__pyx_filename = NULL;
5137 int __pyx_clineno = 0;
5138 __Pyx_RefNannySetupContext(
"LinearADR_Sine_diffusiveVelocity", 0);
5147 __Pyx_XDECREF(__pyx_r);
5148 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 123, __pyx_L1_error)
5149 __Pyx_GOTREF(__pyx_t_1);
5150 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 123, __pyx_L1_error)
5151 __Pyx_GOTREF(__pyx_t_2);
5152 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 123, __pyx_L1_error)
5153 __Pyx_GOTREF(__pyx_t_3);
5154 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
5155 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
5156 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 123, __pyx_L1_error)
5157 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
5158 __pyx_t_3 = __Pyx_PyInt_From_int(
LinearADR_Sine_diffusiveVelocity(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_f->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 123, __pyx_L1_error)
5159 __Pyx_GOTREF(__pyx_t_3);
5160 __pyx_r = __pyx_t_3;
5174 __Pyx_XDECREF(__pyx_t_1);
5175 __Pyx_XDECREF(__pyx_t_2);
5176 __Pyx_XDECREF(__pyx_t_3);
5177 __Pyx_AddTraceback(
"canalyticalSolutions.LinearADR_Sine_diffusiveVelocity", __pyx_clineno, __pyx_lineno, __pyx_filename);
5180 __Pyx_XGIVEREF(__pyx_r);
5181 __Pyx_RefNannyFinishContext();
5194 static PyObject *__pyx_pw_20canalyticalSolutions_39LinearADR_Sine_dr(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
5195 static PyMethodDef __pyx_mdef_20canalyticalSolutions_39LinearADR_Sine_dr = {
"LinearADR_Sine_dr", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_39LinearADR_Sine_dr, METH_VARARGS|METH_KEYWORDS, 0};
5196 static PyObject *__pyx_pw_20canalyticalSolutions_39LinearADR_Sine_dr(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
5197 PyArrayObject *__pyx_v_iwork = 0;
5198 PyArrayObject *__pyx_v_rwork = 0;
5200 PyArrayObject *__pyx_v_x = 0;
5201 PyArrayObject *__pyx_v_u = 0;
5202 PyArrayObject *__pyx_v_dr = 0;
5203 int __pyx_lineno = 0;
5204 const char *__pyx_filename = NULL;
5205 int __pyx_clineno = 0;
5206 PyObject *__pyx_r = 0;
5207 __Pyx_RefNannyDeclarations
5208 __Pyx_RefNannySetupContext(
"LinearADR_Sine_dr (wrapper)", 0);
5210 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_u,&__pyx_n_s_dr,0};
5211 PyObject* values[6] = {0,0,0,0,0,0};
5212 if (unlikely(__pyx_kwds)) {
5214 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
5216 case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
5218 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
5220 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
5222 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
5224 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5226 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5229 default:
goto __pyx_L5_argtuple_error;
5231 kw_args = PyDict_Size(__pyx_kwds);
5234 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
5235 else goto __pyx_L5_argtuple_error;
5238 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
5240 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_dr", 1, 6, 6, 1); __PYX_ERR(0, 126, __pyx_L3_error)
5244 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
5246 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_dr", 1, 6, 6, 2); __PYX_ERR(0, 126, __pyx_L3_error)
5250 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
5252 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_dr", 1, 6, 6, 3); __PYX_ERR(0, 126, __pyx_L3_error)
5256 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
5258 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_dr", 1, 6, 6, 4); __PYX_ERR(0, 126, __pyx_L3_error)
5262 if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_dr)) != 0)) kw_args--;
5264 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_dr", 1, 6, 6, 5); __PYX_ERR(0, 126, __pyx_L3_error)
5267 if (unlikely(kw_args > 0)) {
5268 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"LinearADR_Sine_dr") < 0)) __PYX_ERR(0, 126, __pyx_L3_error)
5270 }
else if (PyTuple_GET_SIZE(__pyx_args) != 6) {
5271 goto __pyx_L5_argtuple_error;
5273 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5274 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5275 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
5276 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
5277 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
5278 values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
5280 __pyx_v_iwork = ((PyArrayObject *)values[0]);
5281 __pyx_v_rwork = ((PyArrayObject *)values[1]);
5282 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 126, __pyx_L3_error)
5283 __pyx_v_x = ((PyArrayObject *)values[3]);
5284 __pyx_v_u = ((PyArrayObject *)values[4]);
5285 __pyx_v_dr = ((PyArrayObject *)values[5]);
5287 goto __pyx_L4_argument_unpacking_done;
5288 __pyx_L5_argtuple_error:;
5289 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_dr", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 126, __pyx_L3_error)
5291 __Pyx_AddTraceback(
"canalyticalSolutions.LinearADR_Sine_dr", __pyx_clineno, __pyx_lineno, __pyx_filename);
5292 __Pyx_RefNannyFinishContext();
5294 __pyx_L4_argument_unpacking_done:;
5295 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 126, __pyx_L1_error)
5296 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 126, __pyx_L1_error)
5297 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 126, __pyx_L1_error)
5298 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1,
"u", 0))) __PYX_ERR(0, 126, __pyx_L1_error)
5299 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dr), __pyx_ptype_5numpy_ndarray, 1,
"dr", 0))) __PYX_ERR(0, 126, __pyx_L1_error)
5300 __pyx_r = __pyx_pf_20canalyticalSolutions_38LinearADR_Sine_dr(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_u, __pyx_v_dr);
5307 __Pyx_RefNannyFinishContext();
5311 static PyObject *__pyx_pf_20canalyticalSolutions_38LinearADR_Sine_dr(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_dr) {
5312 PyObject *__pyx_r = NULL;
5313 __Pyx_RefNannyDeclarations
5314 PyObject *__pyx_t_1 = NULL;
5315 PyObject *__pyx_t_2 = NULL;
5316 PyObject *__pyx_t_3 = NULL;
5318 int __pyx_lineno = 0;
5319 const char *__pyx_filename = NULL;
5320 int __pyx_clineno = 0;
5321 __Pyx_RefNannySetupContext(
"LinearADR_Sine_dr", 0);
5330 __Pyx_XDECREF(__pyx_r);
5331 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 127, __pyx_L1_error)
5332 __Pyx_GOTREF(__pyx_t_1);
5333 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 127, __pyx_L1_error)
5334 __Pyx_GOTREF(__pyx_t_2);
5335 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 127, __pyx_L1_error)
5336 __Pyx_GOTREF(__pyx_t_3);
5337 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
5338 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
5339 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 127, __pyx_L1_error)
5340 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
5341 __pyx_t_3 = __Pyx_PyInt_From_int(
LinearADR_Sine_dr(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_u->data), ((
double *)__pyx_v_dr->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 127, __pyx_L1_error)
5342 __Pyx_GOTREF(__pyx_t_3);
5343 __pyx_r = __pyx_t_3;
5357 __Pyx_XDECREF(__pyx_t_1);
5358 __Pyx_XDECREF(__pyx_t_2);
5359 __Pyx_XDECREF(__pyx_t_3);
5360 __Pyx_AddTraceback(
"canalyticalSolutions.LinearADR_Sine_dr", __pyx_clineno, __pyx_lineno, __pyx_filename);
5363 __Pyx_XGIVEREF(__pyx_r);
5364 __Pyx_RefNannyFinishContext();
5377 static PyObject *__pyx_pw_20canalyticalSolutions_41LinearADR_Sine_du(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
5378 static PyMethodDef __pyx_mdef_20canalyticalSolutions_41LinearADR_Sine_du = {
"LinearADR_Sine_du", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_41LinearADR_Sine_du, METH_VARARGS|METH_KEYWORDS, 0};
5379 static PyObject *__pyx_pw_20canalyticalSolutions_41LinearADR_Sine_du(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
5380 PyArrayObject *__pyx_v_iwork = 0;
5381 PyArrayObject *__pyx_v_rwork = 0;
5383 PyArrayObject *__pyx_v_x = 0;
5384 PyArrayObject *__pyx_v_du = 0;
5385 int __pyx_lineno = 0;
5386 const char *__pyx_filename = NULL;
5387 int __pyx_clineno = 0;
5388 PyObject *__pyx_r = 0;
5389 __Pyx_RefNannyDeclarations
5390 __Pyx_RefNannySetupContext(
"LinearADR_Sine_du (wrapper)", 0);
5392 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_du,0};
5393 PyObject* values[5] = {0,0,0,0,0};
5394 if (unlikely(__pyx_kwds)) {
5396 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
5398 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
5400 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
5402 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
5404 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5406 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5409 default:
goto __pyx_L5_argtuple_error;
5411 kw_args = PyDict_Size(__pyx_kwds);
5414 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
5415 else goto __pyx_L5_argtuple_error;
5418 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
5420 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_du", 1, 5, 5, 1); __PYX_ERR(0, 130, __pyx_L3_error)
5424 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
5426 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_du", 1, 5, 5, 2); __PYX_ERR(0, 130, __pyx_L3_error)
5430 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
5432 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_du", 1, 5, 5, 3); __PYX_ERR(0, 130, __pyx_L3_error)
5436 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_du)) != 0)) kw_args--;
5438 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_du", 1, 5, 5, 4); __PYX_ERR(0, 130, __pyx_L3_error)
5441 if (unlikely(kw_args > 0)) {
5442 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"LinearADR_Sine_du") < 0)) __PYX_ERR(0, 130, __pyx_L3_error)
5444 }
else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
5445 goto __pyx_L5_argtuple_error;
5447 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5448 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5449 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
5450 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
5451 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
5453 __pyx_v_iwork = ((PyArrayObject *)values[0]);
5454 __pyx_v_rwork = ((PyArrayObject *)values[1]);
5455 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 130, __pyx_L3_error)
5456 __pyx_v_x = ((PyArrayObject *)values[3]);
5457 __pyx_v_du = ((PyArrayObject *)values[4]);
5459 goto __pyx_L4_argument_unpacking_done;
5460 __pyx_L5_argtuple_error:;
5461 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_du", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 130, __pyx_L3_error)
5463 __Pyx_AddTraceback(
"canalyticalSolutions.LinearADR_Sine_du", __pyx_clineno, __pyx_lineno, __pyx_filename);
5464 __Pyx_RefNannyFinishContext();
5466 __pyx_L4_argument_unpacking_done:;
5467 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 130, __pyx_L1_error)
5468 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 130, __pyx_L1_error)
5469 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 130, __pyx_L1_error)
5470 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_du), __pyx_ptype_5numpy_ndarray, 1,
"du", 0))) __PYX_ERR(0, 130, __pyx_L1_error)
5471 __pyx_r = __pyx_pf_20canalyticalSolutions_40LinearADR_Sine_du(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_du);
5478 __Pyx_RefNannyFinishContext();
5482 static PyObject *__pyx_pf_20canalyticalSolutions_40LinearADR_Sine_du(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_du) {
5483 PyObject *__pyx_r = NULL;
5484 __Pyx_RefNannyDeclarations
5485 PyObject *__pyx_t_1 = NULL;
5486 PyObject *__pyx_t_2 = NULL;
5487 PyObject *__pyx_t_3 = NULL;
5489 int __pyx_lineno = 0;
5490 const char *__pyx_filename = NULL;
5491 int __pyx_clineno = 0;
5492 __Pyx_RefNannySetupContext(
"LinearADR_Sine_du", 0);
5501 __Pyx_XDECREF(__pyx_r);
5502 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 131, __pyx_L1_error)
5503 __Pyx_GOTREF(__pyx_t_1);
5504 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 131, __pyx_L1_error)
5505 __Pyx_GOTREF(__pyx_t_2);
5506 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 131, __pyx_L1_error)
5507 __Pyx_GOTREF(__pyx_t_3);
5508 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
5509 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
5510 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 131, __pyx_L1_error)
5511 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
5512 __pyx_t_3 = __Pyx_PyInt_From_int(
LinearADR_Sine_du(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_du->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 131, __pyx_L1_error)
5513 __Pyx_GOTREF(__pyx_t_3);
5514 __pyx_r = __pyx_t_3;
5528 __Pyx_XDECREF(__pyx_t_1);
5529 __Pyx_XDECREF(__pyx_t_2);
5530 __Pyx_XDECREF(__pyx_t_3);
5531 __Pyx_AddTraceback(
"canalyticalSolutions.LinearADR_Sine_du", __pyx_clineno, __pyx_lineno, __pyx_filename);
5534 __Pyx_XGIVEREF(__pyx_r);
5535 __Pyx_RefNannyFinishContext();
5548 static PyObject *__pyx_pw_20canalyticalSolutions_43LinearADR_Sine_r(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
5549 static PyMethodDef __pyx_mdef_20canalyticalSolutions_43LinearADR_Sine_r = {
"LinearADR_Sine_r", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_43LinearADR_Sine_r, METH_VARARGS|METH_KEYWORDS, 0};
5550 static PyObject *__pyx_pw_20canalyticalSolutions_43LinearADR_Sine_r(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
5551 PyArrayObject *__pyx_v_iwork = 0;
5552 PyArrayObject *__pyx_v_rwork = 0;
5554 PyArrayObject *__pyx_v_x = 0;
5555 PyArrayObject *__pyx_v_u = 0;
5556 PyArrayObject *__pyx_v_r = 0;
5557 int __pyx_lineno = 0;
5558 const char *__pyx_filename = NULL;
5559 int __pyx_clineno = 0;
5560 PyObject *__pyx_r = 0;
5561 __Pyx_RefNannyDeclarations
5562 __Pyx_RefNannySetupContext(
"LinearADR_Sine_r (wrapper)", 0);
5564 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_u,&__pyx_n_s_r,0};
5565 PyObject* values[6] = {0,0,0,0,0,0};
5566 if (unlikely(__pyx_kwds)) {
5568 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
5570 case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
5572 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
5574 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
5576 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
5578 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5580 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5583 default:
goto __pyx_L5_argtuple_error;
5585 kw_args = PyDict_Size(__pyx_kwds);
5588 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
5589 else goto __pyx_L5_argtuple_error;
5592 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
5594 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_r", 1, 6, 6, 1); __PYX_ERR(0, 134, __pyx_L3_error)
5598 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
5600 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_r", 1, 6, 6, 2); __PYX_ERR(0, 134, __pyx_L3_error)
5604 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
5606 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_r", 1, 6, 6, 3); __PYX_ERR(0, 134, __pyx_L3_error)
5610 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
5612 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_r", 1, 6, 6, 4); __PYX_ERR(0, 134, __pyx_L3_error)
5616 if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_r)) != 0)) kw_args--;
5618 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_r", 1, 6, 6, 5); __PYX_ERR(0, 134, __pyx_L3_error)
5621 if (unlikely(kw_args > 0)) {
5622 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"LinearADR_Sine_r") < 0)) __PYX_ERR(0, 134, __pyx_L3_error)
5624 }
else if (PyTuple_GET_SIZE(__pyx_args) != 6) {
5625 goto __pyx_L5_argtuple_error;
5627 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5628 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5629 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
5630 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
5631 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
5632 values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
5634 __pyx_v_iwork = ((PyArrayObject *)values[0]);
5635 __pyx_v_rwork = ((PyArrayObject *)values[1]);
5636 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 134, __pyx_L3_error)
5637 __pyx_v_x = ((PyArrayObject *)values[3]);
5638 __pyx_v_u = ((PyArrayObject *)values[4]);
5639 __pyx_v_r = ((PyArrayObject *)values[5]);
5641 goto __pyx_L4_argument_unpacking_done;
5642 __pyx_L5_argtuple_error:;
5643 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_r", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 134, __pyx_L3_error)
5645 __Pyx_AddTraceback(
"canalyticalSolutions.LinearADR_Sine_r", __pyx_clineno, __pyx_lineno, __pyx_filename);
5646 __Pyx_RefNannyFinishContext();
5648 __pyx_L4_argument_unpacking_done:;
5649 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 134, __pyx_L1_error)
5650 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 134, __pyx_L1_error)
5651 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 134, __pyx_L1_error)
5652 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1,
"u", 0))) __PYX_ERR(0, 134, __pyx_L1_error)
5653 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_r), __pyx_ptype_5numpy_ndarray, 1,
"r", 0))) __PYX_ERR(0, 134, __pyx_L1_error)
5654 __pyx_r = __pyx_pf_20canalyticalSolutions_42LinearADR_Sine_r(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_u, __pyx_v_r);
5661 __Pyx_RefNannyFinishContext();
5665 static PyObject *__pyx_pf_20canalyticalSolutions_42LinearADR_Sine_r(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_r) {
5666 PyObject *__pyx_r = NULL;
5667 __Pyx_RefNannyDeclarations
5668 PyObject *__pyx_t_1 = NULL;
5669 PyObject *__pyx_t_2 = NULL;
5670 PyObject *__pyx_t_3 = NULL;
5672 int __pyx_lineno = 0;
5673 const char *__pyx_filename = NULL;
5674 int __pyx_clineno = 0;
5675 __Pyx_RefNannySetupContext(
"LinearADR_Sine_r", 0);
5684 __Pyx_XDECREF(__pyx_r);
5685 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 135, __pyx_L1_error)
5686 __Pyx_GOTREF(__pyx_t_1);
5687 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 135, __pyx_L1_error)
5688 __Pyx_GOTREF(__pyx_t_2);
5689 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 135, __pyx_L1_error)
5690 __Pyx_GOTREF(__pyx_t_3);
5691 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
5692 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
5693 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 135, __pyx_L1_error)
5694 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
5695 __pyx_t_3 = __Pyx_PyInt_From_int(
LinearADR_Sine_r(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_u->data), ((
double *)__pyx_v_r->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 135, __pyx_L1_error)
5696 __Pyx_GOTREF(__pyx_t_3);
5697 __pyx_r = __pyx_t_3;
5711 __Pyx_XDECREF(__pyx_t_1);
5712 __Pyx_XDECREF(__pyx_t_2);
5713 __Pyx_XDECREF(__pyx_t_3);
5714 __Pyx_AddTraceback(
"canalyticalSolutions.LinearADR_Sine_r", __pyx_clineno, __pyx_lineno, __pyx_filename);
5717 __Pyx_XGIVEREF(__pyx_r);
5718 __Pyx_RefNannyFinishContext();
5731 static PyObject *__pyx_pw_20canalyticalSolutions_45LinearADR_Sine_totalVelocity(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
5732 static PyMethodDef __pyx_mdef_20canalyticalSolutions_45LinearADR_Sine_totalVelocity = {
"LinearADR_Sine_totalVelocity", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_45LinearADR_Sine_totalVelocity, METH_VARARGS|METH_KEYWORDS, 0};
5733 static PyObject *__pyx_pw_20canalyticalSolutions_45LinearADR_Sine_totalVelocity(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
5734 PyArrayObject *__pyx_v_iwork = 0;
5735 PyArrayObject *__pyx_v_rwork = 0;
5737 PyArrayObject *__pyx_v_x = 0;
5738 PyArrayObject *__pyx_v_u = 0;
5739 int __pyx_lineno = 0;
5740 const char *__pyx_filename = NULL;
5741 int __pyx_clineno = 0;
5742 PyObject *__pyx_r = 0;
5743 __Pyx_RefNannyDeclarations
5744 __Pyx_RefNannySetupContext(
"LinearADR_Sine_totalVelocity (wrapper)", 0);
5746 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_u,0};
5747 PyObject* values[5] = {0,0,0,0,0};
5748 if (unlikely(__pyx_kwds)) {
5750 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
5752 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
5754 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
5756 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
5758 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5760 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5763 default:
goto __pyx_L5_argtuple_error;
5765 kw_args = PyDict_Size(__pyx_kwds);
5768 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
5769 else goto __pyx_L5_argtuple_error;
5772 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
5774 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_totalVelocity", 1, 5, 5, 1); __PYX_ERR(0, 138, __pyx_L3_error)
5778 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
5780 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_totalVelocity", 1, 5, 5, 2); __PYX_ERR(0, 138, __pyx_L3_error)
5784 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
5786 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_totalVelocity", 1, 5, 5, 3); __PYX_ERR(0, 138, __pyx_L3_error)
5790 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
5792 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_totalVelocity", 1, 5, 5, 4); __PYX_ERR(0, 138, __pyx_L3_error)
5795 if (unlikely(kw_args > 0)) {
5796 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"LinearADR_Sine_totalVelocity") < 0)) __PYX_ERR(0, 138, __pyx_L3_error)
5798 }
else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
5799 goto __pyx_L5_argtuple_error;
5801 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5802 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5803 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
5804 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
5805 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
5807 __pyx_v_iwork = ((PyArrayObject *)values[0]);
5808 __pyx_v_rwork = ((PyArrayObject *)values[1]);
5809 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 138, __pyx_L3_error)
5810 __pyx_v_x = ((PyArrayObject *)values[3]);
5811 __pyx_v_u = ((PyArrayObject *)values[4]);
5813 goto __pyx_L4_argument_unpacking_done;
5814 __pyx_L5_argtuple_error:;
5815 __Pyx_RaiseArgtupleInvalid(
"LinearADR_Sine_totalVelocity", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 138, __pyx_L3_error)
5817 __Pyx_AddTraceback(
"canalyticalSolutions.LinearADR_Sine_totalVelocity", __pyx_clineno, __pyx_lineno, __pyx_filename);
5818 __Pyx_RefNannyFinishContext();
5820 __pyx_L4_argument_unpacking_done:;
5821 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 138, __pyx_L1_error)
5822 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 138, __pyx_L1_error)
5823 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 138, __pyx_L1_error)
5824 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1,
"u", 0))) __PYX_ERR(0, 138, __pyx_L1_error)
5825 __pyx_r = __pyx_pf_20canalyticalSolutions_44LinearADR_Sine_totalVelocity(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_u);
5832 __Pyx_RefNannyFinishContext();
5836 static PyObject *__pyx_pf_20canalyticalSolutions_44LinearADR_Sine_totalVelocity(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u) {
5837 PyObject *__pyx_r = NULL;
5838 __Pyx_RefNannyDeclarations
5839 PyObject *__pyx_t_1 = NULL;
5840 PyObject *__pyx_t_2 = NULL;
5841 PyObject *__pyx_t_3 = NULL;
5843 int __pyx_lineno = 0;
5844 const char *__pyx_filename = NULL;
5845 int __pyx_clineno = 0;
5846 __Pyx_RefNannySetupContext(
"LinearADR_Sine_totalVelocity", 0);
5855 __Pyx_XDECREF(__pyx_r);
5856 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 139, __pyx_L1_error)
5857 __Pyx_GOTREF(__pyx_t_1);
5858 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 139, __pyx_L1_error)
5859 __Pyx_GOTREF(__pyx_t_2);
5860 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 139, __pyx_L1_error)
5861 __Pyx_GOTREF(__pyx_t_3);
5862 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
5863 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
5864 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 139, __pyx_L1_error)
5865 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
5866 __pyx_t_3 = __Pyx_PyInt_From_int(
LinearADR_Sine_totalVelocity(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_u->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 139, __pyx_L1_error)
5867 __Pyx_GOTREF(__pyx_t_3);
5868 __pyx_r = __pyx_t_3;
5882 __Pyx_XDECREF(__pyx_t_1);
5883 __Pyx_XDECREF(__pyx_t_2);
5884 __Pyx_XDECREF(__pyx_t_3);
5885 __Pyx_AddTraceback(
"canalyticalSolutions.LinearADR_Sine_totalVelocity", __pyx_clineno, __pyx_lineno, __pyx_filename);
5888 __Pyx_XGIVEREF(__pyx_r);
5889 __Pyx_RefNannyFinishContext();
5902 static PyObject *__pyx_pw_20canalyticalSolutions_47NonlinearAD_SteadyState(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
5903 static PyMethodDef __pyx_mdef_20canalyticalSolutions_47NonlinearAD_SteadyState = {
"NonlinearAD_SteadyState", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_47NonlinearAD_SteadyState, METH_VARARGS|METH_KEYWORDS, 0};
5904 static PyObject *__pyx_pw_20canalyticalSolutions_47NonlinearAD_SteadyState(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
5905 PyArrayObject *__pyx_v_iwork = 0;
5906 PyArrayObject *__pyx_v_rwork = 0;
5908 PyArrayObject *__pyx_v_x = 0;
5909 PyArrayObject *__pyx_v_u = 0;
5910 int __pyx_lineno = 0;
5911 const char *__pyx_filename = NULL;
5912 int __pyx_clineno = 0;
5913 PyObject *__pyx_r = 0;
5914 __Pyx_RefNannyDeclarations
5915 __Pyx_RefNannySetupContext(
"NonlinearAD_SteadyState (wrapper)", 0);
5917 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_u,0};
5918 PyObject* values[5] = {0,0,0,0,0};
5919 if (unlikely(__pyx_kwds)) {
5921 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
5923 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
5925 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
5927 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
5929 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5931 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5934 default:
goto __pyx_L5_argtuple_error;
5936 kw_args = PyDict_Size(__pyx_kwds);
5939 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
5940 else goto __pyx_L5_argtuple_error;
5943 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
5945 __Pyx_RaiseArgtupleInvalid(
"NonlinearAD_SteadyState", 1, 5, 5, 1); __PYX_ERR(0, 142, __pyx_L3_error)
5949 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
5951 __Pyx_RaiseArgtupleInvalid(
"NonlinearAD_SteadyState", 1, 5, 5, 2); __PYX_ERR(0, 142, __pyx_L3_error)
5955 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
5957 __Pyx_RaiseArgtupleInvalid(
"NonlinearAD_SteadyState", 1, 5, 5, 3); __PYX_ERR(0, 142, __pyx_L3_error)
5961 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
5963 __Pyx_RaiseArgtupleInvalid(
"NonlinearAD_SteadyState", 1, 5, 5, 4); __PYX_ERR(0, 142, __pyx_L3_error)
5966 if (unlikely(kw_args > 0)) {
5967 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"NonlinearAD_SteadyState") < 0)) __PYX_ERR(0, 142, __pyx_L3_error)
5969 }
else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
5970 goto __pyx_L5_argtuple_error;
5972 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5973 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5974 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
5975 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
5976 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
5978 __pyx_v_iwork = ((PyArrayObject *)values[0]);
5979 __pyx_v_rwork = ((PyArrayObject *)values[1]);
5980 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 142, __pyx_L3_error)
5981 __pyx_v_x = ((PyArrayObject *)values[3]);
5982 __pyx_v_u = ((PyArrayObject *)values[4]);
5984 goto __pyx_L4_argument_unpacking_done;
5985 __pyx_L5_argtuple_error:;
5986 __Pyx_RaiseArgtupleInvalid(
"NonlinearAD_SteadyState", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 142, __pyx_L3_error)
5988 __Pyx_AddTraceback(
"canalyticalSolutions.NonlinearAD_SteadyState", __pyx_clineno, __pyx_lineno, __pyx_filename);
5989 __Pyx_RefNannyFinishContext();
5991 __pyx_L4_argument_unpacking_done:;
5992 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 142, __pyx_L1_error)
5993 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 142, __pyx_L1_error)
5994 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 142, __pyx_L1_error)
5995 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1,
"u", 0))) __PYX_ERR(0, 142, __pyx_L1_error)
5996 __pyx_r = __pyx_pf_20canalyticalSolutions_46NonlinearAD_SteadyState(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_u);
6003 __Pyx_RefNannyFinishContext();
6007 static PyObject *__pyx_pf_20canalyticalSolutions_46NonlinearAD_SteadyState(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u) {
6008 PyObject *__pyx_r = NULL;
6009 __Pyx_RefNannyDeclarations
6010 PyObject *__pyx_t_1 = NULL;
6011 PyObject *__pyx_t_2 = NULL;
6012 PyObject *__pyx_t_3 = NULL;
6014 int __pyx_lineno = 0;
6015 const char *__pyx_filename = NULL;
6016 int __pyx_clineno = 0;
6017 __Pyx_RefNannySetupContext(
"NonlinearAD_SteadyState", 0);
6026 __Pyx_XDECREF(__pyx_r);
6027 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 143, __pyx_L1_error)
6028 __Pyx_GOTREF(__pyx_t_1);
6029 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 143, __pyx_L1_error)
6030 __Pyx_GOTREF(__pyx_t_2);
6031 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 143, __pyx_L1_error)
6032 __Pyx_GOTREF(__pyx_t_3);
6033 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
6034 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
6035 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 143, __pyx_L1_error)
6036 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
6037 __pyx_t_3 = __Pyx_PyInt_From_int(
NonlinearAD_SteadyState(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_u->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 143, __pyx_L1_error)
6038 __Pyx_GOTREF(__pyx_t_3);
6039 __pyx_r = __pyx_t_3;
6053 __Pyx_XDECREF(__pyx_t_1);
6054 __Pyx_XDECREF(__pyx_t_2);
6055 __Pyx_XDECREF(__pyx_t_3);
6056 __Pyx_AddTraceback(
"canalyticalSolutions.NonlinearAD_SteadyState", __pyx_clineno, __pyx_lineno, __pyx_filename);
6059 __Pyx_XGIVEREF(__pyx_r);
6060 __Pyx_RefNannyFinishContext();
6073 static PyObject *__pyx_pw_20canalyticalSolutions_49NonlinearADR_Decay_DiracIC(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
6074 static PyMethodDef __pyx_mdef_20canalyticalSolutions_49NonlinearADR_Decay_DiracIC = {
"NonlinearADR_Decay_DiracIC", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_49NonlinearADR_Decay_DiracIC, METH_VARARGS|METH_KEYWORDS, 0};
6075 static PyObject *__pyx_pw_20canalyticalSolutions_49NonlinearADR_Decay_DiracIC(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
6076 PyArrayObject *__pyx_v_iwork = 0;
6077 PyArrayObject *__pyx_v_rwork = 0;
6079 PyArrayObject *__pyx_v_x = 0;
6080 PyArrayObject *__pyx_v_u = 0;
6081 int __pyx_lineno = 0;
6082 const char *__pyx_filename = NULL;
6083 int __pyx_clineno = 0;
6084 PyObject *__pyx_r = 0;
6085 __Pyx_RefNannyDeclarations
6086 __Pyx_RefNannySetupContext(
"NonlinearADR_Decay_DiracIC (wrapper)", 0);
6088 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_u,0};
6089 PyObject* values[5] = {0,0,0,0,0};
6090 if (unlikely(__pyx_kwds)) {
6092 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
6094 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
6096 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
6098 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
6100 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
6102 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
6105 default:
goto __pyx_L5_argtuple_error;
6107 kw_args = PyDict_Size(__pyx_kwds);
6110 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
6111 else goto __pyx_L5_argtuple_error;
6114 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
6116 __Pyx_RaiseArgtupleInvalid(
"NonlinearADR_Decay_DiracIC", 1, 5, 5, 1); __PYX_ERR(0, 146, __pyx_L3_error)
6120 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
6122 __Pyx_RaiseArgtupleInvalid(
"NonlinearADR_Decay_DiracIC", 1, 5, 5, 2); __PYX_ERR(0, 146, __pyx_L3_error)
6126 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
6128 __Pyx_RaiseArgtupleInvalid(
"NonlinearADR_Decay_DiracIC", 1, 5, 5, 3); __PYX_ERR(0, 146, __pyx_L3_error)
6132 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
6134 __Pyx_RaiseArgtupleInvalid(
"NonlinearADR_Decay_DiracIC", 1, 5, 5, 4); __PYX_ERR(0, 146, __pyx_L3_error)
6137 if (unlikely(kw_args > 0)) {
6138 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"NonlinearADR_Decay_DiracIC") < 0)) __PYX_ERR(0, 146, __pyx_L3_error)
6140 }
else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
6141 goto __pyx_L5_argtuple_error;
6143 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
6144 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
6145 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
6146 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
6147 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
6149 __pyx_v_iwork = ((PyArrayObject *)values[0]);
6150 __pyx_v_rwork = ((PyArrayObject *)values[1]);
6151 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 146, __pyx_L3_error)
6152 __pyx_v_x = ((PyArrayObject *)values[3]);
6153 __pyx_v_u = ((PyArrayObject *)values[4]);
6155 goto __pyx_L4_argument_unpacking_done;
6156 __pyx_L5_argtuple_error:;
6157 __Pyx_RaiseArgtupleInvalid(
"NonlinearADR_Decay_DiracIC", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 146, __pyx_L3_error)
6159 __Pyx_AddTraceback(
"canalyticalSolutions.NonlinearADR_Decay_DiracIC", __pyx_clineno, __pyx_lineno, __pyx_filename);
6160 __Pyx_RefNannyFinishContext();
6162 __pyx_L4_argument_unpacking_done:;
6163 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 146, __pyx_L1_error)
6164 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 146, __pyx_L1_error)
6165 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 146, __pyx_L1_error)
6166 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1,
"u", 0))) __PYX_ERR(0, 146, __pyx_L1_error)
6167 __pyx_r = __pyx_pf_20canalyticalSolutions_48NonlinearADR_Decay_DiracIC(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_u);
6174 __Pyx_RefNannyFinishContext();
6178 static PyObject *__pyx_pf_20canalyticalSolutions_48NonlinearADR_Decay_DiracIC(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u) {
6179 PyObject *__pyx_r = NULL;
6180 __Pyx_RefNannyDeclarations
6181 PyObject *__pyx_t_1 = NULL;
6182 PyObject *__pyx_t_2 = NULL;
6183 PyObject *__pyx_t_3 = NULL;
6185 int __pyx_lineno = 0;
6186 const char *__pyx_filename = NULL;
6187 int __pyx_clineno = 0;
6188 __Pyx_RefNannySetupContext(
"NonlinearADR_Decay_DiracIC", 0);
6197 __Pyx_XDECREF(__pyx_r);
6198 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 147, __pyx_L1_error)
6199 __Pyx_GOTREF(__pyx_t_1);
6200 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 147, __pyx_L1_error)
6201 __Pyx_GOTREF(__pyx_t_2);
6202 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 147, __pyx_L1_error)
6203 __Pyx_GOTREF(__pyx_t_3);
6204 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
6205 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
6206 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 147, __pyx_L1_error)
6207 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
6208 __pyx_t_3 = __Pyx_PyInt_From_int(
NonlinearADR_Decay_DiracIC(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_u->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 147, __pyx_L1_error)
6209 __Pyx_GOTREF(__pyx_t_3);
6210 __pyx_r = __pyx_t_3;
6224 __Pyx_XDECREF(__pyx_t_1);
6225 __Pyx_XDECREF(__pyx_t_2);
6226 __Pyx_XDECREF(__pyx_t_3);
6227 __Pyx_AddTraceback(
"canalyticalSolutions.NonlinearADR_Decay_DiracIC", __pyx_clineno, __pyx_lineno, __pyx_filename);
6230 __Pyx_XGIVEREF(__pyx_r);
6231 __Pyx_RefNannyFinishContext();
6244 static PyObject *__pyx_pw_20canalyticalSolutions_51NonlinearADR_Decay_DiracIC_dr(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
6245 static PyMethodDef __pyx_mdef_20canalyticalSolutions_51NonlinearADR_Decay_DiracIC_dr = {
"NonlinearADR_Decay_DiracIC_dr", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_51NonlinearADR_Decay_DiracIC_dr, METH_VARARGS|METH_KEYWORDS, 0};
6246 static PyObject *__pyx_pw_20canalyticalSolutions_51NonlinearADR_Decay_DiracIC_dr(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
6247 PyArrayObject *__pyx_v_iwork = 0;
6248 PyArrayObject *__pyx_v_rwork = 0;
6250 PyArrayObject *__pyx_v_x = 0;
6251 PyArrayObject *__pyx_v_u = 0;
6252 PyArrayObject *__pyx_v_dr = 0;
6253 int __pyx_lineno = 0;
6254 const char *__pyx_filename = NULL;
6255 int __pyx_clineno = 0;
6256 PyObject *__pyx_r = 0;
6257 __Pyx_RefNannyDeclarations
6258 __Pyx_RefNannySetupContext(
"NonlinearADR_Decay_DiracIC_dr (wrapper)", 0);
6260 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_u,&__pyx_n_s_dr,0};
6261 PyObject* values[6] = {0,0,0,0,0,0};
6262 if (unlikely(__pyx_kwds)) {
6264 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
6266 case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
6268 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
6270 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
6272 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
6274 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
6276 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
6279 default:
goto __pyx_L5_argtuple_error;
6281 kw_args = PyDict_Size(__pyx_kwds);
6284 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
6285 else goto __pyx_L5_argtuple_error;
6288 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rwork)) != 0)) kw_args--;
6290 __Pyx_RaiseArgtupleInvalid(
"NonlinearADR_Decay_DiracIC_dr", 1, 6, 6, 1); __PYX_ERR(0, 150, __pyx_L3_error)
6294 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_t)) != 0)) kw_args--;
6296 __Pyx_RaiseArgtupleInvalid(
"NonlinearADR_Decay_DiracIC_dr", 1, 6, 6, 2); __PYX_ERR(0, 150, __pyx_L3_error)
6300 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
6302 __Pyx_RaiseArgtupleInvalid(
"NonlinearADR_Decay_DiracIC_dr", 1, 6, 6, 3); __PYX_ERR(0, 150, __pyx_L3_error)
6306 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
6308 __Pyx_RaiseArgtupleInvalid(
"NonlinearADR_Decay_DiracIC_dr", 1, 6, 6, 4); __PYX_ERR(0, 150, __pyx_L3_error)
6312 if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_dr)) != 0)) kw_args--;
6314 __Pyx_RaiseArgtupleInvalid(
"NonlinearADR_Decay_DiracIC_dr", 1, 6, 6, 5); __PYX_ERR(0, 150, __pyx_L3_error)
6317 if (unlikely(kw_args > 0)) {
6318 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"NonlinearADR_Decay_DiracIC_dr") < 0)) __PYX_ERR(0, 150, __pyx_L3_error)
6320 }
else if (PyTuple_GET_SIZE(__pyx_args) != 6) {
6321 goto __pyx_L5_argtuple_error;
6323 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
6324 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
6325 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
6326 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
6327 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
6328 values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
6330 __pyx_v_iwork = ((PyArrayObject *)values[0]);
6331 __pyx_v_rwork = ((PyArrayObject *)values[1]);
6332 __pyx_v_t = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_t == (
double)-1) && PyErr_Occurred())) __PYX_ERR(0, 150, __pyx_L3_error)
6333 __pyx_v_x = ((PyArrayObject *)values[3]);
6334 __pyx_v_u = ((PyArrayObject *)values[4]);
6335 __pyx_v_dr = ((PyArrayObject *)values[5]);
6337 goto __pyx_L4_argument_unpacking_done;
6338 __pyx_L5_argtuple_error:;
6339 __Pyx_RaiseArgtupleInvalid(
"NonlinearADR_Decay_DiracIC_dr", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 150, __pyx_L3_error)
6341 __Pyx_AddTraceback(
"canalyticalSolutions.NonlinearADR_Decay_DiracIC_dr", __pyx_clineno, __pyx_lineno, __pyx_filename);
6342 __Pyx_RefNannyFinishContext();
6344 __pyx_L4_argument_unpacking_done:;
6345 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_iwork), __pyx_ptype_5numpy_ndarray, 1,
"iwork", 0))) __PYX_ERR(0, 150, __pyx_L1_error)
6346 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rwork), __pyx_ptype_5numpy_ndarray, 1,
"rwork", 0))) __PYX_ERR(0, 150, __pyx_L1_error)
6347 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1,
"x", 0))) __PYX_ERR(0, 150, __pyx_L1_error)
6348 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1,
"u", 0))) __PYX_ERR(0, 150, __pyx_L1_error)
6349 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dr), __pyx_ptype_5numpy_ndarray, 1,
"dr", 0))) __PYX_ERR(0, 150, __pyx_L1_error)
6350 __pyx_r = __pyx_pf_20canalyticalSolutions_50NonlinearADR_Decay_DiracIC_dr(__pyx_self, __pyx_v_iwork, __pyx_v_rwork, __pyx_v_t, __pyx_v_x, __pyx_v_u, __pyx_v_dr);
6357 __Pyx_RefNannyFinishContext();
6361 static PyObject *__pyx_pf_20canalyticalSolutions_50NonlinearADR_Decay_DiracIC_dr(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_iwork, PyArrayObject *__pyx_v_rwork,
double __pyx_v_t, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_dr) {
6362 PyObject *__pyx_r = NULL;
6363 __Pyx_RefNannyDeclarations
6364 PyObject *__pyx_t_1 = NULL;
6365 PyObject *__pyx_t_2 = NULL;
6366 PyObject *__pyx_t_3 = NULL;
6368 int __pyx_lineno = 0;
6369 const char *__pyx_filename = NULL;
6370 int __pyx_clineno = 0;
6371 __Pyx_RefNannySetupContext(
"NonlinearADR_Decay_DiracIC_dr", 0);
6380 __Pyx_XDECREF(__pyx_r);
6381 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 151, __pyx_L1_error)
6382 __Pyx_GOTREF(__pyx_t_1);
6383 __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_x->dimensions[(__pyx_v_x->nd - 1)]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 151, __pyx_L1_error)
6384 __Pyx_GOTREF(__pyx_t_2);
6385 __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 151, __pyx_L1_error)
6386 __Pyx_GOTREF(__pyx_t_3);
6387 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
6388 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
6389 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 151, __pyx_L1_error)
6390 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
6391 __pyx_t_3 = __Pyx_PyInt_From_int(
NonlinearADR_Decay_DiracIC_dr(((
int *)__pyx_v_iwork->data), ((
double *)__pyx_v_rwork->data), __pyx_t_4, __pyx_v_t, ((
double *)__pyx_v_x->data), ((
double *)__pyx_v_u->data), ((
double *)__pyx_v_dr->data)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 151, __pyx_L1_error)
6392 __Pyx_GOTREF(__pyx_t_3);
6393 __pyx_r = __pyx_t_3;
6407 __Pyx_XDECREF(__pyx_t_1);
6408 __Pyx_XDECREF(__pyx_t_2);
6409 __Pyx_XDECREF(__pyx_t_3);
6410 __Pyx_AddTraceback(
"canalyticalSolutions.NonlinearADR_Decay_DiracIC_dr", __pyx_clineno, __pyx_lineno, __pyx_filename);
6413 __Pyx_XGIVEREF(__pyx_r);
6414 __Pyx_RefNannyFinishContext();
6427 static PyObject *__pyx_pw_20canalyticalSolutions_53NonlinearADR_Decay_DiracIC_r(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
6428 static PyMethodDef __pyx_mdef_20canalyticalSolutions_53NonlinearADR_Decay_DiracIC_r = {
"NonlinearADR_Decay_DiracIC_r", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_20canalyticalSolutions_53NonlinearADR_Decay_DiracIC_r, METH_VARARGS|METH_KEYWORDS, 0};
6429 static PyObject *__pyx_pw_20canalyticalSolutions_53NonlinearADR_Decay_DiracIC_r(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
6430 PyArrayObject *__pyx_v_iwork = 0;
6431 PyArrayObject *__pyx_v_rwork = 0;
6433 PyArrayObject *__pyx_v_x = 0;
6434 PyArrayObject *__pyx_v_u = 0;
6435 PyArrayObject *__pyx_v_r = 0;
6436 int __pyx_lineno = 0;
6437 const char *__pyx_filename = NULL;
6438 int __pyx_clineno = 0;
6439 PyObject *__pyx_r = 0;
6440 __Pyx_RefNannyDeclarations
6441 __Pyx_RefNannySetupContext(
"NonlinearADR_Decay_DiracIC_r (wrapper)", 0);
6443 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_iwork,&__pyx_n_s_rwork,&__pyx_n_s_t,&__pyx_n_s_x,&__pyx_n_s_u,&__pyx_n_s_r,0};
6444 PyObject* values[6] = {0,0,0,0,0,0};
6445 if (unlikely(__pyx_kwds)) {
6447 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
6449 case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
6451 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
6453 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
6455 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
6457 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
6459 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
6462 default:
goto __pyx_L5_argtuple_error;
6464 kw_args = PyDict_Size(__pyx_kwds);
6467 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_iwork)) != 0)) kw_args--;
6468 else goto __pyx_L5_argtuple_error;
6471 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_