proteus  1.8.1
C/C++/Fortran libraries
cpostprocessing.c
Go to the documentation of this file.
1 /* Generated by Cython 0.29.30 */
2 
3 #ifndef PY_SSIZE_T_CLEAN
4 #define PY_SSIZE_T_CLEAN
5 #endif /* PY_SSIZE_T_CLEAN */
6 #include "Python.h"
7 #ifndef Py_PYTHON_H
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+.
11 #else
12 #define CYTHON_ABI "0_29_30"
13 #define CYTHON_HEX_VERSION 0x001D1EF0
14 #define CYTHON_FUTURE_DIVISION 0
15 #include <stddef.h>
16 #ifndef offsetof
17  #define offsetof(type, member) ( (size_t) & ((type*)0) -> member )
18 #endif
19 #if !defined(WIN32) && !defined(MS_WINDOWS)
20  #ifndef __stdcall
21  #define __stdcall
22  #endif
23  #ifndef __cdecl
24  #define __cdecl
25  #endif
26  #ifndef __fastcall
27  #define __fastcall
28  #endif
29 #endif
30 #ifndef DL_IMPORT
31  #define DL_IMPORT(t) t
32 #endif
33 #ifndef DL_EXPORT
34  #define DL_EXPORT(t) t
35 #endif
36 #define __PYX_COMMA ,
37 #ifndef HAVE_LONG_LONG
38  #if PY_VERSION_HEX >= 0x02070000
39  #define HAVE_LONG_LONG
40  #endif
41 #endif
42 #ifndef PY_LONG_LONG
43  #define PY_LONG_LONG LONG_LONG
44 #endif
45 #ifndef Py_HUGE_VAL
46  #define Py_HUGE_VAL HUGE_VAL
47 #endif
48 #ifdef PYPY_VERSION
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
61  #endif
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)
90  #endif
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
97  #endif
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
106  #endif
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
113  #endif
114  #ifndef CYTHON_ASSUME_SAFE_MACROS
115  #define CYTHON_ASSUME_SAFE_MACROS 1
116  #endif
117  #ifndef CYTHON_UNPACK_METHODS
118  #define CYTHON_UNPACK_METHODS 1
119  #endif
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
134  #endif
135 #else
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
141  #endif
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
147  #endif
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
153  #endif
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
159  #endif
160  #ifndef CYTHON_USE_PYLIST_INTERNALS
161  #define CYTHON_USE_PYLIST_INTERNALS 1
162  #endif
163  #ifndef CYTHON_USE_UNICODE_INTERNALS
164  #define CYTHON_USE_UNICODE_INTERNALS 1
165  #endif
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
171  #endif
172  #ifndef CYTHON_AVOID_BORROWED_REFS
173  #define CYTHON_AVOID_BORROWED_REFS 0
174  #endif
175  #ifndef CYTHON_ASSUME_SAFE_MACROS
176  #define CYTHON_ASSUME_SAFE_MACROS 1
177  #endif
178  #ifndef CYTHON_UNPACK_METHODS
179  #define CYTHON_UNPACK_METHODS 1
180  #endif
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
186  #endif
187  #ifndef CYTHON_FAST_PYCALL
188  #define CYTHON_FAST_PYCALL (PY_VERSION_HEX < 0x030A0000)
189  #endif
190  #ifndef CYTHON_PEP489_MULTI_PHASE_INIT
191  #define CYTHON_PEP489_MULTI_PHASE_INIT (PY_VERSION_HEX >= 0x03050000)
192  #endif
193  #ifndef CYTHON_USE_TP_FINALIZE
194  #define CYTHON_USE_TP_FINALIZE (PY_VERSION_HEX >= 0x030400a1)
195  #endif
196  #ifndef CYTHON_USE_DICT_VERSIONS
197  #define CYTHON_USE_DICT_VERSIONS (PY_VERSION_HEX >= 0x030600B1)
198  #endif
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)
204  #endif
205  #ifndef CYTHON_UPDATE_DESCRIPTOR_DOC
206  #define CYTHON_UPDATE_DESCRIPTOR_DOC 1
207  #endif
208 #endif
209 #if !defined(CYTHON_FAST_PYCCALL)
210 #define CYTHON_FAST_PYCCALL (CYTHON_FAST_PYCALL && PY_VERSION_HEX >= 0x030600B1)
211 #endif
212 #if CYTHON_USE_PYLONG_INTERNALS
213  #if PY_MAJOR_VERSION < 3
214  #include "longintrepr.h"
215  #endif
216  #undef SHIFT
217  #undef BASE
218  #undef MASK
219  #ifdef SIZEOF_VOID_P
220  enum { __pyx_check_sizeof_voidp = 1 / (int)(SIZEOF_VOID_P == sizeof(void*)) };
221  #endif
222 #endif
223 #ifndef __has_attribute
224  #define __has_attribute(x) 0
225 #endif
226 #ifndef __has_cpp_attribute
227  #define __has_cpp_attribute(x) 0
228 #endif
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
236  #else
237  #define CYTHON_RESTRICT
238  #endif
239 #endif
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__))
244 # else
245 # define CYTHON_UNUSED
246 # endif
247 # elif defined(__ICC) || (defined(__INTEL_COMPILER) && !defined(_MSC_VER))
248 # define CYTHON_UNUSED __attribute__ ((__unused__))
249 # else
250 # define CYTHON_UNUSED
251 # endif
252 #endif
253 #ifndef CYTHON_MAYBE_UNUSED_VAR
254 # if defined(__cplusplus)
255  template<class T> void CYTHON_MAYBE_UNUSED_VAR( const T& ) { }
256 # else
257 # define CYTHON_MAYBE_UNUSED_VAR(x) (void)(x)
258 # endif
259 #endif
260 #ifndef CYTHON_NCP_UNUSED
261 # if CYTHON_COMPILING_IN_CPYTHON
262 # define CYTHON_NCP_UNUSED
263 # else
264 # define CYTHON_NCP_UNUSED CYTHON_UNUSED
265 # endif
266 #endif
267 #define __Pyx_void_to_None(void_result) ((void)(void_result), Py_INCREF(Py_None), Py_None)
268 #ifdef _MSC_VER
269  #ifndef _MSC_STDINT_H_
270  #if _MSC_VER < 1300
271  typedef unsigned char uint8_t;
272  typedef unsigned int uint32_t;
273  #else
274  typedef unsigned __int8 uint8_t;
275  typedef unsigned __int32 uint32_t;
276  #endif
277  #endif
278 #else
279  #include <stdint.h>
280 #endif
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]]
289  #endif
290  #endif
291  #ifndef CYTHON_FALLTHROUGH
292  #if __has_attribute(fallthrough)
293  #define CYTHON_FALLTHROUGH __attribute__((fallthrough))
294  #else
295  #define CYTHON_FALLTHROUGH
296  #endif
297  #endif
298  #if defined(__clang__ ) && defined(__apple_build_version__)
299  #if __apple_build_version__ < 7000000
300  #undef CYTHON_FALLTHROUGH
301  #define CYTHON_FALLTHROUGH
302  #endif
303  #endif
304 #endif
305 
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
315  #else
316  #define CYTHON_INLINE
317  #endif
318 #endif
319 
320 #if CYTHON_COMPILING_IN_PYPY && PY_VERSION_HEX < 0x02070600 && !defined(Py_OptimizeFlag)
321  #define Py_OptimizeFlag 0
322 #endif
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
330 #else
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; // unfortunately __pyx_empty_tuple isn't available here
370  if (!(call_result = PyObject_Call(replace, empty, kwds))) goto cleanup_code_too;
371  Py_XDECREF((PyObject*)co);
372  co = (PyCodeObject*)call_result;
373  call_result = NULL;
374  if (0) {
375  cleanup_code_too:
376  Py_XDECREF((PyObject*)co);
377  co = NULL;
378  }
379  end:
380  Py_XDECREF(kwds);
381  Py_XDECREF(argcount);
382  Py_XDECREF(posonlyargcount);
383  Py_XDECREF(kwonlyargcount);
384  Py_XDECREF(nlocals);
385  Py_XDECREF(stacksize);
386  Py_XDECREF(replace);
387  Py_XDECREF(call_result);
388  Py_XDECREF(empty);
389  if (type) {
390  PyErr_Restore(type, value, traceback);
391  }
392  return co;
393  }
394 #else
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)
397 #endif
398  #define __Pyx_DefaultClassType PyType_Type
399 #endif
400 #ifndef Py_TPFLAGS_CHECKTYPES
401  #define Py_TPFLAGS_CHECKTYPES 0
402 #endif
403 #ifndef Py_TPFLAGS_HAVE_INDEX
404  #define Py_TPFLAGS_HAVE_INDEX 0
405 #endif
406 #ifndef Py_TPFLAGS_HAVE_NEWBUFFER
407  #define Py_TPFLAGS_HAVE_NEWBUFFER 0
408 #endif
409 #ifndef Py_TPFLAGS_HAVE_FINALIZE
410  #define Py_TPFLAGS_HAVE_FINALIZE 0
411 #endif
412 #ifndef METH_STACKLESS
413  #define METH_STACKLESS 0
414 #endif
415 #if PY_VERSION_HEX <= 0x030700A3 || !defined(METH_FASTCALL)
416  #ifndef METH_FASTCALL
417  #define METH_FASTCALL 0x80
418  #endif
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);
422 #else
423  #define __Pyx_PyCFunctionFast _PyCFunctionFast
424  #define __Pyx_PyCFunctionFastWithKeywords _PyCFunctionFastWithKeywords
425 #endif
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)))))
429 #else
430 #define __Pyx_PyFastCFunction_Check(func) 0
431 #endif
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)
436 #endif
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)
441 #endif
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)
445 #else
446  #define __Pyx_PyCode_HasFreeVars(co) (PyCode_GetNumFree(co) > 0)
447  #define __Pyx_PyFrame_SetLineNumber(frame, lineno) (frame)->f_lineno = (lineno)
448 #endif
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()
455 #else
456  #define __Pyx_PyThreadState_Current _PyThreadState_Current
457 #endif
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();
464  return 0;
465 }
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;
469  return key;
470 }
471 static CYTHON_INLINE void PyThread_tss_free(Py_tss_t *key) {
472  PyObject_Free(key);
473 }
474 static CYTHON_INLINE int PyThread_tss_is_created(Py_tss_t *key) {
475  return *key != Py_tss_NEEDS_INIT;
476 }
477 static CYTHON_INLINE void PyThread_tss_delete(Py_tss_t *key) {
478  PyThread_delete_key(*key);
479  *key = Py_tss_NEEDS_INIT;
480 }
481 static CYTHON_INLINE int PyThread_tss_set(Py_tss_t *key, void *value) {
482  return PyThread_set_key_value(*key, value);
483 }
484 static CYTHON_INLINE void * PyThread_tss_get(Py_tss_t *key) {
485  return PyThread_get_key_value(*key);
486 }
487 #endif
488 #if CYTHON_COMPILING_IN_CPYTHON || defined(_PyDict_NewPresized)
489 #define __Pyx_PyDict_NewPresized(n) ((n <= 8) ? PyDict_New() : _PyDict_NewPresized(n))
490 #else
491 #define __Pyx_PyDict_NewPresized(n) PyDict_New()
492 #endif
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)
496 #else
497  #define __Pyx_PyNumber_Divide(x,y) PyNumber_Divide(x,y)
498  #define __Pyx_PyNumber_InPlaceDivide(x,y) PyNumber_InPlaceDivide(x,y)
499 #endif
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)
502 #else
503 #define __Pyx_PyDict_GetItemStr(dict, name) PyDict_GetItem(dict, name)
504 #endif
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)))
510  #else
511  #define __Pyx_PyUnicode_READY(op) (0)
512  #endif
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))
523  #else
524  #define __Pyx_PyUnicode_IS_TRUE(u) (0 != (likely(PyUnicode_IS_READY(u)) ? PyUnicode_GET_LENGTH(u) : PyUnicode_GET_SIZE(u)))
525  #endif
526  #else
527  #define __Pyx_PyUnicode_IS_TRUE(u) (0 != PyUnicode_GET_LENGTH(u))
528  #endif
529 #else
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))
543 #endif
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)
547 #else
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))
551 #endif
552 #if CYTHON_COMPILING_IN_PYPY && !defined(PyUnicode_Contains)
553  #define PyUnicode_Contains(u, s) PySequence_Contains(u, s)
554 #endif
555 #if CYTHON_COMPILING_IN_PYPY && !defined(PyByteArray_Check)
556  #define PyByteArray_Check(obj) PyObject_TypeCheck(obj, &PyByteArray_Type)
557 #endif
558 #if CYTHON_COMPILING_IN_PYPY && !defined(PyObject_Format)
559  #define PyObject_Format(obj, fmt) PyObject_CallMethod(obj, "__format__", "O", fmt)
560 #endif
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)
565 #else
566  #define __Pyx_PyString_Format(a, b) PyString_Format(a, b)
567 #endif
568 #if PY_MAJOR_VERSION < 3 && !defined(PyObject_ASCII)
569  #define PyObject_ASCII(o) PyObject_Repr(o)
570 #endif
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
579 #endif
580 #endif
581 #if PY_MAJOR_VERSION >= 3
582  #define __Pyx_PyBaseString_Check(obj) PyUnicode_Check(obj)
583  #define __Pyx_PyBaseString_CheckExact(obj) PyUnicode_CheckExact(obj)
584 #else
585  #define __Pyx_PyBaseString_Check(obj) (PyString_Check(obj) || PyUnicode_Check(obj))
586  #define __Pyx_PyBaseString_CheckExact(obj) (PyString_CheckExact(obj) || PyUnicode_CheckExact(obj))
587 #endif
588 #ifndef PySet_CheckExact
589  #define PySet_CheckExact(obj) (Py_TYPE(obj) == &PySet_Type)
590 #endif
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)
594 #else
595  #define __Pyx_SET_REFCNT(obj, refcnt) Py_REFCNT(obj) = (refcnt)
596  #define __Pyx_SET_SIZE(obj, size) Py_SIZE(obj) = (size)
597 #endif
598 #if CYTHON_ASSUME_SAFE_MACROS
599  #define __Pyx_PySequence_SIZE(seq) Py_SIZE(seq)
600 #else
601  #define __Pyx_PySequence_SIZE(seq) PySequence_Size(seq)
602 #endif
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
619 #endif
620 #if PY_MAJOR_VERSION >= 3
621  #define PyBoolObject PyLongObject
622 #endif
623 #if PY_MAJOR_VERSION >= 3 && CYTHON_COMPILING_IN_PYPY
624  #ifndef PyUnicode_InternFromString
625  #define PyUnicode_InternFromString(s) PyUnicode_FromString(s)
626  #endif
627 #endif
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
632 #else
633  #define __Pyx_PyInt_FromHash_t PyInt_FromSsize_t
634  #define __Pyx_PyInt_AsHash_t __Pyx_PyIndex_AsSsize_t
635 #endif
636 #if PY_MAJOR_VERSION >= 3
637  #define __Pyx_PyMethod_New(func, self, klass) ((self) ? ((void)(klass), PyMethod_New(func, self)) : __Pyx_NewRef(func))
638 #else
639  #define __Pyx_PyMethod_New(func, self, klass) PyMethod_New(func, self, klass)
640 #endif
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)
645  #else
646  #define __Pyx_PyType_AsAsync(obj) ((__Pyx_PyAsyncMethodsStruct*) (Py_TYPE(obj)->tp_reserved))
647  #endif
648 #else
649  #define __Pyx_PyType_AsAsync(obj) NULL
650 #endif
651 #ifndef __Pyx_PyAsyncMethodsStruct
652  typedef struct {
653  unaryfunc am_await;
654  unaryfunc am_aiter;
655  unaryfunc am_anext;
656  } __Pyx_PyAsyncMethodsStruct;
657 #endif
658 
659 #if defined(_WIN32) || defined(WIN32) || defined(MS_WINDOWS)
660  #if !defined(_USE_MATH_DEFINES)
661  #define _USE_MATH_DEFINES
662  #endif
663 #endif
664 #include <math.h>
665 #ifdef NAN
666 #define __PYX_NAN() ((float) NAN)
667 #else
668 static CYTHON_INLINE float __PYX_NAN() {
669  float value;
670  memset(&value, 0xFF, sizeof(value));
671  return value;
672 }
673 #endif
674 #if defined(__CYGWIN__) && defined(_LDBL_EQ_DBL)
675 #define __Pyx_truncl trunc
676 #else
677 #define __Pyx_truncl truncl
678 #endif
679 
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; }
684 
685 #ifndef __PYX_EXTERN_C
686  #ifdef __cplusplus
687  #define __PYX_EXTERN_C extern "C"
688  #else
689  #define __PYX_EXTERN_C extern
690  #endif
691 #endif
692 
693 #define __PYX_HAVE__cpostprocessing
694 #define __PYX_HAVE_API__cpostprocessing
695 /* Early includes */
696 #include <string.h>
697 #include <stdio.h>
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"
703 
704  /* NumPy API declarations from "numpy/__init__.pxd" */
705 
706 #include "postprocessing.h"
707 #ifdef _OPENMP
708 #include <omp.h>
709 #endif /* _OPENMP */
710 
711 #if defined(PYREX_WITHOUT_ASSERTIONS) && !defined(CYTHON_WITHOUT_ASSERTIONS)
712 #define CYTHON_WITHOUT_ASSERTIONS
713 #endif
714 
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;
717 
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;
738 }
739 #if defined (__cplusplus) && __cplusplus >= 201103L
740  #include <cstdlib>
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)
752 #else
753  #define __Pyx_sst_abs(value) ((value<0) ? -value : value)
754 #endif
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
765 #else
766  #define __Pyx_PyStr_FromString __Pyx_PyUnicode_FromString
767  #define __Pyx_PyStr_FromStringAndSize __Pyx_PyUnicode_FromStringAndSize
768 #endif
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;
787  while (*u_end++) ;
788  return (size_t)(u_end - u - 1);
789 }
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))
806 #else
807 #define __pyx_PyFloat_AsDouble(x) PyFloat_AsDouble(x)
808 #endif
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))
812 #else
813 #define __Pyx_PyNumber_Int(x) (PyInt_CheckExact(x) ? __Pyx_NewRef(x) : PyNumber_Int(x))
814 #endif
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) {
819  PyObject* sys;
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");
825  if (!sys) goto bad;
826  default_encoding = PyObject_CallMethod(sys, (char*) "getdefaultencoding", NULL);
827  Py_DECREF(sys);
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;
833  } else {
834  char ascii_chars[128];
835  int c;
836  for (c = 0; c < 128; c++) {
837  ascii_chars[c] = c;
838  }
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) {
844  PyErr_Format(
845  PyExc_ValueError,
846  "This module compiled with c_string_encoding=ascii, but default encoding '%.200s' is not a superset of ascii.",
847  default_encoding_c);
848  goto bad;
849  }
850  Py_DECREF(ascii_chars_u);
851  Py_DECREF(ascii_chars_b);
852  }
853  Py_DECREF(default_encoding);
854  return 0;
855 bad:
856  Py_XDECREF(default_encoding);
857  Py_XDECREF(ascii_chars_u);
858  Py_XDECREF(ascii_chars_b);
859  return -1;
860 }
861 #endif
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)
864 #else
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) {
869  PyObject* sys;
870  PyObject* default_encoding = NULL;
871  char* default_encoding_c;
872  sys = PyImport_ImportModule("sys");
873  if (!sys) goto bad;
874  default_encoding = PyObject_CallMethod(sys, (char*) (const char*) "getdefaultencoding", NULL);
875  Py_DECREF(sys);
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);
883  return 0;
884 bad:
885  Py_XDECREF(default_encoding);
886  return -1;
887 }
888 #endif
889 #endif
890 
891 
892 /* Test for GCC > 2.95 */
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)
896 #else /* !__GNUC__ or GCC < 2.95 */
897  #define likely(x) (x)
898  #define unlikely(x) (x)
899 #endif /* __GNUC__ */
900 static CYTHON_INLINE void __Pyx_pretend_to_initialize(void* ptr) { (void)ptr; }
901 
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;
913 
914 /* Header.proto */
915 #if !defined(CYTHON_CCOMPLEX)
916  #if defined(__cplusplus)
917  #define CYTHON_CCOMPLEX 1
918  #elif defined(_Complex_I)
919  #define CYTHON_CCOMPLEX 1
920  #else
921  #define CYTHON_CCOMPLEX 0
922  #endif
923 #endif
924 #if CYTHON_CCOMPLEX
925  #ifdef __cplusplus
926  #include <complex>
927  #else
928  #include <complex.h>
929  #endif
930 #endif
931 #if CYTHON_CCOMPLEX && !defined(__cplusplus) && defined(__sun__) && defined(__GNUC__)
932  #undef _Complex_I
933  #define _Complex_I 1.0fj
934 #endif
935 
936 
937 static const char *__pyx_f[] = {
938  "proteus/cpostprocessing.pyx",
939  "stringsource",
940  "__init__.pxd",
941  "type.pxd",
942 };
943 /* BufferFormatStructs.proto */
944 #define IS_UNSIGNED(type) (((type) -1) > 0)
945 struct __Pyx_StructField_;
946 #define __PYX_BUF_FLAGS_PACKED_STRUCT (1 << 0)
947 typedef struct {
948  const char* name;
949  struct __Pyx_StructField_* fields;
950  size_t size;
951  size_t arraysize[8];
952  int ndim;
953  char typegroup;
954  char is_unsigned;
955  int flags;
956 } __Pyx_TypeInfo;
957 typedef struct __Pyx_StructField_ {
958  __Pyx_TypeInfo* type;
959  const char* name;
960  size_t offset;
961 } __Pyx_StructField;
962 typedef struct {
963  __Pyx_StructField* field;
964  size_t parent_offset;
965 } __Pyx_BufFmt_StackElem;
966 typedef struct {
967  __Pyx_StructField root;
968  __Pyx_BufFmt_StackElem* head;
969  size_t fmt_offset;
970  size_t new_count, enc_count;
971  size_t struct_alignment;
972  int is_complex;
973  char enc_type;
974  char new_packmode;
975  char enc_packmode;
976  char is_valid_array;
977 } __Pyx_BufFmt_Context;
978 
979 
980 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":690
981  * # in Cython to enable them only on the right systems.
982  *
983  * ctypedef npy_int8 int8_t # <<<<<<<<<<<<<<
984  * ctypedef npy_int16 int16_t
985  * ctypedef npy_int32 int32_t
986  */
987 typedef npy_int8 __pyx_t_5numpy_int8_t;
988 
989 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":691
990  *
991  * ctypedef npy_int8 int8_t
992  * ctypedef npy_int16 int16_t # <<<<<<<<<<<<<<
993  * ctypedef npy_int32 int32_t
994  * ctypedef npy_int64 int64_t
995  */
996 typedef npy_int16 __pyx_t_5numpy_int16_t;
997 
998 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":692
999  * ctypedef npy_int8 int8_t
1000  * ctypedef npy_int16 int16_t
1001  * ctypedef npy_int32 int32_t # <<<<<<<<<<<<<<
1002  * ctypedef npy_int64 int64_t
1003  * #ctypedef npy_int96 int96_t
1004  */
1005 typedef npy_int32 __pyx_t_5numpy_int32_t;
1006 
1007 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":693
1008  * ctypedef npy_int16 int16_t
1009  * ctypedef npy_int32 int32_t
1010  * ctypedef npy_int64 int64_t # <<<<<<<<<<<<<<
1011  * #ctypedef npy_int96 int96_t
1012  * #ctypedef npy_int128 int128_t
1013  */
1014 typedef npy_int64 __pyx_t_5numpy_int64_t;
1015 
1016 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":697
1017  * #ctypedef npy_int128 int128_t
1018  *
1019  * ctypedef npy_uint8 uint8_t # <<<<<<<<<<<<<<
1020  * ctypedef npy_uint16 uint16_t
1021  * ctypedef npy_uint32 uint32_t
1022  */
1023 typedef npy_uint8 __pyx_t_5numpy_uint8_t;
1024 
1025 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":698
1026  *
1027  * ctypedef npy_uint8 uint8_t
1028  * ctypedef npy_uint16 uint16_t # <<<<<<<<<<<<<<
1029  * ctypedef npy_uint32 uint32_t
1030  * ctypedef npy_uint64 uint64_t
1031  */
1032 typedef npy_uint16 __pyx_t_5numpy_uint16_t;
1033 
1034 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":699
1035  * ctypedef npy_uint8 uint8_t
1036  * ctypedef npy_uint16 uint16_t
1037  * ctypedef npy_uint32 uint32_t # <<<<<<<<<<<<<<
1038  * ctypedef npy_uint64 uint64_t
1039  * #ctypedef npy_uint96 uint96_t
1040  */
1041 typedef npy_uint32 __pyx_t_5numpy_uint32_t;
1042 
1043 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":700
1044  * ctypedef npy_uint16 uint16_t
1045  * ctypedef npy_uint32 uint32_t
1046  * ctypedef npy_uint64 uint64_t # <<<<<<<<<<<<<<
1047  * #ctypedef npy_uint96 uint96_t
1048  * #ctypedef npy_uint128 uint128_t
1049  */
1050 typedef npy_uint64 __pyx_t_5numpy_uint64_t;
1051 
1052 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":704
1053  * #ctypedef npy_uint128 uint128_t
1054  *
1055  * ctypedef npy_float32 float32_t # <<<<<<<<<<<<<<
1056  * ctypedef npy_float64 float64_t
1057  * #ctypedef npy_float80 float80_t
1058  */
1059 typedef npy_float32 __pyx_t_5numpy_float32_t;
1060 
1061 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":705
1062  *
1063  * ctypedef npy_float32 float32_t
1064  * ctypedef npy_float64 float64_t # <<<<<<<<<<<<<<
1065  * #ctypedef npy_float80 float80_t
1066  * #ctypedef npy_float128 float128_t
1067  */
1068 typedef npy_float64 __pyx_t_5numpy_float64_t;
1069 
1070 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":714
1071  * # The int types are mapped a bit surprising --
1072  * # numpy.int corresponds to 'l' and numpy.long to 'q'
1073  * ctypedef npy_long int_t # <<<<<<<<<<<<<<
1074  * ctypedef npy_longlong long_t
1075  * ctypedef npy_longlong longlong_t
1076  */
1077 typedef npy_long __pyx_t_5numpy_int_t;
1078 
1079 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":715
1080  * # numpy.int corresponds to 'l' and numpy.long to 'q'
1081  * ctypedef npy_long int_t
1082  * ctypedef npy_longlong long_t # <<<<<<<<<<<<<<
1083  * ctypedef npy_longlong longlong_t
1084  *
1085  */
1086 typedef npy_longlong __pyx_t_5numpy_long_t;
1087 
1088 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":716
1089  * ctypedef npy_long int_t
1090  * ctypedef npy_longlong long_t
1091  * ctypedef npy_longlong longlong_t # <<<<<<<<<<<<<<
1092  *
1093  * ctypedef npy_ulong uint_t
1094  */
1095 typedef npy_longlong __pyx_t_5numpy_longlong_t;
1096 
1097 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":718
1098  * ctypedef npy_longlong longlong_t
1099  *
1100  * ctypedef npy_ulong uint_t # <<<<<<<<<<<<<<
1101  * ctypedef npy_ulonglong ulong_t
1102  * ctypedef npy_ulonglong ulonglong_t
1103  */
1104 typedef npy_ulong __pyx_t_5numpy_uint_t;
1105 
1106 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":719
1107  *
1108  * ctypedef npy_ulong uint_t
1109  * ctypedef npy_ulonglong ulong_t # <<<<<<<<<<<<<<
1110  * ctypedef npy_ulonglong ulonglong_t
1111  *
1112  */
1113 typedef npy_ulonglong __pyx_t_5numpy_ulong_t;
1114 
1115 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":720
1116  * ctypedef npy_ulong uint_t
1117  * ctypedef npy_ulonglong ulong_t
1118  * ctypedef npy_ulonglong ulonglong_t # <<<<<<<<<<<<<<
1119  *
1120  * ctypedef npy_intp intp_t
1121  */
1122 typedef npy_ulonglong __pyx_t_5numpy_ulonglong_t;
1123 
1124 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":722
1125  * ctypedef npy_ulonglong ulonglong_t
1126  *
1127  * ctypedef npy_intp intp_t # <<<<<<<<<<<<<<
1128  * ctypedef npy_uintp uintp_t
1129  *
1130  */
1131 typedef npy_intp __pyx_t_5numpy_intp_t;
1132 
1133 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":723
1134  *
1135  * ctypedef npy_intp intp_t
1136  * ctypedef npy_uintp uintp_t # <<<<<<<<<<<<<<
1137  *
1138  * ctypedef npy_double float_t
1139  */
1140 typedef npy_uintp __pyx_t_5numpy_uintp_t;
1141 
1142 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":725
1143  * ctypedef npy_uintp uintp_t
1144  *
1145  * ctypedef npy_double float_t # <<<<<<<<<<<<<<
1146  * ctypedef npy_double double_t
1147  * ctypedef npy_longdouble longdouble_t
1148  */
1149 typedef npy_double __pyx_t_5numpy_float_t;
1150 
1151 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":726
1152  *
1153  * ctypedef npy_double float_t
1154  * ctypedef npy_double double_t # <<<<<<<<<<<<<<
1155  * ctypedef npy_longdouble longdouble_t
1156  *
1157  */
1158 typedef npy_double __pyx_t_5numpy_double_t;
1159 
1160 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":727
1161  * ctypedef npy_double float_t
1162  * ctypedef npy_double double_t
1163  * ctypedef npy_longdouble longdouble_t # <<<<<<<<<<<<<<
1164  *
1165  * ctypedef npy_cfloat cfloat_t
1166  */
1167 typedef npy_longdouble __pyx_t_5numpy_longdouble_t;
1168 /* Declarations.proto */
1169 #if CYTHON_CCOMPLEX
1170  #ifdef __cplusplus
1171  typedef ::std::complex< float > __pyx_t_float_complex;
1172  #else
1173  typedef float _Complex __pyx_t_float_complex;
1174  #endif
1175 #else
1176  typedef struct { float real, imag; } __pyx_t_float_complex;
1177 #endif
1178 static CYTHON_INLINE __pyx_t_float_complex __pyx_t_float_complex_from_parts(float, float);
1179 
1180 /* Declarations.proto */
1181 #if CYTHON_CCOMPLEX
1182  #ifdef __cplusplus
1183  typedef ::std::complex< double > __pyx_t_double_complex;
1184  #else
1185  typedef double _Complex __pyx_t_double_complex;
1186  #endif
1187 #else
1188  typedef struct { double real, imag; } __pyx_t_double_complex;
1189 #endif
1190 static CYTHON_INLINE __pyx_t_double_complex __pyx_t_double_complex_from_parts(double, double);
1191 
1192 
1193 /*--- Type declarations ---*/
1194 struct __pyx_obj_15cpostprocessing_NodeStarFactor;
1195 
1196 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":729
1197  * ctypedef npy_longdouble longdouble_t
1198  *
1199  * ctypedef npy_cfloat cfloat_t # <<<<<<<<<<<<<<
1200  * ctypedef npy_cdouble cdouble_t
1201  * ctypedef npy_clongdouble clongdouble_t
1202  */
1203 typedef npy_cfloat __pyx_t_5numpy_cfloat_t;
1204 
1205 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":730
1206  *
1207  * ctypedef npy_cfloat cfloat_t
1208  * ctypedef npy_cdouble cdouble_t # <<<<<<<<<<<<<<
1209  * ctypedef npy_clongdouble clongdouble_t
1210  *
1211  */
1212 typedef npy_cdouble __pyx_t_5numpy_cdouble_t;
1213 
1214 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":731
1215  * ctypedef npy_cfloat cfloat_t
1216  * ctypedef npy_cdouble cdouble_t
1217  * ctypedef npy_clongdouble clongdouble_t # <<<<<<<<<<<<<<
1218  *
1219  * ctypedef npy_cdouble complex_t
1220  */
1221 typedef npy_clongdouble __pyx_t_5numpy_clongdouble_t;
1222 
1223 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":733
1224  * ctypedef npy_clongdouble clongdouble_t
1225  *
1226  * ctypedef npy_cdouble complex_t # <<<<<<<<<<<<<<
1227  *
1228  * cdef inline object PyArray_MultiIterNew1(a):
1229  */
1230 typedef npy_cdouble __pyx_t_5numpy_complex_t;
1231 
1232 /* "cpostprocessing.pyx":762
1233  *
1234  * # put in data structure for node star solves now
1235  * cdef class NodeStarFactor: # <<<<<<<<<<<<<<
1236  * cdef pp.NodeStarFactorStruct nsf
1237  * def __cinit__(self,
1238  */
1239 struct __pyx_obj_15cpostprocessing_NodeStarFactor {
1240  PyObject_HEAD
1242 };
1243 
1244 
1245 /* --- Runtime support code (head) --- */
1246 /* Refnanny.proto */
1247 #ifndef CYTHON_REFNANNY
1248  #define CYTHON_REFNANNY 0
1249 #endif
1250 #if CYTHON_REFNANNY
1251  typedef struct {
1252  void (*INCREF)(void*, PyObject*, int);
1253  void (*DECREF)(void*, PyObject*, int);
1254  void (*GOTREF)(void*, PyObject*, int);
1255  void (*GIVEREF)(void*, PyObject*, int);
1256  void* (*SetupContext)(const char*, int, const char*);
1257  void (*FinishContext)(void**);
1258  } __Pyx_RefNannyAPIStruct;
1259  static __Pyx_RefNannyAPIStruct *__Pyx_RefNanny = NULL;
1260  static __Pyx_RefNannyAPIStruct *__Pyx_RefNannyImportAPI(const char *modname);
1261  #define __Pyx_RefNannyDeclarations void *__pyx_refnanny = NULL;
1262 #ifdef WITH_THREAD
1263  #define __Pyx_RefNannySetupContext(name, acquire_gil)\
1264  if (acquire_gil) {\
1265  PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure();\
1266  __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__);\
1267  PyGILState_Release(__pyx_gilstate_save);\
1268  } else {\
1269  __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__);\
1270  }
1271 #else
1272  #define __Pyx_RefNannySetupContext(name, acquire_gil)\
1273  __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__)
1274 #endif
1275  #define __Pyx_RefNannyFinishContext()\
1276  __Pyx_RefNanny->FinishContext(&__pyx_refnanny)
1277  #define __Pyx_INCREF(r) __Pyx_RefNanny->INCREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
1278  #define __Pyx_DECREF(r) __Pyx_RefNanny->DECREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
1279  #define __Pyx_GOTREF(r) __Pyx_RefNanny->GOTREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
1280  #define __Pyx_GIVEREF(r) __Pyx_RefNanny->GIVEREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
1281  #define __Pyx_XINCREF(r) do { if((r) != NULL) {__Pyx_INCREF(r); }} while(0)
1282  #define __Pyx_XDECREF(r) do { if((r) != NULL) {__Pyx_DECREF(r); }} while(0)
1283  #define __Pyx_XGOTREF(r) do { if((r) != NULL) {__Pyx_GOTREF(r); }} while(0)
1284  #define __Pyx_XGIVEREF(r) do { if((r) != NULL) {__Pyx_GIVEREF(r);}} while(0)
1285 #else
1286  #define __Pyx_RefNannyDeclarations
1287  #define __Pyx_RefNannySetupContext(name, acquire_gil)
1288  #define __Pyx_RefNannyFinishContext()
1289  #define __Pyx_INCREF(r) Py_INCREF(r)
1290  #define __Pyx_DECREF(r) Py_DECREF(r)
1291  #define __Pyx_GOTREF(r)
1292  #define __Pyx_GIVEREF(r)
1293  #define __Pyx_XINCREF(r) Py_XINCREF(r)
1294  #define __Pyx_XDECREF(r) Py_XDECREF(r)
1295  #define __Pyx_XGOTREF(r)
1296  #define __Pyx_XGIVEREF(r)
1297 #endif
1298 #define __Pyx_XDECREF_SET(r, v) do {\
1299  PyObject *tmp = (PyObject *) r;\
1300  r = v; __Pyx_XDECREF(tmp);\
1301  } while (0)
1302 #define __Pyx_DECREF_SET(r, v) do {\
1303  PyObject *tmp = (PyObject *) r;\
1304  r = v; __Pyx_DECREF(tmp);\
1305  } while (0)
1306 #define __Pyx_CLEAR(r) do { PyObject* tmp = ((PyObject*)(r)); r = NULL; __Pyx_DECREF(tmp);} while(0)
1307 #define __Pyx_XCLEAR(r) do { if((r) != NULL) {PyObject* tmp = ((PyObject*)(r)); r = NULL; __Pyx_DECREF(tmp);}} while(0)
1308 
1309 /* PyObjectGetAttrStr.proto */
1310 #if CYTHON_USE_TYPE_SLOTS
1311 static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStr(PyObject* obj, PyObject* attr_name);
1312 #else
1313 #define __Pyx_PyObject_GetAttrStr(o,n) PyObject_GetAttr(o,n)
1314 #endif
1315 
1316 /* GetBuiltinName.proto */
1317 static PyObject *__Pyx_GetBuiltinName(PyObject *name);
1318 
1319 /* RaiseArgTupleInvalid.proto */
1320 static void __Pyx_RaiseArgtupleInvalid(const char* func_name, int exact,
1321  Py_ssize_t num_min, Py_ssize_t num_max, Py_ssize_t num_found);
1322 
1323 /* RaiseDoubleKeywords.proto */
1324 static void __Pyx_RaiseDoubleKeywordsError(const char* func_name, PyObject* kw_name);
1325 
1326 /* ParseKeywords.proto */
1327 static int __Pyx_ParseOptionalKeywords(PyObject *kwds, PyObject **argnames[],\
1328  PyObject *kwds2, PyObject *values[], Py_ssize_t num_pos_args,\
1329  const char* function_name);
1330 
1331 /* ArgTypeTest.proto */
1332 #define __Pyx_ArgTypeTest(obj, type, none_allowed, name, exact)\
1333  ((likely((Py_TYPE(obj) == type) | (none_allowed && (obj == Py_None)))) ? 1 :\
1334  __Pyx__ArgTypeTest(obj, type, name, exact))
1335 static int __Pyx__ArgTypeTest(PyObject *obj, PyTypeObject *type, const char *name, int exact);
1336 
1337 /* PyObjectCall.proto */
1338 #if CYTHON_COMPILING_IN_CPYTHON
1339 static CYTHON_INLINE PyObject* __Pyx_PyObject_Call(PyObject *func, PyObject *arg, PyObject *kw);
1340 #else
1341 #define __Pyx_PyObject_Call(func, arg, kw) PyObject_Call(func, arg, kw)
1342 #endif
1343 
1344 /* PyThreadStateGet.proto */
1345 #if CYTHON_FAST_THREAD_STATE
1346 #define __Pyx_PyThreadState_declare PyThreadState *__pyx_tstate;
1347 #define __Pyx_PyThreadState_assign __pyx_tstate = __Pyx_PyThreadState_Current;
1348 #define __Pyx_PyErr_Occurred() __pyx_tstate->curexc_type
1349 #else
1350 #define __Pyx_PyThreadState_declare
1351 #define __Pyx_PyThreadState_assign
1352 #define __Pyx_PyErr_Occurred() PyErr_Occurred()
1353 #endif
1354 
1355 /* PyErrFetchRestore.proto */
1356 #if CYTHON_FAST_THREAD_STATE
1357 #define __Pyx_PyErr_Clear() __Pyx_ErrRestore(NULL, NULL, NULL)
1358 #define __Pyx_ErrRestoreWithState(type, value, tb) __Pyx_ErrRestoreInState(PyThreadState_GET(), type, value, tb)
1359 #define __Pyx_ErrFetchWithState(type, value, tb) __Pyx_ErrFetchInState(PyThreadState_GET(), type, value, tb)
1360 #define __Pyx_ErrRestore(type, value, tb) __Pyx_ErrRestoreInState(__pyx_tstate, type, value, tb)
1361 #define __Pyx_ErrFetch(type, value, tb) __Pyx_ErrFetchInState(__pyx_tstate, type, value, tb)
1362 static CYTHON_INLINE void __Pyx_ErrRestoreInState(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb);
1363 static CYTHON_INLINE void __Pyx_ErrFetchInState(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb);
1364 #if CYTHON_COMPILING_IN_CPYTHON
1365 #define __Pyx_PyErr_SetNone(exc) (Py_INCREF(exc), __Pyx_ErrRestore((exc), NULL, NULL))
1366 #else
1367 #define __Pyx_PyErr_SetNone(exc) PyErr_SetNone(exc)
1368 #endif
1369 #else
1370 #define __Pyx_PyErr_Clear() PyErr_Clear()
1371 #define __Pyx_PyErr_SetNone(exc) PyErr_SetNone(exc)
1372 #define __Pyx_ErrRestoreWithState(type, value, tb) PyErr_Restore(type, value, tb)
1373 #define __Pyx_ErrFetchWithState(type, value, tb) PyErr_Fetch(type, value, tb)
1374 #define __Pyx_ErrRestoreInState(tstate, type, value, tb) PyErr_Restore(type, value, tb)
1375 #define __Pyx_ErrFetchInState(tstate, type, value, tb) PyErr_Fetch(type, value, tb)
1376 #define __Pyx_ErrRestore(type, value, tb) PyErr_Restore(type, value, tb)
1377 #define __Pyx_ErrFetch(type, value, tb) PyErr_Fetch(type, value, tb)
1378 #endif
1379 
1380 /* RaiseException.proto */
1381 static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb, PyObject *cause);
1382 
1383 /* IsLittleEndian.proto */
1384 static CYTHON_INLINE int __Pyx_Is_Little_Endian(void);
1385 
1386 /* BufferFormatCheck.proto */
1387 static const char* __Pyx_BufFmt_CheckString(__Pyx_BufFmt_Context* ctx, const char* ts);
1388 static void __Pyx_BufFmt_Init(__Pyx_BufFmt_Context* ctx,
1389  __Pyx_BufFmt_StackElem* stack,
1390  __Pyx_TypeInfo* type);
1391 
1392 /* BufferGetAndValidate.proto */
1393 #define __Pyx_GetBufferAndValidate(buf, obj, dtype, flags, nd, cast, stack)\
1394  ((obj == Py_None || obj == NULL) ?\
1395  (__Pyx_ZeroBuffer(buf), 0) :\
1396  __Pyx__GetBufferAndValidate(buf, obj, dtype, flags, nd, cast, stack))
1397 static int __Pyx__GetBufferAndValidate(Py_buffer* buf, PyObject* obj,
1398  __Pyx_TypeInfo* dtype, int flags, int nd, int cast, __Pyx_BufFmt_StackElem* stack);
1399 static void __Pyx_ZeroBuffer(Py_buffer* buf);
1400 static CYTHON_INLINE void __Pyx_SafeReleaseBuffer(Py_buffer* info);
1401 static Py_ssize_t __Pyx_minusones[] = { -1, -1, -1, -1, -1, -1, -1, -1 };
1402 static Py_ssize_t __Pyx_zeros[] = { 0, 0, 0, 0, 0, 0, 0, 0 };
1403 
1404 /* GetItemInt.proto */
1405 #define __Pyx_GetItemInt(o, i, type, is_signed, to_py_func, is_list, wraparound, boundscheck)\
1406  (__Pyx_fits_Py_ssize_t(i, type, is_signed) ?\
1407  __Pyx_GetItemInt_Fast(o, (Py_ssize_t)i, is_list, wraparound, boundscheck) :\
1408  (is_list ? (PyErr_SetString(PyExc_IndexError, "list index out of range"), (PyObject*)NULL) :\
1409  __Pyx_GetItemInt_Generic(o, to_py_func(i))))
1410 #define __Pyx_GetItemInt_List(o, i, type, is_signed, to_py_func, is_list, wraparound, boundscheck)\
1411  (__Pyx_fits_Py_ssize_t(i, type, is_signed) ?\
1412  __Pyx_GetItemInt_List_Fast(o, (Py_ssize_t)i, wraparound, boundscheck) :\
1413  (PyErr_SetString(PyExc_IndexError, "list index out of range"), (PyObject*)NULL))
1414 static CYTHON_INLINE PyObject *__Pyx_GetItemInt_List_Fast(PyObject *o, Py_ssize_t i,
1415  int wraparound, int boundscheck);
1416 #define __Pyx_GetItemInt_Tuple(o, i, type, is_signed, to_py_func, is_list, wraparound, boundscheck)\
1417  (__Pyx_fits_Py_ssize_t(i, type, is_signed) ?\
1418  __Pyx_GetItemInt_Tuple_Fast(o, (Py_ssize_t)i, wraparound, boundscheck) :\
1419  (PyErr_SetString(PyExc_IndexError, "tuple index out of range"), (PyObject*)NULL))
1420 static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Tuple_Fast(PyObject *o, Py_ssize_t i,
1421  int wraparound, int boundscheck);
1422 static PyObject *__Pyx_GetItemInt_Generic(PyObject *o, PyObject* j);
1423 static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Fast(PyObject *o, Py_ssize_t i,
1424  int is_list, int wraparound, int boundscheck);
1425 
1426 /* ObjectGetItem.proto */
1427 #if CYTHON_USE_TYPE_SLOTS
1428 static CYTHON_INLINE PyObject *__Pyx_PyObject_GetItem(PyObject *obj, PyObject* key);
1429 #else
1430 #define __Pyx_PyObject_GetItem(obj, key) PyObject_GetItem(obj, key)
1431 #endif
1432 
1433 /* BufferIndexError.proto */
1434 static void __Pyx_RaiseBufferIndexError(int axis);
1435 
1436 #define __Pyx_BufPtrStrided2d(type, buf, i0, s0, i1, s1) (type)((char*)buf + i0 * s0 + i1 * s1)
1437 /* GetTopmostException.proto */
1438 #if CYTHON_USE_EXC_INFO_STACK
1439 static _PyErr_StackItem * __Pyx_PyErr_GetTopmostException(PyThreadState *tstate);
1440 #endif
1441 
1442 /* SaveResetException.proto */
1443 #if CYTHON_FAST_THREAD_STATE
1444 #define __Pyx_ExceptionSave(type, value, tb) __Pyx__ExceptionSave(__pyx_tstate, type, value, tb)
1445 static CYTHON_INLINE void __Pyx__ExceptionSave(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb);
1446 #define __Pyx_ExceptionReset(type, value, tb) __Pyx__ExceptionReset(__pyx_tstate, type, value, tb)
1447 static CYTHON_INLINE void __Pyx__ExceptionReset(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb);
1448 #else
1449 #define __Pyx_ExceptionSave(type, value, tb) PyErr_GetExcInfo(type, value, tb)
1450 #define __Pyx_ExceptionReset(type, value, tb) PyErr_SetExcInfo(type, value, tb)
1451 #endif
1452 
1453 /* PyErrExceptionMatches.proto */
1454 #if CYTHON_FAST_THREAD_STATE
1455 #define __Pyx_PyErr_ExceptionMatches(err) __Pyx_PyErr_ExceptionMatchesInState(__pyx_tstate, err)
1456 static CYTHON_INLINE int __Pyx_PyErr_ExceptionMatchesInState(PyThreadState* tstate, PyObject* err);
1457 #else
1458 #define __Pyx_PyErr_ExceptionMatches(err) PyErr_ExceptionMatches(err)
1459 #endif
1460 
1461 /* GetException.proto */
1462 #if CYTHON_FAST_THREAD_STATE
1463 #define __Pyx_GetException(type, value, tb) __Pyx__GetException(__pyx_tstate, type, value, tb)
1464 static int __Pyx__GetException(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb);
1465 #else
1466 static int __Pyx_GetException(PyObject **type, PyObject **value, PyObject **tb);
1467 #endif
1468 
1469 /* PyObject_GenericGetAttrNoDict.proto */
1470 #if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000
1471 static CYTHON_INLINE PyObject* __Pyx_PyObject_GenericGetAttrNoDict(PyObject* obj, PyObject* attr_name);
1472 #else
1473 #define __Pyx_PyObject_GenericGetAttrNoDict PyObject_GenericGetAttr
1474 #endif
1475 
1476 /* PyObject_GenericGetAttr.proto */
1477 #if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000
1478 static PyObject* __Pyx_PyObject_GenericGetAttr(PyObject* obj, PyObject* attr_name);
1479 #else
1480 #define __Pyx_PyObject_GenericGetAttr PyObject_GenericGetAttr
1481 #endif
1482 
1483 /* PyObjectGetAttrStrNoError.proto */
1484 static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStrNoError(PyObject* obj, PyObject* attr_name);
1485 
1486 /* SetupReduce.proto */
1487 static int __Pyx_setup_reduce(PyObject* type_obj);
1488 
1489 /* TypeImport.proto */
1490 #ifndef __PYX_HAVE_RT_ImportType_proto
1491 #define __PYX_HAVE_RT_ImportType_proto
1492 enum __Pyx_ImportType_CheckSize {
1493  __Pyx_ImportType_CheckSize_Error = 0,
1494  __Pyx_ImportType_CheckSize_Warn = 1,
1495  __Pyx_ImportType_CheckSize_Ignore = 2
1496 };
1497 static PyTypeObject *__Pyx_ImportType(PyObject* module, const char *module_name, const char *class_name, size_t size, enum __Pyx_ImportType_CheckSize check_size);
1498 #endif
1499 
1500 /* Import.proto */
1501 static PyObject *__Pyx_Import(PyObject *name, PyObject *from_list, int level);
1502 
1503 /* PyDictVersioning.proto */
1504 #if CYTHON_USE_DICT_VERSIONS && CYTHON_USE_TYPE_SLOTS
1505 #define __PYX_DICT_VERSION_INIT ((PY_UINT64_T) -1)
1506 #define __PYX_GET_DICT_VERSION(dict) (((PyDictObject*)(dict))->ma_version_tag)
1507 #define __PYX_UPDATE_DICT_CACHE(dict, value, cache_var, version_var)\
1508  (version_var) = __PYX_GET_DICT_VERSION(dict);\
1509  (cache_var) = (value);
1510 #define __PYX_PY_DICT_LOOKUP_IF_MODIFIED(VAR, DICT, LOOKUP) {\
1511  static PY_UINT64_T __pyx_dict_version = 0;\
1512  static PyObject *__pyx_dict_cached_value = NULL;\
1513  if (likely(__PYX_GET_DICT_VERSION(DICT) == __pyx_dict_version)) {\
1514  (VAR) = __pyx_dict_cached_value;\
1515  } else {\
1516  (VAR) = __pyx_dict_cached_value = (LOOKUP);\
1517  __pyx_dict_version = __PYX_GET_DICT_VERSION(DICT);\
1518  }\
1519 }
1520 static CYTHON_INLINE PY_UINT64_T __Pyx_get_tp_dict_version(PyObject *obj);
1521 static CYTHON_INLINE PY_UINT64_T __Pyx_get_object_dict_version(PyObject *obj);
1522 static CYTHON_INLINE int __Pyx_object_dict_version_matches(PyObject* obj, PY_UINT64_T tp_dict_version, PY_UINT64_T obj_dict_version);
1523 #else
1524 #define __PYX_GET_DICT_VERSION(dict) (0)
1525 #define __PYX_UPDATE_DICT_CACHE(dict, value, cache_var, version_var)
1526 #define __PYX_PY_DICT_LOOKUP_IF_MODIFIED(VAR, DICT, LOOKUP) (VAR) = (LOOKUP);
1527 #endif
1528 
1529 /* CLineInTraceback.proto */
1530 #ifdef CYTHON_CLINE_IN_TRACEBACK
1531 #define __Pyx_CLineForTraceback(tstate, c_line) (((CYTHON_CLINE_IN_TRACEBACK)) ? c_line : 0)
1532 #else
1533 static int __Pyx_CLineForTraceback(PyThreadState *tstate, int c_line);
1534 #endif
1535 
1536 /* CodeObjectCache.proto */
1537 typedef struct {
1538  PyCodeObject* code_object;
1539  int code_line;
1540 } __Pyx_CodeObjectCacheEntry;
1541 struct __Pyx_CodeObjectCache {
1542  int count;
1543  int max_count;
1544  __Pyx_CodeObjectCacheEntry* entries;
1545 };
1546 static struct __Pyx_CodeObjectCache __pyx_code_cache = {0,0,NULL};
1547 static int __pyx_bisect_code_objects(__Pyx_CodeObjectCacheEntry* entries, int count, int code_line);
1548 static PyCodeObject *__pyx_find_code_object(int code_line);
1549 static void __pyx_insert_code_object(int code_line, PyCodeObject* code_object);
1550 
1551 /* AddTraceback.proto */
1552 static void __Pyx_AddTraceback(const char *funcname, int c_line,
1553  int py_line, const char *filename);
1554 
1555 /* BufferStructDeclare.proto */
1556 typedef struct {
1557  Py_ssize_t shape, strides, suboffsets;
1558 } __Pyx_Buf_DimInfo;
1559 typedef struct {
1560  size_t refcount;
1561  Py_buffer pybuffer;
1562 } __Pyx_Buffer;
1563 typedef struct {
1564  __Pyx_Buffer *rcbuffer;
1565  char *data;
1566  __Pyx_Buf_DimInfo diminfo[8];
1567 } __Pyx_LocalBuf_ND;
1568 
1569 #if PY_MAJOR_VERSION < 3
1570  static int __Pyx_GetBuffer(PyObject *obj, Py_buffer *view, int flags);
1571  static void __Pyx_ReleaseBuffer(Py_buffer *view);
1572 #else
1573  #define __Pyx_GetBuffer PyObject_GetBuffer
1574  #define __Pyx_ReleaseBuffer PyBuffer_Release
1575 #endif
1576 
1577 
1578 /* GCCDiagnostics.proto */
1579 #if defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 6))
1580 #define __Pyx_HAS_GCC_DIAGNOSTIC
1581 #endif
1582 
1583 /* RealImag.proto */
1584 #if CYTHON_CCOMPLEX
1585  #ifdef __cplusplus
1586  #define __Pyx_CREAL(z) ((z).real())
1587  #define __Pyx_CIMAG(z) ((z).imag())
1588  #else
1589  #define __Pyx_CREAL(z) (__real__(z))
1590  #define __Pyx_CIMAG(z) (__imag__(z))
1591  #endif
1592 #else
1593  #define __Pyx_CREAL(z) ((z).real)
1594  #define __Pyx_CIMAG(z) ((z).imag)
1595 #endif
1596 #if defined(__cplusplus) && CYTHON_CCOMPLEX\
1597  && (defined(_WIN32) || defined(__clang__) || (defined(__GNUC__) && (__GNUC__ >= 5 || __GNUC__ == 4 && __GNUC_MINOR__ >= 4 )) || __cplusplus >= 201103)
1598  #define __Pyx_SET_CREAL(z,x) ((z).real(x))
1599  #define __Pyx_SET_CIMAG(z,y) ((z).imag(y))
1600 #else
1601  #define __Pyx_SET_CREAL(z,x) __Pyx_CREAL(z) = (x)
1602  #define __Pyx_SET_CIMAG(z,y) __Pyx_CIMAG(z) = (y)
1603 #endif
1604 
1605 /* Arithmetic.proto */
1606 #if CYTHON_CCOMPLEX
1607  #define __Pyx_c_eq_float(a, b) ((a)==(b))
1608  #define __Pyx_c_sum_float(a, b) ((a)+(b))
1609  #define __Pyx_c_diff_float(a, b) ((a)-(b))
1610  #define __Pyx_c_prod_float(a, b) ((a)*(b))
1611  #define __Pyx_c_quot_float(a, b) ((a)/(b))
1612  #define __Pyx_c_neg_float(a) (-(a))
1613  #ifdef __cplusplus
1614  #define __Pyx_c_is_zero_float(z) ((z)==(float)0)
1615  #define __Pyx_c_conj_float(z) (::std::conj(z))
1616  #if 1
1617  #define __Pyx_c_abs_float(z) (::std::abs(z))
1618  #define __Pyx_c_pow_float(a, b) (::std::pow(a, b))
1619  #endif
1620  #else
1621  #define __Pyx_c_is_zero_float(z) ((z)==0)
1622  #define __Pyx_c_conj_float(z) (conjf(z))
1623  #if 1
1624  #define __Pyx_c_abs_float(z) (cabsf(z))
1625  #define __Pyx_c_pow_float(a, b) (cpowf(a, b))
1626  #endif
1627  #endif
1628 #else
1629  static CYTHON_INLINE int __Pyx_c_eq_float(__pyx_t_float_complex, __pyx_t_float_complex);
1630  static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_sum_float(__pyx_t_float_complex, __pyx_t_float_complex);
1631  static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_diff_float(__pyx_t_float_complex, __pyx_t_float_complex);
1632  static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_prod_float(__pyx_t_float_complex, __pyx_t_float_complex);
1633  static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_quot_float(__pyx_t_float_complex, __pyx_t_float_complex);
1634  static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_neg_float(__pyx_t_float_complex);
1635  static CYTHON_INLINE int __Pyx_c_is_zero_float(__pyx_t_float_complex);
1636  static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_conj_float(__pyx_t_float_complex);
1637  #if 1
1638  static CYTHON_INLINE float __Pyx_c_abs_float(__pyx_t_float_complex);
1639  static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_pow_float(__pyx_t_float_complex, __pyx_t_float_complex);
1640  #endif
1641 #endif
1642 
1643 /* Arithmetic.proto */
1644 #if CYTHON_CCOMPLEX
1645  #define __Pyx_c_eq_double(a, b) ((a)==(b))
1646  #define __Pyx_c_sum_double(a, b) ((a)+(b))
1647  #define __Pyx_c_diff_double(a, b) ((a)-(b))
1648  #define __Pyx_c_prod_double(a, b) ((a)*(b))
1649  #define __Pyx_c_quot_double(a, b) ((a)/(b))
1650  #define __Pyx_c_neg_double(a) (-(a))
1651  #ifdef __cplusplus
1652  #define __Pyx_c_is_zero_double(z) ((z)==(double)0)
1653  #define __Pyx_c_conj_double(z) (::std::conj(z))
1654  #if 1
1655  #define __Pyx_c_abs_double(z) (::std::abs(z))
1656  #define __Pyx_c_pow_double(a, b) (::std::pow(a, b))
1657  #endif
1658  #else
1659  #define __Pyx_c_is_zero_double(z) ((z)==0)
1660  #define __Pyx_c_conj_double(z) (conj(z))
1661  #if 1
1662  #define __Pyx_c_abs_double(z) (cabs(z))
1663  #define __Pyx_c_pow_double(a, b) (cpow(a, b))
1664  #endif
1665  #endif
1666 #else
1667  static CYTHON_INLINE int __Pyx_c_eq_double(__pyx_t_double_complex, __pyx_t_double_complex);
1668  static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_sum_double(__pyx_t_double_complex, __pyx_t_double_complex);
1669  static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_diff_double(__pyx_t_double_complex, __pyx_t_double_complex);
1670  static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_prod_double(__pyx_t_double_complex, __pyx_t_double_complex);
1671  static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_quot_double(__pyx_t_double_complex, __pyx_t_double_complex);
1672  static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_neg_double(__pyx_t_double_complex);
1673  static CYTHON_INLINE int __Pyx_c_is_zero_double(__pyx_t_double_complex);
1674  static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_conj_double(__pyx_t_double_complex);
1675  #if 1
1676  static CYTHON_INLINE double __Pyx_c_abs_double(__pyx_t_double_complex);
1677  static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_pow_double(__pyx_t_double_complex, __pyx_t_double_complex);
1678  #endif
1679 #endif
1680 
1681 /* CIntFromPy.proto */
1682 static CYTHON_INLINE int __Pyx_PyInt_As_int(PyObject *);
1683 
1684 /* CIntToPy.proto */
1685 static CYTHON_INLINE PyObject* __Pyx_PyInt_From_Py_intptr_t(Py_intptr_t value);
1686 
1687 /* CIntToPy.proto */
1688 static CYTHON_INLINE PyObject* __Pyx_PyInt_From_int(int value);
1689 
1690 /* CIntToPy.proto */
1691 static CYTHON_INLINE PyObject* __Pyx_PyInt_From_long(long value);
1692 
1693 /* CIntFromPy.proto */
1694 static CYTHON_INLINE long __Pyx_PyInt_As_long(PyObject *);
1695 
1696 /* FastTypeChecks.proto */
1697 #if CYTHON_COMPILING_IN_CPYTHON
1698 #define __Pyx_TypeCheck(obj, type) __Pyx_IsSubtype(Py_TYPE(obj), (PyTypeObject *)type)
1699 static CYTHON_INLINE int __Pyx_IsSubtype(PyTypeObject *a, PyTypeObject *b);
1700 static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches(PyObject *err, PyObject *type);
1701 static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches2(PyObject *err, PyObject *type1, PyObject *type2);
1702 #else
1703 #define __Pyx_TypeCheck(obj, type) PyObject_TypeCheck(obj, (PyTypeObject *)type)
1704 #define __Pyx_PyErr_GivenExceptionMatches(err, type) PyErr_GivenExceptionMatches(err, type)
1705 #define __Pyx_PyErr_GivenExceptionMatches2(err, type1, type2) (PyErr_GivenExceptionMatches(err, type1) || PyErr_GivenExceptionMatches(err, type2))
1706 #endif
1707 #define __Pyx_PyException_Check(obj) __Pyx_TypeCheck(obj, PyExc_Exception)
1708 
1709 /* CheckBinaryVersion.proto */
1710 static int __Pyx_check_binary_version(void);
1711 
1712 /* InitStrings.proto */
1713 static int __Pyx_InitStrings(__Pyx_StringTabEntry *t);
1714 
1715 
1716 /* Module declarations from 'cpython.buffer' */
1717 
1718 /* Module declarations from 'libc.string' */
1719 
1720 /* Module declarations from 'libc.stdio' */
1721 
1722 /* Module declarations from '__builtin__' */
1723 
1724 /* Module declarations from 'cpython.type' */
1725 static PyTypeObject *__pyx_ptype_7cpython_4type_type = 0;
1726 
1727 /* Module declarations from 'cpython' */
1728 
1729 /* Module declarations from 'cpython.object' */
1730 
1731 /* Module declarations from 'cpython.ref' */
1732 
1733 /* Module declarations from 'cpython.mem' */
1734 
1735 /* Module declarations from 'numpy' */
1736 
1737 /* Module declarations from 'numpy' */
1738 static PyTypeObject *__pyx_ptype_5numpy_dtype = 0;
1739 static PyTypeObject *__pyx_ptype_5numpy_flatiter = 0;
1740 static PyTypeObject *__pyx_ptype_5numpy_broadcast = 0;
1741 static PyTypeObject *__pyx_ptype_5numpy_ndarray = 0;
1742 static PyTypeObject *__pyx_ptype_5numpy_generic = 0;
1743 static PyTypeObject *__pyx_ptype_5numpy_number = 0;
1744 static PyTypeObject *__pyx_ptype_5numpy_integer = 0;
1745 static PyTypeObject *__pyx_ptype_5numpy_signedinteger = 0;
1746 static PyTypeObject *__pyx_ptype_5numpy_unsignedinteger = 0;
1747 static PyTypeObject *__pyx_ptype_5numpy_inexact = 0;
1748 static PyTypeObject *__pyx_ptype_5numpy_floating = 0;
1749 static PyTypeObject *__pyx_ptype_5numpy_complexfloating = 0;
1750 static PyTypeObject *__pyx_ptype_5numpy_flexible = 0;
1751 static PyTypeObject *__pyx_ptype_5numpy_character = 0;
1752 static PyTypeObject *__pyx_ptype_5numpy_ufunc = 0;
1753 
1754 /* Module declarations from 'postprocessing' */
1755 
1756 /* Module declarations from 'cpostprocessing' */
1757 static PyTypeObject *__pyx_ptype_15cpostprocessing_NodeStarFactor = 0;
1758 static __Pyx_TypeInfo __Pyx_TypeInfo_int = { "int", NULL, sizeof(int), { 0 }, 0, IS_UNSIGNED(int) ? 'U' : 'I', IS_UNSIGNED(int), 0 };
1759 #define __Pyx_MODULE_NAME "cpostprocessing"
1760 extern int __pyx_module_is_main_cpostprocessing;
1761 int __pyx_module_is_main_cpostprocessing = 0;
1762 
1763 /* Implementation of 'cpostprocessing' */
1764 static PyObject *__pyx_builtin_range;
1765 static PyObject *__pyx_builtin_TypeError;
1766 static PyObject *__pyx_builtin_ImportError;
1767 static const char __pyx_k_I[] = "I";
1768 static const char __pyx_k_a[] = "a";
1769 static const char __pyx_k_f[] = "f";
1770 static const char __pyx_k_k[] = "k";
1771 static const char __pyx_k_n[] = "n";
1772 static const char __pyx_k_r[] = "r";
1773 static const char __pyx_k_u[] = "u";
1774 static const char __pyx_k_w[] = "w";
1775 static const char __pyx_k_x[] = "x";
1776 static const char __pyx_k_dS[] = "dS";
1777 static const char __pyx_k_dx[] = "dx";
1778 static const char __pyx_k_mt[] = "mt";
1779 static const char __pyx_k_np[] = "np";
1780 static const char __pyx_k_ebN[] = "ebN";
1781 static const char __pyx_k_phi[] = "phi";
1782 static const char __pyx_k_q_v[] = "q_v";
1783 static const char __pyx_k_detJ[] = "detJ";
1784 static const char __pyx_k_flux[] = "flux";
1785 static const char __pyx_k_main[] = "__main__";
1786 static const char __pyx_k_name[] = "__name__";
1787 static const char __pyx_k_pwcV[] = "pwcV";
1788 static const char __pyx_k_pwcW[] = "pwcW";
1789 static const char __pyx_k_size[] = "size";
1790 static const char __pyx_k_test[] = "__test__";
1791 static const char __pyx_k_alpha[] = "alpha";
1792 static const char __pyx_k_ebq_n[] = "ebq_n";
1793 static const char __pyx_k_ebq_v[] = "ebq_v";
1794 static const char __pyx_k_gradu[] = "gradu";
1795 static const char __pyx_k_numpy[] = "numpy";
1796 static const char __pyx_k_range[] = "range";
1797 static const char __pyx_k_vdofs[] = "vdofs";
1798 static const char __pyx_k_colind[] = "colind";
1799 static const char __pyx_k_degree[] = "degree";
1800 static const char __pyx_k_ebqe_v[] = "ebqe_v";
1801 static const char __pyx_k_import[] = "__import__";
1802 static const char __pyx_k_nSpace[] = "nSpace";
1803 static const char __pyx_k_quad_a[] = "quad_a";
1804 static const char __pyx_k_quad_f[] = "quad_f";
1805 static const char __pyx_k_reduce[] = "__reduce__";
1806 static const char __pyx_k_rowptr[] = "rowptr";
1807 static const char __pyx_k_v_ebqe[] = "v_ebqe";
1808 static const char __pyx_k_w_dS_f[] = "w_dS_f";
1809 static const char __pyx_k_w_dV_m[] = "w_dV_m";
1810 static const char __pyx_k_w_dV_r[] = "w_dV_r";
1811 static const char __pyx_k_x_ebqe[] = "x_ebqe";
1812 static const char __pyx_k_gradphi[] = "gradphi";
1813 static const char __pyx_k_nPoints[] = "nPoints";
1814 static const char __pyx_k_q_vdofs[] = "q_vdofs";
1815 static const char __pyx_k_getstate[] = "__getstate__";
1816 static const char __pyx_k_grad_phi[] = "grad_phi";
1817 static const char __pyx_k_p1_vdofs[] = "p1_vdofs";
1818 static const char __pyx_k_residual[] = "residual";
1819 static const char __pyx_k_rt0vdofs[] = "rt0vdofs";
1820 static const char __pyx_k_setstate[] = "__setstate__";
1821 static const char __pyx_k_vAverage[] = "vAverage";
1822 static const char __pyx_k_velocity[] = "velocity";
1823 static const char __pyx_k_TypeError[] = "TypeError";
1824 static const char __pyx_k_abs_det_J[] = "abs_det_J";
1825 static const char __pyx_k_dofMapl2g[] = "dofMapl2g";
1826 static const char __pyx_k_edgeFlags[] = "edgeFlags";
1827 static const char __pyx_k_nodeArray[] = "nodeArray";
1828 static const char __pyx_k_reduce_ex[] = "__reduce_ex__";
1829 static const char __pyx_k_v_element[] = "v_element";
1830 static const char __pyx_k_x_element[] = "x_element";
1831 static const char __pyx_k_q_velocity[] = "q_velocity";
1832 static const char __pyx_k_sqrt_det_g[] = "sqrt_det_g";
1833 static const char __pyx_k_updateCoef[] = "updateCoef";
1834 static const char __pyx_k_ImportError[] = "ImportError";
1835 static const char __pyx_k_alphaFactor[] = "alphaFactor";
1836 static const char __pyx_k_subdomain_U[] = "subdomain_U";
1837 static const char __pyx_k_buildBDM2rhs[] = "buildBDM2rhs";
1838 static const char __pyx_k_ebq_velocity[] = "ebq_velocity";
1839 static const char __pyx_k_elementNodes[] = "elementNodes";
1840 static const char __pyx_k_max_nN_owned[] = "max_nN_owned";
1841 static const char __pyx_k_nNodes_owned[] = "nNodes_owned";
1842 static const char __pyx_k_permutations[] = "permutations";
1843 static const char __pyx_k_q_basis_vals[] = "q_basis_vals";
1844 static const char __pyx_k_rt0potential[] = "rt0potential";
1845 static const char __pyx_k_ebqe_velocity[] = "ebqe_velocity";
1846 static const char __pyx_k_internalNodes[] = "internalNodes";
1847 static const char __pyx_k_nElements_dof[] = "nElements_dof";
1848 static const char __pyx_k_nVDOF_element[] = "nVDOF_element";
1849 static const char __pyx_k_reduce_cython[] = "__reduce_cython__";
1850 static const char __pyx_k_vConservative[] = "vConservative";
1851 static const char __pyx_k_BDMmat_element[] = "BDMmat_element";
1852 static const char __pyx_k_NodeStarFactor[] = "NodeStarFactor";
1853 static const char __pyx_k_fluxCorrection[] = "fluxCorrection";
1854 static const char __pyx_k_nElements_node[] = "nElements_node";
1855 static const char __pyx_k_nVDOFs_element[] = "nVDOFs_element";
1856 static const char __pyx_k_nodeStarFactor[] = "nodeStarFactor";
1857 static const char __pyx_k_w_int_div_free[] = "w_int_div_free";
1858 static const char __pyx_k_cpostprocessing[] = "cpostprocessing";
1859 static const char __pyx_k_diffusionTensor[] = "diffusionTensor";
1860 static const char __pyx_k_dofStarElements[] = "dofStarElements";
1861 static const char __pyx_k_ebq_global_flux[] = "ebq_global_flux";
1862 static const char __pyx_k_ebq_v_par_local[] = "ebq_v_par_local";
1863 static const char __pyx_k_elementResidual[] = "elementResidual";
1864 static const char __pyx_k_piola_trial_fun[] = "piola_trial_fun";
1865 static const char __pyx_k_setstate_cython[] = "__setstate_cython__";
1866 static const char __pyx_k_nFreeDOF_element[] = "nFreeDOF_element";
1867 static const char __pyx_k_nodeStarElements[] = "nodeStarElements";
1868 static const char __pyx_k_rt0vdofs_element[] = "rt0vdofs_element";
1869 static const char __pyx_k_velocity_element[] = "velocity_element";
1870 static const char __pyx_k_w_int_test_grads[] = "w_int_test_grads";
1871 static const char __pyx_k_advectiveVelocity[] = "advectiveVelocity";
1872 static const char __pyx_k_elementNodesArray[] = "elementNodesArray";
1873 static const char __pyx_k_element_locations[] = "element_locations";
1874 static const char __pyx_k_fluxBoundaryNodes[] = "fluxBoundaryNodes";
1875 static const char __pyx_k_freeLocal_element[] = "freeLocal_element";
1876 static const char __pyx_k_nQuadraturePoints[] = "nQuadraturePoints";
1877 static const char __pyx_k_sunWheelerGSsweep[] = "sunWheelerGSsweep";
1878 static const char __pyx_k_u_elementBoundary[] = "u_elementBoundary";
1879 static const char __pyx_k_v_elementBoundary[] = "v_elementBoundary";
1880 static const char __pyx_k_x_elementBoundary[] = "x_elementBoundary";
1881 static const char __pyx_k_addAverageToParVec[] = "addAverageToParVec";
1882 static const char __pyx_k_cline_in_traceback[] = "cline_in_traceback";
1883 static const char __pyx_k_elementBarycenters[] = "elementBarycenters";
1884 static const char __pyx_k_elementResidualPWL[] = "elementResidualPWL";
1885 static const char __pyx_k_nDOF_trial_element[] = "nDOF_trial_element";
1886 static const char __pyx_k_nElementBoundaries[] = "nElementBoundaries";
1887 static const char __pyx_k_w_interior_divfree[] = "w_interior_divfree";
1888 static const char __pyx_k_aElementQuadWeights[] = "aElementQuadWeights";
1889 static const char __pyx_k_ebq_global_velocity[] = "ebq_global_velocity";
1890 static const char __pyx_k_ebq_velocityAverage[] = "ebq_velocityAverage";
1891 static const char __pyx_k_BDMmatPivots_element[] = "BDMmatPivots_element";
1892 static const char __pyx_k_conservationResidual[] = "conservationResidual";
1893 static const char __pyx_k_flux_elementBoundary[] = "flux_elementBoundary";
1894 static const char __pyx_k_w_interior_gradients[] = "w_interior_gradients";
1895 static const char __pyx_k_fluxElementBoundaries[] = "fluxElementBoundaries";
1896 static const char __pyx_k_nodeStarElementsArray[] = "nodeStarElementsArray";
1897 static const char __pyx_k_vConservative_element[] = "vConservative_element";
1898 static const char __pyx_k_elementBoundariesArray[] = "elementBoundariesArray";
1899 static const char __pyx_k_dofStarElementNeighbors[] = "dofStarElementNeighbors";
1900 static const char __pyx_k_elementBoundaryElements[] = "elementBoundaryElements";
1901 static const char __pyx_k_computeFluxCorrectionPWC[] = "computeFluxCorrectionPWC";
1902 static const char __pyx_k_nodeStarElementNeighbors[] = "nodeStarElementNeighbors";
1903 static const char __pyx_k_solveLocalBDM1projection[] = "solveLocalBDM1projection";
1904 static const char __pyx_k_solveLocalBDM2projection[] = "solveLocalBDM2projection";
1905 static const char __pyx_k_v_elementBoundary_global[] = "v_elementBoundary_global";
1906 static const char __pyx_k_x_elementBoundary_global[] = "x_elementBoundary_global";
1907 static const char __pyx_k_exteriorElementBoundaries[] = "exteriorElementBoundaries";
1908 static const char __pyx_k_interiorElementBoundaries[] = "interiorElementBoundaries";
1909 static const char __pyx_k_skipflag_elementBoundaries[] = "skipflag_elementBoundaries";
1910 static const char __pyx_k_uQuadratureWeights_element[] = "uQuadratureWeights_element";
1911 static const char __pyx_k_calculateElementResidualPWL[] = "calculateElementResidualPWL";
1912 static const char __pyx_k_getElementRT0velocityValues[] = "getElementRT0velocityValues";
1913 static const char __pyx_k_proteus_cpostprocessing_pyx[] = "proteus/cpostprocessing.pyx";
1914 static const char __pyx_k_calculateConservationFluxPWL[] = "calculateConservationFluxPWL";
1915 static const char __pyx_k_elementBoundaryElementsArray[] = "elementBoundaryElementsArray";
1916 static const char __pyx_k_fluxCorrectionVelocityUpdate[] = "fluxCorrectionVelocityUpdate";
1917 static const char __pyx_k_subdomain_U_copy_global2local[] = "_subdomain_U_copy_global2local";
1918 static const char __pyx_k_subdomain_U_copy_local2global[] = "_subdomain_U_copy_local2global";
1919 static const char __pyx_k_exteriorElementBoundariesArray[] = "exteriorElementBoundariesArray";
1920 static const char __pyx_k_nodeStarElementsNeighborsArray[] = "nodeStarElementsNeighborsArray";
1921 static const char __pyx_k_postProcessRT0velocityFromP1nc[] = "postProcessRT0velocityFromP1nc";
1922 static const char __pyx_k_exteriorElementBoundariesToSkip[] = "exteriorElementBoundariesToSkip";
1923 static const char __pyx_k_numpy_core_multiarray_failed_to[] = "numpy.core.multiarray failed to import";
1924 static const char __pyx_k_postProcessRT0potentialFromP1nc[] = "postProcessRT0potentialFromP1nc";
1925 static const char __pyx_k_buildLocalBDM1projectionMatrices[] = "buildLocalBDM1projectionMatrices";
1926 static const char __pyx_k_buildLocalBDM2projectionMatrices[] = "buildLocalBDM2projectionMatrices";
1927 static const char __pyx_k_calculateConservationFluxPWL_noN[] = "calculateConservationFluxPWL_noNeumannFix";
1928 static const char __pyx_k_calculateConservationFluxPWL_opt[] = "calculateConservationFluxPWL_opt";
1929 static const char __pyx_k_calculateConservationJacobianPWL[] = "calculateConservationJacobianPWL";
1930 static const char __pyx_k_calculateConservationResidualGlo[] = "calculateConservationResidualGlobalBoundaries";
1931 static const char __pyx_k_calculateConservationResidualPWL[] = "calculateConservationResidualPWL";
1932 static const char __pyx_k_copyElementBoundaryVelocityToPar[] = "copyElementBoundaryVelocityToParVec";
1933 static const char __pyx_k_copyParVecToElementBoundaryVeloc[] = "copyParVecToElementBoundaryVelocity";
1934 static const char __pyx_k_elementBoundaryLocalElementBound[] = "elementBoundaryLocalElementBoundaries";
1935 static const char __pyx_k_elementBoundaryQuadratureWeights[] = "elementBoundaryQuadratureWeights";
1936 static const char __pyx_k_factorLocalBDM1projectionMatrice[] = "factorLocalBDM1projectionMatrices";
1937 static const char __pyx_k_factorLocalBDM2projectionMatrice[] = "factorLocalBDM2projectionMatrices";
1938 static const char __pyx_k_getElementBDM1velocityValuesLagr[] = "getElementBDM1velocityValuesLagrangeRep";
1939 static const char __pyx_k_getElementBDM2velocityValuesLagr[] = "getElementBDM2velocityValuesLagrangeRep";
1940 static const char __pyx_k_getElementBoundaryBDM1velocityVa[] = "getElementBoundaryBDM1velocityValuesLagrangeRep";
1941 static const char __pyx_k_getElementBoundaryRT0velocityVal[] = "getElementBoundaryRT0velocityValues";
1942 static const char __pyx_k_getElementLDGvelocityValuesLagra[] = "getElementLDGvelocityValuesLagrangeRep";
1943 static const char __pyx_k_getElementRT0velocityValuesFluxR[] = "getElementRT0velocityValuesFluxRep";
1944 static const char __pyx_k_getGlobalElementBoundaryBDM1velo[] = "getGlobalElementBoundaryBDM1velocityValuesLagrangeRep";
1945 static const char __pyx_k_getGlobalElementBoundaryRT0veloc[] = "getGlobalElementBoundaryRT0velocityValues";
1946 static const char __pyx_k_getGlobalExteriorElementBoundary[] = "getGlobalExteriorElementBoundaryRT0velocityValues";
1947 static const char __pyx_k_getRT0velocityValuesFluxRep_arbi[] = "getRT0velocityValuesFluxRep_arbitraryElementMembership";
1948 static const char __pyx_k_no_default___reduce___due_to_non[] = "no default __reduce__ due to non-trivial __cinit__";
1949 static const char __pyx_k_numpy_core_umath_failed_to_impor[] = "numpy.core.umath failed to import";
1950 static const char __pyx_k_postProcessRT0velocityFromP1nc_s[] = "postProcessRT0velocityFromP1nc_sd";
1951 static const char __pyx_k_projectElementBoundaryFluxToRT0f[] = "projectElementBoundaryFluxToRT0fluxRep";
1952 static const char __pyx_k_projectElementBoundaryVelocityTo[] = "projectElementBoundaryVelocityToRT0fluxRep";
1953 static const char __pyx_k_solveLocalBDM1projectionFromFlux[] = "solveLocalBDM1projectionFromFlux";
1954 static const char __pyx_k_uQuadratureWeights_elementBounda[] = "uQuadratureWeights_elementBoundary";
1955 static const char __pyx_k_updateAdvectiveVelocityPointEval[] = "updateAdvectiveVelocityPointEval";
1956 static const char __pyx_k_updateDiffusiveVelocityPointEval[] = "updateDiffusiveVelocityPointEval";
1957 static const char __pyx_k_updateRT0velocityWithAveragedPot[] = "updateRT0velocityWithAveragedPotentialP1nc";
1958 static const char __pyx_k_updateSelectedExteriorElementBou[] = "updateSelectedExteriorElementBoundaryFlux";
1959 static const char __pyx_k_postProcessRT0potentialFromP1nc_2[] = "postProcessRT0potentialFromP1nc_sd";
1960 static const char __pyx_k_calculateConservationJacobianPWL_2[] = "calculateConservationJacobianPWL_opt";
1961 static const char __pyx_k_calculateConservationJacobianPWL_3[] = "calculateConservationJacobianPWL_interiorBoundaries";
1962 static const char __pyx_k_calculateConservationResidualPWL_2[] = "calculateConservationResidualPWL_opt";
1963 static const char __pyx_k_calculateConservationResidualPWL_3[] = "calculateConservationResidualPWL_primative";
1964 static const char __pyx_k_calculateConservationResidualPWL_4[] = "calculateConservationResidualPWL_interiorBoundaries";
1965 static const char __pyx_k_getElementBoundaryRT0velocityVal_2[] = "getElementBoundaryRT0velocityValuesFluxRep";
1966 static const char __pyx_k_getGlobalElementBoundaryRT0veloc_2[] = "getGlobalElementBoundaryRT0velocityValuesFluxRep";
1967 static const char __pyx_k_getGlobalExteriorElementBoundary_2[] = "getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep";
1968 static const char __pyx_k_getGlobalExteriorElementBoundary_3[] = "getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep";
1969 static const char __pyx_k_updateDiffusiveVelocityPointEval_2[] = "updateDiffusiveVelocityPointEval_sd";
1970 static const char __pyx_k_updateRT0velocityWithAveragedPot_2[] = "updateRT0velocityWithAveragedPotentialP1nc_sd";
1971 static PyObject *__pyx_n_s_BDMmatPivots_element;
1972 static PyObject *__pyx_n_s_BDMmat_element;
1973 static PyObject *__pyx_n_s_I;
1974 static PyObject *__pyx_n_s_ImportError;
1975 static PyObject *__pyx_n_s_NodeStarFactor;
1976 static PyObject *__pyx_n_s_TypeError;
1977 static PyObject *__pyx_n_s_a;
1978 static PyObject *__pyx_n_s_aElementQuadWeights;
1979 static PyObject *__pyx_n_s_abs_det_J;
1980 static PyObject *__pyx_n_s_addAverageToParVec;
1981 static PyObject *__pyx_n_s_advectiveVelocity;
1982 static PyObject *__pyx_n_s_alpha;
1983 static PyObject *__pyx_n_s_alphaFactor;
1984 static PyObject *__pyx_n_s_buildBDM2rhs;
1985 static PyObject *__pyx_n_s_buildLocalBDM1projectionMatrices;
1986 static PyObject *__pyx_n_s_buildLocalBDM2projectionMatrices;
1987 static PyObject *__pyx_n_s_calculateConservationFluxPWL;
1988 static PyObject *__pyx_n_s_calculateConservationFluxPWL_noN;
1989 static PyObject *__pyx_n_s_calculateConservationFluxPWL_opt;
1990 static PyObject *__pyx_n_s_calculateConservationJacobianPWL;
1991 static PyObject *__pyx_n_s_calculateConservationJacobianPWL_2;
1992 static PyObject *__pyx_n_s_calculateConservationJacobianPWL_3;
1993 static PyObject *__pyx_n_s_calculateConservationResidualGlo;
1994 static PyObject *__pyx_n_s_calculateConservationResidualPWL;
1995 static PyObject *__pyx_n_s_calculateConservationResidualPWL_2;
1996 static PyObject *__pyx_n_s_calculateConservationResidualPWL_3;
1997 static PyObject *__pyx_n_s_calculateConservationResidualPWL_4;
1998 static PyObject *__pyx_n_s_calculateElementResidualPWL;
1999 static PyObject *__pyx_n_s_cline_in_traceback;
2000 static PyObject *__pyx_n_s_colind;
2001 static PyObject *__pyx_n_s_computeFluxCorrectionPWC;
2002 static PyObject *__pyx_n_s_conservationResidual;
2003 static PyObject *__pyx_n_s_copyElementBoundaryVelocityToPar;
2004 static PyObject *__pyx_n_s_copyParVecToElementBoundaryVeloc;
2005 static PyObject *__pyx_n_s_cpostprocessing;
2006 static PyObject *__pyx_n_s_dS;
2007 static PyObject *__pyx_n_s_degree;
2008 static PyObject *__pyx_n_s_detJ;
2009 static PyObject *__pyx_n_s_diffusionTensor;
2010 static PyObject *__pyx_n_s_dofMapl2g;
2011 static PyObject *__pyx_n_s_dofStarElementNeighbors;
2012 static PyObject *__pyx_n_s_dofStarElements;
2013 static PyObject *__pyx_n_s_dx;
2014 static PyObject *__pyx_n_s_ebN;
2015 static PyObject *__pyx_n_s_ebq_global_flux;
2016 static PyObject *__pyx_n_s_ebq_global_velocity;
2017 static PyObject *__pyx_n_s_ebq_n;
2018 static PyObject *__pyx_n_s_ebq_v;
2019 static PyObject *__pyx_n_s_ebq_v_par_local;
2020 static PyObject *__pyx_n_s_ebq_velocity;
2021 static PyObject *__pyx_n_s_ebq_velocityAverage;
2022 static PyObject *__pyx_n_s_ebqe_v;
2023 static PyObject *__pyx_n_s_ebqe_velocity;
2024 static PyObject *__pyx_n_s_edgeFlags;
2025 static PyObject *__pyx_n_s_elementBarycenters;
2026 static PyObject *__pyx_n_s_elementBoundariesArray;
2027 static PyObject *__pyx_n_s_elementBoundaryElements;
2028 static PyObject *__pyx_n_s_elementBoundaryElementsArray;
2029 static PyObject *__pyx_n_s_elementBoundaryLocalElementBound;
2030 static PyObject *__pyx_n_s_elementBoundaryQuadratureWeights;
2031 static PyObject *__pyx_n_s_elementNodes;
2032 static PyObject *__pyx_n_s_elementNodesArray;
2033 static PyObject *__pyx_n_s_elementResidual;
2034 static PyObject *__pyx_n_s_elementResidualPWL;
2035 static PyObject *__pyx_n_s_element_locations;
2036 static PyObject *__pyx_n_s_exteriorElementBoundaries;
2037 static PyObject *__pyx_n_s_exteriorElementBoundariesArray;
2038 static PyObject *__pyx_n_s_exteriorElementBoundariesToSkip;
2039 static PyObject *__pyx_n_s_f;
2040 static PyObject *__pyx_n_s_factorLocalBDM1projectionMatrice;
2041 static PyObject *__pyx_n_s_factorLocalBDM2projectionMatrice;
2042 static PyObject *__pyx_n_s_flux;
2043 static PyObject *__pyx_n_s_fluxBoundaryNodes;
2044 static PyObject *__pyx_n_s_fluxCorrection;
2045 static PyObject *__pyx_n_s_fluxCorrectionVelocityUpdate;
2046 static PyObject *__pyx_n_s_fluxElementBoundaries;
2047 static PyObject *__pyx_n_s_flux_elementBoundary;
2048 static PyObject *__pyx_n_s_freeLocal_element;
2049 static PyObject *__pyx_n_s_getElementBDM1velocityValuesLagr;
2050 static PyObject *__pyx_n_s_getElementBDM2velocityValuesLagr;
2051 static PyObject *__pyx_n_s_getElementBoundaryBDM1velocityVa;
2052 static PyObject *__pyx_n_s_getElementBoundaryRT0velocityVal;
2053 static PyObject *__pyx_n_s_getElementBoundaryRT0velocityVal_2;
2054 static PyObject *__pyx_n_s_getElementLDGvelocityValuesLagra;
2055 static PyObject *__pyx_n_s_getElementRT0velocityValues;
2056 static PyObject *__pyx_n_s_getElementRT0velocityValuesFluxR;
2057 static PyObject *__pyx_n_s_getGlobalElementBoundaryBDM1velo;
2058 static PyObject *__pyx_n_s_getGlobalElementBoundaryRT0veloc;
2059 static PyObject *__pyx_n_s_getGlobalElementBoundaryRT0veloc_2;
2060 static PyObject *__pyx_n_s_getGlobalExteriorElementBoundary;
2061 static PyObject *__pyx_n_s_getGlobalExteriorElementBoundary_2;
2062 static PyObject *__pyx_n_s_getGlobalExteriorElementBoundary_3;
2063 static PyObject *__pyx_n_s_getRT0velocityValuesFluxRep_arbi;
2064 static PyObject *__pyx_n_s_getstate;
2065 static PyObject *__pyx_n_s_grad_phi;
2066 static PyObject *__pyx_n_s_gradphi;
2067 static PyObject *__pyx_n_s_gradu;
2068 static PyObject *__pyx_n_s_import;
2069 static PyObject *__pyx_n_s_interiorElementBoundaries;
2070 static PyObject *__pyx_n_s_internalNodes;
2071 static PyObject *__pyx_n_s_k;
2072 static PyObject *__pyx_n_s_main;
2073 static PyObject *__pyx_n_s_max_nN_owned;
2074 static PyObject *__pyx_n_s_mt;
2075 static PyObject *__pyx_n_s_n;
2076 static PyObject *__pyx_n_s_nDOF_trial_element;
2077 static PyObject *__pyx_n_s_nElementBoundaries;
2078 static PyObject *__pyx_n_s_nElements_dof;
2079 static PyObject *__pyx_n_s_nElements_node;
2080 static PyObject *__pyx_n_s_nFreeDOF_element;
2081 static PyObject *__pyx_n_s_nNodes_owned;
2082 static PyObject *__pyx_n_s_nPoints;
2083 static PyObject *__pyx_n_s_nQuadraturePoints;
2084 static PyObject *__pyx_n_s_nSpace;
2085 static PyObject *__pyx_n_s_nVDOF_element;
2086 static PyObject *__pyx_n_s_nVDOFs_element;
2087 static PyObject *__pyx_n_s_name;
2088 static PyObject *__pyx_kp_s_no_default___reduce___due_to_non;
2089 static PyObject *__pyx_n_s_nodeArray;
2090 static PyObject *__pyx_n_s_nodeStarElementNeighbors;
2091 static PyObject *__pyx_n_s_nodeStarElements;
2092 static PyObject *__pyx_n_s_nodeStarElementsArray;
2093 static PyObject *__pyx_n_s_nodeStarElementsNeighborsArray;
2094 static PyObject *__pyx_n_s_nodeStarFactor;
2095 static PyObject *__pyx_n_s_np;
2096 static PyObject *__pyx_n_s_numpy;
2097 static PyObject *__pyx_kp_s_numpy_core_multiarray_failed_to;
2098 static PyObject *__pyx_kp_s_numpy_core_umath_failed_to_impor;
2099 static PyObject *__pyx_n_s_p1_vdofs;
2100 static PyObject *__pyx_n_s_permutations;
2101 static PyObject *__pyx_n_s_phi;
2102 static PyObject *__pyx_n_s_piola_trial_fun;
2103 static PyObject *__pyx_n_s_postProcessRT0potentialFromP1nc;
2104 static PyObject *__pyx_n_s_postProcessRT0potentialFromP1nc_2;
2105 static PyObject *__pyx_n_s_postProcessRT0velocityFromP1nc;
2106 static PyObject *__pyx_n_s_postProcessRT0velocityFromP1nc_s;
2107 static PyObject *__pyx_n_s_projectElementBoundaryFluxToRT0f;
2108 static PyObject *__pyx_n_s_projectElementBoundaryVelocityTo;
2109 static PyObject *__pyx_kp_s_proteus_cpostprocessing_pyx;
2110 static PyObject *__pyx_n_s_pwcV;
2111 static PyObject *__pyx_n_s_pwcW;
2112 static PyObject *__pyx_n_s_q_basis_vals;
2113 static PyObject *__pyx_n_s_q_v;
2114 static PyObject *__pyx_n_s_q_vdofs;
2115 static PyObject *__pyx_n_s_q_velocity;
2116 static PyObject *__pyx_n_s_quad_a;
2117 static PyObject *__pyx_n_s_quad_f;
2118 static PyObject *__pyx_n_s_r;
2119 static PyObject *__pyx_n_s_range;
2120 static PyObject *__pyx_n_s_reduce;
2121 static PyObject *__pyx_n_s_reduce_cython;
2122 static PyObject *__pyx_n_s_reduce_ex;
2123 static PyObject *__pyx_n_s_residual;
2124 static PyObject *__pyx_n_s_rowptr;
2125 static PyObject *__pyx_n_s_rt0potential;
2126 static PyObject *__pyx_n_s_rt0vdofs;
2127 static PyObject *__pyx_n_s_rt0vdofs_element;
2128 static PyObject *__pyx_n_s_setstate;
2129 static PyObject *__pyx_n_s_setstate_cython;
2130 static PyObject *__pyx_n_s_size;
2131 static PyObject *__pyx_n_s_skipflag_elementBoundaries;
2132 static PyObject *__pyx_n_s_solveLocalBDM1projection;
2133 static PyObject *__pyx_n_s_solveLocalBDM1projectionFromFlux;
2134 static PyObject *__pyx_n_s_solveLocalBDM2projection;
2135 static PyObject *__pyx_n_s_sqrt_det_g;
2136 static PyObject *__pyx_n_s_subdomain_U;
2137 static PyObject *__pyx_n_s_subdomain_U_copy_global2local;
2138 static PyObject *__pyx_n_s_subdomain_U_copy_local2global;
2139 static PyObject *__pyx_n_s_sunWheelerGSsweep;
2140 static PyObject *__pyx_n_s_test;
2141 static PyObject *__pyx_n_s_u;
2142 static PyObject *__pyx_n_s_uQuadratureWeights_element;
2143 static PyObject *__pyx_n_s_uQuadratureWeights_elementBounda;
2144 static PyObject *__pyx_n_s_u_elementBoundary;
2145 static PyObject *__pyx_n_s_updateAdvectiveVelocityPointEval;
2146 static PyObject *__pyx_n_s_updateCoef;
2147 static PyObject *__pyx_n_s_updateDiffusiveVelocityPointEval;
2148 static PyObject *__pyx_n_s_updateDiffusiveVelocityPointEval_2;
2149 static PyObject *__pyx_n_s_updateRT0velocityWithAveragedPot;
2150 static PyObject *__pyx_n_s_updateRT0velocityWithAveragedPot_2;
2151 static PyObject *__pyx_n_s_updateSelectedExteriorElementBou;
2152 static PyObject *__pyx_n_s_vAverage;
2153 static PyObject *__pyx_n_s_vConservative;
2154 static PyObject *__pyx_n_s_vConservative_element;
2155 static PyObject *__pyx_n_s_v_ebqe;
2156 static PyObject *__pyx_n_s_v_element;
2157 static PyObject *__pyx_n_s_v_elementBoundary;
2158 static PyObject *__pyx_n_s_v_elementBoundary_global;
2159 static PyObject *__pyx_n_s_vdofs;
2160 static PyObject *__pyx_n_s_velocity;
2161 static PyObject *__pyx_n_s_velocity_element;
2162 static PyObject *__pyx_n_s_w;
2163 static PyObject *__pyx_n_s_w_dS_f;
2164 static PyObject *__pyx_n_s_w_dV_m;
2165 static PyObject *__pyx_n_s_w_dV_r;
2166 static PyObject *__pyx_n_s_w_int_div_free;
2167 static PyObject *__pyx_n_s_w_int_test_grads;
2168 static PyObject *__pyx_n_s_w_interior_divfree;
2169 static PyObject *__pyx_n_s_w_interior_gradients;
2170 static PyObject *__pyx_n_s_x;
2171 static PyObject *__pyx_n_s_x_ebqe;
2172 static PyObject *__pyx_n_s_x_element;
2173 static PyObject *__pyx_n_s_x_elementBoundary;
2174 static PyObject *__pyx_n_s_x_elementBoundary_global;
2175 static PyObject *__pyx_pf_15cpostprocessing_postProcessRT0velocityFromP1nc(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_nFreeDOF_element, PyArrayObject *__pyx_v_freeLocal_element, PyArrayObject *__pyx_v_detJ, PyArrayObject *__pyx_v_sqrt_det_g, PyArrayObject *__pyx_v_n, PyArrayObject *__pyx_v_elementBarycenters, PyArrayObject *__pyx_v_quad_a, PyArrayObject *__pyx_v_quad_f, PyArrayObject *__pyx_v_w_dV_r, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_gradu, PyArrayObject *__pyx_v_a, PyArrayObject *__pyx_v_f, PyArrayObject *__pyx_v_r, PyArrayObject *__pyx_v_rt0vdofs, PyArrayObject *__pyx_v_w_dV_m, PyArrayObject *__pyx_v_mt); /* proto */
2176 static PyObject *__pyx_pf_15cpostprocessing_2postProcessRT0velocityFromP1nc_sd(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_rowptr, PyArrayObject *__pyx_v_colind, PyArrayObject *__pyx_v_nFreeDOF_element, PyArrayObject *__pyx_v_freeLocal_element, PyArrayObject *__pyx_v_detJ, PyArrayObject *__pyx_v_sqrt_det_g, PyArrayObject *__pyx_v_n, PyArrayObject *__pyx_v_elementBarycenters, PyArrayObject *__pyx_v_quad_a, PyArrayObject *__pyx_v_quad_f, PyArrayObject *__pyx_v_w_dV_r, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_gradu, PyArrayObject *__pyx_v_a, PyArrayObject *__pyx_v_f, PyArrayObject *__pyx_v_r, PyArrayObject *__pyx_v_rt0vdofs, PyArrayObject *__pyx_v_w_dV_m, PyArrayObject *__pyx_v_mt); /* proto */
2177 static PyObject *__pyx_pf_15cpostprocessing_4updateRT0velocityWithAveragedPotentialP1nc(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_detJ, PyArrayObject *__pyx_v_quad_a, PyArrayObject *__pyx_v_phi, PyArrayObject *__pyx_v_gradphi, PyArrayObject *__pyx_v_a, PyArrayObject *__pyx_v_rt0vdofs_element); /* proto */
2178 static PyObject *__pyx_pf_15cpostprocessing_6updateRT0velocityWithAveragedPotentialP1nc_sd(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_rowptr, PyArrayObject *__pyx_v_colind, PyArrayObject *__pyx_v_detJ, PyArrayObject *__pyx_v_quad_a, PyArrayObject *__pyx_v_phi, PyArrayObject *__pyx_v_gradphi, PyArrayObject *__pyx_v_a, PyArrayObject *__pyx_v_rt0vdofs_element); /* proto */
2179 static PyObject *__pyx_pf_15cpostprocessing_8getElementRT0velocityValues(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_x_element, PyArrayObject *__pyx_v_rt0vdofs_element, PyArrayObject *__pyx_v_v_element); /* proto */
2180 static PyObject *__pyx_pf_15cpostprocessing_10getElementBoundaryRT0velocityValues(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_x_elementBoundary, PyArrayObject *__pyx_v_rt0vdofs_element, PyArrayObject *__pyx_v_v_elementBoundary); /* proto */
2181 static PyObject *__pyx_pf_15cpostprocessing_12getGlobalElementBoundaryRT0velocityValues(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_elementBoundaryElementsArray, PyArrayObject *__pyx_v_x_elementBoundary_global, PyArrayObject *__pyx_v_rt0vdofs_element, PyArrayObject *__pyx_v_v_elementBoundary_global); /* proto */
2182 static PyObject *__pyx_pf_15cpostprocessing_14getGlobalExteriorElementBoundaryRT0velocityValues(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_exteriorElementBoundariesArray, PyArrayObject *__pyx_v_elementBoundaryElementsArray, PyArrayObject *__pyx_v_x_elementBoundary_global, PyArrayObject *__pyx_v_rt0vdofs_element, PyArrayObject *__pyx_v_v_elementBoundary_global); /* proto */
2183 static PyObject *__pyx_pf_15cpostprocessing_16postProcessRT0potentialFromP1nc(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_uQuadratureWeights_element, PyArrayObject *__pyx_v_elementBarycenters, PyArrayObject *__pyx_v_aElementQuadWeights, PyArrayObject *__pyx_v_detJ, CYTHON_UNUSED PyArrayObject *__pyx_v_uQuadratureWeights_elementBoundary, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_gradu, PyArrayObject *__pyx_v_x_elementBoundary, PyArrayObject *__pyx_v_u_elementBoundary, PyArrayObject *__pyx_v_n, PyArrayObject *__pyx_v_a, PyArrayObject *__pyx_v_f, PyArrayObject *__pyx_v_r, PyArrayObject *__pyx_v_rt0vdofs, PyArrayObject *__pyx_v_rt0potential); /* proto */
2184 static PyObject *__pyx_pf_15cpostprocessing_18postProcessRT0potentialFromP1nc_sd(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_rowptr, PyArrayObject *__pyx_v_colind, PyArrayObject *__pyx_v_uQuadratureWeights_element, PyArrayObject *__pyx_v_elementBarycenters, PyArrayObject *__pyx_v_aElementQuadWeights, PyArrayObject *__pyx_v_detJ, CYTHON_UNUSED PyArrayObject *__pyx_v_uQuadratureWeights_elementBoundary, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_gradu, PyArrayObject *__pyx_v_x_elementBoundary, PyArrayObject *__pyx_v_u_elementBoundary, PyArrayObject *__pyx_v_n, PyArrayObject *__pyx_v_a, PyArrayObject *__pyx_v_f, PyArrayObject *__pyx_v_r, PyArrayObject *__pyx_v_rt0vdofs, PyArrayObject *__pyx_v_rt0potential); /* proto */
2185 static PyObject *__pyx_pf_15cpostprocessing_20buildLocalBDM1projectionMatrices(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_w_dS_f, PyArrayObject *__pyx_v_ebq_n, PyArrayObject *__pyx_v_ebq_v, PyArrayObject *__pyx_v_BDMmat_element); /* proto */
2186 static PyObject *__pyx_pf_15cpostprocessing_22buildLocalBDM2projectionMatrices(CYTHON_UNUSED PyObject *__pyx_self, int __pyx_v_degree, PyArrayObject *__pyx_v_w_dS_f, PyArrayObject *__pyx_v_ebq_n, PyArrayObject *__pyx_v_ebq_v, PyArrayObject *__pyx_v_q_basis_vals, PyArrayObject *__pyx_v_w_int_test_grads, PyArrayObject *__pyx_v_w_int_div_free, PyArrayObject *__pyx_v_piola_trial_fun, PyArrayObject *__pyx_v_edgeFlags, PyArrayObject *__pyx_v_BDMmat_element); /* proto */
2187 static PyObject *__pyx_pf_15cpostprocessing_24factorLocalBDM1projectionMatrices(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_BDMmat_element, PyArrayObject *__pyx_v_BDMmatPivots_element); /* proto */
2188 static PyObject *__pyx_pf_15cpostprocessing_26factorLocalBDM2projectionMatrices(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_BDMmat_element, PyArrayObject *__pyx_v_BDMmatPivots_element); /* proto */
2189 static PyObject *__pyx_pf_15cpostprocessing_28solveLocalBDM1projection(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_BDMmat_element, PyArrayObject *__pyx_v_BDMmatPivots_element, PyArrayObject *__pyx_v_w_dS_f, PyArrayObject *__pyx_v_ebq_n, PyArrayObject *__pyx_v_ebq_velocity, PyArrayObject *__pyx_v_q_vdofs); /* proto */
2190 static PyObject *__pyx_pf_15cpostprocessing_30solveLocalBDM2projection(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_BDMmat_element, PyArrayObject *__pyx_v_BDMmatPivots_element, PyArrayObject *__pyx_v_w_dS_f, PyArrayObject *__pyx_v_ebq_n, PyArrayObject *__pyx_v_w_interior_gradients, PyArrayObject *__pyx_v_ebq_velocity, PyArrayObject *__pyx_v_q_velocity, PyArrayObject *__pyx_v_q_vdofs); /* proto */
2191 static PyObject *__pyx_pf_15cpostprocessing_32buildBDM2rhs(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_BDMmat_element, PyArrayObject *__pyx_v_BDMmatPivots_element, PyArrayObject *__pyx_v_w_dS_f, PyArrayObject *__pyx_v_ebq_n, PyArrayObject *__pyx_v_w_interior_gradients, PyArrayObject *__pyx_v_w_interior_divfree, PyArrayObject *__pyx_v_ebq_velocity, PyArrayObject *__pyx_v_q_velocity, PyArrayObject *__pyx_v_q_vdofs, PyArrayObject *__pyx_v_edgeFlags); /* proto */
2192 static PyObject *__pyx_pf_15cpostprocessing_34solveLocalBDM1projectionFromFlux(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_BDMmat_element, PyArrayObject *__pyx_v_BDMmatPivots_element, PyArrayObject *__pyx_v_elementBoundaryElementsArray, PyArrayObject *__pyx_v_elementBoundariesArray, PyArrayObject *__pyx_v_w_dS_f, PyArrayObject *__pyx_v_ebq_global_flux, PyArrayObject *__pyx_v_q_vdofs); /* proto */
2193 static PyObject *__pyx_pf_15cpostprocessing_36getElementBDM1velocityValuesLagrangeRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_q_v, PyArrayObject *__pyx_v_p1_vdofs, PyArrayObject *__pyx_v_q_velocity); /* proto */
2194 static PyObject *__pyx_pf_15cpostprocessing_38getElementBDM2velocityValuesLagrangeRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_q_v, PyArrayObject *__pyx_v_p1_vdofs, PyArrayObject *__pyx_v_q_velocity); /* proto */
2195 static PyObject *__pyx_pf_15cpostprocessing_40getElementLDGvelocityValuesLagrangeRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_q_v, PyArrayObject *__pyx_v_vdofs, PyArrayObject *__pyx_v_q_velocity); /* proto */
2196 static PyObject *__pyx_pf_15cpostprocessing_42getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_elementBoundaryElementsArray, PyArrayObject *__pyx_v_exteriorElementBoundariesArray, PyArrayObject *__pyx_v_ebqe_v, PyArrayObject *__pyx_v_p1_vdofs, PyArrayObject *__pyx_v_ebqe_velocity); /* proto */
2197 static PyObject *__pyx_pf_15cpostprocessing_44getGlobalElementBoundaryBDM1velocityValuesLagrangeRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_elementBoundaryElementsArray, PyArrayObject *__pyx_v_exteriorElementBoundariesArray, PyArrayObject *__pyx_v_ebqe_v, PyArrayObject *__pyx_v_p1_vdofs, PyArrayObject *__pyx_v_ebq_global_velocity); /* proto */
2198 static PyObject *__pyx_pf_15cpostprocessing_46getElementBoundaryBDM1velocityValuesLagrangeRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_elementBoundaryElementsArray, PyArrayObject *__pyx_v_exteriorElementBoundariesArray, PyArrayObject *__pyx_v_ebq_v, PyArrayObject *__pyx_v_p1_vdofs, PyArrayObject *__pyx_v_ebq_velocity); /* proto */
2199 static PyObject *__pyx_pf_15cpostprocessing_48projectElementBoundaryVelocityToRT0fluxRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_elementBoundaryQuadratureWeights, PyArrayObject *__pyx_v_n, PyArrayObject *__pyx_v_v_elementBoundary, PyArrayObject *__pyx_v_rt0vdofs_element); /* proto */
2200 static PyObject *__pyx_pf_15cpostprocessing_50projectElementBoundaryFluxToRT0fluxRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_elementBoundaryElementsArray, PyArrayObject *__pyx_v_elementBoundariesArray, PyArrayObject *__pyx_v_elementBoundaryQuadratureWeights, PyArrayObject *__pyx_v_flux_elementBoundary, PyArrayObject *__pyx_v_rt0vdofs_element); /* proto */
2201 static PyObject *__pyx_pf_15cpostprocessing_52getElementRT0velocityValuesFluxRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_nodeArray, PyArrayObject *__pyx_v_elementNodesArray, PyArrayObject *__pyx_v_abs_det_J, PyArrayObject *__pyx_v_x_element, PyArrayObject *__pyx_v_rt0vdofs_element, PyArrayObject *__pyx_v_v_element); /* proto */
2202 static PyObject *__pyx_pf_15cpostprocessing_54getElementBoundaryRT0velocityValuesFluxRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_nodeArray, PyArrayObject *__pyx_v_elementNodesArray, PyArrayObject *__pyx_v_abs_det_J, PyArrayObject *__pyx_v_x_elementBoundary, PyArrayObject *__pyx_v_rt0vdofs_element, PyArrayObject *__pyx_v_v_elementBoundary); /* proto */
2203 static PyObject *__pyx_pf_15cpostprocessing_56getGlobalElementBoundaryRT0velocityValuesFluxRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_nodeArray, PyArrayObject *__pyx_v_elementNodesArray, PyArrayObject *__pyx_v_elementBoundaryElementsArray, PyArrayObject *__pyx_v_abs_det_J, PyArrayObject *__pyx_v_x_elementBoundary_global, PyArrayObject *__pyx_v_rt0vdofs_element, PyArrayObject *__pyx_v_v_elementBoundary_global); /* proto */
2204 static PyObject *__pyx_pf_15cpostprocessing_58getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_nodeArray, PyArrayObject *__pyx_v_elementNodesArray, PyArrayObject *__pyx_v_elementBoundaryElementsArray, PyArrayObject *__pyx_v_exteriorElementBoundariesArray, PyArrayObject *__pyx_v_abs_det_J, PyArrayObject *__pyx_v_x_ebqe, PyArrayObject *__pyx_v_rt0vdofs_element, PyArrayObject *__pyx_v_v_ebqe); /* proto */
2205 static PyObject *__pyx_pf_15cpostprocessing_60getRT0velocityValuesFluxRep_arbitraryElementMembership(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_nodeArray, PyArrayObject *__pyx_v_elementNodesArray, PyArrayObject *__pyx_v_abs_det_J, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_element_locations, PyArrayObject *__pyx_v_rt0vdofs_element, PyArrayObject *__pyx_v_v_element); /* proto */
2206 static PyObject *__pyx_pf_15cpostprocessing_62fluxCorrectionVelocityUpdate(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_interiorElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries, PyArrayObject *__pyx_v_dS, PyArrayObject *__pyx_v_n, PyArrayObject *__pyx_v_fluxCorrection, PyArrayObject *__pyx_v_velocity, PyArrayObject *__pyx_v_velocity_element); /* proto */
2207 static PyObject *__pyx_pf_15cpostprocessing_64computeFluxCorrectionPWC(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_interiorElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_pwcW, PyArrayObject *__pyx_v_pwcV, PyArrayObject *__pyx_v_fluxCorrection); /* proto */
2208 static PyObject *__pyx_pf_15cpostprocessing_66sunWheelerGSsweep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_interiorElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries, PyArrayObject *__pyx_v_dS, PyArrayObject *__pyx_v_n, PyArrayObject *__pyx_v_sqrt_det_g, PyArrayObject *__pyx_v_alphaFactor, PyArrayObject *__pyx_v_fluxCorrection, PyArrayObject *__pyx_v_conservationResidual); /* proto */
2209 static int __pyx_pf_15cpostprocessing_14NodeStarFactor___cinit__(struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_self, PyArrayObject *__pyx_v_nElements_node, PyArrayObject *__pyx_v_nodeStarElementsArray, PyArrayObject *__pyx_v_nodeStarElementsNeighborsArray); /* proto */
2210 static void __pyx_pf_15cpostprocessing_14NodeStarFactor_2__dealloc__(struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_self); /* proto */
2211 static PyObject *__pyx_pf_15cpostprocessing_14NodeStarFactor_4setU(struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_self, double __pyx_v_val); /* proto */
2212 static PyObject *__pyx_pf_15cpostprocessing_14NodeStarFactor_6copyData(struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_self, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_other); /* proto */
2213 static PyObject *__pyx_pf_15cpostprocessing_14NodeStarFactor_8__reduce_cython__(CYTHON_UNUSED struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_self); /* proto */
2214 static PyObject *__pyx_pf_15cpostprocessing_14NodeStarFactor_10__setstate_cython__(CYTHON_UNUSED struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v___pyx_state); /* proto */
2215 static PyObject *__pyx_pf_15cpostprocessing_68calculateConservationResidualPWL(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_interiorElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries, PyArrayObject *__pyx_v_elementNodes, PyArrayObject *__pyx_v_dofMapl2g, PyArrayObject *__pyx_v_nodeStarElements, PyArrayObject *__pyx_v_nodeStarElementNeighbors, PyArrayObject *__pyx_v_nElements_node, PyArrayObject *__pyx_v_fluxElementBoundaries, PyArrayObject *__pyx_v_elementResidual, PyArrayObject *__pyx_v_vAverage, PyArrayObject *__pyx_v_dx, PyArrayObject *__pyx_v_w, PyArrayObject *__pyx_v_n, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor, PyArrayObject *__pyx_v_conservationResidual, PyArrayObject *__pyx_v_vConservative, PyArrayObject *__pyx_v_vConservative_element); /* proto */
2216 static PyObject *__pyx_pf_15cpostprocessing_70calculateConservationJacobianPWL(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_interiorElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries, PyArrayObject *__pyx_v_elementNodes, PyArrayObject *__pyx_v_dofMapl2g, PyArrayObject *__pyx_v_dofStarElements, PyArrayObject *__pyx_v_dofStarElementNeighbors, PyArrayObject *__pyx_v_nElements_dof, PyArrayObject *__pyx_v_internalNodes, PyArrayObject *__pyx_v_fluxElementBoundaries, PyArrayObject *__pyx_v_fluxBoundaryNodes, PyArrayObject *__pyx_v_w, PyArrayObject *__pyx_v_n, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor); /* proto */
2217 static PyObject *__pyx_pf_15cpostprocessing_72calculateConservationFluxPWL(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_nElements_node, PyArrayObject *__pyx_v_internalNodes, PyArrayObject *__pyx_v_fluxBoundaryNodes, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor); /* proto */
2218 static PyObject *__pyx_pf_15cpostprocessing_74calculateConservationFluxPWL_noNeumannFix(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_nElements_node, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor); /* proto */
2219 static PyObject *__pyx_pf_15cpostprocessing_76calculateConservationResidualPWL_opt(CYTHON_UNUSED PyObject *__pyx_self, int __pyx_v_nNodes_owned, PyArrayObject *__pyx_v_interiorElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries, PyArrayObject *__pyx_v_elementNodes, PyArrayObject *__pyx_v_nodeStarElements, PyArrayObject *__pyx_v_nodeStarElementNeighbors, PyArrayObject *__pyx_v_nElements_node, PyArrayObject *__pyx_v_fluxElementBoundaries, PyArrayObject *__pyx_v_elementResidual, PyArrayObject *__pyx_v_vAverage, PyArrayObject *__pyx_v_dx, PyArrayObject *__pyx_v_w, PyArrayObject *__pyx_v_n, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor, PyArrayObject *__pyx_v_conservationResidual, PyArrayObject *__pyx_v_vConservative, PyArrayObject *__pyx_v_vConservative_element); /* proto */
2220 static PyObject *__pyx_pf_15cpostprocessing_78calculateConservationResidualPWL_primative(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_interiorElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries, PyArrayObject *__pyx_v_skipflag_elementBoundaries, PyArrayObject *__pyx_v_elementResidual, PyArrayObject *__pyx_v_dx, PyArrayObject *__pyx_v_n, PyArrayObject *__pyx_v_conservationResidual, PyArrayObject *__pyx_v_vConservative); /* proto */
2221 static PyObject *__pyx_pf_15cpostprocessing_80calculateConservationJacobianPWL_opt(CYTHON_UNUSED PyObject *__pyx_self, int __pyx_v_nNodes_owned, PyArrayObject *__pyx_v_interiorElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries, PyArrayObject *__pyx_v_elementNodes, PyArrayObject *__pyx_v_nodeStarElements, PyArrayObject *__pyx_v_nodeStarElementNeighbors, PyArrayObject *__pyx_v_nElements_node, PyArrayObject *__pyx_v_internalNodes, PyArrayObject *__pyx_v_fluxElementBoundaries, PyArrayObject *__pyx_v_fluxBoundaryNodes, PyArrayObject *__pyx_v_w, PyArrayObject *__pyx_v_n, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor); /* proto */
2222 static PyObject *__pyx_pf_15cpostprocessing_82calculateConservationFluxPWL_opt(CYTHON_UNUSED PyObject *__pyx_self, int __pyx_v_nNodes_owned, PyArrayObject *__pyx_v_nElements_node, PyArrayObject *__pyx_v_internalNodes, PyArrayObject *__pyx_v_fluxBoundaryNodes, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor); /* proto */
2223 static PyObject *__pyx_pf_15cpostprocessing_84calculateConservationResidualPWL_interiorBoundaries(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_interiorElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries, PyArrayObject *__pyx_v_elementNodes, PyArrayObject *__pyx_v_nodeStarElements, PyArrayObject *__pyx_v_nodeStarElementNeighbors, PyArrayObject *__pyx_v_nElements_node, PyArrayObject *__pyx_v_fluxElementBoundaries, PyArrayObject *__pyx_v_elementResidual, PyArrayObject *__pyx_v_vAverage, PyArrayObject *__pyx_v_dx, PyArrayObject *__pyx_v_w, PyArrayObject *__pyx_v_n, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor, PyArrayObject *__pyx_v_conservationResidual, PyArrayObject *__pyx_v_vConservative, PyArrayObject *__pyx_v_vConservative_element); /* proto */
2224 static PyObject *__pyx_pf_15cpostprocessing_86calculateConservationJacobianPWL_interiorBoundaries(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_interiorElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries, PyArrayObject *__pyx_v_elementNodes, PyArrayObject *__pyx_v_nodeStarElements, PyArrayObject *__pyx_v_nodeStarElementNeighbors, PyArrayObject *__pyx_v_nElements_node, PyArrayObject *__pyx_v_fluxElementBoundaries, PyArrayObject *__pyx_v_w, PyArrayObject *__pyx_v_n, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor); /* proto */
2225 static PyObject *__pyx_pf_15cpostprocessing_88_subdomain_U_copy_global2local(CYTHON_UNUSED PyObject *__pyx_self, int __pyx_v_max_nN_owned, PyArrayObject *__pyx_v_elementNodes, PyArrayObject *__pyx_v_nodeStarElements, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor, PyArrayObject *__pyx_v_subdomain_U); /* proto */
2226 static PyObject *__pyx_pf_15cpostprocessing_90_subdomain_U_copy_local2global(CYTHON_UNUSED PyObject *__pyx_self, int __pyx_v_max_nN_owned, PyArrayObject *__pyx_v_elementNodes, PyArrayObject *__pyx_v_nodeStarElements, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor, PyArrayObject *__pyx_v_subdomain_U); /* proto */
2227 static PyObject *__pyx_pf_15cpostprocessing_92calculateConservationResidualGlobalBoundaries(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_interiorElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundariesToSkip, PyArrayObject *__pyx_v_dS, PyArrayObject *__pyx_v_n, PyArrayObject *__pyx_v_elementResidual, PyArrayObject *__pyx_v_velocity, PyArrayObject *__pyx_v_conservationResidual); /* proto */
2228 static PyObject *__pyx_pf_15cpostprocessing_94updateSelectedExteriorElementBoundaryFlux(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries, PyArrayObject *__pyx_v_skipflag_elementBoundaries, PyArrayObject *__pyx_v_flux, PyArrayObject *__pyx_v_w, PyArrayObject *__pyx_v_residual); /* proto */
2229 static PyObject *__pyx_pf_15cpostprocessing_96updateAdvectiveVelocityPointEval(CYTHON_UNUSED PyObject *__pyx_self, double __pyx_v_updateCoef, PyArrayObject *__pyx_v_advectiveVelocity, PyArrayObject *__pyx_v_velocity); /* proto */
2230 static PyObject *__pyx_pf_15cpostprocessing_98updateDiffusiveVelocityPointEval(CYTHON_UNUSED PyObject *__pyx_self, double __pyx_v_updateCoef, PyArrayObject *__pyx_v_diffusionTensor, PyArrayObject *__pyx_v_grad_phi, PyArrayObject *__pyx_v_velocity); /* proto */
2231 static PyObject *__pyx_pf_15cpostprocessing_100updateDiffusiveVelocityPointEval_sd(CYTHON_UNUSED PyObject *__pyx_self, double __pyx_v_updateCoef, PyArrayObject *__pyx_v_rowptr, PyArrayObject *__pyx_v_colind, PyArrayObject *__pyx_v_diffusionTensor, PyArrayObject *__pyx_v_grad_phi, PyArrayObject *__pyx_v_velocity); /* proto */
2232 static PyObject *__pyx_pf_15cpostprocessing_102calculateElementResidualPWL(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_alpha, PyArrayObject *__pyx_v_elementResidual, PyArrayObject *__pyx_v_elementResidualPWL); /* proto */
2233 static PyObject *__pyx_pf_15cpostprocessing_104copyElementBoundaryVelocityToParVec(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_ebq_velocity, PyArrayObject *__pyx_v_permutations, PyArrayObject *__pyx_v_ebq_v_par_local); /* proto */
2234 static PyObject *__pyx_pf_15cpostprocessing_106addAverageToParVec(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_ebq_velocityAverage, PyArrayObject *__pyx_v_permutations, PyArrayObject *__pyx_v_ebq_v_par_local); /* proto */
2235 static PyObject *__pyx_pf_15cpostprocessing_108copyParVecToElementBoundaryVelocity(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_ebq_velocity, PyArrayObject *__pyx_v_permutations, PyArrayObject *__pyx_v_ebq_v_par_local); /* proto */
2236 static PyObject *__pyx_tp_new_15cpostprocessing_NodeStarFactor(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/
2237 static PyObject *__pyx_tuple_;
2238 static PyObject *__pyx_tuple__2;
2239 static PyObject *__pyx_tuple__3;
2240 static PyObject *__pyx_tuple__4;
2241 static PyObject *__pyx_tuple__5;
2242 static PyObject *__pyx_tuple__7;
2243 static PyObject *__pyx_tuple__9;
2244 static PyObject *__pyx_tuple__11;
2245 static PyObject *__pyx_tuple__13;
2246 static PyObject *__pyx_tuple__15;
2247 static PyObject *__pyx_tuple__17;
2248 static PyObject *__pyx_tuple__19;
2249 static PyObject *__pyx_tuple__21;
2250 static PyObject *__pyx_tuple__23;
2251 static PyObject *__pyx_tuple__25;
2252 static PyObject *__pyx_tuple__27;
2253 static PyObject *__pyx_tuple__29;
2254 static PyObject *__pyx_tuple__31;
2255 static PyObject *__pyx_tuple__33;
2256 static PyObject *__pyx_tuple__35;
2257 static PyObject *__pyx_tuple__37;
2258 static PyObject *__pyx_tuple__39;
2259 static PyObject *__pyx_tuple__41;
2260 static PyObject *__pyx_tuple__43;
2261 static PyObject *__pyx_tuple__45;
2262 static PyObject *__pyx_tuple__47;
2263 static PyObject *__pyx_tuple__49;
2264 static PyObject *__pyx_tuple__51;
2265 static PyObject *__pyx_tuple__53;
2266 static PyObject *__pyx_tuple__55;
2267 static PyObject *__pyx_tuple__57;
2268 static PyObject *__pyx_tuple__59;
2269 static PyObject *__pyx_tuple__61;
2270 static PyObject *__pyx_tuple__63;
2271 static PyObject *__pyx_tuple__65;
2272 static PyObject *__pyx_tuple__67;
2273 static PyObject *__pyx_tuple__69;
2274 static PyObject *__pyx_tuple__71;
2275 static PyObject *__pyx_tuple__73;
2276 static PyObject *__pyx_tuple__75;
2277 static PyObject *__pyx_tuple__77;
2278 static PyObject *__pyx_tuple__79;
2279 static PyObject *__pyx_tuple__81;
2280 static PyObject *__pyx_tuple__83;
2281 static PyObject *__pyx_tuple__85;
2282 static PyObject *__pyx_tuple__87;
2283 static PyObject *__pyx_tuple__89;
2284 static PyObject *__pyx_tuple__91;
2285 static PyObject *__pyx_tuple__93;
2286 static PyObject *__pyx_tuple__95;
2287 static PyObject *__pyx_tuple__97;
2288 static PyObject *__pyx_tuple__99;
2289 static PyObject *__pyx_codeobj__6;
2290 static PyObject *__pyx_codeobj__8;
2291 static PyObject *__pyx_tuple__101;
2292 static PyObject *__pyx_tuple__103;
2293 static PyObject *__pyx_tuple__105;
2294 static PyObject *__pyx_tuple__107;
2295 static PyObject *__pyx_tuple__109;
2296 static PyObject *__pyx_tuple__111;
2297 static PyObject *__pyx_tuple__113;
2298 static PyObject *__pyx_codeobj__10;
2299 static PyObject *__pyx_codeobj__12;
2300 static PyObject *__pyx_codeobj__14;
2301 static PyObject *__pyx_codeobj__16;
2302 static PyObject *__pyx_codeobj__18;
2303 static PyObject *__pyx_codeobj__20;
2304 static PyObject *__pyx_codeobj__22;
2305 static PyObject *__pyx_codeobj__24;
2306 static PyObject *__pyx_codeobj__26;
2307 static PyObject *__pyx_codeobj__28;
2308 static PyObject *__pyx_codeobj__30;
2309 static PyObject *__pyx_codeobj__32;
2310 static PyObject *__pyx_codeobj__34;
2311 static PyObject *__pyx_codeobj__36;
2312 static PyObject *__pyx_codeobj__38;
2313 static PyObject *__pyx_codeobj__40;
2314 static PyObject *__pyx_codeobj__42;
2315 static PyObject *__pyx_codeobj__44;
2316 static PyObject *__pyx_codeobj__46;
2317 static PyObject *__pyx_codeobj__48;
2318 static PyObject *__pyx_codeobj__50;
2319 static PyObject *__pyx_codeobj__52;
2320 static PyObject *__pyx_codeobj__54;
2321 static PyObject *__pyx_codeobj__56;
2322 static PyObject *__pyx_codeobj__58;
2323 static PyObject *__pyx_codeobj__60;
2324 static PyObject *__pyx_codeobj__62;
2325 static PyObject *__pyx_codeobj__64;
2326 static PyObject *__pyx_codeobj__66;
2327 static PyObject *__pyx_codeobj__68;
2328 static PyObject *__pyx_codeobj__70;
2329 static PyObject *__pyx_codeobj__72;
2330 static PyObject *__pyx_codeobj__74;
2331 static PyObject *__pyx_codeobj__76;
2332 static PyObject *__pyx_codeobj__78;
2333 static PyObject *__pyx_codeobj__80;
2334 static PyObject *__pyx_codeobj__82;
2335 static PyObject *__pyx_codeobj__84;
2336 static PyObject *__pyx_codeobj__86;
2337 static PyObject *__pyx_codeobj__88;
2338 static PyObject *__pyx_codeobj__90;
2339 static PyObject *__pyx_codeobj__92;
2340 static PyObject *__pyx_codeobj__94;
2341 static PyObject *__pyx_codeobj__96;
2342 static PyObject *__pyx_codeobj__98;
2343 static PyObject *__pyx_codeobj__100;
2344 static PyObject *__pyx_codeobj__102;
2345 static PyObject *__pyx_codeobj__104;
2346 static PyObject *__pyx_codeobj__106;
2347 static PyObject *__pyx_codeobj__108;
2348 static PyObject *__pyx_codeobj__110;
2349 static PyObject *__pyx_codeobj__112;
2350 static PyObject *__pyx_codeobj__114;
2351 /* Late includes */
2352 
2353 /* "cpostprocessing.pyx":6
2354  * cimport postprocessing as pp
2355  *
2356  * def postProcessRT0velocityFromP1nc(np.ndarray nFreeDOF_element, # <<<<<<<<<<<<<<
2357  * np.ndarray freeLocal_element,
2358  * np.ndarray detJ,
2359  */
2360 
2361 /* Python wrapper */
2362 static PyObject *__pyx_pw_15cpostprocessing_1postProcessRT0velocityFromP1nc(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
2363 static PyMethodDef __pyx_mdef_15cpostprocessing_1postProcessRT0velocityFromP1nc = {"postProcessRT0velocityFromP1nc", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_1postProcessRT0velocityFromP1nc, METH_VARARGS|METH_KEYWORDS, 0};
2364 static PyObject *__pyx_pw_15cpostprocessing_1postProcessRT0velocityFromP1nc(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
2365  PyArrayObject *__pyx_v_nFreeDOF_element = 0;
2366  PyArrayObject *__pyx_v_freeLocal_element = 0;
2367  PyArrayObject *__pyx_v_detJ = 0;
2368  PyArrayObject *__pyx_v_sqrt_det_g = 0;
2369  PyArrayObject *__pyx_v_n = 0;
2370  PyArrayObject *__pyx_v_elementBarycenters = 0;
2371  PyArrayObject *__pyx_v_quad_a = 0;
2372  PyArrayObject *__pyx_v_quad_f = 0;
2373  PyArrayObject *__pyx_v_w_dV_r = 0;
2374  PyArrayObject *__pyx_v_u = 0;
2375  PyArrayObject *__pyx_v_gradu = 0;
2376  PyArrayObject *__pyx_v_a = 0;
2377  PyArrayObject *__pyx_v_f = 0;
2378  PyArrayObject *__pyx_v_r = 0;
2379  PyArrayObject *__pyx_v_rt0vdofs = 0;
2380  PyArrayObject *__pyx_v_w_dV_m = 0;
2381  PyArrayObject *__pyx_v_mt = 0;
2382  int __pyx_lineno = 0;
2383  const char *__pyx_filename = NULL;
2384  int __pyx_clineno = 0;
2385  PyObject *__pyx_r = 0;
2386  __Pyx_RefNannyDeclarations
2387  __Pyx_RefNannySetupContext("postProcessRT0velocityFromP1nc (wrapper)", 0);
2388  {
2389  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_nFreeDOF_element,&__pyx_n_s_freeLocal_element,&__pyx_n_s_detJ,&__pyx_n_s_sqrt_det_g,&__pyx_n_s_n,&__pyx_n_s_elementBarycenters,&__pyx_n_s_quad_a,&__pyx_n_s_quad_f,&__pyx_n_s_w_dV_r,&__pyx_n_s_u,&__pyx_n_s_gradu,&__pyx_n_s_a,&__pyx_n_s_f,&__pyx_n_s_r,&__pyx_n_s_rt0vdofs,&__pyx_n_s_w_dV_m,&__pyx_n_s_mt,0};
2390  PyObject* values[17] = {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0};
2391 
2392  /* "cpostprocessing.pyx":21
2393  * np.ndarray r,
2394  * np.ndarray rt0vdofs,
2395  * np.ndarray w_dV_m=None, # <<<<<<<<<<<<<<
2396  * np.ndarray mt=None):
2397  * if mt is not None and w_dV_m is not None:
2398  */
2399  values[15] = (PyObject *)((PyArrayObject *)Py_None);
2400 
2401  /* "cpostprocessing.pyx":22
2402  * np.ndarray rt0vdofs,
2403  * np.ndarray w_dV_m=None,
2404  * np.ndarray mt=None): # <<<<<<<<<<<<<<
2405  * if mt is not None and w_dV_m is not None:
2406  * pp.postProcessRT0velocityFromP1nc(gradu.shape[0],#/[inserted by cython to avoid comment start]*nElements_global*[inserted by cython to avoid comment closer]/
2407  */
2408  values[16] = (PyObject *)((PyArrayObject *)Py_None);
2409  if (unlikely(__pyx_kwds)) {
2410  Py_ssize_t kw_args;
2411  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
2412  switch (pos_args) {
2413  case 17: values[16] = PyTuple_GET_ITEM(__pyx_args, 16);
2414  CYTHON_FALLTHROUGH;
2415  case 16: values[15] = PyTuple_GET_ITEM(__pyx_args, 15);
2416  CYTHON_FALLTHROUGH;
2417  case 15: values[14] = PyTuple_GET_ITEM(__pyx_args, 14);
2418  CYTHON_FALLTHROUGH;
2419  case 14: values[13] = PyTuple_GET_ITEM(__pyx_args, 13);
2420  CYTHON_FALLTHROUGH;
2421  case 13: values[12] = PyTuple_GET_ITEM(__pyx_args, 12);
2422  CYTHON_FALLTHROUGH;
2423  case 12: values[11] = PyTuple_GET_ITEM(__pyx_args, 11);
2424  CYTHON_FALLTHROUGH;
2425  case 11: values[10] = PyTuple_GET_ITEM(__pyx_args, 10);
2426  CYTHON_FALLTHROUGH;
2427  case 10: values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
2428  CYTHON_FALLTHROUGH;
2429  case 9: values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
2430  CYTHON_FALLTHROUGH;
2431  case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
2432  CYTHON_FALLTHROUGH;
2433  case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
2434  CYTHON_FALLTHROUGH;
2435  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
2436  CYTHON_FALLTHROUGH;
2437  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
2438  CYTHON_FALLTHROUGH;
2439  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
2440  CYTHON_FALLTHROUGH;
2441  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
2442  CYTHON_FALLTHROUGH;
2443  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
2444  CYTHON_FALLTHROUGH;
2445  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
2446  CYTHON_FALLTHROUGH;
2447  case 0: break;
2448  default: goto __pyx_L5_argtuple_error;
2449  }
2450  kw_args = PyDict_Size(__pyx_kwds);
2451  switch (pos_args) {
2452  case 0:
2453  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nFreeDOF_element)) != 0)) kw_args--;
2454  else goto __pyx_L5_argtuple_error;
2455  CYTHON_FALLTHROUGH;
2456  case 1:
2457  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_freeLocal_element)) != 0)) kw_args--;
2458  else {
2459  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc", 0, 15, 17, 1); __PYX_ERR(0, 6, __pyx_L3_error)
2460  }
2461  CYTHON_FALLTHROUGH;
2462  case 2:
2463  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_detJ)) != 0)) kw_args--;
2464  else {
2465  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc", 0, 15, 17, 2); __PYX_ERR(0, 6, __pyx_L3_error)
2466  }
2467  CYTHON_FALLTHROUGH;
2468  case 3:
2469  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_sqrt_det_g)) != 0)) kw_args--;
2470  else {
2471  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc", 0, 15, 17, 3); __PYX_ERR(0, 6, __pyx_L3_error)
2472  }
2473  CYTHON_FALLTHROUGH;
2474  case 4:
2475  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_n)) != 0)) kw_args--;
2476  else {
2477  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc", 0, 15, 17, 4); __PYX_ERR(0, 6, __pyx_L3_error)
2478  }
2479  CYTHON_FALLTHROUGH;
2480  case 5:
2481  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBarycenters)) != 0)) kw_args--;
2482  else {
2483  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc", 0, 15, 17, 5); __PYX_ERR(0, 6, __pyx_L3_error)
2484  }
2485  CYTHON_FALLTHROUGH;
2486  case 6:
2487  if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_quad_a)) != 0)) kw_args--;
2488  else {
2489  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc", 0, 15, 17, 6); __PYX_ERR(0, 6, __pyx_L3_error)
2490  }
2491  CYTHON_FALLTHROUGH;
2492  case 7:
2493  if (likely((values[7] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_quad_f)) != 0)) kw_args--;
2494  else {
2495  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc", 0, 15, 17, 7); __PYX_ERR(0, 6, __pyx_L3_error)
2496  }
2497  CYTHON_FALLTHROUGH;
2498  case 8:
2499  if (likely((values[8] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_w_dV_r)) != 0)) kw_args--;
2500  else {
2501  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc", 0, 15, 17, 8); __PYX_ERR(0, 6, __pyx_L3_error)
2502  }
2503  CYTHON_FALLTHROUGH;
2504  case 9:
2505  if (likely((values[9] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
2506  else {
2507  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc", 0, 15, 17, 9); __PYX_ERR(0, 6, __pyx_L3_error)
2508  }
2509  CYTHON_FALLTHROUGH;
2510  case 10:
2511  if (likely((values[10] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_gradu)) != 0)) kw_args--;
2512  else {
2513  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc", 0, 15, 17, 10); __PYX_ERR(0, 6, __pyx_L3_error)
2514  }
2515  CYTHON_FALLTHROUGH;
2516  case 11:
2517  if (likely((values[11] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_a)) != 0)) kw_args--;
2518  else {
2519  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc", 0, 15, 17, 11); __PYX_ERR(0, 6, __pyx_L3_error)
2520  }
2521  CYTHON_FALLTHROUGH;
2522  case 12:
2523  if (likely((values[12] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_f)) != 0)) kw_args--;
2524  else {
2525  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc", 0, 15, 17, 12); __PYX_ERR(0, 6, __pyx_L3_error)
2526  }
2527  CYTHON_FALLTHROUGH;
2528  case 13:
2529  if (likely((values[13] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_r)) != 0)) kw_args--;
2530  else {
2531  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc", 0, 15, 17, 13); __PYX_ERR(0, 6, __pyx_L3_error)
2532  }
2533  CYTHON_FALLTHROUGH;
2534  case 14:
2535  if (likely((values[14] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rt0vdofs)) != 0)) kw_args--;
2536  else {
2537  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc", 0, 15, 17, 14); __PYX_ERR(0, 6, __pyx_L3_error)
2538  }
2539  CYTHON_FALLTHROUGH;
2540  case 15:
2541  if (kw_args > 0) {
2542  PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_w_dV_m);
2543  if (value) { values[15] = value; kw_args--; }
2544  }
2545  CYTHON_FALLTHROUGH;
2546  case 16:
2547  if (kw_args > 0) {
2548  PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_mt);
2549  if (value) { values[16] = value; kw_args--; }
2550  }
2551  }
2552  if (unlikely(kw_args > 0)) {
2553  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "postProcessRT0velocityFromP1nc") < 0)) __PYX_ERR(0, 6, __pyx_L3_error)
2554  }
2555  } else {
2556  switch (PyTuple_GET_SIZE(__pyx_args)) {
2557  case 17: values[16] = PyTuple_GET_ITEM(__pyx_args, 16);
2558  CYTHON_FALLTHROUGH;
2559  case 16: values[15] = PyTuple_GET_ITEM(__pyx_args, 15);
2560  CYTHON_FALLTHROUGH;
2561  case 15: values[14] = PyTuple_GET_ITEM(__pyx_args, 14);
2562  values[13] = PyTuple_GET_ITEM(__pyx_args, 13);
2563  values[12] = PyTuple_GET_ITEM(__pyx_args, 12);
2564  values[11] = PyTuple_GET_ITEM(__pyx_args, 11);
2565  values[10] = PyTuple_GET_ITEM(__pyx_args, 10);
2566  values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
2567  values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
2568  values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
2569  values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
2570  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
2571  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
2572  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
2573  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
2574  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
2575  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
2576  break;
2577  default: goto __pyx_L5_argtuple_error;
2578  }
2579  }
2580  __pyx_v_nFreeDOF_element = ((PyArrayObject *)values[0]);
2581  __pyx_v_freeLocal_element = ((PyArrayObject *)values[1]);
2582  __pyx_v_detJ = ((PyArrayObject *)values[2]);
2583  __pyx_v_sqrt_det_g = ((PyArrayObject *)values[3]);
2584  __pyx_v_n = ((PyArrayObject *)values[4]);
2585  __pyx_v_elementBarycenters = ((PyArrayObject *)values[5]);
2586  __pyx_v_quad_a = ((PyArrayObject *)values[6]);
2587  __pyx_v_quad_f = ((PyArrayObject *)values[7]);
2588  __pyx_v_w_dV_r = ((PyArrayObject *)values[8]);
2589  __pyx_v_u = ((PyArrayObject *)values[9]);
2590  __pyx_v_gradu = ((PyArrayObject *)values[10]);
2591  __pyx_v_a = ((PyArrayObject *)values[11]);
2592  __pyx_v_f = ((PyArrayObject *)values[12]);
2593  __pyx_v_r = ((PyArrayObject *)values[13]);
2594  __pyx_v_rt0vdofs = ((PyArrayObject *)values[14]);
2595  __pyx_v_w_dV_m = ((PyArrayObject *)values[15]);
2596  __pyx_v_mt = ((PyArrayObject *)values[16]);
2597  }
2598  goto __pyx_L4_argument_unpacking_done;
2599  __pyx_L5_argtuple_error:;
2600  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc", 0, 15, 17, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 6, __pyx_L3_error)
2601  __pyx_L3_error:;
2602  __Pyx_AddTraceback("cpostprocessing.postProcessRT0velocityFromP1nc", __pyx_clineno, __pyx_lineno, __pyx_filename);
2603  __Pyx_RefNannyFinishContext();
2604  return NULL;
2605  __pyx_L4_argument_unpacking_done:;
2606  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nFreeDOF_element), __pyx_ptype_5numpy_ndarray, 1, "nFreeDOF_element", 0))) __PYX_ERR(0, 6, __pyx_L1_error)
2607  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_freeLocal_element), __pyx_ptype_5numpy_ndarray, 1, "freeLocal_element", 0))) __PYX_ERR(0, 7, __pyx_L1_error)
2608  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_detJ), __pyx_ptype_5numpy_ndarray, 1, "detJ", 0))) __PYX_ERR(0, 8, __pyx_L1_error)
2609  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_sqrt_det_g), __pyx_ptype_5numpy_ndarray, 1, "sqrt_det_g", 0))) __PYX_ERR(0, 9, __pyx_L1_error)
2610  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_n), __pyx_ptype_5numpy_ndarray, 1, "n", 0))) __PYX_ERR(0, 10, __pyx_L1_error)
2611  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBarycenters), __pyx_ptype_5numpy_ndarray, 1, "elementBarycenters", 0))) __PYX_ERR(0, 11, __pyx_L1_error)
2612  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_quad_a), __pyx_ptype_5numpy_ndarray, 1, "quad_a", 0))) __PYX_ERR(0, 12, __pyx_L1_error)
2613  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_quad_f), __pyx_ptype_5numpy_ndarray, 1, "quad_f", 0))) __PYX_ERR(0, 13, __pyx_L1_error)
2614  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_w_dV_r), __pyx_ptype_5numpy_ndarray, 1, "w_dV_r", 0))) __PYX_ERR(0, 14, __pyx_L1_error)
2615  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1, "u", 0))) __PYX_ERR(0, 15, __pyx_L1_error)
2616  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_gradu), __pyx_ptype_5numpy_ndarray, 1, "gradu", 0))) __PYX_ERR(0, 16, __pyx_L1_error)
2617  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 17, __pyx_L1_error)
2618  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_f), __pyx_ptype_5numpy_ndarray, 1, "f", 0))) __PYX_ERR(0, 18, __pyx_L1_error)
2619  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_r), __pyx_ptype_5numpy_ndarray, 1, "r", 0))) __PYX_ERR(0, 19, __pyx_L1_error)
2620  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rt0vdofs), __pyx_ptype_5numpy_ndarray, 1, "rt0vdofs", 0))) __PYX_ERR(0, 20, __pyx_L1_error)
2621  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_w_dV_m), __pyx_ptype_5numpy_ndarray, 1, "w_dV_m", 0))) __PYX_ERR(0, 21, __pyx_L1_error)
2622  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_mt), __pyx_ptype_5numpy_ndarray, 1, "mt", 0))) __PYX_ERR(0, 22, __pyx_L1_error)
2623  __pyx_r = __pyx_pf_15cpostprocessing_postProcessRT0velocityFromP1nc(__pyx_self, __pyx_v_nFreeDOF_element, __pyx_v_freeLocal_element, __pyx_v_detJ, __pyx_v_sqrt_det_g, __pyx_v_n, __pyx_v_elementBarycenters, __pyx_v_quad_a, __pyx_v_quad_f, __pyx_v_w_dV_r, __pyx_v_u, __pyx_v_gradu, __pyx_v_a, __pyx_v_f, __pyx_v_r, __pyx_v_rt0vdofs, __pyx_v_w_dV_m, __pyx_v_mt);
2624 
2625  /* "cpostprocessing.pyx":6
2626  * cimport postprocessing as pp
2627  *
2628  * def postProcessRT0velocityFromP1nc(np.ndarray nFreeDOF_element, # <<<<<<<<<<<<<<
2629  * np.ndarray freeLocal_element,
2630  * np.ndarray detJ,
2631  */
2632 
2633  /* function exit code */
2634  goto __pyx_L0;
2635  __pyx_L1_error:;
2636  __pyx_r = NULL;
2637  __pyx_L0:;
2638  __Pyx_RefNannyFinishContext();
2639  return __pyx_r;
2640 }
2641 
2642 static PyObject *__pyx_pf_15cpostprocessing_postProcessRT0velocityFromP1nc(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_nFreeDOF_element, PyArrayObject *__pyx_v_freeLocal_element, PyArrayObject *__pyx_v_detJ, PyArrayObject *__pyx_v_sqrt_det_g, PyArrayObject *__pyx_v_n, PyArrayObject *__pyx_v_elementBarycenters, PyArrayObject *__pyx_v_quad_a, PyArrayObject *__pyx_v_quad_f, PyArrayObject *__pyx_v_w_dV_r, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_gradu, PyArrayObject *__pyx_v_a, PyArrayObject *__pyx_v_f, PyArrayObject *__pyx_v_r, PyArrayObject *__pyx_v_rt0vdofs, PyArrayObject *__pyx_v_w_dV_m, PyArrayObject *__pyx_v_mt) {
2643  PyObject *__pyx_r = NULL;
2644  __Pyx_RefNannyDeclarations
2645  int __pyx_t_1;
2646  int __pyx_t_2;
2647  int __pyx_t_3;
2648  __Pyx_RefNannySetupContext("postProcessRT0velocityFromP1nc", 0);
2649 
2650  /* "cpostprocessing.pyx":23
2651  * np.ndarray w_dV_m=None,
2652  * np.ndarray mt=None):
2653  * if mt is not None and w_dV_m is not None: # <<<<<<<<<<<<<<
2654  * pp.postProcessRT0velocityFromP1nc(gradu.shape[0],#/[inserted by cython to avoid comment start]*nElements_global*[inserted by cython to avoid comment closer]/
2655  * gradu.shape[1],#/[inserted by cython to avoid comment start]*nQuadraturePoints_element*[inserted by cython to avoid comment closer]/
2656  */
2657  __pyx_t_2 = (((PyObject *)__pyx_v_mt) != Py_None);
2658  __pyx_t_3 = (__pyx_t_2 != 0);
2659  if (__pyx_t_3) {
2660  } else {
2661  __pyx_t_1 = __pyx_t_3;
2662  goto __pyx_L4_bool_binop_done;
2663  }
2664  __pyx_t_3 = (((PyObject *)__pyx_v_w_dV_m) != Py_None);
2665  __pyx_t_2 = (__pyx_t_3 != 0);
2666  __pyx_t_1 = __pyx_t_2;
2667  __pyx_L4_bool_binop_done:;
2668  if (__pyx_t_1) {
2669 
2670  /* "cpostprocessing.pyx":24
2671  * np.ndarray mt=None):
2672  * if mt is not None and w_dV_m is not None:
2673  * pp.postProcessRT0velocityFromP1nc(gradu.shape[0],#/[inserted by cython to avoid comment start]*nElements_global*[inserted by cython to avoid comment closer]/ # <<<<<<<<<<<<<<
2674  * gradu.shape[1],#/[inserted by cython to avoid comment start]*nQuadraturePoints_element*[inserted by cython to avoid comment closer]/
2675  * w_dV_r.shape[2],#/[inserted by cython to avoid comment start]*nDOF_test_element*[inserted by cython to avoid comment closer]/
2676  */
2677  postProcessRT0velocityFromP1nc((__pyx_v_gradu->dimensions[0]), (__pyx_v_gradu->dimensions[1]), (__pyx_v_w_dV_r->dimensions[2]), (__pyx_v_n->dimensions[1]), (__pyx_v_n->dimensions[2]), (__pyx_v_gradu->dimensions[2]), ((int *)__pyx_v_nFreeDOF_element->data), ((int *)__pyx_v_freeLocal_element->data), ((double *)__pyx_v_detJ->data), ((double *)__pyx_v_sqrt_det_g->data), ((double *)__pyx_v_n->data), ((double *)__pyx_v_elementBarycenters->data), ((double *)__pyx_v_quad_a->data), ((double *)__pyx_v_quad_f->data), ((double *)__pyx_v_w_dV_r->data), ((double *)__pyx_v_w_dV_m->data), ((double *)__pyx_v_u->data), ((double *)__pyx_v_gradu->data), ((double *)__pyx_v_a->data), ((double *)__pyx_v_f->data), ((double *)__pyx_v_r->data), ((double *)__pyx_v_mt->data), ((double *)__pyx_v_rt0vdofs->data));
2678 
2679  /* "cpostprocessing.pyx":23
2680  * np.ndarray w_dV_m=None,
2681  * np.ndarray mt=None):
2682  * if mt is not None and w_dV_m is not None: # <<<<<<<<<<<<<<
2683  * pp.postProcessRT0velocityFromP1nc(gradu.shape[0],#/[inserted by cython to avoid comment start]*nElements_global*[inserted by cython to avoid comment closer]/
2684  * gradu.shape[1],#/[inserted by cython to avoid comment start]*nQuadraturePoints_element*[inserted by cython to avoid comment closer]/
2685  */
2686  goto __pyx_L3;
2687  }
2688 
2689  /* "cpostprocessing.pyx":48
2690  * <double*>(rt0vdofs.data))
2691  * else:
2692  * pp.postProcessRT0velocityFromP1ncNoMass(gradu.shape[0],#/[inserted by cython to avoid comment start]*nElements_global*[inserted by cython to avoid comment closer]/ # <<<<<<<<<<<<<<
2693  * gradu.shape[1],#/[inserted by cython to avoid comment start]*nQuadraturePoints_element*[inserted by cython to avoid comment closer]/
2694  * w_dV_r.shape[2],#/[inserted by cython to avoid comment start]*nDOF_test_element*[inserted by cython to avoid comment closer]/
2695  */
2696  /*else*/ {
2697 
2698  /* "cpostprocessing.pyx":68
2699  * <double*>(f.data),
2700  * <double*>(r.data),
2701  * <double*>(rt0vdofs.data)) # <<<<<<<<<<<<<<
2702  *
2703  * def postProcessRT0velocityFromP1nc_sd(np.ndarray rowptr,
2704  */
2705  postProcessRT0velocityFromP1ncNoMass((__pyx_v_gradu->dimensions[0]), (__pyx_v_gradu->dimensions[1]), (__pyx_v_w_dV_r->dimensions[2]), (__pyx_v_n->dimensions[1]), (__pyx_v_n->dimensions[2]), (__pyx_v_gradu->dimensions[2]), ((int *)__pyx_v_nFreeDOF_element->data), ((int *)__pyx_v_freeLocal_element->data), ((double *)__pyx_v_detJ->data), ((double *)__pyx_v_sqrt_det_g->data), ((double *)__pyx_v_n->data), ((double *)__pyx_v_elementBarycenters->data), ((double *)__pyx_v_quad_a->data), ((double *)__pyx_v_quad_f->data), ((double *)__pyx_v_w_dV_r->data), ((double *)__pyx_v_u->data), ((double *)__pyx_v_gradu->data), ((double *)__pyx_v_a->data), ((double *)__pyx_v_f->data), ((double *)__pyx_v_r->data), ((double *)__pyx_v_rt0vdofs->data));
2706  }
2707  __pyx_L3:;
2708 
2709  /* "cpostprocessing.pyx":6
2710  * cimport postprocessing as pp
2711  *
2712  * def postProcessRT0velocityFromP1nc(np.ndarray nFreeDOF_element, # <<<<<<<<<<<<<<
2713  * np.ndarray freeLocal_element,
2714  * np.ndarray detJ,
2715  */
2716 
2717  /* function exit code */
2718  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
2719  __Pyx_XGIVEREF(__pyx_r);
2720  __Pyx_RefNannyFinishContext();
2721  return __pyx_r;
2722 }
2723 
2724 /* "cpostprocessing.pyx":70
2725  * <double*>(rt0vdofs.data))
2726  *
2727  * def postProcessRT0velocityFromP1nc_sd(np.ndarray rowptr, # <<<<<<<<<<<<<<
2728  * np.ndarray colind,
2729  * np.ndarray nFreeDOF_element,
2730  */
2731 
2732 /* Python wrapper */
2733 static PyObject *__pyx_pw_15cpostprocessing_3postProcessRT0velocityFromP1nc_sd(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
2734 static PyMethodDef __pyx_mdef_15cpostprocessing_3postProcessRT0velocityFromP1nc_sd = {"postProcessRT0velocityFromP1nc_sd", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_3postProcessRT0velocityFromP1nc_sd, METH_VARARGS|METH_KEYWORDS, 0};
2735 static PyObject *__pyx_pw_15cpostprocessing_3postProcessRT0velocityFromP1nc_sd(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
2736  PyArrayObject *__pyx_v_rowptr = 0;
2737  PyArrayObject *__pyx_v_colind = 0;
2738  PyArrayObject *__pyx_v_nFreeDOF_element = 0;
2739  PyArrayObject *__pyx_v_freeLocal_element = 0;
2740  PyArrayObject *__pyx_v_detJ = 0;
2741  PyArrayObject *__pyx_v_sqrt_det_g = 0;
2742  PyArrayObject *__pyx_v_n = 0;
2743  PyArrayObject *__pyx_v_elementBarycenters = 0;
2744  PyArrayObject *__pyx_v_quad_a = 0;
2745  PyArrayObject *__pyx_v_quad_f = 0;
2746  PyArrayObject *__pyx_v_w_dV_r = 0;
2747  PyArrayObject *__pyx_v_u = 0;
2748  PyArrayObject *__pyx_v_gradu = 0;
2749  PyArrayObject *__pyx_v_a = 0;
2750  PyArrayObject *__pyx_v_f = 0;
2751  PyArrayObject *__pyx_v_r = 0;
2752  PyArrayObject *__pyx_v_rt0vdofs = 0;
2753  PyArrayObject *__pyx_v_w_dV_m = 0;
2754  PyArrayObject *__pyx_v_mt = 0;
2755  int __pyx_lineno = 0;
2756  const char *__pyx_filename = NULL;
2757  int __pyx_clineno = 0;
2758  PyObject *__pyx_r = 0;
2759  __Pyx_RefNannyDeclarations
2760  __Pyx_RefNannySetupContext("postProcessRT0velocityFromP1nc_sd (wrapper)", 0);
2761  {
2762  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_rowptr,&__pyx_n_s_colind,&__pyx_n_s_nFreeDOF_element,&__pyx_n_s_freeLocal_element,&__pyx_n_s_detJ,&__pyx_n_s_sqrt_det_g,&__pyx_n_s_n,&__pyx_n_s_elementBarycenters,&__pyx_n_s_quad_a,&__pyx_n_s_quad_f,&__pyx_n_s_w_dV_r,&__pyx_n_s_u,&__pyx_n_s_gradu,&__pyx_n_s_a,&__pyx_n_s_f,&__pyx_n_s_r,&__pyx_n_s_rt0vdofs,&__pyx_n_s_w_dV_m,&__pyx_n_s_mt,0};
2763  PyObject* values[19] = {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0};
2764 
2765  /* "cpostprocessing.pyx":87
2766  * np.ndarray r,
2767  * np.ndarray rt0vdofs,
2768  * np.ndarray w_dV_m=None, # <<<<<<<<<<<<<<
2769  * np.ndarray mt=None):
2770  * if mt is None and w_dV_m is not None:
2771  */
2772  values[17] = (PyObject *)((PyArrayObject *)Py_None);
2773 
2774  /* "cpostprocessing.pyx":88
2775  * np.ndarray rt0vdofs,
2776  * np.ndarray w_dV_m=None,
2777  * np.ndarray mt=None): # <<<<<<<<<<<<<<
2778  * if mt is None and w_dV_m is not None:
2779  * pp.postProcessRT0velocityFromP1nc_sd(gradu.shape[0],#/[inserted by cython to avoid comment start]*nElements_global*[inserted by cython to avoid comment closer]/
2780  */
2781  values[18] = (PyObject *)((PyArrayObject *)Py_None);
2782  if (unlikely(__pyx_kwds)) {
2783  Py_ssize_t kw_args;
2784  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
2785  switch (pos_args) {
2786  case 19: values[18] = PyTuple_GET_ITEM(__pyx_args, 18);
2787  CYTHON_FALLTHROUGH;
2788  case 18: values[17] = PyTuple_GET_ITEM(__pyx_args, 17);
2789  CYTHON_FALLTHROUGH;
2790  case 17: values[16] = PyTuple_GET_ITEM(__pyx_args, 16);
2791  CYTHON_FALLTHROUGH;
2792  case 16: values[15] = PyTuple_GET_ITEM(__pyx_args, 15);
2793  CYTHON_FALLTHROUGH;
2794  case 15: values[14] = PyTuple_GET_ITEM(__pyx_args, 14);
2795  CYTHON_FALLTHROUGH;
2796  case 14: values[13] = PyTuple_GET_ITEM(__pyx_args, 13);
2797  CYTHON_FALLTHROUGH;
2798  case 13: values[12] = PyTuple_GET_ITEM(__pyx_args, 12);
2799  CYTHON_FALLTHROUGH;
2800  case 12: values[11] = PyTuple_GET_ITEM(__pyx_args, 11);
2801  CYTHON_FALLTHROUGH;
2802  case 11: values[10] = PyTuple_GET_ITEM(__pyx_args, 10);
2803  CYTHON_FALLTHROUGH;
2804  case 10: values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
2805  CYTHON_FALLTHROUGH;
2806  case 9: values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
2807  CYTHON_FALLTHROUGH;
2808  case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
2809  CYTHON_FALLTHROUGH;
2810  case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
2811  CYTHON_FALLTHROUGH;
2812  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
2813  CYTHON_FALLTHROUGH;
2814  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
2815  CYTHON_FALLTHROUGH;
2816  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
2817  CYTHON_FALLTHROUGH;
2818  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
2819  CYTHON_FALLTHROUGH;
2820  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
2821  CYTHON_FALLTHROUGH;
2822  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
2823  CYTHON_FALLTHROUGH;
2824  case 0: break;
2825  default: goto __pyx_L5_argtuple_error;
2826  }
2827  kw_args = PyDict_Size(__pyx_kwds);
2828  switch (pos_args) {
2829  case 0:
2830  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rowptr)) != 0)) kw_args--;
2831  else goto __pyx_L5_argtuple_error;
2832  CYTHON_FALLTHROUGH;
2833  case 1:
2834  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_colind)) != 0)) kw_args--;
2835  else {
2836  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc_sd", 0, 17, 19, 1); __PYX_ERR(0, 70, __pyx_L3_error)
2837  }
2838  CYTHON_FALLTHROUGH;
2839  case 2:
2840  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nFreeDOF_element)) != 0)) kw_args--;
2841  else {
2842  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc_sd", 0, 17, 19, 2); __PYX_ERR(0, 70, __pyx_L3_error)
2843  }
2844  CYTHON_FALLTHROUGH;
2845  case 3:
2846  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_freeLocal_element)) != 0)) kw_args--;
2847  else {
2848  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc_sd", 0, 17, 19, 3); __PYX_ERR(0, 70, __pyx_L3_error)
2849  }
2850  CYTHON_FALLTHROUGH;
2851  case 4:
2852  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_detJ)) != 0)) kw_args--;
2853  else {
2854  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc_sd", 0, 17, 19, 4); __PYX_ERR(0, 70, __pyx_L3_error)
2855  }
2856  CYTHON_FALLTHROUGH;
2857  case 5:
2858  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_sqrt_det_g)) != 0)) kw_args--;
2859  else {
2860  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc_sd", 0, 17, 19, 5); __PYX_ERR(0, 70, __pyx_L3_error)
2861  }
2862  CYTHON_FALLTHROUGH;
2863  case 6:
2864  if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_n)) != 0)) kw_args--;
2865  else {
2866  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc_sd", 0, 17, 19, 6); __PYX_ERR(0, 70, __pyx_L3_error)
2867  }
2868  CYTHON_FALLTHROUGH;
2869  case 7:
2870  if (likely((values[7] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBarycenters)) != 0)) kw_args--;
2871  else {
2872  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc_sd", 0, 17, 19, 7); __PYX_ERR(0, 70, __pyx_L3_error)
2873  }
2874  CYTHON_FALLTHROUGH;
2875  case 8:
2876  if (likely((values[8] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_quad_a)) != 0)) kw_args--;
2877  else {
2878  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc_sd", 0, 17, 19, 8); __PYX_ERR(0, 70, __pyx_L3_error)
2879  }
2880  CYTHON_FALLTHROUGH;
2881  case 9:
2882  if (likely((values[9] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_quad_f)) != 0)) kw_args--;
2883  else {
2884  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc_sd", 0, 17, 19, 9); __PYX_ERR(0, 70, __pyx_L3_error)
2885  }
2886  CYTHON_FALLTHROUGH;
2887  case 10:
2888  if (likely((values[10] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_w_dV_r)) != 0)) kw_args--;
2889  else {
2890  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc_sd", 0, 17, 19, 10); __PYX_ERR(0, 70, __pyx_L3_error)
2891  }
2892  CYTHON_FALLTHROUGH;
2893  case 11:
2894  if (likely((values[11] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
2895  else {
2896  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc_sd", 0, 17, 19, 11); __PYX_ERR(0, 70, __pyx_L3_error)
2897  }
2898  CYTHON_FALLTHROUGH;
2899  case 12:
2900  if (likely((values[12] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_gradu)) != 0)) kw_args--;
2901  else {
2902  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc_sd", 0, 17, 19, 12); __PYX_ERR(0, 70, __pyx_L3_error)
2903  }
2904  CYTHON_FALLTHROUGH;
2905  case 13:
2906  if (likely((values[13] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_a)) != 0)) kw_args--;
2907  else {
2908  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc_sd", 0, 17, 19, 13); __PYX_ERR(0, 70, __pyx_L3_error)
2909  }
2910  CYTHON_FALLTHROUGH;
2911  case 14:
2912  if (likely((values[14] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_f)) != 0)) kw_args--;
2913  else {
2914  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc_sd", 0, 17, 19, 14); __PYX_ERR(0, 70, __pyx_L3_error)
2915  }
2916  CYTHON_FALLTHROUGH;
2917  case 15:
2918  if (likely((values[15] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_r)) != 0)) kw_args--;
2919  else {
2920  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc_sd", 0, 17, 19, 15); __PYX_ERR(0, 70, __pyx_L3_error)
2921  }
2922  CYTHON_FALLTHROUGH;
2923  case 16:
2924  if (likely((values[16] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rt0vdofs)) != 0)) kw_args--;
2925  else {
2926  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc_sd", 0, 17, 19, 16); __PYX_ERR(0, 70, __pyx_L3_error)
2927  }
2928  CYTHON_FALLTHROUGH;
2929  case 17:
2930  if (kw_args > 0) {
2931  PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_w_dV_m);
2932  if (value) { values[17] = value; kw_args--; }
2933  }
2934  CYTHON_FALLTHROUGH;
2935  case 18:
2936  if (kw_args > 0) {
2937  PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_mt);
2938  if (value) { values[18] = value; kw_args--; }
2939  }
2940  }
2941  if (unlikely(kw_args > 0)) {
2942  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "postProcessRT0velocityFromP1nc_sd") < 0)) __PYX_ERR(0, 70, __pyx_L3_error)
2943  }
2944  } else {
2945  switch (PyTuple_GET_SIZE(__pyx_args)) {
2946  case 19: values[18] = PyTuple_GET_ITEM(__pyx_args, 18);
2947  CYTHON_FALLTHROUGH;
2948  case 18: values[17] = PyTuple_GET_ITEM(__pyx_args, 17);
2949  CYTHON_FALLTHROUGH;
2950  case 17: values[16] = PyTuple_GET_ITEM(__pyx_args, 16);
2951  values[15] = PyTuple_GET_ITEM(__pyx_args, 15);
2952  values[14] = PyTuple_GET_ITEM(__pyx_args, 14);
2953  values[13] = PyTuple_GET_ITEM(__pyx_args, 13);
2954  values[12] = PyTuple_GET_ITEM(__pyx_args, 12);
2955  values[11] = PyTuple_GET_ITEM(__pyx_args, 11);
2956  values[10] = PyTuple_GET_ITEM(__pyx_args, 10);
2957  values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
2958  values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
2959  values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
2960  values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
2961  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
2962  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
2963  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
2964  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
2965  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
2966  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
2967  break;
2968  default: goto __pyx_L5_argtuple_error;
2969  }
2970  }
2971  __pyx_v_rowptr = ((PyArrayObject *)values[0]);
2972  __pyx_v_colind = ((PyArrayObject *)values[1]);
2973  __pyx_v_nFreeDOF_element = ((PyArrayObject *)values[2]);
2974  __pyx_v_freeLocal_element = ((PyArrayObject *)values[3]);
2975  __pyx_v_detJ = ((PyArrayObject *)values[4]);
2976  __pyx_v_sqrt_det_g = ((PyArrayObject *)values[5]);
2977  __pyx_v_n = ((PyArrayObject *)values[6]);
2978  __pyx_v_elementBarycenters = ((PyArrayObject *)values[7]);
2979  __pyx_v_quad_a = ((PyArrayObject *)values[8]);
2980  __pyx_v_quad_f = ((PyArrayObject *)values[9]);
2981  __pyx_v_w_dV_r = ((PyArrayObject *)values[10]);
2982  __pyx_v_u = ((PyArrayObject *)values[11]);
2983  __pyx_v_gradu = ((PyArrayObject *)values[12]);
2984  __pyx_v_a = ((PyArrayObject *)values[13]);
2985  __pyx_v_f = ((PyArrayObject *)values[14]);
2986  __pyx_v_r = ((PyArrayObject *)values[15]);
2987  __pyx_v_rt0vdofs = ((PyArrayObject *)values[16]);
2988  __pyx_v_w_dV_m = ((PyArrayObject *)values[17]);
2989  __pyx_v_mt = ((PyArrayObject *)values[18]);
2990  }
2991  goto __pyx_L4_argument_unpacking_done;
2992  __pyx_L5_argtuple_error:;
2993  __Pyx_RaiseArgtupleInvalid("postProcessRT0velocityFromP1nc_sd", 0, 17, 19, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 70, __pyx_L3_error)
2994  __pyx_L3_error:;
2995  __Pyx_AddTraceback("cpostprocessing.postProcessRT0velocityFromP1nc_sd", __pyx_clineno, __pyx_lineno, __pyx_filename);
2996  __Pyx_RefNannyFinishContext();
2997  return NULL;
2998  __pyx_L4_argument_unpacking_done:;
2999  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rowptr), __pyx_ptype_5numpy_ndarray, 1, "rowptr", 0))) __PYX_ERR(0, 70, __pyx_L1_error)
3000  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_colind), __pyx_ptype_5numpy_ndarray, 1, "colind", 0))) __PYX_ERR(0, 71, __pyx_L1_error)
3001  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nFreeDOF_element), __pyx_ptype_5numpy_ndarray, 1, "nFreeDOF_element", 0))) __PYX_ERR(0, 72, __pyx_L1_error)
3002  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_freeLocal_element), __pyx_ptype_5numpy_ndarray, 1, "freeLocal_element", 0))) __PYX_ERR(0, 73, __pyx_L1_error)
3003  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_detJ), __pyx_ptype_5numpy_ndarray, 1, "detJ", 0))) __PYX_ERR(0, 74, __pyx_L1_error)
3004  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_sqrt_det_g), __pyx_ptype_5numpy_ndarray, 1, "sqrt_det_g", 0))) __PYX_ERR(0, 75, __pyx_L1_error)
3005  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_n), __pyx_ptype_5numpy_ndarray, 1, "n", 0))) __PYX_ERR(0, 76, __pyx_L1_error)
3006  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBarycenters), __pyx_ptype_5numpy_ndarray, 1, "elementBarycenters", 0))) __PYX_ERR(0, 77, __pyx_L1_error)
3007  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_quad_a), __pyx_ptype_5numpy_ndarray, 1, "quad_a", 0))) __PYX_ERR(0, 78, __pyx_L1_error)
3008  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_quad_f), __pyx_ptype_5numpy_ndarray, 1, "quad_f", 0))) __PYX_ERR(0, 79, __pyx_L1_error)
3009  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_w_dV_r), __pyx_ptype_5numpy_ndarray, 1, "w_dV_r", 0))) __PYX_ERR(0, 80, __pyx_L1_error)
3010  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1, "u", 0))) __PYX_ERR(0, 81, __pyx_L1_error)
3011  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_gradu), __pyx_ptype_5numpy_ndarray, 1, "gradu", 0))) __PYX_ERR(0, 82, __pyx_L1_error)
3012  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 83, __pyx_L1_error)
3013  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_f), __pyx_ptype_5numpy_ndarray, 1, "f", 0))) __PYX_ERR(0, 84, __pyx_L1_error)
3014  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_r), __pyx_ptype_5numpy_ndarray, 1, "r", 0))) __PYX_ERR(0, 85, __pyx_L1_error)
3015  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rt0vdofs), __pyx_ptype_5numpy_ndarray, 1, "rt0vdofs", 0))) __PYX_ERR(0, 86, __pyx_L1_error)
3016  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_w_dV_m), __pyx_ptype_5numpy_ndarray, 1, "w_dV_m", 0))) __PYX_ERR(0, 87, __pyx_L1_error)
3017  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_mt), __pyx_ptype_5numpy_ndarray, 1, "mt", 0))) __PYX_ERR(0, 88, __pyx_L1_error)
3018  __pyx_r = __pyx_pf_15cpostprocessing_2postProcessRT0velocityFromP1nc_sd(__pyx_self, __pyx_v_rowptr, __pyx_v_colind, __pyx_v_nFreeDOF_element, __pyx_v_freeLocal_element, __pyx_v_detJ, __pyx_v_sqrt_det_g, __pyx_v_n, __pyx_v_elementBarycenters, __pyx_v_quad_a, __pyx_v_quad_f, __pyx_v_w_dV_r, __pyx_v_u, __pyx_v_gradu, __pyx_v_a, __pyx_v_f, __pyx_v_r, __pyx_v_rt0vdofs, __pyx_v_w_dV_m, __pyx_v_mt);
3019 
3020  /* "cpostprocessing.pyx":70
3021  * <double*>(rt0vdofs.data))
3022  *
3023  * def postProcessRT0velocityFromP1nc_sd(np.ndarray rowptr, # <<<<<<<<<<<<<<
3024  * np.ndarray colind,
3025  * np.ndarray nFreeDOF_element,
3026  */
3027 
3028  /* function exit code */
3029  goto __pyx_L0;
3030  __pyx_L1_error:;
3031  __pyx_r = NULL;
3032  __pyx_L0:;
3033  __Pyx_RefNannyFinishContext();
3034  return __pyx_r;
3035 }
3036 
3037 static PyObject *__pyx_pf_15cpostprocessing_2postProcessRT0velocityFromP1nc_sd(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_rowptr, PyArrayObject *__pyx_v_colind, PyArrayObject *__pyx_v_nFreeDOF_element, PyArrayObject *__pyx_v_freeLocal_element, PyArrayObject *__pyx_v_detJ, PyArrayObject *__pyx_v_sqrt_det_g, PyArrayObject *__pyx_v_n, PyArrayObject *__pyx_v_elementBarycenters, PyArrayObject *__pyx_v_quad_a, PyArrayObject *__pyx_v_quad_f, PyArrayObject *__pyx_v_w_dV_r, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_gradu, PyArrayObject *__pyx_v_a, PyArrayObject *__pyx_v_f, PyArrayObject *__pyx_v_r, PyArrayObject *__pyx_v_rt0vdofs, PyArrayObject *__pyx_v_w_dV_m, PyArrayObject *__pyx_v_mt) {
3038  PyObject *__pyx_r = NULL;
3039  __Pyx_RefNannyDeclarations
3040  int __pyx_t_1;
3041  int __pyx_t_2;
3042  int __pyx_t_3;
3043  __Pyx_RefNannySetupContext("postProcessRT0velocityFromP1nc_sd", 0);
3044 
3045  /* "cpostprocessing.pyx":89
3046  * np.ndarray w_dV_m=None,
3047  * np.ndarray mt=None):
3048  * if mt is None and w_dV_m is not None: # <<<<<<<<<<<<<<
3049  * pp.postProcessRT0velocityFromP1nc_sd(gradu.shape[0],#/[inserted by cython to avoid comment start]*nElements_global*[inserted by cython to avoid comment closer]/
3050  * gradu.shape[1],#/[inserted by cython to avoid comment start]*nQuadraturePoints_element*[inserted by cython to avoid comment closer]/
3051  */
3052  __pyx_t_2 = (((PyObject *)__pyx_v_mt) == Py_None);
3053  __pyx_t_3 = (__pyx_t_2 != 0);
3054  if (__pyx_t_3) {
3055  } else {
3056  __pyx_t_1 = __pyx_t_3;
3057  goto __pyx_L4_bool_binop_done;
3058  }
3059  __pyx_t_3 = (((PyObject *)__pyx_v_w_dV_m) != Py_None);
3060  __pyx_t_2 = (__pyx_t_3 != 0);
3061  __pyx_t_1 = __pyx_t_2;
3062  __pyx_L4_bool_binop_done:;
3063  if (__pyx_t_1) {
3064 
3065  /* "cpostprocessing.pyx":90
3066  * np.ndarray mt=None):
3067  * if mt is None and w_dV_m is not None:
3068  * pp.postProcessRT0velocityFromP1nc_sd(gradu.shape[0],#/[inserted by cython to avoid comment start]*nElements_global*[inserted by cython to avoid comment closer]/ # <<<<<<<<<<<<<<
3069  * gradu.shape[1],#/[inserted by cython to avoid comment start]*nQuadraturePoints_element*[inserted by cython to avoid comment closer]/
3070  * w_dV_r.shape[2],#/[inserted by cython to avoid comment start]*nDOF_test_element*[inserted by cython to avoid comment closer]/
3071  */
3072  postProcessRT0velocityFromP1nc_sd((__pyx_v_gradu->dimensions[0]), (__pyx_v_gradu->dimensions[1]), (__pyx_v_w_dV_r->dimensions[2]), (__pyx_v_n->dimensions[1]), (__pyx_v_n->dimensions[2]), (__pyx_v_gradu->dimensions[2]), ((int *)__pyx_v_rowptr->data), ((int *)__pyx_v_colind->data), ((int *)__pyx_v_nFreeDOF_element->data), ((int *)__pyx_v_freeLocal_element->data), ((double *)__pyx_v_detJ->data), ((double *)__pyx_v_sqrt_det_g->data), ((double *)__pyx_v_n->data), ((double *)__pyx_v_elementBarycenters->data), ((double *)__pyx_v_quad_a->data), ((double *)__pyx_v_quad_f->data), ((double *)__pyx_v_w_dV_r->data), ((double *)__pyx_v_w_dV_m->data), ((double *)__pyx_v_u->data), ((double *)__pyx_v_gradu->data), ((double *)__pyx_v_a->data), ((double *)__pyx_v_f->data), ((double *)__pyx_v_r->data), ((double *)__pyx_v_mt->data), ((double *)__pyx_v_rt0vdofs->data));
3073 
3074  /* "cpostprocessing.pyx":89
3075  * np.ndarray w_dV_m=None,
3076  * np.ndarray mt=None):
3077  * if mt is None and w_dV_m is not None: # <<<<<<<<<<<<<<
3078  * pp.postProcessRT0velocityFromP1nc_sd(gradu.shape[0],#/[inserted by cython to avoid comment start]*nElements_global*[inserted by cython to avoid comment closer]/
3079  * gradu.shape[1],#/[inserted by cython to avoid comment start]*nQuadraturePoints_element*[inserted by cython to avoid comment closer]/
3080  */
3081  goto __pyx_L3;
3082  }
3083 
3084  /* "cpostprocessing.pyx":116
3085  * <double*>(rt0vdofs.data))
3086  * else:
3087  * pp.postProcessRT0velocityFromP1ncNoMass_sd(gradu.shape[0],#/[inserted by cython to avoid comment start]*nElements_global*[inserted by cython to avoid comment closer]/ # <<<<<<<<<<<<<<
3088  * gradu.shape[1],#/[inserted by cython to avoid comment start]*nQuadraturePoints_element*[inserted by cython to avoid comment closer]/
3089  * w_dV_r.shape[2],#/[inserted by cython to avoid comment start]*nDOF_test_element*[inserted by cython to avoid comment closer]/
3090  */
3091  /*else*/ {
3092 
3093  /* "cpostprocessing.pyx":138
3094  * <double*>(f.data),
3095  * <double*>(r.data),
3096  * <double*>(rt0vdofs.data)) # <<<<<<<<<<<<<<
3097  *
3098  * def updateRT0velocityWithAveragedPotentialP1nc(np.ndarray detJ,
3099  */
3100  postProcessRT0velocityFromP1ncNoMass_sd((__pyx_v_gradu->dimensions[0]), (__pyx_v_gradu->dimensions[1]), (__pyx_v_w_dV_r->dimensions[2]), (__pyx_v_n->dimensions[1]), (__pyx_v_n->dimensions[2]), (__pyx_v_gradu->dimensions[2]), ((int *)__pyx_v_rowptr->data), ((int *)__pyx_v_colind->data), ((int *)__pyx_v_nFreeDOF_element->data), ((int *)__pyx_v_freeLocal_element->data), ((double *)__pyx_v_detJ->data), ((double *)__pyx_v_sqrt_det_g->data), ((double *)__pyx_v_n->data), ((double *)__pyx_v_elementBarycenters->data), ((double *)__pyx_v_quad_a->data), ((double *)__pyx_v_quad_f->data), ((double *)__pyx_v_w_dV_r->data), ((double *)__pyx_v_u->data), ((double *)__pyx_v_gradu->data), ((double *)__pyx_v_a->data), ((double *)__pyx_v_f->data), ((double *)__pyx_v_r->data), ((double *)__pyx_v_rt0vdofs->data));
3101  }
3102  __pyx_L3:;
3103 
3104  /* "cpostprocessing.pyx":70
3105  * <double*>(rt0vdofs.data))
3106  *
3107  * def postProcessRT0velocityFromP1nc_sd(np.ndarray rowptr, # <<<<<<<<<<<<<<
3108  * np.ndarray colind,
3109  * np.ndarray nFreeDOF_element,
3110  */
3111 
3112  /* function exit code */
3113  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
3114  __Pyx_XGIVEREF(__pyx_r);
3115  __Pyx_RefNannyFinishContext();
3116  return __pyx_r;
3117 }
3118 
3119 /* "cpostprocessing.pyx":140
3120  * <double*>(rt0vdofs.data))
3121  *
3122  * def updateRT0velocityWithAveragedPotentialP1nc(np.ndarray detJ, # <<<<<<<<<<<<<<
3123  * np.ndarray quad_a,
3124  * np.ndarray phi,
3125  */
3126 
3127 /* Python wrapper */
3128 static PyObject *__pyx_pw_15cpostprocessing_5updateRT0velocityWithAveragedPotentialP1nc(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
3129 static PyMethodDef __pyx_mdef_15cpostprocessing_5updateRT0velocityWithAveragedPotentialP1nc = {"updateRT0velocityWithAveragedPotentialP1nc", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_5updateRT0velocityWithAveragedPotentialP1nc, METH_VARARGS|METH_KEYWORDS, 0};
3130 static PyObject *__pyx_pw_15cpostprocessing_5updateRT0velocityWithAveragedPotentialP1nc(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
3131  PyArrayObject *__pyx_v_detJ = 0;
3132  PyArrayObject *__pyx_v_quad_a = 0;
3133  PyArrayObject *__pyx_v_phi = 0;
3134  PyArrayObject *__pyx_v_gradphi = 0;
3135  PyArrayObject *__pyx_v_a = 0;
3136  PyArrayObject *__pyx_v_rt0vdofs_element = 0;
3137  int __pyx_lineno = 0;
3138  const char *__pyx_filename = NULL;
3139  int __pyx_clineno = 0;
3140  PyObject *__pyx_r = 0;
3141  __Pyx_RefNannyDeclarations
3142  __Pyx_RefNannySetupContext("updateRT0velocityWithAveragedPotentialP1nc (wrapper)", 0);
3143  {
3144  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_detJ,&__pyx_n_s_quad_a,&__pyx_n_s_phi,&__pyx_n_s_gradphi,&__pyx_n_s_a,&__pyx_n_s_rt0vdofs_element,0};
3145  PyObject* values[6] = {0,0,0,0,0,0};
3146  if (unlikely(__pyx_kwds)) {
3147  Py_ssize_t kw_args;
3148  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
3149  switch (pos_args) {
3150  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
3151  CYTHON_FALLTHROUGH;
3152  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
3153  CYTHON_FALLTHROUGH;
3154  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
3155  CYTHON_FALLTHROUGH;
3156  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
3157  CYTHON_FALLTHROUGH;
3158  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
3159  CYTHON_FALLTHROUGH;
3160  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
3161  CYTHON_FALLTHROUGH;
3162  case 0: break;
3163  default: goto __pyx_L5_argtuple_error;
3164  }
3165  kw_args = PyDict_Size(__pyx_kwds);
3166  switch (pos_args) {
3167  case 0:
3168  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_detJ)) != 0)) kw_args--;
3169  else goto __pyx_L5_argtuple_error;
3170  CYTHON_FALLTHROUGH;
3171  case 1:
3172  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_quad_a)) != 0)) kw_args--;
3173  else {
3174  __Pyx_RaiseArgtupleInvalid("updateRT0velocityWithAveragedPotentialP1nc", 1, 6, 6, 1); __PYX_ERR(0, 140, __pyx_L3_error)
3175  }
3176  CYTHON_FALLTHROUGH;
3177  case 2:
3178  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_phi)) != 0)) kw_args--;
3179  else {
3180  __Pyx_RaiseArgtupleInvalid("updateRT0velocityWithAveragedPotentialP1nc", 1, 6, 6, 2); __PYX_ERR(0, 140, __pyx_L3_error)
3181  }
3182  CYTHON_FALLTHROUGH;
3183  case 3:
3184  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_gradphi)) != 0)) kw_args--;
3185  else {
3186  __Pyx_RaiseArgtupleInvalid("updateRT0velocityWithAveragedPotentialP1nc", 1, 6, 6, 3); __PYX_ERR(0, 140, __pyx_L3_error)
3187  }
3188  CYTHON_FALLTHROUGH;
3189  case 4:
3190  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_a)) != 0)) kw_args--;
3191  else {
3192  __Pyx_RaiseArgtupleInvalid("updateRT0velocityWithAveragedPotentialP1nc", 1, 6, 6, 4); __PYX_ERR(0, 140, __pyx_L3_error)
3193  }
3194  CYTHON_FALLTHROUGH;
3195  case 5:
3196  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rt0vdofs_element)) != 0)) kw_args--;
3197  else {
3198  __Pyx_RaiseArgtupleInvalid("updateRT0velocityWithAveragedPotentialP1nc", 1, 6, 6, 5); __PYX_ERR(0, 140, __pyx_L3_error)
3199  }
3200  }
3201  if (unlikely(kw_args > 0)) {
3202  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "updateRT0velocityWithAveragedPotentialP1nc") < 0)) __PYX_ERR(0, 140, __pyx_L3_error)
3203  }
3204  } else if (PyTuple_GET_SIZE(__pyx_args) != 6) {
3205  goto __pyx_L5_argtuple_error;
3206  } else {
3207  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
3208  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
3209  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
3210  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
3211  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
3212  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
3213  }
3214  __pyx_v_detJ = ((PyArrayObject *)values[0]);
3215  __pyx_v_quad_a = ((PyArrayObject *)values[1]);
3216  __pyx_v_phi = ((PyArrayObject *)values[2]);
3217  __pyx_v_gradphi = ((PyArrayObject *)values[3]);
3218  __pyx_v_a = ((PyArrayObject *)values[4]);
3219  __pyx_v_rt0vdofs_element = ((PyArrayObject *)values[5]);
3220  }
3221  goto __pyx_L4_argument_unpacking_done;
3222  __pyx_L5_argtuple_error:;
3223  __Pyx_RaiseArgtupleInvalid("updateRT0velocityWithAveragedPotentialP1nc", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 140, __pyx_L3_error)
3224  __pyx_L3_error:;
3225  __Pyx_AddTraceback("cpostprocessing.updateRT0velocityWithAveragedPotentialP1nc", __pyx_clineno, __pyx_lineno, __pyx_filename);
3226  __Pyx_RefNannyFinishContext();
3227  return NULL;
3228  __pyx_L4_argument_unpacking_done:;
3229  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_detJ), __pyx_ptype_5numpy_ndarray, 1, "detJ", 0))) __PYX_ERR(0, 140, __pyx_L1_error)
3230  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_quad_a), __pyx_ptype_5numpy_ndarray, 1, "quad_a", 0))) __PYX_ERR(0, 141, __pyx_L1_error)
3231  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_phi), __pyx_ptype_5numpy_ndarray, 1, "phi", 0))) __PYX_ERR(0, 142, __pyx_L1_error)
3232  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_gradphi), __pyx_ptype_5numpy_ndarray, 1, "gradphi", 0))) __PYX_ERR(0, 143, __pyx_L1_error)
3233  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 144, __pyx_L1_error)
3234  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rt0vdofs_element), __pyx_ptype_5numpy_ndarray, 1, "rt0vdofs_element", 0))) __PYX_ERR(0, 145, __pyx_L1_error)
3235  __pyx_r = __pyx_pf_15cpostprocessing_4updateRT0velocityWithAveragedPotentialP1nc(__pyx_self, __pyx_v_detJ, __pyx_v_quad_a, __pyx_v_phi, __pyx_v_gradphi, __pyx_v_a, __pyx_v_rt0vdofs_element);
3236 
3237  /* function exit code */
3238  goto __pyx_L0;
3239  __pyx_L1_error:;
3240  __pyx_r = NULL;
3241  __pyx_L0:;
3242  __Pyx_RefNannyFinishContext();
3243  return __pyx_r;
3244 }
3245 
3246 static PyObject *__pyx_pf_15cpostprocessing_4updateRT0velocityWithAveragedPotentialP1nc(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_detJ, PyArrayObject *__pyx_v_quad_a, PyArrayObject *__pyx_v_phi, PyArrayObject *__pyx_v_gradphi, PyArrayObject *__pyx_v_a, PyArrayObject *__pyx_v_rt0vdofs_element) {
3247  PyObject *__pyx_r = NULL;
3248  __Pyx_RefNannyDeclarations
3249  __Pyx_RefNannySetupContext("updateRT0velocityWithAveragedPotentialP1nc", 0);
3250 
3251  /* "cpostprocessing.pyx":146
3252  * np.ndarray a,
3253  * np.ndarray rt0vdofs_element):
3254  * pp.updateRT0velocityWithAveragedPotentialP1nc(a.shape[0], # <<<<<<<<<<<<<<
3255  * a.shape[1],
3256  * gradphi.shape[gradphi.ndim-1],
3257  */
3258  updateRT0velocityWithAveragedPotentialP1nc((__pyx_v_a->dimensions[0]), (__pyx_v_a->dimensions[1]), (__pyx_v_gradphi->dimensions[(__pyx_v_gradphi->nd - 1)]), ((double *)__pyx_v_detJ->data), ((double *)__pyx_v_quad_a->data), ((double *)__pyx_v_phi->data), ((double *)__pyx_v_gradphi->data), ((double *)__pyx_v_a->data), ((double *)__pyx_v_rt0vdofs_element->data));
3259 
3260  /* "cpostprocessing.pyx":140
3261  * <double*>(rt0vdofs.data))
3262  *
3263  * def updateRT0velocityWithAveragedPotentialP1nc(np.ndarray detJ, # <<<<<<<<<<<<<<
3264  * np.ndarray quad_a,
3265  * np.ndarray phi,
3266  */
3267 
3268  /* function exit code */
3269  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
3270  __Pyx_XGIVEREF(__pyx_r);
3271  __Pyx_RefNannyFinishContext();
3272  return __pyx_r;
3273 }
3274 
3275 /* "cpostprocessing.pyx":156
3276  * <double*>(rt0vdofs_element.data))
3277  *
3278  * def updateRT0velocityWithAveragedPotentialP1nc_sd(np.ndarray rowptr, # <<<<<<<<<<<<<<
3279  * np.ndarray colind,
3280  * np.ndarray detJ,
3281  */
3282 
3283 /* Python wrapper */
3284 static PyObject *__pyx_pw_15cpostprocessing_7updateRT0velocityWithAveragedPotentialP1nc_sd(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
3285 static PyMethodDef __pyx_mdef_15cpostprocessing_7updateRT0velocityWithAveragedPotentialP1nc_sd = {"updateRT0velocityWithAveragedPotentialP1nc_sd", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_7updateRT0velocityWithAveragedPotentialP1nc_sd, METH_VARARGS|METH_KEYWORDS, 0};
3286 static PyObject *__pyx_pw_15cpostprocessing_7updateRT0velocityWithAveragedPotentialP1nc_sd(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
3287  PyArrayObject *__pyx_v_rowptr = 0;
3288  PyArrayObject *__pyx_v_colind = 0;
3289  PyArrayObject *__pyx_v_detJ = 0;
3290  PyArrayObject *__pyx_v_quad_a = 0;
3291  PyArrayObject *__pyx_v_phi = 0;
3292  PyArrayObject *__pyx_v_gradphi = 0;
3293  PyArrayObject *__pyx_v_a = 0;
3294  PyArrayObject *__pyx_v_rt0vdofs_element = 0;
3295  int __pyx_lineno = 0;
3296  const char *__pyx_filename = NULL;
3297  int __pyx_clineno = 0;
3298  PyObject *__pyx_r = 0;
3299  __Pyx_RefNannyDeclarations
3300  __Pyx_RefNannySetupContext("updateRT0velocityWithAveragedPotentialP1nc_sd (wrapper)", 0);
3301  {
3302  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_rowptr,&__pyx_n_s_colind,&__pyx_n_s_detJ,&__pyx_n_s_quad_a,&__pyx_n_s_phi,&__pyx_n_s_gradphi,&__pyx_n_s_a,&__pyx_n_s_rt0vdofs_element,0};
3303  PyObject* values[8] = {0,0,0,0,0,0,0,0};
3304  if (unlikely(__pyx_kwds)) {
3305  Py_ssize_t kw_args;
3306  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
3307  switch (pos_args) {
3308  case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
3309  CYTHON_FALLTHROUGH;
3310  case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
3311  CYTHON_FALLTHROUGH;
3312  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
3313  CYTHON_FALLTHROUGH;
3314  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
3315  CYTHON_FALLTHROUGH;
3316  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
3317  CYTHON_FALLTHROUGH;
3318  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
3319  CYTHON_FALLTHROUGH;
3320  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
3321  CYTHON_FALLTHROUGH;
3322  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
3323  CYTHON_FALLTHROUGH;
3324  case 0: break;
3325  default: goto __pyx_L5_argtuple_error;
3326  }
3327  kw_args = PyDict_Size(__pyx_kwds);
3328  switch (pos_args) {
3329  case 0:
3330  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rowptr)) != 0)) kw_args--;
3331  else goto __pyx_L5_argtuple_error;
3332  CYTHON_FALLTHROUGH;
3333  case 1:
3334  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_colind)) != 0)) kw_args--;
3335  else {
3336  __Pyx_RaiseArgtupleInvalid("updateRT0velocityWithAveragedPotentialP1nc_sd", 1, 8, 8, 1); __PYX_ERR(0, 156, __pyx_L3_error)
3337  }
3338  CYTHON_FALLTHROUGH;
3339  case 2:
3340  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_detJ)) != 0)) kw_args--;
3341  else {
3342  __Pyx_RaiseArgtupleInvalid("updateRT0velocityWithAveragedPotentialP1nc_sd", 1, 8, 8, 2); __PYX_ERR(0, 156, __pyx_L3_error)
3343  }
3344  CYTHON_FALLTHROUGH;
3345  case 3:
3346  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_quad_a)) != 0)) kw_args--;
3347  else {
3348  __Pyx_RaiseArgtupleInvalid("updateRT0velocityWithAveragedPotentialP1nc_sd", 1, 8, 8, 3); __PYX_ERR(0, 156, __pyx_L3_error)
3349  }
3350  CYTHON_FALLTHROUGH;
3351  case 4:
3352  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_phi)) != 0)) kw_args--;
3353  else {
3354  __Pyx_RaiseArgtupleInvalid("updateRT0velocityWithAveragedPotentialP1nc_sd", 1, 8, 8, 4); __PYX_ERR(0, 156, __pyx_L3_error)
3355  }
3356  CYTHON_FALLTHROUGH;
3357  case 5:
3358  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_gradphi)) != 0)) kw_args--;
3359  else {
3360  __Pyx_RaiseArgtupleInvalid("updateRT0velocityWithAveragedPotentialP1nc_sd", 1, 8, 8, 5); __PYX_ERR(0, 156, __pyx_L3_error)
3361  }
3362  CYTHON_FALLTHROUGH;
3363  case 6:
3364  if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_a)) != 0)) kw_args--;
3365  else {
3366  __Pyx_RaiseArgtupleInvalid("updateRT0velocityWithAveragedPotentialP1nc_sd", 1, 8, 8, 6); __PYX_ERR(0, 156, __pyx_L3_error)
3367  }
3368  CYTHON_FALLTHROUGH;
3369  case 7:
3370  if (likely((values[7] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rt0vdofs_element)) != 0)) kw_args--;
3371  else {
3372  __Pyx_RaiseArgtupleInvalid("updateRT0velocityWithAveragedPotentialP1nc_sd", 1, 8, 8, 7); __PYX_ERR(0, 156, __pyx_L3_error)
3373  }
3374  }
3375  if (unlikely(kw_args > 0)) {
3376  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "updateRT0velocityWithAveragedPotentialP1nc_sd") < 0)) __PYX_ERR(0, 156, __pyx_L3_error)
3377  }
3378  } else if (PyTuple_GET_SIZE(__pyx_args) != 8) {
3379  goto __pyx_L5_argtuple_error;
3380  } else {
3381  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
3382  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
3383  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
3384  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
3385  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
3386  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
3387  values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
3388  values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
3389  }
3390  __pyx_v_rowptr = ((PyArrayObject *)values[0]);
3391  __pyx_v_colind = ((PyArrayObject *)values[1]);
3392  __pyx_v_detJ = ((PyArrayObject *)values[2]);
3393  __pyx_v_quad_a = ((PyArrayObject *)values[3]);
3394  __pyx_v_phi = ((PyArrayObject *)values[4]);
3395  __pyx_v_gradphi = ((PyArrayObject *)values[5]);
3396  __pyx_v_a = ((PyArrayObject *)values[6]);
3397  __pyx_v_rt0vdofs_element = ((PyArrayObject *)values[7]);
3398  }
3399  goto __pyx_L4_argument_unpacking_done;
3400  __pyx_L5_argtuple_error:;
3401  __Pyx_RaiseArgtupleInvalid("updateRT0velocityWithAveragedPotentialP1nc_sd", 1, 8, 8, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 156, __pyx_L3_error)
3402  __pyx_L3_error:;
3403  __Pyx_AddTraceback("cpostprocessing.updateRT0velocityWithAveragedPotentialP1nc_sd", __pyx_clineno, __pyx_lineno, __pyx_filename);
3404  __Pyx_RefNannyFinishContext();
3405  return NULL;
3406  __pyx_L4_argument_unpacking_done:;
3407  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rowptr), __pyx_ptype_5numpy_ndarray, 1, "rowptr", 0))) __PYX_ERR(0, 156, __pyx_L1_error)
3408  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_colind), __pyx_ptype_5numpy_ndarray, 1, "colind", 0))) __PYX_ERR(0, 157, __pyx_L1_error)
3409  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_detJ), __pyx_ptype_5numpy_ndarray, 1, "detJ", 0))) __PYX_ERR(0, 158, __pyx_L1_error)
3410  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_quad_a), __pyx_ptype_5numpy_ndarray, 1, "quad_a", 0))) __PYX_ERR(0, 159, __pyx_L1_error)
3411  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_phi), __pyx_ptype_5numpy_ndarray, 1, "phi", 0))) __PYX_ERR(0, 160, __pyx_L1_error)
3412  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_gradphi), __pyx_ptype_5numpy_ndarray, 1, "gradphi", 0))) __PYX_ERR(0, 161, __pyx_L1_error)
3413  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 162, __pyx_L1_error)
3414  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rt0vdofs_element), __pyx_ptype_5numpy_ndarray, 1, "rt0vdofs_element", 0))) __PYX_ERR(0, 163, __pyx_L1_error)
3415  __pyx_r = __pyx_pf_15cpostprocessing_6updateRT0velocityWithAveragedPotentialP1nc_sd(__pyx_self, __pyx_v_rowptr, __pyx_v_colind, __pyx_v_detJ, __pyx_v_quad_a, __pyx_v_phi, __pyx_v_gradphi, __pyx_v_a, __pyx_v_rt0vdofs_element);
3416 
3417  /* function exit code */
3418  goto __pyx_L0;
3419  __pyx_L1_error:;
3420  __pyx_r = NULL;
3421  __pyx_L0:;
3422  __Pyx_RefNannyFinishContext();
3423  return __pyx_r;
3424 }
3425 
3426 static PyObject *__pyx_pf_15cpostprocessing_6updateRT0velocityWithAveragedPotentialP1nc_sd(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_rowptr, PyArrayObject *__pyx_v_colind, PyArrayObject *__pyx_v_detJ, PyArrayObject *__pyx_v_quad_a, PyArrayObject *__pyx_v_phi, PyArrayObject *__pyx_v_gradphi, PyArrayObject *__pyx_v_a, PyArrayObject *__pyx_v_rt0vdofs_element) {
3427  PyObject *__pyx_r = NULL;
3428  __Pyx_RefNannyDeclarations
3429  __Pyx_RefNannySetupContext("updateRT0velocityWithAveragedPotentialP1nc_sd", 0);
3430 
3431  /* "cpostprocessing.pyx":164
3432  * np.ndarray a,
3433  * np.ndarray rt0vdofs_element):
3434  * pp.updateRT0velocityWithAveragedPotentialP1nc_sd(a.shape[0], # <<<<<<<<<<<<<<
3435  * a.shape[1],
3436  * gradphi.shape[gradphi.ndim-1],
3437  */
3438  updateRT0velocityWithAveragedPotentialP1nc_sd((__pyx_v_a->dimensions[0]), (__pyx_v_a->dimensions[1]), (__pyx_v_gradphi->dimensions[(__pyx_v_gradphi->nd - 1)]), ((int *)__pyx_v_rowptr->data), ((int *)__pyx_v_colind->data), ((double *)__pyx_v_detJ->data), ((double *)__pyx_v_quad_a->data), ((double *)__pyx_v_phi->data), ((double *)__pyx_v_gradphi->data), ((double *)__pyx_v_a->data), ((double *)__pyx_v_rt0vdofs_element->data));
3439 
3440  /* "cpostprocessing.pyx":156
3441  * <double*>(rt0vdofs_element.data))
3442  *
3443  * def updateRT0velocityWithAveragedPotentialP1nc_sd(np.ndarray rowptr, # <<<<<<<<<<<<<<
3444  * np.ndarray colind,
3445  * np.ndarray detJ,
3446  */
3447 
3448  /* function exit code */
3449  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
3450  __Pyx_XGIVEREF(__pyx_r);
3451  __Pyx_RefNannyFinishContext();
3452  return __pyx_r;
3453 }
3454 
3455 /* "cpostprocessing.pyx":176
3456  * <double*>(rt0vdofs_element.data))
3457  *
3458  * def getElementRT0velocityValues(np.ndarray x_element, # <<<<<<<<<<<<<<
3459  * np.ndarray rt0vdofs_element,
3460  * np.ndarray v_element):
3461  */
3462 
3463 /* Python wrapper */
3464 static PyObject *__pyx_pw_15cpostprocessing_9getElementRT0velocityValues(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
3465 static PyMethodDef __pyx_mdef_15cpostprocessing_9getElementRT0velocityValues = {"getElementRT0velocityValues", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_9getElementRT0velocityValues, METH_VARARGS|METH_KEYWORDS, 0};
3466 static PyObject *__pyx_pw_15cpostprocessing_9getElementRT0velocityValues(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
3467  PyArrayObject *__pyx_v_x_element = 0;
3468  PyArrayObject *__pyx_v_rt0vdofs_element = 0;
3469  PyArrayObject *__pyx_v_v_element = 0;
3470  int __pyx_lineno = 0;
3471  const char *__pyx_filename = NULL;
3472  int __pyx_clineno = 0;
3473  PyObject *__pyx_r = 0;
3474  __Pyx_RefNannyDeclarations
3475  __Pyx_RefNannySetupContext("getElementRT0velocityValues (wrapper)", 0);
3476  {
3477  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_x_element,&__pyx_n_s_rt0vdofs_element,&__pyx_n_s_v_element,0};
3478  PyObject* values[3] = {0,0,0};
3479  if (unlikely(__pyx_kwds)) {
3480  Py_ssize_t kw_args;
3481  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
3482  switch (pos_args) {
3483  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
3484  CYTHON_FALLTHROUGH;
3485  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
3486  CYTHON_FALLTHROUGH;
3487  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
3488  CYTHON_FALLTHROUGH;
3489  case 0: break;
3490  default: goto __pyx_L5_argtuple_error;
3491  }
3492  kw_args = PyDict_Size(__pyx_kwds);
3493  switch (pos_args) {
3494  case 0:
3495  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x_element)) != 0)) kw_args--;
3496  else goto __pyx_L5_argtuple_error;
3497  CYTHON_FALLTHROUGH;
3498  case 1:
3499  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rt0vdofs_element)) != 0)) kw_args--;
3500  else {
3501  __Pyx_RaiseArgtupleInvalid("getElementRT0velocityValues", 1, 3, 3, 1); __PYX_ERR(0, 176, __pyx_L3_error)
3502  }
3503  CYTHON_FALLTHROUGH;
3504  case 2:
3505  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_v_element)) != 0)) kw_args--;
3506  else {
3507  __Pyx_RaiseArgtupleInvalid("getElementRT0velocityValues", 1, 3, 3, 2); __PYX_ERR(0, 176, __pyx_L3_error)
3508  }
3509  }
3510  if (unlikely(kw_args > 0)) {
3511  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "getElementRT0velocityValues") < 0)) __PYX_ERR(0, 176, __pyx_L3_error)
3512  }
3513  } else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
3514  goto __pyx_L5_argtuple_error;
3515  } else {
3516  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
3517  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
3518  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
3519  }
3520  __pyx_v_x_element = ((PyArrayObject *)values[0]);
3521  __pyx_v_rt0vdofs_element = ((PyArrayObject *)values[1]);
3522  __pyx_v_v_element = ((PyArrayObject *)values[2]);
3523  }
3524  goto __pyx_L4_argument_unpacking_done;
3525  __pyx_L5_argtuple_error:;
3526  __Pyx_RaiseArgtupleInvalid("getElementRT0velocityValues", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 176, __pyx_L3_error)
3527  __pyx_L3_error:;
3528  __Pyx_AddTraceback("cpostprocessing.getElementRT0velocityValues", __pyx_clineno, __pyx_lineno, __pyx_filename);
3529  __Pyx_RefNannyFinishContext();
3530  return NULL;
3531  __pyx_L4_argument_unpacking_done:;
3532  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_element), __pyx_ptype_5numpy_ndarray, 1, "x_element", 0))) __PYX_ERR(0, 176, __pyx_L1_error)
3533  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rt0vdofs_element), __pyx_ptype_5numpy_ndarray, 1, "rt0vdofs_element", 0))) __PYX_ERR(0, 177, __pyx_L1_error)
3534  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_v_element), __pyx_ptype_5numpy_ndarray, 1, "v_element", 0))) __PYX_ERR(0, 178, __pyx_L1_error)
3535  __pyx_r = __pyx_pf_15cpostprocessing_8getElementRT0velocityValues(__pyx_self, __pyx_v_x_element, __pyx_v_rt0vdofs_element, __pyx_v_v_element);
3536 
3537  /* function exit code */
3538  goto __pyx_L0;
3539  __pyx_L1_error:;
3540  __pyx_r = NULL;
3541  __pyx_L0:;
3542  __Pyx_RefNannyFinishContext();
3543  return __pyx_r;
3544 }
3545 
3546 static PyObject *__pyx_pf_15cpostprocessing_8getElementRT0velocityValues(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_x_element, PyArrayObject *__pyx_v_rt0vdofs_element, PyArrayObject *__pyx_v_v_element) {
3547  PyObject *__pyx_r = NULL;
3548  __Pyx_RefNannyDeclarations
3549  __Pyx_RefNannySetupContext("getElementRT0velocityValues", 0);
3550 
3551  /* "cpostprocessing.pyx":179
3552  * np.ndarray rt0vdofs_element,
3553  * np.ndarray v_element):
3554  * pp.getElementRT0velocityValues(v_element.shape[0], # <<<<<<<<<<<<<<
3555  * v_element.shape[1],
3556  * v_element.shape[2],
3557  */
3558  getElementRT0velocityValues((__pyx_v_v_element->dimensions[0]), (__pyx_v_v_element->dimensions[1]), (__pyx_v_v_element->dimensions[2]), ((double *)__pyx_v_x_element->data), ((double *)__pyx_v_rt0vdofs_element->data), ((double *)__pyx_v_v_element->data));
3559 
3560  /* "cpostprocessing.pyx":176
3561  * <double*>(rt0vdofs_element.data))
3562  *
3563  * def getElementRT0velocityValues(np.ndarray x_element, # <<<<<<<<<<<<<<
3564  * np.ndarray rt0vdofs_element,
3565  * np.ndarray v_element):
3566  */
3567 
3568  /* function exit code */
3569  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
3570  __Pyx_XGIVEREF(__pyx_r);
3571  __Pyx_RefNannyFinishContext();
3572  return __pyx_r;
3573 }
3574 
3575 /* "cpostprocessing.pyx":186
3576  * <double*>(v_element.data))
3577  *
3578  * def getElementBoundaryRT0velocityValues(np.ndarray x_elementBoundary, # <<<<<<<<<<<<<<
3579  * np.ndarray rt0vdofs_element,
3580  * np.ndarray v_elementBoundary):
3581  */
3582 
3583 /* Python wrapper */
3584 static PyObject *__pyx_pw_15cpostprocessing_11getElementBoundaryRT0velocityValues(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
3585 static PyMethodDef __pyx_mdef_15cpostprocessing_11getElementBoundaryRT0velocityValues = {"getElementBoundaryRT0velocityValues", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_11getElementBoundaryRT0velocityValues, METH_VARARGS|METH_KEYWORDS, 0};
3586 static PyObject *__pyx_pw_15cpostprocessing_11getElementBoundaryRT0velocityValues(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
3587  PyArrayObject *__pyx_v_x_elementBoundary = 0;
3588  PyArrayObject *__pyx_v_rt0vdofs_element = 0;
3589  PyArrayObject *__pyx_v_v_elementBoundary = 0;
3590  int __pyx_lineno = 0;
3591  const char *__pyx_filename = NULL;
3592  int __pyx_clineno = 0;
3593  PyObject *__pyx_r = 0;
3594  __Pyx_RefNannyDeclarations
3595  __Pyx_RefNannySetupContext("getElementBoundaryRT0velocityValues (wrapper)", 0);
3596  {
3597  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_x_elementBoundary,&__pyx_n_s_rt0vdofs_element,&__pyx_n_s_v_elementBoundary,0};
3598  PyObject* values[3] = {0,0,0};
3599  if (unlikely(__pyx_kwds)) {
3600  Py_ssize_t kw_args;
3601  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
3602  switch (pos_args) {
3603  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
3604  CYTHON_FALLTHROUGH;
3605  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
3606  CYTHON_FALLTHROUGH;
3607  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
3608  CYTHON_FALLTHROUGH;
3609  case 0: break;
3610  default: goto __pyx_L5_argtuple_error;
3611  }
3612  kw_args = PyDict_Size(__pyx_kwds);
3613  switch (pos_args) {
3614  case 0:
3615  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x_elementBoundary)) != 0)) kw_args--;
3616  else goto __pyx_L5_argtuple_error;
3617  CYTHON_FALLTHROUGH;
3618  case 1:
3619  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rt0vdofs_element)) != 0)) kw_args--;
3620  else {
3621  __Pyx_RaiseArgtupleInvalid("getElementBoundaryRT0velocityValues", 1, 3, 3, 1); __PYX_ERR(0, 186, __pyx_L3_error)
3622  }
3623  CYTHON_FALLTHROUGH;
3624  case 2:
3625  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_v_elementBoundary)) != 0)) kw_args--;
3626  else {
3627  __Pyx_RaiseArgtupleInvalid("getElementBoundaryRT0velocityValues", 1, 3, 3, 2); __PYX_ERR(0, 186, __pyx_L3_error)
3628  }
3629  }
3630  if (unlikely(kw_args > 0)) {
3631  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "getElementBoundaryRT0velocityValues") < 0)) __PYX_ERR(0, 186, __pyx_L3_error)
3632  }
3633  } else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
3634  goto __pyx_L5_argtuple_error;
3635  } else {
3636  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
3637  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
3638  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
3639  }
3640  __pyx_v_x_elementBoundary = ((PyArrayObject *)values[0]);
3641  __pyx_v_rt0vdofs_element = ((PyArrayObject *)values[1]);
3642  __pyx_v_v_elementBoundary = ((PyArrayObject *)values[2]);
3643  }
3644  goto __pyx_L4_argument_unpacking_done;
3645  __pyx_L5_argtuple_error:;
3646  __Pyx_RaiseArgtupleInvalid("getElementBoundaryRT0velocityValues", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 186, __pyx_L3_error)
3647  __pyx_L3_error:;
3648  __Pyx_AddTraceback("cpostprocessing.getElementBoundaryRT0velocityValues", __pyx_clineno, __pyx_lineno, __pyx_filename);
3649  __Pyx_RefNannyFinishContext();
3650  return NULL;
3651  __pyx_L4_argument_unpacking_done:;
3652  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_elementBoundary), __pyx_ptype_5numpy_ndarray, 1, "x_elementBoundary", 0))) __PYX_ERR(0, 186, __pyx_L1_error)
3653  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rt0vdofs_element), __pyx_ptype_5numpy_ndarray, 1, "rt0vdofs_element", 0))) __PYX_ERR(0, 187, __pyx_L1_error)
3654  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_v_elementBoundary), __pyx_ptype_5numpy_ndarray, 1, "v_elementBoundary", 0))) __PYX_ERR(0, 188, __pyx_L1_error)
3655  __pyx_r = __pyx_pf_15cpostprocessing_10getElementBoundaryRT0velocityValues(__pyx_self, __pyx_v_x_elementBoundary, __pyx_v_rt0vdofs_element, __pyx_v_v_elementBoundary);
3656 
3657  /* function exit code */
3658  goto __pyx_L0;
3659  __pyx_L1_error:;
3660  __pyx_r = NULL;
3661  __pyx_L0:;
3662  __Pyx_RefNannyFinishContext();
3663  return __pyx_r;
3664 }
3665 
3666 static PyObject *__pyx_pf_15cpostprocessing_10getElementBoundaryRT0velocityValues(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_x_elementBoundary, PyArrayObject *__pyx_v_rt0vdofs_element, PyArrayObject *__pyx_v_v_elementBoundary) {
3667  PyObject *__pyx_r = NULL;
3668  __Pyx_RefNannyDeclarations
3669  __Pyx_RefNannySetupContext("getElementBoundaryRT0velocityValues", 0);
3670 
3671  /* "cpostprocessing.pyx":189
3672  * np.ndarray rt0vdofs_element,
3673  * np.ndarray v_elementBoundary):
3674  * pp.getElementBoundaryRT0velocityValues(v_elementBoundary.shape[0], # <<<<<<<<<<<<<<
3675  * v_elementBoundary.shape[1],
3676  * v_elementBoundary.shape[2],
3677  */
3678  getElementBoundaryRT0velocityValues((__pyx_v_v_elementBoundary->dimensions[0]), (__pyx_v_v_elementBoundary->dimensions[1]), (__pyx_v_v_elementBoundary->dimensions[2]), (__pyx_v_v_elementBoundary->dimensions[3]), ((double *)__pyx_v_x_elementBoundary->data), ((double *)__pyx_v_rt0vdofs_element->data), ((double *)__pyx_v_v_elementBoundary->data));
3679 
3680  /* "cpostprocessing.pyx":186
3681  * <double*>(v_element.data))
3682  *
3683  * def getElementBoundaryRT0velocityValues(np.ndarray x_elementBoundary, # <<<<<<<<<<<<<<
3684  * np.ndarray rt0vdofs_element,
3685  * np.ndarray v_elementBoundary):
3686  */
3687 
3688  /* function exit code */
3689  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
3690  __Pyx_XGIVEREF(__pyx_r);
3691  __Pyx_RefNannyFinishContext();
3692  return __pyx_r;
3693 }
3694 
3695 /* "cpostprocessing.pyx":197
3696  * <double*>(v_elementBoundary.data))
3697  *
3698  * def getGlobalElementBoundaryRT0velocityValues(np.ndarray elementBoundaryElementsArray, # <<<<<<<<<<<<<<
3699  * np.ndarray x_elementBoundary_global,
3700  * np.ndarray rt0vdofs_element,
3701  */
3702 
3703 /* Python wrapper */
3704 static PyObject *__pyx_pw_15cpostprocessing_13getGlobalElementBoundaryRT0velocityValues(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
3705 static PyMethodDef __pyx_mdef_15cpostprocessing_13getGlobalElementBoundaryRT0velocityValues = {"getGlobalElementBoundaryRT0velocityValues", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_13getGlobalElementBoundaryRT0velocityValues, METH_VARARGS|METH_KEYWORDS, 0};
3706 static PyObject *__pyx_pw_15cpostprocessing_13getGlobalElementBoundaryRT0velocityValues(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
3707  PyArrayObject *__pyx_v_elementBoundaryElementsArray = 0;
3708  PyArrayObject *__pyx_v_x_elementBoundary_global = 0;
3709  PyArrayObject *__pyx_v_rt0vdofs_element = 0;
3710  PyArrayObject *__pyx_v_v_elementBoundary_global = 0;
3711  int __pyx_lineno = 0;
3712  const char *__pyx_filename = NULL;
3713  int __pyx_clineno = 0;
3714  PyObject *__pyx_r = 0;
3715  __Pyx_RefNannyDeclarations
3716  __Pyx_RefNannySetupContext("getGlobalElementBoundaryRT0velocityValues (wrapper)", 0);
3717  {
3718  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_elementBoundaryElementsArray,&__pyx_n_s_x_elementBoundary_global,&__pyx_n_s_rt0vdofs_element,&__pyx_n_s_v_elementBoundary_global,0};
3719  PyObject* values[4] = {0,0,0,0};
3720  if (unlikely(__pyx_kwds)) {
3721  Py_ssize_t kw_args;
3722  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
3723  switch (pos_args) {
3724  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
3725  CYTHON_FALLTHROUGH;
3726  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
3727  CYTHON_FALLTHROUGH;
3728  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
3729  CYTHON_FALLTHROUGH;
3730  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
3731  CYTHON_FALLTHROUGH;
3732  case 0: break;
3733  default: goto __pyx_L5_argtuple_error;
3734  }
3735  kw_args = PyDict_Size(__pyx_kwds);
3736  switch (pos_args) {
3737  case 0:
3738  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryElementsArray)) != 0)) kw_args--;
3739  else goto __pyx_L5_argtuple_error;
3740  CYTHON_FALLTHROUGH;
3741  case 1:
3742  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x_elementBoundary_global)) != 0)) kw_args--;
3743  else {
3744  __Pyx_RaiseArgtupleInvalid("getGlobalElementBoundaryRT0velocityValues", 1, 4, 4, 1); __PYX_ERR(0, 197, __pyx_L3_error)
3745  }
3746  CYTHON_FALLTHROUGH;
3747  case 2:
3748  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rt0vdofs_element)) != 0)) kw_args--;
3749  else {
3750  __Pyx_RaiseArgtupleInvalid("getGlobalElementBoundaryRT0velocityValues", 1, 4, 4, 2); __PYX_ERR(0, 197, __pyx_L3_error)
3751  }
3752  CYTHON_FALLTHROUGH;
3753  case 3:
3754  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_v_elementBoundary_global)) != 0)) kw_args--;
3755  else {
3756  __Pyx_RaiseArgtupleInvalid("getGlobalElementBoundaryRT0velocityValues", 1, 4, 4, 3); __PYX_ERR(0, 197, __pyx_L3_error)
3757  }
3758  }
3759  if (unlikely(kw_args > 0)) {
3760  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "getGlobalElementBoundaryRT0velocityValues") < 0)) __PYX_ERR(0, 197, __pyx_L3_error)
3761  }
3762  } else if (PyTuple_GET_SIZE(__pyx_args) != 4) {
3763  goto __pyx_L5_argtuple_error;
3764  } else {
3765  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
3766  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
3767  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
3768  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
3769  }
3770  __pyx_v_elementBoundaryElementsArray = ((PyArrayObject *)values[0]);
3771  __pyx_v_x_elementBoundary_global = ((PyArrayObject *)values[1]);
3772  __pyx_v_rt0vdofs_element = ((PyArrayObject *)values[2]);
3773  __pyx_v_v_elementBoundary_global = ((PyArrayObject *)values[3]);
3774  }
3775  goto __pyx_L4_argument_unpacking_done;
3776  __pyx_L5_argtuple_error:;
3777  __Pyx_RaiseArgtupleInvalid("getGlobalElementBoundaryRT0velocityValues", 1, 4, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 197, __pyx_L3_error)
3778  __pyx_L3_error:;
3779  __Pyx_AddTraceback("cpostprocessing.getGlobalElementBoundaryRT0velocityValues", __pyx_clineno, __pyx_lineno, __pyx_filename);
3780  __Pyx_RefNannyFinishContext();
3781  return NULL;
3782  __pyx_L4_argument_unpacking_done:;
3783  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryElementsArray), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryElementsArray", 0))) __PYX_ERR(0, 197, __pyx_L1_error)
3784  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_elementBoundary_global), __pyx_ptype_5numpy_ndarray, 1, "x_elementBoundary_global", 0))) __PYX_ERR(0, 198, __pyx_L1_error)
3785  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rt0vdofs_element), __pyx_ptype_5numpy_ndarray, 1, "rt0vdofs_element", 0))) __PYX_ERR(0, 199, __pyx_L1_error)
3786  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_v_elementBoundary_global), __pyx_ptype_5numpy_ndarray, 1, "v_elementBoundary_global", 0))) __PYX_ERR(0, 200, __pyx_L1_error)
3787  __pyx_r = __pyx_pf_15cpostprocessing_12getGlobalElementBoundaryRT0velocityValues(__pyx_self, __pyx_v_elementBoundaryElementsArray, __pyx_v_x_elementBoundary_global, __pyx_v_rt0vdofs_element, __pyx_v_v_elementBoundary_global);
3788 
3789  /* function exit code */
3790  goto __pyx_L0;
3791  __pyx_L1_error:;
3792  __pyx_r = NULL;
3793  __pyx_L0:;
3794  __Pyx_RefNannyFinishContext();
3795  return __pyx_r;
3796 }
3797 
3798 static PyObject *__pyx_pf_15cpostprocessing_12getGlobalElementBoundaryRT0velocityValues(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_elementBoundaryElementsArray, PyArrayObject *__pyx_v_x_elementBoundary_global, PyArrayObject *__pyx_v_rt0vdofs_element, PyArrayObject *__pyx_v_v_elementBoundary_global) {
3799  PyObject *__pyx_r = NULL;
3800  __Pyx_RefNannyDeclarations
3801  __Pyx_RefNannySetupContext("getGlobalElementBoundaryRT0velocityValues", 0);
3802 
3803  /* "cpostprocessing.pyx":201
3804  * np.ndarray rt0vdofs_element,
3805  * np.ndarray v_elementBoundary_global):
3806  * pp.getGlobalElementBoundaryRT0velocityValues(v_elementBoundary_global.shape[0], # <<<<<<<<<<<<<<
3807  * v_elementBoundary_global.shape[1],
3808  * v_elementBoundary_global.shape[2],
3809  */
3810  getGlobalElementBoundaryRT0velocityValues((__pyx_v_v_elementBoundary_global->dimensions[0]), (__pyx_v_v_elementBoundary_global->dimensions[1]), (__pyx_v_v_elementBoundary_global->dimensions[2]), ((int *)__pyx_v_elementBoundaryElementsArray->data), ((double *)__pyx_v_x_elementBoundary_global->data), ((double *)__pyx_v_rt0vdofs_element->data), ((double *)__pyx_v_v_elementBoundary_global->data));
3811 
3812  /* "cpostprocessing.pyx":197
3813  * <double*>(v_elementBoundary.data))
3814  *
3815  * def getGlobalElementBoundaryRT0velocityValues(np.ndarray elementBoundaryElementsArray, # <<<<<<<<<<<<<<
3816  * np.ndarray x_elementBoundary_global,
3817  * np.ndarray rt0vdofs_element,
3818  */
3819 
3820  /* function exit code */
3821  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
3822  __Pyx_XGIVEREF(__pyx_r);
3823  __Pyx_RefNannyFinishContext();
3824  return __pyx_r;
3825 }
3826 
3827 /* "cpostprocessing.pyx":209
3828  * <double*>(v_elementBoundary_global.data))
3829  *
3830  * def getGlobalExteriorElementBoundaryRT0velocityValues(np.ndarray exteriorElementBoundariesArray, # <<<<<<<<<<<<<<
3831  * np.ndarray elementBoundaryElementsArray,
3832  * np.ndarray x_elementBoundary_global,
3833  */
3834 
3835 /* Python wrapper */
3836 static PyObject *__pyx_pw_15cpostprocessing_15getGlobalExteriorElementBoundaryRT0velocityValues(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
3837 static PyMethodDef __pyx_mdef_15cpostprocessing_15getGlobalExteriorElementBoundaryRT0velocityValues = {"getGlobalExteriorElementBoundaryRT0velocityValues", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_15getGlobalExteriorElementBoundaryRT0velocityValues, METH_VARARGS|METH_KEYWORDS, 0};
3838 static PyObject *__pyx_pw_15cpostprocessing_15getGlobalExteriorElementBoundaryRT0velocityValues(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
3839  PyArrayObject *__pyx_v_exteriorElementBoundariesArray = 0;
3840  PyArrayObject *__pyx_v_elementBoundaryElementsArray = 0;
3841  PyArrayObject *__pyx_v_x_elementBoundary_global = 0;
3842  PyArrayObject *__pyx_v_rt0vdofs_element = 0;
3843  PyArrayObject *__pyx_v_v_elementBoundary_global = 0;
3844  int __pyx_lineno = 0;
3845  const char *__pyx_filename = NULL;
3846  int __pyx_clineno = 0;
3847  PyObject *__pyx_r = 0;
3848  __Pyx_RefNannyDeclarations
3849  __Pyx_RefNannySetupContext("getGlobalExteriorElementBoundaryRT0velocityValues (wrapper)", 0);
3850  {
3851  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_exteriorElementBoundariesArray,&__pyx_n_s_elementBoundaryElementsArray,&__pyx_n_s_x_elementBoundary_global,&__pyx_n_s_rt0vdofs_element,&__pyx_n_s_v_elementBoundary_global,0};
3852  PyObject* values[5] = {0,0,0,0,0};
3853  if (unlikely(__pyx_kwds)) {
3854  Py_ssize_t kw_args;
3855  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
3856  switch (pos_args) {
3857  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
3858  CYTHON_FALLTHROUGH;
3859  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
3860  CYTHON_FALLTHROUGH;
3861  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
3862  CYTHON_FALLTHROUGH;
3863  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
3864  CYTHON_FALLTHROUGH;
3865  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
3866  CYTHON_FALLTHROUGH;
3867  case 0: break;
3868  default: goto __pyx_L5_argtuple_error;
3869  }
3870  kw_args = PyDict_Size(__pyx_kwds);
3871  switch (pos_args) {
3872  case 0:
3873  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_exteriorElementBoundariesArray)) != 0)) kw_args--;
3874  else goto __pyx_L5_argtuple_error;
3875  CYTHON_FALLTHROUGH;
3876  case 1:
3877  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryElementsArray)) != 0)) kw_args--;
3878  else {
3879  __Pyx_RaiseArgtupleInvalid("getGlobalExteriorElementBoundaryRT0velocityValues", 1, 5, 5, 1); __PYX_ERR(0, 209, __pyx_L3_error)
3880  }
3881  CYTHON_FALLTHROUGH;
3882  case 2:
3883  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x_elementBoundary_global)) != 0)) kw_args--;
3884  else {
3885  __Pyx_RaiseArgtupleInvalid("getGlobalExteriorElementBoundaryRT0velocityValues", 1, 5, 5, 2); __PYX_ERR(0, 209, __pyx_L3_error)
3886  }
3887  CYTHON_FALLTHROUGH;
3888  case 3:
3889  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rt0vdofs_element)) != 0)) kw_args--;
3890  else {
3891  __Pyx_RaiseArgtupleInvalid("getGlobalExteriorElementBoundaryRT0velocityValues", 1, 5, 5, 3); __PYX_ERR(0, 209, __pyx_L3_error)
3892  }
3893  CYTHON_FALLTHROUGH;
3894  case 4:
3895  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_v_elementBoundary_global)) != 0)) kw_args--;
3896  else {
3897  __Pyx_RaiseArgtupleInvalid("getGlobalExteriorElementBoundaryRT0velocityValues", 1, 5, 5, 4); __PYX_ERR(0, 209, __pyx_L3_error)
3898  }
3899  }
3900  if (unlikely(kw_args > 0)) {
3901  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "getGlobalExteriorElementBoundaryRT0velocityValues") < 0)) __PYX_ERR(0, 209, __pyx_L3_error)
3902  }
3903  } else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
3904  goto __pyx_L5_argtuple_error;
3905  } else {
3906  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
3907  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
3908  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
3909  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
3910  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
3911  }
3912  __pyx_v_exteriorElementBoundariesArray = ((PyArrayObject *)values[0]);
3913  __pyx_v_elementBoundaryElementsArray = ((PyArrayObject *)values[1]);
3914  __pyx_v_x_elementBoundary_global = ((PyArrayObject *)values[2]);
3915  __pyx_v_rt0vdofs_element = ((PyArrayObject *)values[3]);
3916  __pyx_v_v_elementBoundary_global = ((PyArrayObject *)values[4]);
3917  }
3918  goto __pyx_L4_argument_unpacking_done;
3919  __pyx_L5_argtuple_error:;
3920  __Pyx_RaiseArgtupleInvalid("getGlobalExteriorElementBoundaryRT0velocityValues", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 209, __pyx_L3_error)
3921  __pyx_L3_error:;
3922  __Pyx_AddTraceback("cpostprocessing.getGlobalExteriorElementBoundaryRT0velocityValues", __pyx_clineno, __pyx_lineno, __pyx_filename);
3923  __Pyx_RefNannyFinishContext();
3924  return NULL;
3925  __pyx_L4_argument_unpacking_done:;
3926  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_exteriorElementBoundariesArray), __pyx_ptype_5numpy_ndarray, 1, "exteriorElementBoundariesArray", 0))) __PYX_ERR(0, 209, __pyx_L1_error)
3927  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryElementsArray), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryElementsArray", 0))) __PYX_ERR(0, 210, __pyx_L1_error)
3928  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_elementBoundary_global), __pyx_ptype_5numpy_ndarray, 1, "x_elementBoundary_global", 0))) __PYX_ERR(0, 211, __pyx_L1_error)
3929  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rt0vdofs_element), __pyx_ptype_5numpy_ndarray, 1, "rt0vdofs_element", 0))) __PYX_ERR(0, 212, __pyx_L1_error)
3930  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_v_elementBoundary_global), __pyx_ptype_5numpy_ndarray, 1, "v_elementBoundary_global", 0))) __PYX_ERR(0, 213, __pyx_L1_error)
3931  __pyx_r = __pyx_pf_15cpostprocessing_14getGlobalExteriorElementBoundaryRT0velocityValues(__pyx_self, __pyx_v_exteriorElementBoundariesArray, __pyx_v_elementBoundaryElementsArray, __pyx_v_x_elementBoundary_global, __pyx_v_rt0vdofs_element, __pyx_v_v_elementBoundary_global);
3932 
3933  /* function exit code */
3934  goto __pyx_L0;
3935  __pyx_L1_error:;
3936  __pyx_r = NULL;
3937  __pyx_L0:;
3938  __Pyx_RefNannyFinishContext();
3939  return __pyx_r;
3940 }
3941 
3942 static PyObject *__pyx_pf_15cpostprocessing_14getGlobalExteriorElementBoundaryRT0velocityValues(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_exteriorElementBoundariesArray, PyArrayObject *__pyx_v_elementBoundaryElementsArray, PyArrayObject *__pyx_v_x_elementBoundary_global, PyArrayObject *__pyx_v_rt0vdofs_element, PyArrayObject *__pyx_v_v_elementBoundary_global) {
3943  PyObject *__pyx_r = NULL;
3944  __Pyx_RefNannyDeclarations
3945  __Pyx_RefNannySetupContext("getGlobalExteriorElementBoundaryRT0velocityValues", 0);
3946 
3947  /* "cpostprocessing.pyx":214
3948  * np.ndarray rt0vdofs_element,
3949  * np.ndarray v_elementBoundary_global):
3950  * pp.getGlobalExteriorElementBoundaryRT0velocityValues(exteriorElementBoundariesArray.shape[0], # <<<<<<<<<<<<<<
3951  * v_elementBoundary_global.shape[1],
3952  * v_elementBoundary_global.shape[2],
3953  */
3954  getGlobalExteriorElementBoundaryRT0velocityValues((__pyx_v_exteriorElementBoundariesArray->dimensions[0]), (__pyx_v_v_elementBoundary_global->dimensions[1]), (__pyx_v_v_elementBoundary_global->dimensions[2]), ((int *)__pyx_v_elementBoundaryElementsArray->data), ((int *)__pyx_v_exteriorElementBoundariesArray->data), ((double *)__pyx_v_x_elementBoundary_global->data), ((double *)__pyx_v_rt0vdofs_element->data), ((double *)__pyx_v_v_elementBoundary_global->data));
3955 
3956  /* "cpostprocessing.pyx":209
3957  * <double*>(v_elementBoundary_global.data))
3958  *
3959  * def getGlobalExteriorElementBoundaryRT0velocityValues(np.ndarray exteriorElementBoundariesArray, # <<<<<<<<<<<<<<
3960  * np.ndarray elementBoundaryElementsArray,
3961  * np.ndarray x_elementBoundary_global,
3962  */
3963 
3964  /* function exit code */
3965  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
3966  __Pyx_XGIVEREF(__pyx_r);
3967  __Pyx_RefNannyFinishContext();
3968  return __pyx_r;
3969 }
3970 
3971 /* "cpostprocessing.pyx":223
3972  * <double*>(v_elementBoundary_global.data))
3973  *
3974  * def postProcessRT0potentialFromP1nc(np.ndarray uQuadratureWeights_element, # <<<<<<<<<<<<<<
3975  * np.ndarray elementBarycenters,
3976  * np.ndarray aElementQuadWeights,
3977  */
3978 
3979 /* Python wrapper */
3980 static PyObject *__pyx_pw_15cpostprocessing_17postProcessRT0potentialFromP1nc(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
3981 static PyMethodDef __pyx_mdef_15cpostprocessing_17postProcessRT0potentialFromP1nc = {"postProcessRT0potentialFromP1nc", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_17postProcessRT0potentialFromP1nc, METH_VARARGS|METH_KEYWORDS, 0};
3982 static PyObject *__pyx_pw_15cpostprocessing_17postProcessRT0potentialFromP1nc(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
3983  PyArrayObject *__pyx_v_uQuadratureWeights_element = 0;
3984  PyArrayObject *__pyx_v_elementBarycenters = 0;
3985  PyArrayObject *__pyx_v_aElementQuadWeights = 0;
3986  PyArrayObject *__pyx_v_detJ = 0;
3987  CYTHON_UNUSED PyArrayObject *__pyx_v_uQuadratureWeights_elementBoundary = 0;
3988  PyArrayObject *__pyx_v_x = 0;
3989  PyArrayObject *__pyx_v_u = 0;
3990  PyArrayObject *__pyx_v_gradu = 0;
3991  PyArrayObject *__pyx_v_x_elementBoundary = 0;
3992  PyArrayObject *__pyx_v_u_elementBoundary = 0;
3993  PyArrayObject *__pyx_v_n = 0;
3994  PyArrayObject *__pyx_v_a = 0;
3995  PyArrayObject *__pyx_v_f = 0;
3996  PyArrayObject *__pyx_v_r = 0;
3997  PyArrayObject *__pyx_v_rt0vdofs = 0;
3998  PyArrayObject *__pyx_v_rt0potential = 0;
3999  int __pyx_lineno = 0;
4000  const char *__pyx_filename = NULL;
4001  int __pyx_clineno = 0;
4002  PyObject *__pyx_r = 0;
4003  __Pyx_RefNannyDeclarations
4004  __Pyx_RefNannySetupContext("postProcessRT0potentialFromP1nc (wrapper)", 0);
4005  {
4006  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_uQuadratureWeights_element,&__pyx_n_s_elementBarycenters,&__pyx_n_s_aElementQuadWeights,&__pyx_n_s_detJ,&__pyx_n_s_uQuadratureWeights_elementBounda,&__pyx_n_s_x,&__pyx_n_s_u,&__pyx_n_s_gradu,&__pyx_n_s_x_elementBoundary,&__pyx_n_s_u_elementBoundary,&__pyx_n_s_n,&__pyx_n_s_a,&__pyx_n_s_f,&__pyx_n_s_r,&__pyx_n_s_rt0vdofs,&__pyx_n_s_rt0potential,0};
4007  PyObject* values[16] = {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0};
4008  if (unlikely(__pyx_kwds)) {
4009  Py_ssize_t kw_args;
4010  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
4011  switch (pos_args) {
4012  case 16: values[15] = PyTuple_GET_ITEM(__pyx_args, 15);
4013  CYTHON_FALLTHROUGH;
4014  case 15: values[14] = PyTuple_GET_ITEM(__pyx_args, 14);
4015  CYTHON_FALLTHROUGH;
4016  case 14: values[13] = PyTuple_GET_ITEM(__pyx_args, 13);
4017  CYTHON_FALLTHROUGH;
4018  case 13: values[12] = PyTuple_GET_ITEM(__pyx_args, 12);
4019  CYTHON_FALLTHROUGH;
4020  case 12: values[11] = PyTuple_GET_ITEM(__pyx_args, 11);
4021  CYTHON_FALLTHROUGH;
4022  case 11: values[10] = PyTuple_GET_ITEM(__pyx_args, 10);
4023  CYTHON_FALLTHROUGH;
4024  case 10: values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
4025  CYTHON_FALLTHROUGH;
4026  case 9: values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
4027  CYTHON_FALLTHROUGH;
4028  case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
4029  CYTHON_FALLTHROUGH;
4030  case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
4031  CYTHON_FALLTHROUGH;
4032  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
4033  CYTHON_FALLTHROUGH;
4034  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
4035  CYTHON_FALLTHROUGH;
4036  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
4037  CYTHON_FALLTHROUGH;
4038  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
4039  CYTHON_FALLTHROUGH;
4040  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
4041  CYTHON_FALLTHROUGH;
4042  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
4043  CYTHON_FALLTHROUGH;
4044  case 0: break;
4045  default: goto __pyx_L5_argtuple_error;
4046  }
4047  kw_args = PyDict_Size(__pyx_kwds);
4048  switch (pos_args) {
4049  case 0:
4050  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_uQuadratureWeights_element)) != 0)) kw_args--;
4051  else goto __pyx_L5_argtuple_error;
4052  CYTHON_FALLTHROUGH;
4053  case 1:
4054  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBarycenters)) != 0)) kw_args--;
4055  else {
4056  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc", 1, 16, 16, 1); __PYX_ERR(0, 223, __pyx_L3_error)
4057  }
4058  CYTHON_FALLTHROUGH;
4059  case 2:
4060  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_aElementQuadWeights)) != 0)) kw_args--;
4061  else {
4062  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc", 1, 16, 16, 2); __PYX_ERR(0, 223, __pyx_L3_error)
4063  }
4064  CYTHON_FALLTHROUGH;
4065  case 3:
4066  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_detJ)) != 0)) kw_args--;
4067  else {
4068  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc", 1, 16, 16, 3); __PYX_ERR(0, 223, __pyx_L3_error)
4069  }
4070  CYTHON_FALLTHROUGH;
4071  case 4:
4072  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_uQuadratureWeights_elementBounda)) != 0)) kw_args--;
4073  else {
4074  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc", 1, 16, 16, 4); __PYX_ERR(0, 223, __pyx_L3_error)
4075  }
4076  CYTHON_FALLTHROUGH;
4077  case 5:
4078  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
4079  else {
4080  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc", 1, 16, 16, 5); __PYX_ERR(0, 223, __pyx_L3_error)
4081  }
4082  CYTHON_FALLTHROUGH;
4083  case 6:
4084  if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
4085  else {
4086  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc", 1, 16, 16, 6); __PYX_ERR(0, 223, __pyx_L3_error)
4087  }
4088  CYTHON_FALLTHROUGH;
4089  case 7:
4090  if (likely((values[7] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_gradu)) != 0)) kw_args--;
4091  else {
4092  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc", 1, 16, 16, 7); __PYX_ERR(0, 223, __pyx_L3_error)
4093  }
4094  CYTHON_FALLTHROUGH;
4095  case 8:
4096  if (likely((values[8] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x_elementBoundary)) != 0)) kw_args--;
4097  else {
4098  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc", 1, 16, 16, 8); __PYX_ERR(0, 223, __pyx_L3_error)
4099  }
4100  CYTHON_FALLTHROUGH;
4101  case 9:
4102  if (likely((values[9] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u_elementBoundary)) != 0)) kw_args--;
4103  else {
4104  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc", 1, 16, 16, 9); __PYX_ERR(0, 223, __pyx_L3_error)
4105  }
4106  CYTHON_FALLTHROUGH;
4107  case 10:
4108  if (likely((values[10] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_n)) != 0)) kw_args--;
4109  else {
4110  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc", 1, 16, 16, 10); __PYX_ERR(0, 223, __pyx_L3_error)
4111  }
4112  CYTHON_FALLTHROUGH;
4113  case 11:
4114  if (likely((values[11] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_a)) != 0)) kw_args--;
4115  else {
4116  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc", 1, 16, 16, 11); __PYX_ERR(0, 223, __pyx_L3_error)
4117  }
4118  CYTHON_FALLTHROUGH;
4119  case 12:
4120  if (likely((values[12] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_f)) != 0)) kw_args--;
4121  else {
4122  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc", 1, 16, 16, 12); __PYX_ERR(0, 223, __pyx_L3_error)
4123  }
4124  CYTHON_FALLTHROUGH;
4125  case 13:
4126  if (likely((values[13] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_r)) != 0)) kw_args--;
4127  else {
4128  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc", 1, 16, 16, 13); __PYX_ERR(0, 223, __pyx_L3_error)
4129  }
4130  CYTHON_FALLTHROUGH;
4131  case 14:
4132  if (likely((values[14] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rt0vdofs)) != 0)) kw_args--;
4133  else {
4134  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc", 1, 16, 16, 14); __PYX_ERR(0, 223, __pyx_L3_error)
4135  }
4136  CYTHON_FALLTHROUGH;
4137  case 15:
4138  if (likely((values[15] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rt0potential)) != 0)) kw_args--;
4139  else {
4140  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc", 1, 16, 16, 15); __PYX_ERR(0, 223, __pyx_L3_error)
4141  }
4142  }
4143  if (unlikely(kw_args > 0)) {
4144  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "postProcessRT0potentialFromP1nc") < 0)) __PYX_ERR(0, 223, __pyx_L3_error)
4145  }
4146  } else if (PyTuple_GET_SIZE(__pyx_args) != 16) {
4147  goto __pyx_L5_argtuple_error;
4148  } else {
4149  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
4150  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
4151  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
4152  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
4153  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
4154  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
4155  values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
4156  values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
4157  values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
4158  values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
4159  values[10] = PyTuple_GET_ITEM(__pyx_args, 10);
4160  values[11] = PyTuple_GET_ITEM(__pyx_args, 11);
4161  values[12] = PyTuple_GET_ITEM(__pyx_args, 12);
4162  values[13] = PyTuple_GET_ITEM(__pyx_args, 13);
4163  values[14] = PyTuple_GET_ITEM(__pyx_args, 14);
4164  values[15] = PyTuple_GET_ITEM(__pyx_args, 15);
4165  }
4166  __pyx_v_uQuadratureWeights_element = ((PyArrayObject *)values[0]);
4167  __pyx_v_elementBarycenters = ((PyArrayObject *)values[1]);
4168  __pyx_v_aElementQuadWeights = ((PyArrayObject *)values[2]);
4169  __pyx_v_detJ = ((PyArrayObject *)values[3]);
4170  __pyx_v_uQuadratureWeights_elementBoundary = ((PyArrayObject *)values[4]);
4171  __pyx_v_x = ((PyArrayObject *)values[5]);
4172  __pyx_v_u = ((PyArrayObject *)values[6]);
4173  __pyx_v_gradu = ((PyArrayObject *)values[7]);
4174  __pyx_v_x_elementBoundary = ((PyArrayObject *)values[8]);
4175  __pyx_v_u_elementBoundary = ((PyArrayObject *)values[9]);
4176  __pyx_v_n = ((PyArrayObject *)values[10]);
4177  __pyx_v_a = ((PyArrayObject *)values[11]);
4178  __pyx_v_f = ((PyArrayObject *)values[12]);
4179  __pyx_v_r = ((PyArrayObject *)values[13]);
4180  __pyx_v_rt0vdofs = ((PyArrayObject *)values[14]);
4181  __pyx_v_rt0potential = ((PyArrayObject *)values[15]);
4182  }
4183  goto __pyx_L4_argument_unpacking_done;
4184  __pyx_L5_argtuple_error:;
4185  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc", 1, 16, 16, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 223, __pyx_L3_error)
4186  __pyx_L3_error:;
4187  __Pyx_AddTraceback("cpostprocessing.postProcessRT0potentialFromP1nc", __pyx_clineno, __pyx_lineno, __pyx_filename);
4188  __Pyx_RefNannyFinishContext();
4189  return NULL;
4190  __pyx_L4_argument_unpacking_done:;
4191  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_uQuadratureWeights_element), __pyx_ptype_5numpy_ndarray, 1, "uQuadratureWeights_element", 0))) __PYX_ERR(0, 223, __pyx_L1_error)
4192  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBarycenters), __pyx_ptype_5numpy_ndarray, 1, "elementBarycenters", 0))) __PYX_ERR(0, 224, __pyx_L1_error)
4193  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_aElementQuadWeights), __pyx_ptype_5numpy_ndarray, 1, "aElementQuadWeights", 0))) __PYX_ERR(0, 225, __pyx_L1_error)
4194  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_detJ), __pyx_ptype_5numpy_ndarray, 1, "detJ", 0))) __PYX_ERR(0, 226, __pyx_L1_error)
4195  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_uQuadratureWeights_elementBoundary), __pyx_ptype_5numpy_ndarray, 1, "uQuadratureWeights_elementBoundary", 0))) __PYX_ERR(0, 227, __pyx_L1_error)
4196  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1, "x", 0))) __PYX_ERR(0, 228, __pyx_L1_error)
4197  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1, "u", 0))) __PYX_ERR(0, 229, __pyx_L1_error)
4198  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_gradu), __pyx_ptype_5numpy_ndarray, 1, "gradu", 0))) __PYX_ERR(0, 230, __pyx_L1_error)
4199  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_elementBoundary), __pyx_ptype_5numpy_ndarray, 1, "x_elementBoundary", 0))) __PYX_ERR(0, 231, __pyx_L1_error)
4200  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u_elementBoundary), __pyx_ptype_5numpy_ndarray, 1, "u_elementBoundary", 0))) __PYX_ERR(0, 232, __pyx_L1_error)
4201  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_n), __pyx_ptype_5numpy_ndarray, 1, "n", 0))) __PYX_ERR(0, 233, __pyx_L1_error)
4202  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 234, __pyx_L1_error)
4203  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_f), __pyx_ptype_5numpy_ndarray, 1, "f", 0))) __PYX_ERR(0, 235, __pyx_L1_error)
4204  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_r), __pyx_ptype_5numpy_ndarray, 1, "r", 0))) __PYX_ERR(0, 236, __pyx_L1_error)
4205  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rt0vdofs), __pyx_ptype_5numpy_ndarray, 1, "rt0vdofs", 0))) __PYX_ERR(0, 237, __pyx_L1_error)
4206  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rt0potential), __pyx_ptype_5numpy_ndarray, 1, "rt0potential", 0))) __PYX_ERR(0, 238, __pyx_L1_error)
4207  __pyx_r = __pyx_pf_15cpostprocessing_16postProcessRT0potentialFromP1nc(__pyx_self, __pyx_v_uQuadratureWeights_element, __pyx_v_elementBarycenters, __pyx_v_aElementQuadWeights, __pyx_v_detJ, __pyx_v_uQuadratureWeights_elementBoundary, __pyx_v_x, __pyx_v_u, __pyx_v_gradu, __pyx_v_x_elementBoundary, __pyx_v_u_elementBoundary, __pyx_v_n, __pyx_v_a, __pyx_v_f, __pyx_v_r, __pyx_v_rt0vdofs, __pyx_v_rt0potential);
4208 
4209  /* function exit code */
4210  goto __pyx_L0;
4211  __pyx_L1_error:;
4212  __pyx_r = NULL;
4213  __pyx_L0:;
4214  __Pyx_RefNannyFinishContext();
4215  return __pyx_r;
4216 }
4217 
4218 static PyObject *__pyx_pf_15cpostprocessing_16postProcessRT0potentialFromP1nc(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_uQuadratureWeights_element, PyArrayObject *__pyx_v_elementBarycenters, PyArrayObject *__pyx_v_aElementQuadWeights, PyArrayObject *__pyx_v_detJ, CYTHON_UNUSED PyArrayObject *__pyx_v_uQuadratureWeights_elementBoundary, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_gradu, PyArrayObject *__pyx_v_x_elementBoundary, PyArrayObject *__pyx_v_u_elementBoundary, PyArrayObject *__pyx_v_n, PyArrayObject *__pyx_v_a, PyArrayObject *__pyx_v_f, PyArrayObject *__pyx_v_r, PyArrayObject *__pyx_v_rt0vdofs, PyArrayObject *__pyx_v_rt0potential) {
4219  PyObject *__pyx_r = NULL;
4220  __Pyx_RefNannyDeclarations
4221  __Pyx_RefNannySetupContext("postProcessRT0potentialFromP1nc", 0);
4222 
4223  /* "cpostprocessing.pyx":239
4224  * np.ndarray rt0vdofs,
4225  * np.ndarray rt0potential):
4226  * pp.postProcessRT0potentialFromP1nc(u.shape[0], # <<<<<<<<<<<<<<
4227  * u.shape[1],
4228  * n.shape[1],
4229  */
4230  postProcessRT0potentialFromP1nc((__pyx_v_u->dimensions[0]), (__pyx_v_u->dimensions[1]), (__pyx_v_n->dimensions[1]), (__pyx_v_n->dimensions[2]), (__pyx_v_n->dimensions[3]), ((double *)__pyx_v_uQuadratureWeights_element->data), ((double *)__pyx_v_elementBarycenters->data), ((double *)__pyx_v_aElementQuadWeights->data), ((double *)__pyx_v_detJ->data), ((double *)__pyx_v_uQuadratureWeights_element->data), ((double *)__pyx_v_x->data), ((double *)__pyx_v_u->data), ((double *)__pyx_v_gradu->data), ((double *)__pyx_v_x_elementBoundary->data), ((double *)__pyx_v_u_elementBoundary->data), ((double *)__pyx_v_n->data), ((double *)__pyx_v_a->data), ((double *)__pyx_v_f->data), ((double *)__pyx_v_r->data), ((double *)__pyx_v_rt0vdofs->data), ((double *)__pyx_v_rt0potential->data));
4231 
4232  /* "cpostprocessing.pyx":223
4233  * <double*>(v_elementBoundary_global.data))
4234  *
4235  * def postProcessRT0potentialFromP1nc(np.ndarray uQuadratureWeights_element, # <<<<<<<<<<<<<<
4236  * np.ndarray elementBarycenters,
4237  * np.ndarray aElementQuadWeights,
4238  */
4239 
4240  /* function exit code */
4241  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
4242  __Pyx_XGIVEREF(__pyx_r);
4243  __Pyx_RefNannyFinishContext();
4244  return __pyx_r;
4245 }
4246 
4247 /* "cpostprocessing.pyx":261
4248  * <double*>(rt0potential.data))
4249  *
4250  * def postProcessRT0potentialFromP1nc_sd(np.ndarray rowptr, # <<<<<<<<<<<<<<
4251  * np.ndarray colind,
4252  * np.ndarray uQuadratureWeights_element,
4253  */
4254 
4255 /* Python wrapper */
4256 static PyObject *__pyx_pw_15cpostprocessing_19postProcessRT0potentialFromP1nc_sd(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
4257 static PyMethodDef __pyx_mdef_15cpostprocessing_19postProcessRT0potentialFromP1nc_sd = {"postProcessRT0potentialFromP1nc_sd", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_19postProcessRT0potentialFromP1nc_sd, METH_VARARGS|METH_KEYWORDS, 0};
4258 static PyObject *__pyx_pw_15cpostprocessing_19postProcessRT0potentialFromP1nc_sd(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
4259  PyArrayObject *__pyx_v_rowptr = 0;
4260  PyArrayObject *__pyx_v_colind = 0;
4261  PyArrayObject *__pyx_v_uQuadratureWeights_element = 0;
4262  PyArrayObject *__pyx_v_elementBarycenters = 0;
4263  PyArrayObject *__pyx_v_aElementQuadWeights = 0;
4264  PyArrayObject *__pyx_v_detJ = 0;
4265  CYTHON_UNUSED PyArrayObject *__pyx_v_uQuadratureWeights_elementBoundary = 0;
4266  PyArrayObject *__pyx_v_x = 0;
4267  PyArrayObject *__pyx_v_u = 0;
4268  PyArrayObject *__pyx_v_gradu = 0;
4269  PyArrayObject *__pyx_v_x_elementBoundary = 0;
4270  PyArrayObject *__pyx_v_u_elementBoundary = 0;
4271  PyArrayObject *__pyx_v_n = 0;
4272  PyArrayObject *__pyx_v_a = 0;
4273  PyArrayObject *__pyx_v_f = 0;
4274  PyArrayObject *__pyx_v_r = 0;
4275  PyArrayObject *__pyx_v_rt0vdofs = 0;
4276  PyArrayObject *__pyx_v_rt0potential = 0;
4277  int __pyx_lineno = 0;
4278  const char *__pyx_filename = NULL;
4279  int __pyx_clineno = 0;
4280  PyObject *__pyx_r = 0;
4281  __Pyx_RefNannyDeclarations
4282  __Pyx_RefNannySetupContext("postProcessRT0potentialFromP1nc_sd (wrapper)", 0);
4283  {
4284  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_rowptr,&__pyx_n_s_colind,&__pyx_n_s_uQuadratureWeights_element,&__pyx_n_s_elementBarycenters,&__pyx_n_s_aElementQuadWeights,&__pyx_n_s_detJ,&__pyx_n_s_uQuadratureWeights_elementBounda,&__pyx_n_s_x,&__pyx_n_s_u,&__pyx_n_s_gradu,&__pyx_n_s_x_elementBoundary,&__pyx_n_s_u_elementBoundary,&__pyx_n_s_n,&__pyx_n_s_a,&__pyx_n_s_f,&__pyx_n_s_r,&__pyx_n_s_rt0vdofs,&__pyx_n_s_rt0potential,0};
4285  PyObject* values[18] = {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0};
4286  if (unlikely(__pyx_kwds)) {
4287  Py_ssize_t kw_args;
4288  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
4289  switch (pos_args) {
4290  case 18: values[17] = PyTuple_GET_ITEM(__pyx_args, 17);
4291  CYTHON_FALLTHROUGH;
4292  case 17: values[16] = PyTuple_GET_ITEM(__pyx_args, 16);
4293  CYTHON_FALLTHROUGH;
4294  case 16: values[15] = PyTuple_GET_ITEM(__pyx_args, 15);
4295  CYTHON_FALLTHROUGH;
4296  case 15: values[14] = PyTuple_GET_ITEM(__pyx_args, 14);
4297  CYTHON_FALLTHROUGH;
4298  case 14: values[13] = PyTuple_GET_ITEM(__pyx_args, 13);
4299  CYTHON_FALLTHROUGH;
4300  case 13: values[12] = PyTuple_GET_ITEM(__pyx_args, 12);
4301  CYTHON_FALLTHROUGH;
4302  case 12: values[11] = PyTuple_GET_ITEM(__pyx_args, 11);
4303  CYTHON_FALLTHROUGH;
4304  case 11: values[10] = PyTuple_GET_ITEM(__pyx_args, 10);
4305  CYTHON_FALLTHROUGH;
4306  case 10: values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
4307  CYTHON_FALLTHROUGH;
4308  case 9: values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
4309  CYTHON_FALLTHROUGH;
4310  case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
4311  CYTHON_FALLTHROUGH;
4312  case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
4313  CYTHON_FALLTHROUGH;
4314  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
4315  CYTHON_FALLTHROUGH;
4316  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
4317  CYTHON_FALLTHROUGH;
4318  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
4319  CYTHON_FALLTHROUGH;
4320  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
4321  CYTHON_FALLTHROUGH;
4322  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
4323  CYTHON_FALLTHROUGH;
4324  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
4325  CYTHON_FALLTHROUGH;
4326  case 0: break;
4327  default: goto __pyx_L5_argtuple_error;
4328  }
4329  kw_args = PyDict_Size(__pyx_kwds);
4330  switch (pos_args) {
4331  case 0:
4332  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rowptr)) != 0)) kw_args--;
4333  else goto __pyx_L5_argtuple_error;
4334  CYTHON_FALLTHROUGH;
4335  case 1:
4336  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_colind)) != 0)) kw_args--;
4337  else {
4338  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc_sd", 1, 18, 18, 1); __PYX_ERR(0, 261, __pyx_L3_error)
4339  }
4340  CYTHON_FALLTHROUGH;
4341  case 2:
4342  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_uQuadratureWeights_element)) != 0)) kw_args--;
4343  else {
4344  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc_sd", 1, 18, 18, 2); __PYX_ERR(0, 261, __pyx_L3_error)
4345  }
4346  CYTHON_FALLTHROUGH;
4347  case 3:
4348  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBarycenters)) != 0)) kw_args--;
4349  else {
4350  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc_sd", 1, 18, 18, 3); __PYX_ERR(0, 261, __pyx_L3_error)
4351  }
4352  CYTHON_FALLTHROUGH;
4353  case 4:
4354  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_aElementQuadWeights)) != 0)) kw_args--;
4355  else {
4356  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc_sd", 1, 18, 18, 4); __PYX_ERR(0, 261, __pyx_L3_error)
4357  }
4358  CYTHON_FALLTHROUGH;
4359  case 5:
4360  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_detJ)) != 0)) kw_args--;
4361  else {
4362  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc_sd", 1, 18, 18, 5); __PYX_ERR(0, 261, __pyx_L3_error)
4363  }
4364  CYTHON_FALLTHROUGH;
4365  case 6:
4366  if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_uQuadratureWeights_elementBounda)) != 0)) kw_args--;
4367  else {
4368  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc_sd", 1, 18, 18, 6); __PYX_ERR(0, 261, __pyx_L3_error)
4369  }
4370  CYTHON_FALLTHROUGH;
4371  case 7:
4372  if (likely((values[7] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
4373  else {
4374  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc_sd", 1, 18, 18, 7); __PYX_ERR(0, 261, __pyx_L3_error)
4375  }
4376  CYTHON_FALLTHROUGH;
4377  case 8:
4378  if (likely((values[8] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u)) != 0)) kw_args--;
4379  else {
4380  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc_sd", 1, 18, 18, 8); __PYX_ERR(0, 261, __pyx_L3_error)
4381  }
4382  CYTHON_FALLTHROUGH;
4383  case 9:
4384  if (likely((values[9] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_gradu)) != 0)) kw_args--;
4385  else {
4386  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc_sd", 1, 18, 18, 9); __PYX_ERR(0, 261, __pyx_L3_error)
4387  }
4388  CYTHON_FALLTHROUGH;
4389  case 10:
4390  if (likely((values[10] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x_elementBoundary)) != 0)) kw_args--;
4391  else {
4392  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc_sd", 1, 18, 18, 10); __PYX_ERR(0, 261, __pyx_L3_error)
4393  }
4394  CYTHON_FALLTHROUGH;
4395  case 11:
4396  if (likely((values[11] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_u_elementBoundary)) != 0)) kw_args--;
4397  else {
4398  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc_sd", 1, 18, 18, 11); __PYX_ERR(0, 261, __pyx_L3_error)
4399  }
4400  CYTHON_FALLTHROUGH;
4401  case 12:
4402  if (likely((values[12] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_n)) != 0)) kw_args--;
4403  else {
4404  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc_sd", 1, 18, 18, 12); __PYX_ERR(0, 261, __pyx_L3_error)
4405  }
4406  CYTHON_FALLTHROUGH;
4407  case 13:
4408  if (likely((values[13] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_a)) != 0)) kw_args--;
4409  else {
4410  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc_sd", 1, 18, 18, 13); __PYX_ERR(0, 261, __pyx_L3_error)
4411  }
4412  CYTHON_FALLTHROUGH;
4413  case 14:
4414  if (likely((values[14] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_f)) != 0)) kw_args--;
4415  else {
4416  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc_sd", 1, 18, 18, 14); __PYX_ERR(0, 261, __pyx_L3_error)
4417  }
4418  CYTHON_FALLTHROUGH;
4419  case 15:
4420  if (likely((values[15] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_r)) != 0)) kw_args--;
4421  else {
4422  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc_sd", 1, 18, 18, 15); __PYX_ERR(0, 261, __pyx_L3_error)
4423  }
4424  CYTHON_FALLTHROUGH;
4425  case 16:
4426  if (likely((values[16] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rt0vdofs)) != 0)) kw_args--;
4427  else {
4428  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc_sd", 1, 18, 18, 16); __PYX_ERR(0, 261, __pyx_L3_error)
4429  }
4430  CYTHON_FALLTHROUGH;
4431  case 17:
4432  if (likely((values[17] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rt0potential)) != 0)) kw_args--;
4433  else {
4434  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc_sd", 1, 18, 18, 17); __PYX_ERR(0, 261, __pyx_L3_error)
4435  }
4436  }
4437  if (unlikely(kw_args > 0)) {
4438  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "postProcessRT0potentialFromP1nc_sd") < 0)) __PYX_ERR(0, 261, __pyx_L3_error)
4439  }
4440  } else if (PyTuple_GET_SIZE(__pyx_args) != 18) {
4441  goto __pyx_L5_argtuple_error;
4442  } else {
4443  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
4444  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
4445  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
4446  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
4447  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
4448  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
4449  values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
4450  values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
4451  values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
4452  values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
4453  values[10] = PyTuple_GET_ITEM(__pyx_args, 10);
4454  values[11] = PyTuple_GET_ITEM(__pyx_args, 11);
4455  values[12] = PyTuple_GET_ITEM(__pyx_args, 12);
4456  values[13] = PyTuple_GET_ITEM(__pyx_args, 13);
4457  values[14] = PyTuple_GET_ITEM(__pyx_args, 14);
4458  values[15] = PyTuple_GET_ITEM(__pyx_args, 15);
4459  values[16] = PyTuple_GET_ITEM(__pyx_args, 16);
4460  values[17] = PyTuple_GET_ITEM(__pyx_args, 17);
4461  }
4462  __pyx_v_rowptr = ((PyArrayObject *)values[0]);
4463  __pyx_v_colind = ((PyArrayObject *)values[1]);
4464  __pyx_v_uQuadratureWeights_element = ((PyArrayObject *)values[2]);
4465  __pyx_v_elementBarycenters = ((PyArrayObject *)values[3]);
4466  __pyx_v_aElementQuadWeights = ((PyArrayObject *)values[4]);
4467  __pyx_v_detJ = ((PyArrayObject *)values[5]);
4468  __pyx_v_uQuadratureWeights_elementBoundary = ((PyArrayObject *)values[6]);
4469  __pyx_v_x = ((PyArrayObject *)values[7]);
4470  __pyx_v_u = ((PyArrayObject *)values[8]);
4471  __pyx_v_gradu = ((PyArrayObject *)values[9]);
4472  __pyx_v_x_elementBoundary = ((PyArrayObject *)values[10]);
4473  __pyx_v_u_elementBoundary = ((PyArrayObject *)values[11]);
4474  __pyx_v_n = ((PyArrayObject *)values[12]);
4475  __pyx_v_a = ((PyArrayObject *)values[13]);
4476  __pyx_v_f = ((PyArrayObject *)values[14]);
4477  __pyx_v_r = ((PyArrayObject *)values[15]);
4478  __pyx_v_rt0vdofs = ((PyArrayObject *)values[16]);
4479  __pyx_v_rt0potential = ((PyArrayObject *)values[17]);
4480  }
4481  goto __pyx_L4_argument_unpacking_done;
4482  __pyx_L5_argtuple_error:;
4483  __Pyx_RaiseArgtupleInvalid("postProcessRT0potentialFromP1nc_sd", 1, 18, 18, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 261, __pyx_L3_error)
4484  __pyx_L3_error:;
4485  __Pyx_AddTraceback("cpostprocessing.postProcessRT0potentialFromP1nc_sd", __pyx_clineno, __pyx_lineno, __pyx_filename);
4486  __Pyx_RefNannyFinishContext();
4487  return NULL;
4488  __pyx_L4_argument_unpacking_done:;
4489  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rowptr), __pyx_ptype_5numpy_ndarray, 1, "rowptr", 0))) __PYX_ERR(0, 261, __pyx_L1_error)
4490  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_colind), __pyx_ptype_5numpy_ndarray, 1, "colind", 0))) __PYX_ERR(0, 262, __pyx_L1_error)
4491  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_uQuadratureWeights_element), __pyx_ptype_5numpy_ndarray, 1, "uQuadratureWeights_element", 0))) __PYX_ERR(0, 263, __pyx_L1_error)
4492  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBarycenters), __pyx_ptype_5numpy_ndarray, 1, "elementBarycenters", 0))) __PYX_ERR(0, 264, __pyx_L1_error)
4493  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_aElementQuadWeights), __pyx_ptype_5numpy_ndarray, 1, "aElementQuadWeights", 0))) __PYX_ERR(0, 265, __pyx_L1_error)
4494  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_detJ), __pyx_ptype_5numpy_ndarray, 1, "detJ", 0))) __PYX_ERR(0, 266, __pyx_L1_error)
4495  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_uQuadratureWeights_elementBoundary), __pyx_ptype_5numpy_ndarray, 1, "uQuadratureWeights_elementBoundary", 0))) __PYX_ERR(0, 267, __pyx_L1_error)
4496  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1, "x", 0))) __PYX_ERR(0, 268, __pyx_L1_error)
4497  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1, "u", 0))) __PYX_ERR(0, 269, __pyx_L1_error)
4498  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_gradu), __pyx_ptype_5numpy_ndarray, 1, "gradu", 0))) __PYX_ERR(0, 270, __pyx_L1_error)
4499  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_elementBoundary), __pyx_ptype_5numpy_ndarray, 1, "x_elementBoundary", 0))) __PYX_ERR(0, 271, __pyx_L1_error)
4500  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u_elementBoundary), __pyx_ptype_5numpy_ndarray, 1, "u_elementBoundary", 0))) __PYX_ERR(0, 272, __pyx_L1_error)
4501  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_n), __pyx_ptype_5numpy_ndarray, 1, "n", 0))) __PYX_ERR(0, 273, __pyx_L1_error)
4502  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) __PYX_ERR(0, 274, __pyx_L1_error)
4503  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_f), __pyx_ptype_5numpy_ndarray, 1, "f", 0))) __PYX_ERR(0, 275, __pyx_L1_error)
4504  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_r), __pyx_ptype_5numpy_ndarray, 1, "r", 0))) __PYX_ERR(0, 276, __pyx_L1_error)
4505  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rt0vdofs), __pyx_ptype_5numpy_ndarray, 1, "rt0vdofs", 0))) __PYX_ERR(0, 277, __pyx_L1_error)
4506  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rt0potential), __pyx_ptype_5numpy_ndarray, 1, "rt0potential", 0))) __PYX_ERR(0, 278, __pyx_L1_error)
4507  __pyx_r = __pyx_pf_15cpostprocessing_18postProcessRT0potentialFromP1nc_sd(__pyx_self, __pyx_v_rowptr, __pyx_v_colind, __pyx_v_uQuadratureWeights_element, __pyx_v_elementBarycenters, __pyx_v_aElementQuadWeights, __pyx_v_detJ, __pyx_v_uQuadratureWeights_elementBoundary, __pyx_v_x, __pyx_v_u, __pyx_v_gradu, __pyx_v_x_elementBoundary, __pyx_v_u_elementBoundary, __pyx_v_n, __pyx_v_a, __pyx_v_f, __pyx_v_r, __pyx_v_rt0vdofs, __pyx_v_rt0potential);
4508 
4509  /* function exit code */
4510  goto __pyx_L0;
4511  __pyx_L1_error:;
4512  __pyx_r = NULL;
4513  __pyx_L0:;
4514  __Pyx_RefNannyFinishContext();
4515  return __pyx_r;
4516 }
4517 
4518 static PyObject *__pyx_pf_15cpostprocessing_18postProcessRT0potentialFromP1nc_sd(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_rowptr, PyArrayObject *__pyx_v_colind, PyArrayObject *__pyx_v_uQuadratureWeights_element, PyArrayObject *__pyx_v_elementBarycenters, PyArrayObject *__pyx_v_aElementQuadWeights, PyArrayObject *__pyx_v_detJ, CYTHON_UNUSED PyArrayObject *__pyx_v_uQuadratureWeights_elementBoundary, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_u, PyArrayObject *__pyx_v_gradu, PyArrayObject *__pyx_v_x_elementBoundary, PyArrayObject *__pyx_v_u_elementBoundary, PyArrayObject *__pyx_v_n, PyArrayObject *__pyx_v_a, PyArrayObject *__pyx_v_f, PyArrayObject *__pyx_v_r, PyArrayObject *__pyx_v_rt0vdofs, PyArrayObject *__pyx_v_rt0potential) {
4519  PyObject *__pyx_r = NULL;
4520  __Pyx_RefNannyDeclarations
4521  __Pyx_RefNannySetupContext("postProcessRT0potentialFromP1nc_sd", 0);
4522 
4523  /* "cpostprocessing.pyx":279
4524  * np.ndarray rt0vdofs,
4525  * np.ndarray rt0potential):
4526  * pp.postProcessRT0potentialFromP1nc_sd(u.shape[0], # <<<<<<<<<<<<<<
4527  * u.shape[1],
4528  * n.shape[1],
4529  */
4530  postProcessRT0potentialFromP1nc_sd((__pyx_v_u->dimensions[0]), (__pyx_v_u->dimensions[1]), (__pyx_v_n->dimensions[1]), (__pyx_v_n->dimensions[2]), (__pyx_v_n->dimensions[3]), ((int *)__pyx_v_rowptr->data), ((int *)__pyx_v_colind->data), ((double *)__pyx_v_uQuadratureWeights_element->data), ((double *)__pyx_v_elementBarycenters->data), ((double *)__pyx_v_aElementQuadWeights->data), ((double *)__pyx_v_detJ->data), ((double *)__pyx_v_uQuadratureWeights_element->data), ((double *)__pyx_v_x->data), ((double *)__pyx_v_u->data), ((double *)__pyx_v_gradu->data), ((double *)__pyx_v_x_elementBoundary->data), ((double *)__pyx_v_u_elementBoundary->data), ((double *)__pyx_v_n->data), ((double *)__pyx_v_a->data), ((double *)__pyx_v_f->data), ((double *)__pyx_v_r->data), ((double *)__pyx_v_rt0vdofs->data), ((double *)__pyx_v_rt0potential->data));
4531 
4532  /* "cpostprocessing.pyx":261
4533  * <double*>(rt0potential.data))
4534  *
4535  * def postProcessRT0potentialFromP1nc_sd(np.ndarray rowptr, # <<<<<<<<<<<<<<
4536  * np.ndarray colind,
4537  * np.ndarray uQuadratureWeights_element,
4538  */
4539 
4540  /* function exit code */
4541  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
4542  __Pyx_XGIVEREF(__pyx_r);
4543  __Pyx_RefNannyFinishContext();
4544  return __pyx_r;
4545 }
4546 
4547 /* "cpostprocessing.pyx":303
4548  * <double*>(rt0potential.data))
4549  *
4550  * def buildLocalBDM1projectionMatrices(np.ndarray w_dS_f, # <<<<<<<<<<<<<<
4551  * np.ndarray ebq_n,
4552  * np.ndarray ebq_v,
4553  */
4554 
4555 /* Python wrapper */
4556 static PyObject *__pyx_pw_15cpostprocessing_21buildLocalBDM1projectionMatrices(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
4557 static PyMethodDef __pyx_mdef_15cpostprocessing_21buildLocalBDM1projectionMatrices = {"buildLocalBDM1projectionMatrices", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_21buildLocalBDM1projectionMatrices, METH_VARARGS|METH_KEYWORDS, 0};
4558 static PyObject *__pyx_pw_15cpostprocessing_21buildLocalBDM1projectionMatrices(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
4559  PyArrayObject *__pyx_v_w_dS_f = 0;
4560  PyArrayObject *__pyx_v_ebq_n = 0;
4561  PyArrayObject *__pyx_v_ebq_v = 0;
4562  PyArrayObject *__pyx_v_BDMmat_element = 0;
4563  int __pyx_lineno = 0;
4564  const char *__pyx_filename = NULL;
4565  int __pyx_clineno = 0;
4566  PyObject *__pyx_r = 0;
4567  __Pyx_RefNannyDeclarations
4568  __Pyx_RefNannySetupContext("buildLocalBDM1projectionMatrices (wrapper)", 0);
4569  {
4570  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_w_dS_f,&__pyx_n_s_ebq_n,&__pyx_n_s_ebq_v,&__pyx_n_s_BDMmat_element,0};
4571  PyObject* values[4] = {0,0,0,0};
4572  if (unlikely(__pyx_kwds)) {
4573  Py_ssize_t kw_args;
4574  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
4575  switch (pos_args) {
4576  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
4577  CYTHON_FALLTHROUGH;
4578  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
4579  CYTHON_FALLTHROUGH;
4580  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
4581  CYTHON_FALLTHROUGH;
4582  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
4583  CYTHON_FALLTHROUGH;
4584  case 0: break;
4585  default: goto __pyx_L5_argtuple_error;
4586  }
4587  kw_args = PyDict_Size(__pyx_kwds);
4588  switch (pos_args) {
4589  case 0:
4590  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_w_dS_f)) != 0)) kw_args--;
4591  else goto __pyx_L5_argtuple_error;
4592  CYTHON_FALLTHROUGH;
4593  case 1:
4594  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ebq_n)) != 0)) kw_args--;
4595  else {
4596  __Pyx_RaiseArgtupleInvalid("buildLocalBDM1projectionMatrices", 1, 4, 4, 1); __PYX_ERR(0, 303, __pyx_L3_error)
4597  }
4598  CYTHON_FALLTHROUGH;
4599  case 2:
4600  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ebq_v)) != 0)) kw_args--;
4601  else {
4602  __Pyx_RaiseArgtupleInvalid("buildLocalBDM1projectionMatrices", 1, 4, 4, 2); __PYX_ERR(0, 303, __pyx_L3_error)
4603  }
4604  CYTHON_FALLTHROUGH;
4605  case 3:
4606  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_BDMmat_element)) != 0)) kw_args--;
4607  else {
4608  __Pyx_RaiseArgtupleInvalid("buildLocalBDM1projectionMatrices", 1, 4, 4, 3); __PYX_ERR(0, 303, __pyx_L3_error)
4609  }
4610  }
4611  if (unlikely(kw_args > 0)) {
4612  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "buildLocalBDM1projectionMatrices") < 0)) __PYX_ERR(0, 303, __pyx_L3_error)
4613  }
4614  } else if (PyTuple_GET_SIZE(__pyx_args) != 4) {
4615  goto __pyx_L5_argtuple_error;
4616  } else {
4617  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
4618  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
4619  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
4620  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
4621  }
4622  __pyx_v_w_dS_f = ((PyArrayObject *)values[0]);
4623  __pyx_v_ebq_n = ((PyArrayObject *)values[1]);
4624  __pyx_v_ebq_v = ((PyArrayObject *)values[2]);
4625  __pyx_v_BDMmat_element = ((PyArrayObject *)values[3]);
4626  }
4627  goto __pyx_L4_argument_unpacking_done;
4628  __pyx_L5_argtuple_error:;
4629  __Pyx_RaiseArgtupleInvalid("buildLocalBDM1projectionMatrices", 1, 4, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 303, __pyx_L3_error)
4630  __pyx_L3_error:;
4631  __Pyx_AddTraceback("cpostprocessing.buildLocalBDM1projectionMatrices", __pyx_clineno, __pyx_lineno, __pyx_filename);
4632  __Pyx_RefNannyFinishContext();
4633  return NULL;
4634  __pyx_L4_argument_unpacking_done:;
4635  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_w_dS_f), __pyx_ptype_5numpy_ndarray, 1, "w_dS_f", 0))) __PYX_ERR(0, 303, __pyx_L1_error)
4636  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ebq_n), __pyx_ptype_5numpy_ndarray, 1, "ebq_n", 0))) __PYX_ERR(0, 304, __pyx_L1_error)
4637  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ebq_v), __pyx_ptype_5numpy_ndarray, 1, "ebq_v", 0))) __PYX_ERR(0, 305, __pyx_L1_error)
4638  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_BDMmat_element), __pyx_ptype_5numpy_ndarray, 1, "BDMmat_element", 0))) __PYX_ERR(0, 306, __pyx_L1_error)
4639  __pyx_r = __pyx_pf_15cpostprocessing_20buildLocalBDM1projectionMatrices(__pyx_self, __pyx_v_w_dS_f, __pyx_v_ebq_n, __pyx_v_ebq_v, __pyx_v_BDMmat_element);
4640 
4641  /* function exit code */
4642  goto __pyx_L0;
4643  __pyx_L1_error:;
4644  __pyx_r = NULL;
4645  __pyx_L0:;
4646  __Pyx_RefNannyFinishContext();
4647  return __pyx_r;
4648 }
4649 
4650 static PyObject *__pyx_pf_15cpostprocessing_20buildLocalBDM1projectionMatrices(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_w_dS_f, PyArrayObject *__pyx_v_ebq_n, PyArrayObject *__pyx_v_ebq_v, PyArrayObject *__pyx_v_BDMmat_element) {
4651  PyObject *__pyx_r = NULL;
4652  __Pyx_RefNannyDeclarations
4653  __Pyx_RefNannySetupContext("buildLocalBDM1projectionMatrices", 0);
4654 
4655  /* "cpostprocessing.pyx":307
4656  * np.ndarray ebq_v,
4657  * np.ndarray BDMmat_element):
4658  * pp.buildLocalBDM1projectionMatrices(ebq_n.shape[0], # <<<<<<<<<<<<<<
4659  * ebq_n.shape[1],
4660  * ebq_n.shape[2],
4661  */
4662  buildLocalBDM1projectionMatrices((__pyx_v_ebq_n->dimensions[0]), (__pyx_v_ebq_n->dimensions[1]), (__pyx_v_ebq_n->dimensions[2]), (__pyx_v_ebq_n->dimensions[3]), (__pyx_v_w_dS_f->dimensions[3]), (__pyx_v_ebq_v->dimensions[3]), (__pyx_v_BDMmat_element->dimensions[1]), ((double *)__pyx_v_w_dS_f->data), ((double *)__pyx_v_ebq_n->data), ((double *)__pyx_v_ebq_v->data), ((double *)__pyx_v_BDMmat_element->data));
4663 
4664  /* "cpostprocessing.pyx":303
4665  * <double*>(rt0potential.data))
4666  *
4667  * def buildLocalBDM1projectionMatrices(np.ndarray w_dS_f, # <<<<<<<<<<<<<<
4668  * np.ndarray ebq_n,
4669  * np.ndarray ebq_v,
4670  */
4671 
4672  /* function exit code */
4673  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
4674  __Pyx_XGIVEREF(__pyx_r);
4675  __Pyx_RefNannyFinishContext();
4676  return __pyx_r;
4677 }
4678 
4679 /* "cpostprocessing.pyx":319
4680  * <double*>(BDMmat_element.data))
4681  *
4682  * def buildLocalBDM2projectionMatrices(int degree, # <<<<<<<<<<<<<<
4683  * np.ndarray w_dS_f,
4684  * np.ndarray ebq_n,
4685  */
4686 
4687 /* Python wrapper */
4688 static PyObject *__pyx_pw_15cpostprocessing_23buildLocalBDM2projectionMatrices(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
4689 static PyMethodDef __pyx_mdef_15cpostprocessing_23buildLocalBDM2projectionMatrices = {"buildLocalBDM2projectionMatrices", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_23buildLocalBDM2projectionMatrices, METH_VARARGS|METH_KEYWORDS, 0};
4690 static PyObject *__pyx_pw_15cpostprocessing_23buildLocalBDM2projectionMatrices(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
4691  int __pyx_v_degree;
4692  PyArrayObject *__pyx_v_w_dS_f = 0;
4693  PyArrayObject *__pyx_v_ebq_n = 0;
4694  PyArrayObject *__pyx_v_ebq_v = 0;
4695  PyArrayObject *__pyx_v_q_basis_vals = 0;
4696  PyArrayObject *__pyx_v_w_int_test_grads = 0;
4697  PyArrayObject *__pyx_v_w_int_div_free = 0;
4698  PyArrayObject *__pyx_v_piola_trial_fun = 0;
4699  PyArrayObject *__pyx_v_edgeFlags = 0;
4700  PyArrayObject *__pyx_v_BDMmat_element = 0;
4701  int __pyx_lineno = 0;
4702  const char *__pyx_filename = NULL;
4703  int __pyx_clineno = 0;
4704  PyObject *__pyx_r = 0;
4705  __Pyx_RefNannyDeclarations
4706  __Pyx_RefNannySetupContext("buildLocalBDM2projectionMatrices (wrapper)", 0);
4707  {
4708  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_degree,&__pyx_n_s_w_dS_f,&__pyx_n_s_ebq_n,&__pyx_n_s_ebq_v,&__pyx_n_s_q_basis_vals,&__pyx_n_s_w_int_test_grads,&__pyx_n_s_w_int_div_free,&__pyx_n_s_piola_trial_fun,&__pyx_n_s_edgeFlags,&__pyx_n_s_BDMmat_element,0};
4709  PyObject* values[10] = {0,0,0,0,0,0,0,0,0,0};
4710  if (unlikely(__pyx_kwds)) {
4711  Py_ssize_t kw_args;
4712  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
4713  switch (pos_args) {
4714  case 10: values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
4715  CYTHON_FALLTHROUGH;
4716  case 9: values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
4717  CYTHON_FALLTHROUGH;
4718  case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
4719  CYTHON_FALLTHROUGH;
4720  case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
4721  CYTHON_FALLTHROUGH;
4722  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
4723  CYTHON_FALLTHROUGH;
4724  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
4725  CYTHON_FALLTHROUGH;
4726  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
4727  CYTHON_FALLTHROUGH;
4728  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
4729  CYTHON_FALLTHROUGH;
4730  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
4731  CYTHON_FALLTHROUGH;
4732  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
4733  CYTHON_FALLTHROUGH;
4734  case 0: break;
4735  default: goto __pyx_L5_argtuple_error;
4736  }
4737  kw_args = PyDict_Size(__pyx_kwds);
4738  switch (pos_args) {
4739  case 0:
4740  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_degree)) != 0)) kw_args--;
4741  else goto __pyx_L5_argtuple_error;
4742  CYTHON_FALLTHROUGH;
4743  case 1:
4744  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_w_dS_f)) != 0)) kw_args--;
4745  else {
4746  __Pyx_RaiseArgtupleInvalid("buildLocalBDM2projectionMatrices", 1, 10, 10, 1); __PYX_ERR(0, 319, __pyx_L3_error)
4747  }
4748  CYTHON_FALLTHROUGH;
4749  case 2:
4750  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ebq_n)) != 0)) kw_args--;
4751  else {
4752  __Pyx_RaiseArgtupleInvalid("buildLocalBDM2projectionMatrices", 1, 10, 10, 2); __PYX_ERR(0, 319, __pyx_L3_error)
4753  }
4754  CYTHON_FALLTHROUGH;
4755  case 3:
4756  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ebq_v)) != 0)) kw_args--;
4757  else {
4758  __Pyx_RaiseArgtupleInvalid("buildLocalBDM2projectionMatrices", 1, 10, 10, 3); __PYX_ERR(0, 319, __pyx_L3_error)
4759  }
4760  CYTHON_FALLTHROUGH;
4761  case 4:
4762  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_q_basis_vals)) != 0)) kw_args--;
4763  else {
4764  __Pyx_RaiseArgtupleInvalid("buildLocalBDM2projectionMatrices", 1, 10, 10, 4); __PYX_ERR(0, 319, __pyx_L3_error)
4765  }
4766  CYTHON_FALLTHROUGH;
4767  case 5:
4768  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_w_int_test_grads)) != 0)) kw_args--;
4769  else {
4770  __Pyx_RaiseArgtupleInvalid("buildLocalBDM2projectionMatrices", 1, 10, 10, 5); __PYX_ERR(0, 319, __pyx_L3_error)
4771  }
4772  CYTHON_FALLTHROUGH;
4773  case 6:
4774  if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_w_int_div_free)) != 0)) kw_args--;
4775  else {
4776  __Pyx_RaiseArgtupleInvalid("buildLocalBDM2projectionMatrices", 1, 10, 10, 6); __PYX_ERR(0, 319, __pyx_L3_error)
4777  }
4778  CYTHON_FALLTHROUGH;
4779  case 7:
4780  if (likely((values[7] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_piola_trial_fun)) != 0)) kw_args--;
4781  else {
4782  __Pyx_RaiseArgtupleInvalid("buildLocalBDM2projectionMatrices", 1, 10, 10, 7); __PYX_ERR(0, 319, __pyx_L3_error)
4783  }
4784  CYTHON_FALLTHROUGH;
4785  case 8:
4786  if (likely((values[8] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_edgeFlags)) != 0)) kw_args--;
4787  else {
4788  __Pyx_RaiseArgtupleInvalid("buildLocalBDM2projectionMatrices", 1, 10, 10, 8); __PYX_ERR(0, 319, __pyx_L3_error)
4789  }
4790  CYTHON_FALLTHROUGH;
4791  case 9:
4792  if (likely((values[9] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_BDMmat_element)) != 0)) kw_args--;
4793  else {
4794  __Pyx_RaiseArgtupleInvalid("buildLocalBDM2projectionMatrices", 1, 10, 10, 9); __PYX_ERR(0, 319, __pyx_L3_error)
4795  }
4796  }
4797  if (unlikely(kw_args > 0)) {
4798  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "buildLocalBDM2projectionMatrices") < 0)) __PYX_ERR(0, 319, __pyx_L3_error)
4799  }
4800  } else if (PyTuple_GET_SIZE(__pyx_args) != 10) {
4801  goto __pyx_L5_argtuple_error;
4802  } else {
4803  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
4804  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
4805  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
4806  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
4807  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
4808  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
4809  values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
4810  values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
4811  values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
4812  values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
4813  }
4814  __pyx_v_degree = __Pyx_PyInt_As_int(values[0]); if (unlikely((__pyx_v_degree == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 319, __pyx_L3_error)
4815  __pyx_v_w_dS_f = ((PyArrayObject *)values[1]);
4816  __pyx_v_ebq_n = ((PyArrayObject *)values[2]);
4817  __pyx_v_ebq_v = ((PyArrayObject *)values[3]);
4818  __pyx_v_q_basis_vals = ((PyArrayObject *)values[4]);
4819  __pyx_v_w_int_test_grads = ((PyArrayObject *)values[5]);
4820  __pyx_v_w_int_div_free = ((PyArrayObject *)values[6]);
4821  __pyx_v_piola_trial_fun = ((PyArrayObject *)values[7]);
4822  __pyx_v_edgeFlags = ((PyArrayObject *)values[8]);
4823  __pyx_v_BDMmat_element = ((PyArrayObject *)values[9]);
4824  }
4825  goto __pyx_L4_argument_unpacking_done;
4826  __pyx_L5_argtuple_error:;
4827  __Pyx_RaiseArgtupleInvalid("buildLocalBDM2projectionMatrices", 1, 10, 10, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 319, __pyx_L3_error)
4828  __pyx_L3_error:;
4829  __Pyx_AddTraceback("cpostprocessing.buildLocalBDM2projectionMatrices", __pyx_clineno, __pyx_lineno, __pyx_filename);
4830  __Pyx_RefNannyFinishContext();
4831  return NULL;
4832  __pyx_L4_argument_unpacking_done:;
4833  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_w_dS_f), __pyx_ptype_5numpy_ndarray, 1, "w_dS_f", 0))) __PYX_ERR(0, 320, __pyx_L1_error)
4834  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ebq_n), __pyx_ptype_5numpy_ndarray, 1, "ebq_n", 0))) __PYX_ERR(0, 321, __pyx_L1_error)
4835  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ebq_v), __pyx_ptype_5numpy_ndarray, 1, "ebq_v", 0))) __PYX_ERR(0, 322, __pyx_L1_error)
4836  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_q_basis_vals), __pyx_ptype_5numpy_ndarray, 1, "q_basis_vals", 0))) __PYX_ERR(0, 323, __pyx_L1_error)
4837  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_w_int_test_grads), __pyx_ptype_5numpy_ndarray, 1, "w_int_test_grads", 0))) __PYX_ERR(0, 324, __pyx_L1_error)
4838  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_w_int_div_free), __pyx_ptype_5numpy_ndarray, 1, "w_int_div_free", 0))) __PYX_ERR(0, 325, __pyx_L1_error)
4839  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_piola_trial_fun), __pyx_ptype_5numpy_ndarray, 1, "piola_trial_fun", 0))) __PYX_ERR(0, 326, __pyx_L1_error)
4840  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_edgeFlags), __pyx_ptype_5numpy_ndarray, 1, "edgeFlags", 0))) __PYX_ERR(0, 327, __pyx_L1_error)
4841  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_BDMmat_element), __pyx_ptype_5numpy_ndarray, 1, "BDMmat_element", 0))) __PYX_ERR(0, 328, __pyx_L1_error)
4842  __pyx_r = __pyx_pf_15cpostprocessing_22buildLocalBDM2projectionMatrices(__pyx_self, __pyx_v_degree, __pyx_v_w_dS_f, __pyx_v_ebq_n, __pyx_v_ebq_v, __pyx_v_q_basis_vals, __pyx_v_w_int_test_grads, __pyx_v_w_int_div_free, __pyx_v_piola_trial_fun, __pyx_v_edgeFlags, __pyx_v_BDMmat_element);
4843 
4844  /* function exit code */
4845  goto __pyx_L0;
4846  __pyx_L1_error:;
4847  __pyx_r = NULL;
4848  __pyx_L0:;
4849  __Pyx_RefNannyFinishContext();
4850  return __pyx_r;
4851 }
4852 
4853 static PyObject *__pyx_pf_15cpostprocessing_22buildLocalBDM2projectionMatrices(CYTHON_UNUSED PyObject *__pyx_self, int __pyx_v_degree, PyArrayObject *__pyx_v_w_dS_f, PyArrayObject *__pyx_v_ebq_n, PyArrayObject *__pyx_v_ebq_v, PyArrayObject *__pyx_v_q_basis_vals, PyArrayObject *__pyx_v_w_int_test_grads, PyArrayObject *__pyx_v_w_int_div_free, PyArrayObject *__pyx_v_piola_trial_fun, PyArrayObject *__pyx_v_edgeFlags, PyArrayObject *__pyx_v_BDMmat_element) {
4854  PyObject *__pyx_r = NULL;
4855  __Pyx_RefNannyDeclarations
4856  __Pyx_RefNannySetupContext("buildLocalBDM2projectionMatrices", 0);
4857 
4858  /* "cpostprocessing.pyx":329
4859  * np.ndarray edgeFlags,
4860  * np.ndarray BDMmat_element):
4861  * pp.buildLocalBDM2projectionMatrices(degree, # <<<<<<<<<<<<<<
4862  * ebq_n.shape[0],
4863  * ebq_n.shape[1],
4864  */
4865  buildLocalBDM2projectionMatrices(__pyx_v_degree, (__pyx_v_ebq_n->dimensions[0]), (__pyx_v_ebq_n->dimensions[1]), (__pyx_v_ebq_n->dimensions[2]), (__pyx_v_q_basis_vals->dimensions[1]), (__pyx_v_ebq_n->dimensions[3]), (__pyx_v_w_dS_f->dimensions[3]), (__pyx_v_ebq_v->dimensions[3]), (__pyx_v_w_int_test_grads->dimensions[2]), (__pyx_v_BDMmat_element->dimensions[1]), ((int *)__pyx_v_edgeFlags->data), ((double *)__pyx_v_w_dS_f->data), ((double *)__pyx_v_ebq_n->data), ((double *)__pyx_v_ebq_v->data), ((double *)__pyx_v_BDMmat_element->data), ((double *)__pyx_v_q_basis_vals->data), ((double *)__pyx_v_w_int_test_grads->data), ((double *)__pyx_v_w_int_div_free->data), ((double *)__pyx_v_piola_trial_fun->data));
4866 
4867  /* "cpostprocessing.pyx":319
4868  * <double*>(BDMmat_element.data))
4869  *
4870  * def buildLocalBDM2projectionMatrices(int degree, # <<<<<<<<<<<<<<
4871  * np.ndarray w_dS_f,
4872  * np.ndarray ebq_n,
4873  */
4874 
4875  /* function exit code */
4876  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
4877  __Pyx_XGIVEREF(__pyx_r);
4878  __Pyx_RefNannyFinishContext();
4879  return __pyx_r;
4880 }
4881 
4882 /* "cpostprocessing.pyx":349
4883  * <double*>(piola_trial_fun.data))
4884  *
4885  * def factorLocalBDM1projectionMatrices(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
4886  * np.ndarray BDMmatPivots_element):
4887  * pp.factorLocalBDM1projectionMatrices(BDMmat_element.shape[0],
4888  */
4889 
4890 /* Python wrapper */
4891 static PyObject *__pyx_pw_15cpostprocessing_25factorLocalBDM1projectionMatrices(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
4892 static PyMethodDef __pyx_mdef_15cpostprocessing_25factorLocalBDM1projectionMatrices = {"factorLocalBDM1projectionMatrices", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_25factorLocalBDM1projectionMatrices, METH_VARARGS|METH_KEYWORDS, 0};
4893 static PyObject *__pyx_pw_15cpostprocessing_25factorLocalBDM1projectionMatrices(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
4894  PyArrayObject *__pyx_v_BDMmat_element = 0;
4895  PyArrayObject *__pyx_v_BDMmatPivots_element = 0;
4896  int __pyx_lineno = 0;
4897  const char *__pyx_filename = NULL;
4898  int __pyx_clineno = 0;
4899  PyObject *__pyx_r = 0;
4900  __Pyx_RefNannyDeclarations
4901  __Pyx_RefNannySetupContext("factorLocalBDM1projectionMatrices (wrapper)", 0);
4902  {
4903  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_BDMmat_element,&__pyx_n_s_BDMmatPivots_element,0};
4904  PyObject* values[2] = {0,0};
4905  if (unlikely(__pyx_kwds)) {
4906  Py_ssize_t kw_args;
4907  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
4908  switch (pos_args) {
4909  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
4910  CYTHON_FALLTHROUGH;
4911  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
4912  CYTHON_FALLTHROUGH;
4913  case 0: break;
4914  default: goto __pyx_L5_argtuple_error;
4915  }
4916  kw_args = PyDict_Size(__pyx_kwds);
4917  switch (pos_args) {
4918  case 0:
4919  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_BDMmat_element)) != 0)) kw_args--;
4920  else goto __pyx_L5_argtuple_error;
4921  CYTHON_FALLTHROUGH;
4922  case 1:
4923  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_BDMmatPivots_element)) != 0)) kw_args--;
4924  else {
4925  __Pyx_RaiseArgtupleInvalid("factorLocalBDM1projectionMatrices", 1, 2, 2, 1); __PYX_ERR(0, 349, __pyx_L3_error)
4926  }
4927  }
4928  if (unlikely(kw_args > 0)) {
4929  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "factorLocalBDM1projectionMatrices") < 0)) __PYX_ERR(0, 349, __pyx_L3_error)
4930  }
4931  } else if (PyTuple_GET_SIZE(__pyx_args) != 2) {
4932  goto __pyx_L5_argtuple_error;
4933  } else {
4934  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
4935  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
4936  }
4937  __pyx_v_BDMmat_element = ((PyArrayObject *)values[0]);
4938  __pyx_v_BDMmatPivots_element = ((PyArrayObject *)values[1]);
4939  }
4940  goto __pyx_L4_argument_unpacking_done;
4941  __pyx_L5_argtuple_error:;
4942  __Pyx_RaiseArgtupleInvalid("factorLocalBDM1projectionMatrices", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 349, __pyx_L3_error)
4943  __pyx_L3_error:;
4944  __Pyx_AddTraceback("cpostprocessing.factorLocalBDM1projectionMatrices", __pyx_clineno, __pyx_lineno, __pyx_filename);
4945  __Pyx_RefNannyFinishContext();
4946  return NULL;
4947  __pyx_L4_argument_unpacking_done:;
4948  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_BDMmat_element), __pyx_ptype_5numpy_ndarray, 1, "BDMmat_element", 0))) __PYX_ERR(0, 349, __pyx_L1_error)
4949  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_BDMmatPivots_element), __pyx_ptype_5numpy_ndarray, 1, "BDMmatPivots_element", 0))) __PYX_ERR(0, 350, __pyx_L1_error)
4950  __pyx_r = __pyx_pf_15cpostprocessing_24factorLocalBDM1projectionMatrices(__pyx_self, __pyx_v_BDMmat_element, __pyx_v_BDMmatPivots_element);
4951 
4952  /* function exit code */
4953  goto __pyx_L0;
4954  __pyx_L1_error:;
4955  __pyx_r = NULL;
4956  __pyx_L0:;
4957  __Pyx_RefNannyFinishContext();
4958  return __pyx_r;
4959 }
4960 
4961 static PyObject *__pyx_pf_15cpostprocessing_24factorLocalBDM1projectionMatrices(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_BDMmat_element, PyArrayObject *__pyx_v_BDMmatPivots_element) {
4962  PyObject *__pyx_r = NULL;
4963  __Pyx_RefNannyDeclarations
4964  __Pyx_RefNannySetupContext("factorLocalBDM1projectionMatrices", 0);
4965 
4966  /* "cpostprocessing.pyx":351
4967  * def factorLocalBDM1projectionMatrices(np.ndarray BDMmat_element,
4968  * np.ndarray BDMmatPivots_element):
4969  * pp.factorLocalBDM1projectionMatrices(BDMmat_element.shape[0], # <<<<<<<<<<<<<<
4970  * BDMmat_element.shape[1],
4971  * <double*>(BDMmat_element.data),
4972  */
4973  factorLocalBDM1projectionMatrices((__pyx_v_BDMmat_element->dimensions[0]), (__pyx_v_BDMmat_element->dimensions[1]), ((double *)__pyx_v_BDMmat_element->data), ((int *)__pyx_v_BDMmatPivots_element->data));
4974 
4975  /* "cpostprocessing.pyx":349
4976  * <double*>(piola_trial_fun.data))
4977  *
4978  * def factorLocalBDM1projectionMatrices(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
4979  * np.ndarray BDMmatPivots_element):
4980  * pp.factorLocalBDM1projectionMatrices(BDMmat_element.shape[0],
4981  */
4982 
4983  /* function exit code */
4984  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
4985  __Pyx_XGIVEREF(__pyx_r);
4986  __Pyx_RefNannyFinishContext();
4987  return __pyx_r;
4988 }
4989 
4990 /* "cpostprocessing.pyx":356
4991  * <int*>(BDMmatPivots_element.data))
4992  *
4993  * def factorLocalBDM2projectionMatrices(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
4994  * np.ndarray BDMmatPivots_element):
4995  * pp.factorLocalBDM2projectionMatrices(BDMmat_element.shape[0],
4996  */
4997 
4998 /* Python wrapper */
4999 static PyObject *__pyx_pw_15cpostprocessing_27factorLocalBDM2projectionMatrices(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
5000 static PyMethodDef __pyx_mdef_15cpostprocessing_27factorLocalBDM2projectionMatrices = {"factorLocalBDM2projectionMatrices", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_27factorLocalBDM2projectionMatrices, METH_VARARGS|METH_KEYWORDS, 0};
5001 static PyObject *__pyx_pw_15cpostprocessing_27factorLocalBDM2projectionMatrices(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
5002  PyArrayObject *__pyx_v_BDMmat_element = 0;
5003  PyArrayObject *__pyx_v_BDMmatPivots_element = 0;
5004  int __pyx_lineno = 0;
5005  const char *__pyx_filename = NULL;
5006  int __pyx_clineno = 0;
5007  PyObject *__pyx_r = 0;
5008  __Pyx_RefNannyDeclarations
5009  __Pyx_RefNannySetupContext("factorLocalBDM2projectionMatrices (wrapper)", 0);
5010  {
5011  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_BDMmat_element,&__pyx_n_s_BDMmatPivots_element,0};
5012  PyObject* values[2] = {0,0};
5013  if (unlikely(__pyx_kwds)) {
5014  Py_ssize_t kw_args;
5015  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
5016  switch (pos_args) {
5017  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5018  CYTHON_FALLTHROUGH;
5019  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5020  CYTHON_FALLTHROUGH;
5021  case 0: break;
5022  default: goto __pyx_L5_argtuple_error;
5023  }
5024  kw_args = PyDict_Size(__pyx_kwds);
5025  switch (pos_args) {
5026  case 0:
5027  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_BDMmat_element)) != 0)) kw_args--;
5028  else goto __pyx_L5_argtuple_error;
5029  CYTHON_FALLTHROUGH;
5030  case 1:
5031  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_BDMmatPivots_element)) != 0)) kw_args--;
5032  else {
5033  __Pyx_RaiseArgtupleInvalid("factorLocalBDM2projectionMatrices", 1, 2, 2, 1); __PYX_ERR(0, 356, __pyx_L3_error)
5034  }
5035  }
5036  if (unlikely(kw_args > 0)) {
5037  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "factorLocalBDM2projectionMatrices") < 0)) __PYX_ERR(0, 356, __pyx_L3_error)
5038  }
5039  } else if (PyTuple_GET_SIZE(__pyx_args) != 2) {
5040  goto __pyx_L5_argtuple_error;
5041  } else {
5042  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5043  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5044  }
5045  __pyx_v_BDMmat_element = ((PyArrayObject *)values[0]);
5046  __pyx_v_BDMmatPivots_element = ((PyArrayObject *)values[1]);
5047  }
5048  goto __pyx_L4_argument_unpacking_done;
5049  __pyx_L5_argtuple_error:;
5050  __Pyx_RaiseArgtupleInvalid("factorLocalBDM2projectionMatrices", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 356, __pyx_L3_error)
5051  __pyx_L3_error:;
5052  __Pyx_AddTraceback("cpostprocessing.factorLocalBDM2projectionMatrices", __pyx_clineno, __pyx_lineno, __pyx_filename);
5053  __Pyx_RefNannyFinishContext();
5054  return NULL;
5055  __pyx_L4_argument_unpacking_done:;
5056  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_BDMmat_element), __pyx_ptype_5numpy_ndarray, 1, "BDMmat_element", 0))) __PYX_ERR(0, 356, __pyx_L1_error)
5057  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_BDMmatPivots_element), __pyx_ptype_5numpy_ndarray, 1, "BDMmatPivots_element", 0))) __PYX_ERR(0, 357, __pyx_L1_error)
5058  __pyx_r = __pyx_pf_15cpostprocessing_26factorLocalBDM2projectionMatrices(__pyx_self, __pyx_v_BDMmat_element, __pyx_v_BDMmatPivots_element);
5059 
5060  /* function exit code */
5061  goto __pyx_L0;
5062  __pyx_L1_error:;
5063  __pyx_r = NULL;
5064  __pyx_L0:;
5065  __Pyx_RefNannyFinishContext();
5066  return __pyx_r;
5067 }
5068 
5069 static PyObject *__pyx_pf_15cpostprocessing_26factorLocalBDM2projectionMatrices(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_BDMmat_element, PyArrayObject *__pyx_v_BDMmatPivots_element) {
5070  PyObject *__pyx_r = NULL;
5071  __Pyx_RefNannyDeclarations
5072  __Pyx_RefNannySetupContext("factorLocalBDM2projectionMatrices", 0);
5073 
5074  /* "cpostprocessing.pyx":358
5075  * def factorLocalBDM2projectionMatrices(np.ndarray BDMmat_element,
5076  * np.ndarray BDMmatPivots_element):
5077  * pp.factorLocalBDM2projectionMatrices(BDMmat_element.shape[0], # <<<<<<<<<<<<<<
5078  * BDMmat_element.shape[1],
5079  * <double*>(BDMmat_element.data),
5080  */
5081  factorLocalBDM2projectionMatrices((__pyx_v_BDMmat_element->dimensions[0]), (__pyx_v_BDMmat_element->dimensions[1]), ((double *)__pyx_v_BDMmat_element->data), ((int *)__pyx_v_BDMmatPivots_element->data));
5082 
5083  /* "cpostprocessing.pyx":356
5084  * <int*>(BDMmatPivots_element.data))
5085  *
5086  * def factorLocalBDM2projectionMatrices(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
5087  * np.ndarray BDMmatPivots_element):
5088  * pp.factorLocalBDM2projectionMatrices(BDMmat_element.shape[0],
5089  */
5090 
5091  /* function exit code */
5092  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
5093  __Pyx_XGIVEREF(__pyx_r);
5094  __Pyx_RefNannyFinishContext();
5095  return __pyx_r;
5096 }
5097 
5098 /* "cpostprocessing.pyx":363
5099  * <int*>(BDMmatPivots_element.data))
5100  *
5101  * def solveLocalBDM1projection(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
5102  * np.ndarray BDMmatPivots_element,
5103  * np.ndarray w_dS_f,
5104  */
5105 
5106 /* Python wrapper */
5107 static PyObject *__pyx_pw_15cpostprocessing_29solveLocalBDM1projection(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
5108 static PyMethodDef __pyx_mdef_15cpostprocessing_29solveLocalBDM1projection = {"solveLocalBDM1projection", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_29solveLocalBDM1projection, METH_VARARGS|METH_KEYWORDS, 0};
5109 static PyObject *__pyx_pw_15cpostprocessing_29solveLocalBDM1projection(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
5110  PyArrayObject *__pyx_v_BDMmat_element = 0;
5111  PyArrayObject *__pyx_v_BDMmatPivots_element = 0;
5112  PyArrayObject *__pyx_v_w_dS_f = 0;
5113  PyArrayObject *__pyx_v_ebq_n = 0;
5114  PyArrayObject *__pyx_v_ebq_velocity = 0;
5115  PyArrayObject *__pyx_v_q_vdofs = 0;
5116  int __pyx_lineno = 0;
5117  const char *__pyx_filename = NULL;
5118  int __pyx_clineno = 0;
5119  PyObject *__pyx_r = 0;
5120  __Pyx_RefNannyDeclarations
5121  __Pyx_RefNannySetupContext("solveLocalBDM1projection (wrapper)", 0);
5122  {
5123  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_BDMmat_element,&__pyx_n_s_BDMmatPivots_element,&__pyx_n_s_w_dS_f,&__pyx_n_s_ebq_n,&__pyx_n_s_ebq_velocity,&__pyx_n_s_q_vdofs,0};
5124  PyObject* values[6] = {0,0,0,0,0,0};
5125  if (unlikely(__pyx_kwds)) {
5126  Py_ssize_t kw_args;
5127  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
5128  switch (pos_args) {
5129  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
5130  CYTHON_FALLTHROUGH;
5131  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
5132  CYTHON_FALLTHROUGH;
5133  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
5134  CYTHON_FALLTHROUGH;
5135  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
5136  CYTHON_FALLTHROUGH;
5137  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5138  CYTHON_FALLTHROUGH;
5139  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5140  CYTHON_FALLTHROUGH;
5141  case 0: break;
5142  default: goto __pyx_L5_argtuple_error;
5143  }
5144  kw_args = PyDict_Size(__pyx_kwds);
5145  switch (pos_args) {
5146  case 0:
5147  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_BDMmat_element)) != 0)) kw_args--;
5148  else goto __pyx_L5_argtuple_error;
5149  CYTHON_FALLTHROUGH;
5150  case 1:
5151  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_BDMmatPivots_element)) != 0)) kw_args--;
5152  else {
5153  __Pyx_RaiseArgtupleInvalid("solveLocalBDM1projection", 1, 6, 6, 1); __PYX_ERR(0, 363, __pyx_L3_error)
5154  }
5155  CYTHON_FALLTHROUGH;
5156  case 2:
5157  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_w_dS_f)) != 0)) kw_args--;
5158  else {
5159  __Pyx_RaiseArgtupleInvalid("solveLocalBDM1projection", 1, 6, 6, 2); __PYX_ERR(0, 363, __pyx_L3_error)
5160  }
5161  CYTHON_FALLTHROUGH;
5162  case 3:
5163  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ebq_n)) != 0)) kw_args--;
5164  else {
5165  __Pyx_RaiseArgtupleInvalid("solveLocalBDM1projection", 1, 6, 6, 3); __PYX_ERR(0, 363, __pyx_L3_error)
5166  }
5167  CYTHON_FALLTHROUGH;
5168  case 4:
5169  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ebq_velocity)) != 0)) kw_args--;
5170  else {
5171  __Pyx_RaiseArgtupleInvalid("solveLocalBDM1projection", 1, 6, 6, 4); __PYX_ERR(0, 363, __pyx_L3_error)
5172  }
5173  CYTHON_FALLTHROUGH;
5174  case 5:
5175  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_q_vdofs)) != 0)) kw_args--;
5176  else {
5177  __Pyx_RaiseArgtupleInvalid("solveLocalBDM1projection", 1, 6, 6, 5); __PYX_ERR(0, 363, __pyx_L3_error)
5178  }
5179  }
5180  if (unlikely(kw_args > 0)) {
5181  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "solveLocalBDM1projection") < 0)) __PYX_ERR(0, 363, __pyx_L3_error)
5182  }
5183  } else if (PyTuple_GET_SIZE(__pyx_args) != 6) {
5184  goto __pyx_L5_argtuple_error;
5185  } else {
5186  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5187  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5188  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
5189  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
5190  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
5191  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
5192  }
5193  __pyx_v_BDMmat_element = ((PyArrayObject *)values[0]);
5194  __pyx_v_BDMmatPivots_element = ((PyArrayObject *)values[1]);
5195  __pyx_v_w_dS_f = ((PyArrayObject *)values[2]);
5196  __pyx_v_ebq_n = ((PyArrayObject *)values[3]);
5197  __pyx_v_ebq_velocity = ((PyArrayObject *)values[4]);
5198  __pyx_v_q_vdofs = ((PyArrayObject *)values[5]);
5199  }
5200  goto __pyx_L4_argument_unpacking_done;
5201  __pyx_L5_argtuple_error:;
5202  __Pyx_RaiseArgtupleInvalid("solveLocalBDM1projection", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 363, __pyx_L3_error)
5203  __pyx_L3_error:;
5204  __Pyx_AddTraceback("cpostprocessing.solveLocalBDM1projection", __pyx_clineno, __pyx_lineno, __pyx_filename);
5205  __Pyx_RefNannyFinishContext();
5206  return NULL;
5207  __pyx_L4_argument_unpacking_done:;
5208  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_BDMmat_element), __pyx_ptype_5numpy_ndarray, 1, "BDMmat_element", 0))) __PYX_ERR(0, 363, __pyx_L1_error)
5209  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_BDMmatPivots_element), __pyx_ptype_5numpy_ndarray, 1, "BDMmatPivots_element", 0))) __PYX_ERR(0, 364, __pyx_L1_error)
5210  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_w_dS_f), __pyx_ptype_5numpy_ndarray, 1, "w_dS_f", 0))) __PYX_ERR(0, 365, __pyx_L1_error)
5211  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ebq_n), __pyx_ptype_5numpy_ndarray, 1, "ebq_n", 0))) __PYX_ERR(0, 366, __pyx_L1_error)
5212  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ebq_velocity), __pyx_ptype_5numpy_ndarray, 1, "ebq_velocity", 0))) __PYX_ERR(0, 367, __pyx_L1_error)
5213  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_q_vdofs), __pyx_ptype_5numpy_ndarray, 1, "q_vdofs", 0))) __PYX_ERR(0, 368, __pyx_L1_error)
5214  __pyx_r = __pyx_pf_15cpostprocessing_28solveLocalBDM1projection(__pyx_self, __pyx_v_BDMmat_element, __pyx_v_BDMmatPivots_element, __pyx_v_w_dS_f, __pyx_v_ebq_n, __pyx_v_ebq_velocity, __pyx_v_q_vdofs);
5215 
5216  /* function exit code */
5217  goto __pyx_L0;
5218  __pyx_L1_error:;
5219  __pyx_r = NULL;
5220  __pyx_L0:;
5221  __Pyx_RefNannyFinishContext();
5222  return __pyx_r;
5223 }
5224 
5225 static PyObject *__pyx_pf_15cpostprocessing_28solveLocalBDM1projection(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_BDMmat_element, PyArrayObject *__pyx_v_BDMmatPivots_element, PyArrayObject *__pyx_v_w_dS_f, PyArrayObject *__pyx_v_ebq_n, PyArrayObject *__pyx_v_ebq_velocity, PyArrayObject *__pyx_v_q_vdofs) {
5226  PyObject *__pyx_r = NULL;
5227  __Pyx_RefNannyDeclarations
5228  __Pyx_RefNannySetupContext("solveLocalBDM1projection", 0);
5229 
5230  /* "cpostprocessing.pyx":369
5231  * np.ndarray ebq_velocity,
5232  * np.ndarray q_vdofs):
5233  * pp.solveLocalBDM1projection(ebq_n.shape[0], # <<<<<<<<<<<<<<
5234  * ebq_n.shape[1],
5235  * ebq_n.shape[2],
5236  */
5237  solveLocalBDM1projection((__pyx_v_ebq_n->dimensions[0]), (__pyx_v_ebq_n->dimensions[1]), (__pyx_v_ebq_n->dimensions[2]), (__pyx_v_ebq_n->dimensions[3]), (__pyx_v_w_dS_f->dimensions[3]), (__pyx_v_BDMmat_element->dimensions[1]), ((double *)__pyx_v_BDMmat_element->data), ((int *)__pyx_v_BDMmatPivots_element->data), ((double *)__pyx_v_w_dS_f->data), ((double *)__pyx_v_ebq_n->data), ((double *)__pyx_v_ebq_velocity->data), ((double *)__pyx_v_q_vdofs->data));
5238 
5239  /* "cpostprocessing.pyx":363
5240  * <int*>(BDMmatPivots_element.data))
5241  *
5242  * def solveLocalBDM1projection(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
5243  * np.ndarray BDMmatPivots_element,
5244  * np.ndarray w_dS_f,
5245  */
5246 
5247  /* function exit code */
5248  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
5249  __Pyx_XGIVEREF(__pyx_r);
5250  __Pyx_RefNannyFinishContext();
5251  return __pyx_r;
5252 }
5253 
5254 /* "cpostprocessing.pyx":382
5255  * <double*>(q_vdofs.data))
5256  *
5257  * def solveLocalBDM2projection(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
5258  * np.ndarray BDMmatPivots_element,
5259  * np.ndarray w_dS_f,
5260  */
5261 
5262 /* Python wrapper */
5263 static PyObject *__pyx_pw_15cpostprocessing_31solveLocalBDM2projection(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
5264 static PyMethodDef __pyx_mdef_15cpostprocessing_31solveLocalBDM2projection = {"solveLocalBDM2projection", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_31solveLocalBDM2projection, METH_VARARGS|METH_KEYWORDS, 0};
5265 static PyObject *__pyx_pw_15cpostprocessing_31solveLocalBDM2projection(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
5266  PyArrayObject *__pyx_v_BDMmat_element = 0;
5267  PyArrayObject *__pyx_v_BDMmatPivots_element = 0;
5268  PyArrayObject *__pyx_v_w_dS_f = 0;
5269  PyArrayObject *__pyx_v_ebq_n = 0;
5270  PyArrayObject *__pyx_v_w_interior_gradients = 0;
5271  PyArrayObject *__pyx_v_ebq_velocity = 0;
5272  PyArrayObject *__pyx_v_q_velocity = 0;
5273  PyArrayObject *__pyx_v_q_vdofs = 0;
5274  int __pyx_lineno = 0;
5275  const char *__pyx_filename = NULL;
5276  int __pyx_clineno = 0;
5277  PyObject *__pyx_r = 0;
5278  __Pyx_RefNannyDeclarations
5279  __Pyx_RefNannySetupContext("solveLocalBDM2projection (wrapper)", 0);
5280  {
5281  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_BDMmat_element,&__pyx_n_s_BDMmatPivots_element,&__pyx_n_s_w_dS_f,&__pyx_n_s_ebq_n,&__pyx_n_s_w_interior_gradients,&__pyx_n_s_ebq_velocity,&__pyx_n_s_q_velocity,&__pyx_n_s_q_vdofs,0};
5282  PyObject* values[8] = {0,0,0,0,0,0,0,0};
5283  if (unlikely(__pyx_kwds)) {
5284  Py_ssize_t kw_args;
5285  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
5286  switch (pos_args) {
5287  case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
5288  CYTHON_FALLTHROUGH;
5289  case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
5290  CYTHON_FALLTHROUGH;
5291  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
5292  CYTHON_FALLTHROUGH;
5293  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
5294  CYTHON_FALLTHROUGH;
5295  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
5296  CYTHON_FALLTHROUGH;
5297  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
5298  CYTHON_FALLTHROUGH;
5299  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5300  CYTHON_FALLTHROUGH;
5301  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5302  CYTHON_FALLTHROUGH;
5303  case 0: break;
5304  default: goto __pyx_L5_argtuple_error;
5305  }
5306  kw_args = PyDict_Size(__pyx_kwds);
5307  switch (pos_args) {
5308  case 0:
5309  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_BDMmat_element)) != 0)) kw_args--;
5310  else goto __pyx_L5_argtuple_error;
5311  CYTHON_FALLTHROUGH;
5312  case 1:
5313  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_BDMmatPivots_element)) != 0)) kw_args--;
5314  else {
5315  __Pyx_RaiseArgtupleInvalid("solveLocalBDM2projection", 1, 8, 8, 1); __PYX_ERR(0, 382, __pyx_L3_error)
5316  }
5317  CYTHON_FALLTHROUGH;
5318  case 2:
5319  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_w_dS_f)) != 0)) kw_args--;
5320  else {
5321  __Pyx_RaiseArgtupleInvalid("solveLocalBDM2projection", 1, 8, 8, 2); __PYX_ERR(0, 382, __pyx_L3_error)
5322  }
5323  CYTHON_FALLTHROUGH;
5324  case 3:
5325  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ebq_n)) != 0)) kw_args--;
5326  else {
5327  __Pyx_RaiseArgtupleInvalid("solveLocalBDM2projection", 1, 8, 8, 3); __PYX_ERR(0, 382, __pyx_L3_error)
5328  }
5329  CYTHON_FALLTHROUGH;
5330  case 4:
5331  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_w_interior_gradients)) != 0)) kw_args--;
5332  else {
5333  __Pyx_RaiseArgtupleInvalid("solveLocalBDM2projection", 1, 8, 8, 4); __PYX_ERR(0, 382, __pyx_L3_error)
5334  }
5335  CYTHON_FALLTHROUGH;
5336  case 5:
5337  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ebq_velocity)) != 0)) kw_args--;
5338  else {
5339  __Pyx_RaiseArgtupleInvalid("solveLocalBDM2projection", 1, 8, 8, 5); __PYX_ERR(0, 382, __pyx_L3_error)
5340  }
5341  CYTHON_FALLTHROUGH;
5342  case 6:
5343  if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_q_velocity)) != 0)) kw_args--;
5344  else {
5345  __Pyx_RaiseArgtupleInvalid("solveLocalBDM2projection", 1, 8, 8, 6); __PYX_ERR(0, 382, __pyx_L3_error)
5346  }
5347  CYTHON_FALLTHROUGH;
5348  case 7:
5349  if (likely((values[7] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_q_vdofs)) != 0)) kw_args--;
5350  else {
5351  __Pyx_RaiseArgtupleInvalid("solveLocalBDM2projection", 1, 8, 8, 7); __PYX_ERR(0, 382, __pyx_L3_error)
5352  }
5353  }
5354  if (unlikely(kw_args > 0)) {
5355  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "solveLocalBDM2projection") < 0)) __PYX_ERR(0, 382, __pyx_L3_error)
5356  }
5357  } else if (PyTuple_GET_SIZE(__pyx_args) != 8) {
5358  goto __pyx_L5_argtuple_error;
5359  } else {
5360  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5361  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5362  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
5363  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
5364  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
5365  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
5366  values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
5367  values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
5368  }
5369  __pyx_v_BDMmat_element = ((PyArrayObject *)values[0]);
5370  __pyx_v_BDMmatPivots_element = ((PyArrayObject *)values[1]);
5371  __pyx_v_w_dS_f = ((PyArrayObject *)values[2]);
5372  __pyx_v_ebq_n = ((PyArrayObject *)values[3]);
5373  __pyx_v_w_interior_gradients = ((PyArrayObject *)values[4]);
5374  __pyx_v_ebq_velocity = ((PyArrayObject *)values[5]);
5375  __pyx_v_q_velocity = ((PyArrayObject *)values[6]);
5376  __pyx_v_q_vdofs = ((PyArrayObject *)values[7]);
5377  }
5378  goto __pyx_L4_argument_unpacking_done;
5379  __pyx_L5_argtuple_error:;
5380  __Pyx_RaiseArgtupleInvalid("solveLocalBDM2projection", 1, 8, 8, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 382, __pyx_L3_error)
5381  __pyx_L3_error:;
5382  __Pyx_AddTraceback("cpostprocessing.solveLocalBDM2projection", __pyx_clineno, __pyx_lineno, __pyx_filename);
5383  __Pyx_RefNannyFinishContext();
5384  return NULL;
5385  __pyx_L4_argument_unpacking_done:;
5386  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_BDMmat_element), __pyx_ptype_5numpy_ndarray, 1, "BDMmat_element", 0))) __PYX_ERR(0, 382, __pyx_L1_error)
5387  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_BDMmatPivots_element), __pyx_ptype_5numpy_ndarray, 1, "BDMmatPivots_element", 0))) __PYX_ERR(0, 383, __pyx_L1_error)
5388  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_w_dS_f), __pyx_ptype_5numpy_ndarray, 1, "w_dS_f", 0))) __PYX_ERR(0, 384, __pyx_L1_error)
5389  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ebq_n), __pyx_ptype_5numpy_ndarray, 1, "ebq_n", 0))) __PYX_ERR(0, 385, __pyx_L1_error)
5390  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_w_interior_gradients), __pyx_ptype_5numpy_ndarray, 1, "w_interior_gradients", 0))) __PYX_ERR(0, 386, __pyx_L1_error)
5391  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ebq_velocity), __pyx_ptype_5numpy_ndarray, 1, "ebq_velocity", 0))) __PYX_ERR(0, 387, __pyx_L1_error)
5392  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_q_velocity), __pyx_ptype_5numpy_ndarray, 1, "q_velocity", 0))) __PYX_ERR(0, 388, __pyx_L1_error)
5393  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_q_vdofs), __pyx_ptype_5numpy_ndarray, 1, "q_vdofs", 0))) __PYX_ERR(0, 389, __pyx_L1_error)
5394  __pyx_r = __pyx_pf_15cpostprocessing_30solveLocalBDM2projection(__pyx_self, __pyx_v_BDMmat_element, __pyx_v_BDMmatPivots_element, __pyx_v_w_dS_f, __pyx_v_ebq_n, __pyx_v_w_interior_gradients, __pyx_v_ebq_velocity, __pyx_v_q_velocity, __pyx_v_q_vdofs);
5395 
5396  /* function exit code */
5397  goto __pyx_L0;
5398  __pyx_L1_error:;
5399  __pyx_r = NULL;
5400  __pyx_L0:;
5401  __Pyx_RefNannyFinishContext();
5402  return __pyx_r;
5403 }
5404 
5405 static PyObject *__pyx_pf_15cpostprocessing_30solveLocalBDM2projection(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_BDMmat_element, PyArrayObject *__pyx_v_BDMmatPivots_element, PyArrayObject *__pyx_v_w_dS_f, PyArrayObject *__pyx_v_ebq_n, PyArrayObject *__pyx_v_w_interior_gradients, PyArrayObject *__pyx_v_ebq_velocity, PyArrayObject *__pyx_v_q_velocity, PyArrayObject *__pyx_v_q_vdofs) {
5406  PyObject *__pyx_r = NULL;
5407  __Pyx_RefNannyDeclarations
5408  __Pyx_RefNannySetupContext("solveLocalBDM2projection", 0);
5409 
5410  /* "cpostprocessing.pyx":390
5411  * np.ndarray q_velocity,
5412  * np.ndarray q_vdofs):
5413  * pp.solveLocalBDM2projection(ebq_n.shape[0], # <<<<<<<<<<<<<<
5414  * ebq_n.shape[1],
5415  * ebq_n.shape[2],
5416  */
5417  solveLocalBDM2projection((__pyx_v_ebq_n->dimensions[0]), (__pyx_v_ebq_n->dimensions[1]), (__pyx_v_ebq_n->dimensions[2]), (__pyx_v_ebq_n->dimensions[3]), (__pyx_v_w_dS_f->dimensions[3]), (__pyx_v_BDMmat_element->dimensions[1]), ((double *)__pyx_v_BDMmat_element->data), ((int *)__pyx_v_BDMmatPivots_element->data), ((double *)__pyx_v_w_dS_f->data), ((double *)__pyx_v_ebq_n->data), ((double *)__pyx_v_w_interior_gradients->data), ((double *)__pyx_v_q_velocity->data), ((double *)__pyx_v_ebq_velocity->data), ((double *)__pyx_v_q_vdofs->data));
5418 
5419  /* "cpostprocessing.pyx":382
5420  * <double*>(q_vdofs.data))
5421  *
5422  * def solveLocalBDM2projection(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
5423  * np.ndarray BDMmatPivots_element,
5424  * np.ndarray w_dS_f,
5425  */
5426 
5427  /* function exit code */
5428  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
5429  __Pyx_XGIVEREF(__pyx_r);
5430  __Pyx_RefNannyFinishContext();
5431  return __pyx_r;
5432 }
5433 
5434 /* "cpostprocessing.pyx":405
5435  * <double*>(q_vdofs.data))
5436  *
5437  * def buildBDM2rhs(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
5438  * np.ndarray BDMmatPivots_element,
5439  * np.ndarray w_dS_f,
5440  */
5441 
5442 /* Python wrapper */
5443 static PyObject *__pyx_pw_15cpostprocessing_33buildBDM2rhs(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
5444 static PyMethodDef __pyx_mdef_15cpostprocessing_33buildBDM2rhs = {"buildBDM2rhs", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_33buildBDM2rhs, METH_VARARGS|METH_KEYWORDS, 0};
5445 static PyObject *__pyx_pw_15cpostprocessing_33buildBDM2rhs(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
5446  PyArrayObject *__pyx_v_BDMmat_element = 0;
5447  PyArrayObject *__pyx_v_BDMmatPivots_element = 0;
5448  PyArrayObject *__pyx_v_w_dS_f = 0;
5449  PyArrayObject *__pyx_v_ebq_n = 0;
5450  PyArrayObject *__pyx_v_w_interior_gradients = 0;
5451  PyArrayObject *__pyx_v_w_interior_divfree = 0;
5452  PyArrayObject *__pyx_v_ebq_velocity = 0;
5453  PyArrayObject *__pyx_v_q_velocity = 0;
5454  PyArrayObject *__pyx_v_q_vdofs = 0;
5455  PyArrayObject *__pyx_v_edgeFlags = 0;
5456  int __pyx_lineno = 0;
5457  const char *__pyx_filename = NULL;
5458  int __pyx_clineno = 0;
5459  PyObject *__pyx_r = 0;
5460  __Pyx_RefNannyDeclarations
5461  __Pyx_RefNannySetupContext("buildBDM2rhs (wrapper)", 0);
5462  {
5463  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_BDMmat_element,&__pyx_n_s_BDMmatPivots_element,&__pyx_n_s_w_dS_f,&__pyx_n_s_ebq_n,&__pyx_n_s_w_interior_gradients,&__pyx_n_s_w_interior_divfree,&__pyx_n_s_ebq_velocity,&__pyx_n_s_q_velocity,&__pyx_n_s_q_vdofs,&__pyx_n_s_edgeFlags,0};
5464  PyObject* values[10] = {0,0,0,0,0,0,0,0,0,0};
5465  if (unlikely(__pyx_kwds)) {
5466  Py_ssize_t kw_args;
5467  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
5468  switch (pos_args) {
5469  case 10: values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
5470  CYTHON_FALLTHROUGH;
5471  case 9: values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
5472  CYTHON_FALLTHROUGH;
5473  case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
5474  CYTHON_FALLTHROUGH;
5475  case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
5476  CYTHON_FALLTHROUGH;
5477  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
5478  CYTHON_FALLTHROUGH;
5479  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
5480  CYTHON_FALLTHROUGH;
5481  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
5482  CYTHON_FALLTHROUGH;
5483  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
5484  CYTHON_FALLTHROUGH;
5485  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5486  CYTHON_FALLTHROUGH;
5487  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5488  CYTHON_FALLTHROUGH;
5489  case 0: break;
5490  default: goto __pyx_L5_argtuple_error;
5491  }
5492  kw_args = PyDict_Size(__pyx_kwds);
5493  switch (pos_args) {
5494  case 0:
5495  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_BDMmat_element)) != 0)) kw_args--;
5496  else goto __pyx_L5_argtuple_error;
5497  CYTHON_FALLTHROUGH;
5498  case 1:
5499  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_BDMmatPivots_element)) != 0)) kw_args--;
5500  else {
5501  __Pyx_RaiseArgtupleInvalid("buildBDM2rhs", 1, 10, 10, 1); __PYX_ERR(0, 405, __pyx_L3_error)
5502  }
5503  CYTHON_FALLTHROUGH;
5504  case 2:
5505  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_w_dS_f)) != 0)) kw_args--;
5506  else {
5507  __Pyx_RaiseArgtupleInvalid("buildBDM2rhs", 1, 10, 10, 2); __PYX_ERR(0, 405, __pyx_L3_error)
5508  }
5509  CYTHON_FALLTHROUGH;
5510  case 3:
5511  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ebq_n)) != 0)) kw_args--;
5512  else {
5513  __Pyx_RaiseArgtupleInvalid("buildBDM2rhs", 1, 10, 10, 3); __PYX_ERR(0, 405, __pyx_L3_error)
5514  }
5515  CYTHON_FALLTHROUGH;
5516  case 4:
5517  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_w_interior_gradients)) != 0)) kw_args--;
5518  else {
5519  __Pyx_RaiseArgtupleInvalid("buildBDM2rhs", 1, 10, 10, 4); __PYX_ERR(0, 405, __pyx_L3_error)
5520  }
5521  CYTHON_FALLTHROUGH;
5522  case 5:
5523  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_w_interior_divfree)) != 0)) kw_args--;
5524  else {
5525  __Pyx_RaiseArgtupleInvalid("buildBDM2rhs", 1, 10, 10, 5); __PYX_ERR(0, 405, __pyx_L3_error)
5526  }
5527  CYTHON_FALLTHROUGH;
5528  case 6:
5529  if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ebq_velocity)) != 0)) kw_args--;
5530  else {
5531  __Pyx_RaiseArgtupleInvalid("buildBDM2rhs", 1, 10, 10, 6); __PYX_ERR(0, 405, __pyx_L3_error)
5532  }
5533  CYTHON_FALLTHROUGH;
5534  case 7:
5535  if (likely((values[7] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_q_velocity)) != 0)) kw_args--;
5536  else {
5537  __Pyx_RaiseArgtupleInvalid("buildBDM2rhs", 1, 10, 10, 7); __PYX_ERR(0, 405, __pyx_L3_error)
5538  }
5539  CYTHON_FALLTHROUGH;
5540  case 8:
5541  if (likely((values[8] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_q_vdofs)) != 0)) kw_args--;
5542  else {
5543  __Pyx_RaiseArgtupleInvalid("buildBDM2rhs", 1, 10, 10, 8); __PYX_ERR(0, 405, __pyx_L3_error)
5544  }
5545  CYTHON_FALLTHROUGH;
5546  case 9:
5547  if (likely((values[9] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_edgeFlags)) != 0)) kw_args--;
5548  else {
5549  __Pyx_RaiseArgtupleInvalid("buildBDM2rhs", 1, 10, 10, 9); __PYX_ERR(0, 405, __pyx_L3_error)
5550  }
5551  }
5552  if (unlikely(kw_args > 0)) {
5553  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "buildBDM2rhs") < 0)) __PYX_ERR(0, 405, __pyx_L3_error)
5554  }
5555  } else if (PyTuple_GET_SIZE(__pyx_args) != 10) {
5556  goto __pyx_L5_argtuple_error;
5557  } else {
5558  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5559  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5560  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
5561  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
5562  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
5563  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
5564  values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
5565  values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
5566  values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
5567  values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
5568  }
5569  __pyx_v_BDMmat_element = ((PyArrayObject *)values[0]);
5570  __pyx_v_BDMmatPivots_element = ((PyArrayObject *)values[1]);
5571  __pyx_v_w_dS_f = ((PyArrayObject *)values[2]);
5572  __pyx_v_ebq_n = ((PyArrayObject *)values[3]);
5573  __pyx_v_w_interior_gradients = ((PyArrayObject *)values[4]);
5574  __pyx_v_w_interior_divfree = ((PyArrayObject *)values[5]);
5575  __pyx_v_ebq_velocity = ((PyArrayObject *)values[6]);
5576  __pyx_v_q_velocity = ((PyArrayObject *)values[7]);
5577  __pyx_v_q_vdofs = ((PyArrayObject *)values[8]);
5578  __pyx_v_edgeFlags = ((PyArrayObject *)values[9]);
5579  }
5580  goto __pyx_L4_argument_unpacking_done;
5581  __pyx_L5_argtuple_error:;
5582  __Pyx_RaiseArgtupleInvalid("buildBDM2rhs", 1, 10, 10, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 405, __pyx_L3_error)
5583  __pyx_L3_error:;
5584  __Pyx_AddTraceback("cpostprocessing.buildBDM2rhs", __pyx_clineno, __pyx_lineno, __pyx_filename);
5585  __Pyx_RefNannyFinishContext();
5586  return NULL;
5587  __pyx_L4_argument_unpacking_done:;
5588  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_BDMmat_element), __pyx_ptype_5numpy_ndarray, 1, "BDMmat_element", 0))) __PYX_ERR(0, 405, __pyx_L1_error)
5589  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_BDMmatPivots_element), __pyx_ptype_5numpy_ndarray, 1, "BDMmatPivots_element", 0))) __PYX_ERR(0, 406, __pyx_L1_error)
5590  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_w_dS_f), __pyx_ptype_5numpy_ndarray, 1, "w_dS_f", 0))) __PYX_ERR(0, 407, __pyx_L1_error)
5591  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ebq_n), __pyx_ptype_5numpy_ndarray, 1, "ebq_n", 0))) __PYX_ERR(0, 408, __pyx_L1_error)
5592  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_w_interior_gradients), __pyx_ptype_5numpy_ndarray, 1, "w_interior_gradients", 0))) __PYX_ERR(0, 409, __pyx_L1_error)
5593  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_w_interior_divfree), __pyx_ptype_5numpy_ndarray, 1, "w_interior_divfree", 0))) __PYX_ERR(0, 410, __pyx_L1_error)
5594  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ebq_velocity), __pyx_ptype_5numpy_ndarray, 1, "ebq_velocity", 0))) __PYX_ERR(0, 411, __pyx_L1_error)
5595  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_q_velocity), __pyx_ptype_5numpy_ndarray, 1, "q_velocity", 0))) __PYX_ERR(0, 412, __pyx_L1_error)
5596  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_q_vdofs), __pyx_ptype_5numpy_ndarray, 1, "q_vdofs", 0))) __PYX_ERR(0, 413, __pyx_L1_error)
5597  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_edgeFlags), __pyx_ptype_5numpy_ndarray, 1, "edgeFlags", 0))) __PYX_ERR(0, 414, __pyx_L1_error)
5598  __pyx_r = __pyx_pf_15cpostprocessing_32buildBDM2rhs(__pyx_self, __pyx_v_BDMmat_element, __pyx_v_BDMmatPivots_element, __pyx_v_w_dS_f, __pyx_v_ebq_n, __pyx_v_w_interior_gradients, __pyx_v_w_interior_divfree, __pyx_v_ebq_velocity, __pyx_v_q_velocity, __pyx_v_q_vdofs, __pyx_v_edgeFlags);
5599 
5600  /* function exit code */
5601  goto __pyx_L0;
5602  __pyx_L1_error:;
5603  __pyx_r = NULL;
5604  __pyx_L0:;
5605  __Pyx_RefNannyFinishContext();
5606  return __pyx_r;
5607 }
5608 
5609 static PyObject *__pyx_pf_15cpostprocessing_32buildBDM2rhs(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_BDMmat_element, PyArrayObject *__pyx_v_BDMmatPivots_element, PyArrayObject *__pyx_v_w_dS_f, PyArrayObject *__pyx_v_ebq_n, PyArrayObject *__pyx_v_w_interior_gradients, PyArrayObject *__pyx_v_w_interior_divfree, PyArrayObject *__pyx_v_ebq_velocity, PyArrayObject *__pyx_v_q_velocity, PyArrayObject *__pyx_v_q_vdofs, PyArrayObject *__pyx_v_edgeFlags) {
5610  PyObject *__pyx_r = NULL;
5611  __Pyx_RefNannyDeclarations
5612  __Pyx_RefNannySetupContext("buildBDM2rhs", 0);
5613 
5614  /* "cpostprocessing.pyx":415
5615  * np.ndarray q_vdofs,
5616  * np.ndarray edgeFlags):
5617  * pp.buildBDM2rhs(ebq_n.shape[0], # <<<<<<<<<<<<<<
5618  * ebq_n.shape[1],
5619  * ebq_n.shape[2],
5620  */
5621  buildBDM2rhs((__pyx_v_ebq_n->dimensions[0]), (__pyx_v_ebq_n->dimensions[1]), (__pyx_v_ebq_n->dimensions[2]), (__pyx_v_q_velocity->dimensions[1]), (__pyx_v_ebq_n->dimensions[3]), (__pyx_v_w_dS_f->dimensions[3]), (__pyx_v_BDMmat_element->dimensions[1]), (__pyx_v_w_interior_gradients->dimensions[2]), ((double *)__pyx_v_BDMmat_element->data), ((int *)__pyx_v_BDMmatPivots_element->data), ((int *)__pyx_v_edgeFlags->data), ((double *)__pyx_v_w_dS_f->data), ((double *)__pyx_v_ebq_n->data), ((double *)__pyx_v_w_interior_gradients->data), ((double *)__pyx_v_w_interior_divfree->data), ((double *)__pyx_v_ebq_velocity->data), ((double *)__pyx_v_q_velocity->data), ((double *)__pyx_v_q_vdofs->data));
5622 
5623  /* "cpostprocessing.pyx":405
5624  * <double*>(q_vdofs.data))
5625  *
5626  * def buildBDM2rhs(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
5627  * np.ndarray BDMmatPivots_element,
5628  * np.ndarray w_dS_f,
5629  */
5630 
5631  /* function exit code */
5632  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
5633  __Pyx_XGIVEREF(__pyx_r);
5634  __Pyx_RefNannyFinishContext();
5635  return __pyx_r;
5636 }
5637 
5638 /* "cpostprocessing.pyx":434
5639  * <double*>(q_vdofs.data))
5640  *
5641  * def solveLocalBDM1projectionFromFlux(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
5642  * np.ndarray BDMmatPivots_element,
5643  * np.ndarray elementBoundaryElementsArray,
5644  */
5645 
5646 /* Python wrapper */
5647 static PyObject *__pyx_pw_15cpostprocessing_35solveLocalBDM1projectionFromFlux(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
5648 static PyMethodDef __pyx_mdef_15cpostprocessing_35solveLocalBDM1projectionFromFlux = {"solveLocalBDM1projectionFromFlux", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_35solveLocalBDM1projectionFromFlux, METH_VARARGS|METH_KEYWORDS, 0};
5649 static PyObject *__pyx_pw_15cpostprocessing_35solveLocalBDM1projectionFromFlux(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
5650  PyArrayObject *__pyx_v_BDMmat_element = 0;
5651  PyArrayObject *__pyx_v_BDMmatPivots_element = 0;
5652  PyArrayObject *__pyx_v_elementBoundaryElementsArray = 0;
5653  PyArrayObject *__pyx_v_elementBoundariesArray = 0;
5654  PyArrayObject *__pyx_v_w_dS_f = 0;
5655  PyArrayObject *__pyx_v_ebq_global_flux = 0;
5656  PyArrayObject *__pyx_v_q_vdofs = 0;
5657  int __pyx_lineno = 0;
5658  const char *__pyx_filename = NULL;
5659  int __pyx_clineno = 0;
5660  PyObject *__pyx_r = 0;
5661  __Pyx_RefNannyDeclarations
5662  __Pyx_RefNannySetupContext("solveLocalBDM1projectionFromFlux (wrapper)", 0);
5663  {
5664  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_BDMmat_element,&__pyx_n_s_BDMmatPivots_element,&__pyx_n_s_elementBoundaryElementsArray,&__pyx_n_s_elementBoundariesArray,&__pyx_n_s_w_dS_f,&__pyx_n_s_ebq_global_flux,&__pyx_n_s_q_vdofs,0};
5665  PyObject* values[7] = {0,0,0,0,0,0,0};
5666  if (unlikely(__pyx_kwds)) {
5667  Py_ssize_t kw_args;
5668  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
5669  switch (pos_args) {
5670  case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
5671  CYTHON_FALLTHROUGH;
5672  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
5673  CYTHON_FALLTHROUGH;
5674  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
5675  CYTHON_FALLTHROUGH;
5676  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
5677  CYTHON_FALLTHROUGH;
5678  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
5679  CYTHON_FALLTHROUGH;
5680  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5681  CYTHON_FALLTHROUGH;
5682  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5683  CYTHON_FALLTHROUGH;
5684  case 0: break;
5685  default: goto __pyx_L5_argtuple_error;
5686  }
5687  kw_args = PyDict_Size(__pyx_kwds);
5688  switch (pos_args) {
5689  case 0:
5690  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_BDMmat_element)) != 0)) kw_args--;
5691  else goto __pyx_L5_argtuple_error;
5692  CYTHON_FALLTHROUGH;
5693  case 1:
5694  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_BDMmatPivots_element)) != 0)) kw_args--;
5695  else {
5696  __Pyx_RaiseArgtupleInvalid("solveLocalBDM1projectionFromFlux", 1, 7, 7, 1); __PYX_ERR(0, 434, __pyx_L3_error)
5697  }
5698  CYTHON_FALLTHROUGH;
5699  case 2:
5700  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryElementsArray)) != 0)) kw_args--;
5701  else {
5702  __Pyx_RaiseArgtupleInvalid("solveLocalBDM1projectionFromFlux", 1, 7, 7, 2); __PYX_ERR(0, 434, __pyx_L3_error)
5703  }
5704  CYTHON_FALLTHROUGH;
5705  case 3:
5706  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundariesArray)) != 0)) kw_args--;
5707  else {
5708  __Pyx_RaiseArgtupleInvalid("solveLocalBDM1projectionFromFlux", 1, 7, 7, 3); __PYX_ERR(0, 434, __pyx_L3_error)
5709  }
5710  CYTHON_FALLTHROUGH;
5711  case 4:
5712  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_w_dS_f)) != 0)) kw_args--;
5713  else {
5714  __Pyx_RaiseArgtupleInvalid("solveLocalBDM1projectionFromFlux", 1, 7, 7, 4); __PYX_ERR(0, 434, __pyx_L3_error)
5715  }
5716  CYTHON_FALLTHROUGH;
5717  case 5:
5718  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ebq_global_flux)) != 0)) kw_args--;
5719  else {
5720  __Pyx_RaiseArgtupleInvalid("solveLocalBDM1projectionFromFlux", 1, 7, 7, 5); __PYX_ERR(0, 434, __pyx_L3_error)
5721  }
5722  CYTHON_FALLTHROUGH;
5723  case 6:
5724  if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_q_vdofs)) != 0)) kw_args--;
5725  else {
5726  __Pyx_RaiseArgtupleInvalid("solveLocalBDM1projectionFromFlux", 1, 7, 7, 6); __PYX_ERR(0, 434, __pyx_L3_error)
5727  }
5728  }
5729  if (unlikely(kw_args > 0)) {
5730  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "solveLocalBDM1projectionFromFlux") < 0)) __PYX_ERR(0, 434, __pyx_L3_error)
5731  }
5732  } else if (PyTuple_GET_SIZE(__pyx_args) != 7) {
5733  goto __pyx_L5_argtuple_error;
5734  } else {
5735  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5736  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5737  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
5738  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
5739  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
5740  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
5741  values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
5742  }
5743  __pyx_v_BDMmat_element = ((PyArrayObject *)values[0]);
5744  __pyx_v_BDMmatPivots_element = ((PyArrayObject *)values[1]);
5745  __pyx_v_elementBoundaryElementsArray = ((PyArrayObject *)values[2]);
5746  __pyx_v_elementBoundariesArray = ((PyArrayObject *)values[3]);
5747  __pyx_v_w_dS_f = ((PyArrayObject *)values[4]);
5748  __pyx_v_ebq_global_flux = ((PyArrayObject *)values[5]);
5749  __pyx_v_q_vdofs = ((PyArrayObject *)values[6]);
5750  }
5751  goto __pyx_L4_argument_unpacking_done;
5752  __pyx_L5_argtuple_error:;
5753  __Pyx_RaiseArgtupleInvalid("solveLocalBDM1projectionFromFlux", 1, 7, 7, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 434, __pyx_L3_error)
5754  __pyx_L3_error:;
5755  __Pyx_AddTraceback("cpostprocessing.solveLocalBDM1projectionFromFlux", __pyx_clineno, __pyx_lineno, __pyx_filename);
5756  __Pyx_RefNannyFinishContext();
5757  return NULL;
5758  __pyx_L4_argument_unpacking_done:;
5759  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_BDMmat_element), __pyx_ptype_5numpy_ndarray, 1, "BDMmat_element", 0))) __PYX_ERR(0, 434, __pyx_L1_error)
5760  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_BDMmatPivots_element), __pyx_ptype_5numpy_ndarray, 1, "BDMmatPivots_element", 0))) __PYX_ERR(0, 435, __pyx_L1_error)
5761  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryElementsArray), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryElementsArray", 0))) __PYX_ERR(0, 436, __pyx_L1_error)
5762  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundariesArray), __pyx_ptype_5numpy_ndarray, 1, "elementBoundariesArray", 0))) __PYX_ERR(0, 437, __pyx_L1_error)
5763  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_w_dS_f), __pyx_ptype_5numpy_ndarray, 1, "w_dS_f", 0))) __PYX_ERR(0, 438, __pyx_L1_error)
5764  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ebq_global_flux), __pyx_ptype_5numpy_ndarray, 1, "ebq_global_flux", 0))) __PYX_ERR(0, 439, __pyx_L1_error)
5765  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_q_vdofs), __pyx_ptype_5numpy_ndarray, 1, "q_vdofs", 0))) __PYX_ERR(0, 440, __pyx_L1_error)
5766  __pyx_r = __pyx_pf_15cpostprocessing_34solveLocalBDM1projectionFromFlux(__pyx_self, __pyx_v_BDMmat_element, __pyx_v_BDMmatPivots_element, __pyx_v_elementBoundaryElementsArray, __pyx_v_elementBoundariesArray, __pyx_v_w_dS_f, __pyx_v_ebq_global_flux, __pyx_v_q_vdofs);
5767 
5768  /* function exit code */
5769  goto __pyx_L0;
5770  __pyx_L1_error:;
5771  __pyx_r = NULL;
5772  __pyx_L0:;
5773  __Pyx_RefNannyFinishContext();
5774  return __pyx_r;
5775 }
5776 
5777 static PyObject *__pyx_pf_15cpostprocessing_34solveLocalBDM1projectionFromFlux(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_BDMmat_element, PyArrayObject *__pyx_v_BDMmatPivots_element, PyArrayObject *__pyx_v_elementBoundaryElementsArray, PyArrayObject *__pyx_v_elementBoundariesArray, PyArrayObject *__pyx_v_w_dS_f, PyArrayObject *__pyx_v_ebq_global_flux, PyArrayObject *__pyx_v_q_vdofs) {
5778  PyObject *__pyx_r = NULL;
5779  __Pyx_RefNannyDeclarations
5780  __Pyx_RefNannySetupContext("solveLocalBDM1projectionFromFlux", 0);
5781 
5782  /* "cpostprocessing.pyx":441
5783  * np.ndarray ebq_global_flux,
5784  * np.ndarray q_vdofs):
5785  * pp.solveLocalBDM1projectionFromFlux(w_dS_f.shape[0], # <<<<<<<<<<<<<<
5786  * w_dS_f.shape[1],
5787  * w_dS_f.shape[2],
5788  */
5789  solveLocalBDM1projectionFromFlux((__pyx_v_w_dS_f->dimensions[0]), (__pyx_v_w_dS_f->dimensions[1]), (__pyx_v_w_dS_f->dimensions[2]), (__pyx_v_w_dS_f->dimensions[3]), (__pyx_v_BDMmat_element->dimensions[1]), ((double *)__pyx_v_BDMmat_element->data), ((int *)__pyx_v_BDMmatPivots_element->data), ((int *)__pyx_v_elementBoundaryElementsArray->data), ((int *)__pyx_v_elementBoundariesArray->data), ((double *)__pyx_v_w_dS_f->data), ((double *)__pyx_v_ebq_global_flux->data), ((double *)__pyx_v_q_vdofs->data));
5790 
5791  /* "cpostprocessing.pyx":434
5792  * <double*>(q_vdofs.data))
5793  *
5794  * def solveLocalBDM1projectionFromFlux(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
5795  * np.ndarray BDMmatPivots_element,
5796  * np.ndarray elementBoundaryElementsArray,
5797  */
5798 
5799  /* function exit code */
5800  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
5801  __Pyx_XGIVEREF(__pyx_r);
5802  __Pyx_RefNannyFinishContext();
5803  return __pyx_r;
5804 }
5805 
5806 /* "cpostprocessing.pyx":454
5807  * <double*>(q_vdofs.data))
5808  *
5809  * def getElementBDM1velocityValuesLagrangeRep(np.ndarray q_v, # <<<<<<<<<<<<<<
5810  * np.ndarray p1_vdofs,
5811  * np.ndarray q_velocity):
5812  */
5813 
5814 /* Python wrapper */
5815 static PyObject *__pyx_pw_15cpostprocessing_37getElementBDM1velocityValuesLagrangeRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
5816 static PyMethodDef __pyx_mdef_15cpostprocessing_37getElementBDM1velocityValuesLagrangeRep = {"getElementBDM1velocityValuesLagrangeRep", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_37getElementBDM1velocityValuesLagrangeRep, METH_VARARGS|METH_KEYWORDS, 0};
5817 static PyObject *__pyx_pw_15cpostprocessing_37getElementBDM1velocityValuesLagrangeRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
5818  PyArrayObject *__pyx_v_q_v = 0;
5819  PyArrayObject *__pyx_v_p1_vdofs = 0;
5820  PyArrayObject *__pyx_v_q_velocity = 0;
5821  int __pyx_lineno = 0;
5822  const char *__pyx_filename = NULL;
5823  int __pyx_clineno = 0;
5824  PyObject *__pyx_r = 0;
5825  __Pyx_RefNannyDeclarations
5826  __Pyx_RefNannySetupContext("getElementBDM1velocityValuesLagrangeRep (wrapper)", 0);
5827  {
5828  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_q_v,&__pyx_n_s_p1_vdofs,&__pyx_n_s_q_velocity,0};
5829  PyObject* values[3] = {0,0,0};
5830  if (unlikely(__pyx_kwds)) {
5831  Py_ssize_t kw_args;
5832  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
5833  switch (pos_args) {
5834  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
5835  CYTHON_FALLTHROUGH;
5836  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5837  CYTHON_FALLTHROUGH;
5838  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5839  CYTHON_FALLTHROUGH;
5840  case 0: break;
5841  default: goto __pyx_L5_argtuple_error;
5842  }
5843  kw_args = PyDict_Size(__pyx_kwds);
5844  switch (pos_args) {
5845  case 0:
5846  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_q_v)) != 0)) kw_args--;
5847  else goto __pyx_L5_argtuple_error;
5848  CYTHON_FALLTHROUGH;
5849  case 1:
5850  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_p1_vdofs)) != 0)) kw_args--;
5851  else {
5852  __Pyx_RaiseArgtupleInvalid("getElementBDM1velocityValuesLagrangeRep", 1, 3, 3, 1); __PYX_ERR(0, 454, __pyx_L3_error)
5853  }
5854  CYTHON_FALLTHROUGH;
5855  case 2:
5856  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_q_velocity)) != 0)) kw_args--;
5857  else {
5858  __Pyx_RaiseArgtupleInvalid("getElementBDM1velocityValuesLagrangeRep", 1, 3, 3, 2); __PYX_ERR(0, 454, __pyx_L3_error)
5859  }
5860  }
5861  if (unlikely(kw_args > 0)) {
5862  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "getElementBDM1velocityValuesLagrangeRep") < 0)) __PYX_ERR(0, 454, __pyx_L3_error)
5863  }
5864  } else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
5865  goto __pyx_L5_argtuple_error;
5866  } else {
5867  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
5868  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
5869  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
5870  }
5871  __pyx_v_q_v = ((PyArrayObject *)values[0]);
5872  __pyx_v_p1_vdofs = ((PyArrayObject *)values[1]);
5873  __pyx_v_q_velocity = ((PyArrayObject *)values[2]);
5874  }
5875  goto __pyx_L4_argument_unpacking_done;
5876  __pyx_L5_argtuple_error:;
5877  __Pyx_RaiseArgtupleInvalid("getElementBDM1velocityValuesLagrangeRep", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 454, __pyx_L3_error)
5878  __pyx_L3_error:;
5879  __Pyx_AddTraceback("cpostprocessing.getElementBDM1velocityValuesLagrangeRep", __pyx_clineno, __pyx_lineno, __pyx_filename);
5880  __Pyx_RefNannyFinishContext();
5881  return NULL;
5882  __pyx_L4_argument_unpacking_done:;
5883  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_q_v), __pyx_ptype_5numpy_ndarray, 1, "q_v", 0))) __PYX_ERR(0, 454, __pyx_L1_error)
5884  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_p1_vdofs), __pyx_ptype_5numpy_ndarray, 1, "p1_vdofs", 0))) __PYX_ERR(0, 455, __pyx_L1_error)
5885  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_q_velocity), __pyx_ptype_5numpy_ndarray, 1, "q_velocity", 0))) __PYX_ERR(0, 456, __pyx_L1_error)
5886  __pyx_r = __pyx_pf_15cpostprocessing_36getElementBDM1velocityValuesLagrangeRep(__pyx_self, __pyx_v_q_v, __pyx_v_p1_vdofs, __pyx_v_q_velocity);
5887 
5888  /* function exit code */
5889  goto __pyx_L0;
5890  __pyx_L1_error:;
5891  __pyx_r = NULL;
5892  __pyx_L0:;
5893  __Pyx_RefNannyFinishContext();
5894  return __pyx_r;
5895 }
5896 
5897 static PyObject *__pyx_pf_15cpostprocessing_36getElementBDM1velocityValuesLagrangeRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_q_v, PyArrayObject *__pyx_v_p1_vdofs, PyArrayObject *__pyx_v_q_velocity) {
5898  int __pyx_v_nVDOFs_element;
5899  PyObject *__pyx_r = NULL;
5900  __Pyx_RefNannyDeclarations
5901  int __pyx_t_1;
5902  int __pyx_lineno = 0;
5903  const char *__pyx_filename = NULL;
5904  int __pyx_clineno = 0;
5905  __Pyx_RefNannySetupContext("getElementBDM1velocityValuesLagrangeRep", 0);
5906 
5907  /* "cpostprocessing.pyx":457
5908  * np.ndarray p1_vdofs,
5909  * np.ndarray q_velocity):
5910  * cdef int nVDOFs_element = q_velocity.shape[2]*(q_velocity.shape[2]+1) # <<<<<<<<<<<<<<
5911  *
5912  * if p1_vdofs.ndim > 1:
5913  */
5914  __pyx_v_nVDOFs_element = ((__pyx_v_q_velocity->dimensions[2]) * ((__pyx_v_q_velocity->dimensions[2]) + 1));
5915 
5916  /* "cpostprocessing.pyx":459
5917  * cdef int nVDOFs_element = q_velocity.shape[2]*(q_velocity.shape[2]+1)
5918  *
5919  * if p1_vdofs.ndim > 1: # <<<<<<<<<<<<<<
5920  * assert nVDOFs_element == p1_vdofs.shape[1]
5921  * pp.getElementBDM1velocityValuesLagrangeRep(q_velocity.shape[0],
5922  */
5923  __pyx_t_1 = ((__pyx_v_p1_vdofs->nd > 1) != 0);
5924  if (__pyx_t_1) {
5925 
5926  /* "cpostprocessing.pyx":460
5927  *
5928  * if p1_vdofs.ndim > 1:
5929  * assert nVDOFs_element == p1_vdofs.shape[1] # <<<<<<<<<<<<<<
5930  * pp.getElementBDM1velocityValuesLagrangeRep(q_velocity.shape[0],
5931  * q_velocity.shape[1],
5932  */
5933  #ifndef CYTHON_WITHOUT_ASSERTIONS
5934  if (unlikely(!Py_OptimizeFlag)) {
5935  if (unlikely(!((__pyx_v_nVDOFs_element == (__pyx_v_p1_vdofs->dimensions[1])) != 0))) {
5936  PyErr_SetNone(PyExc_AssertionError);
5937  __PYX_ERR(0, 460, __pyx_L1_error)
5938  }
5939  }
5940  #endif
5941 
5942  /* "cpostprocessing.pyx":459
5943  * cdef int nVDOFs_element = q_velocity.shape[2]*(q_velocity.shape[2]+1)
5944  *
5945  * if p1_vdofs.ndim > 1: # <<<<<<<<<<<<<<
5946  * assert nVDOFs_element == p1_vdofs.shape[1]
5947  * pp.getElementBDM1velocityValuesLagrangeRep(q_velocity.shape[0],
5948  */
5949  }
5950 
5951  /* "cpostprocessing.pyx":461
5952  * if p1_vdofs.ndim > 1:
5953  * assert nVDOFs_element == p1_vdofs.shape[1]
5954  * pp.getElementBDM1velocityValuesLagrangeRep(q_velocity.shape[0], # <<<<<<<<<<<<<<
5955  * q_velocity.shape[1],
5956  * q_velocity.shape[2],
5957  */
5958  getElementBDM1velocityValuesLagrangeRep((__pyx_v_q_velocity->dimensions[0]), (__pyx_v_q_velocity->dimensions[1]), (__pyx_v_q_velocity->dimensions[2]), (__pyx_v_q_v->dimensions[2]), __pyx_v_nVDOFs_element, ((double *)__pyx_v_q_v->data), ((double *)__pyx_v_p1_vdofs->data), ((double *)__pyx_v_q_velocity->data));
5959 
5960  /* "cpostprocessing.pyx":454
5961  * <double*>(q_vdofs.data))
5962  *
5963  * def getElementBDM1velocityValuesLagrangeRep(np.ndarray q_v, # <<<<<<<<<<<<<<
5964  * np.ndarray p1_vdofs,
5965  * np.ndarray q_velocity):
5966  */
5967 
5968  /* function exit code */
5969  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
5970  goto __pyx_L0;
5971  __pyx_L1_error:;
5972  __Pyx_AddTraceback("cpostprocessing.getElementBDM1velocityValuesLagrangeRep", __pyx_clineno, __pyx_lineno, __pyx_filename);
5973  __pyx_r = NULL;
5974  __pyx_L0:;
5975  __Pyx_XGIVEREF(__pyx_r);
5976  __Pyx_RefNannyFinishContext();
5977  return __pyx_r;
5978 }
5979 
5980 /* "cpostprocessing.pyx":470
5981  * <double*>(q_velocity.data))
5982  *
5983  * def getElementBDM2velocityValuesLagrangeRep(np.ndarray q_v, # <<<<<<<<<<<<<<
5984  * np.ndarray p1_vdofs,
5985  * np.ndarray q_velocity):
5986  */
5987 
5988 /* Python wrapper */
5989 static PyObject *__pyx_pw_15cpostprocessing_39getElementBDM2velocityValuesLagrangeRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
5990 static PyMethodDef __pyx_mdef_15cpostprocessing_39getElementBDM2velocityValuesLagrangeRep = {"getElementBDM2velocityValuesLagrangeRep", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_39getElementBDM2velocityValuesLagrangeRep, METH_VARARGS|METH_KEYWORDS, 0};
5991 static PyObject *__pyx_pw_15cpostprocessing_39getElementBDM2velocityValuesLagrangeRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
5992  PyArrayObject *__pyx_v_q_v = 0;
5993  PyArrayObject *__pyx_v_p1_vdofs = 0;
5994  PyArrayObject *__pyx_v_q_velocity = 0;
5995  int __pyx_lineno = 0;
5996  const char *__pyx_filename = NULL;
5997  int __pyx_clineno = 0;
5998  PyObject *__pyx_r = 0;
5999  __Pyx_RefNannyDeclarations
6000  __Pyx_RefNannySetupContext("getElementBDM2velocityValuesLagrangeRep (wrapper)", 0);
6001  {
6002  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_q_v,&__pyx_n_s_p1_vdofs,&__pyx_n_s_q_velocity,0};
6003  PyObject* values[3] = {0,0,0};
6004  if (unlikely(__pyx_kwds)) {
6005  Py_ssize_t kw_args;
6006  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
6007  switch (pos_args) {
6008  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
6009  CYTHON_FALLTHROUGH;
6010  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
6011  CYTHON_FALLTHROUGH;
6012  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
6013  CYTHON_FALLTHROUGH;
6014  case 0: break;
6015  default: goto __pyx_L5_argtuple_error;
6016  }
6017  kw_args = PyDict_Size(__pyx_kwds);
6018  switch (pos_args) {
6019  case 0:
6020  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_q_v)) != 0)) kw_args--;
6021  else goto __pyx_L5_argtuple_error;
6022  CYTHON_FALLTHROUGH;
6023  case 1:
6024  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_p1_vdofs)) != 0)) kw_args--;
6025  else {
6026  __Pyx_RaiseArgtupleInvalid("getElementBDM2velocityValuesLagrangeRep", 1, 3, 3, 1); __PYX_ERR(0, 470, __pyx_L3_error)
6027  }
6028  CYTHON_FALLTHROUGH;
6029  case 2:
6030  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_q_velocity)) != 0)) kw_args--;
6031  else {
6032  __Pyx_RaiseArgtupleInvalid("getElementBDM2velocityValuesLagrangeRep", 1, 3, 3, 2); __PYX_ERR(0, 470, __pyx_L3_error)
6033  }
6034  }
6035  if (unlikely(kw_args > 0)) {
6036  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "getElementBDM2velocityValuesLagrangeRep") < 0)) __PYX_ERR(0, 470, __pyx_L3_error)
6037  }
6038  } else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
6039  goto __pyx_L5_argtuple_error;
6040  } else {
6041  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
6042  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
6043  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
6044  }
6045  __pyx_v_q_v = ((PyArrayObject *)values[0]);
6046  __pyx_v_p1_vdofs = ((PyArrayObject *)values[1]);
6047  __pyx_v_q_velocity = ((PyArrayObject *)values[2]);
6048  }
6049  goto __pyx_L4_argument_unpacking_done;
6050  __pyx_L5_argtuple_error:;
6051  __Pyx_RaiseArgtupleInvalid("getElementBDM2velocityValuesLagrangeRep", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 470, __pyx_L3_error)
6052  __pyx_L3_error:;
6053  __Pyx_AddTraceback("cpostprocessing.getElementBDM2velocityValuesLagrangeRep", __pyx_clineno, __pyx_lineno, __pyx_filename);
6054  __Pyx_RefNannyFinishContext();
6055  return NULL;
6056  __pyx_L4_argument_unpacking_done:;
6057  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_q_v), __pyx_ptype_5numpy_ndarray, 1, "q_v", 0))) __PYX_ERR(0, 470, __pyx_L1_error)
6058  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_p1_vdofs), __pyx_ptype_5numpy_ndarray, 1, "p1_vdofs", 0))) __PYX_ERR(0, 471, __pyx_L1_error)
6059  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_q_velocity), __pyx_ptype_5numpy_ndarray, 1, "q_velocity", 0))) __PYX_ERR(0, 472, __pyx_L1_error)
6060  __pyx_r = __pyx_pf_15cpostprocessing_38getElementBDM2velocityValuesLagrangeRep(__pyx_self, __pyx_v_q_v, __pyx_v_p1_vdofs, __pyx_v_q_velocity);
6061 
6062  /* function exit code */
6063  goto __pyx_L0;
6064  __pyx_L1_error:;
6065  __pyx_r = NULL;
6066  __pyx_L0:;
6067  __Pyx_RefNannyFinishContext();
6068  return __pyx_r;
6069 }
6070 
6071 static PyObject *__pyx_pf_15cpostprocessing_38getElementBDM2velocityValuesLagrangeRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_q_v, PyArrayObject *__pyx_v_p1_vdofs, PyArrayObject *__pyx_v_q_velocity) {
6072  long __pyx_v_nVDOFs_element;
6073  PyObject *__pyx_r = NULL;
6074  __Pyx_RefNannyDeclarations
6075  int __pyx_t_1;
6076  int __pyx_lineno = 0;
6077  const char *__pyx_filename = NULL;
6078  int __pyx_clineno = 0;
6079  __Pyx_RefNannySetupContext("getElementBDM2velocityValuesLagrangeRep", 0);
6080 
6081  /* "cpostprocessing.pyx":473
6082  * np.ndarray p1_vdofs,
6083  * np.ndarray q_velocity):
6084  * if q_velocity.shape[2] == 2: # <<<<<<<<<<<<<<
6085  * #dimension of bdm2 in 2d
6086  * nVDOFs_element = 12
6087  */
6088  __pyx_t_1 = (((__pyx_v_q_velocity->dimensions[2]) == 2) != 0);
6089  if (__pyx_t_1) {
6090 
6091  /* "cpostprocessing.pyx":475
6092  * if q_velocity.shape[2] == 2:
6093  * #dimension of bdm2 in 2d
6094  * nVDOFs_element = 12 # <<<<<<<<<<<<<<
6095  * elif q_velocity.shape[2] == 3:
6096  * #dimension of bdm2 in 3d
6097  */
6098  __pyx_v_nVDOFs_element = 12;
6099 
6100  /* "cpostprocessing.pyx":473
6101  * np.ndarray p1_vdofs,
6102  * np.ndarray q_velocity):
6103  * if q_velocity.shape[2] == 2: # <<<<<<<<<<<<<<
6104  * #dimension of bdm2 in 2d
6105  * nVDOFs_element = 12
6106  */
6107  goto __pyx_L3;
6108  }
6109 
6110  /* "cpostprocessing.pyx":476
6111  * #dimension of bdm2 in 2d
6112  * nVDOFs_element = 12
6113  * elif q_velocity.shape[2] == 3: # <<<<<<<<<<<<<<
6114  * #dimension of bdm2 in 3d
6115  * nVDOFs_element = 30
6116  */
6117  __pyx_t_1 = (((__pyx_v_q_velocity->dimensions[2]) == 3) != 0);
6118  if (__pyx_t_1) {
6119 
6120  /* "cpostprocessing.pyx":478
6121  * elif q_velocity.shape[2] == 3:
6122  * #dimension of bdm2 in 3d
6123  * nVDOFs_element = 30 # <<<<<<<<<<<<<<
6124  *
6125  * if p1_vdofs.ndim > 1:
6126  */
6127  __pyx_v_nVDOFs_element = 30;
6128 
6129  /* "cpostprocessing.pyx":476
6130  * #dimension of bdm2 in 2d
6131  * nVDOFs_element = 12
6132  * elif q_velocity.shape[2] == 3: # <<<<<<<<<<<<<<
6133  * #dimension of bdm2 in 3d
6134  * nVDOFs_element = 30
6135  */
6136  }
6137  __pyx_L3:;
6138 
6139  /* "cpostprocessing.pyx":480
6140  * nVDOFs_element = 30
6141  *
6142  * if p1_vdofs.ndim > 1: # <<<<<<<<<<<<<<
6143  * assert nVDOFs_element == p1_vdofs.shape[1]
6144  *
6145  */
6146  __pyx_t_1 = ((__pyx_v_p1_vdofs->nd > 1) != 0);
6147  if (__pyx_t_1) {
6148 
6149  /* "cpostprocessing.pyx":481
6150  *
6151  * if p1_vdofs.ndim > 1:
6152  * assert nVDOFs_element == p1_vdofs.shape[1] # <<<<<<<<<<<<<<
6153  *
6154  * pp.getElementBDM2velocityValuesLagrangeRep(q_velocity.shape[0],
6155  */
6156  #ifndef CYTHON_WITHOUT_ASSERTIONS
6157  if (unlikely(!Py_OptimizeFlag)) {
6158  if (unlikely(!((__pyx_v_nVDOFs_element == (__pyx_v_p1_vdofs->dimensions[1])) != 0))) {
6159  PyErr_SetNone(PyExc_AssertionError);
6160  __PYX_ERR(0, 481, __pyx_L1_error)
6161  }
6162  }
6163  #endif
6164 
6165  /* "cpostprocessing.pyx":480
6166  * nVDOFs_element = 30
6167  *
6168  * if p1_vdofs.ndim > 1: # <<<<<<<<<<<<<<
6169  * assert nVDOFs_element == p1_vdofs.shape[1]
6170  *
6171  */
6172  }
6173 
6174  /* "cpostprocessing.pyx":483
6175  * assert nVDOFs_element == p1_vdofs.shape[1]
6176  *
6177  * pp.getElementBDM2velocityValuesLagrangeRep(q_velocity.shape[0], # <<<<<<<<<<<<<<
6178  * q_velocity.shape[1],
6179  * q_velocity.shape[2],
6180  */
6181  getElementBDM2velocityValuesLagrangeRep((__pyx_v_q_velocity->dimensions[0]), (__pyx_v_q_velocity->dimensions[1]), (__pyx_v_q_velocity->dimensions[2]), (__pyx_v_q_v->dimensions[2]), __pyx_v_nVDOFs_element, ((double *)__pyx_v_q_v->data), ((double *)__pyx_v_p1_vdofs->data), ((double *)__pyx_v_q_velocity->data));
6182 
6183  /* "cpostprocessing.pyx":470
6184  * <double*>(q_velocity.data))
6185  *
6186  * def getElementBDM2velocityValuesLagrangeRep(np.ndarray q_v, # <<<<<<<<<<<<<<
6187  * np.ndarray p1_vdofs,
6188  * np.ndarray q_velocity):
6189  */
6190 
6191  /* function exit code */
6192  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
6193  goto __pyx_L0;
6194  __pyx_L1_error:;
6195  __Pyx_AddTraceback("cpostprocessing.getElementBDM2velocityValuesLagrangeRep", __pyx_clineno, __pyx_lineno, __pyx_filename);
6196  __pyx_r = NULL;
6197  __pyx_L0:;
6198  __Pyx_XGIVEREF(__pyx_r);
6199  __Pyx_RefNannyFinishContext();
6200  return __pyx_r;
6201 }
6202 
6203 /* "cpostprocessing.pyx":492
6204  * <double*>(q_velocity.data))
6205  *
6206  * def getElementLDGvelocityValuesLagrangeRep(np.ndarray q_v, # <<<<<<<<<<<<<<
6207  * np.ndarray vdofs,
6208  * np.ndarray q_velocity):
6209  */
6210 
6211 /* Python wrapper */
6212 static PyObject *__pyx_pw_15cpostprocessing_41getElementLDGvelocityValuesLagrangeRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
6213 static PyMethodDef __pyx_mdef_15cpostprocessing_41getElementLDGvelocityValuesLagrangeRep = {"getElementLDGvelocityValuesLagrangeRep", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_41getElementLDGvelocityValuesLagrangeRep, METH_VARARGS|METH_KEYWORDS, 0};
6214 static PyObject *__pyx_pw_15cpostprocessing_41getElementLDGvelocityValuesLagrangeRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
6215  PyArrayObject *__pyx_v_q_v = 0;
6216  PyArrayObject *__pyx_v_vdofs = 0;
6217  PyArrayObject *__pyx_v_q_velocity = 0;
6218  int __pyx_lineno = 0;
6219  const char *__pyx_filename = NULL;
6220  int __pyx_clineno = 0;
6221  PyObject *__pyx_r = 0;
6222  __Pyx_RefNannyDeclarations
6223  __Pyx_RefNannySetupContext("getElementLDGvelocityValuesLagrangeRep (wrapper)", 0);
6224  {
6225  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_q_v,&__pyx_n_s_vdofs,&__pyx_n_s_q_velocity,0};
6226  PyObject* values[3] = {0,0,0};
6227  if (unlikely(__pyx_kwds)) {
6228  Py_ssize_t kw_args;
6229  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
6230  switch (pos_args) {
6231  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
6232  CYTHON_FALLTHROUGH;
6233  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
6234  CYTHON_FALLTHROUGH;
6235  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
6236  CYTHON_FALLTHROUGH;
6237  case 0: break;
6238  default: goto __pyx_L5_argtuple_error;
6239  }
6240  kw_args = PyDict_Size(__pyx_kwds);
6241  switch (pos_args) {
6242  case 0:
6243  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_q_v)) != 0)) kw_args--;
6244  else goto __pyx_L5_argtuple_error;
6245  CYTHON_FALLTHROUGH;
6246  case 1:
6247  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_vdofs)) != 0)) kw_args--;
6248  else {
6249  __Pyx_RaiseArgtupleInvalid("getElementLDGvelocityValuesLagrangeRep", 1, 3, 3, 1); __PYX_ERR(0, 492, __pyx_L3_error)
6250  }
6251  CYTHON_FALLTHROUGH;
6252  case 2:
6253  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_q_velocity)) != 0)) kw_args--;
6254  else {
6255  __Pyx_RaiseArgtupleInvalid("getElementLDGvelocityValuesLagrangeRep", 1, 3, 3, 2); __PYX_ERR(0, 492, __pyx_L3_error)
6256  }
6257  }
6258  if (unlikely(kw_args > 0)) {
6259  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "getElementLDGvelocityValuesLagrangeRep") < 0)) __PYX_ERR(0, 492, __pyx_L3_error)
6260  }
6261  } else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
6262  goto __pyx_L5_argtuple_error;
6263  } else {
6264  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
6265  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
6266  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
6267  }
6268  __pyx_v_q_v = ((PyArrayObject *)values[0]);
6269  __pyx_v_vdofs = ((PyArrayObject *)values[1]);
6270  __pyx_v_q_velocity = ((PyArrayObject *)values[2]);
6271  }
6272  goto __pyx_L4_argument_unpacking_done;
6273  __pyx_L5_argtuple_error:;
6274  __Pyx_RaiseArgtupleInvalid("getElementLDGvelocityValuesLagrangeRep", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 492, __pyx_L3_error)
6275  __pyx_L3_error:;
6276  __Pyx_AddTraceback("cpostprocessing.getElementLDGvelocityValuesLagrangeRep", __pyx_clineno, __pyx_lineno, __pyx_filename);
6277  __Pyx_RefNannyFinishContext();
6278  return NULL;
6279  __pyx_L4_argument_unpacking_done:;
6280  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_q_v), __pyx_ptype_5numpy_ndarray, 1, "q_v", 0))) __PYX_ERR(0, 492, __pyx_L1_error)
6281  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_vdofs), __pyx_ptype_5numpy_ndarray, 1, "vdofs", 0))) __PYX_ERR(0, 493, __pyx_L1_error)
6282  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_q_velocity), __pyx_ptype_5numpy_ndarray, 1, "q_velocity", 0))) __PYX_ERR(0, 494, __pyx_L1_error)
6283  __pyx_r = __pyx_pf_15cpostprocessing_40getElementLDGvelocityValuesLagrangeRep(__pyx_self, __pyx_v_q_v, __pyx_v_vdofs, __pyx_v_q_velocity);
6284 
6285  /* function exit code */
6286  goto __pyx_L0;
6287  __pyx_L1_error:;
6288  __pyx_r = NULL;
6289  __pyx_L0:;
6290  __Pyx_RefNannyFinishContext();
6291  return __pyx_r;
6292 }
6293 
6294 static PyObject *__pyx_pf_15cpostprocessing_40getElementLDGvelocityValuesLagrangeRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_q_v, PyArrayObject *__pyx_v_vdofs, PyArrayObject *__pyx_v_q_velocity) {
6295  int __pyx_v_nVDOF_element;
6296  int __pyx_v_nDOF_trial_element;
6297  PyObject *__pyx_r = NULL;
6298  __Pyx_RefNannyDeclarations
6299  int __pyx_t_1;
6300  int __pyx_lineno = 0;
6301  const char *__pyx_filename = NULL;
6302  int __pyx_clineno = 0;
6303  __Pyx_RefNannySetupContext("getElementLDGvelocityValuesLagrangeRep", 0);
6304 
6305  /* "cpostprocessing.pyx":495
6306  * np.ndarray vdofs,
6307  * np.ndarray q_velocity):
6308  * cdef int nVDOF_element =vdofs.shape[1] # <<<<<<<<<<<<<<
6309  * cdef int nDOF_trial_element=q_v.shape[2]
6310  * if vdofs.ndim > 1:
6311  */
6312  __pyx_v_nVDOF_element = (__pyx_v_vdofs->dimensions[1]);
6313 
6314  /* "cpostprocessing.pyx":496
6315  * np.ndarray q_velocity):
6316  * cdef int nVDOF_element =vdofs.shape[1]
6317  * cdef int nDOF_trial_element=q_v.shape[2] # <<<<<<<<<<<<<<
6318  * if vdofs.ndim > 1:
6319  * assert nVDOF_element == q_v.shape[2]*q_velocity.shape[2]
6320  */
6321  __pyx_v_nDOF_trial_element = (__pyx_v_q_v->dimensions[2]);
6322 
6323  /* "cpostprocessing.pyx":497
6324  * cdef int nVDOF_element =vdofs.shape[1]
6325  * cdef int nDOF_trial_element=q_v.shape[2]
6326  * if vdofs.ndim > 1: # <<<<<<<<<<<<<<
6327  * assert nVDOF_element == q_v.shape[2]*q_velocity.shape[2]
6328  * pp.getElementLDGvelocityValuesLagrangeRep(q_velocity.shape[0],
6329  */
6330  __pyx_t_1 = ((__pyx_v_vdofs->nd > 1) != 0);
6331  if (__pyx_t_1) {
6332 
6333  /* "cpostprocessing.pyx":498
6334  * cdef int nDOF_trial_element=q_v.shape[2]
6335  * if vdofs.ndim > 1:
6336  * assert nVDOF_element == q_v.shape[2]*q_velocity.shape[2] # <<<<<<<<<<<<<<
6337  * pp.getElementLDGvelocityValuesLagrangeRep(q_velocity.shape[0],
6338  * q_velocity.shape[1],
6339  */
6340  #ifndef CYTHON_WITHOUT_ASSERTIONS
6341  if (unlikely(!Py_OptimizeFlag)) {
6342  if (unlikely(!((__pyx_v_nVDOF_element == ((__pyx_v_q_v->dimensions[2]) * (__pyx_v_q_velocity->dimensions[2]))) != 0))) {
6343  PyErr_SetNone(PyExc_AssertionError);
6344  __PYX_ERR(0, 498, __pyx_L1_error)
6345  }
6346  }
6347  #endif
6348 
6349  /* "cpostprocessing.pyx":497
6350  * cdef int nVDOF_element =vdofs.shape[1]
6351  * cdef int nDOF_trial_element=q_v.shape[2]
6352  * if vdofs.ndim > 1: # <<<<<<<<<<<<<<
6353  * assert nVDOF_element == q_v.shape[2]*q_velocity.shape[2]
6354  * pp.getElementLDGvelocityValuesLagrangeRep(q_velocity.shape[0],
6355  */
6356  }
6357 
6358  /* "cpostprocessing.pyx":499
6359  * if vdofs.ndim > 1:
6360  * assert nVDOF_element == q_v.shape[2]*q_velocity.shape[2]
6361  * pp.getElementLDGvelocityValuesLagrangeRep(q_velocity.shape[0], # <<<<<<<<<<<<<<
6362  * q_velocity.shape[1],
6363  * q_velocity.shape[2],
6364  */
6365  getElementLDGvelocityValuesLagrangeRep((__pyx_v_q_velocity->dimensions[0]), (__pyx_v_q_velocity->dimensions[1]), (__pyx_v_q_velocity->dimensions[2]), __pyx_v_nDOF_trial_element, __pyx_v_nVDOF_element, ((double *)__pyx_v_q_v->data), ((double *)__pyx_v_vdofs->data), ((double *)__pyx_v_q_velocity->data));
6366 
6367  /* "cpostprocessing.pyx":492
6368  * <double*>(q_velocity.data))
6369  *
6370  * def getElementLDGvelocityValuesLagrangeRep(np.ndarray q_v, # <<<<<<<<<<<<<<
6371  * np.ndarray vdofs,
6372  * np.ndarray q_velocity):
6373  */
6374 
6375  /* function exit code */
6376  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
6377  goto __pyx_L0;
6378  __pyx_L1_error:;
6379  __Pyx_AddTraceback("cpostprocessing.getElementLDGvelocityValuesLagrangeRep", __pyx_clineno, __pyx_lineno, __pyx_filename);
6380  __pyx_r = NULL;
6381  __pyx_L0:;
6382  __Pyx_XGIVEREF(__pyx_r);
6383  __Pyx_RefNannyFinishContext();
6384  return __pyx_r;
6385 }
6386 
6387 /* "cpostprocessing.pyx":508
6388  * <double*>(q_velocity.data))
6389  *
6390  * def getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep(np.ndarray elementBoundaryElementsArray, # <<<<<<<<<<<<<<
6391  * np.ndarray exteriorElementBoundariesArray,
6392  * np.ndarray ebqe_v,
6393  */
6394 
6395 /* Python wrapper */
6396 static PyObject *__pyx_pw_15cpostprocessing_43getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
6397 static PyMethodDef __pyx_mdef_15cpostprocessing_43getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep = {"getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_43getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep, METH_VARARGS|METH_KEYWORDS, 0};
6398 static PyObject *__pyx_pw_15cpostprocessing_43getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
6399  PyArrayObject *__pyx_v_elementBoundaryElementsArray = 0;
6400  PyArrayObject *__pyx_v_exteriorElementBoundariesArray = 0;
6401  PyArrayObject *__pyx_v_ebqe_v = 0;
6402  PyArrayObject *__pyx_v_p1_vdofs = 0;
6403  PyArrayObject *__pyx_v_ebqe_velocity = 0;
6404  int __pyx_lineno = 0;
6405  const char *__pyx_filename = NULL;
6406  int __pyx_clineno = 0;
6407  PyObject *__pyx_r = 0;
6408  __Pyx_RefNannyDeclarations
6409  __Pyx_RefNannySetupContext("getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep (wrapper)", 0);
6410  {
6411  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_elementBoundaryElementsArray,&__pyx_n_s_exteriorElementBoundariesArray,&__pyx_n_s_ebqe_v,&__pyx_n_s_p1_vdofs,&__pyx_n_s_ebqe_velocity,0};
6412  PyObject* values[5] = {0,0,0,0,0};
6413  if (unlikely(__pyx_kwds)) {
6414  Py_ssize_t kw_args;
6415  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
6416  switch (pos_args) {
6417  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
6418  CYTHON_FALLTHROUGH;
6419  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
6420  CYTHON_FALLTHROUGH;
6421  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
6422  CYTHON_FALLTHROUGH;
6423  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
6424  CYTHON_FALLTHROUGH;
6425  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
6426  CYTHON_FALLTHROUGH;
6427  case 0: break;
6428  default: goto __pyx_L5_argtuple_error;
6429  }
6430  kw_args = PyDict_Size(__pyx_kwds);
6431  switch (pos_args) {
6432  case 0:
6433  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryElementsArray)) != 0)) kw_args--;
6434  else goto __pyx_L5_argtuple_error;
6435  CYTHON_FALLTHROUGH;
6436  case 1:
6437  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_exteriorElementBoundariesArray)) != 0)) kw_args--;
6438  else {
6439  __Pyx_RaiseArgtupleInvalid("getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep", 1, 5, 5, 1); __PYX_ERR(0, 508, __pyx_L3_error)
6440  }
6441  CYTHON_FALLTHROUGH;
6442  case 2:
6443  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ebqe_v)) != 0)) kw_args--;
6444  else {
6445  __Pyx_RaiseArgtupleInvalid("getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep", 1, 5, 5, 2); __PYX_ERR(0, 508, __pyx_L3_error)
6446  }
6447  CYTHON_FALLTHROUGH;
6448  case 3:
6449  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_p1_vdofs)) != 0)) kw_args--;
6450  else {
6451  __Pyx_RaiseArgtupleInvalid("getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep", 1, 5, 5, 3); __PYX_ERR(0, 508, __pyx_L3_error)
6452  }
6453  CYTHON_FALLTHROUGH;
6454  case 4:
6455  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ebqe_velocity)) != 0)) kw_args--;
6456  else {
6457  __Pyx_RaiseArgtupleInvalid("getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep", 1, 5, 5, 4); __PYX_ERR(0, 508, __pyx_L3_error)
6458  }
6459  }
6460  if (unlikely(kw_args > 0)) {
6461  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep") < 0)) __PYX_ERR(0, 508, __pyx_L3_error)
6462  }
6463  } else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
6464  goto __pyx_L5_argtuple_error;
6465  } else {
6466  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
6467  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
6468  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
6469  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
6470  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
6471  }
6472  __pyx_v_elementBoundaryElementsArray = ((PyArrayObject *)values[0]);
6473  __pyx_v_exteriorElementBoundariesArray = ((PyArrayObject *)values[1]);
6474  __pyx_v_ebqe_v = ((PyArrayObject *)values[2]);
6475  __pyx_v_p1_vdofs = ((PyArrayObject *)values[3]);
6476  __pyx_v_ebqe_velocity = ((PyArrayObject *)values[4]);
6477  }
6478  goto __pyx_L4_argument_unpacking_done;
6479  __pyx_L5_argtuple_error:;
6480  __Pyx_RaiseArgtupleInvalid("getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 508, __pyx_L3_error)
6481  __pyx_L3_error:;
6482  __Pyx_AddTraceback("cpostprocessing.getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep", __pyx_clineno, __pyx_lineno, __pyx_filename);
6483  __Pyx_RefNannyFinishContext();
6484  return NULL;
6485  __pyx_L4_argument_unpacking_done:;
6486  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryElementsArray), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryElementsArray", 0))) __PYX_ERR(0, 508, __pyx_L1_error)
6487  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_exteriorElementBoundariesArray), __pyx_ptype_5numpy_ndarray, 1, "exteriorElementBoundariesArray", 0))) __PYX_ERR(0, 509, __pyx_L1_error)
6488  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ebqe_v), __pyx_ptype_5numpy_ndarray, 1, "ebqe_v", 0))) __PYX_ERR(0, 510, __pyx_L1_error)
6489  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_p1_vdofs), __pyx_ptype_5numpy_ndarray, 1, "p1_vdofs", 0))) __PYX_ERR(0, 511, __pyx_L1_error)
6490  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ebqe_velocity), __pyx_ptype_5numpy_ndarray, 1, "ebqe_velocity", 0))) __PYX_ERR(0, 512, __pyx_L1_error)
6491  __pyx_r = __pyx_pf_15cpostprocessing_42getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep(__pyx_self, __pyx_v_elementBoundaryElementsArray, __pyx_v_exteriorElementBoundariesArray, __pyx_v_ebqe_v, __pyx_v_p1_vdofs, __pyx_v_ebqe_velocity);
6492 
6493  /* function exit code */
6494  goto __pyx_L0;
6495  __pyx_L1_error:;
6496  __pyx_r = NULL;
6497  __pyx_L0:;
6498  __Pyx_RefNannyFinishContext();
6499  return __pyx_r;
6500 }
6501 
6502 static PyObject *__pyx_pf_15cpostprocessing_42getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_elementBoundaryElementsArray, PyArrayObject *__pyx_v_exteriorElementBoundariesArray, PyArrayObject *__pyx_v_ebqe_v, PyArrayObject *__pyx_v_p1_vdofs, PyArrayObject *__pyx_v_ebqe_velocity) {
6503  int __pyx_v_nVDOFs_element;
6504  PyObject *__pyx_r = NULL;
6505  __Pyx_RefNannyDeclarations
6506  int __pyx_t_1;
6507  int __pyx_lineno = 0;
6508  const char *__pyx_filename = NULL;
6509  int __pyx_clineno = 0;
6510  __Pyx_RefNannySetupContext("getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep", 0);
6511 
6512  /* "cpostprocessing.pyx":513
6513  * np.ndarray p1_vdofs,
6514  * np.ndarray ebqe_velocity):
6515  * cdef int nVDOFs_element = ebqe_velocity.shape[2]*(ebqe_velocity.shape[2]+1) # <<<<<<<<<<<<<<
6516  * if p1_vdofs.ndim > 1:
6517  * assert nVDOFs_element == p1_vdofs.shape[1]
6518  */
6519  __pyx_v_nVDOFs_element = ((__pyx_v_ebqe_velocity->dimensions[2]) * ((__pyx_v_ebqe_velocity->dimensions[2]) + 1));
6520 
6521  /* "cpostprocessing.pyx":514
6522  * np.ndarray ebqe_velocity):
6523  * cdef int nVDOFs_element = ebqe_velocity.shape[2]*(ebqe_velocity.shape[2]+1)
6524  * if p1_vdofs.ndim > 1: # <<<<<<<<<<<<<<
6525  * assert nVDOFs_element == p1_vdofs.shape[1]
6526  * pp.getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep(ebqe_velocity.shape[0],
6527  */
6528  __pyx_t_1 = ((__pyx_v_p1_vdofs->nd > 1) != 0);
6529  if (__pyx_t_1) {
6530 
6531  /* "cpostprocessing.pyx":515
6532  * cdef int nVDOFs_element = ebqe_velocity.shape[2]*(ebqe_velocity.shape[2]+1)
6533  * if p1_vdofs.ndim > 1:
6534  * assert nVDOFs_element == p1_vdofs.shape[1] # <<<<<<<<<<<<<<
6535  * pp.getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep(ebqe_velocity.shape[0],
6536  * ebqe_velocity.shape[1],
6537  */
6538  #ifndef CYTHON_WITHOUT_ASSERTIONS
6539  if (unlikely(!Py_OptimizeFlag)) {
6540  if (unlikely(!((__pyx_v_nVDOFs_element == (__pyx_v_p1_vdofs->dimensions[1])) != 0))) {
6541  PyErr_SetNone(PyExc_AssertionError);
6542  __PYX_ERR(0, 515, __pyx_L1_error)
6543  }
6544  }
6545  #endif
6546 
6547  /* "cpostprocessing.pyx":514
6548  * np.ndarray ebqe_velocity):
6549  * cdef int nVDOFs_element = ebqe_velocity.shape[2]*(ebqe_velocity.shape[2]+1)
6550  * if p1_vdofs.ndim > 1: # <<<<<<<<<<<<<<
6551  * assert nVDOFs_element == p1_vdofs.shape[1]
6552  * pp.getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep(ebqe_velocity.shape[0],
6553  */
6554  }
6555 
6556  /* "cpostprocessing.pyx":516
6557  * if p1_vdofs.ndim > 1:
6558  * assert nVDOFs_element == p1_vdofs.shape[1]
6559  * pp.getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep(ebqe_velocity.shape[0], # <<<<<<<<<<<<<<
6560  * ebqe_velocity.shape[1],
6561  * ebqe_velocity.shape[2],
6562  */
6563  getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep((__pyx_v_ebqe_velocity->dimensions[0]), (__pyx_v_ebqe_velocity->dimensions[1]), (__pyx_v_ebqe_velocity->dimensions[2]), (__pyx_v_ebqe_v->dimensions[2]), __pyx_v_nVDOFs_element, ((int *)__pyx_v_elementBoundaryElementsArray->data), ((int *)__pyx_v_exteriorElementBoundariesArray->data), ((double *)__pyx_v_ebqe_v->data), ((double *)__pyx_v_p1_vdofs->data), ((double *)__pyx_v_ebqe_velocity->data));
6564 
6565  /* "cpostprocessing.pyx":508
6566  * <double*>(q_velocity.data))
6567  *
6568  * def getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep(np.ndarray elementBoundaryElementsArray, # <<<<<<<<<<<<<<
6569  * np.ndarray exteriorElementBoundariesArray,
6570  * np.ndarray ebqe_v,
6571  */
6572 
6573  /* function exit code */
6574  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
6575  goto __pyx_L0;
6576  __pyx_L1_error:;
6577  __Pyx_AddTraceback("cpostprocessing.getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep", __pyx_clineno, __pyx_lineno, __pyx_filename);
6578  __pyx_r = NULL;
6579  __pyx_L0:;
6580  __Pyx_XGIVEREF(__pyx_r);
6581  __Pyx_RefNannyFinishContext();
6582  return __pyx_r;
6583 }
6584 
6585 /* "cpostprocessing.pyx":527
6586  * <double*>(ebqe_velocity.data))
6587  *
6588  * def getGlobalElementBoundaryBDM1velocityValuesLagrangeRep(np.ndarray elementBoundaryElementsArray, # <<<<<<<<<<<<<<
6589  * np.ndarray exteriorElementBoundariesArray,
6590  * np.ndarray ebqe_v,
6591  */
6592 
6593 /* Python wrapper */
6594 static PyObject *__pyx_pw_15cpostprocessing_45getGlobalElementBoundaryBDM1velocityValuesLagrangeRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
6595 static PyMethodDef __pyx_mdef_15cpostprocessing_45getGlobalElementBoundaryBDM1velocityValuesLagrangeRep = {"getGlobalElementBoundaryBDM1velocityValuesLagrangeRep", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_45getGlobalElementBoundaryBDM1velocityValuesLagrangeRep, METH_VARARGS|METH_KEYWORDS, 0};
6596 static PyObject *__pyx_pw_15cpostprocessing_45getGlobalElementBoundaryBDM1velocityValuesLagrangeRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
6597  PyArrayObject *__pyx_v_elementBoundaryElementsArray = 0;
6598  PyArrayObject *__pyx_v_exteriorElementBoundariesArray = 0;
6599  PyArrayObject *__pyx_v_ebqe_v = 0;
6600  PyArrayObject *__pyx_v_p1_vdofs = 0;
6601  PyArrayObject *__pyx_v_ebq_global_velocity = 0;
6602  int __pyx_lineno = 0;
6603  const char *__pyx_filename = NULL;
6604  int __pyx_clineno = 0;
6605  PyObject *__pyx_r = 0;
6606  __Pyx_RefNannyDeclarations
6607  __Pyx_RefNannySetupContext("getGlobalElementBoundaryBDM1velocityValuesLagrangeRep (wrapper)", 0);
6608  {
6609  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_elementBoundaryElementsArray,&__pyx_n_s_exteriorElementBoundariesArray,&__pyx_n_s_ebqe_v,&__pyx_n_s_p1_vdofs,&__pyx_n_s_ebq_global_velocity,0};
6610  PyObject* values[5] = {0,0,0,0,0};
6611  if (unlikely(__pyx_kwds)) {
6612  Py_ssize_t kw_args;
6613  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
6614  switch (pos_args) {
6615  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
6616  CYTHON_FALLTHROUGH;
6617  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
6618  CYTHON_FALLTHROUGH;
6619  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
6620  CYTHON_FALLTHROUGH;
6621  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
6622  CYTHON_FALLTHROUGH;
6623  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
6624  CYTHON_FALLTHROUGH;
6625  case 0: break;
6626  default: goto __pyx_L5_argtuple_error;
6627  }
6628  kw_args = PyDict_Size(__pyx_kwds);
6629  switch (pos_args) {
6630  case 0:
6631  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryElementsArray)) != 0)) kw_args--;
6632  else goto __pyx_L5_argtuple_error;
6633  CYTHON_FALLTHROUGH;
6634  case 1:
6635  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_exteriorElementBoundariesArray)) != 0)) kw_args--;
6636  else {
6637  __Pyx_RaiseArgtupleInvalid("getGlobalElementBoundaryBDM1velocityValuesLagrangeRep", 1, 5, 5, 1); __PYX_ERR(0, 527, __pyx_L3_error)
6638  }
6639  CYTHON_FALLTHROUGH;
6640  case 2:
6641  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ebqe_v)) != 0)) kw_args--;
6642  else {
6643  __Pyx_RaiseArgtupleInvalid("getGlobalElementBoundaryBDM1velocityValuesLagrangeRep", 1, 5, 5, 2); __PYX_ERR(0, 527, __pyx_L3_error)
6644  }
6645  CYTHON_FALLTHROUGH;
6646  case 3:
6647  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_p1_vdofs)) != 0)) kw_args--;
6648  else {
6649  __Pyx_RaiseArgtupleInvalid("getGlobalElementBoundaryBDM1velocityValuesLagrangeRep", 1, 5, 5, 3); __PYX_ERR(0, 527, __pyx_L3_error)
6650  }
6651  CYTHON_FALLTHROUGH;
6652  case 4:
6653  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ebq_global_velocity)) != 0)) kw_args--;
6654  else {
6655  __Pyx_RaiseArgtupleInvalid("getGlobalElementBoundaryBDM1velocityValuesLagrangeRep", 1, 5, 5, 4); __PYX_ERR(0, 527, __pyx_L3_error)
6656  }
6657  }
6658  if (unlikely(kw_args > 0)) {
6659  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "getGlobalElementBoundaryBDM1velocityValuesLagrangeRep") < 0)) __PYX_ERR(0, 527, __pyx_L3_error)
6660  }
6661  } else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
6662  goto __pyx_L5_argtuple_error;
6663  } else {
6664  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
6665  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
6666  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
6667  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
6668  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
6669  }
6670  __pyx_v_elementBoundaryElementsArray = ((PyArrayObject *)values[0]);
6671  __pyx_v_exteriorElementBoundariesArray = ((PyArrayObject *)values[1]);
6672  __pyx_v_ebqe_v = ((PyArrayObject *)values[2]);
6673  __pyx_v_p1_vdofs = ((PyArrayObject *)values[3]);
6674  __pyx_v_ebq_global_velocity = ((PyArrayObject *)values[4]);
6675  }
6676  goto __pyx_L4_argument_unpacking_done;
6677  __pyx_L5_argtuple_error:;
6678  __Pyx_RaiseArgtupleInvalid("getGlobalElementBoundaryBDM1velocityValuesLagrangeRep", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 527, __pyx_L3_error)
6679  __pyx_L3_error:;
6680  __Pyx_AddTraceback("cpostprocessing.getGlobalElementBoundaryBDM1velocityValuesLagrangeRep", __pyx_clineno, __pyx_lineno, __pyx_filename);
6681  __Pyx_RefNannyFinishContext();
6682  return NULL;
6683  __pyx_L4_argument_unpacking_done:;
6684  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryElementsArray), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryElementsArray", 0))) __PYX_ERR(0, 527, __pyx_L1_error)
6685  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_exteriorElementBoundariesArray), __pyx_ptype_5numpy_ndarray, 1, "exteriorElementBoundariesArray", 0))) __PYX_ERR(0, 528, __pyx_L1_error)
6686  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ebqe_v), __pyx_ptype_5numpy_ndarray, 1, "ebqe_v", 0))) __PYX_ERR(0, 529, __pyx_L1_error)
6687  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_p1_vdofs), __pyx_ptype_5numpy_ndarray, 1, "p1_vdofs", 0))) __PYX_ERR(0, 530, __pyx_L1_error)
6688  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ebq_global_velocity), __pyx_ptype_5numpy_ndarray, 1, "ebq_global_velocity", 0))) __PYX_ERR(0, 531, __pyx_L1_error)
6689  __pyx_r = __pyx_pf_15cpostprocessing_44getGlobalElementBoundaryBDM1velocityValuesLagrangeRep(__pyx_self, __pyx_v_elementBoundaryElementsArray, __pyx_v_exteriorElementBoundariesArray, __pyx_v_ebqe_v, __pyx_v_p1_vdofs, __pyx_v_ebq_global_velocity);
6690 
6691  /* function exit code */
6692  goto __pyx_L0;
6693  __pyx_L1_error:;
6694  __pyx_r = NULL;
6695  __pyx_L0:;
6696  __Pyx_RefNannyFinishContext();
6697  return __pyx_r;
6698 }
6699 
6700 static PyObject *__pyx_pf_15cpostprocessing_44getGlobalElementBoundaryBDM1velocityValuesLagrangeRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_elementBoundaryElementsArray, PyArrayObject *__pyx_v_exteriorElementBoundariesArray, PyArrayObject *__pyx_v_ebqe_v, PyArrayObject *__pyx_v_p1_vdofs, PyArrayObject *__pyx_v_ebq_global_velocity) {
6701  int __pyx_v_nVDOFs_element;
6702  PyObject *__pyx_r = NULL;
6703  __Pyx_RefNannyDeclarations
6704  int __pyx_t_1;
6705  int __pyx_lineno = 0;
6706  const char *__pyx_filename = NULL;
6707  int __pyx_clineno = 0;
6708  __Pyx_RefNannySetupContext("getGlobalElementBoundaryBDM1velocityValuesLagrangeRep", 0);
6709 
6710  /* "cpostprocessing.pyx":532
6711  * np.ndarray p1_vdofs,
6712  * np.ndarray ebq_global_velocity):
6713  * cdef int nVDOFs_element = ebq_global_velocity.shape[2]*(ebq_global_velocity.shape[2]+1) # <<<<<<<<<<<<<<
6714  * if p1_vdofs.ndim > 1:
6715  * assert nVDOFs_element == p1_vdofs.shape[1]
6716  */
6717  __pyx_v_nVDOFs_element = ((__pyx_v_ebq_global_velocity->dimensions[2]) * ((__pyx_v_ebq_global_velocity->dimensions[2]) + 1));
6718 
6719  /* "cpostprocessing.pyx":533
6720  * np.ndarray ebq_global_velocity):
6721  * cdef int nVDOFs_element = ebq_global_velocity.shape[2]*(ebq_global_velocity.shape[2]+1)
6722  * if p1_vdofs.ndim > 1: # <<<<<<<<<<<<<<
6723  * assert nVDOFs_element == p1_vdofs.shape[1]
6724  * pp.getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep(ebqe_v.shape[0],
6725  */
6726  __pyx_t_1 = ((__pyx_v_p1_vdofs->nd > 1) != 0);
6727  if (__pyx_t_1) {
6728 
6729  /* "cpostprocessing.pyx":534
6730  * cdef int nVDOFs_element = ebq_global_velocity.shape[2]*(ebq_global_velocity.shape[2]+1)
6731  * if p1_vdofs.ndim > 1:
6732  * assert nVDOFs_element == p1_vdofs.shape[1] # <<<<<<<<<<<<<<
6733  * pp.getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep(ebqe_v.shape[0],
6734  * ebq_global_velocity.shape[1],
6735  */
6736  #ifndef CYTHON_WITHOUT_ASSERTIONS
6737  if (unlikely(!Py_OptimizeFlag)) {
6738  if (unlikely(!((__pyx_v_nVDOFs_element == (__pyx_v_p1_vdofs->dimensions[1])) != 0))) {
6739  PyErr_SetNone(PyExc_AssertionError);
6740  __PYX_ERR(0, 534, __pyx_L1_error)
6741  }
6742  }
6743  #endif
6744 
6745  /* "cpostprocessing.pyx":533
6746  * np.ndarray ebq_global_velocity):
6747  * cdef int nVDOFs_element = ebq_global_velocity.shape[2]*(ebq_global_velocity.shape[2]+1)
6748  * if p1_vdofs.ndim > 1: # <<<<<<<<<<<<<<
6749  * assert nVDOFs_element == p1_vdofs.shape[1]
6750  * pp.getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep(ebqe_v.shape[0],
6751  */
6752  }
6753 
6754  /* "cpostprocessing.pyx":535
6755  * if p1_vdofs.ndim > 1:
6756  * assert nVDOFs_element == p1_vdofs.shape[1]
6757  * pp.getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep(ebqe_v.shape[0], # <<<<<<<<<<<<<<
6758  * ebq_global_velocity.shape[1],
6759  * ebq_global_velocity.shape[2],
6760  */
6761  getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep((__pyx_v_ebqe_v->dimensions[0]), (__pyx_v_ebq_global_velocity->dimensions[1]), (__pyx_v_ebq_global_velocity->dimensions[2]), (__pyx_v_ebqe_v->dimensions[2]), __pyx_v_nVDOFs_element, ((int *)__pyx_v_elementBoundaryElementsArray->data), ((int *)__pyx_v_exteriorElementBoundariesArray->data), ((double *)__pyx_v_ebqe_v->data), ((double *)__pyx_v_p1_vdofs->data), ((double *)__pyx_v_ebq_global_velocity->data));
6762 
6763  /* "cpostprocessing.pyx":527
6764  * <double*>(ebqe_velocity.data))
6765  *
6766  * def getGlobalElementBoundaryBDM1velocityValuesLagrangeRep(np.ndarray elementBoundaryElementsArray, # <<<<<<<<<<<<<<
6767  * np.ndarray exteriorElementBoundariesArray,
6768  * np.ndarray ebqe_v,
6769  */
6770 
6771  /* function exit code */
6772  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
6773  goto __pyx_L0;
6774  __pyx_L1_error:;
6775  __Pyx_AddTraceback("cpostprocessing.getGlobalElementBoundaryBDM1velocityValuesLagrangeRep", __pyx_clineno, __pyx_lineno, __pyx_filename);
6776  __pyx_r = NULL;
6777  __pyx_L0:;
6778  __Pyx_XGIVEREF(__pyx_r);
6779  __Pyx_RefNannyFinishContext();
6780  return __pyx_r;
6781 }
6782 
6783 /* "cpostprocessing.pyx":546
6784  * <double*>(ebq_global_velocity.data))
6785  *
6786  * def getElementBoundaryBDM1velocityValuesLagrangeRep(np.ndarray elementBoundaryElementsArray, # <<<<<<<<<<<<<<
6787  * np.ndarray exteriorElementBoundariesArray,
6788  * np.ndarray ebq_v,
6789  */
6790 
6791 /* Python wrapper */
6792 static PyObject *__pyx_pw_15cpostprocessing_47getElementBoundaryBDM1velocityValuesLagrangeRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
6793 static PyMethodDef __pyx_mdef_15cpostprocessing_47getElementBoundaryBDM1velocityValuesLagrangeRep = {"getElementBoundaryBDM1velocityValuesLagrangeRep", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_47getElementBoundaryBDM1velocityValuesLagrangeRep, METH_VARARGS|METH_KEYWORDS, 0};
6794 static PyObject *__pyx_pw_15cpostprocessing_47getElementBoundaryBDM1velocityValuesLagrangeRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
6795  PyArrayObject *__pyx_v_elementBoundaryElementsArray = 0;
6796  PyArrayObject *__pyx_v_exteriorElementBoundariesArray = 0;
6797  PyArrayObject *__pyx_v_ebq_v = 0;
6798  PyArrayObject *__pyx_v_p1_vdofs = 0;
6799  PyArrayObject *__pyx_v_ebq_velocity = 0;
6800  int __pyx_lineno = 0;
6801  const char *__pyx_filename = NULL;
6802  int __pyx_clineno = 0;
6803  PyObject *__pyx_r = 0;
6804  __Pyx_RefNannyDeclarations
6805  __Pyx_RefNannySetupContext("getElementBoundaryBDM1velocityValuesLagrangeRep (wrapper)", 0);
6806  {
6807  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_elementBoundaryElementsArray,&__pyx_n_s_exteriorElementBoundariesArray,&__pyx_n_s_ebq_v,&__pyx_n_s_p1_vdofs,&__pyx_n_s_ebq_velocity,0};
6808  PyObject* values[5] = {0,0,0,0,0};
6809  if (unlikely(__pyx_kwds)) {
6810  Py_ssize_t kw_args;
6811  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
6812  switch (pos_args) {
6813  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
6814  CYTHON_FALLTHROUGH;
6815  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
6816  CYTHON_FALLTHROUGH;
6817  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
6818  CYTHON_FALLTHROUGH;
6819  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
6820  CYTHON_FALLTHROUGH;
6821  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
6822  CYTHON_FALLTHROUGH;
6823  case 0: break;
6824  default: goto __pyx_L5_argtuple_error;
6825  }
6826  kw_args = PyDict_Size(__pyx_kwds);
6827  switch (pos_args) {
6828  case 0:
6829  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryElementsArray)) != 0)) kw_args--;
6830  else goto __pyx_L5_argtuple_error;
6831  CYTHON_FALLTHROUGH;
6832  case 1:
6833  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_exteriorElementBoundariesArray)) != 0)) kw_args--;
6834  else {
6835  __Pyx_RaiseArgtupleInvalid("getElementBoundaryBDM1velocityValuesLagrangeRep", 1, 5, 5, 1); __PYX_ERR(0, 546, __pyx_L3_error)
6836  }
6837  CYTHON_FALLTHROUGH;
6838  case 2:
6839  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ebq_v)) != 0)) kw_args--;
6840  else {
6841  __Pyx_RaiseArgtupleInvalid("getElementBoundaryBDM1velocityValuesLagrangeRep", 1, 5, 5, 2); __PYX_ERR(0, 546, __pyx_L3_error)
6842  }
6843  CYTHON_FALLTHROUGH;
6844  case 3:
6845  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_p1_vdofs)) != 0)) kw_args--;
6846  else {
6847  __Pyx_RaiseArgtupleInvalid("getElementBoundaryBDM1velocityValuesLagrangeRep", 1, 5, 5, 3); __PYX_ERR(0, 546, __pyx_L3_error)
6848  }
6849  CYTHON_FALLTHROUGH;
6850  case 4:
6851  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ebq_velocity)) != 0)) kw_args--;
6852  else {
6853  __Pyx_RaiseArgtupleInvalid("getElementBoundaryBDM1velocityValuesLagrangeRep", 1, 5, 5, 4); __PYX_ERR(0, 546, __pyx_L3_error)
6854  }
6855  }
6856  if (unlikely(kw_args > 0)) {
6857  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "getElementBoundaryBDM1velocityValuesLagrangeRep") < 0)) __PYX_ERR(0, 546, __pyx_L3_error)
6858  }
6859  } else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
6860  goto __pyx_L5_argtuple_error;
6861  } else {
6862  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
6863  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
6864  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
6865  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
6866  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
6867  }
6868  __pyx_v_elementBoundaryElementsArray = ((PyArrayObject *)values[0]);
6869  __pyx_v_exteriorElementBoundariesArray = ((PyArrayObject *)values[1]);
6870  __pyx_v_ebq_v = ((PyArrayObject *)values[2]);
6871  __pyx_v_p1_vdofs = ((PyArrayObject *)values[3]);
6872  __pyx_v_ebq_velocity = ((PyArrayObject *)values[4]);
6873  }
6874  goto __pyx_L4_argument_unpacking_done;
6875  __pyx_L5_argtuple_error:;
6876  __Pyx_RaiseArgtupleInvalid("getElementBoundaryBDM1velocityValuesLagrangeRep", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 546, __pyx_L3_error)
6877  __pyx_L3_error:;
6878  __Pyx_AddTraceback("cpostprocessing.getElementBoundaryBDM1velocityValuesLagrangeRep", __pyx_clineno, __pyx_lineno, __pyx_filename);
6879  __Pyx_RefNannyFinishContext();
6880  return NULL;
6881  __pyx_L4_argument_unpacking_done:;
6882  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryElementsArray), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryElementsArray", 0))) __PYX_ERR(0, 546, __pyx_L1_error)
6883  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_exteriorElementBoundariesArray), __pyx_ptype_5numpy_ndarray, 1, "exteriorElementBoundariesArray", 0))) __PYX_ERR(0, 547, __pyx_L1_error)
6884  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ebq_v), __pyx_ptype_5numpy_ndarray, 1, "ebq_v", 0))) __PYX_ERR(0, 548, __pyx_L1_error)
6885  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_p1_vdofs), __pyx_ptype_5numpy_ndarray, 1, "p1_vdofs", 0))) __PYX_ERR(0, 549, __pyx_L1_error)
6886  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ebq_velocity), __pyx_ptype_5numpy_ndarray, 1, "ebq_velocity", 0))) __PYX_ERR(0, 550, __pyx_L1_error)
6887  __pyx_r = __pyx_pf_15cpostprocessing_46getElementBoundaryBDM1velocityValuesLagrangeRep(__pyx_self, __pyx_v_elementBoundaryElementsArray, __pyx_v_exteriorElementBoundariesArray, __pyx_v_ebq_v, __pyx_v_p1_vdofs, __pyx_v_ebq_velocity);
6888 
6889  /* function exit code */
6890  goto __pyx_L0;
6891  __pyx_L1_error:;
6892  __pyx_r = NULL;
6893  __pyx_L0:;
6894  __Pyx_RefNannyFinishContext();
6895  return __pyx_r;
6896 }
6897 
6898 static PyObject *__pyx_pf_15cpostprocessing_46getElementBoundaryBDM1velocityValuesLagrangeRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_elementBoundaryElementsArray, PyArrayObject *__pyx_v_exteriorElementBoundariesArray, PyArrayObject *__pyx_v_ebq_v, PyArrayObject *__pyx_v_p1_vdofs, PyArrayObject *__pyx_v_ebq_velocity) {
6899  int __pyx_v_nVDOFs_element;
6900  PyObject *__pyx_r = NULL;
6901  __Pyx_RefNannyDeclarations
6902  int __pyx_t_1;
6903  int __pyx_lineno = 0;
6904  const char *__pyx_filename = NULL;
6905  int __pyx_clineno = 0;
6906  __Pyx_RefNannySetupContext("getElementBoundaryBDM1velocityValuesLagrangeRep", 0);
6907 
6908  /* "cpostprocessing.pyx":551
6909  * np.ndarray p1_vdofs,
6910  * np.ndarray ebq_velocity):
6911  * cdef int nVDOFs_element = ebq_velocity.shape[3]*(ebq_velocity.shape[3]+1) # <<<<<<<<<<<<<<
6912  * if p1_vdofs.ndim > 1:
6913  * assert nVDOFs_element == p1_vdofs.shape[1]
6914  */
6915  __pyx_v_nVDOFs_element = ((__pyx_v_ebq_velocity->dimensions[3]) * ((__pyx_v_ebq_velocity->dimensions[3]) + 1));
6916 
6917  /* "cpostprocessing.pyx":552
6918  * np.ndarray ebq_velocity):
6919  * cdef int nVDOFs_element = ebq_velocity.shape[3]*(ebq_velocity.shape[3]+1)
6920  * if p1_vdofs.ndim > 1: # <<<<<<<<<<<<<<
6921  * assert nVDOFs_element == p1_vdofs.shape[1]
6922  * pp.getElementBoundaryBDM1velocityValuesLagrangeRep(ebq_velocity.shape[0],
6923  */
6924  __pyx_t_1 = ((__pyx_v_p1_vdofs->nd > 1) != 0);
6925  if (__pyx_t_1) {
6926 
6927  /* "cpostprocessing.pyx":553
6928  * cdef int nVDOFs_element = ebq_velocity.shape[3]*(ebq_velocity.shape[3]+1)
6929  * if p1_vdofs.ndim > 1:
6930  * assert nVDOFs_element == p1_vdofs.shape[1] # <<<<<<<<<<<<<<
6931  * pp.getElementBoundaryBDM1velocityValuesLagrangeRep(ebq_velocity.shape[0],
6932  * ebq_velocity.shape[1],
6933  */
6934  #ifndef CYTHON_WITHOUT_ASSERTIONS
6935  if (unlikely(!Py_OptimizeFlag)) {
6936  if (unlikely(!((__pyx_v_nVDOFs_element == (__pyx_v_p1_vdofs->dimensions[1])) != 0))) {
6937  PyErr_SetNone(PyExc_AssertionError);
6938  __PYX_ERR(0, 553, __pyx_L1_error)
6939  }
6940  }
6941  #endif
6942 
6943  /* "cpostprocessing.pyx":554
6944  * if p1_vdofs.ndim > 1:
6945  * assert nVDOFs_element == p1_vdofs.shape[1]
6946  * pp.getElementBoundaryBDM1velocityValuesLagrangeRep(ebq_velocity.shape[0], # <<<<<<<<<<<<<<
6947  * ebq_velocity.shape[1],
6948  * ebq_velocity.shape[2],
6949  */
6950  getElementBoundaryBDM1velocityValuesLagrangeRep((__pyx_v_ebq_velocity->dimensions[0]), (__pyx_v_ebq_velocity->dimensions[1]), (__pyx_v_ebq_velocity->dimensions[2]), (__pyx_v_ebq_velocity->dimensions[3]), (__pyx_v_ebq_v->dimensions[2]), __pyx_v_nVDOFs_element, ((int *)__pyx_v_elementBoundaryElementsArray->data), ((int *)__pyx_v_exteriorElementBoundariesArray->data), ((double *)__pyx_v_ebq_v->data), ((double *)__pyx_v_p1_vdofs->data), ((double *)__pyx_v_ebq_velocity->data));
6951 
6952  /* "cpostprocessing.pyx":552
6953  * np.ndarray ebq_velocity):
6954  * cdef int nVDOFs_element = ebq_velocity.shape[3]*(ebq_velocity.shape[3]+1)
6955  * if p1_vdofs.ndim > 1: # <<<<<<<<<<<<<<
6956  * assert nVDOFs_element == p1_vdofs.shape[1]
6957  * pp.getElementBoundaryBDM1velocityValuesLagrangeRep(ebq_velocity.shape[0],
6958  */
6959  }
6960 
6961  /* "cpostprocessing.pyx":546
6962  * <double*>(ebq_global_velocity.data))
6963  *
6964  * def getElementBoundaryBDM1velocityValuesLagrangeRep(np.ndarray elementBoundaryElementsArray, # <<<<<<<<<<<<<<
6965  * np.ndarray exteriorElementBoundariesArray,
6966  * np.ndarray ebq_v,
6967  */
6968 
6969  /* function exit code */
6970  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
6971  goto __pyx_L0;
6972  __pyx_L1_error:;
6973  __Pyx_AddTraceback("cpostprocessing.getElementBoundaryBDM1velocityValuesLagrangeRep", __pyx_clineno, __pyx_lineno, __pyx_filename);
6974  __pyx_r = NULL;
6975  __pyx_L0:;
6976  __Pyx_XGIVEREF(__pyx_r);
6977  __Pyx_RefNannyFinishContext();
6978  return __pyx_r;
6979 }
6980 
6981 /* "cpostprocessing.pyx":566
6982  * <double*>(ebq_velocity.data))
6983  *
6984  * def projectElementBoundaryVelocityToRT0fluxRep(np.ndarray elementBoundaryQuadratureWeights, # <<<<<<<<<<<<<<
6985  * np.ndarray n,
6986  * np.ndarray v_elementBoundary,
6987  */
6988 
6989 /* Python wrapper */
6990 static PyObject *__pyx_pw_15cpostprocessing_49projectElementBoundaryVelocityToRT0fluxRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
6991 static PyMethodDef __pyx_mdef_15cpostprocessing_49projectElementBoundaryVelocityToRT0fluxRep = {"projectElementBoundaryVelocityToRT0fluxRep", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_49projectElementBoundaryVelocityToRT0fluxRep, METH_VARARGS|METH_KEYWORDS, 0};
6992 static PyObject *__pyx_pw_15cpostprocessing_49projectElementBoundaryVelocityToRT0fluxRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
6993  PyArrayObject *__pyx_v_elementBoundaryQuadratureWeights = 0;
6994  PyArrayObject *__pyx_v_n = 0;
6995  PyArrayObject *__pyx_v_v_elementBoundary = 0;
6996  PyArrayObject *__pyx_v_rt0vdofs_element = 0;
6997  int __pyx_lineno = 0;
6998  const char *__pyx_filename = NULL;
6999  int __pyx_clineno = 0;
7000  PyObject *__pyx_r = 0;
7001  __Pyx_RefNannyDeclarations
7002  __Pyx_RefNannySetupContext("projectElementBoundaryVelocityToRT0fluxRep (wrapper)", 0);
7003  {
7004  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_elementBoundaryQuadratureWeights,&__pyx_n_s_n,&__pyx_n_s_v_elementBoundary,&__pyx_n_s_rt0vdofs_element,0};
7005  PyObject* values[4] = {0,0,0,0};
7006  if (unlikely(__pyx_kwds)) {
7007  Py_ssize_t kw_args;
7008  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
7009  switch (pos_args) {
7010  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
7011  CYTHON_FALLTHROUGH;
7012  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
7013  CYTHON_FALLTHROUGH;
7014  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
7015  CYTHON_FALLTHROUGH;
7016  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
7017  CYTHON_FALLTHROUGH;
7018  case 0: break;
7019  default: goto __pyx_L5_argtuple_error;
7020  }
7021  kw_args = PyDict_Size(__pyx_kwds);
7022  switch (pos_args) {
7023  case 0:
7024  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryQuadratureWeights)) != 0)) kw_args--;
7025  else goto __pyx_L5_argtuple_error;
7026  CYTHON_FALLTHROUGH;
7027  case 1:
7028  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_n)) != 0)) kw_args--;
7029  else {
7030  __Pyx_RaiseArgtupleInvalid("projectElementBoundaryVelocityToRT0fluxRep", 1, 4, 4, 1); __PYX_ERR(0, 566, __pyx_L3_error)
7031  }
7032  CYTHON_FALLTHROUGH;
7033  case 2:
7034  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_v_elementBoundary)) != 0)) kw_args--;
7035  else {
7036  __Pyx_RaiseArgtupleInvalid("projectElementBoundaryVelocityToRT0fluxRep", 1, 4, 4, 2); __PYX_ERR(0, 566, __pyx_L3_error)
7037  }
7038  CYTHON_FALLTHROUGH;
7039  case 3:
7040  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rt0vdofs_element)) != 0)) kw_args--;
7041  else {
7042  __Pyx_RaiseArgtupleInvalid("projectElementBoundaryVelocityToRT0fluxRep", 1, 4, 4, 3); __PYX_ERR(0, 566, __pyx_L3_error)
7043  }
7044  }
7045  if (unlikely(kw_args > 0)) {
7046  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "projectElementBoundaryVelocityToRT0fluxRep") < 0)) __PYX_ERR(0, 566, __pyx_L3_error)
7047  }
7048  } else if (PyTuple_GET_SIZE(__pyx_args) != 4) {
7049  goto __pyx_L5_argtuple_error;
7050  } else {
7051  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
7052  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
7053  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
7054  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
7055  }
7056  __pyx_v_elementBoundaryQuadratureWeights = ((PyArrayObject *)values[0]);
7057  __pyx_v_n = ((PyArrayObject *)values[1]);
7058  __pyx_v_v_elementBoundary = ((PyArrayObject *)values[2]);
7059  __pyx_v_rt0vdofs_element = ((PyArrayObject *)values[3]);
7060  }
7061  goto __pyx_L4_argument_unpacking_done;
7062  __pyx_L5_argtuple_error:;
7063  __Pyx_RaiseArgtupleInvalid("projectElementBoundaryVelocityToRT0fluxRep", 1, 4, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 566, __pyx_L3_error)
7064  __pyx_L3_error:;
7065  __Pyx_AddTraceback("cpostprocessing.projectElementBoundaryVelocityToRT0fluxRep", __pyx_clineno, __pyx_lineno, __pyx_filename);
7066  __Pyx_RefNannyFinishContext();
7067  return NULL;
7068  __pyx_L4_argument_unpacking_done:;
7069  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryQuadratureWeights), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryQuadratureWeights", 0))) __PYX_ERR(0, 566, __pyx_L1_error)
7070  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_n), __pyx_ptype_5numpy_ndarray, 1, "n", 0))) __PYX_ERR(0, 567, __pyx_L1_error)
7071  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_v_elementBoundary), __pyx_ptype_5numpy_ndarray, 1, "v_elementBoundary", 0))) __PYX_ERR(0, 568, __pyx_L1_error)
7072  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rt0vdofs_element), __pyx_ptype_5numpy_ndarray, 1, "rt0vdofs_element", 0))) __PYX_ERR(0, 569, __pyx_L1_error)
7073  __pyx_r = __pyx_pf_15cpostprocessing_48projectElementBoundaryVelocityToRT0fluxRep(__pyx_self, __pyx_v_elementBoundaryQuadratureWeights, __pyx_v_n, __pyx_v_v_elementBoundary, __pyx_v_rt0vdofs_element);
7074 
7075  /* function exit code */
7076  goto __pyx_L0;
7077  __pyx_L1_error:;
7078  __pyx_r = NULL;
7079  __pyx_L0:;
7080  __Pyx_RefNannyFinishContext();
7081  return __pyx_r;
7082 }
7083 
7084 static PyObject *__pyx_pf_15cpostprocessing_48projectElementBoundaryVelocityToRT0fluxRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_elementBoundaryQuadratureWeights, PyArrayObject *__pyx_v_n, PyArrayObject *__pyx_v_v_elementBoundary, PyArrayObject *__pyx_v_rt0vdofs_element) {
7085  PyObject *__pyx_r = NULL;
7086  __Pyx_RefNannyDeclarations
7087  __Pyx_RefNannySetupContext("projectElementBoundaryVelocityToRT0fluxRep", 0);
7088 
7089  /* "cpostprocessing.pyx":570
7090  * np.ndarray v_elementBoundary,
7091  * np.ndarray rt0vdofs_element):
7092  * pp.projectElementBoundaryVelocityToRT0fluxRep(n.shape[0], # <<<<<<<<<<<<<<
7093  * n.shape[1],
7094  * n.shape[2],
7095  */
7096  projectElementBoundaryVelocityToRT0fluxRep((__pyx_v_n->dimensions[0]), (__pyx_v_n->dimensions[1]), (__pyx_v_n->dimensions[2]), (__pyx_v_n->dimensions[3]), ((double *)__pyx_v_elementBoundaryQuadratureWeights->data), ((double *)__pyx_v_n->data), ((double *)__pyx_v_v_elementBoundary->data), ((double *)__pyx_v_rt0vdofs_element->data));
7097 
7098  /* "cpostprocessing.pyx":566
7099  * <double*>(ebq_velocity.data))
7100  *
7101  * def projectElementBoundaryVelocityToRT0fluxRep(np.ndarray elementBoundaryQuadratureWeights, # <<<<<<<<<<<<<<
7102  * np.ndarray n,
7103  * np.ndarray v_elementBoundary,
7104  */
7105 
7106  /* function exit code */
7107  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
7108  __Pyx_XGIVEREF(__pyx_r);
7109  __Pyx_RefNannyFinishContext();
7110  return __pyx_r;
7111 }
7112 
7113 /* "cpostprocessing.pyx":579
7114  * <double*>(rt0vdofs_element.data))
7115  *
7116  * def projectElementBoundaryFluxToRT0fluxRep(np.ndarray elementBoundaryElementsArray, # <<<<<<<<<<<<<<
7117  * np.ndarray elementBoundariesArray,
7118  * np.ndarray elementBoundaryQuadratureWeights,
7119  */
7120 
7121 /* Python wrapper */
7122 static PyObject *__pyx_pw_15cpostprocessing_51projectElementBoundaryFluxToRT0fluxRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
7123 static PyMethodDef __pyx_mdef_15cpostprocessing_51projectElementBoundaryFluxToRT0fluxRep = {"projectElementBoundaryFluxToRT0fluxRep", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_51projectElementBoundaryFluxToRT0fluxRep, METH_VARARGS|METH_KEYWORDS, 0};
7124 static PyObject *__pyx_pw_15cpostprocessing_51projectElementBoundaryFluxToRT0fluxRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
7125  PyArrayObject *__pyx_v_elementBoundaryElementsArray = 0;
7126  PyArrayObject *__pyx_v_elementBoundariesArray = 0;
7127  PyArrayObject *__pyx_v_elementBoundaryQuadratureWeights = 0;
7128  PyArrayObject *__pyx_v_flux_elementBoundary = 0;
7129  PyArrayObject *__pyx_v_rt0vdofs_element = 0;
7130  int __pyx_lineno = 0;
7131  const char *__pyx_filename = NULL;
7132  int __pyx_clineno = 0;
7133  PyObject *__pyx_r = 0;
7134  __Pyx_RefNannyDeclarations
7135  __Pyx_RefNannySetupContext("projectElementBoundaryFluxToRT0fluxRep (wrapper)", 0);
7136  {
7137  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_elementBoundaryElementsArray,&__pyx_n_s_elementBoundariesArray,&__pyx_n_s_elementBoundaryQuadratureWeights,&__pyx_n_s_flux_elementBoundary,&__pyx_n_s_rt0vdofs_element,0};
7138  PyObject* values[5] = {0,0,0,0,0};
7139  if (unlikely(__pyx_kwds)) {
7140  Py_ssize_t kw_args;
7141  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
7142  switch (pos_args) {
7143  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
7144  CYTHON_FALLTHROUGH;
7145  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
7146  CYTHON_FALLTHROUGH;
7147  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
7148  CYTHON_FALLTHROUGH;
7149  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
7150  CYTHON_FALLTHROUGH;
7151  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
7152  CYTHON_FALLTHROUGH;
7153  case 0: break;
7154  default: goto __pyx_L5_argtuple_error;
7155  }
7156  kw_args = PyDict_Size(__pyx_kwds);
7157  switch (pos_args) {
7158  case 0:
7159  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryElementsArray)) != 0)) kw_args--;
7160  else goto __pyx_L5_argtuple_error;
7161  CYTHON_FALLTHROUGH;
7162  case 1:
7163  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundariesArray)) != 0)) kw_args--;
7164  else {
7165  __Pyx_RaiseArgtupleInvalid("projectElementBoundaryFluxToRT0fluxRep", 1, 5, 5, 1); __PYX_ERR(0, 579, __pyx_L3_error)
7166  }
7167  CYTHON_FALLTHROUGH;
7168  case 2:
7169  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryQuadratureWeights)) != 0)) kw_args--;
7170  else {
7171  __Pyx_RaiseArgtupleInvalid("projectElementBoundaryFluxToRT0fluxRep", 1, 5, 5, 2); __PYX_ERR(0, 579, __pyx_L3_error)
7172  }
7173  CYTHON_FALLTHROUGH;
7174  case 3:
7175  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_flux_elementBoundary)) != 0)) kw_args--;
7176  else {
7177  __Pyx_RaiseArgtupleInvalid("projectElementBoundaryFluxToRT0fluxRep", 1, 5, 5, 3); __PYX_ERR(0, 579, __pyx_L3_error)
7178  }
7179  CYTHON_FALLTHROUGH;
7180  case 4:
7181  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rt0vdofs_element)) != 0)) kw_args--;
7182  else {
7183  __Pyx_RaiseArgtupleInvalid("projectElementBoundaryFluxToRT0fluxRep", 1, 5, 5, 4); __PYX_ERR(0, 579, __pyx_L3_error)
7184  }
7185  }
7186  if (unlikely(kw_args > 0)) {
7187  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "projectElementBoundaryFluxToRT0fluxRep") < 0)) __PYX_ERR(0, 579, __pyx_L3_error)
7188  }
7189  } else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
7190  goto __pyx_L5_argtuple_error;
7191  } else {
7192  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
7193  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
7194  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
7195  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
7196  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
7197  }
7198  __pyx_v_elementBoundaryElementsArray = ((PyArrayObject *)values[0]);
7199  __pyx_v_elementBoundariesArray = ((PyArrayObject *)values[1]);
7200  __pyx_v_elementBoundaryQuadratureWeights = ((PyArrayObject *)values[2]);
7201  __pyx_v_flux_elementBoundary = ((PyArrayObject *)values[3]);
7202  __pyx_v_rt0vdofs_element = ((PyArrayObject *)values[4]);
7203  }
7204  goto __pyx_L4_argument_unpacking_done;
7205  __pyx_L5_argtuple_error:;
7206  __Pyx_RaiseArgtupleInvalid("projectElementBoundaryFluxToRT0fluxRep", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 579, __pyx_L3_error)
7207  __pyx_L3_error:;
7208  __Pyx_AddTraceback("cpostprocessing.projectElementBoundaryFluxToRT0fluxRep", __pyx_clineno, __pyx_lineno, __pyx_filename);
7209  __Pyx_RefNannyFinishContext();
7210  return NULL;
7211  __pyx_L4_argument_unpacking_done:;
7212  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryElementsArray), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryElementsArray", 0))) __PYX_ERR(0, 579, __pyx_L1_error)
7213  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundariesArray), __pyx_ptype_5numpy_ndarray, 1, "elementBoundariesArray", 0))) __PYX_ERR(0, 580, __pyx_L1_error)
7214  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryQuadratureWeights), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryQuadratureWeights", 0))) __PYX_ERR(0, 581, __pyx_L1_error)
7215  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_flux_elementBoundary), __pyx_ptype_5numpy_ndarray, 1, "flux_elementBoundary", 0))) __PYX_ERR(0, 582, __pyx_L1_error)
7216  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rt0vdofs_element), __pyx_ptype_5numpy_ndarray, 1, "rt0vdofs_element", 0))) __PYX_ERR(0, 583, __pyx_L1_error)
7217  __pyx_r = __pyx_pf_15cpostprocessing_50projectElementBoundaryFluxToRT0fluxRep(__pyx_self, __pyx_v_elementBoundaryElementsArray, __pyx_v_elementBoundariesArray, __pyx_v_elementBoundaryQuadratureWeights, __pyx_v_flux_elementBoundary, __pyx_v_rt0vdofs_element);
7218 
7219  /* function exit code */
7220  goto __pyx_L0;
7221  __pyx_L1_error:;
7222  __pyx_r = NULL;
7223  __pyx_L0:;
7224  __Pyx_RefNannyFinishContext();
7225  return __pyx_r;
7226 }
7227 
7228 static PyObject *__pyx_pf_15cpostprocessing_50projectElementBoundaryFluxToRT0fluxRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_elementBoundaryElementsArray, PyArrayObject *__pyx_v_elementBoundariesArray, PyArrayObject *__pyx_v_elementBoundaryQuadratureWeights, PyArrayObject *__pyx_v_flux_elementBoundary, PyArrayObject *__pyx_v_rt0vdofs_element) {
7229  PyObject *__pyx_r = NULL;
7230  __Pyx_RefNannyDeclarations
7231  __Pyx_RefNannySetupContext("projectElementBoundaryFluxToRT0fluxRep", 0);
7232 
7233  /* "cpostprocessing.pyx":584
7234  * np.ndarray flux_elementBoundary,
7235  * np.ndarray rt0vdofs_element):
7236  * pp.projectElementBoundaryFluxToRT0fluxRep(elementBoundaryQuadratureWeights.shape[0], # <<<<<<<<<<<<<<
7237  * elementBoundaryQuadratureWeights.shape[1],
7238  * elementBoundaryQuadratureWeights.shape[2],
7239  */
7240  projectElementBoundaryFluxToRT0fluxRep((__pyx_v_elementBoundaryQuadratureWeights->dimensions[0]), (__pyx_v_elementBoundaryQuadratureWeights->dimensions[1]), (__pyx_v_elementBoundaryQuadratureWeights->dimensions[2]), (__pyx_v_rt0vdofs_element->dimensions[1]), ((int *)__pyx_v_elementBoundaryElementsArray->data), ((int *)__pyx_v_elementBoundariesArray->data), ((double *)__pyx_v_elementBoundaryQuadratureWeights->data), ((double *)__pyx_v_flux_elementBoundary->data), ((double *)__pyx_v_rt0vdofs_element->data));
7241 
7242  /* "cpostprocessing.pyx":579
7243  * <double*>(rt0vdofs_element.data))
7244  *
7245  * def projectElementBoundaryFluxToRT0fluxRep(np.ndarray elementBoundaryElementsArray, # <<<<<<<<<<<<<<
7246  * np.ndarray elementBoundariesArray,
7247  * np.ndarray elementBoundaryQuadratureWeights,
7248  */
7249 
7250  /* function exit code */
7251  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
7252  __Pyx_XGIVEREF(__pyx_r);
7253  __Pyx_RefNannyFinishContext();
7254  return __pyx_r;
7255 }
7256 
7257 /* "cpostprocessing.pyx":594
7258  * <double*>(rt0vdofs_element.data))
7259  *
7260  * def getElementRT0velocityValuesFluxRep(np.ndarray nodeArray, # <<<<<<<<<<<<<<
7261  * np.ndarray elementNodesArray,
7262  * np.ndarray abs_det_J,
7263  */
7264 
7265 /* Python wrapper */
7266 static PyObject *__pyx_pw_15cpostprocessing_53getElementRT0velocityValuesFluxRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
7267 static PyMethodDef __pyx_mdef_15cpostprocessing_53getElementRT0velocityValuesFluxRep = {"getElementRT0velocityValuesFluxRep", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_53getElementRT0velocityValuesFluxRep, METH_VARARGS|METH_KEYWORDS, 0};
7268 static PyObject *__pyx_pw_15cpostprocessing_53getElementRT0velocityValuesFluxRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
7269  PyArrayObject *__pyx_v_nodeArray = 0;
7270  PyArrayObject *__pyx_v_elementNodesArray = 0;
7271  PyArrayObject *__pyx_v_abs_det_J = 0;
7272  PyArrayObject *__pyx_v_x_element = 0;
7273  PyArrayObject *__pyx_v_rt0vdofs_element = 0;
7274  PyArrayObject *__pyx_v_v_element = 0;
7275  int __pyx_lineno = 0;
7276  const char *__pyx_filename = NULL;
7277  int __pyx_clineno = 0;
7278  PyObject *__pyx_r = 0;
7279  __Pyx_RefNannyDeclarations
7280  __Pyx_RefNannySetupContext("getElementRT0velocityValuesFluxRep (wrapper)", 0);
7281  {
7282  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_nodeArray,&__pyx_n_s_elementNodesArray,&__pyx_n_s_abs_det_J,&__pyx_n_s_x_element,&__pyx_n_s_rt0vdofs_element,&__pyx_n_s_v_element,0};
7283  PyObject* values[6] = {0,0,0,0,0,0};
7284  if (unlikely(__pyx_kwds)) {
7285  Py_ssize_t kw_args;
7286  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
7287  switch (pos_args) {
7288  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
7289  CYTHON_FALLTHROUGH;
7290  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
7291  CYTHON_FALLTHROUGH;
7292  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
7293  CYTHON_FALLTHROUGH;
7294  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
7295  CYTHON_FALLTHROUGH;
7296  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
7297  CYTHON_FALLTHROUGH;
7298  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
7299  CYTHON_FALLTHROUGH;
7300  case 0: break;
7301  default: goto __pyx_L5_argtuple_error;
7302  }
7303  kw_args = PyDict_Size(__pyx_kwds);
7304  switch (pos_args) {
7305  case 0:
7306  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeArray)) != 0)) kw_args--;
7307  else goto __pyx_L5_argtuple_error;
7308  CYTHON_FALLTHROUGH;
7309  case 1:
7310  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementNodesArray)) != 0)) kw_args--;
7311  else {
7312  __Pyx_RaiseArgtupleInvalid("getElementRT0velocityValuesFluxRep", 1, 6, 6, 1); __PYX_ERR(0, 594, __pyx_L3_error)
7313  }
7314  CYTHON_FALLTHROUGH;
7315  case 2:
7316  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_abs_det_J)) != 0)) kw_args--;
7317  else {
7318  __Pyx_RaiseArgtupleInvalid("getElementRT0velocityValuesFluxRep", 1, 6, 6, 2); __PYX_ERR(0, 594, __pyx_L3_error)
7319  }
7320  CYTHON_FALLTHROUGH;
7321  case 3:
7322  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x_element)) != 0)) kw_args--;
7323  else {
7324  __Pyx_RaiseArgtupleInvalid("getElementRT0velocityValuesFluxRep", 1, 6, 6, 3); __PYX_ERR(0, 594, __pyx_L3_error)
7325  }
7326  CYTHON_FALLTHROUGH;
7327  case 4:
7328  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rt0vdofs_element)) != 0)) kw_args--;
7329  else {
7330  __Pyx_RaiseArgtupleInvalid("getElementRT0velocityValuesFluxRep", 1, 6, 6, 4); __PYX_ERR(0, 594, __pyx_L3_error)
7331  }
7332  CYTHON_FALLTHROUGH;
7333  case 5:
7334  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_v_element)) != 0)) kw_args--;
7335  else {
7336  __Pyx_RaiseArgtupleInvalid("getElementRT0velocityValuesFluxRep", 1, 6, 6, 5); __PYX_ERR(0, 594, __pyx_L3_error)
7337  }
7338  }
7339  if (unlikely(kw_args > 0)) {
7340  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "getElementRT0velocityValuesFluxRep") < 0)) __PYX_ERR(0, 594, __pyx_L3_error)
7341  }
7342  } else if (PyTuple_GET_SIZE(__pyx_args) != 6) {
7343  goto __pyx_L5_argtuple_error;
7344  } else {
7345  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
7346  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
7347  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
7348  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
7349  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
7350  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
7351  }
7352  __pyx_v_nodeArray = ((PyArrayObject *)values[0]);
7353  __pyx_v_elementNodesArray = ((PyArrayObject *)values[1]);
7354  __pyx_v_abs_det_J = ((PyArrayObject *)values[2]);
7355  __pyx_v_x_element = ((PyArrayObject *)values[3]);
7356  __pyx_v_rt0vdofs_element = ((PyArrayObject *)values[4]);
7357  __pyx_v_v_element = ((PyArrayObject *)values[5]);
7358  }
7359  goto __pyx_L4_argument_unpacking_done;
7360  __pyx_L5_argtuple_error:;
7361  __Pyx_RaiseArgtupleInvalid("getElementRT0velocityValuesFluxRep", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 594, __pyx_L3_error)
7362  __pyx_L3_error:;
7363  __Pyx_AddTraceback("cpostprocessing.getElementRT0velocityValuesFluxRep", __pyx_clineno, __pyx_lineno, __pyx_filename);
7364  __Pyx_RefNannyFinishContext();
7365  return NULL;
7366  __pyx_L4_argument_unpacking_done:;
7367  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeArray), __pyx_ptype_5numpy_ndarray, 1, "nodeArray", 0))) __PYX_ERR(0, 594, __pyx_L1_error)
7368  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementNodesArray), __pyx_ptype_5numpy_ndarray, 1, "elementNodesArray", 0))) __PYX_ERR(0, 595, __pyx_L1_error)
7369  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_abs_det_J), __pyx_ptype_5numpy_ndarray, 1, "abs_det_J", 0))) __PYX_ERR(0, 596, __pyx_L1_error)
7370  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_element), __pyx_ptype_5numpy_ndarray, 1, "x_element", 0))) __PYX_ERR(0, 597, __pyx_L1_error)
7371  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rt0vdofs_element), __pyx_ptype_5numpy_ndarray, 1, "rt0vdofs_element", 0))) __PYX_ERR(0, 598, __pyx_L1_error)
7372  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_v_element), __pyx_ptype_5numpy_ndarray, 1, "v_element", 0))) __PYX_ERR(0, 599, __pyx_L1_error)
7373  __pyx_r = __pyx_pf_15cpostprocessing_52getElementRT0velocityValuesFluxRep(__pyx_self, __pyx_v_nodeArray, __pyx_v_elementNodesArray, __pyx_v_abs_det_J, __pyx_v_x_element, __pyx_v_rt0vdofs_element, __pyx_v_v_element);
7374 
7375  /* function exit code */
7376  goto __pyx_L0;
7377  __pyx_L1_error:;
7378  __pyx_r = NULL;
7379  __pyx_L0:;
7380  __Pyx_RefNannyFinishContext();
7381  return __pyx_r;
7382 }
7383 
7384 static PyObject *__pyx_pf_15cpostprocessing_52getElementRT0velocityValuesFluxRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_nodeArray, PyArrayObject *__pyx_v_elementNodesArray, PyArrayObject *__pyx_v_abs_det_J, PyArrayObject *__pyx_v_x_element, PyArrayObject *__pyx_v_rt0vdofs_element, PyArrayObject *__pyx_v_v_element) {
7385  PyObject *__pyx_r = NULL;
7386  __Pyx_RefNannyDeclarations
7387  __Pyx_RefNannySetupContext("getElementRT0velocityValuesFluxRep", 0);
7388 
7389  /* "cpostprocessing.pyx":600
7390  * np.ndarray rt0vdofs_element,
7391  * np.ndarray v_element):
7392  * pp.getElementRT0velocityValuesFluxRep(v_element.shape[0], # <<<<<<<<<<<<<<
7393  * elementNodesArray.shape[1],
7394  * v_element.shape[1],
7395  */
7396  getElementRT0velocityValuesFluxRep((__pyx_v_v_element->dimensions[0]), (__pyx_v_elementNodesArray->dimensions[1]), (__pyx_v_v_element->dimensions[1]), (__pyx_v_v_element->dimensions[2]), (__pyx_v_abs_det_J->dimensions[1]), ((double *)__pyx_v_nodeArray->data), ((int *)__pyx_v_elementNodesArray->data), ((double *)__pyx_v_abs_det_J->data), ((double *)__pyx_v_x_element->data), ((double *)__pyx_v_rt0vdofs_element->data), ((double *)__pyx_v_v_element->data));
7397 
7398  /* "cpostprocessing.pyx":594
7399  * <double*>(rt0vdofs_element.data))
7400  *
7401  * def getElementRT0velocityValuesFluxRep(np.ndarray nodeArray, # <<<<<<<<<<<<<<
7402  * np.ndarray elementNodesArray,
7403  * np.ndarray abs_det_J,
7404  */
7405 
7406  /* function exit code */
7407  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
7408  __Pyx_XGIVEREF(__pyx_r);
7409  __Pyx_RefNannyFinishContext();
7410  return __pyx_r;
7411 }
7412 
7413 /* "cpostprocessing.pyx":612
7414  * <double*>(v_element.data))
7415  *
7416  * def getElementBoundaryRT0velocityValuesFluxRep(np.ndarray nodeArray, # <<<<<<<<<<<<<<
7417  * np.ndarray elementNodesArray,
7418  * np.ndarray abs_det_J,
7419  */
7420 
7421 /* Python wrapper */
7422 static PyObject *__pyx_pw_15cpostprocessing_55getElementBoundaryRT0velocityValuesFluxRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
7423 static PyMethodDef __pyx_mdef_15cpostprocessing_55getElementBoundaryRT0velocityValuesFluxRep = {"getElementBoundaryRT0velocityValuesFluxRep", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_55getElementBoundaryRT0velocityValuesFluxRep, METH_VARARGS|METH_KEYWORDS, 0};
7424 static PyObject *__pyx_pw_15cpostprocessing_55getElementBoundaryRT0velocityValuesFluxRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
7425  PyArrayObject *__pyx_v_nodeArray = 0;
7426  PyArrayObject *__pyx_v_elementNodesArray = 0;
7427  PyArrayObject *__pyx_v_abs_det_J = 0;
7428  PyArrayObject *__pyx_v_x_elementBoundary = 0;
7429  PyArrayObject *__pyx_v_rt0vdofs_element = 0;
7430  PyArrayObject *__pyx_v_v_elementBoundary = 0;
7431  int __pyx_lineno = 0;
7432  const char *__pyx_filename = NULL;
7433  int __pyx_clineno = 0;
7434  PyObject *__pyx_r = 0;
7435  __Pyx_RefNannyDeclarations
7436  __Pyx_RefNannySetupContext("getElementBoundaryRT0velocityValuesFluxRep (wrapper)", 0);
7437  {
7438  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_nodeArray,&__pyx_n_s_elementNodesArray,&__pyx_n_s_abs_det_J,&__pyx_n_s_x_elementBoundary,&__pyx_n_s_rt0vdofs_element,&__pyx_n_s_v_elementBoundary,0};
7439  PyObject* values[6] = {0,0,0,0,0,0};
7440  if (unlikely(__pyx_kwds)) {
7441  Py_ssize_t kw_args;
7442  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
7443  switch (pos_args) {
7444  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
7445  CYTHON_FALLTHROUGH;
7446  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
7447  CYTHON_FALLTHROUGH;
7448  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
7449  CYTHON_FALLTHROUGH;
7450  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
7451  CYTHON_FALLTHROUGH;
7452  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
7453  CYTHON_FALLTHROUGH;
7454  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
7455  CYTHON_FALLTHROUGH;
7456  case 0: break;
7457  default: goto __pyx_L5_argtuple_error;
7458  }
7459  kw_args = PyDict_Size(__pyx_kwds);
7460  switch (pos_args) {
7461  case 0:
7462  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeArray)) != 0)) kw_args--;
7463  else goto __pyx_L5_argtuple_error;
7464  CYTHON_FALLTHROUGH;
7465  case 1:
7466  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementNodesArray)) != 0)) kw_args--;
7467  else {
7468  __Pyx_RaiseArgtupleInvalid("getElementBoundaryRT0velocityValuesFluxRep", 1, 6, 6, 1); __PYX_ERR(0, 612, __pyx_L3_error)
7469  }
7470  CYTHON_FALLTHROUGH;
7471  case 2:
7472  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_abs_det_J)) != 0)) kw_args--;
7473  else {
7474  __Pyx_RaiseArgtupleInvalid("getElementBoundaryRT0velocityValuesFluxRep", 1, 6, 6, 2); __PYX_ERR(0, 612, __pyx_L3_error)
7475  }
7476  CYTHON_FALLTHROUGH;
7477  case 3:
7478  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x_elementBoundary)) != 0)) kw_args--;
7479  else {
7480  __Pyx_RaiseArgtupleInvalid("getElementBoundaryRT0velocityValuesFluxRep", 1, 6, 6, 3); __PYX_ERR(0, 612, __pyx_L3_error)
7481  }
7482  CYTHON_FALLTHROUGH;
7483  case 4:
7484  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rt0vdofs_element)) != 0)) kw_args--;
7485  else {
7486  __Pyx_RaiseArgtupleInvalid("getElementBoundaryRT0velocityValuesFluxRep", 1, 6, 6, 4); __PYX_ERR(0, 612, __pyx_L3_error)
7487  }
7488  CYTHON_FALLTHROUGH;
7489  case 5:
7490  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_v_elementBoundary)) != 0)) kw_args--;
7491  else {
7492  __Pyx_RaiseArgtupleInvalid("getElementBoundaryRT0velocityValuesFluxRep", 1, 6, 6, 5); __PYX_ERR(0, 612, __pyx_L3_error)
7493  }
7494  }
7495  if (unlikely(kw_args > 0)) {
7496  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "getElementBoundaryRT0velocityValuesFluxRep") < 0)) __PYX_ERR(0, 612, __pyx_L3_error)
7497  }
7498  } else if (PyTuple_GET_SIZE(__pyx_args) != 6) {
7499  goto __pyx_L5_argtuple_error;
7500  } else {
7501  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
7502  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
7503  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
7504  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
7505  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
7506  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
7507  }
7508  __pyx_v_nodeArray = ((PyArrayObject *)values[0]);
7509  __pyx_v_elementNodesArray = ((PyArrayObject *)values[1]);
7510  __pyx_v_abs_det_J = ((PyArrayObject *)values[2]);
7511  __pyx_v_x_elementBoundary = ((PyArrayObject *)values[3]);
7512  __pyx_v_rt0vdofs_element = ((PyArrayObject *)values[4]);
7513  __pyx_v_v_elementBoundary = ((PyArrayObject *)values[5]);
7514  }
7515  goto __pyx_L4_argument_unpacking_done;
7516  __pyx_L5_argtuple_error:;
7517  __Pyx_RaiseArgtupleInvalid("getElementBoundaryRT0velocityValuesFluxRep", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 612, __pyx_L3_error)
7518  __pyx_L3_error:;
7519  __Pyx_AddTraceback("cpostprocessing.getElementBoundaryRT0velocityValuesFluxRep", __pyx_clineno, __pyx_lineno, __pyx_filename);
7520  __Pyx_RefNannyFinishContext();
7521  return NULL;
7522  __pyx_L4_argument_unpacking_done:;
7523  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeArray), __pyx_ptype_5numpy_ndarray, 1, "nodeArray", 0))) __PYX_ERR(0, 612, __pyx_L1_error)
7524  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementNodesArray), __pyx_ptype_5numpy_ndarray, 1, "elementNodesArray", 0))) __PYX_ERR(0, 613, __pyx_L1_error)
7525  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_abs_det_J), __pyx_ptype_5numpy_ndarray, 1, "abs_det_J", 0))) __PYX_ERR(0, 614, __pyx_L1_error)
7526  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_elementBoundary), __pyx_ptype_5numpy_ndarray, 1, "x_elementBoundary", 0))) __PYX_ERR(0, 615, __pyx_L1_error)
7527  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rt0vdofs_element), __pyx_ptype_5numpy_ndarray, 1, "rt0vdofs_element", 0))) __PYX_ERR(0, 616, __pyx_L1_error)
7528  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_v_elementBoundary), __pyx_ptype_5numpy_ndarray, 1, "v_elementBoundary", 0))) __PYX_ERR(0, 617, __pyx_L1_error)
7529  __pyx_r = __pyx_pf_15cpostprocessing_54getElementBoundaryRT0velocityValuesFluxRep(__pyx_self, __pyx_v_nodeArray, __pyx_v_elementNodesArray, __pyx_v_abs_det_J, __pyx_v_x_elementBoundary, __pyx_v_rt0vdofs_element, __pyx_v_v_elementBoundary);
7530 
7531  /* function exit code */
7532  goto __pyx_L0;
7533  __pyx_L1_error:;
7534  __pyx_r = NULL;
7535  __pyx_L0:;
7536  __Pyx_RefNannyFinishContext();
7537  return __pyx_r;
7538 }
7539 
7540 static PyObject *__pyx_pf_15cpostprocessing_54getElementBoundaryRT0velocityValuesFluxRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_nodeArray, PyArrayObject *__pyx_v_elementNodesArray, PyArrayObject *__pyx_v_abs_det_J, PyArrayObject *__pyx_v_x_elementBoundary, PyArrayObject *__pyx_v_rt0vdofs_element, PyArrayObject *__pyx_v_v_elementBoundary) {
7541  PyObject *__pyx_r = NULL;
7542  __Pyx_RefNannyDeclarations
7543  __Pyx_RefNannySetupContext("getElementBoundaryRT0velocityValuesFluxRep", 0);
7544 
7545  /* "cpostprocessing.pyx":618
7546  * np.ndarray rt0vdofs_element,
7547  * np.ndarray v_elementBoundary):
7548  * pp.getElementBoundaryRT0velocityValuesFluxRep(v_elementBoundary.shape[0], # <<<<<<<<<<<<<<
7549  * v_elementBoundary.shape[1],
7550  * v_elementBoundary.shape[2],
7551  */
7552  getElementBoundaryRT0velocityValuesFluxRep((__pyx_v_v_elementBoundary->dimensions[0]), (__pyx_v_v_elementBoundary->dimensions[1]), (__pyx_v_v_elementBoundary->dimensions[2]), (__pyx_v_v_elementBoundary->dimensions[3]), (__pyx_v_abs_det_J->dimensions[1]), ((double *)__pyx_v_nodeArray->data), ((int *)__pyx_v_elementNodesArray->data), ((double *)__pyx_v_abs_det_J->data), ((double *)__pyx_v_x_elementBoundary->data), ((double *)__pyx_v_rt0vdofs_element->data), ((double *)__pyx_v_v_elementBoundary->data));
7553 
7554  /* "cpostprocessing.pyx":612
7555  * <double*>(v_element.data))
7556  *
7557  * def getElementBoundaryRT0velocityValuesFluxRep(np.ndarray nodeArray, # <<<<<<<<<<<<<<
7558  * np.ndarray elementNodesArray,
7559  * np.ndarray abs_det_J,
7560  */
7561 
7562  /* function exit code */
7563  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
7564  __Pyx_XGIVEREF(__pyx_r);
7565  __Pyx_RefNannyFinishContext();
7566  return __pyx_r;
7567 }
7568 
7569 /* "cpostprocessing.pyx":630
7570  * <double*>(v_elementBoundary.data))
7571  *
7572  * def getGlobalElementBoundaryRT0velocityValuesFluxRep(np.ndarray nodeArray, # <<<<<<<<<<<<<<
7573  * np.ndarray elementNodesArray,
7574  * np.ndarray elementBoundaryElementsArray,
7575  */
7576 
7577 /* Python wrapper */
7578 static PyObject *__pyx_pw_15cpostprocessing_57getGlobalElementBoundaryRT0velocityValuesFluxRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
7579 static PyMethodDef __pyx_mdef_15cpostprocessing_57getGlobalElementBoundaryRT0velocityValuesFluxRep = {"getGlobalElementBoundaryRT0velocityValuesFluxRep", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_57getGlobalElementBoundaryRT0velocityValuesFluxRep, METH_VARARGS|METH_KEYWORDS, 0};
7580 static PyObject *__pyx_pw_15cpostprocessing_57getGlobalElementBoundaryRT0velocityValuesFluxRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
7581  PyArrayObject *__pyx_v_nodeArray = 0;
7582  PyArrayObject *__pyx_v_elementNodesArray = 0;
7583  PyArrayObject *__pyx_v_elementBoundaryElementsArray = 0;
7584  PyArrayObject *__pyx_v_abs_det_J = 0;
7585  PyArrayObject *__pyx_v_x_elementBoundary_global = 0;
7586  PyArrayObject *__pyx_v_rt0vdofs_element = 0;
7587  PyArrayObject *__pyx_v_v_elementBoundary_global = 0;
7588  int __pyx_lineno = 0;
7589  const char *__pyx_filename = NULL;
7590  int __pyx_clineno = 0;
7591  PyObject *__pyx_r = 0;
7592  __Pyx_RefNannyDeclarations
7593  __Pyx_RefNannySetupContext("getGlobalElementBoundaryRT0velocityValuesFluxRep (wrapper)", 0);
7594  {
7595  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_nodeArray,&__pyx_n_s_elementNodesArray,&__pyx_n_s_elementBoundaryElementsArray,&__pyx_n_s_abs_det_J,&__pyx_n_s_x_elementBoundary_global,&__pyx_n_s_rt0vdofs_element,&__pyx_n_s_v_elementBoundary_global,0};
7596  PyObject* values[7] = {0,0,0,0,0,0,0};
7597  if (unlikely(__pyx_kwds)) {
7598  Py_ssize_t kw_args;
7599  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
7600  switch (pos_args) {
7601  case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
7602  CYTHON_FALLTHROUGH;
7603  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
7604  CYTHON_FALLTHROUGH;
7605  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
7606  CYTHON_FALLTHROUGH;
7607  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
7608  CYTHON_FALLTHROUGH;
7609  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
7610  CYTHON_FALLTHROUGH;
7611  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
7612  CYTHON_FALLTHROUGH;
7613  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
7614  CYTHON_FALLTHROUGH;
7615  case 0: break;
7616  default: goto __pyx_L5_argtuple_error;
7617  }
7618  kw_args = PyDict_Size(__pyx_kwds);
7619  switch (pos_args) {
7620  case 0:
7621  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeArray)) != 0)) kw_args--;
7622  else goto __pyx_L5_argtuple_error;
7623  CYTHON_FALLTHROUGH;
7624  case 1:
7625  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementNodesArray)) != 0)) kw_args--;
7626  else {
7627  __Pyx_RaiseArgtupleInvalid("getGlobalElementBoundaryRT0velocityValuesFluxRep", 1, 7, 7, 1); __PYX_ERR(0, 630, __pyx_L3_error)
7628  }
7629  CYTHON_FALLTHROUGH;
7630  case 2:
7631  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryElementsArray)) != 0)) kw_args--;
7632  else {
7633  __Pyx_RaiseArgtupleInvalid("getGlobalElementBoundaryRT0velocityValuesFluxRep", 1, 7, 7, 2); __PYX_ERR(0, 630, __pyx_L3_error)
7634  }
7635  CYTHON_FALLTHROUGH;
7636  case 3:
7637  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_abs_det_J)) != 0)) kw_args--;
7638  else {
7639  __Pyx_RaiseArgtupleInvalid("getGlobalElementBoundaryRT0velocityValuesFluxRep", 1, 7, 7, 3); __PYX_ERR(0, 630, __pyx_L3_error)
7640  }
7641  CYTHON_FALLTHROUGH;
7642  case 4:
7643  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x_elementBoundary_global)) != 0)) kw_args--;
7644  else {
7645  __Pyx_RaiseArgtupleInvalid("getGlobalElementBoundaryRT0velocityValuesFluxRep", 1, 7, 7, 4); __PYX_ERR(0, 630, __pyx_L3_error)
7646  }
7647  CYTHON_FALLTHROUGH;
7648  case 5:
7649  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rt0vdofs_element)) != 0)) kw_args--;
7650  else {
7651  __Pyx_RaiseArgtupleInvalid("getGlobalElementBoundaryRT0velocityValuesFluxRep", 1, 7, 7, 5); __PYX_ERR(0, 630, __pyx_L3_error)
7652  }
7653  CYTHON_FALLTHROUGH;
7654  case 6:
7655  if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_v_elementBoundary_global)) != 0)) kw_args--;
7656  else {
7657  __Pyx_RaiseArgtupleInvalid("getGlobalElementBoundaryRT0velocityValuesFluxRep", 1, 7, 7, 6); __PYX_ERR(0, 630, __pyx_L3_error)
7658  }
7659  }
7660  if (unlikely(kw_args > 0)) {
7661  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "getGlobalElementBoundaryRT0velocityValuesFluxRep") < 0)) __PYX_ERR(0, 630, __pyx_L3_error)
7662  }
7663  } else if (PyTuple_GET_SIZE(__pyx_args) != 7) {
7664  goto __pyx_L5_argtuple_error;
7665  } else {
7666  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
7667  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
7668  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
7669  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
7670  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
7671  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
7672  values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
7673  }
7674  __pyx_v_nodeArray = ((PyArrayObject *)values[0]);
7675  __pyx_v_elementNodesArray = ((PyArrayObject *)values[1]);
7676  __pyx_v_elementBoundaryElementsArray = ((PyArrayObject *)values[2]);
7677  __pyx_v_abs_det_J = ((PyArrayObject *)values[3]);
7678  __pyx_v_x_elementBoundary_global = ((PyArrayObject *)values[4]);
7679  __pyx_v_rt0vdofs_element = ((PyArrayObject *)values[5]);
7680  __pyx_v_v_elementBoundary_global = ((PyArrayObject *)values[6]);
7681  }
7682  goto __pyx_L4_argument_unpacking_done;
7683  __pyx_L5_argtuple_error:;
7684  __Pyx_RaiseArgtupleInvalid("getGlobalElementBoundaryRT0velocityValuesFluxRep", 1, 7, 7, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 630, __pyx_L3_error)
7685  __pyx_L3_error:;
7686  __Pyx_AddTraceback("cpostprocessing.getGlobalElementBoundaryRT0velocityValuesFluxRep", __pyx_clineno, __pyx_lineno, __pyx_filename);
7687  __Pyx_RefNannyFinishContext();
7688  return NULL;
7689  __pyx_L4_argument_unpacking_done:;
7690  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeArray), __pyx_ptype_5numpy_ndarray, 1, "nodeArray", 0))) __PYX_ERR(0, 630, __pyx_L1_error)
7691  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementNodesArray), __pyx_ptype_5numpy_ndarray, 1, "elementNodesArray", 0))) __PYX_ERR(0, 631, __pyx_L1_error)
7692  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryElementsArray), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryElementsArray", 0))) __PYX_ERR(0, 632, __pyx_L1_error)
7693  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_abs_det_J), __pyx_ptype_5numpy_ndarray, 1, "abs_det_J", 0))) __PYX_ERR(0, 633, __pyx_L1_error)
7694  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_elementBoundary_global), __pyx_ptype_5numpy_ndarray, 1, "x_elementBoundary_global", 0))) __PYX_ERR(0, 634, __pyx_L1_error)
7695  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rt0vdofs_element), __pyx_ptype_5numpy_ndarray, 1, "rt0vdofs_element", 0))) __PYX_ERR(0, 635, __pyx_L1_error)
7696  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_v_elementBoundary_global), __pyx_ptype_5numpy_ndarray, 1, "v_elementBoundary_global", 0))) __PYX_ERR(0, 636, __pyx_L1_error)
7697  __pyx_r = __pyx_pf_15cpostprocessing_56getGlobalElementBoundaryRT0velocityValuesFluxRep(__pyx_self, __pyx_v_nodeArray, __pyx_v_elementNodesArray, __pyx_v_elementBoundaryElementsArray, __pyx_v_abs_det_J, __pyx_v_x_elementBoundary_global, __pyx_v_rt0vdofs_element, __pyx_v_v_elementBoundary_global);
7698 
7699  /* function exit code */
7700  goto __pyx_L0;
7701  __pyx_L1_error:;
7702  __pyx_r = NULL;
7703  __pyx_L0:;
7704  __Pyx_RefNannyFinishContext();
7705  return __pyx_r;
7706 }
7707 
7708 static PyObject *__pyx_pf_15cpostprocessing_56getGlobalElementBoundaryRT0velocityValuesFluxRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_nodeArray, PyArrayObject *__pyx_v_elementNodesArray, PyArrayObject *__pyx_v_elementBoundaryElementsArray, PyArrayObject *__pyx_v_abs_det_J, PyArrayObject *__pyx_v_x_elementBoundary_global, PyArrayObject *__pyx_v_rt0vdofs_element, PyArrayObject *__pyx_v_v_elementBoundary_global) {
7709  PyObject *__pyx_r = NULL;
7710  __Pyx_RefNannyDeclarations
7711  __Pyx_RefNannySetupContext("getGlobalElementBoundaryRT0velocityValuesFluxRep", 0);
7712 
7713  /* "cpostprocessing.pyx":637
7714  * np.ndarray rt0vdofs_element,
7715  * np.ndarray v_elementBoundary_global):
7716  * pp.getGlobalElementBoundaryRT0velocityValuesFluxRep(v_elementBoundary_global.shape[0], # <<<<<<<<<<<<<<
7717  * v_elementBoundary_global.shape[1],
7718  * v_elementBoundary_global.shape[2],
7719  */
7720  getGlobalElementBoundaryRT0velocityValuesFluxRep((__pyx_v_v_elementBoundary_global->dimensions[0]), (__pyx_v_v_elementBoundary_global->dimensions[1]), (__pyx_v_v_elementBoundary_global->dimensions[2]), (__pyx_v_abs_det_J->dimensions[1]), ((double *)__pyx_v_nodeArray->data), ((int *)__pyx_v_elementNodesArray->data), ((int *)__pyx_v_elementBoundaryElementsArray->data), ((double *)__pyx_v_abs_det_J->data), ((double *)__pyx_v_x_elementBoundary_global->data), ((double *)__pyx_v_rt0vdofs_element->data), ((double *)__pyx_v_v_elementBoundary_global->data));
7721 
7722  /* "cpostprocessing.pyx":630
7723  * <double*>(v_elementBoundary.data))
7724  *
7725  * def getGlobalElementBoundaryRT0velocityValuesFluxRep(np.ndarray nodeArray, # <<<<<<<<<<<<<<
7726  * np.ndarray elementNodesArray,
7727  * np.ndarray elementBoundaryElementsArray,
7728  */
7729 
7730  /* function exit code */
7731  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
7732  __Pyx_XGIVEREF(__pyx_r);
7733  __Pyx_RefNannyFinishContext();
7734  return __pyx_r;
7735 }
7736 
7737 /* "cpostprocessing.pyx":649
7738  * <double*>(v_elementBoundary_global.data))
7739  *
7740  * def getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep(np.ndarray nodeArray, # <<<<<<<<<<<<<<
7741  * np.ndarray elementNodesArray,
7742  * np.ndarray elementBoundaryElementsArray,
7743  */
7744 
7745 /* Python wrapper */
7746 static PyObject *__pyx_pw_15cpostprocessing_59getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
7747 static PyMethodDef __pyx_mdef_15cpostprocessing_59getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep = {"getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_59getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep, METH_VARARGS|METH_KEYWORDS, 0};
7748 static PyObject *__pyx_pw_15cpostprocessing_59getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
7749  PyArrayObject *__pyx_v_nodeArray = 0;
7750  PyArrayObject *__pyx_v_elementNodesArray = 0;
7751  PyArrayObject *__pyx_v_elementBoundaryElementsArray = 0;
7752  PyArrayObject *__pyx_v_exteriorElementBoundariesArray = 0;
7753  PyArrayObject *__pyx_v_abs_det_J = 0;
7754  PyArrayObject *__pyx_v_x_ebqe = 0;
7755  PyArrayObject *__pyx_v_rt0vdofs_element = 0;
7756  PyArrayObject *__pyx_v_v_ebqe = 0;
7757  int __pyx_lineno = 0;
7758  const char *__pyx_filename = NULL;
7759  int __pyx_clineno = 0;
7760  PyObject *__pyx_r = 0;
7761  __Pyx_RefNannyDeclarations
7762  __Pyx_RefNannySetupContext("getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep (wrapper)", 0);
7763  {
7764  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_nodeArray,&__pyx_n_s_elementNodesArray,&__pyx_n_s_elementBoundaryElementsArray,&__pyx_n_s_exteriorElementBoundariesArray,&__pyx_n_s_abs_det_J,&__pyx_n_s_x_ebqe,&__pyx_n_s_rt0vdofs_element,&__pyx_n_s_v_ebqe,0};
7765  PyObject* values[8] = {0,0,0,0,0,0,0,0};
7766  if (unlikely(__pyx_kwds)) {
7767  Py_ssize_t kw_args;
7768  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
7769  switch (pos_args) {
7770  case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
7771  CYTHON_FALLTHROUGH;
7772  case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
7773  CYTHON_FALLTHROUGH;
7774  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
7775  CYTHON_FALLTHROUGH;
7776  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
7777  CYTHON_FALLTHROUGH;
7778  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
7779  CYTHON_FALLTHROUGH;
7780  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
7781  CYTHON_FALLTHROUGH;
7782  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
7783  CYTHON_FALLTHROUGH;
7784  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
7785  CYTHON_FALLTHROUGH;
7786  case 0: break;
7787  default: goto __pyx_L5_argtuple_error;
7788  }
7789  kw_args = PyDict_Size(__pyx_kwds);
7790  switch (pos_args) {
7791  case 0:
7792  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeArray)) != 0)) kw_args--;
7793  else goto __pyx_L5_argtuple_error;
7794  CYTHON_FALLTHROUGH;
7795  case 1:
7796  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementNodesArray)) != 0)) kw_args--;
7797  else {
7798  __Pyx_RaiseArgtupleInvalid("getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep", 1, 8, 8, 1); __PYX_ERR(0, 649, __pyx_L3_error)
7799  }
7800  CYTHON_FALLTHROUGH;
7801  case 2:
7802  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryElementsArray)) != 0)) kw_args--;
7803  else {
7804  __Pyx_RaiseArgtupleInvalid("getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep", 1, 8, 8, 2); __PYX_ERR(0, 649, __pyx_L3_error)
7805  }
7806  CYTHON_FALLTHROUGH;
7807  case 3:
7808  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_exteriorElementBoundariesArray)) != 0)) kw_args--;
7809  else {
7810  __Pyx_RaiseArgtupleInvalid("getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep", 1, 8, 8, 3); __PYX_ERR(0, 649, __pyx_L3_error)
7811  }
7812  CYTHON_FALLTHROUGH;
7813  case 4:
7814  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_abs_det_J)) != 0)) kw_args--;
7815  else {
7816  __Pyx_RaiseArgtupleInvalid("getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep", 1, 8, 8, 4); __PYX_ERR(0, 649, __pyx_L3_error)
7817  }
7818  CYTHON_FALLTHROUGH;
7819  case 5:
7820  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x_ebqe)) != 0)) kw_args--;
7821  else {
7822  __Pyx_RaiseArgtupleInvalid("getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep", 1, 8, 8, 5); __PYX_ERR(0, 649, __pyx_L3_error)
7823  }
7824  CYTHON_FALLTHROUGH;
7825  case 6:
7826  if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rt0vdofs_element)) != 0)) kw_args--;
7827  else {
7828  __Pyx_RaiseArgtupleInvalid("getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep", 1, 8, 8, 6); __PYX_ERR(0, 649, __pyx_L3_error)
7829  }
7830  CYTHON_FALLTHROUGH;
7831  case 7:
7832  if (likely((values[7] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_v_ebqe)) != 0)) kw_args--;
7833  else {
7834  __Pyx_RaiseArgtupleInvalid("getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep", 1, 8, 8, 7); __PYX_ERR(0, 649, __pyx_L3_error)
7835  }
7836  }
7837  if (unlikely(kw_args > 0)) {
7838  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep") < 0)) __PYX_ERR(0, 649, __pyx_L3_error)
7839  }
7840  } else if (PyTuple_GET_SIZE(__pyx_args) != 8) {
7841  goto __pyx_L5_argtuple_error;
7842  } else {
7843  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
7844  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
7845  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
7846  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
7847  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
7848  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
7849  values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
7850  values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
7851  }
7852  __pyx_v_nodeArray = ((PyArrayObject *)values[0]);
7853  __pyx_v_elementNodesArray = ((PyArrayObject *)values[1]);
7854  __pyx_v_elementBoundaryElementsArray = ((PyArrayObject *)values[2]);
7855  __pyx_v_exteriorElementBoundariesArray = ((PyArrayObject *)values[3]);
7856  __pyx_v_abs_det_J = ((PyArrayObject *)values[4]);
7857  __pyx_v_x_ebqe = ((PyArrayObject *)values[5]);
7858  __pyx_v_rt0vdofs_element = ((PyArrayObject *)values[6]);
7859  __pyx_v_v_ebqe = ((PyArrayObject *)values[7]);
7860  }
7861  goto __pyx_L4_argument_unpacking_done;
7862  __pyx_L5_argtuple_error:;
7863  __Pyx_RaiseArgtupleInvalid("getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep", 1, 8, 8, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 649, __pyx_L3_error)
7864  __pyx_L3_error:;
7865  __Pyx_AddTraceback("cpostprocessing.getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep", __pyx_clineno, __pyx_lineno, __pyx_filename);
7866  __Pyx_RefNannyFinishContext();
7867  return NULL;
7868  __pyx_L4_argument_unpacking_done:;
7869  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeArray), __pyx_ptype_5numpy_ndarray, 1, "nodeArray", 0))) __PYX_ERR(0, 649, __pyx_L1_error)
7870  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementNodesArray), __pyx_ptype_5numpy_ndarray, 1, "elementNodesArray", 0))) __PYX_ERR(0, 650, __pyx_L1_error)
7871  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryElementsArray), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryElementsArray", 0))) __PYX_ERR(0, 651, __pyx_L1_error)
7872  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_exteriorElementBoundariesArray), __pyx_ptype_5numpy_ndarray, 1, "exteriorElementBoundariesArray", 0))) __PYX_ERR(0, 652, __pyx_L1_error)
7873  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_abs_det_J), __pyx_ptype_5numpy_ndarray, 1, "abs_det_J", 0))) __PYX_ERR(0, 653, __pyx_L1_error)
7874  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_ebqe), __pyx_ptype_5numpy_ndarray, 1, "x_ebqe", 0))) __PYX_ERR(0, 654, __pyx_L1_error)
7875  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rt0vdofs_element), __pyx_ptype_5numpy_ndarray, 1, "rt0vdofs_element", 0))) __PYX_ERR(0, 655, __pyx_L1_error)
7876  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_v_ebqe), __pyx_ptype_5numpy_ndarray, 1, "v_ebqe", 0))) __PYX_ERR(0, 656, __pyx_L1_error)
7877  __pyx_r = __pyx_pf_15cpostprocessing_58getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep(__pyx_self, __pyx_v_nodeArray, __pyx_v_elementNodesArray, __pyx_v_elementBoundaryElementsArray, __pyx_v_exteriorElementBoundariesArray, __pyx_v_abs_det_J, __pyx_v_x_ebqe, __pyx_v_rt0vdofs_element, __pyx_v_v_ebqe);
7878 
7879  /* function exit code */
7880  goto __pyx_L0;
7881  __pyx_L1_error:;
7882  __pyx_r = NULL;
7883  __pyx_L0:;
7884  __Pyx_RefNannyFinishContext();
7885  return __pyx_r;
7886 }
7887 
7888 static PyObject *__pyx_pf_15cpostprocessing_58getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_nodeArray, PyArrayObject *__pyx_v_elementNodesArray, PyArrayObject *__pyx_v_elementBoundaryElementsArray, PyArrayObject *__pyx_v_exteriorElementBoundariesArray, PyArrayObject *__pyx_v_abs_det_J, PyArrayObject *__pyx_v_x_ebqe, PyArrayObject *__pyx_v_rt0vdofs_element, PyArrayObject *__pyx_v_v_ebqe) {
7889  PyObject *__pyx_r = NULL;
7890  __Pyx_RefNannyDeclarations
7891  __Pyx_RefNannySetupContext("getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep", 0);
7892 
7893  /* "cpostprocessing.pyx":657
7894  * np.ndarray rt0vdofs_element,
7895  * np.ndarray v_ebqe):
7896  * pp.getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep(v_ebqe.shape[0], # <<<<<<<<<<<<<<
7897  * v_ebqe.shape[1],
7898  * v_ebqe.shape[2],
7899  */
7900  getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep((__pyx_v_v_ebqe->dimensions[0]), (__pyx_v_v_ebqe->dimensions[1]), (__pyx_v_v_ebqe->dimensions[2]), (__pyx_v_abs_det_J->dimensions[1]), ((double *)__pyx_v_nodeArray->data), ((int *)__pyx_v_elementNodesArray->data), ((int *)__pyx_v_elementBoundaryElementsArray->data), ((int *)__pyx_v_exteriorElementBoundariesArray->data), ((double *)__pyx_v_abs_det_J->data), ((double *)__pyx_v_x_ebqe->data), ((double *)__pyx_v_rt0vdofs_element->data), ((double *)__pyx_v_v_ebqe->data));
7901 
7902  /* "cpostprocessing.pyx":649
7903  * <double*>(v_elementBoundary_global.data))
7904  *
7905  * def getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep(np.ndarray nodeArray, # <<<<<<<<<<<<<<
7906  * np.ndarray elementNodesArray,
7907  * np.ndarray elementBoundaryElementsArray,
7908  */
7909 
7910  /* function exit code */
7911  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
7912  __Pyx_XGIVEREF(__pyx_r);
7913  __Pyx_RefNannyFinishContext();
7914  return __pyx_r;
7915 }
7916 
7917 /* "cpostprocessing.pyx":670
7918  * <double*>(v_ebqe.data))
7919  *
7920  * def getRT0velocityValuesFluxRep_arbitraryElementMembership(np.ndarray nodeArray, # <<<<<<<<<<<<<<
7921  * np.ndarray elementNodesArray,
7922  * np.ndarray abs_det_J,
7923  */
7924 
7925 /* Python wrapper */
7926 static PyObject *__pyx_pw_15cpostprocessing_61getRT0velocityValuesFluxRep_arbitraryElementMembership(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
7927 static PyMethodDef __pyx_mdef_15cpostprocessing_61getRT0velocityValuesFluxRep_arbitraryElementMembership = {"getRT0velocityValuesFluxRep_arbitraryElementMembership", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_61getRT0velocityValuesFluxRep_arbitraryElementMembership, METH_VARARGS|METH_KEYWORDS, 0};
7928 static PyObject *__pyx_pw_15cpostprocessing_61getRT0velocityValuesFluxRep_arbitraryElementMembership(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
7929  PyArrayObject *__pyx_v_nodeArray = 0;
7930  PyArrayObject *__pyx_v_elementNodesArray = 0;
7931  PyArrayObject *__pyx_v_abs_det_J = 0;
7932  PyArrayObject *__pyx_v_x = 0;
7933  PyArrayObject *__pyx_v_element_locations = 0;
7934  PyArrayObject *__pyx_v_rt0vdofs_element = 0;
7935  PyArrayObject *__pyx_v_v_element = 0;
7936  int __pyx_lineno = 0;
7937  const char *__pyx_filename = NULL;
7938  int __pyx_clineno = 0;
7939  PyObject *__pyx_r = 0;
7940  __Pyx_RefNannyDeclarations
7941  __Pyx_RefNannySetupContext("getRT0velocityValuesFluxRep_arbitraryElementMembership (wrapper)", 0);
7942  {
7943  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_nodeArray,&__pyx_n_s_elementNodesArray,&__pyx_n_s_abs_det_J,&__pyx_n_s_x,&__pyx_n_s_element_locations,&__pyx_n_s_rt0vdofs_element,&__pyx_n_s_v_element,0};
7944  PyObject* values[7] = {0,0,0,0,0,0,0};
7945  if (unlikely(__pyx_kwds)) {
7946  Py_ssize_t kw_args;
7947  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
7948  switch (pos_args) {
7949  case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
7950  CYTHON_FALLTHROUGH;
7951  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
7952  CYTHON_FALLTHROUGH;
7953  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
7954  CYTHON_FALLTHROUGH;
7955  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
7956  CYTHON_FALLTHROUGH;
7957  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
7958  CYTHON_FALLTHROUGH;
7959  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
7960  CYTHON_FALLTHROUGH;
7961  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
7962  CYTHON_FALLTHROUGH;
7963  case 0: break;
7964  default: goto __pyx_L5_argtuple_error;
7965  }
7966  kw_args = PyDict_Size(__pyx_kwds);
7967  switch (pos_args) {
7968  case 0:
7969  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeArray)) != 0)) kw_args--;
7970  else goto __pyx_L5_argtuple_error;
7971  CYTHON_FALLTHROUGH;
7972  case 1:
7973  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementNodesArray)) != 0)) kw_args--;
7974  else {
7975  __Pyx_RaiseArgtupleInvalid("getRT0velocityValuesFluxRep_arbitraryElementMembership", 1, 7, 7, 1); __PYX_ERR(0, 670, __pyx_L3_error)
7976  }
7977  CYTHON_FALLTHROUGH;
7978  case 2:
7979  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_abs_det_J)) != 0)) kw_args--;
7980  else {
7981  __Pyx_RaiseArgtupleInvalid("getRT0velocityValuesFluxRep_arbitraryElementMembership", 1, 7, 7, 2); __PYX_ERR(0, 670, __pyx_L3_error)
7982  }
7983  CYTHON_FALLTHROUGH;
7984  case 3:
7985  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_x)) != 0)) kw_args--;
7986  else {
7987  __Pyx_RaiseArgtupleInvalid("getRT0velocityValuesFluxRep_arbitraryElementMembership", 1, 7, 7, 3); __PYX_ERR(0, 670, __pyx_L3_error)
7988  }
7989  CYTHON_FALLTHROUGH;
7990  case 4:
7991  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_element_locations)) != 0)) kw_args--;
7992  else {
7993  __Pyx_RaiseArgtupleInvalid("getRT0velocityValuesFluxRep_arbitraryElementMembership", 1, 7, 7, 4); __PYX_ERR(0, 670, __pyx_L3_error)
7994  }
7995  CYTHON_FALLTHROUGH;
7996  case 5:
7997  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rt0vdofs_element)) != 0)) kw_args--;
7998  else {
7999  __Pyx_RaiseArgtupleInvalid("getRT0velocityValuesFluxRep_arbitraryElementMembership", 1, 7, 7, 5); __PYX_ERR(0, 670, __pyx_L3_error)
8000  }
8001  CYTHON_FALLTHROUGH;
8002  case 6:
8003  if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_v_element)) != 0)) kw_args--;
8004  else {
8005  __Pyx_RaiseArgtupleInvalid("getRT0velocityValuesFluxRep_arbitraryElementMembership", 1, 7, 7, 6); __PYX_ERR(0, 670, __pyx_L3_error)
8006  }
8007  }
8008  if (unlikely(kw_args > 0)) {
8009  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "getRT0velocityValuesFluxRep_arbitraryElementMembership") < 0)) __PYX_ERR(0, 670, __pyx_L3_error)
8010  }
8011  } else if (PyTuple_GET_SIZE(__pyx_args) != 7) {
8012  goto __pyx_L5_argtuple_error;
8013  } else {
8014  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
8015  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
8016  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
8017  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
8018  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
8019  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
8020  values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
8021  }
8022  __pyx_v_nodeArray = ((PyArrayObject *)values[0]);
8023  __pyx_v_elementNodesArray = ((PyArrayObject *)values[1]);
8024  __pyx_v_abs_det_J = ((PyArrayObject *)values[2]);
8025  __pyx_v_x = ((PyArrayObject *)values[3]);
8026  __pyx_v_element_locations = ((PyArrayObject *)values[4]);
8027  __pyx_v_rt0vdofs_element = ((PyArrayObject *)values[5]);
8028  __pyx_v_v_element = ((PyArrayObject *)values[6]);
8029  }
8030  goto __pyx_L4_argument_unpacking_done;
8031  __pyx_L5_argtuple_error:;
8032  __Pyx_RaiseArgtupleInvalid("getRT0velocityValuesFluxRep_arbitraryElementMembership", 1, 7, 7, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 670, __pyx_L3_error)
8033  __pyx_L3_error:;
8034  __Pyx_AddTraceback("cpostprocessing.getRT0velocityValuesFluxRep_arbitraryElementMembership", __pyx_clineno, __pyx_lineno, __pyx_filename);
8035  __Pyx_RefNannyFinishContext();
8036  return NULL;
8037  __pyx_L4_argument_unpacking_done:;
8038  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeArray), __pyx_ptype_5numpy_ndarray, 1, "nodeArray", 0))) __PYX_ERR(0, 670, __pyx_L1_error)
8039  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementNodesArray), __pyx_ptype_5numpy_ndarray, 1, "elementNodesArray", 0))) __PYX_ERR(0, 671, __pyx_L1_error)
8040  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_abs_det_J), __pyx_ptype_5numpy_ndarray, 1, "abs_det_J", 0))) __PYX_ERR(0, 672, __pyx_L1_error)
8041  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x), __pyx_ptype_5numpy_ndarray, 1, "x", 0))) __PYX_ERR(0, 673, __pyx_L1_error)
8042  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_element_locations), __pyx_ptype_5numpy_ndarray, 1, "element_locations", 0))) __PYX_ERR(0, 674, __pyx_L1_error)
8043  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rt0vdofs_element), __pyx_ptype_5numpy_ndarray, 1, "rt0vdofs_element", 0))) __PYX_ERR(0, 675, __pyx_L1_error)
8044  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_v_element), __pyx_ptype_5numpy_ndarray, 1, "v_element", 0))) __PYX_ERR(0, 676, __pyx_L1_error)
8045  __pyx_r = __pyx_pf_15cpostprocessing_60getRT0velocityValuesFluxRep_arbitraryElementMembership(__pyx_self, __pyx_v_nodeArray, __pyx_v_elementNodesArray, __pyx_v_abs_det_J, __pyx_v_x, __pyx_v_element_locations, __pyx_v_rt0vdofs_element, __pyx_v_v_element);
8046 
8047  /* function exit code */
8048  goto __pyx_L0;
8049  __pyx_L1_error:;
8050  __pyx_r = NULL;
8051  __pyx_L0:;
8052  __Pyx_RefNannyFinishContext();
8053  return __pyx_r;
8054 }
8055 
8056 static PyObject *__pyx_pf_15cpostprocessing_60getRT0velocityValuesFluxRep_arbitraryElementMembership(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_nodeArray, PyArrayObject *__pyx_v_elementNodesArray, PyArrayObject *__pyx_v_abs_det_J, PyArrayObject *__pyx_v_x, PyArrayObject *__pyx_v_element_locations, PyArrayObject *__pyx_v_rt0vdofs_element, PyArrayObject *__pyx_v_v_element) {
8057  int __pyx_v_nPoints;
8058  PyObject *__pyx_r = NULL;
8059  __Pyx_RefNannyDeclarations
8060  PyObject *__pyx_t_1 = NULL;
8061  PyObject *__pyx_t_2 = NULL;
8062  PyObject *__pyx_t_3 = NULL;
8063  int __pyx_t_4;
8064  int __pyx_lineno = 0;
8065  const char *__pyx_filename = NULL;
8066  int __pyx_clineno = 0;
8067  __Pyx_RefNannySetupContext("getRT0velocityValuesFluxRep_arbitraryElementMembership", 0);
8068 
8069  /* "cpostprocessing.pyx":677
8070  * np.ndarray rt0vdofs_element,
8071  * np.ndarray v_element):
8072  * cdef int nPoints = x.size/x.shape[x.ndim-1] # <<<<<<<<<<<<<<
8073  * pp.getRT0velocityValuesFluxRep_arbitraryElementMembership(elementNodesArray.shape[0],
8074  * elementNodesArray.shape[1],
8075  */
8076  __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_x), __pyx_n_s_size); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 677, __pyx_L1_error)
8077  __Pyx_GOTREF(__pyx_t_1);
8078  __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, 677, __pyx_L1_error)
8079  __Pyx_GOTREF(__pyx_t_2);
8080  __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 677, __pyx_L1_error)
8081  __Pyx_GOTREF(__pyx_t_3);
8082  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
8083  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
8084  __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3); if (unlikely((__pyx_t_4 == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 677, __pyx_L1_error)
8085  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
8086  __pyx_v_nPoints = __pyx_t_4;
8087 
8088  /* "cpostprocessing.pyx":678
8089  * np.ndarray v_element):
8090  * cdef int nPoints = x.size/x.shape[x.ndim-1]
8091  * pp.getRT0velocityValuesFluxRep_arbitraryElementMembership(elementNodesArray.shape[0], # <<<<<<<<<<<<<<
8092  * elementNodesArray.shape[1],
8093  * nPoints,
8094  */
8095  getRT0velocityValuesFluxRep_arbitraryElementMembership((__pyx_v_elementNodesArray->dimensions[0]), (__pyx_v_elementNodesArray->dimensions[1]), __pyx_v_nPoints, (__pyx_v_v_element->dimensions[1]), (__pyx_v_abs_det_J->dimensions[1]), ((double *)__pyx_v_nodeArray->data), ((int *)__pyx_v_elementNodesArray->data), ((double *)__pyx_v_abs_det_J->data), ((double *)__pyx_v_x->data), ((int *)__pyx_v_element_locations->data), ((double *)__pyx_v_rt0vdofs_element->data), ((double *)__pyx_v_v_element->data));
8096 
8097  /* "cpostprocessing.pyx":670
8098  * <double*>(v_ebqe.data))
8099  *
8100  * def getRT0velocityValuesFluxRep_arbitraryElementMembership(np.ndarray nodeArray, # <<<<<<<<<<<<<<
8101  * np.ndarray elementNodesArray,
8102  * np.ndarray abs_det_J,
8103  */
8104 
8105  /* function exit code */
8106  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
8107  goto __pyx_L0;
8108  __pyx_L1_error:;
8109  __Pyx_XDECREF(__pyx_t_1);
8110  __Pyx_XDECREF(__pyx_t_2);
8111  __Pyx_XDECREF(__pyx_t_3);
8112  __Pyx_AddTraceback("cpostprocessing.getRT0velocityValuesFluxRep_arbitraryElementMembership", __pyx_clineno, __pyx_lineno, __pyx_filename);
8113  __pyx_r = NULL;
8114  __pyx_L0:;
8115  __Pyx_XGIVEREF(__pyx_r);
8116  __Pyx_RefNannyFinishContext();
8117  return __pyx_r;
8118 }
8119 
8120 /* "cpostprocessing.pyx":691
8121  * <double*>(v_element.data))
8122  *
8123  * def fluxCorrectionVelocityUpdate(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
8124  * np.ndarray exteriorElementBoundaries,
8125  * np.ndarray elementBoundaryElements,
8126  */
8127 
8128 /* Python wrapper */
8129 static PyObject *__pyx_pw_15cpostprocessing_63fluxCorrectionVelocityUpdate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
8130 static PyMethodDef __pyx_mdef_15cpostprocessing_63fluxCorrectionVelocityUpdate = {"fluxCorrectionVelocityUpdate", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_63fluxCorrectionVelocityUpdate, METH_VARARGS|METH_KEYWORDS, 0};
8131 static PyObject *__pyx_pw_15cpostprocessing_63fluxCorrectionVelocityUpdate(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
8132  PyArrayObject *__pyx_v_interiorElementBoundaries = 0;
8133  PyArrayObject *__pyx_v_exteriorElementBoundaries = 0;
8134  PyArrayObject *__pyx_v_elementBoundaryElements = 0;
8135  PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries = 0;
8136  PyArrayObject *__pyx_v_dS = 0;
8137  PyArrayObject *__pyx_v_n = 0;
8138  PyArrayObject *__pyx_v_fluxCorrection = 0;
8139  PyArrayObject *__pyx_v_velocity = 0;
8140  PyArrayObject *__pyx_v_velocity_element = 0;
8141  int __pyx_lineno = 0;
8142  const char *__pyx_filename = NULL;
8143  int __pyx_clineno = 0;
8144  PyObject *__pyx_r = 0;
8145  __Pyx_RefNannyDeclarations
8146  __Pyx_RefNannySetupContext("fluxCorrectionVelocityUpdate (wrapper)", 0);
8147  {
8148  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_interiorElementBoundaries,&__pyx_n_s_exteriorElementBoundaries,&__pyx_n_s_elementBoundaryElements,&__pyx_n_s_elementBoundaryLocalElementBound,&__pyx_n_s_dS,&__pyx_n_s_n,&__pyx_n_s_fluxCorrection,&__pyx_n_s_velocity,&__pyx_n_s_velocity_element,0};
8149  PyObject* values[9] = {0,0,0,0,0,0,0,0,0};
8150  if (unlikely(__pyx_kwds)) {
8151  Py_ssize_t kw_args;
8152  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
8153  switch (pos_args) {
8154  case 9: values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
8155  CYTHON_FALLTHROUGH;
8156  case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
8157  CYTHON_FALLTHROUGH;
8158  case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
8159  CYTHON_FALLTHROUGH;
8160  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
8161  CYTHON_FALLTHROUGH;
8162  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
8163  CYTHON_FALLTHROUGH;
8164  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
8165  CYTHON_FALLTHROUGH;
8166  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
8167  CYTHON_FALLTHROUGH;
8168  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
8169  CYTHON_FALLTHROUGH;
8170  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
8171  CYTHON_FALLTHROUGH;
8172  case 0: break;
8173  default: goto __pyx_L5_argtuple_error;
8174  }
8175  kw_args = PyDict_Size(__pyx_kwds);
8176  switch (pos_args) {
8177  case 0:
8178  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_interiorElementBoundaries)) != 0)) kw_args--;
8179  else goto __pyx_L5_argtuple_error;
8180  CYTHON_FALLTHROUGH;
8181  case 1:
8182  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_exteriorElementBoundaries)) != 0)) kw_args--;
8183  else {
8184  __Pyx_RaiseArgtupleInvalid("fluxCorrectionVelocityUpdate", 1, 9, 9, 1); __PYX_ERR(0, 691, __pyx_L3_error)
8185  }
8186  CYTHON_FALLTHROUGH;
8187  case 2:
8188  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryElements)) != 0)) kw_args--;
8189  else {
8190  __Pyx_RaiseArgtupleInvalid("fluxCorrectionVelocityUpdate", 1, 9, 9, 2); __PYX_ERR(0, 691, __pyx_L3_error)
8191  }
8192  CYTHON_FALLTHROUGH;
8193  case 3:
8194  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryLocalElementBound)) != 0)) kw_args--;
8195  else {
8196  __Pyx_RaiseArgtupleInvalid("fluxCorrectionVelocityUpdate", 1, 9, 9, 3); __PYX_ERR(0, 691, __pyx_L3_error)
8197  }
8198  CYTHON_FALLTHROUGH;
8199  case 4:
8200  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_dS)) != 0)) kw_args--;
8201  else {
8202  __Pyx_RaiseArgtupleInvalid("fluxCorrectionVelocityUpdate", 1, 9, 9, 4); __PYX_ERR(0, 691, __pyx_L3_error)
8203  }
8204  CYTHON_FALLTHROUGH;
8205  case 5:
8206  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_n)) != 0)) kw_args--;
8207  else {
8208  __Pyx_RaiseArgtupleInvalid("fluxCorrectionVelocityUpdate", 1, 9, 9, 5); __PYX_ERR(0, 691, __pyx_L3_error)
8209  }
8210  CYTHON_FALLTHROUGH;
8211  case 6:
8212  if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_fluxCorrection)) != 0)) kw_args--;
8213  else {
8214  __Pyx_RaiseArgtupleInvalid("fluxCorrectionVelocityUpdate", 1, 9, 9, 6); __PYX_ERR(0, 691, __pyx_L3_error)
8215  }
8216  CYTHON_FALLTHROUGH;
8217  case 7:
8218  if (likely((values[7] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_velocity)) != 0)) kw_args--;
8219  else {
8220  __Pyx_RaiseArgtupleInvalid("fluxCorrectionVelocityUpdate", 1, 9, 9, 7); __PYX_ERR(0, 691, __pyx_L3_error)
8221  }
8222  CYTHON_FALLTHROUGH;
8223  case 8:
8224  if (likely((values[8] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_velocity_element)) != 0)) kw_args--;
8225  else {
8226  __Pyx_RaiseArgtupleInvalid("fluxCorrectionVelocityUpdate", 1, 9, 9, 8); __PYX_ERR(0, 691, __pyx_L3_error)
8227  }
8228  }
8229  if (unlikely(kw_args > 0)) {
8230  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "fluxCorrectionVelocityUpdate") < 0)) __PYX_ERR(0, 691, __pyx_L3_error)
8231  }
8232  } else if (PyTuple_GET_SIZE(__pyx_args) != 9) {
8233  goto __pyx_L5_argtuple_error;
8234  } else {
8235  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
8236  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
8237  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
8238  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
8239  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
8240  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
8241  values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
8242  values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
8243  values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
8244  }
8245  __pyx_v_interiorElementBoundaries = ((PyArrayObject *)values[0]);
8246  __pyx_v_exteriorElementBoundaries = ((PyArrayObject *)values[1]);
8247  __pyx_v_elementBoundaryElements = ((PyArrayObject *)values[2]);
8248  __pyx_v_elementBoundaryLocalElementBoundaries = ((PyArrayObject *)values[3]);
8249  __pyx_v_dS = ((PyArrayObject *)values[4]);
8250  __pyx_v_n = ((PyArrayObject *)values[5]);
8251  __pyx_v_fluxCorrection = ((PyArrayObject *)values[6]);
8252  __pyx_v_velocity = ((PyArrayObject *)values[7]);
8253  __pyx_v_velocity_element = ((PyArrayObject *)values[8]);
8254  }
8255  goto __pyx_L4_argument_unpacking_done;
8256  __pyx_L5_argtuple_error:;
8257  __Pyx_RaiseArgtupleInvalid("fluxCorrectionVelocityUpdate", 1, 9, 9, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 691, __pyx_L3_error)
8258  __pyx_L3_error:;
8259  __Pyx_AddTraceback("cpostprocessing.fluxCorrectionVelocityUpdate", __pyx_clineno, __pyx_lineno, __pyx_filename);
8260  __Pyx_RefNannyFinishContext();
8261  return NULL;
8262  __pyx_L4_argument_unpacking_done:;
8263  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_interiorElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "interiorElementBoundaries", 0))) __PYX_ERR(0, 691, __pyx_L1_error)
8264  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_exteriorElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "exteriorElementBoundaries", 0))) __PYX_ERR(0, 692, __pyx_L1_error)
8265  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryElements), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryElements", 0))) __PYX_ERR(0, 693, __pyx_L1_error)
8266  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryLocalElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryLocalElementBoundaries", 0))) __PYX_ERR(0, 694, __pyx_L1_error)
8267  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dS), __pyx_ptype_5numpy_ndarray, 1, "dS", 0))) __PYX_ERR(0, 695, __pyx_L1_error)
8268  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_n), __pyx_ptype_5numpy_ndarray, 1, "n", 0))) __PYX_ERR(0, 696, __pyx_L1_error)
8269  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_fluxCorrection), __pyx_ptype_5numpy_ndarray, 1, "fluxCorrection", 0))) __PYX_ERR(0, 697, __pyx_L1_error)
8270  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_velocity), __pyx_ptype_5numpy_ndarray, 1, "velocity", 0))) __PYX_ERR(0, 698, __pyx_L1_error)
8271  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_velocity_element), __pyx_ptype_5numpy_ndarray, 1, "velocity_element", 0))) __PYX_ERR(0, 699, __pyx_L1_error)
8272  __pyx_r = __pyx_pf_15cpostprocessing_62fluxCorrectionVelocityUpdate(__pyx_self, __pyx_v_interiorElementBoundaries, __pyx_v_exteriorElementBoundaries, __pyx_v_elementBoundaryElements, __pyx_v_elementBoundaryLocalElementBoundaries, __pyx_v_dS, __pyx_v_n, __pyx_v_fluxCorrection, __pyx_v_velocity, __pyx_v_velocity_element);
8273 
8274  /* function exit code */
8275  goto __pyx_L0;
8276  __pyx_L1_error:;
8277  __pyx_r = NULL;
8278  __pyx_L0:;
8279  __Pyx_RefNannyFinishContext();
8280  return __pyx_r;
8281 }
8282 
8283 static PyObject *__pyx_pf_15cpostprocessing_62fluxCorrectionVelocityUpdate(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_interiorElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries, PyArrayObject *__pyx_v_dS, PyArrayObject *__pyx_v_n, PyArrayObject *__pyx_v_fluxCorrection, PyArrayObject *__pyx_v_velocity, PyArrayObject *__pyx_v_velocity_element) {
8284  PyObject *__pyx_r = NULL;
8285  __Pyx_RefNannyDeclarations
8286  __Pyx_RefNannySetupContext("fluxCorrectionVelocityUpdate", 0);
8287 
8288  /* "cpostprocessing.pyx":700
8289  * np.ndarray velocity,
8290  * np.ndarray velocity_element):
8291  * pp.fluxCorrectionVelocityUpdate(dS.shape[0], # <<<<<<<<<<<<<<
8292  * velocity.shape[0],
8293  * interiorElementBoundaries.shape[0],
8294  */
8295  fluxCorrectionVelocityUpdate((__pyx_v_dS->dimensions[0]), (__pyx_v_velocity->dimensions[0]), (__pyx_v_interiorElementBoundaries->dimensions[0]), (__pyx_v_exteriorElementBoundaries->dimensions[0]), (__pyx_v_dS->dimensions[1]), (__pyx_v_dS->dimensions[2]), (__pyx_v_velocity->dimensions[2]), ((int *)__pyx_v_interiorElementBoundaries->data), ((int *)__pyx_v_exteriorElementBoundaries->data), ((int *)__pyx_v_elementBoundaryElements->data), ((int *)__pyx_v_elementBoundaryLocalElementBoundaries->data), ((double *)__pyx_v_dS->data), ((double *)__pyx_v_n->data), ((double *)__pyx_v_fluxCorrection->data), ((double *)__pyx_v_velocity->data), ((double *)__pyx_v_velocity_element->data));
8296 
8297  /* "cpostprocessing.pyx":691
8298  * <double*>(v_element.data))
8299  *
8300  * def fluxCorrectionVelocityUpdate(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
8301  * np.ndarray exteriorElementBoundaries,
8302  * np.ndarray elementBoundaryElements,
8303  */
8304 
8305  /* function exit code */
8306  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
8307  __Pyx_XGIVEREF(__pyx_r);
8308  __Pyx_RefNannyFinishContext();
8309  return __pyx_r;
8310 }
8311 
8312 /* "cpostprocessing.pyx":717
8313  * <double*>(velocity_element.data))
8314  *
8315  * def computeFluxCorrectionPWC(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
8316  * np.ndarray exteriorElementBoundaries,
8317  * np.ndarray elementBoundaryElements,
8318  */
8319 
8320 /* Python wrapper */
8321 static PyObject *__pyx_pw_15cpostprocessing_65computeFluxCorrectionPWC(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
8322 static PyMethodDef __pyx_mdef_15cpostprocessing_65computeFluxCorrectionPWC = {"computeFluxCorrectionPWC", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_65computeFluxCorrectionPWC, METH_VARARGS|METH_KEYWORDS, 0};
8323 static PyObject *__pyx_pw_15cpostprocessing_65computeFluxCorrectionPWC(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
8324  PyArrayObject *__pyx_v_interiorElementBoundaries = 0;
8325  PyArrayObject *__pyx_v_exteriorElementBoundaries = 0;
8326  PyArrayObject *__pyx_v_elementBoundaryElements = 0;
8327  PyArrayObject *__pyx_v_pwcW = 0;
8328  PyArrayObject *__pyx_v_pwcV = 0;
8329  PyArrayObject *__pyx_v_fluxCorrection = 0;
8330  int __pyx_lineno = 0;
8331  const char *__pyx_filename = NULL;
8332  int __pyx_clineno = 0;
8333  PyObject *__pyx_r = 0;
8334  __Pyx_RefNannyDeclarations
8335  __Pyx_RefNannySetupContext("computeFluxCorrectionPWC (wrapper)", 0);
8336  {
8337  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_interiorElementBoundaries,&__pyx_n_s_exteriorElementBoundaries,&__pyx_n_s_elementBoundaryElements,&__pyx_n_s_pwcW,&__pyx_n_s_pwcV,&__pyx_n_s_fluxCorrection,0};
8338  PyObject* values[6] = {0,0,0,0,0,0};
8339  if (unlikely(__pyx_kwds)) {
8340  Py_ssize_t kw_args;
8341  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
8342  switch (pos_args) {
8343  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
8344  CYTHON_FALLTHROUGH;
8345  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
8346  CYTHON_FALLTHROUGH;
8347  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
8348  CYTHON_FALLTHROUGH;
8349  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
8350  CYTHON_FALLTHROUGH;
8351  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
8352  CYTHON_FALLTHROUGH;
8353  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
8354  CYTHON_FALLTHROUGH;
8355  case 0: break;
8356  default: goto __pyx_L5_argtuple_error;
8357  }
8358  kw_args = PyDict_Size(__pyx_kwds);
8359  switch (pos_args) {
8360  case 0:
8361  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_interiorElementBoundaries)) != 0)) kw_args--;
8362  else goto __pyx_L5_argtuple_error;
8363  CYTHON_FALLTHROUGH;
8364  case 1:
8365  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_exteriorElementBoundaries)) != 0)) kw_args--;
8366  else {
8367  __Pyx_RaiseArgtupleInvalid("computeFluxCorrectionPWC", 1, 6, 6, 1); __PYX_ERR(0, 717, __pyx_L3_error)
8368  }
8369  CYTHON_FALLTHROUGH;
8370  case 2:
8371  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryElements)) != 0)) kw_args--;
8372  else {
8373  __Pyx_RaiseArgtupleInvalid("computeFluxCorrectionPWC", 1, 6, 6, 2); __PYX_ERR(0, 717, __pyx_L3_error)
8374  }
8375  CYTHON_FALLTHROUGH;
8376  case 3:
8377  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_pwcW)) != 0)) kw_args--;
8378  else {
8379  __Pyx_RaiseArgtupleInvalid("computeFluxCorrectionPWC", 1, 6, 6, 3); __PYX_ERR(0, 717, __pyx_L3_error)
8380  }
8381  CYTHON_FALLTHROUGH;
8382  case 4:
8383  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_pwcV)) != 0)) kw_args--;
8384  else {
8385  __Pyx_RaiseArgtupleInvalid("computeFluxCorrectionPWC", 1, 6, 6, 4); __PYX_ERR(0, 717, __pyx_L3_error)
8386  }
8387  CYTHON_FALLTHROUGH;
8388  case 5:
8389  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_fluxCorrection)) != 0)) kw_args--;
8390  else {
8391  __Pyx_RaiseArgtupleInvalid("computeFluxCorrectionPWC", 1, 6, 6, 5); __PYX_ERR(0, 717, __pyx_L3_error)
8392  }
8393  }
8394  if (unlikely(kw_args > 0)) {
8395  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "computeFluxCorrectionPWC") < 0)) __PYX_ERR(0, 717, __pyx_L3_error)
8396  }
8397  } else if (PyTuple_GET_SIZE(__pyx_args) != 6) {
8398  goto __pyx_L5_argtuple_error;
8399  } else {
8400  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
8401  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
8402  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
8403  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
8404  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
8405  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
8406  }
8407  __pyx_v_interiorElementBoundaries = ((PyArrayObject *)values[0]);
8408  __pyx_v_exteriorElementBoundaries = ((PyArrayObject *)values[1]);
8409  __pyx_v_elementBoundaryElements = ((PyArrayObject *)values[2]);
8410  __pyx_v_pwcW = ((PyArrayObject *)values[3]);
8411  __pyx_v_pwcV = ((PyArrayObject *)values[4]);
8412  __pyx_v_fluxCorrection = ((PyArrayObject *)values[5]);
8413  }
8414  goto __pyx_L4_argument_unpacking_done;
8415  __pyx_L5_argtuple_error:;
8416  __Pyx_RaiseArgtupleInvalid("computeFluxCorrectionPWC", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 717, __pyx_L3_error)
8417  __pyx_L3_error:;
8418  __Pyx_AddTraceback("cpostprocessing.computeFluxCorrectionPWC", __pyx_clineno, __pyx_lineno, __pyx_filename);
8419  __Pyx_RefNannyFinishContext();
8420  return NULL;
8421  __pyx_L4_argument_unpacking_done:;
8422  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_interiorElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "interiorElementBoundaries", 0))) __PYX_ERR(0, 717, __pyx_L1_error)
8423  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_exteriorElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "exteriorElementBoundaries", 0))) __PYX_ERR(0, 718, __pyx_L1_error)
8424  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryElements), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryElements", 0))) __PYX_ERR(0, 719, __pyx_L1_error)
8425  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_pwcW), __pyx_ptype_5numpy_ndarray, 1, "pwcW", 0))) __PYX_ERR(0, 720, __pyx_L1_error)
8426  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_pwcV), __pyx_ptype_5numpy_ndarray, 1, "pwcV", 0))) __PYX_ERR(0, 721, __pyx_L1_error)
8427  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_fluxCorrection), __pyx_ptype_5numpy_ndarray, 1, "fluxCorrection", 0))) __PYX_ERR(0, 722, __pyx_L1_error)
8428  __pyx_r = __pyx_pf_15cpostprocessing_64computeFluxCorrectionPWC(__pyx_self, __pyx_v_interiorElementBoundaries, __pyx_v_exteriorElementBoundaries, __pyx_v_elementBoundaryElements, __pyx_v_pwcW, __pyx_v_pwcV, __pyx_v_fluxCorrection);
8429 
8430  /* function exit code */
8431  goto __pyx_L0;
8432  __pyx_L1_error:;
8433  __pyx_r = NULL;
8434  __pyx_L0:;
8435  __Pyx_RefNannyFinishContext();
8436  return __pyx_r;
8437 }
8438 
8439 static PyObject *__pyx_pf_15cpostprocessing_64computeFluxCorrectionPWC(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_interiorElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_pwcW, PyArrayObject *__pyx_v_pwcV, PyArrayObject *__pyx_v_fluxCorrection) {
8440  PyObject *__pyx_r = NULL;
8441  __Pyx_RefNannyDeclarations
8442  __Pyx_RefNannySetupContext("computeFluxCorrectionPWC", 0);
8443 
8444  /* "cpostprocessing.pyx":723
8445  * np.ndarray pwcV,
8446  * np.ndarray fluxCorrection):
8447  * pp.computeFluxCorrectionPWC(elementBoundaryElements.shape[0], # <<<<<<<<<<<<<<
8448  * interiorElementBoundaries.shape[0],
8449  * exteriorElementBoundaries.shape[0],
8450  */
8451  computeFluxCorrectionPWC((__pyx_v_elementBoundaryElements->dimensions[0]), (__pyx_v_interiorElementBoundaries->dimensions[0]), (__pyx_v_exteriorElementBoundaries->dimensions[0]), ((int *)__pyx_v_interiorElementBoundaries->data), ((int *)__pyx_v_exteriorElementBoundaries->data), ((int *)__pyx_v_elementBoundaryElements->data), ((double *)__pyx_v_pwcW->data), ((double *)__pyx_v_pwcV->data), ((double *)__pyx_v_fluxCorrection->data));
8452 
8453  /* "cpostprocessing.pyx":717
8454  * <double*>(velocity_element.data))
8455  *
8456  * def computeFluxCorrectionPWC(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
8457  * np.ndarray exteriorElementBoundaries,
8458  * np.ndarray elementBoundaryElements,
8459  */
8460 
8461  /* function exit code */
8462  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
8463  __Pyx_XGIVEREF(__pyx_r);
8464  __Pyx_RefNannyFinishContext();
8465  return __pyx_r;
8466 }
8467 
8468 /* "cpostprocessing.pyx":733
8469  * <double*>(fluxCorrection.data))
8470  *
8471  * def sunWheelerGSsweep(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
8472  * np.ndarray exteriorElementBoundaries,
8473  * np.ndarray elementBoundaryElements,
8474  */
8475 
8476 /* Python wrapper */
8477 static PyObject *__pyx_pw_15cpostprocessing_67sunWheelerGSsweep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
8478 static PyMethodDef __pyx_mdef_15cpostprocessing_67sunWheelerGSsweep = {"sunWheelerGSsweep", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_67sunWheelerGSsweep, METH_VARARGS|METH_KEYWORDS, 0};
8479 static PyObject *__pyx_pw_15cpostprocessing_67sunWheelerGSsweep(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
8480  PyArrayObject *__pyx_v_interiorElementBoundaries = 0;
8481  PyArrayObject *__pyx_v_exteriorElementBoundaries = 0;
8482  PyArrayObject *__pyx_v_elementBoundaryElements = 0;
8483  PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries = 0;
8484  PyArrayObject *__pyx_v_dS = 0;
8485  PyArrayObject *__pyx_v_n = 0;
8486  PyArrayObject *__pyx_v_sqrt_det_g = 0;
8487  PyArrayObject *__pyx_v_alphaFactor = 0;
8488  PyArrayObject *__pyx_v_fluxCorrection = 0;
8489  PyArrayObject *__pyx_v_conservationResidual = 0;
8490  int __pyx_lineno = 0;
8491  const char *__pyx_filename = NULL;
8492  int __pyx_clineno = 0;
8493  PyObject *__pyx_r = 0;
8494  __Pyx_RefNannyDeclarations
8495  __Pyx_RefNannySetupContext("sunWheelerGSsweep (wrapper)", 0);
8496  {
8497  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_interiorElementBoundaries,&__pyx_n_s_exteriorElementBoundaries,&__pyx_n_s_elementBoundaryElements,&__pyx_n_s_elementBoundaryLocalElementBound,&__pyx_n_s_dS,&__pyx_n_s_n,&__pyx_n_s_sqrt_det_g,&__pyx_n_s_alphaFactor,&__pyx_n_s_fluxCorrection,&__pyx_n_s_conservationResidual,0};
8498  PyObject* values[10] = {0,0,0,0,0,0,0,0,0,0};
8499  if (unlikely(__pyx_kwds)) {
8500  Py_ssize_t kw_args;
8501  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
8502  switch (pos_args) {
8503  case 10: values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
8504  CYTHON_FALLTHROUGH;
8505  case 9: values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
8506  CYTHON_FALLTHROUGH;
8507  case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
8508  CYTHON_FALLTHROUGH;
8509  case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
8510  CYTHON_FALLTHROUGH;
8511  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
8512  CYTHON_FALLTHROUGH;
8513  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
8514  CYTHON_FALLTHROUGH;
8515  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
8516  CYTHON_FALLTHROUGH;
8517  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
8518  CYTHON_FALLTHROUGH;
8519  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
8520  CYTHON_FALLTHROUGH;
8521  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
8522  CYTHON_FALLTHROUGH;
8523  case 0: break;
8524  default: goto __pyx_L5_argtuple_error;
8525  }
8526  kw_args = PyDict_Size(__pyx_kwds);
8527  switch (pos_args) {
8528  case 0:
8529  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_interiorElementBoundaries)) != 0)) kw_args--;
8530  else goto __pyx_L5_argtuple_error;
8531  CYTHON_FALLTHROUGH;
8532  case 1:
8533  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_exteriorElementBoundaries)) != 0)) kw_args--;
8534  else {
8535  __Pyx_RaiseArgtupleInvalid("sunWheelerGSsweep", 1, 10, 10, 1); __PYX_ERR(0, 733, __pyx_L3_error)
8536  }
8537  CYTHON_FALLTHROUGH;
8538  case 2:
8539  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryElements)) != 0)) kw_args--;
8540  else {
8541  __Pyx_RaiseArgtupleInvalid("sunWheelerGSsweep", 1, 10, 10, 2); __PYX_ERR(0, 733, __pyx_L3_error)
8542  }
8543  CYTHON_FALLTHROUGH;
8544  case 3:
8545  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryLocalElementBound)) != 0)) kw_args--;
8546  else {
8547  __Pyx_RaiseArgtupleInvalid("sunWheelerGSsweep", 1, 10, 10, 3); __PYX_ERR(0, 733, __pyx_L3_error)
8548  }
8549  CYTHON_FALLTHROUGH;
8550  case 4:
8551  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_dS)) != 0)) kw_args--;
8552  else {
8553  __Pyx_RaiseArgtupleInvalid("sunWheelerGSsweep", 1, 10, 10, 4); __PYX_ERR(0, 733, __pyx_L3_error)
8554  }
8555  CYTHON_FALLTHROUGH;
8556  case 5:
8557  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_n)) != 0)) kw_args--;
8558  else {
8559  __Pyx_RaiseArgtupleInvalid("sunWheelerGSsweep", 1, 10, 10, 5); __PYX_ERR(0, 733, __pyx_L3_error)
8560  }
8561  CYTHON_FALLTHROUGH;
8562  case 6:
8563  if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_sqrt_det_g)) != 0)) kw_args--;
8564  else {
8565  __Pyx_RaiseArgtupleInvalid("sunWheelerGSsweep", 1, 10, 10, 6); __PYX_ERR(0, 733, __pyx_L3_error)
8566  }
8567  CYTHON_FALLTHROUGH;
8568  case 7:
8569  if (likely((values[7] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_alphaFactor)) != 0)) kw_args--;
8570  else {
8571  __Pyx_RaiseArgtupleInvalid("sunWheelerGSsweep", 1, 10, 10, 7); __PYX_ERR(0, 733, __pyx_L3_error)
8572  }
8573  CYTHON_FALLTHROUGH;
8574  case 8:
8575  if (likely((values[8] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_fluxCorrection)) != 0)) kw_args--;
8576  else {
8577  __Pyx_RaiseArgtupleInvalid("sunWheelerGSsweep", 1, 10, 10, 8); __PYX_ERR(0, 733, __pyx_L3_error)
8578  }
8579  CYTHON_FALLTHROUGH;
8580  case 9:
8581  if (likely((values[9] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_conservationResidual)) != 0)) kw_args--;
8582  else {
8583  __Pyx_RaiseArgtupleInvalid("sunWheelerGSsweep", 1, 10, 10, 9); __PYX_ERR(0, 733, __pyx_L3_error)
8584  }
8585  }
8586  if (unlikely(kw_args > 0)) {
8587  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "sunWheelerGSsweep") < 0)) __PYX_ERR(0, 733, __pyx_L3_error)
8588  }
8589  } else if (PyTuple_GET_SIZE(__pyx_args) != 10) {
8590  goto __pyx_L5_argtuple_error;
8591  } else {
8592  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
8593  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
8594  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
8595  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
8596  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
8597  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
8598  values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
8599  values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
8600  values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
8601  values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
8602  }
8603  __pyx_v_interiorElementBoundaries = ((PyArrayObject *)values[0]);
8604  __pyx_v_exteriorElementBoundaries = ((PyArrayObject *)values[1]);
8605  __pyx_v_elementBoundaryElements = ((PyArrayObject *)values[2]);
8606  __pyx_v_elementBoundaryLocalElementBoundaries = ((PyArrayObject *)values[3]);
8607  __pyx_v_dS = ((PyArrayObject *)values[4]);
8608  __pyx_v_n = ((PyArrayObject *)values[5]);
8609  __pyx_v_sqrt_det_g = ((PyArrayObject *)values[6]);
8610  __pyx_v_alphaFactor = ((PyArrayObject *)values[7]);
8611  __pyx_v_fluxCorrection = ((PyArrayObject *)values[8]);
8612  __pyx_v_conservationResidual = ((PyArrayObject *)values[9]);
8613  }
8614  goto __pyx_L4_argument_unpacking_done;
8615  __pyx_L5_argtuple_error:;
8616  __Pyx_RaiseArgtupleInvalid("sunWheelerGSsweep", 1, 10, 10, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 733, __pyx_L3_error)
8617  __pyx_L3_error:;
8618  __Pyx_AddTraceback("cpostprocessing.sunWheelerGSsweep", __pyx_clineno, __pyx_lineno, __pyx_filename);
8619  __Pyx_RefNannyFinishContext();
8620  return NULL;
8621  __pyx_L4_argument_unpacking_done:;
8622  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_interiorElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "interiorElementBoundaries", 0))) __PYX_ERR(0, 733, __pyx_L1_error)
8623  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_exteriorElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "exteriorElementBoundaries", 0))) __PYX_ERR(0, 734, __pyx_L1_error)
8624  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryElements), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryElements", 0))) __PYX_ERR(0, 735, __pyx_L1_error)
8625  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryLocalElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryLocalElementBoundaries", 0))) __PYX_ERR(0, 736, __pyx_L1_error)
8626  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dS), __pyx_ptype_5numpy_ndarray, 1, "dS", 0))) __PYX_ERR(0, 737, __pyx_L1_error)
8627  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_n), __pyx_ptype_5numpy_ndarray, 1, "n", 0))) __PYX_ERR(0, 738, __pyx_L1_error)
8628  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_sqrt_det_g), __pyx_ptype_5numpy_ndarray, 1, "sqrt_det_g", 0))) __PYX_ERR(0, 739, __pyx_L1_error)
8629  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_alphaFactor), __pyx_ptype_5numpy_ndarray, 1, "alphaFactor", 0))) __PYX_ERR(0, 740, __pyx_L1_error)
8630  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_fluxCorrection), __pyx_ptype_5numpy_ndarray, 1, "fluxCorrection", 0))) __PYX_ERR(0, 741, __pyx_L1_error)
8631  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_conservationResidual), __pyx_ptype_5numpy_ndarray, 1, "conservationResidual", 0))) __PYX_ERR(0, 742, __pyx_L1_error)
8632  __pyx_r = __pyx_pf_15cpostprocessing_66sunWheelerGSsweep(__pyx_self, __pyx_v_interiorElementBoundaries, __pyx_v_exteriorElementBoundaries, __pyx_v_elementBoundaryElements, __pyx_v_elementBoundaryLocalElementBoundaries, __pyx_v_dS, __pyx_v_n, __pyx_v_sqrt_det_g, __pyx_v_alphaFactor, __pyx_v_fluxCorrection, __pyx_v_conservationResidual);
8633 
8634  /* function exit code */
8635  goto __pyx_L0;
8636  __pyx_L1_error:;
8637  __pyx_r = NULL;
8638  __pyx_L0:;
8639  __Pyx_RefNannyFinishContext();
8640  return __pyx_r;
8641 }
8642 
8643 static PyObject *__pyx_pf_15cpostprocessing_66sunWheelerGSsweep(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_interiorElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries, PyArrayObject *__pyx_v_dS, PyArrayObject *__pyx_v_n, PyArrayObject *__pyx_v_sqrt_det_g, PyArrayObject *__pyx_v_alphaFactor, PyArrayObject *__pyx_v_fluxCorrection, PyArrayObject *__pyx_v_conservationResidual) {
8644  PyObject *__pyx_r = NULL;
8645  __Pyx_RefNannyDeclarations
8646  __Pyx_RefNannySetupContext("sunWheelerGSsweep", 0);
8647 
8648  /* "cpostprocessing.pyx":743
8649  * np.ndarray fluxCorrection,
8650  * np.ndarray conservationResidual):
8651  * pp.sunWheelerGSsweep(conservationResidual.shape[0], # <<<<<<<<<<<<<<
8652  * elementBoundaryElements.shape[0],
8653  * interiorElementBoundaries.shape[0],
8654  */
8655  sunWheelerGSsweep((__pyx_v_conservationResidual->dimensions[0]), (__pyx_v_elementBoundaryElements->dimensions[0]), (__pyx_v_interiorElementBoundaries->dimensions[0]), (__pyx_v_exteriorElementBoundaries->dimensions[0]), (__pyx_v_dS->dimensions[1]), (__pyx_v_dS->dimensions[2]), (__pyx_v_n->dimensions[2]), ((int *)__pyx_v_interiorElementBoundaries->data), ((int *)__pyx_v_exteriorElementBoundaries->data), ((int *)__pyx_v_elementBoundaryElements->data), ((int *)__pyx_v_elementBoundaryLocalElementBoundaries->data), ((double *)__pyx_v_dS->data), ((double *)__pyx_v_n->data), ((double *)__pyx_v_sqrt_det_g->data), ((double *)__pyx_v_alphaFactor->data), ((double *)__pyx_v_fluxCorrection->data), ((double *)__pyx_v_conservationResidual->data));
8656 
8657  /* "cpostprocessing.pyx":733
8658  * <double*>(fluxCorrection.data))
8659  *
8660  * def sunWheelerGSsweep(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
8661  * np.ndarray exteriorElementBoundaries,
8662  * np.ndarray elementBoundaryElements,
8663  */
8664 
8665  /* function exit code */
8666  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
8667  __Pyx_XGIVEREF(__pyx_r);
8668  __Pyx_RefNannyFinishContext();
8669  return __pyx_r;
8670 }
8671 
8672 /* "cpostprocessing.pyx":764
8673  * cdef class NodeStarFactor:
8674  * cdef pp.NodeStarFactorStruct nsf
8675  * def __cinit__(self, # <<<<<<<<<<<<<<
8676  * np.ndarray nElements_node,
8677  * np.ndarray nodeStarElementsArray,
8678  */
8679 
8680 /* Python wrapper */
8681 static int __pyx_pw_15cpostprocessing_14NodeStarFactor_1__cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
8682 static int __pyx_pw_15cpostprocessing_14NodeStarFactor_1__cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
8683  PyArrayObject *__pyx_v_nElements_node = 0;
8684  PyArrayObject *__pyx_v_nodeStarElementsArray = 0;
8685  PyArrayObject *__pyx_v_nodeStarElementsNeighborsArray = 0;
8686  int __pyx_lineno = 0;
8687  const char *__pyx_filename = NULL;
8688  int __pyx_clineno = 0;
8689  int __pyx_r;
8690  __Pyx_RefNannyDeclarations
8691  __Pyx_RefNannySetupContext("__cinit__ (wrapper)", 0);
8692  {
8693  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_nElements_node,&__pyx_n_s_nodeStarElementsArray,&__pyx_n_s_nodeStarElementsNeighborsArray,0};
8694  PyObject* values[3] = {0,0,0};
8695  if (unlikely(__pyx_kwds)) {
8696  Py_ssize_t kw_args;
8697  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
8698  switch (pos_args) {
8699  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
8700  CYTHON_FALLTHROUGH;
8701  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
8702  CYTHON_FALLTHROUGH;
8703  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
8704  CYTHON_FALLTHROUGH;
8705  case 0: break;
8706  default: goto __pyx_L5_argtuple_error;
8707  }
8708  kw_args = PyDict_Size(__pyx_kwds);
8709  switch (pos_args) {
8710  case 0:
8711  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nElements_node)) != 0)) kw_args--;
8712  else goto __pyx_L5_argtuple_error;
8713  CYTHON_FALLTHROUGH;
8714  case 1:
8715  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarElementsArray)) != 0)) kw_args--;
8716  else {
8717  __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 3, 3, 1); __PYX_ERR(0, 764, __pyx_L3_error)
8718  }
8719  CYTHON_FALLTHROUGH;
8720  case 2:
8721  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarElementsNeighborsArray)) != 0)) kw_args--;
8722  else {
8723  __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 3, 3, 2); __PYX_ERR(0, 764, __pyx_L3_error)
8724  }
8725  }
8726  if (unlikely(kw_args > 0)) {
8727  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) __PYX_ERR(0, 764, __pyx_L3_error)
8728  }
8729  } else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
8730  goto __pyx_L5_argtuple_error;
8731  } else {
8732  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
8733  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
8734  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
8735  }
8736  __pyx_v_nElements_node = ((PyArrayObject *)values[0]);
8737  __pyx_v_nodeStarElementsArray = ((PyArrayObject *)values[1]);
8738  __pyx_v_nodeStarElementsNeighborsArray = ((PyArrayObject *)values[2]);
8739  }
8740  goto __pyx_L4_argument_unpacking_done;
8741  __pyx_L5_argtuple_error:;
8742  __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 764, __pyx_L3_error)
8743  __pyx_L3_error:;
8744  __Pyx_AddTraceback("cpostprocessing.NodeStarFactor.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8745  __Pyx_RefNannyFinishContext();
8746  return -1;
8747  __pyx_L4_argument_unpacking_done:;
8748  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nElements_node), __pyx_ptype_5numpy_ndarray, 1, "nElements_node", 0))) __PYX_ERR(0, 765, __pyx_L1_error)
8749  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarElementsArray), __pyx_ptype_5numpy_ndarray, 1, "nodeStarElementsArray", 0))) __PYX_ERR(0, 766, __pyx_L1_error)
8750  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarElementsNeighborsArray), __pyx_ptype_5numpy_ndarray, 1, "nodeStarElementsNeighborsArray", 0))) __PYX_ERR(0, 767, __pyx_L1_error)
8751  __pyx_r = __pyx_pf_15cpostprocessing_14NodeStarFactor___cinit__(((struct __pyx_obj_15cpostprocessing_NodeStarFactor *)__pyx_v_self), __pyx_v_nElements_node, __pyx_v_nodeStarElementsArray, __pyx_v_nodeStarElementsNeighborsArray);
8752 
8753  /* function exit code */
8754  goto __pyx_L0;
8755  __pyx_L1_error:;
8756  __pyx_r = -1;
8757  __pyx_L0:;
8758  __Pyx_RefNannyFinishContext();
8759  return __pyx_r;
8760 }
8761 
8762 static int __pyx_pf_15cpostprocessing_14NodeStarFactor___cinit__(struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_self, PyArrayObject *__pyx_v_nElements_node, PyArrayObject *__pyx_v_nodeStarElementsArray, PyArrayObject *__pyx_v_nodeStarElementsNeighborsArray) {
8763  int __pyx_v_rval;
8764  int __pyx_r;
8765  __Pyx_RefNannyDeclarations
8766  int __pyx_lineno = 0;
8767  const char *__pyx_filename = NULL;
8768  int __pyx_clineno = 0;
8769  __Pyx_RefNannySetupContext("__cinit__", 0);
8770 
8771  /* "cpostprocessing.pyx":768
8772  * np.ndarray nodeStarElementsArray,
8773  * np.ndarray nodeStarElementsNeighborsArray):
8774  * cdef int rval=0 # <<<<<<<<<<<<<<
8775  * rval = pp.nodeStar_init(nodeStarElementsArray.shape[0],
8776  * nodeStarElementsArray.shape[1],
8777  */
8778  __pyx_v_rval = 0;
8779 
8780  /* "cpostprocessing.pyx":769
8781  * np.ndarray nodeStarElementsNeighborsArray):
8782  * cdef int rval=0
8783  * rval = pp.nodeStar_init(nodeStarElementsArray.shape[0], # <<<<<<<<<<<<<<
8784  * nodeStarElementsArray.shape[1],
8785  * nElements_node.shape[0],
8786  */
8787  __pyx_v_rval = nodeStar_init((__pyx_v_nodeStarElementsArray->dimensions[0]), (__pyx_v_nodeStarElementsArray->dimensions[1]), (__pyx_v_nElements_node->dimensions[0]), ((int *)__pyx_v_nElements_node->data), ((int *)__pyx_v_nodeStarElementsArray->data), ((int *)__pyx_v_nodeStarElementsNeighborsArray->data), (&__pyx_v_self->nsf.N), (&__pyx_v_self->nsf.subdomain_dim), (&__pyx_v_self->nsf.subdomain_L), (&__pyx_v_self->nsf.subdomain_R), (&__pyx_v_self->nsf.subdomain_U), (&__pyx_v_self->nsf.subdomain_pivots), (&__pyx_v_self->nsf.subdomain_column_pivots));
8788 
8789  /* "cpostprocessing.pyx":782
8790  * &self.nsf.subdomain_pivots,
8791  * &self.nsf.subdomain_column_pivots)
8792  * assert rval == 0 # <<<<<<<<<<<<<<
8793  *
8794  * def __dealloc__(self):
8795  */
8796  #ifndef CYTHON_WITHOUT_ASSERTIONS
8797  if (unlikely(!Py_OptimizeFlag)) {
8798  if (unlikely(!((__pyx_v_rval == 0) != 0))) {
8799  PyErr_SetNone(PyExc_AssertionError);
8800  __PYX_ERR(0, 782, __pyx_L1_error)
8801  }
8802  }
8803  #endif
8804 
8805  /* "cpostprocessing.pyx":764
8806  * cdef class NodeStarFactor:
8807  * cdef pp.NodeStarFactorStruct nsf
8808  * def __cinit__(self, # <<<<<<<<<<<<<<
8809  * np.ndarray nElements_node,
8810  * np.ndarray nodeStarElementsArray,
8811  */
8812 
8813  /* function exit code */
8814  __pyx_r = 0;
8815  goto __pyx_L0;
8816  __pyx_L1_error:;
8817  __Pyx_AddTraceback("cpostprocessing.NodeStarFactor.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8818  __pyx_r = -1;
8819  __pyx_L0:;
8820  __Pyx_RefNannyFinishContext();
8821  return __pyx_r;
8822 }
8823 
8824 /* "cpostprocessing.pyx":784
8825  * assert rval == 0
8826  *
8827  * def __dealloc__(self): # <<<<<<<<<<<<<<
8828  * pp.nodeStar_free(self.nsf.N,
8829  * self.nsf.subdomain_dim,
8830  */
8831 
8832 /* Python wrapper */
8833 static void __pyx_pw_15cpostprocessing_14NodeStarFactor_3__dealloc__(PyObject *__pyx_v_self); /*proto*/
8834 static void __pyx_pw_15cpostprocessing_14NodeStarFactor_3__dealloc__(PyObject *__pyx_v_self) {
8835  __Pyx_RefNannyDeclarations
8836  __Pyx_RefNannySetupContext("__dealloc__ (wrapper)", 0);
8837  __pyx_pf_15cpostprocessing_14NodeStarFactor_2__dealloc__(((struct __pyx_obj_15cpostprocessing_NodeStarFactor *)__pyx_v_self));
8838 
8839  /* function exit code */
8840  __Pyx_RefNannyFinishContext();
8841 }
8842 
8843 static void __pyx_pf_15cpostprocessing_14NodeStarFactor_2__dealloc__(struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_self) {
8844  __Pyx_RefNannyDeclarations
8845  __Pyx_RefNannySetupContext("__dealloc__", 0);
8846 
8847  /* "cpostprocessing.pyx":785
8848  *
8849  * def __dealloc__(self):
8850  * pp.nodeStar_free(self.nsf.N, # <<<<<<<<<<<<<<
8851  * self.nsf.subdomain_dim,
8852  * self.nsf.subdomain_L,
8853  */
8854  (void)(nodeStar_free(__pyx_v_self->nsf.N, __pyx_v_self->nsf.subdomain_dim, __pyx_v_self->nsf.subdomain_L, __pyx_v_self->nsf.subdomain_R, __pyx_v_self->nsf.subdomain_U, __pyx_v_self->nsf.subdomain_pivots, __pyx_v_self->nsf.subdomain_column_pivots));
8855 
8856  /* "cpostprocessing.pyx":784
8857  * assert rval == 0
8858  *
8859  * def __dealloc__(self): # <<<<<<<<<<<<<<
8860  * pp.nodeStar_free(self.nsf.N,
8861  * self.nsf.subdomain_dim,
8862  */
8863 
8864  /* function exit code */
8865  __Pyx_RefNannyFinishContext();
8866 }
8867 
8868 /* "cpostprocessing.pyx":793
8869  * self.nsf.subdomain_column_pivots)
8870  *
8871  * def setU(self, # <<<<<<<<<<<<<<
8872  * double val):
8873  * cdef int I
8874  */
8875 
8876 /* Python wrapper */
8877 static PyObject *__pyx_pw_15cpostprocessing_14NodeStarFactor_5setU(PyObject *__pyx_v_self, PyObject *__pyx_arg_val); /*proto*/
8878 static PyObject *__pyx_pw_15cpostprocessing_14NodeStarFactor_5setU(PyObject *__pyx_v_self, PyObject *__pyx_arg_val) {
8879  double __pyx_v_val;
8880  int __pyx_lineno = 0;
8881  const char *__pyx_filename = NULL;
8882  int __pyx_clineno = 0;
8883  PyObject *__pyx_r = 0;
8884  __Pyx_RefNannyDeclarations
8885  __Pyx_RefNannySetupContext("setU (wrapper)", 0);
8886  assert(__pyx_arg_val); {
8887  __pyx_v_val = __pyx_PyFloat_AsDouble(__pyx_arg_val); if (unlikely((__pyx_v_val == (double)-1) && PyErr_Occurred())) __PYX_ERR(0, 794, __pyx_L3_error)
8888  }
8889  goto __pyx_L4_argument_unpacking_done;
8890  __pyx_L3_error:;
8891  __Pyx_AddTraceback("cpostprocessing.NodeStarFactor.setU", __pyx_clineno, __pyx_lineno, __pyx_filename);
8892  __Pyx_RefNannyFinishContext();
8893  return NULL;
8894  __pyx_L4_argument_unpacking_done:;
8895  __pyx_r = __pyx_pf_15cpostprocessing_14NodeStarFactor_4setU(((struct __pyx_obj_15cpostprocessing_NodeStarFactor *)__pyx_v_self), ((double)__pyx_v_val));
8896 
8897  /* function exit code */
8898  __Pyx_RefNannyFinishContext();
8899  return __pyx_r;
8900 }
8901 
8902 static PyObject *__pyx_pf_15cpostprocessing_14NodeStarFactor_4setU(struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_self, double __pyx_v_val) {
8903  int __pyx_v_I;
8904  int __pyx_v_i;
8905  PyObject *__pyx_r = NULL;
8906  __Pyx_RefNannyDeclarations
8907  int __pyx_t_1;
8908  int __pyx_t_2;
8909  int __pyx_t_3;
8910  int __pyx_t_4;
8911  int __pyx_t_5;
8912  int __pyx_t_6;
8913  __Pyx_RefNannySetupContext("setU", 0);
8914 
8915  /* "cpostprocessing.pyx":797
8916  * cdef int I
8917  * cdef int i
8918  * for I in range(self.nsf.N): # <<<<<<<<<<<<<<
8919  * for i in range(self.nsf.subdomain_dim[I]):
8920  * self.nsf.subdomain_U[I][i] = val
8921  */
8922  __pyx_t_1 = __pyx_v_self->nsf.N;
8923  __pyx_t_2 = __pyx_t_1;
8924  for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
8925  __pyx_v_I = __pyx_t_3;
8926 
8927  /* "cpostprocessing.pyx":798
8928  * cdef int i
8929  * for I in range(self.nsf.N):
8930  * for i in range(self.nsf.subdomain_dim[I]): # <<<<<<<<<<<<<<
8931  * self.nsf.subdomain_U[I][i] = val
8932  *
8933  */
8934  __pyx_t_4 = (__pyx_v_self->nsf.subdomain_dim[__pyx_v_I]);
8935  __pyx_t_5 = __pyx_t_4;
8936  for (__pyx_t_6 = 0; __pyx_t_6 < __pyx_t_5; __pyx_t_6+=1) {
8937  __pyx_v_i = __pyx_t_6;
8938 
8939  /* "cpostprocessing.pyx":799
8940  * for I in range(self.nsf.N):
8941  * for i in range(self.nsf.subdomain_dim[I]):
8942  * self.nsf.subdomain_U[I][i] = val # <<<<<<<<<<<<<<
8943  *
8944  * def copyData(self,
8945  */
8946  ((__pyx_v_self->nsf.subdomain_U[__pyx_v_I])[__pyx_v_i]) = __pyx_v_val;
8947  }
8948  }
8949 
8950  /* "cpostprocessing.pyx":793
8951  * self.nsf.subdomain_column_pivots)
8952  *
8953  * def setU(self, # <<<<<<<<<<<<<<
8954  * double val):
8955  * cdef int I
8956  */
8957 
8958  /* function exit code */
8959  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
8960  __Pyx_XGIVEREF(__pyx_r);
8961  __Pyx_RefNannyFinishContext();
8962  return __pyx_r;
8963 }
8964 
8965 /* "cpostprocessing.pyx":801
8966  * self.nsf.subdomain_U[I][i] = val
8967  *
8968  * def copyData(self, # <<<<<<<<<<<<<<
8969  * NodeStarFactor other):
8970  * pp.nodeStar_copy(other.nsf.N,
8971  */
8972 
8973 /* Python wrapper */
8974 static PyObject *__pyx_pw_15cpostprocessing_14NodeStarFactor_7copyData(PyObject *__pyx_v_self, PyObject *__pyx_v_other); /*proto*/
8975 static PyObject *__pyx_pw_15cpostprocessing_14NodeStarFactor_7copyData(PyObject *__pyx_v_self, PyObject *__pyx_v_other) {
8976  int __pyx_lineno = 0;
8977  const char *__pyx_filename = NULL;
8978  int __pyx_clineno = 0;
8979  PyObject *__pyx_r = 0;
8980  __Pyx_RefNannyDeclarations
8981  __Pyx_RefNannySetupContext("copyData (wrapper)", 0);
8982  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_other), __pyx_ptype_15cpostprocessing_NodeStarFactor, 1, "other", 0))) __PYX_ERR(0, 802, __pyx_L1_error)
8983  __pyx_r = __pyx_pf_15cpostprocessing_14NodeStarFactor_6copyData(((struct __pyx_obj_15cpostprocessing_NodeStarFactor *)__pyx_v_self), ((struct __pyx_obj_15cpostprocessing_NodeStarFactor *)__pyx_v_other));
8984 
8985  /* function exit code */
8986  goto __pyx_L0;
8987  __pyx_L1_error:;
8988  __pyx_r = NULL;
8989  __pyx_L0:;
8990  __Pyx_RefNannyFinishContext();
8991  return __pyx_r;
8992 }
8993 
8994 static PyObject *__pyx_pf_15cpostprocessing_14NodeStarFactor_6copyData(struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_self, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_other) {
8995  PyObject *__pyx_r = NULL;
8996  __Pyx_RefNannyDeclarations
8997  __Pyx_RefNannySetupContext("copyData", 0);
8998 
8999  /* "cpostprocessing.pyx":803
9000  * def copyData(self,
9001  * NodeStarFactor other):
9002  * pp.nodeStar_copy(other.nsf.N, # <<<<<<<<<<<<<<
9003  * other.nsf.subdomain_dim,
9004  * other.nsf.subdomain_L,
9005  */
9006  (void)(nodeStar_copy(__pyx_v_other->nsf.N, __pyx_v_other->nsf.subdomain_dim, __pyx_v_other->nsf.subdomain_L, __pyx_v_other->nsf.subdomain_R, __pyx_v_other->nsf.subdomain_U, __pyx_v_other->nsf.subdomain_pivots, __pyx_v_other->nsf.subdomain_column_pivots, (&__pyx_v_self->nsf.N), (&__pyx_v_self->nsf.subdomain_dim), (&__pyx_v_self->nsf.subdomain_L), (&__pyx_v_self->nsf.subdomain_R), (&__pyx_v_self->nsf.subdomain_U), (&__pyx_v_self->nsf.subdomain_pivots), (&__pyx_v_self->nsf.subdomain_column_pivots)));
9007 
9008  /* "cpostprocessing.pyx":801
9009  * self.nsf.subdomain_U[I][i] = val
9010  *
9011  * def copyData(self, # <<<<<<<<<<<<<<
9012  * NodeStarFactor other):
9013  * pp.nodeStar_copy(other.nsf.N,
9014  */
9015 
9016  /* function exit code */
9017  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
9018  __Pyx_XGIVEREF(__pyx_r);
9019  __Pyx_RefNannyFinishContext();
9020  return __pyx_r;
9021 }
9022 
9023 /* "(tree fragment)":1
9024  * def __reduce_cython__(self): # <<<<<<<<<<<<<<
9025  * raise TypeError("no default __reduce__ due to non-trivial __cinit__")
9026  * def __setstate_cython__(self, __pyx_state):
9027  */
9028 
9029 /* Python wrapper */
9030 static PyObject *__pyx_pw_15cpostprocessing_14NodeStarFactor_9__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
9031 static PyObject *__pyx_pw_15cpostprocessing_14NodeStarFactor_9__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
9032  PyObject *__pyx_r = 0;
9033  __Pyx_RefNannyDeclarations
9034  __Pyx_RefNannySetupContext("__reduce_cython__ (wrapper)", 0);
9035  __pyx_r = __pyx_pf_15cpostprocessing_14NodeStarFactor_8__reduce_cython__(((struct __pyx_obj_15cpostprocessing_NodeStarFactor *)__pyx_v_self));
9036 
9037  /* function exit code */
9038  __Pyx_RefNannyFinishContext();
9039  return __pyx_r;
9040 }
9041 
9042 static PyObject *__pyx_pf_15cpostprocessing_14NodeStarFactor_8__reduce_cython__(CYTHON_UNUSED struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_self) {
9043  PyObject *__pyx_r = NULL;
9044  __Pyx_RefNannyDeclarations
9045  PyObject *__pyx_t_1 = NULL;
9046  int __pyx_lineno = 0;
9047  const char *__pyx_filename = NULL;
9048  int __pyx_clineno = 0;
9049  __Pyx_RefNannySetupContext("__reduce_cython__", 0);
9050 
9051  /* "(tree fragment)":2
9052  * def __reduce_cython__(self):
9053  * raise TypeError("no default __reduce__ due to non-trivial __cinit__") # <<<<<<<<<<<<<<
9054  * def __setstate_cython__(self, __pyx_state):
9055  * raise TypeError("no default __reduce__ due to non-trivial __cinit__")
9056  */
9057  __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple_, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2, __pyx_L1_error)
9058  __Pyx_GOTREF(__pyx_t_1);
9059  __Pyx_Raise(__pyx_t_1, 0, 0, 0);
9060  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
9061  __PYX_ERR(1, 2, __pyx_L1_error)
9062 
9063  /* "(tree fragment)":1
9064  * def __reduce_cython__(self): # <<<<<<<<<<<<<<
9065  * raise TypeError("no default __reduce__ due to non-trivial __cinit__")
9066  * def __setstate_cython__(self, __pyx_state):
9067  */
9068 
9069  /* function exit code */
9070  __pyx_L1_error:;
9071  __Pyx_XDECREF(__pyx_t_1);
9072  __Pyx_AddTraceback("cpostprocessing.NodeStarFactor.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
9073  __pyx_r = NULL;
9074  __Pyx_XGIVEREF(__pyx_r);
9075  __Pyx_RefNannyFinishContext();
9076  return __pyx_r;
9077 }
9078 
9079 /* "(tree fragment)":3
9080  * def __reduce_cython__(self):
9081  * raise TypeError("no default __reduce__ due to non-trivial __cinit__")
9082  * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<<
9083  * raise TypeError("no default __reduce__ due to non-trivial __cinit__")
9084  */
9085 
9086 /* Python wrapper */
9087 static PyObject *__pyx_pw_15cpostprocessing_14NodeStarFactor_11__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/
9088 static PyObject *__pyx_pw_15cpostprocessing_14NodeStarFactor_11__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) {
9089  PyObject *__pyx_r = 0;
9090  __Pyx_RefNannyDeclarations
9091  __Pyx_RefNannySetupContext("__setstate_cython__ (wrapper)", 0);
9092  __pyx_r = __pyx_pf_15cpostprocessing_14NodeStarFactor_10__setstate_cython__(((struct __pyx_obj_15cpostprocessing_NodeStarFactor *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state));
9093 
9094  /* function exit code */
9095  __Pyx_RefNannyFinishContext();
9096  return __pyx_r;
9097 }
9098 
9099 static PyObject *__pyx_pf_15cpostprocessing_14NodeStarFactor_10__setstate_cython__(CYTHON_UNUSED struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v___pyx_state) {
9100  PyObject *__pyx_r = NULL;
9101  __Pyx_RefNannyDeclarations
9102  PyObject *__pyx_t_1 = NULL;
9103  int __pyx_lineno = 0;
9104  const char *__pyx_filename = NULL;
9105  int __pyx_clineno = 0;
9106  __Pyx_RefNannySetupContext("__setstate_cython__", 0);
9107 
9108  /* "(tree fragment)":4
9109  * raise TypeError("no default __reduce__ due to non-trivial __cinit__")
9110  * def __setstate_cython__(self, __pyx_state):
9111  * raise TypeError("no default __reduce__ due to non-trivial __cinit__") # <<<<<<<<<<<<<<
9112  */
9113  __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 4, __pyx_L1_error)
9114  __Pyx_GOTREF(__pyx_t_1);
9115  __Pyx_Raise(__pyx_t_1, 0, 0, 0);
9116  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
9117  __PYX_ERR(1, 4, __pyx_L1_error)
9118 
9119  /* "(tree fragment)":3
9120  * def __reduce_cython__(self):
9121  * raise TypeError("no default __reduce__ due to non-trivial __cinit__")
9122  * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<<
9123  * raise TypeError("no default __reduce__ due to non-trivial __cinit__")
9124  */
9125 
9126  /* function exit code */
9127  __pyx_L1_error:;
9128  __Pyx_XDECREF(__pyx_t_1);
9129  __Pyx_AddTraceback("cpostprocessing.NodeStarFactor.__setstate_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
9130  __pyx_r = NULL;
9131  __Pyx_XGIVEREF(__pyx_r);
9132  __Pyx_RefNannyFinishContext();
9133  return __pyx_r;
9134 }
9135 
9136 /* "cpostprocessing.pyx":818
9137  * &self.nsf.subdomain_column_pivots)
9138  *
9139  * def calculateConservationResidualPWL(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
9140  * np.ndarray exteriorElementBoundaries,
9141  * np.ndarray elementBoundaryElements,
9142  */
9143 
9144 /* Python wrapper */
9145 static PyObject *__pyx_pw_15cpostprocessing_69calculateConservationResidualPWL(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
9146 static PyMethodDef __pyx_mdef_15cpostprocessing_69calculateConservationResidualPWL = {"calculateConservationResidualPWL", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_69calculateConservationResidualPWL, METH_VARARGS|METH_KEYWORDS, 0};
9147 static PyObject *__pyx_pw_15cpostprocessing_69calculateConservationResidualPWL(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
9148  PyArrayObject *__pyx_v_interiorElementBoundaries = 0;
9149  PyArrayObject *__pyx_v_exteriorElementBoundaries = 0;
9150  PyArrayObject *__pyx_v_elementBoundaryElements = 0;
9151  PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries = 0;
9152  PyArrayObject *__pyx_v_elementNodes = 0;
9153  PyArrayObject *__pyx_v_dofMapl2g = 0;
9154  PyArrayObject *__pyx_v_nodeStarElements = 0;
9155  PyArrayObject *__pyx_v_nodeStarElementNeighbors = 0;
9156  PyArrayObject *__pyx_v_nElements_node = 0;
9157  PyArrayObject *__pyx_v_fluxElementBoundaries = 0;
9158  PyArrayObject *__pyx_v_elementResidual = 0;
9159  PyArrayObject *__pyx_v_vAverage = 0;
9160  PyArrayObject *__pyx_v_dx = 0;
9161  PyArrayObject *__pyx_v_w = 0;
9162  PyArrayObject *__pyx_v_n = 0;
9163  struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor = 0;
9164  PyArrayObject *__pyx_v_conservationResidual = 0;
9165  PyArrayObject *__pyx_v_vConservative = 0;
9166  PyArrayObject *__pyx_v_vConservative_element = 0;
9167  int __pyx_lineno = 0;
9168  const char *__pyx_filename = NULL;
9169  int __pyx_clineno = 0;
9170  PyObject *__pyx_r = 0;
9171  __Pyx_RefNannyDeclarations
9172  __Pyx_RefNannySetupContext("calculateConservationResidualPWL (wrapper)", 0);
9173  {
9174  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_interiorElementBoundaries,&__pyx_n_s_exteriorElementBoundaries,&__pyx_n_s_elementBoundaryElements,&__pyx_n_s_elementBoundaryLocalElementBound,&__pyx_n_s_elementNodes,&__pyx_n_s_dofMapl2g,&__pyx_n_s_nodeStarElements,&__pyx_n_s_nodeStarElementNeighbors,&__pyx_n_s_nElements_node,&__pyx_n_s_fluxElementBoundaries,&__pyx_n_s_elementResidual,&__pyx_n_s_vAverage,&__pyx_n_s_dx,&__pyx_n_s_w,&__pyx_n_s_n,&__pyx_n_s_nodeStarFactor,&__pyx_n_s_conservationResidual,&__pyx_n_s_vConservative,&__pyx_n_s_vConservative_element,0};
9175  PyObject* values[19] = {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0};
9176  if (unlikely(__pyx_kwds)) {
9177  Py_ssize_t kw_args;
9178  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
9179  switch (pos_args) {
9180  case 19: values[18] = PyTuple_GET_ITEM(__pyx_args, 18);
9181  CYTHON_FALLTHROUGH;
9182  case 18: values[17] = PyTuple_GET_ITEM(__pyx_args, 17);
9183  CYTHON_FALLTHROUGH;
9184  case 17: values[16] = PyTuple_GET_ITEM(__pyx_args, 16);
9185  CYTHON_FALLTHROUGH;
9186  case 16: values[15] = PyTuple_GET_ITEM(__pyx_args, 15);
9187  CYTHON_FALLTHROUGH;
9188  case 15: values[14] = PyTuple_GET_ITEM(__pyx_args, 14);
9189  CYTHON_FALLTHROUGH;
9190  case 14: values[13] = PyTuple_GET_ITEM(__pyx_args, 13);
9191  CYTHON_FALLTHROUGH;
9192  case 13: values[12] = PyTuple_GET_ITEM(__pyx_args, 12);
9193  CYTHON_FALLTHROUGH;
9194  case 12: values[11] = PyTuple_GET_ITEM(__pyx_args, 11);
9195  CYTHON_FALLTHROUGH;
9196  case 11: values[10] = PyTuple_GET_ITEM(__pyx_args, 10);
9197  CYTHON_FALLTHROUGH;
9198  case 10: values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
9199  CYTHON_FALLTHROUGH;
9200  case 9: values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
9201  CYTHON_FALLTHROUGH;
9202  case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
9203  CYTHON_FALLTHROUGH;
9204  case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
9205  CYTHON_FALLTHROUGH;
9206  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
9207  CYTHON_FALLTHROUGH;
9208  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
9209  CYTHON_FALLTHROUGH;
9210  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
9211  CYTHON_FALLTHROUGH;
9212  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
9213  CYTHON_FALLTHROUGH;
9214  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
9215  CYTHON_FALLTHROUGH;
9216  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
9217  CYTHON_FALLTHROUGH;
9218  case 0: break;
9219  default: goto __pyx_L5_argtuple_error;
9220  }
9221  kw_args = PyDict_Size(__pyx_kwds);
9222  switch (pos_args) {
9223  case 0:
9224  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_interiorElementBoundaries)) != 0)) kw_args--;
9225  else goto __pyx_L5_argtuple_error;
9226  CYTHON_FALLTHROUGH;
9227  case 1:
9228  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_exteriorElementBoundaries)) != 0)) kw_args--;
9229  else {
9230  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL", 1, 19, 19, 1); __PYX_ERR(0, 818, __pyx_L3_error)
9231  }
9232  CYTHON_FALLTHROUGH;
9233  case 2:
9234  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryElements)) != 0)) kw_args--;
9235  else {
9236  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL", 1, 19, 19, 2); __PYX_ERR(0, 818, __pyx_L3_error)
9237  }
9238  CYTHON_FALLTHROUGH;
9239  case 3:
9240  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryLocalElementBound)) != 0)) kw_args--;
9241  else {
9242  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL", 1, 19, 19, 3); __PYX_ERR(0, 818, __pyx_L3_error)
9243  }
9244  CYTHON_FALLTHROUGH;
9245  case 4:
9246  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementNodes)) != 0)) kw_args--;
9247  else {
9248  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL", 1, 19, 19, 4); __PYX_ERR(0, 818, __pyx_L3_error)
9249  }
9250  CYTHON_FALLTHROUGH;
9251  case 5:
9252  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_dofMapl2g)) != 0)) kw_args--;
9253  else {
9254  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL", 1, 19, 19, 5); __PYX_ERR(0, 818, __pyx_L3_error)
9255  }
9256  CYTHON_FALLTHROUGH;
9257  case 6:
9258  if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarElements)) != 0)) kw_args--;
9259  else {
9260  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL", 1, 19, 19, 6); __PYX_ERR(0, 818, __pyx_L3_error)
9261  }
9262  CYTHON_FALLTHROUGH;
9263  case 7:
9264  if (likely((values[7] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarElementNeighbors)) != 0)) kw_args--;
9265  else {
9266  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL", 1, 19, 19, 7); __PYX_ERR(0, 818, __pyx_L3_error)
9267  }
9268  CYTHON_FALLTHROUGH;
9269  case 8:
9270  if (likely((values[8] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nElements_node)) != 0)) kw_args--;
9271  else {
9272  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL", 1, 19, 19, 8); __PYX_ERR(0, 818, __pyx_L3_error)
9273  }
9274  CYTHON_FALLTHROUGH;
9275  case 9:
9276  if (likely((values[9] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_fluxElementBoundaries)) != 0)) kw_args--;
9277  else {
9278  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL", 1, 19, 19, 9); __PYX_ERR(0, 818, __pyx_L3_error)
9279  }
9280  CYTHON_FALLTHROUGH;
9281  case 10:
9282  if (likely((values[10] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementResidual)) != 0)) kw_args--;
9283  else {
9284  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL", 1, 19, 19, 10); __PYX_ERR(0, 818, __pyx_L3_error)
9285  }
9286  CYTHON_FALLTHROUGH;
9287  case 11:
9288  if (likely((values[11] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_vAverage)) != 0)) kw_args--;
9289  else {
9290  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL", 1, 19, 19, 11); __PYX_ERR(0, 818, __pyx_L3_error)
9291  }
9292  CYTHON_FALLTHROUGH;
9293  case 12:
9294  if (likely((values[12] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_dx)) != 0)) kw_args--;
9295  else {
9296  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL", 1, 19, 19, 12); __PYX_ERR(0, 818, __pyx_L3_error)
9297  }
9298  CYTHON_FALLTHROUGH;
9299  case 13:
9300  if (likely((values[13] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_w)) != 0)) kw_args--;
9301  else {
9302  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL", 1, 19, 19, 13); __PYX_ERR(0, 818, __pyx_L3_error)
9303  }
9304  CYTHON_FALLTHROUGH;
9305  case 14:
9306  if (likely((values[14] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_n)) != 0)) kw_args--;
9307  else {
9308  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL", 1, 19, 19, 14); __PYX_ERR(0, 818, __pyx_L3_error)
9309  }
9310  CYTHON_FALLTHROUGH;
9311  case 15:
9312  if (likely((values[15] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarFactor)) != 0)) kw_args--;
9313  else {
9314  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL", 1, 19, 19, 15); __PYX_ERR(0, 818, __pyx_L3_error)
9315  }
9316  CYTHON_FALLTHROUGH;
9317  case 16:
9318  if (likely((values[16] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_conservationResidual)) != 0)) kw_args--;
9319  else {
9320  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL", 1, 19, 19, 16); __PYX_ERR(0, 818, __pyx_L3_error)
9321  }
9322  CYTHON_FALLTHROUGH;
9323  case 17:
9324  if (likely((values[17] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_vConservative)) != 0)) kw_args--;
9325  else {
9326  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL", 1, 19, 19, 17); __PYX_ERR(0, 818, __pyx_L3_error)
9327  }
9328  CYTHON_FALLTHROUGH;
9329  case 18:
9330  if (likely((values[18] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_vConservative_element)) != 0)) kw_args--;
9331  else {
9332  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL", 1, 19, 19, 18); __PYX_ERR(0, 818, __pyx_L3_error)
9333  }
9334  }
9335  if (unlikely(kw_args > 0)) {
9336  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "calculateConservationResidualPWL") < 0)) __PYX_ERR(0, 818, __pyx_L3_error)
9337  }
9338  } else if (PyTuple_GET_SIZE(__pyx_args) != 19) {
9339  goto __pyx_L5_argtuple_error;
9340  } else {
9341  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
9342  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
9343  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
9344  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
9345  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
9346  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
9347  values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
9348  values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
9349  values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
9350  values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
9351  values[10] = PyTuple_GET_ITEM(__pyx_args, 10);
9352  values[11] = PyTuple_GET_ITEM(__pyx_args, 11);
9353  values[12] = PyTuple_GET_ITEM(__pyx_args, 12);
9354  values[13] = PyTuple_GET_ITEM(__pyx_args, 13);
9355  values[14] = PyTuple_GET_ITEM(__pyx_args, 14);
9356  values[15] = PyTuple_GET_ITEM(__pyx_args, 15);
9357  values[16] = PyTuple_GET_ITEM(__pyx_args, 16);
9358  values[17] = PyTuple_GET_ITEM(__pyx_args, 17);
9359  values[18] = PyTuple_GET_ITEM(__pyx_args, 18);
9360  }
9361  __pyx_v_interiorElementBoundaries = ((PyArrayObject *)values[0]);
9362  __pyx_v_exteriorElementBoundaries = ((PyArrayObject *)values[1]);
9363  __pyx_v_elementBoundaryElements = ((PyArrayObject *)values[2]);
9364  __pyx_v_elementBoundaryLocalElementBoundaries = ((PyArrayObject *)values[3]);
9365  __pyx_v_elementNodes = ((PyArrayObject *)values[4]);
9366  __pyx_v_dofMapl2g = ((PyArrayObject *)values[5]);
9367  __pyx_v_nodeStarElements = ((PyArrayObject *)values[6]);
9368  __pyx_v_nodeStarElementNeighbors = ((PyArrayObject *)values[7]);
9369  __pyx_v_nElements_node = ((PyArrayObject *)values[8]);
9370  __pyx_v_fluxElementBoundaries = ((PyArrayObject *)values[9]);
9371  __pyx_v_elementResidual = ((PyArrayObject *)values[10]);
9372  __pyx_v_vAverage = ((PyArrayObject *)values[11]);
9373  __pyx_v_dx = ((PyArrayObject *)values[12]);
9374  __pyx_v_w = ((PyArrayObject *)values[13]);
9375  __pyx_v_n = ((PyArrayObject *)values[14]);
9376  __pyx_v_nodeStarFactor = ((struct __pyx_obj_15cpostprocessing_NodeStarFactor *)values[15]);
9377  __pyx_v_conservationResidual = ((PyArrayObject *)values[16]);
9378  __pyx_v_vConservative = ((PyArrayObject *)values[17]);
9379  __pyx_v_vConservative_element = ((PyArrayObject *)values[18]);
9380  }
9381  goto __pyx_L4_argument_unpacking_done;
9382  __pyx_L5_argtuple_error:;
9383  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL", 1, 19, 19, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 818, __pyx_L3_error)
9384  __pyx_L3_error:;
9385  __Pyx_AddTraceback("cpostprocessing.calculateConservationResidualPWL", __pyx_clineno, __pyx_lineno, __pyx_filename);
9386  __Pyx_RefNannyFinishContext();
9387  return NULL;
9388  __pyx_L4_argument_unpacking_done:;
9389  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_interiorElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "interiorElementBoundaries", 0))) __PYX_ERR(0, 818, __pyx_L1_error)
9390  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_exteriorElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "exteriorElementBoundaries", 0))) __PYX_ERR(0, 819, __pyx_L1_error)
9391  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryElements), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryElements", 0))) __PYX_ERR(0, 820, __pyx_L1_error)
9392  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryLocalElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryLocalElementBoundaries", 0))) __PYX_ERR(0, 821, __pyx_L1_error)
9393  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementNodes), __pyx_ptype_5numpy_ndarray, 1, "elementNodes", 0))) __PYX_ERR(0, 822, __pyx_L1_error)
9394  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dofMapl2g), __pyx_ptype_5numpy_ndarray, 1, "dofMapl2g", 0))) __PYX_ERR(0, 823, __pyx_L1_error)
9395  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarElements), __pyx_ptype_5numpy_ndarray, 1, "nodeStarElements", 0))) __PYX_ERR(0, 824, __pyx_L1_error)
9396  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarElementNeighbors), __pyx_ptype_5numpy_ndarray, 1, "nodeStarElementNeighbors", 0))) __PYX_ERR(0, 825, __pyx_L1_error)
9397  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nElements_node), __pyx_ptype_5numpy_ndarray, 1, "nElements_node", 0))) __PYX_ERR(0, 826, __pyx_L1_error)
9398  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_fluxElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "fluxElementBoundaries", 0))) __PYX_ERR(0, 827, __pyx_L1_error)
9399  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementResidual), __pyx_ptype_5numpy_ndarray, 1, "elementResidual", 0))) __PYX_ERR(0, 828, __pyx_L1_error)
9400  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_vAverage), __pyx_ptype_5numpy_ndarray, 1, "vAverage", 0))) __PYX_ERR(0, 829, __pyx_L1_error)
9401  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dx), __pyx_ptype_5numpy_ndarray, 1, "dx", 0))) __PYX_ERR(0, 830, __pyx_L1_error)
9402  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_w), __pyx_ptype_5numpy_ndarray, 1, "w", 0))) __PYX_ERR(0, 831, __pyx_L1_error)
9403  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_n), __pyx_ptype_5numpy_ndarray, 1, "n", 0))) __PYX_ERR(0, 832, __pyx_L1_error)
9404  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarFactor), __pyx_ptype_15cpostprocessing_NodeStarFactor, 1, "nodeStarFactor", 0))) __PYX_ERR(0, 833, __pyx_L1_error)
9405  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_conservationResidual), __pyx_ptype_5numpy_ndarray, 1, "conservationResidual", 0))) __PYX_ERR(0, 834, __pyx_L1_error)
9406  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_vConservative), __pyx_ptype_5numpy_ndarray, 1, "vConservative", 0))) __PYX_ERR(0, 835, __pyx_L1_error)
9407  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_vConservative_element), __pyx_ptype_5numpy_ndarray, 1, "vConservative_element", 0))) __PYX_ERR(0, 836, __pyx_L1_error)
9408  __pyx_r = __pyx_pf_15cpostprocessing_68calculateConservationResidualPWL(__pyx_self, __pyx_v_interiorElementBoundaries, __pyx_v_exteriorElementBoundaries, __pyx_v_elementBoundaryElements, __pyx_v_elementBoundaryLocalElementBoundaries, __pyx_v_elementNodes, __pyx_v_dofMapl2g, __pyx_v_nodeStarElements, __pyx_v_nodeStarElementNeighbors, __pyx_v_nElements_node, __pyx_v_fluxElementBoundaries, __pyx_v_elementResidual, __pyx_v_vAverage, __pyx_v_dx, __pyx_v_w, __pyx_v_n, __pyx_v_nodeStarFactor, __pyx_v_conservationResidual, __pyx_v_vConservative, __pyx_v_vConservative_element);
9409 
9410  /* function exit code */
9411  goto __pyx_L0;
9412  __pyx_L1_error:;
9413  __pyx_r = NULL;
9414  __pyx_L0:;
9415  __Pyx_RefNannyFinishContext();
9416  return __pyx_r;
9417 }
9418 
9419 static PyObject *__pyx_pf_15cpostprocessing_68calculateConservationResidualPWL(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_interiorElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries, PyArrayObject *__pyx_v_elementNodes, PyArrayObject *__pyx_v_dofMapl2g, PyArrayObject *__pyx_v_nodeStarElements, PyArrayObject *__pyx_v_nodeStarElementNeighbors, PyArrayObject *__pyx_v_nElements_node, PyArrayObject *__pyx_v_fluxElementBoundaries, PyArrayObject *__pyx_v_elementResidual, PyArrayObject *__pyx_v_vAverage, PyArrayObject *__pyx_v_dx, PyArrayObject *__pyx_v_w, PyArrayObject *__pyx_v_n, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor, PyArrayObject *__pyx_v_conservationResidual, PyArrayObject *__pyx_v_vConservative, PyArrayObject *__pyx_v_vConservative_element) {
9420  PyObject *__pyx_r = NULL;
9421  __Pyx_RefNannyDeclarations
9422  __Pyx_RefNannySetupContext("calculateConservationResidualPWL", 0);
9423 
9424  /* "cpostprocessing.pyx":837
9425  * np.ndarray vConservative,
9426  * np.ndarray vConservative_element):
9427  * pp.calculateConservationResidualPWL(w.shape[0], # <<<<<<<<<<<<<<
9428  * #/[inserted by cython to avoid comment start]* nElements_global*[inserted by cython to avoid comment closer]/,
9429  * interiorElementBoundaries.shape[0],
9430  */
9431  calculateConservationResidualPWL((__pyx_v_w->dimensions[0]), (__pyx_v_interiorElementBoundaries->dimensions[0]), (__pyx_v_exteriorElementBoundaries->dimensions[0]), (__pyx_v_w->dimensions[1]), (__pyx_v_w->dimensions[2]), (__pyx_v_w->dimensions[3]), (__pyx_v_dofMapl2g->dimensions[1]), (__pyx_v_n->dimensions[2]), ((int *)__pyx_v_interiorElementBoundaries->data), ((int *)__pyx_v_exteriorElementBoundaries->data), ((int *)__pyx_v_elementBoundaryElements->data), ((int *)__pyx_v_elementBoundaryLocalElementBoundaries->data), ((int *)__pyx_v_elementNodes->data), ((int *)__pyx_v_dofMapl2g->data), ((int *)__pyx_v_nodeStarElements->data), ((int *)__pyx_v_nodeStarElementNeighbors->data), ((int *)__pyx_v_nElements_node->data), ((int *)__pyx_v_fluxElementBoundaries->data), ((double *)__pyx_v_elementResidual->data), ((double *)__pyx_v_vAverage->data), ((double *)__pyx_v_dx->data), ((double *)__pyx_v_w->data), ((double *)__pyx_v_n->data), (&__pyx_v_nodeStarFactor->nsf), ((double *)__pyx_v_conservationResidual->data), ((double *)__pyx_v_vConservative->data), ((double *)__pyx_v_vConservative_element->data));
9432 
9433  /* "cpostprocessing.pyx":818
9434  * &self.nsf.subdomain_column_pivots)
9435  *
9436  * def calculateConservationResidualPWL(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
9437  * np.ndarray exteriorElementBoundaries,
9438  * np.ndarray elementBoundaryElements,
9439  */
9440 
9441  /* function exit code */
9442  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
9443  __Pyx_XGIVEREF(__pyx_r);
9444  __Pyx_RefNannyFinishContext();
9445  return __pyx_r;
9446 }
9447 
9448 /* "cpostprocessing.pyx":873
9449  * <double*>(vConservative_element.data))
9450  *
9451  * def calculateConservationJacobianPWL(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
9452  * np.ndarray exteriorElementBoundaries,
9453  * np.ndarray elementBoundaryElements,
9454  */
9455 
9456 /* Python wrapper */
9457 static PyObject *__pyx_pw_15cpostprocessing_71calculateConservationJacobianPWL(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
9458 static PyMethodDef __pyx_mdef_15cpostprocessing_71calculateConservationJacobianPWL = {"calculateConservationJacobianPWL", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_71calculateConservationJacobianPWL, METH_VARARGS|METH_KEYWORDS, 0};
9459 static PyObject *__pyx_pw_15cpostprocessing_71calculateConservationJacobianPWL(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
9460  PyArrayObject *__pyx_v_interiorElementBoundaries = 0;
9461  PyArrayObject *__pyx_v_exteriorElementBoundaries = 0;
9462  PyArrayObject *__pyx_v_elementBoundaryElements = 0;
9463  PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries = 0;
9464  PyArrayObject *__pyx_v_elementNodes = 0;
9465  PyArrayObject *__pyx_v_dofMapl2g = 0;
9466  PyArrayObject *__pyx_v_dofStarElements = 0;
9467  PyArrayObject *__pyx_v_dofStarElementNeighbors = 0;
9468  PyArrayObject *__pyx_v_nElements_dof = 0;
9469  PyArrayObject *__pyx_v_internalNodes = 0;
9470  PyArrayObject *__pyx_v_fluxElementBoundaries = 0;
9471  PyArrayObject *__pyx_v_fluxBoundaryNodes = 0;
9472  PyArrayObject *__pyx_v_w = 0;
9473  PyArrayObject *__pyx_v_n = 0;
9474  struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor = 0;
9475  int __pyx_lineno = 0;
9476  const char *__pyx_filename = NULL;
9477  int __pyx_clineno = 0;
9478  PyObject *__pyx_r = 0;
9479  __Pyx_RefNannyDeclarations
9480  __Pyx_RefNannySetupContext("calculateConservationJacobianPWL (wrapper)", 0);
9481  {
9482  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_interiorElementBoundaries,&__pyx_n_s_exteriorElementBoundaries,&__pyx_n_s_elementBoundaryElements,&__pyx_n_s_elementBoundaryLocalElementBound,&__pyx_n_s_elementNodes,&__pyx_n_s_dofMapl2g,&__pyx_n_s_dofStarElements,&__pyx_n_s_dofStarElementNeighbors,&__pyx_n_s_nElements_dof,&__pyx_n_s_internalNodes,&__pyx_n_s_fluxElementBoundaries,&__pyx_n_s_fluxBoundaryNodes,&__pyx_n_s_w,&__pyx_n_s_n,&__pyx_n_s_nodeStarFactor,0};
9483  PyObject* values[15] = {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0};
9484  if (unlikely(__pyx_kwds)) {
9485  Py_ssize_t kw_args;
9486  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
9487  switch (pos_args) {
9488  case 15: values[14] = PyTuple_GET_ITEM(__pyx_args, 14);
9489  CYTHON_FALLTHROUGH;
9490  case 14: values[13] = PyTuple_GET_ITEM(__pyx_args, 13);
9491  CYTHON_FALLTHROUGH;
9492  case 13: values[12] = PyTuple_GET_ITEM(__pyx_args, 12);
9493  CYTHON_FALLTHROUGH;
9494  case 12: values[11] = PyTuple_GET_ITEM(__pyx_args, 11);
9495  CYTHON_FALLTHROUGH;
9496  case 11: values[10] = PyTuple_GET_ITEM(__pyx_args, 10);
9497  CYTHON_FALLTHROUGH;
9498  case 10: values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
9499  CYTHON_FALLTHROUGH;
9500  case 9: values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
9501  CYTHON_FALLTHROUGH;
9502  case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
9503  CYTHON_FALLTHROUGH;
9504  case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
9505  CYTHON_FALLTHROUGH;
9506  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
9507  CYTHON_FALLTHROUGH;
9508  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
9509  CYTHON_FALLTHROUGH;
9510  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
9511  CYTHON_FALLTHROUGH;
9512  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
9513  CYTHON_FALLTHROUGH;
9514  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
9515  CYTHON_FALLTHROUGH;
9516  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
9517  CYTHON_FALLTHROUGH;
9518  case 0: break;
9519  default: goto __pyx_L5_argtuple_error;
9520  }
9521  kw_args = PyDict_Size(__pyx_kwds);
9522  switch (pos_args) {
9523  case 0:
9524  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_interiorElementBoundaries)) != 0)) kw_args--;
9525  else goto __pyx_L5_argtuple_error;
9526  CYTHON_FALLTHROUGH;
9527  case 1:
9528  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_exteriorElementBoundaries)) != 0)) kw_args--;
9529  else {
9530  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL", 1, 15, 15, 1); __PYX_ERR(0, 873, __pyx_L3_error)
9531  }
9532  CYTHON_FALLTHROUGH;
9533  case 2:
9534  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryElements)) != 0)) kw_args--;
9535  else {
9536  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL", 1, 15, 15, 2); __PYX_ERR(0, 873, __pyx_L3_error)
9537  }
9538  CYTHON_FALLTHROUGH;
9539  case 3:
9540  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryLocalElementBound)) != 0)) kw_args--;
9541  else {
9542  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL", 1, 15, 15, 3); __PYX_ERR(0, 873, __pyx_L3_error)
9543  }
9544  CYTHON_FALLTHROUGH;
9545  case 4:
9546  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementNodes)) != 0)) kw_args--;
9547  else {
9548  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL", 1, 15, 15, 4); __PYX_ERR(0, 873, __pyx_L3_error)
9549  }
9550  CYTHON_FALLTHROUGH;
9551  case 5:
9552  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_dofMapl2g)) != 0)) kw_args--;
9553  else {
9554  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL", 1, 15, 15, 5); __PYX_ERR(0, 873, __pyx_L3_error)
9555  }
9556  CYTHON_FALLTHROUGH;
9557  case 6:
9558  if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_dofStarElements)) != 0)) kw_args--;
9559  else {
9560  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL", 1, 15, 15, 6); __PYX_ERR(0, 873, __pyx_L3_error)
9561  }
9562  CYTHON_FALLTHROUGH;
9563  case 7:
9564  if (likely((values[7] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_dofStarElementNeighbors)) != 0)) kw_args--;
9565  else {
9566  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL", 1, 15, 15, 7); __PYX_ERR(0, 873, __pyx_L3_error)
9567  }
9568  CYTHON_FALLTHROUGH;
9569  case 8:
9570  if (likely((values[8] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nElements_dof)) != 0)) kw_args--;
9571  else {
9572  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL", 1, 15, 15, 8); __PYX_ERR(0, 873, __pyx_L3_error)
9573  }
9574  CYTHON_FALLTHROUGH;
9575  case 9:
9576  if (likely((values[9] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_internalNodes)) != 0)) kw_args--;
9577  else {
9578  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL", 1, 15, 15, 9); __PYX_ERR(0, 873, __pyx_L3_error)
9579  }
9580  CYTHON_FALLTHROUGH;
9581  case 10:
9582  if (likely((values[10] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_fluxElementBoundaries)) != 0)) kw_args--;
9583  else {
9584  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL", 1, 15, 15, 10); __PYX_ERR(0, 873, __pyx_L3_error)
9585  }
9586  CYTHON_FALLTHROUGH;
9587  case 11:
9588  if (likely((values[11] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_fluxBoundaryNodes)) != 0)) kw_args--;
9589  else {
9590  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL", 1, 15, 15, 11); __PYX_ERR(0, 873, __pyx_L3_error)
9591  }
9592  CYTHON_FALLTHROUGH;
9593  case 12:
9594  if (likely((values[12] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_w)) != 0)) kw_args--;
9595  else {
9596  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL", 1, 15, 15, 12); __PYX_ERR(0, 873, __pyx_L3_error)
9597  }
9598  CYTHON_FALLTHROUGH;
9599  case 13:
9600  if (likely((values[13] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_n)) != 0)) kw_args--;
9601  else {
9602  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL", 1, 15, 15, 13); __PYX_ERR(0, 873, __pyx_L3_error)
9603  }
9604  CYTHON_FALLTHROUGH;
9605  case 14:
9606  if (likely((values[14] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarFactor)) != 0)) kw_args--;
9607  else {
9608  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL", 1, 15, 15, 14); __PYX_ERR(0, 873, __pyx_L3_error)
9609  }
9610  }
9611  if (unlikely(kw_args > 0)) {
9612  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "calculateConservationJacobianPWL") < 0)) __PYX_ERR(0, 873, __pyx_L3_error)
9613  }
9614  } else if (PyTuple_GET_SIZE(__pyx_args) != 15) {
9615  goto __pyx_L5_argtuple_error;
9616  } else {
9617  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
9618  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
9619  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
9620  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
9621  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
9622  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
9623  values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
9624  values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
9625  values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
9626  values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
9627  values[10] = PyTuple_GET_ITEM(__pyx_args, 10);
9628  values[11] = PyTuple_GET_ITEM(__pyx_args, 11);
9629  values[12] = PyTuple_GET_ITEM(__pyx_args, 12);
9630  values[13] = PyTuple_GET_ITEM(__pyx_args, 13);
9631  values[14] = PyTuple_GET_ITEM(__pyx_args, 14);
9632  }
9633  __pyx_v_interiorElementBoundaries = ((PyArrayObject *)values[0]);
9634  __pyx_v_exteriorElementBoundaries = ((PyArrayObject *)values[1]);
9635  __pyx_v_elementBoundaryElements = ((PyArrayObject *)values[2]);
9636  __pyx_v_elementBoundaryLocalElementBoundaries = ((PyArrayObject *)values[3]);
9637  __pyx_v_elementNodes = ((PyArrayObject *)values[4]);
9638  __pyx_v_dofMapl2g = ((PyArrayObject *)values[5]);
9639  __pyx_v_dofStarElements = ((PyArrayObject *)values[6]);
9640  __pyx_v_dofStarElementNeighbors = ((PyArrayObject *)values[7]);
9641  __pyx_v_nElements_dof = ((PyArrayObject *)values[8]);
9642  __pyx_v_internalNodes = ((PyArrayObject *)values[9]);
9643  __pyx_v_fluxElementBoundaries = ((PyArrayObject *)values[10]);
9644  __pyx_v_fluxBoundaryNodes = ((PyArrayObject *)values[11]);
9645  __pyx_v_w = ((PyArrayObject *)values[12]);
9646  __pyx_v_n = ((PyArrayObject *)values[13]);
9647  __pyx_v_nodeStarFactor = ((struct __pyx_obj_15cpostprocessing_NodeStarFactor *)values[14]);
9648  }
9649  goto __pyx_L4_argument_unpacking_done;
9650  __pyx_L5_argtuple_error:;
9651  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL", 1, 15, 15, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 873, __pyx_L3_error)
9652  __pyx_L3_error:;
9653  __Pyx_AddTraceback("cpostprocessing.calculateConservationJacobianPWL", __pyx_clineno, __pyx_lineno, __pyx_filename);
9654  __Pyx_RefNannyFinishContext();
9655  return NULL;
9656  __pyx_L4_argument_unpacking_done:;
9657  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_interiorElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "interiorElementBoundaries", 0))) __PYX_ERR(0, 873, __pyx_L1_error)
9658  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_exteriorElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "exteriorElementBoundaries", 0))) __PYX_ERR(0, 874, __pyx_L1_error)
9659  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryElements), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryElements", 0))) __PYX_ERR(0, 875, __pyx_L1_error)
9660  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryLocalElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryLocalElementBoundaries", 0))) __PYX_ERR(0, 876, __pyx_L1_error)
9661  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementNodes), __pyx_ptype_5numpy_ndarray, 1, "elementNodes", 0))) __PYX_ERR(0, 877, __pyx_L1_error)
9662  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dofMapl2g), __pyx_ptype_5numpy_ndarray, 1, "dofMapl2g", 0))) __PYX_ERR(0, 878, __pyx_L1_error)
9663  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dofStarElements), __pyx_ptype_5numpy_ndarray, 1, "dofStarElements", 0))) __PYX_ERR(0, 879, __pyx_L1_error)
9664  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dofStarElementNeighbors), __pyx_ptype_5numpy_ndarray, 1, "dofStarElementNeighbors", 0))) __PYX_ERR(0, 880, __pyx_L1_error)
9665  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nElements_dof), __pyx_ptype_5numpy_ndarray, 1, "nElements_dof", 0))) __PYX_ERR(0, 881, __pyx_L1_error)
9666  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_internalNodes), __pyx_ptype_5numpy_ndarray, 1, "internalNodes", 0))) __PYX_ERR(0, 882, __pyx_L1_error)
9667  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_fluxElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "fluxElementBoundaries", 0))) __PYX_ERR(0, 883, __pyx_L1_error)
9668  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_fluxBoundaryNodes), __pyx_ptype_5numpy_ndarray, 1, "fluxBoundaryNodes", 0))) __PYX_ERR(0, 884, __pyx_L1_error)
9669  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_w), __pyx_ptype_5numpy_ndarray, 1, "w", 0))) __PYX_ERR(0, 885, __pyx_L1_error)
9670  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_n), __pyx_ptype_5numpy_ndarray, 1, "n", 0))) __PYX_ERR(0, 886, __pyx_L1_error)
9671  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarFactor), __pyx_ptype_15cpostprocessing_NodeStarFactor, 1, "nodeStarFactor", 0))) __PYX_ERR(0, 887, __pyx_L1_error)
9672  __pyx_r = __pyx_pf_15cpostprocessing_70calculateConservationJacobianPWL(__pyx_self, __pyx_v_interiorElementBoundaries, __pyx_v_exteriorElementBoundaries, __pyx_v_elementBoundaryElements, __pyx_v_elementBoundaryLocalElementBoundaries, __pyx_v_elementNodes, __pyx_v_dofMapl2g, __pyx_v_dofStarElements, __pyx_v_dofStarElementNeighbors, __pyx_v_nElements_dof, __pyx_v_internalNodes, __pyx_v_fluxElementBoundaries, __pyx_v_fluxBoundaryNodes, __pyx_v_w, __pyx_v_n, __pyx_v_nodeStarFactor);
9673 
9674  /* function exit code */
9675  goto __pyx_L0;
9676  __pyx_L1_error:;
9677  __pyx_r = NULL;
9678  __pyx_L0:;
9679  __Pyx_RefNannyFinishContext();
9680  return __pyx_r;
9681 }
9682 
9683 static PyObject *__pyx_pf_15cpostprocessing_70calculateConservationJacobianPWL(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_interiorElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries, PyArrayObject *__pyx_v_elementNodes, PyArrayObject *__pyx_v_dofMapl2g, PyArrayObject *__pyx_v_dofStarElements, PyArrayObject *__pyx_v_dofStarElementNeighbors, PyArrayObject *__pyx_v_nElements_dof, PyArrayObject *__pyx_v_internalNodes, PyArrayObject *__pyx_v_fluxElementBoundaries, PyArrayObject *__pyx_v_fluxBoundaryNodes, PyArrayObject *__pyx_v_w, PyArrayObject *__pyx_v_n, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor) {
9684  PyObject *__pyx_r = NULL;
9685  __Pyx_RefNannyDeclarations
9686  __Pyx_RefNannySetupContext("calculateConservationJacobianPWL", 0);
9687 
9688  /* "cpostprocessing.pyx":888
9689  * np.ndarray n,
9690  * NodeStarFactor nodeStarFactor):
9691  * pp.calculateConservationJacobianPWL(nElements_dof.shape[0], # <<<<<<<<<<<<<<
9692  * internalNodes.shape[0],
9693  * w.shape[0],
9694  */
9695  calculateConservationJacobianPWL((__pyx_v_nElements_dof->dimensions[0]), (__pyx_v_internalNodes->dimensions[0]), (__pyx_v_w->dimensions[0]), (__pyx_v_interiorElementBoundaries->dimensions[0]), (__pyx_v_exteriorElementBoundaries->dimensions[0]), (__pyx_v_w->dimensions[1]), (__pyx_v_w->dimensions[2]), (__pyx_v_w->dimensions[3]), (__pyx_v_dofMapl2g->dimensions[1]), (__pyx_v_n->dimensions[2]), ((int *)__pyx_v_interiorElementBoundaries->data), ((int *)__pyx_v_exteriorElementBoundaries->data), ((int *)__pyx_v_elementBoundaryElements->data), ((int *)__pyx_v_elementBoundaryLocalElementBoundaries->data), ((int *)__pyx_v_elementNodes->data), ((int *)__pyx_v_dofMapl2g->data), ((int *)__pyx_v_dofStarElements->data), ((int *)__pyx_v_dofStarElementNeighbors->data), ((int *)__pyx_v_nElements_dof->data), ((int *)__pyx_v_internalNodes->data), ((int *)__pyx_v_fluxElementBoundaries->data), ((int *)__pyx_v_fluxBoundaryNodes->data), ((double *)__pyx_v_w->data), ((double *)__pyx_v_n->data), (&__pyx_v_nodeStarFactor->nsf));
9696 
9697  /* "cpostprocessing.pyx":873
9698  * <double*>(vConservative_element.data))
9699  *
9700  * def calculateConservationJacobianPWL(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
9701  * np.ndarray exteriorElementBoundaries,
9702  * np.ndarray elementBoundaryElements,
9703  */
9704 
9705  /* function exit code */
9706  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
9707  __Pyx_XGIVEREF(__pyx_r);
9708  __Pyx_RefNannyFinishContext();
9709  return __pyx_r;
9710 }
9711 
9712 /* "cpostprocessing.pyx":914
9713  * &nodeStarFactor.nsf)
9714  *
9715  * def calculateConservationFluxPWL(np.ndarray nElements_node, # <<<<<<<<<<<<<<
9716  * np.ndarray internalNodes,
9717  * np.ndarray fluxBoundaryNodes,
9718  */
9719 
9720 /* Python wrapper */
9721 static PyObject *__pyx_pw_15cpostprocessing_73calculateConservationFluxPWL(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
9722 static PyMethodDef __pyx_mdef_15cpostprocessing_73calculateConservationFluxPWL = {"calculateConservationFluxPWL", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_73calculateConservationFluxPWL, METH_VARARGS|METH_KEYWORDS, 0};
9723 static PyObject *__pyx_pw_15cpostprocessing_73calculateConservationFluxPWL(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
9724  PyArrayObject *__pyx_v_nElements_node = 0;
9725  PyArrayObject *__pyx_v_internalNodes = 0;
9726  PyArrayObject *__pyx_v_fluxBoundaryNodes = 0;
9727  struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor = 0;
9728  int __pyx_lineno = 0;
9729  const char *__pyx_filename = NULL;
9730  int __pyx_clineno = 0;
9731  PyObject *__pyx_r = 0;
9732  __Pyx_RefNannyDeclarations
9733  __Pyx_RefNannySetupContext("calculateConservationFluxPWL (wrapper)", 0);
9734  {
9735  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_nElements_node,&__pyx_n_s_internalNodes,&__pyx_n_s_fluxBoundaryNodes,&__pyx_n_s_nodeStarFactor,0};
9736  PyObject* values[4] = {0,0,0,0};
9737  if (unlikely(__pyx_kwds)) {
9738  Py_ssize_t kw_args;
9739  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
9740  switch (pos_args) {
9741  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
9742  CYTHON_FALLTHROUGH;
9743  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
9744  CYTHON_FALLTHROUGH;
9745  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
9746  CYTHON_FALLTHROUGH;
9747  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
9748  CYTHON_FALLTHROUGH;
9749  case 0: break;
9750  default: goto __pyx_L5_argtuple_error;
9751  }
9752  kw_args = PyDict_Size(__pyx_kwds);
9753  switch (pos_args) {
9754  case 0:
9755  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nElements_node)) != 0)) kw_args--;
9756  else goto __pyx_L5_argtuple_error;
9757  CYTHON_FALLTHROUGH;
9758  case 1:
9759  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_internalNodes)) != 0)) kw_args--;
9760  else {
9761  __Pyx_RaiseArgtupleInvalid("calculateConservationFluxPWL", 1, 4, 4, 1); __PYX_ERR(0, 914, __pyx_L3_error)
9762  }
9763  CYTHON_FALLTHROUGH;
9764  case 2:
9765  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_fluxBoundaryNodes)) != 0)) kw_args--;
9766  else {
9767  __Pyx_RaiseArgtupleInvalid("calculateConservationFluxPWL", 1, 4, 4, 2); __PYX_ERR(0, 914, __pyx_L3_error)
9768  }
9769  CYTHON_FALLTHROUGH;
9770  case 3:
9771  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarFactor)) != 0)) kw_args--;
9772  else {
9773  __Pyx_RaiseArgtupleInvalid("calculateConservationFluxPWL", 1, 4, 4, 3); __PYX_ERR(0, 914, __pyx_L3_error)
9774  }
9775  }
9776  if (unlikely(kw_args > 0)) {
9777  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "calculateConservationFluxPWL") < 0)) __PYX_ERR(0, 914, __pyx_L3_error)
9778  }
9779  } else if (PyTuple_GET_SIZE(__pyx_args) != 4) {
9780  goto __pyx_L5_argtuple_error;
9781  } else {
9782  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
9783  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
9784  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
9785  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
9786  }
9787  __pyx_v_nElements_node = ((PyArrayObject *)values[0]);
9788  __pyx_v_internalNodes = ((PyArrayObject *)values[1]);
9789  __pyx_v_fluxBoundaryNodes = ((PyArrayObject *)values[2]);
9790  __pyx_v_nodeStarFactor = ((struct __pyx_obj_15cpostprocessing_NodeStarFactor *)values[3]);
9791  }
9792  goto __pyx_L4_argument_unpacking_done;
9793  __pyx_L5_argtuple_error:;
9794  __Pyx_RaiseArgtupleInvalid("calculateConservationFluxPWL", 1, 4, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 914, __pyx_L3_error)
9795  __pyx_L3_error:;
9796  __Pyx_AddTraceback("cpostprocessing.calculateConservationFluxPWL", __pyx_clineno, __pyx_lineno, __pyx_filename);
9797  __Pyx_RefNannyFinishContext();
9798  return NULL;
9799  __pyx_L4_argument_unpacking_done:;
9800  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nElements_node), __pyx_ptype_5numpy_ndarray, 1, "nElements_node", 0))) __PYX_ERR(0, 914, __pyx_L1_error)
9801  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_internalNodes), __pyx_ptype_5numpy_ndarray, 1, "internalNodes", 0))) __PYX_ERR(0, 915, __pyx_L1_error)
9802  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_fluxBoundaryNodes), __pyx_ptype_5numpy_ndarray, 1, "fluxBoundaryNodes", 0))) __PYX_ERR(0, 916, __pyx_L1_error)
9803  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarFactor), __pyx_ptype_15cpostprocessing_NodeStarFactor, 1, "nodeStarFactor", 0))) __PYX_ERR(0, 917, __pyx_L1_error)
9804  __pyx_r = __pyx_pf_15cpostprocessing_72calculateConservationFluxPWL(__pyx_self, __pyx_v_nElements_node, __pyx_v_internalNodes, __pyx_v_fluxBoundaryNodes, __pyx_v_nodeStarFactor);
9805 
9806  /* function exit code */
9807  goto __pyx_L0;
9808  __pyx_L1_error:;
9809  __pyx_r = NULL;
9810  __pyx_L0:;
9811  __Pyx_RefNannyFinishContext();
9812  return __pyx_r;
9813 }
9814 
9815 static PyObject *__pyx_pf_15cpostprocessing_72calculateConservationFluxPWL(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_nElements_node, PyArrayObject *__pyx_v_internalNodes, PyArrayObject *__pyx_v_fluxBoundaryNodes, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor) {
9816  PyObject *__pyx_r = NULL;
9817  __Pyx_RefNannyDeclarations
9818  __Pyx_RefNannySetupContext("calculateConservationFluxPWL", 0);
9819 
9820  /* "cpostprocessing.pyx":918
9821  * np.ndarray fluxBoundaryNodes,
9822  * NodeStarFactor nodeStarFactor):
9823  * pp.calculateConservationFluxPWL(nElements_node.shape[0], # <<<<<<<<<<<<<<
9824  * internalNodes.shape[0],
9825  * <int*>(nElements_node.data),
9826  */
9827  calculateConservationFluxPWL((__pyx_v_nElements_node->dimensions[0]), (__pyx_v_internalNodes->dimensions[0]), ((int *)__pyx_v_nElements_node->data), ((int *)__pyx_v_internalNodes->data), ((int *)__pyx_v_fluxBoundaryNodes->data), (&__pyx_v_nodeStarFactor->nsf));
9828 
9829  /* "cpostprocessing.pyx":914
9830  * &nodeStarFactor.nsf)
9831  *
9832  * def calculateConservationFluxPWL(np.ndarray nElements_node, # <<<<<<<<<<<<<<
9833  * np.ndarray internalNodes,
9834  * np.ndarray fluxBoundaryNodes,
9835  */
9836 
9837  /* function exit code */
9838  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
9839  __Pyx_XGIVEREF(__pyx_r);
9840  __Pyx_RefNannyFinishContext();
9841  return __pyx_r;
9842 }
9843 
9844 /* "cpostprocessing.pyx":925
9845  * &nodeStarFactor.nsf)
9846  *
9847  * def calculateConservationFluxPWL_noNeumannFix(np.ndarray nElements_node, # <<<<<<<<<<<<<<
9848  * NodeStarFactor nodeStarFactor):
9849  * pp.calculateConservationFluxPWL_noNeumannFix(nElements_node.shape[0],
9850  */
9851 
9852 /* Python wrapper */
9853 static PyObject *__pyx_pw_15cpostprocessing_75calculateConservationFluxPWL_noNeumannFix(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
9854 static PyMethodDef __pyx_mdef_15cpostprocessing_75calculateConservationFluxPWL_noNeumannFix = {"calculateConservationFluxPWL_noNeumannFix", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_75calculateConservationFluxPWL_noNeumannFix, METH_VARARGS|METH_KEYWORDS, 0};
9855 static PyObject *__pyx_pw_15cpostprocessing_75calculateConservationFluxPWL_noNeumannFix(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
9856  PyArrayObject *__pyx_v_nElements_node = 0;
9857  struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor = 0;
9858  int __pyx_lineno = 0;
9859  const char *__pyx_filename = NULL;
9860  int __pyx_clineno = 0;
9861  PyObject *__pyx_r = 0;
9862  __Pyx_RefNannyDeclarations
9863  __Pyx_RefNannySetupContext("calculateConservationFluxPWL_noNeumannFix (wrapper)", 0);
9864  {
9865  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_nElements_node,&__pyx_n_s_nodeStarFactor,0};
9866  PyObject* values[2] = {0,0};
9867  if (unlikely(__pyx_kwds)) {
9868  Py_ssize_t kw_args;
9869  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
9870  switch (pos_args) {
9871  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
9872  CYTHON_FALLTHROUGH;
9873  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
9874  CYTHON_FALLTHROUGH;
9875  case 0: break;
9876  default: goto __pyx_L5_argtuple_error;
9877  }
9878  kw_args = PyDict_Size(__pyx_kwds);
9879  switch (pos_args) {
9880  case 0:
9881  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nElements_node)) != 0)) kw_args--;
9882  else goto __pyx_L5_argtuple_error;
9883  CYTHON_FALLTHROUGH;
9884  case 1:
9885  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarFactor)) != 0)) kw_args--;
9886  else {
9887  __Pyx_RaiseArgtupleInvalid("calculateConservationFluxPWL_noNeumannFix", 1, 2, 2, 1); __PYX_ERR(0, 925, __pyx_L3_error)
9888  }
9889  }
9890  if (unlikely(kw_args > 0)) {
9891  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "calculateConservationFluxPWL_noNeumannFix") < 0)) __PYX_ERR(0, 925, __pyx_L3_error)
9892  }
9893  } else if (PyTuple_GET_SIZE(__pyx_args) != 2) {
9894  goto __pyx_L5_argtuple_error;
9895  } else {
9896  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
9897  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
9898  }
9899  __pyx_v_nElements_node = ((PyArrayObject *)values[0]);
9900  __pyx_v_nodeStarFactor = ((struct __pyx_obj_15cpostprocessing_NodeStarFactor *)values[1]);
9901  }
9902  goto __pyx_L4_argument_unpacking_done;
9903  __pyx_L5_argtuple_error:;
9904  __Pyx_RaiseArgtupleInvalid("calculateConservationFluxPWL_noNeumannFix", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 925, __pyx_L3_error)
9905  __pyx_L3_error:;
9906  __Pyx_AddTraceback("cpostprocessing.calculateConservationFluxPWL_noNeumannFix", __pyx_clineno, __pyx_lineno, __pyx_filename);
9907  __Pyx_RefNannyFinishContext();
9908  return NULL;
9909  __pyx_L4_argument_unpacking_done:;
9910  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nElements_node), __pyx_ptype_5numpy_ndarray, 1, "nElements_node", 0))) __PYX_ERR(0, 925, __pyx_L1_error)
9911  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarFactor), __pyx_ptype_15cpostprocessing_NodeStarFactor, 1, "nodeStarFactor", 0))) __PYX_ERR(0, 926, __pyx_L1_error)
9912  __pyx_r = __pyx_pf_15cpostprocessing_74calculateConservationFluxPWL_noNeumannFix(__pyx_self, __pyx_v_nElements_node, __pyx_v_nodeStarFactor);
9913 
9914  /* function exit code */
9915  goto __pyx_L0;
9916  __pyx_L1_error:;
9917  __pyx_r = NULL;
9918  __pyx_L0:;
9919  __Pyx_RefNannyFinishContext();
9920  return __pyx_r;
9921 }
9922 
9923 static PyObject *__pyx_pf_15cpostprocessing_74calculateConservationFluxPWL_noNeumannFix(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_nElements_node, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor) {
9924  PyObject *__pyx_r = NULL;
9925  __Pyx_RefNannyDeclarations
9926  __Pyx_RefNannySetupContext("calculateConservationFluxPWL_noNeumannFix", 0);
9927 
9928  /* "cpostprocessing.pyx":927
9929  * def calculateConservationFluxPWL_noNeumannFix(np.ndarray nElements_node,
9930  * NodeStarFactor nodeStarFactor):
9931  * pp.calculateConservationFluxPWL_noNeumannFix(nElements_node.shape[0], # <<<<<<<<<<<<<<
9932  * <int*>(nElements_node.data),
9933  * &nodeStarFactor.nsf)
9934  */
9935  calculateConservationFluxPWL_noNeumannFix((__pyx_v_nElements_node->dimensions[0]), ((int *)__pyx_v_nElements_node->data), (&__pyx_v_nodeStarFactor->nsf));
9936 
9937  /* "cpostprocessing.pyx":925
9938  * &nodeStarFactor.nsf)
9939  *
9940  * def calculateConservationFluxPWL_noNeumannFix(np.ndarray nElements_node, # <<<<<<<<<<<<<<
9941  * NodeStarFactor nodeStarFactor):
9942  * pp.calculateConservationFluxPWL_noNeumannFix(nElements_node.shape[0],
9943  */
9944 
9945  /* function exit code */
9946  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
9947  __Pyx_XGIVEREF(__pyx_r);
9948  __Pyx_RefNannyFinishContext();
9949  return __pyx_r;
9950 }
9951 
9952 /* "cpostprocessing.pyx":931
9953  * &nodeStarFactor.nsf)
9954  *
9955  * def calculateConservationResidualPWL_opt(int nNodes_owned, # <<<<<<<<<<<<<<
9956  * np.ndarray interiorElementBoundaries,
9957  * np.ndarray exteriorElementBoundaries,
9958  */
9959 
9960 /* Python wrapper */
9961 static PyObject *__pyx_pw_15cpostprocessing_77calculateConservationResidualPWL_opt(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
9962 static PyMethodDef __pyx_mdef_15cpostprocessing_77calculateConservationResidualPWL_opt = {"calculateConservationResidualPWL_opt", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_77calculateConservationResidualPWL_opt, METH_VARARGS|METH_KEYWORDS, 0};
9963 static PyObject *__pyx_pw_15cpostprocessing_77calculateConservationResidualPWL_opt(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
9964  int __pyx_v_nNodes_owned;
9965  PyArrayObject *__pyx_v_interiorElementBoundaries = 0;
9966  PyArrayObject *__pyx_v_exteriorElementBoundaries = 0;
9967  PyArrayObject *__pyx_v_elementBoundaryElements = 0;
9968  PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries = 0;
9969  PyArrayObject *__pyx_v_elementNodes = 0;
9970  PyArrayObject *__pyx_v_nodeStarElements = 0;
9971  PyArrayObject *__pyx_v_nodeStarElementNeighbors = 0;
9972  PyArrayObject *__pyx_v_nElements_node = 0;
9973  PyArrayObject *__pyx_v_fluxElementBoundaries = 0;
9974  PyArrayObject *__pyx_v_elementResidual = 0;
9975  PyArrayObject *__pyx_v_vAverage = 0;
9976  PyArrayObject *__pyx_v_dx = 0;
9977  PyArrayObject *__pyx_v_w = 0;
9978  PyArrayObject *__pyx_v_n = 0;
9979  struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor = 0;
9980  PyArrayObject *__pyx_v_conservationResidual = 0;
9981  PyArrayObject *__pyx_v_vConservative = 0;
9982  PyArrayObject *__pyx_v_vConservative_element = 0;
9983  int __pyx_lineno = 0;
9984  const char *__pyx_filename = NULL;
9985  int __pyx_clineno = 0;
9986  PyObject *__pyx_r = 0;
9987  __Pyx_RefNannyDeclarations
9988  __Pyx_RefNannySetupContext("calculateConservationResidualPWL_opt (wrapper)", 0);
9989  {
9990  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_nNodes_owned,&__pyx_n_s_interiorElementBoundaries,&__pyx_n_s_exteriorElementBoundaries,&__pyx_n_s_elementBoundaryElements,&__pyx_n_s_elementBoundaryLocalElementBound,&__pyx_n_s_elementNodes,&__pyx_n_s_nodeStarElements,&__pyx_n_s_nodeStarElementNeighbors,&__pyx_n_s_nElements_node,&__pyx_n_s_fluxElementBoundaries,&__pyx_n_s_elementResidual,&__pyx_n_s_vAverage,&__pyx_n_s_dx,&__pyx_n_s_w,&__pyx_n_s_n,&__pyx_n_s_nodeStarFactor,&__pyx_n_s_conservationResidual,&__pyx_n_s_vConservative,&__pyx_n_s_vConservative_element,0};
9991  PyObject* values[19] = {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0};
9992  if (unlikely(__pyx_kwds)) {
9993  Py_ssize_t kw_args;
9994  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
9995  switch (pos_args) {
9996  case 19: values[18] = PyTuple_GET_ITEM(__pyx_args, 18);
9997  CYTHON_FALLTHROUGH;
9998  case 18: values[17] = PyTuple_GET_ITEM(__pyx_args, 17);
9999  CYTHON_FALLTHROUGH;
10000  case 17: values[16] = PyTuple_GET_ITEM(__pyx_args, 16);
10001  CYTHON_FALLTHROUGH;
10002  case 16: values[15] = PyTuple_GET_ITEM(__pyx_args, 15);
10003  CYTHON_FALLTHROUGH;
10004  case 15: values[14] = PyTuple_GET_ITEM(__pyx_args, 14);
10005  CYTHON_FALLTHROUGH;
10006  case 14: values[13] = PyTuple_GET_ITEM(__pyx_args, 13);
10007  CYTHON_FALLTHROUGH;
10008  case 13: values[12] = PyTuple_GET_ITEM(__pyx_args, 12);
10009  CYTHON_FALLTHROUGH;
10010  case 12: values[11] = PyTuple_GET_ITEM(__pyx_args, 11);
10011  CYTHON_FALLTHROUGH;
10012  case 11: values[10] = PyTuple_GET_ITEM(__pyx_args, 10);
10013  CYTHON_FALLTHROUGH;
10014  case 10: values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
10015  CYTHON_FALLTHROUGH;
10016  case 9: values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
10017  CYTHON_FALLTHROUGH;
10018  case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
10019  CYTHON_FALLTHROUGH;
10020  case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
10021  CYTHON_FALLTHROUGH;
10022  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
10023  CYTHON_FALLTHROUGH;
10024  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
10025  CYTHON_FALLTHROUGH;
10026  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
10027  CYTHON_FALLTHROUGH;
10028  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
10029  CYTHON_FALLTHROUGH;
10030  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
10031  CYTHON_FALLTHROUGH;
10032  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
10033  CYTHON_FALLTHROUGH;
10034  case 0: break;
10035  default: goto __pyx_L5_argtuple_error;
10036  }
10037  kw_args = PyDict_Size(__pyx_kwds);
10038  switch (pos_args) {
10039  case 0:
10040  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nNodes_owned)) != 0)) kw_args--;
10041  else goto __pyx_L5_argtuple_error;
10042  CYTHON_FALLTHROUGH;
10043  case 1:
10044  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_interiorElementBoundaries)) != 0)) kw_args--;
10045  else {
10046  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_opt", 1, 19, 19, 1); __PYX_ERR(0, 931, __pyx_L3_error)
10047  }
10048  CYTHON_FALLTHROUGH;
10049  case 2:
10050  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_exteriorElementBoundaries)) != 0)) kw_args--;
10051  else {
10052  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_opt", 1, 19, 19, 2); __PYX_ERR(0, 931, __pyx_L3_error)
10053  }
10054  CYTHON_FALLTHROUGH;
10055  case 3:
10056  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryElements)) != 0)) kw_args--;
10057  else {
10058  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_opt", 1, 19, 19, 3); __PYX_ERR(0, 931, __pyx_L3_error)
10059  }
10060  CYTHON_FALLTHROUGH;
10061  case 4:
10062  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryLocalElementBound)) != 0)) kw_args--;
10063  else {
10064  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_opt", 1, 19, 19, 4); __PYX_ERR(0, 931, __pyx_L3_error)
10065  }
10066  CYTHON_FALLTHROUGH;
10067  case 5:
10068  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementNodes)) != 0)) kw_args--;
10069  else {
10070  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_opt", 1, 19, 19, 5); __PYX_ERR(0, 931, __pyx_L3_error)
10071  }
10072  CYTHON_FALLTHROUGH;
10073  case 6:
10074  if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarElements)) != 0)) kw_args--;
10075  else {
10076  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_opt", 1, 19, 19, 6); __PYX_ERR(0, 931, __pyx_L3_error)
10077  }
10078  CYTHON_FALLTHROUGH;
10079  case 7:
10080  if (likely((values[7] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarElementNeighbors)) != 0)) kw_args--;
10081  else {
10082  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_opt", 1, 19, 19, 7); __PYX_ERR(0, 931, __pyx_L3_error)
10083  }
10084  CYTHON_FALLTHROUGH;
10085  case 8:
10086  if (likely((values[8] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nElements_node)) != 0)) kw_args--;
10087  else {
10088  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_opt", 1, 19, 19, 8); __PYX_ERR(0, 931, __pyx_L3_error)
10089  }
10090  CYTHON_FALLTHROUGH;
10091  case 9:
10092  if (likely((values[9] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_fluxElementBoundaries)) != 0)) kw_args--;
10093  else {
10094  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_opt", 1, 19, 19, 9); __PYX_ERR(0, 931, __pyx_L3_error)
10095  }
10096  CYTHON_FALLTHROUGH;
10097  case 10:
10098  if (likely((values[10] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementResidual)) != 0)) kw_args--;
10099  else {
10100  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_opt", 1, 19, 19, 10); __PYX_ERR(0, 931, __pyx_L3_error)
10101  }
10102  CYTHON_FALLTHROUGH;
10103  case 11:
10104  if (likely((values[11] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_vAverage)) != 0)) kw_args--;
10105  else {
10106  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_opt", 1, 19, 19, 11); __PYX_ERR(0, 931, __pyx_L3_error)
10107  }
10108  CYTHON_FALLTHROUGH;
10109  case 12:
10110  if (likely((values[12] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_dx)) != 0)) kw_args--;
10111  else {
10112  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_opt", 1, 19, 19, 12); __PYX_ERR(0, 931, __pyx_L3_error)
10113  }
10114  CYTHON_FALLTHROUGH;
10115  case 13:
10116  if (likely((values[13] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_w)) != 0)) kw_args--;
10117  else {
10118  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_opt", 1, 19, 19, 13); __PYX_ERR(0, 931, __pyx_L3_error)
10119  }
10120  CYTHON_FALLTHROUGH;
10121  case 14:
10122  if (likely((values[14] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_n)) != 0)) kw_args--;
10123  else {
10124  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_opt", 1, 19, 19, 14); __PYX_ERR(0, 931, __pyx_L3_error)
10125  }
10126  CYTHON_FALLTHROUGH;
10127  case 15:
10128  if (likely((values[15] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarFactor)) != 0)) kw_args--;
10129  else {
10130  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_opt", 1, 19, 19, 15); __PYX_ERR(0, 931, __pyx_L3_error)
10131  }
10132  CYTHON_FALLTHROUGH;
10133  case 16:
10134  if (likely((values[16] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_conservationResidual)) != 0)) kw_args--;
10135  else {
10136  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_opt", 1, 19, 19, 16); __PYX_ERR(0, 931, __pyx_L3_error)
10137  }
10138  CYTHON_FALLTHROUGH;
10139  case 17:
10140  if (likely((values[17] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_vConservative)) != 0)) kw_args--;
10141  else {
10142  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_opt", 1, 19, 19, 17); __PYX_ERR(0, 931, __pyx_L3_error)
10143  }
10144  CYTHON_FALLTHROUGH;
10145  case 18:
10146  if (likely((values[18] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_vConservative_element)) != 0)) kw_args--;
10147  else {
10148  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_opt", 1, 19, 19, 18); __PYX_ERR(0, 931, __pyx_L3_error)
10149  }
10150  }
10151  if (unlikely(kw_args > 0)) {
10152  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "calculateConservationResidualPWL_opt") < 0)) __PYX_ERR(0, 931, __pyx_L3_error)
10153  }
10154  } else if (PyTuple_GET_SIZE(__pyx_args) != 19) {
10155  goto __pyx_L5_argtuple_error;
10156  } else {
10157  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
10158  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
10159  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
10160  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
10161  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
10162  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
10163  values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
10164  values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
10165  values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
10166  values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
10167  values[10] = PyTuple_GET_ITEM(__pyx_args, 10);
10168  values[11] = PyTuple_GET_ITEM(__pyx_args, 11);
10169  values[12] = PyTuple_GET_ITEM(__pyx_args, 12);
10170  values[13] = PyTuple_GET_ITEM(__pyx_args, 13);
10171  values[14] = PyTuple_GET_ITEM(__pyx_args, 14);
10172  values[15] = PyTuple_GET_ITEM(__pyx_args, 15);
10173  values[16] = PyTuple_GET_ITEM(__pyx_args, 16);
10174  values[17] = PyTuple_GET_ITEM(__pyx_args, 17);
10175  values[18] = PyTuple_GET_ITEM(__pyx_args, 18);
10176  }
10177  __pyx_v_nNodes_owned = __Pyx_PyInt_As_int(values[0]); if (unlikely((__pyx_v_nNodes_owned == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 931, __pyx_L3_error)
10178  __pyx_v_interiorElementBoundaries = ((PyArrayObject *)values[1]);
10179  __pyx_v_exteriorElementBoundaries = ((PyArrayObject *)values[2]);
10180  __pyx_v_elementBoundaryElements = ((PyArrayObject *)values[3]);
10181  __pyx_v_elementBoundaryLocalElementBoundaries = ((PyArrayObject *)values[4]);
10182  __pyx_v_elementNodes = ((PyArrayObject *)values[5]);
10183  __pyx_v_nodeStarElements = ((PyArrayObject *)values[6]);
10184  __pyx_v_nodeStarElementNeighbors = ((PyArrayObject *)values[7]);
10185  __pyx_v_nElements_node = ((PyArrayObject *)values[8]);
10186  __pyx_v_fluxElementBoundaries = ((PyArrayObject *)values[9]);
10187  __pyx_v_elementResidual = ((PyArrayObject *)values[10]);
10188  __pyx_v_vAverage = ((PyArrayObject *)values[11]);
10189  __pyx_v_dx = ((PyArrayObject *)values[12]);
10190  __pyx_v_w = ((PyArrayObject *)values[13]);
10191  __pyx_v_n = ((PyArrayObject *)values[14]);
10192  __pyx_v_nodeStarFactor = ((struct __pyx_obj_15cpostprocessing_NodeStarFactor *)values[15]);
10193  __pyx_v_conservationResidual = ((PyArrayObject *)values[16]);
10194  __pyx_v_vConservative = ((PyArrayObject *)values[17]);
10195  __pyx_v_vConservative_element = ((PyArrayObject *)values[18]);
10196  }
10197  goto __pyx_L4_argument_unpacking_done;
10198  __pyx_L5_argtuple_error:;
10199  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_opt", 1, 19, 19, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 931, __pyx_L3_error)
10200  __pyx_L3_error:;
10201  __Pyx_AddTraceback("cpostprocessing.calculateConservationResidualPWL_opt", __pyx_clineno, __pyx_lineno, __pyx_filename);
10202  __Pyx_RefNannyFinishContext();
10203  return NULL;
10204  __pyx_L4_argument_unpacking_done:;
10205  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_interiorElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "interiorElementBoundaries", 0))) __PYX_ERR(0, 932, __pyx_L1_error)
10206  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_exteriorElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "exteriorElementBoundaries", 0))) __PYX_ERR(0, 933, __pyx_L1_error)
10207  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryElements), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryElements", 0))) __PYX_ERR(0, 934, __pyx_L1_error)
10208  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryLocalElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryLocalElementBoundaries", 0))) __PYX_ERR(0, 935, __pyx_L1_error)
10209  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementNodes), __pyx_ptype_5numpy_ndarray, 1, "elementNodes", 0))) __PYX_ERR(0, 936, __pyx_L1_error)
10210  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarElements), __pyx_ptype_5numpy_ndarray, 1, "nodeStarElements", 0))) __PYX_ERR(0, 937, __pyx_L1_error)
10211  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarElementNeighbors), __pyx_ptype_5numpy_ndarray, 1, "nodeStarElementNeighbors", 0))) __PYX_ERR(0, 938, __pyx_L1_error)
10212  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nElements_node), __pyx_ptype_5numpy_ndarray, 1, "nElements_node", 0))) __PYX_ERR(0, 939, __pyx_L1_error)
10213  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_fluxElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "fluxElementBoundaries", 0))) __PYX_ERR(0, 940, __pyx_L1_error)
10214  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementResidual), __pyx_ptype_5numpy_ndarray, 1, "elementResidual", 0))) __PYX_ERR(0, 941, __pyx_L1_error)
10215  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_vAverage), __pyx_ptype_5numpy_ndarray, 1, "vAverage", 0))) __PYX_ERR(0, 942, __pyx_L1_error)
10216  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dx), __pyx_ptype_5numpy_ndarray, 1, "dx", 0))) __PYX_ERR(0, 943, __pyx_L1_error)
10217  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_w), __pyx_ptype_5numpy_ndarray, 1, "w", 0))) __PYX_ERR(0, 944, __pyx_L1_error)
10218  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_n), __pyx_ptype_5numpy_ndarray, 1, "n", 0))) __PYX_ERR(0, 945, __pyx_L1_error)
10219  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarFactor), __pyx_ptype_15cpostprocessing_NodeStarFactor, 1, "nodeStarFactor", 0))) __PYX_ERR(0, 946, __pyx_L1_error)
10220  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_conservationResidual), __pyx_ptype_5numpy_ndarray, 1, "conservationResidual", 0))) __PYX_ERR(0, 947, __pyx_L1_error)
10221  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_vConservative), __pyx_ptype_5numpy_ndarray, 1, "vConservative", 0))) __PYX_ERR(0, 948, __pyx_L1_error)
10222  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_vConservative_element), __pyx_ptype_5numpy_ndarray, 1, "vConservative_element", 0))) __PYX_ERR(0, 949, __pyx_L1_error)
10223  __pyx_r = __pyx_pf_15cpostprocessing_76calculateConservationResidualPWL_opt(__pyx_self, __pyx_v_nNodes_owned, __pyx_v_interiorElementBoundaries, __pyx_v_exteriorElementBoundaries, __pyx_v_elementBoundaryElements, __pyx_v_elementBoundaryLocalElementBoundaries, __pyx_v_elementNodes, __pyx_v_nodeStarElements, __pyx_v_nodeStarElementNeighbors, __pyx_v_nElements_node, __pyx_v_fluxElementBoundaries, __pyx_v_elementResidual, __pyx_v_vAverage, __pyx_v_dx, __pyx_v_w, __pyx_v_n, __pyx_v_nodeStarFactor, __pyx_v_conservationResidual, __pyx_v_vConservative, __pyx_v_vConservative_element);
10224 
10225  /* function exit code */
10226  goto __pyx_L0;
10227  __pyx_L1_error:;
10228  __pyx_r = NULL;
10229  __pyx_L0:;
10230  __Pyx_RefNannyFinishContext();
10231  return __pyx_r;
10232 }
10233 
10234 static PyObject *__pyx_pf_15cpostprocessing_76calculateConservationResidualPWL_opt(CYTHON_UNUSED PyObject *__pyx_self, int __pyx_v_nNodes_owned, PyArrayObject *__pyx_v_interiorElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries, PyArrayObject *__pyx_v_elementNodes, PyArrayObject *__pyx_v_nodeStarElements, PyArrayObject *__pyx_v_nodeStarElementNeighbors, PyArrayObject *__pyx_v_nElements_node, PyArrayObject *__pyx_v_fluxElementBoundaries, PyArrayObject *__pyx_v_elementResidual, PyArrayObject *__pyx_v_vAverage, PyArrayObject *__pyx_v_dx, PyArrayObject *__pyx_v_w, PyArrayObject *__pyx_v_n, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor, PyArrayObject *__pyx_v_conservationResidual, PyArrayObject *__pyx_v_vConservative, PyArrayObject *__pyx_v_vConservative_element) {
10235  PyObject *__pyx_r = NULL;
10236  __Pyx_RefNannyDeclarations
10237  __Pyx_RefNannySetupContext("calculateConservationResidualPWL_opt", 0);
10238 
10239  /* "cpostprocessing.pyx":950
10240  * np.ndarray vConservative,
10241  * np.ndarray vConservative_element):
10242  * pp.calculateConservationResidualPWL_opt(nNodes_owned, # <<<<<<<<<<<<<<
10243  * w.shape[0],
10244  * interiorElementBoundaries.shape[0],
10245  */
10246  calculateConservationResidualPWL_opt(__pyx_v_nNodes_owned, (__pyx_v_w->dimensions[0]), (__pyx_v_interiorElementBoundaries->dimensions[0]), (__pyx_v_exteriorElementBoundaries->dimensions[0]), (__pyx_v_w->dimensions[1]), (__pyx_v_w->dimensions[2]), (__pyx_v_w->dimensions[3]), (__pyx_v_n->dimensions[2]), ((int *)__pyx_v_interiorElementBoundaries->data), ((int *)__pyx_v_exteriorElementBoundaries->data), ((int *)__pyx_v_elementBoundaryElements->data), ((int *)__pyx_v_elementBoundaryLocalElementBoundaries->data), ((int *)__pyx_v_elementNodes->data), ((int *)__pyx_v_nodeStarElements->data), ((int *)__pyx_v_nodeStarElementNeighbors->data), ((int *)__pyx_v_nElements_node->data), ((int *)__pyx_v_fluxElementBoundaries->data), ((double *)__pyx_v_elementResidual->data), ((double *)__pyx_v_vAverage->data), ((double *)__pyx_v_dx->data), ((double *)__pyx_v_w->data), ((double *)__pyx_v_n->data), (&__pyx_v_nodeStarFactor->nsf), ((double *)__pyx_v_conservationResidual->data), ((double *)__pyx_v_vConservative->data), ((double *)__pyx_v_vConservative_element->data));
10247 
10248  /* "cpostprocessing.pyx":931
10249  * &nodeStarFactor.nsf)
10250  *
10251  * def calculateConservationResidualPWL_opt(int nNodes_owned, # <<<<<<<<<<<<<<
10252  * np.ndarray interiorElementBoundaries,
10253  * np.ndarray exteriorElementBoundaries,
10254  */
10255 
10256  /* function exit code */
10257  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
10258  __Pyx_XGIVEREF(__pyx_r);
10259  __Pyx_RefNannyFinishContext();
10260  return __pyx_r;
10261 }
10262 
10263 /* "cpostprocessing.pyx":977
10264  * <double*>(vConservative_element.data))
10265  *
10266  * def calculateConservationResidualPWL_primative(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
10267  * np.ndarray exteriorElementBoundaries,
10268  * np.ndarray elementBoundaryElements,
10269  */
10270 
10271 /* Python wrapper */
10272 static PyObject *__pyx_pw_15cpostprocessing_79calculateConservationResidualPWL_primative(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
10273 static PyMethodDef __pyx_mdef_15cpostprocessing_79calculateConservationResidualPWL_primative = {"calculateConservationResidualPWL_primative", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_79calculateConservationResidualPWL_primative, METH_VARARGS|METH_KEYWORDS, 0};
10274 static PyObject *__pyx_pw_15cpostprocessing_79calculateConservationResidualPWL_primative(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
10275  PyArrayObject *__pyx_v_interiorElementBoundaries = 0;
10276  PyArrayObject *__pyx_v_exteriorElementBoundaries = 0;
10277  PyArrayObject *__pyx_v_elementBoundaryElements = 0;
10278  PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries = 0;
10279  PyArrayObject *__pyx_v_skipflag_elementBoundaries = 0;
10280  PyArrayObject *__pyx_v_elementResidual = 0;
10281  PyArrayObject *__pyx_v_dx = 0;
10282  PyArrayObject *__pyx_v_n = 0;
10283  PyArrayObject *__pyx_v_conservationResidual = 0;
10284  PyArrayObject *__pyx_v_vConservative = 0;
10285  int __pyx_lineno = 0;
10286  const char *__pyx_filename = NULL;
10287  int __pyx_clineno = 0;
10288  PyObject *__pyx_r = 0;
10289  __Pyx_RefNannyDeclarations
10290  __Pyx_RefNannySetupContext("calculateConservationResidualPWL_primative (wrapper)", 0);
10291  {
10292  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_interiorElementBoundaries,&__pyx_n_s_exteriorElementBoundaries,&__pyx_n_s_elementBoundaryElements,&__pyx_n_s_elementBoundaryLocalElementBound,&__pyx_n_s_skipflag_elementBoundaries,&__pyx_n_s_elementResidual,&__pyx_n_s_dx,&__pyx_n_s_n,&__pyx_n_s_conservationResidual,&__pyx_n_s_vConservative,0};
10293  PyObject* values[10] = {0,0,0,0,0,0,0,0,0,0};
10294  if (unlikely(__pyx_kwds)) {
10295  Py_ssize_t kw_args;
10296  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
10297  switch (pos_args) {
10298  case 10: values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
10299  CYTHON_FALLTHROUGH;
10300  case 9: values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
10301  CYTHON_FALLTHROUGH;
10302  case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
10303  CYTHON_FALLTHROUGH;
10304  case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
10305  CYTHON_FALLTHROUGH;
10306  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
10307  CYTHON_FALLTHROUGH;
10308  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
10309  CYTHON_FALLTHROUGH;
10310  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
10311  CYTHON_FALLTHROUGH;
10312  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
10313  CYTHON_FALLTHROUGH;
10314  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
10315  CYTHON_FALLTHROUGH;
10316  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
10317  CYTHON_FALLTHROUGH;
10318  case 0: break;
10319  default: goto __pyx_L5_argtuple_error;
10320  }
10321  kw_args = PyDict_Size(__pyx_kwds);
10322  switch (pos_args) {
10323  case 0:
10324  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_interiorElementBoundaries)) != 0)) kw_args--;
10325  else goto __pyx_L5_argtuple_error;
10326  CYTHON_FALLTHROUGH;
10327  case 1:
10328  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_exteriorElementBoundaries)) != 0)) kw_args--;
10329  else {
10330  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_primative", 1, 10, 10, 1); __PYX_ERR(0, 977, __pyx_L3_error)
10331  }
10332  CYTHON_FALLTHROUGH;
10333  case 2:
10334  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryElements)) != 0)) kw_args--;
10335  else {
10336  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_primative", 1, 10, 10, 2); __PYX_ERR(0, 977, __pyx_L3_error)
10337  }
10338  CYTHON_FALLTHROUGH;
10339  case 3:
10340  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryLocalElementBound)) != 0)) kw_args--;
10341  else {
10342  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_primative", 1, 10, 10, 3); __PYX_ERR(0, 977, __pyx_L3_error)
10343  }
10344  CYTHON_FALLTHROUGH;
10345  case 4:
10346  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_skipflag_elementBoundaries)) != 0)) kw_args--;
10347  else {
10348  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_primative", 1, 10, 10, 4); __PYX_ERR(0, 977, __pyx_L3_error)
10349  }
10350  CYTHON_FALLTHROUGH;
10351  case 5:
10352  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementResidual)) != 0)) kw_args--;
10353  else {
10354  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_primative", 1, 10, 10, 5); __PYX_ERR(0, 977, __pyx_L3_error)
10355  }
10356  CYTHON_FALLTHROUGH;
10357  case 6:
10358  if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_dx)) != 0)) kw_args--;
10359  else {
10360  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_primative", 1, 10, 10, 6); __PYX_ERR(0, 977, __pyx_L3_error)
10361  }
10362  CYTHON_FALLTHROUGH;
10363  case 7:
10364  if (likely((values[7] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_n)) != 0)) kw_args--;
10365  else {
10366  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_primative", 1, 10, 10, 7); __PYX_ERR(0, 977, __pyx_L3_error)
10367  }
10368  CYTHON_FALLTHROUGH;
10369  case 8:
10370  if (likely((values[8] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_conservationResidual)) != 0)) kw_args--;
10371  else {
10372  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_primative", 1, 10, 10, 8); __PYX_ERR(0, 977, __pyx_L3_error)
10373  }
10374  CYTHON_FALLTHROUGH;
10375  case 9:
10376  if (likely((values[9] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_vConservative)) != 0)) kw_args--;
10377  else {
10378  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_primative", 1, 10, 10, 9); __PYX_ERR(0, 977, __pyx_L3_error)
10379  }
10380  }
10381  if (unlikely(kw_args > 0)) {
10382  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "calculateConservationResidualPWL_primative") < 0)) __PYX_ERR(0, 977, __pyx_L3_error)
10383  }
10384  } else if (PyTuple_GET_SIZE(__pyx_args) != 10) {
10385  goto __pyx_L5_argtuple_error;
10386  } else {
10387  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
10388  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
10389  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
10390  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
10391  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
10392  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
10393  values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
10394  values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
10395  values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
10396  values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
10397  }
10398  __pyx_v_interiorElementBoundaries = ((PyArrayObject *)values[0]);
10399  __pyx_v_exteriorElementBoundaries = ((PyArrayObject *)values[1]);
10400  __pyx_v_elementBoundaryElements = ((PyArrayObject *)values[2]);
10401  __pyx_v_elementBoundaryLocalElementBoundaries = ((PyArrayObject *)values[3]);
10402  __pyx_v_skipflag_elementBoundaries = ((PyArrayObject *)values[4]);
10403  __pyx_v_elementResidual = ((PyArrayObject *)values[5]);
10404  __pyx_v_dx = ((PyArrayObject *)values[6]);
10405  __pyx_v_n = ((PyArrayObject *)values[7]);
10406  __pyx_v_conservationResidual = ((PyArrayObject *)values[8]);
10407  __pyx_v_vConservative = ((PyArrayObject *)values[9]);
10408  }
10409  goto __pyx_L4_argument_unpacking_done;
10410  __pyx_L5_argtuple_error:;
10411  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_primative", 1, 10, 10, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 977, __pyx_L3_error)
10412  __pyx_L3_error:;
10413  __Pyx_AddTraceback("cpostprocessing.calculateConservationResidualPWL_primative", __pyx_clineno, __pyx_lineno, __pyx_filename);
10414  __Pyx_RefNannyFinishContext();
10415  return NULL;
10416  __pyx_L4_argument_unpacking_done:;
10417  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_interiorElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "interiorElementBoundaries", 0))) __PYX_ERR(0, 977, __pyx_L1_error)
10418  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_exteriorElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "exteriorElementBoundaries", 0))) __PYX_ERR(0, 978, __pyx_L1_error)
10419  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryElements), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryElements", 0))) __PYX_ERR(0, 979, __pyx_L1_error)
10420  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryLocalElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryLocalElementBoundaries", 0))) __PYX_ERR(0, 980, __pyx_L1_error)
10421  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_skipflag_elementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "skipflag_elementBoundaries", 0))) __PYX_ERR(0, 981, __pyx_L1_error)
10422  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementResidual), __pyx_ptype_5numpy_ndarray, 1, "elementResidual", 0))) __PYX_ERR(0, 982, __pyx_L1_error)
10423  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dx), __pyx_ptype_5numpy_ndarray, 1, "dx", 0))) __PYX_ERR(0, 983, __pyx_L1_error)
10424  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_n), __pyx_ptype_5numpy_ndarray, 1, "n", 0))) __PYX_ERR(0, 984, __pyx_L1_error)
10425  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_conservationResidual), __pyx_ptype_5numpy_ndarray, 1, "conservationResidual", 0))) __PYX_ERR(0, 985, __pyx_L1_error)
10426  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_vConservative), __pyx_ptype_5numpy_ndarray, 1, "vConservative", 0))) __PYX_ERR(0, 986, __pyx_L1_error)
10427  __pyx_r = __pyx_pf_15cpostprocessing_78calculateConservationResidualPWL_primative(__pyx_self, __pyx_v_interiorElementBoundaries, __pyx_v_exteriorElementBoundaries, __pyx_v_elementBoundaryElements, __pyx_v_elementBoundaryLocalElementBoundaries, __pyx_v_skipflag_elementBoundaries, __pyx_v_elementResidual, __pyx_v_dx, __pyx_v_n, __pyx_v_conservationResidual, __pyx_v_vConservative);
10428 
10429  /* function exit code */
10430  goto __pyx_L0;
10431  __pyx_L1_error:;
10432  __pyx_r = NULL;
10433  __pyx_L0:;
10434  __Pyx_RefNannyFinishContext();
10435  return __pyx_r;
10436 }
10437 
10438 static PyObject *__pyx_pf_15cpostprocessing_78calculateConservationResidualPWL_primative(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_interiorElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries, PyArrayObject *__pyx_v_skipflag_elementBoundaries, PyArrayObject *__pyx_v_elementResidual, PyArrayObject *__pyx_v_dx, PyArrayObject *__pyx_v_n, PyArrayObject *__pyx_v_conservationResidual, PyArrayObject *__pyx_v_vConservative) {
10439  PyObject *__pyx_r = NULL;
10440  __Pyx_RefNannyDeclarations
10441  __Pyx_RefNannySetupContext("calculateConservationResidualPWL_primative", 0);
10442 
10443  /* "cpostprocessing.pyx":987
10444  * np.ndarray conservationResidual,
10445  * np.ndarray vConservative):
10446  * pp.calculateConservationResidualPWL_primative(dx.shape[0], # <<<<<<<<<<<<<<
10447  * interiorElementBoundaries.shape[0],
10448  * exteriorElementBoundaries.shape[0],
10449  */
10450  calculateConservationResidualPWL_primative((__pyx_v_dx->dimensions[0]), (__pyx_v_interiorElementBoundaries->dimensions[0]), (__pyx_v_exteriorElementBoundaries->dimensions[0]), (__pyx_v_dx->dimensions[1]), (__pyx_v_dx->dimensions[2]), (__pyx_v_elementResidual->dimensions[1]), (__pyx_v_n->dimensions[2]), ((int *)__pyx_v_interiorElementBoundaries->data), ((int *)__pyx_v_exteriorElementBoundaries->data), ((int *)__pyx_v_elementBoundaryElements->data), ((int *)__pyx_v_elementBoundaryLocalElementBoundaries->data), ((int *)__pyx_v_skipflag_elementBoundaries->data), ((double *)__pyx_v_elementResidual->data), ((double *)__pyx_v_dx->data), ((double *)__pyx_v_n->data), ((double *)__pyx_v_conservationResidual->data), ((double *)__pyx_v_vConservative->data));
10451 
10452  /* "cpostprocessing.pyx":977
10453  * <double*>(vConservative_element.data))
10454  *
10455  * def calculateConservationResidualPWL_primative(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
10456  * np.ndarray exteriorElementBoundaries,
10457  * np.ndarray elementBoundaryElements,
10458  */
10459 
10460  /* function exit code */
10461  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
10462  __Pyx_XGIVEREF(__pyx_r);
10463  __Pyx_RefNannyFinishContext();
10464  return __pyx_r;
10465 }
10466 
10467 /* "cpostprocessing.pyx":1005
10468  * <double*>(vConservative.data))
10469  *
10470  * def calculateConservationJacobianPWL_opt(int nNodes_owned, # <<<<<<<<<<<<<<
10471  * np.ndarray interiorElementBoundaries,
10472  * np.ndarray exteriorElementBoundaries,
10473  */
10474 
10475 /* Python wrapper */
10476 static PyObject *__pyx_pw_15cpostprocessing_81calculateConservationJacobianPWL_opt(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
10477 static PyMethodDef __pyx_mdef_15cpostprocessing_81calculateConservationJacobianPWL_opt = {"calculateConservationJacobianPWL_opt", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_81calculateConservationJacobianPWL_opt, METH_VARARGS|METH_KEYWORDS, 0};
10478 static PyObject *__pyx_pw_15cpostprocessing_81calculateConservationJacobianPWL_opt(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
10479  int __pyx_v_nNodes_owned;
10480  PyArrayObject *__pyx_v_interiorElementBoundaries = 0;
10481  PyArrayObject *__pyx_v_exteriorElementBoundaries = 0;
10482  PyArrayObject *__pyx_v_elementBoundaryElements = 0;
10483  PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries = 0;
10484  PyArrayObject *__pyx_v_elementNodes = 0;
10485  PyArrayObject *__pyx_v_nodeStarElements = 0;
10486  PyArrayObject *__pyx_v_nodeStarElementNeighbors = 0;
10487  PyArrayObject *__pyx_v_nElements_node = 0;
10488  PyArrayObject *__pyx_v_internalNodes = 0;
10489  PyArrayObject *__pyx_v_fluxElementBoundaries = 0;
10490  PyArrayObject *__pyx_v_fluxBoundaryNodes = 0;
10491  PyArrayObject *__pyx_v_w = 0;
10492  PyArrayObject *__pyx_v_n = 0;
10493  struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor = 0;
10494  int __pyx_lineno = 0;
10495  const char *__pyx_filename = NULL;
10496  int __pyx_clineno = 0;
10497  PyObject *__pyx_r = 0;
10498  __Pyx_RefNannyDeclarations
10499  __Pyx_RefNannySetupContext("calculateConservationJacobianPWL_opt (wrapper)", 0);
10500  {
10501  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_nNodes_owned,&__pyx_n_s_interiorElementBoundaries,&__pyx_n_s_exteriorElementBoundaries,&__pyx_n_s_elementBoundaryElements,&__pyx_n_s_elementBoundaryLocalElementBound,&__pyx_n_s_elementNodes,&__pyx_n_s_nodeStarElements,&__pyx_n_s_nodeStarElementNeighbors,&__pyx_n_s_nElements_node,&__pyx_n_s_internalNodes,&__pyx_n_s_fluxElementBoundaries,&__pyx_n_s_fluxBoundaryNodes,&__pyx_n_s_w,&__pyx_n_s_n,&__pyx_n_s_nodeStarFactor,0};
10502  PyObject* values[15] = {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0};
10503  if (unlikely(__pyx_kwds)) {
10504  Py_ssize_t kw_args;
10505  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
10506  switch (pos_args) {
10507  case 15: values[14] = PyTuple_GET_ITEM(__pyx_args, 14);
10508  CYTHON_FALLTHROUGH;
10509  case 14: values[13] = PyTuple_GET_ITEM(__pyx_args, 13);
10510  CYTHON_FALLTHROUGH;
10511  case 13: values[12] = PyTuple_GET_ITEM(__pyx_args, 12);
10512  CYTHON_FALLTHROUGH;
10513  case 12: values[11] = PyTuple_GET_ITEM(__pyx_args, 11);
10514  CYTHON_FALLTHROUGH;
10515  case 11: values[10] = PyTuple_GET_ITEM(__pyx_args, 10);
10516  CYTHON_FALLTHROUGH;
10517  case 10: values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
10518  CYTHON_FALLTHROUGH;
10519  case 9: values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
10520  CYTHON_FALLTHROUGH;
10521  case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
10522  CYTHON_FALLTHROUGH;
10523  case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
10524  CYTHON_FALLTHROUGH;
10525  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
10526  CYTHON_FALLTHROUGH;
10527  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
10528  CYTHON_FALLTHROUGH;
10529  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
10530  CYTHON_FALLTHROUGH;
10531  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
10532  CYTHON_FALLTHROUGH;
10533  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
10534  CYTHON_FALLTHROUGH;
10535  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
10536  CYTHON_FALLTHROUGH;
10537  case 0: break;
10538  default: goto __pyx_L5_argtuple_error;
10539  }
10540  kw_args = PyDict_Size(__pyx_kwds);
10541  switch (pos_args) {
10542  case 0:
10543  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nNodes_owned)) != 0)) kw_args--;
10544  else goto __pyx_L5_argtuple_error;
10545  CYTHON_FALLTHROUGH;
10546  case 1:
10547  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_interiorElementBoundaries)) != 0)) kw_args--;
10548  else {
10549  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_opt", 1, 15, 15, 1); __PYX_ERR(0, 1005, __pyx_L3_error)
10550  }
10551  CYTHON_FALLTHROUGH;
10552  case 2:
10553  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_exteriorElementBoundaries)) != 0)) kw_args--;
10554  else {
10555  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_opt", 1, 15, 15, 2); __PYX_ERR(0, 1005, __pyx_L3_error)
10556  }
10557  CYTHON_FALLTHROUGH;
10558  case 3:
10559  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryElements)) != 0)) kw_args--;
10560  else {
10561  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_opt", 1, 15, 15, 3); __PYX_ERR(0, 1005, __pyx_L3_error)
10562  }
10563  CYTHON_FALLTHROUGH;
10564  case 4:
10565  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryLocalElementBound)) != 0)) kw_args--;
10566  else {
10567  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_opt", 1, 15, 15, 4); __PYX_ERR(0, 1005, __pyx_L3_error)
10568  }
10569  CYTHON_FALLTHROUGH;
10570  case 5:
10571  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementNodes)) != 0)) kw_args--;
10572  else {
10573  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_opt", 1, 15, 15, 5); __PYX_ERR(0, 1005, __pyx_L3_error)
10574  }
10575  CYTHON_FALLTHROUGH;
10576  case 6:
10577  if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarElements)) != 0)) kw_args--;
10578  else {
10579  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_opt", 1, 15, 15, 6); __PYX_ERR(0, 1005, __pyx_L3_error)
10580  }
10581  CYTHON_FALLTHROUGH;
10582  case 7:
10583  if (likely((values[7] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarElementNeighbors)) != 0)) kw_args--;
10584  else {
10585  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_opt", 1, 15, 15, 7); __PYX_ERR(0, 1005, __pyx_L3_error)
10586  }
10587  CYTHON_FALLTHROUGH;
10588  case 8:
10589  if (likely((values[8] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nElements_node)) != 0)) kw_args--;
10590  else {
10591  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_opt", 1, 15, 15, 8); __PYX_ERR(0, 1005, __pyx_L3_error)
10592  }
10593  CYTHON_FALLTHROUGH;
10594  case 9:
10595  if (likely((values[9] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_internalNodes)) != 0)) kw_args--;
10596  else {
10597  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_opt", 1, 15, 15, 9); __PYX_ERR(0, 1005, __pyx_L3_error)
10598  }
10599  CYTHON_FALLTHROUGH;
10600  case 10:
10601  if (likely((values[10] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_fluxElementBoundaries)) != 0)) kw_args--;
10602  else {
10603  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_opt", 1, 15, 15, 10); __PYX_ERR(0, 1005, __pyx_L3_error)
10604  }
10605  CYTHON_FALLTHROUGH;
10606  case 11:
10607  if (likely((values[11] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_fluxBoundaryNodes)) != 0)) kw_args--;
10608  else {
10609  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_opt", 1, 15, 15, 11); __PYX_ERR(0, 1005, __pyx_L3_error)
10610  }
10611  CYTHON_FALLTHROUGH;
10612  case 12:
10613  if (likely((values[12] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_w)) != 0)) kw_args--;
10614  else {
10615  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_opt", 1, 15, 15, 12); __PYX_ERR(0, 1005, __pyx_L3_error)
10616  }
10617  CYTHON_FALLTHROUGH;
10618  case 13:
10619  if (likely((values[13] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_n)) != 0)) kw_args--;
10620  else {
10621  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_opt", 1, 15, 15, 13); __PYX_ERR(0, 1005, __pyx_L3_error)
10622  }
10623  CYTHON_FALLTHROUGH;
10624  case 14:
10625  if (likely((values[14] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarFactor)) != 0)) kw_args--;
10626  else {
10627  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_opt", 1, 15, 15, 14); __PYX_ERR(0, 1005, __pyx_L3_error)
10628  }
10629  }
10630  if (unlikely(kw_args > 0)) {
10631  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "calculateConservationJacobianPWL_opt") < 0)) __PYX_ERR(0, 1005, __pyx_L3_error)
10632  }
10633  } else if (PyTuple_GET_SIZE(__pyx_args) != 15) {
10634  goto __pyx_L5_argtuple_error;
10635  } else {
10636  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
10637  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
10638  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
10639  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
10640  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
10641  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
10642  values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
10643  values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
10644  values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
10645  values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
10646  values[10] = PyTuple_GET_ITEM(__pyx_args, 10);
10647  values[11] = PyTuple_GET_ITEM(__pyx_args, 11);
10648  values[12] = PyTuple_GET_ITEM(__pyx_args, 12);
10649  values[13] = PyTuple_GET_ITEM(__pyx_args, 13);
10650  values[14] = PyTuple_GET_ITEM(__pyx_args, 14);
10651  }
10652  __pyx_v_nNodes_owned = __Pyx_PyInt_As_int(values[0]); if (unlikely((__pyx_v_nNodes_owned == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 1005, __pyx_L3_error)
10653  __pyx_v_interiorElementBoundaries = ((PyArrayObject *)values[1]);
10654  __pyx_v_exteriorElementBoundaries = ((PyArrayObject *)values[2]);
10655  __pyx_v_elementBoundaryElements = ((PyArrayObject *)values[3]);
10656  __pyx_v_elementBoundaryLocalElementBoundaries = ((PyArrayObject *)values[4]);
10657  __pyx_v_elementNodes = ((PyArrayObject *)values[5]);
10658  __pyx_v_nodeStarElements = ((PyArrayObject *)values[6]);
10659  __pyx_v_nodeStarElementNeighbors = ((PyArrayObject *)values[7]);
10660  __pyx_v_nElements_node = ((PyArrayObject *)values[8]);
10661  __pyx_v_internalNodes = ((PyArrayObject *)values[9]);
10662  __pyx_v_fluxElementBoundaries = ((PyArrayObject *)values[10]);
10663  __pyx_v_fluxBoundaryNodes = ((PyArrayObject *)values[11]);
10664  __pyx_v_w = ((PyArrayObject *)values[12]);
10665  __pyx_v_n = ((PyArrayObject *)values[13]);
10666  __pyx_v_nodeStarFactor = ((struct __pyx_obj_15cpostprocessing_NodeStarFactor *)values[14]);
10667  }
10668  goto __pyx_L4_argument_unpacking_done;
10669  __pyx_L5_argtuple_error:;
10670  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_opt", 1, 15, 15, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 1005, __pyx_L3_error)
10671  __pyx_L3_error:;
10672  __Pyx_AddTraceback("cpostprocessing.calculateConservationJacobianPWL_opt", __pyx_clineno, __pyx_lineno, __pyx_filename);
10673  __Pyx_RefNannyFinishContext();
10674  return NULL;
10675  __pyx_L4_argument_unpacking_done:;
10676  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_interiorElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "interiorElementBoundaries", 0))) __PYX_ERR(0, 1006, __pyx_L1_error)
10677  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_exteriorElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "exteriorElementBoundaries", 0))) __PYX_ERR(0, 1007, __pyx_L1_error)
10678  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryElements), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryElements", 0))) __PYX_ERR(0, 1008, __pyx_L1_error)
10679  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryLocalElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryLocalElementBoundaries", 0))) __PYX_ERR(0, 1009, __pyx_L1_error)
10680  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementNodes), __pyx_ptype_5numpy_ndarray, 1, "elementNodes", 0))) __PYX_ERR(0, 1010, __pyx_L1_error)
10681  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarElements), __pyx_ptype_5numpy_ndarray, 1, "nodeStarElements", 0))) __PYX_ERR(0, 1011, __pyx_L1_error)
10682  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarElementNeighbors), __pyx_ptype_5numpy_ndarray, 1, "nodeStarElementNeighbors", 0))) __PYX_ERR(0, 1012, __pyx_L1_error)
10683  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nElements_node), __pyx_ptype_5numpy_ndarray, 1, "nElements_node", 0))) __PYX_ERR(0, 1013, __pyx_L1_error)
10684  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_internalNodes), __pyx_ptype_5numpy_ndarray, 1, "internalNodes", 0))) __PYX_ERR(0, 1014, __pyx_L1_error)
10685  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_fluxElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "fluxElementBoundaries", 0))) __PYX_ERR(0, 1015, __pyx_L1_error)
10686  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_fluxBoundaryNodes), __pyx_ptype_5numpy_ndarray, 1, "fluxBoundaryNodes", 0))) __PYX_ERR(0, 1016, __pyx_L1_error)
10687  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_w), __pyx_ptype_5numpy_ndarray, 1, "w", 0))) __PYX_ERR(0, 1017, __pyx_L1_error)
10688  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_n), __pyx_ptype_5numpy_ndarray, 1, "n", 0))) __PYX_ERR(0, 1018, __pyx_L1_error)
10689  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarFactor), __pyx_ptype_15cpostprocessing_NodeStarFactor, 1, "nodeStarFactor", 0))) __PYX_ERR(0, 1019, __pyx_L1_error)
10690  __pyx_r = __pyx_pf_15cpostprocessing_80calculateConservationJacobianPWL_opt(__pyx_self, __pyx_v_nNodes_owned, __pyx_v_interiorElementBoundaries, __pyx_v_exteriorElementBoundaries, __pyx_v_elementBoundaryElements, __pyx_v_elementBoundaryLocalElementBoundaries, __pyx_v_elementNodes, __pyx_v_nodeStarElements, __pyx_v_nodeStarElementNeighbors, __pyx_v_nElements_node, __pyx_v_internalNodes, __pyx_v_fluxElementBoundaries, __pyx_v_fluxBoundaryNodes, __pyx_v_w, __pyx_v_n, __pyx_v_nodeStarFactor);
10691 
10692  /* function exit code */
10693  goto __pyx_L0;
10694  __pyx_L1_error:;
10695  __pyx_r = NULL;
10696  __pyx_L0:;
10697  __Pyx_RefNannyFinishContext();
10698  return __pyx_r;
10699 }
10700 
10701 static PyObject *__pyx_pf_15cpostprocessing_80calculateConservationJacobianPWL_opt(CYTHON_UNUSED PyObject *__pyx_self, int __pyx_v_nNodes_owned, PyArrayObject *__pyx_v_interiorElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries, PyArrayObject *__pyx_v_elementNodes, PyArrayObject *__pyx_v_nodeStarElements, PyArrayObject *__pyx_v_nodeStarElementNeighbors, PyArrayObject *__pyx_v_nElements_node, PyArrayObject *__pyx_v_internalNodes, PyArrayObject *__pyx_v_fluxElementBoundaries, PyArrayObject *__pyx_v_fluxBoundaryNodes, PyArrayObject *__pyx_v_w, PyArrayObject *__pyx_v_n, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor) {
10702  PyObject *__pyx_r = NULL;
10703  __Pyx_RefNannyDeclarations
10704  __Pyx_RefNannySetupContext("calculateConservationJacobianPWL_opt", 0);
10705 
10706  /* "cpostprocessing.pyx":1020
10707  * np.ndarray n,
10708  * NodeStarFactor nodeStarFactor):
10709  * pp.calculateConservationJacobianPWL_opt(nNodes_owned, # <<<<<<<<<<<<<<
10710  * nElements_node.shape[0],
10711  * internalNodes.shape[0],
10712  */
10713  calculateConservationJacobianPWL_opt(__pyx_v_nNodes_owned, (__pyx_v_nElements_node->dimensions[0]), (__pyx_v_internalNodes->dimensions[0]), (__pyx_v_w->dimensions[0]), (__pyx_v_interiorElementBoundaries->dimensions[0]), (__pyx_v_exteriorElementBoundaries->dimensions[0]), (__pyx_v_w->dimensions[1]), (__pyx_v_w->dimensions[2]), (__pyx_v_w->dimensions[3]), (__pyx_v_n->dimensions[2]), ((int *)__pyx_v_interiorElementBoundaries->data), ((int *)__pyx_v_exteriorElementBoundaries->data), ((int *)__pyx_v_elementBoundaryElements->data), ((int *)__pyx_v_elementBoundaryLocalElementBoundaries->data), ((int *)__pyx_v_elementNodes->data), ((int *)__pyx_v_nodeStarElements->data), ((int *)__pyx_v_nodeStarElementNeighbors->data), ((int *)__pyx_v_nElements_node->data), ((int *)__pyx_v_internalNodes->data), ((int *)__pyx_v_fluxElementBoundaries->data), ((int *)__pyx_v_fluxBoundaryNodes->data), ((double *)__pyx_v_w->data), ((double *)__pyx_v_n->data), (&__pyx_v_nodeStarFactor->nsf));
10714 
10715  /* "cpostprocessing.pyx":1005
10716  * <double*>(vConservative.data))
10717  *
10718  * def calculateConservationJacobianPWL_opt(int nNodes_owned, # <<<<<<<<<<<<<<
10719  * np.ndarray interiorElementBoundaries,
10720  * np.ndarray exteriorElementBoundaries,
10721  */
10722 
10723  /* function exit code */
10724  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
10725  __Pyx_XGIVEREF(__pyx_r);
10726  __Pyx_RefNannyFinishContext();
10727  return __pyx_r;
10728 }
10729 
10730 /* "cpostprocessing.pyx":1045
10731  * &nodeStarFactor.nsf)
10732  *
10733  * def calculateConservationFluxPWL_opt(int nNodes_owned, # <<<<<<<<<<<<<<
10734  * np.ndarray nElements_node,
10735  * np.ndarray internalNodes,
10736  */
10737 
10738 /* Python wrapper */
10739 static PyObject *__pyx_pw_15cpostprocessing_83calculateConservationFluxPWL_opt(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
10740 static PyMethodDef __pyx_mdef_15cpostprocessing_83calculateConservationFluxPWL_opt = {"calculateConservationFluxPWL_opt", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_83calculateConservationFluxPWL_opt, METH_VARARGS|METH_KEYWORDS, 0};
10741 static PyObject *__pyx_pw_15cpostprocessing_83calculateConservationFluxPWL_opt(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
10742  int __pyx_v_nNodes_owned;
10743  PyArrayObject *__pyx_v_nElements_node = 0;
10744  PyArrayObject *__pyx_v_internalNodes = 0;
10745  PyArrayObject *__pyx_v_fluxBoundaryNodes = 0;
10746  struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor = 0;
10747  int __pyx_lineno = 0;
10748  const char *__pyx_filename = NULL;
10749  int __pyx_clineno = 0;
10750  PyObject *__pyx_r = 0;
10751  __Pyx_RefNannyDeclarations
10752  __Pyx_RefNannySetupContext("calculateConservationFluxPWL_opt (wrapper)", 0);
10753  {
10754  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_nNodes_owned,&__pyx_n_s_nElements_node,&__pyx_n_s_internalNodes,&__pyx_n_s_fluxBoundaryNodes,&__pyx_n_s_nodeStarFactor,0};
10755  PyObject* values[5] = {0,0,0,0,0};
10756  if (unlikely(__pyx_kwds)) {
10757  Py_ssize_t kw_args;
10758  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
10759  switch (pos_args) {
10760  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
10761  CYTHON_FALLTHROUGH;
10762  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
10763  CYTHON_FALLTHROUGH;
10764  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
10765  CYTHON_FALLTHROUGH;
10766  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
10767  CYTHON_FALLTHROUGH;
10768  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
10769  CYTHON_FALLTHROUGH;
10770  case 0: break;
10771  default: goto __pyx_L5_argtuple_error;
10772  }
10773  kw_args = PyDict_Size(__pyx_kwds);
10774  switch (pos_args) {
10775  case 0:
10776  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nNodes_owned)) != 0)) kw_args--;
10777  else goto __pyx_L5_argtuple_error;
10778  CYTHON_FALLTHROUGH;
10779  case 1:
10780  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nElements_node)) != 0)) kw_args--;
10781  else {
10782  __Pyx_RaiseArgtupleInvalid("calculateConservationFluxPWL_opt", 1, 5, 5, 1); __PYX_ERR(0, 1045, __pyx_L3_error)
10783  }
10784  CYTHON_FALLTHROUGH;
10785  case 2:
10786  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_internalNodes)) != 0)) kw_args--;
10787  else {
10788  __Pyx_RaiseArgtupleInvalid("calculateConservationFluxPWL_opt", 1, 5, 5, 2); __PYX_ERR(0, 1045, __pyx_L3_error)
10789  }
10790  CYTHON_FALLTHROUGH;
10791  case 3:
10792  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_fluxBoundaryNodes)) != 0)) kw_args--;
10793  else {
10794  __Pyx_RaiseArgtupleInvalid("calculateConservationFluxPWL_opt", 1, 5, 5, 3); __PYX_ERR(0, 1045, __pyx_L3_error)
10795  }
10796  CYTHON_FALLTHROUGH;
10797  case 4:
10798  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarFactor)) != 0)) kw_args--;
10799  else {
10800  __Pyx_RaiseArgtupleInvalid("calculateConservationFluxPWL_opt", 1, 5, 5, 4); __PYX_ERR(0, 1045, __pyx_L3_error)
10801  }
10802  }
10803  if (unlikely(kw_args > 0)) {
10804  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "calculateConservationFluxPWL_opt") < 0)) __PYX_ERR(0, 1045, __pyx_L3_error)
10805  }
10806  } else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
10807  goto __pyx_L5_argtuple_error;
10808  } else {
10809  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
10810  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
10811  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
10812  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
10813  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
10814  }
10815  __pyx_v_nNodes_owned = __Pyx_PyInt_As_int(values[0]); if (unlikely((__pyx_v_nNodes_owned == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 1045, __pyx_L3_error)
10816  __pyx_v_nElements_node = ((PyArrayObject *)values[1]);
10817  __pyx_v_internalNodes = ((PyArrayObject *)values[2]);
10818  __pyx_v_fluxBoundaryNodes = ((PyArrayObject *)values[3]);
10819  __pyx_v_nodeStarFactor = ((struct __pyx_obj_15cpostprocessing_NodeStarFactor *)values[4]);
10820  }
10821  goto __pyx_L4_argument_unpacking_done;
10822  __pyx_L5_argtuple_error:;
10823  __Pyx_RaiseArgtupleInvalid("calculateConservationFluxPWL_opt", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 1045, __pyx_L3_error)
10824  __pyx_L3_error:;
10825  __Pyx_AddTraceback("cpostprocessing.calculateConservationFluxPWL_opt", __pyx_clineno, __pyx_lineno, __pyx_filename);
10826  __Pyx_RefNannyFinishContext();
10827  return NULL;
10828  __pyx_L4_argument_unpacking_done:;
10829  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nElements_node), __pyx_ptype_5numpy_ndarray, 1, "nElements_node", 0))) __PYX_ERR(0, 1046, __pyx_L1_error)
10830  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_internalNodes), __pyx_ptype_5numpy_ndarray, 1, "internalNodes", 0))) __PYX_ERR(0, 1047, __pyx_L1_error)
10831  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_fluxBoundaryNodes), __pyx_ptype_5numpy_ndarray, 1, "fluxBoundaryNodes", 0))) __PYX_ERR(0, 1048, __pyx_L1_error)
10832  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarFactor), __pyx_ptype_15cpostprocessing_NodeStarFactor, 1, "nodeStarFactor", 0))) __PYX_ERR(0, 1049, __pyx_L1_error)
10833  __pyx_r = __pyx_pf_15cpostprocessing_82calculateConservationFluxPWL_opt(__pyx_self, __pyx_v_nNodes_owned, __pyx_v_nElements_node, __pyx_v_internalNodes, __pyx_v_fluxBoundaryNodes, __pyx_v_nodeStarFactor);
10834 
10835  /* function exit code */
10836  goto __pyx_L0;
10837  __pyx_L1_error:;
10838  __pyx_r = NULL;
10839  __pyx_L0:;
10840  __Pyx_RefNannyFinishContext();
10841  return __pyx_r;
10842 }
10843 
10844 static PyObject *__pyx_pf_15cpostprocessing_82calculateConservationFluxPWL_opt(CYTHON_UNUSED PyObject *__pyx_self, int __pyx_v_nNodes_owned, PyArrayObject *__pyx_v_nElements_node, PyArrayObject *__pyx_v_internalNodes, PyArrayObject *__pyx_v_fluxBoundaryNodes, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor) {
10845  PyObject *__pyx_r = NULL;
10846  __Pyx_RefNannyDeclarations
10847  __Pyx_RefNannySetupContext("calculateConservationFluxPWL_opt", 0);
10848 
10849  /* "cpostprocessing.pyx":1050
10850  * np.ndarray fluxBoundaryNodes,
10851  * NodeStarFactor nodeStarFactor):
10852  * pp.calculateConservationFluxPWL_opt(nNodes_owned, # <<<<<<<<<<<<<<
10853  * nElements_node.shape[0],
10854  * internalNodes.shape[0],
10855  */
10856  calculateConservationFluxPWL_opt(__pyx_v_nNodes_owned, (__pyx_v_nElements_node->dimensions[0]), (__pyx_v_internalNodes->dimensions[0]), ((int *)__pyx_v_nElements_node->data), ((int *)__pyx_v_internalNodes->data), ((int *)__pyx_v_fluxBoundaryNodes->data), (&__pyx_v_nodeStarFactor->nsf));
10857 
10858  /* "cpostprocessing.pyx":1045
10859  * &nodeStarFactor.nsf)
10860  *
10861  * def calculateConservationFluxPWL_opt(int nNodes_owned, # <<<<<<<<<<<<<<
10862  * np.ndarray nElements_node,
10863  * np.ndarray internalNodes,
10864  */
10865 
10866  /* function exit code */
10867  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
10868  __Pyx_XGIVEREF(__pyx_r);
10869  __Pyx_RefNannyFinishContext();
10870  return __pyx_r;
10871 }
10872 
10873 /* "cpostprocessing.pyx":1058
10874  * &nodeStarFactor.nsf)
10875  *
10876  * def calculateConservationResidualPWL_interiorBoundaries(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
10877  * np.ndarray exteriorElementBoundaries,
10878  * np.ndarray elementBoundaryElements,
10879  */
10880 
10881 /* Python wrapper */
10882 static PyObject *__pyx_pw_15cpostprocessing_85calculateConservationResidualPWL_interiorBoundaries(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
10883 static PyMethodDef __pyx_mdef_15cpostprocessing_85calculateConservationResidualPWL_interiorBoundaries = {"calculateConservationResidualPWL_interiorBoundaries", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_85calculateConservationResidualPWL_interiorBoundaries, METH_VARARGS|METH_KEYWORDS, 0};
10884 static PyObject *__pyx_pw_15cpostprocessing_85calculateConservationResidualPWL_interiorBoundaries(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
10885  PyArrayObject *__pyx_v_interiorElementBoundaries = 0;
10886  PyArrayObject *__pyx_v_exteriorElementBoundaries = 0;
10887  PyArrayObject *__pyx_v_elementBoundaryElements = 0;
10888  PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries = 0;
10889  PyArrayObject *__pyx_v_elementNodes = 0;
10890  PyArrayObject *__pyx_v_nodeStarElements = 0;
10891  PyArrayObject *__pyx_v_nodeStarElementNeighbors = 0;
10892  PyArrayObject *__pyx_v_nElements_node = 0;
10893  PyArrayObject *__pyx_v_fluxElementBoundaries = 0;
10894  PyArrayObject *__pyx_v_elementResidual = 0;
10895  PyArrayObject *__pyx_v_vAverage = 0;
10896  PyArrayObject *__pyx_v_dx = 0;
10897  PyArrayObject *__pyx_v_w = 0;
10898  PyArrayObject *__pyx_v_n = 0;
10899  struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor = 0;
10900  PyArrayObject *__pyx_v_conservationResidual = 0;
10901  PyArrayObject *__pyx_v_vConservative = 0;
10902  PyArrayObject *__pyx_v_vConservative_element = 0;
10903  int __pyx_lineno = 0;
10904  const char *__pyx_filename = NULL;
10905  int __pyx_clineno = 0;
10906  PyObject *__pyx_r = 0;
10907  __Pyx_RefNannyDeclarations
10908  __Pyx_RefNannySetupContext("calculateConservationResidualPWL_interiorBoundaries (wrapper)", 0);
10909  {
10910  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_interiorElementBoundaries,&__pyx_n_s_exteriorElementBoundaries,&__pyx_n_s_elementBoundaryElements,&__pyx_n_s_elementBoundaryLocalElementBound,&__pyx_n_s_elementNodes,&__pyx_n_s_nodeStarElements,&__pyx_n_s_nodeStarElementNeighbors,&__pyx_n_s_nElements_node,&__pyx_n_s_fluxElementBoundaries,&__pyx_n_s_elementResidual,&__pyx_n_s_vAverage,&__pyx_n_s_dx,&__pyx_n_s_w,&__pyx_n_s_n,&__pyx_n_s_nodeStarFactor,&__pyx_n_s_conservationResidual,&__pyx_n_s_vConservative,&__pyx_n_s_vConservative_element,0};
10911  PyObject* values[18] = {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0};
10912  if (unlikely(__pyx_kwds)) {
10913  Py_ssize_t kw_args;
10914  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
10915  switch (pos_args) {
10916  case 18: values[17] = PyTuple_GET_ITEM(__pyx_args, 17);
10917  CYTHON_FALLTHROUGH;
10918  case 17: values[16] = PyTuple_GET_ITEM(__pyx_args, 16);
10919  CYTHON_FALLTHROUGH;
10920  case 16: values[15] = PyTuple_GET_ITEM(__pyx_args, 15);
10921  CYTHON_FALLTHROUGH;
10922  case 15: values[14] = PyTuple_GET_ITEM(__pyx_args, 14);
10923  CYTHON_FALLTHROUGH;
10924  case 14: values[13] = PyTuple_GET_ITEM(__pyx_args, 13);
10925  CYTHON_FALLTHROUGH;
10926  case 13: values[12] = PyTuple_GET_ITEM(__pyx_args, 12);
10927  CYTHON_FALLTHROUGH;
10928  case 12: values[11] = PyTuple_GET_ITEM(__pyx_args, 11);
10929  CYTHON_FALLTHROUGH;
10930  case 11: values[10] = PyTuple_GET_ITEM(__pyx_args, 10);
10931  CYTHON_FALLTHROUGH;
10932  case 10: values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
10933  CYTHON_FALLTHROUGH;
10934  case 9: values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
10935  CYTHON_FALLTHROUGH;
10936  case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
10937  CYTHON_FALLTHROUGH;
10938  case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
10939  CYTHON_FALLTHROUGH;
10940  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
10941  CYTHON_FALLTHROUGH;
10942  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
10943  CYTHON_FALLTHROUGH;
10944  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
10945  CYTHON_FALLTHROUGH;
10946  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
10947  CYTHON_FALLTHROUGH;
10948  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
10949  CYTHON_FALLTHROUGH;
10950  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
10951  CYTHON_FALLTHROUGH;
10952  case 0: break;
10953  default: goto __pyx_L5_argtuple_error;
10954  }
10955  kw_args = PyDict_Size(__pyx_kwds);
10956  switch (pos_args) {
10957  case 0:
10958  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_interiorElementBoundaries)) != 0)) kw_args--;
10959  else goto __pyx_L5_argtuple_error;
10960  CYTHON_FALLTHROUGH;
10961  case 1:
10962  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_exteriorElementBoundaries)) != 0)) kw_args--;
10963  else {
10964  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_interiorBoundaries", 1, 18, 18, 1); __PYX_ERR(0, 1058, __pyx_L3_error)
10965  }
10966  CYTHON_FALLTHROUGH;
10967  case 2:
10968  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryElements)) != 0)) kw_args--;
10969  else {
10970  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_interiorBoundaries", 1, 18, 18, 2); __PYX_ERR(0, 1058, __pyx_L3_error)
10971  }
10972  CYTHON_FALLTHROUGH;
10973  case 3:
10974  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryLocalElementBound)) != 0)) kw_args--;
10975  else {
10976  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_interiorBoundaries", 1, 18, 18, 3); __PYX_ERR(0, 1058, __pyx_L3_error)
10977  }
10978  CYTHON_FALLTHROUGH;
10979  case 4:
10980  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementNodes)) != 0)) kw_args--;
10981  else {
10982  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_interiorBoundaries", 1, 18, 18, 4); __PYX_ERR(0, 1058, __pyx_L3_error)
10983  }
10984  CYTHON_FALLTHROUGH;
10985  case 5:
10986  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarElements)) != 0)) kw_args--;
10987  else {
10988  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_interiorBoundaries", 1, 18, 18, 5); __PYX_ERR(0, 1058, __pyx_L3_error)
10989  }
10990  CYTHON_FALLTHROUGH;
10991  case 6:
10992  if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarElementNeighbors)) != 0)) kw_args--;
10993  else {
10994  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_interiorBoundaries", 1, 18, 18, 6); __PYX_ERR(0, 1058, __pyx_L3_error)
10995  }
10996  CYTHON_FALLTHROUGH;
10997  case 7:
10998  if (likely((values[7] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nElements_node)) != 0)) kw_args--;
10999  else {
11000  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_interiorBoundaries", 1, 18, 18, 7); __PYX_ERR(0, 1058, __pyx_L3_error)
11001  }
11002  CYTHON_FALLTHROUGH;
11003  case 8:
11004  if (likely((values[8] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_fluxElementBoundaries)) != 0)) kw_args--;
11005  else {
11006  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_interiorBoundaries", 1, 18, 18, 8); __PYX_ERR(0, 1058, __pyx_L3_error)
11007  }
11008  CYTHON_FALLTHROUGH;
11009  case 9:
11010  if (likely((values[9] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementResidual)) != 0)) kw_args--;
11011  else {
11012  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_interiorBoundaries", 1, 18, 18, 9); __PYX_ERR(0, 1058, __pyx_L3_error)
11013  }
11014  CYTHON_FALLTHROUGH;
11015  case 10:
11016  if (likely((values[10] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_vAverage)) != 0)) kw_args--;
11017  else {
11018  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_interiorBoundaries", 1, 18, 18, 10); __PYX_ERR(0, 1058, __pyx_L3_error)
11019  }
11020  CYTHON_FALLTHROUGH;
11021  case 11:
11022  if (likely((values[11] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_dx)) != 0)) kw_args--;
11023  else {
11024  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_interiorBoundaries", 1, 18, 18, 11); __PYX_ERR(0, 1058, __pyx_L3_error)
11025  }
11026  CYTHON_FALLTHROUGH;
11027  case 12:
11028  if (likely((values[12] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_w)) != 0)) kw_args--;
11029  else {
11030  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_interiorBoundaries", 1, 18, 18, 12); __PYX_ERR(0, 1058, __pyx_L3_error)
11031  }
11032  CYTHON_FALLTHROUGH;
11033  case 13:
11034  if (likely((values[13] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_n)) != 0)) kw_args--;
11035  else {
11036  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_interiorBoundaries", 1, 18, 18, 13); __PYX_ERR(0, 1058, __pyx_L3_error)
11037  }
11038  CYTHON_FALLTHROUGH;
11039  case 14:
11040  if (likely((values[14] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarFactor)) != 0)) kw_args--;
11041  else {
11042  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_interiorBoundaries", 1, 18, 18, 14); __PYX_ERR(0, 1058, __pyx_L3_error)
11043  }
11044  CYTHON_FALLTHROUGH;
11045  case 15:
11046  if (likely((values[15] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_conservationResidual)) != 0)) kw_args--;
11047  else {
11048  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_interiorBoundaries", 1, 18, 18, 15); __PYX_ERR(0, 1058, __pyx_L3_error)
11049  }
11050  CYTHON_FALLTHROUGH;
11051  case 16:
11052  if (likely((values[16] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_vConservative)) != 0)) kw_args--;
11053  else {
11054  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_interiorBoundaries", 1, 18, 18, 16); __PYX_ERR(0, 1058, __pyx_L3_error)
11055  }
11056  CYTHON_FALLTHROUGH;
11057  case 17:
11058  if (likely((values[17] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_vConservative_element)) != 0)) kw_args--;
11059  else {
11060  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_interiorBoundaries", 1, 18, 18, 17); __PYX_ERR(0, 1058, __pyx_L3_error)
11061  }
11062  }
11063  if (unlikely(kw_args > 0)) {
11064  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "calculateConservationResidualPWL_interiorBoundaries") < 0)) __PYX_ERR(0, 1058, __pyx_L3_error)
11065  }
11066  } else if (PyTuple_GET_SIZE(__pyx_args) != 18) {
11067  goto __pyx_L5_argtuple_error;
11068  } else {
11069  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
11070  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
11071  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
11072  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
11073  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
11074  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
11075  values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
11076  values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
11077  values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
11078  values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
11079  values[10] = PyTuple_GET_ITEM(__pyx_args, 10);
11080  values[11] = PyTuple_GET_ITEM(__pyx_args, 11);
11081  values[12] = PyTuple_GET_ITEM(__pyx_args, 12);
11082  values[13] = PyTuple_GET_ITEM(__pyx_args, 13);
11083  values[14] = PyTuple_GET_ITEM(__pyx_args, 14);
11084  values[15] = PyTuple_GET_ITEM(__pyx_args, 15);
11085  values[16] = PyTuple_GET_ITEM(__pyx_args, 16);
11086  values[17] = PyTuple_GET_ITEM(__pyx_args, 17);
11087  }
11088  __pyx_v_interiorElementBoundaries = ((PyArrayObject *)values[0]);
11089  __pyx_v_exteriorElementBoundaries = ((PyArrayObject *)values[1]);
11090  __pyx_v_elementBoundaryElements = ((PyArrayObject *)values[2]);
11091  __pyx_v_elementBoundaryLocalElementBoundaries = ((PyArrayObject *)values[3]);
11092  __pyx_v_elementNodes = ((PyArrayObject *)values[4]);
11093  __pyx_v_nodeStarElements = ((PyArrayObject *)values[5]);
11094  __pyx_v_nodeStarElementNeighbors = ((PyArrayObject *)values[6]);
11095  __pyx_v_nElements_node = ((PyArrayObject *)values[7]);
11096  __pyx_v_fluxElementBoundaries = ((PyArrayObject *)values[8]);
11097  __pyx_v_elementResidual = ((PyArrayObject *)values[9]);
11098  __pyx_v_vAverage = ((PyArrayObject *)values[10]);
11099  __pyx_v_dx = ((PyArrayObject *)values[11]);
11100  __pyx_v_w = ((PyArrayObject *)values[12]);
11101  __pyx_v_n = ((PyArrayObject *)values[13]);
11102  __pyx_v_nodeStarFactor = ((struct __pyx_obj_15cpostprocessing_NodeStarFactor *)values[14]);
11103  __pyx_v_conservationResidual = ((PyArrayObject *)values[15]);
11104  __pyx_v_vConservative = ((PyArrayObject *)values[16]);
11105  __pyx_v_vConservative_element = ((PyArrayObject *)values[17]);
11106  }
11107  goto __pyx_L4_argument_unpacking_done;
11108  __pyx_L5_argtuple_error:;
11109  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualPWL_interiorBoundaries", 1, 18, 18, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 1058, __pyx_L3_error)
11110  __pyx_L3_error:;
11111  __Pyx_AddTraceback("cpostprocessing.calculateConservationResidualPWL_interiorBoundaries", __pyx_clineno, __pyx_lineno, __pyx_filename);
11112  __Pyx_RefNannyFinishContext();
11113  return NULL;
11114  __pyx_L4_argument_unpacking_done:;
11115  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_interiorElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "interiorElementBoundaries", 0))) __PYX_ERR(0, 1058, __pyx_L1_error)
11116  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_exteriorElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "exteriorElementBoundaries", 0))) __PYX_ERR(0, 1059, __pyx_L1_error)
11117  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryElements), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryElements", 0))) __PYX_ERR(0, 1060, __pyx_L1_error)
11118  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryLocalElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryLocalElementBoundaries", 0))) __PYX_ERR(0, 1061, __pyx_L1_error)
11119  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementNodes), __pyx_ptype_5numpy_ndarray, 1, "elementNodes", 0))) __PYX_ERR(0, 1062, __pyx_L1_error)
11120  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarElements), __pyx_ptype_5numpy_ndarray, 1, "nodeStarElements", 0))) __PYX_ERR(0, 1063, __pyx_L1_error)
11121  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarElementNeighbors), __pyx_ptype_5numpy_ndarray, 1, "nodeStarElementNeighbors", 0))) __PYX_ERR(0, 1064, __pyx_L1_error)
11122  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nElements_node), __pyx_ptype_5numpy_ndarray, 1, "nElements_node", 0))) __PYX_ERR(0, 1065, __pyx_L1_error)
11123  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_fluxElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "fluxElementBoundaries", 0))) __PYX_ERR(0, 1066, __pyx_L1_error)
11124  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementResidual), __pyx_ptype_5numpy_ndarray, 1, "elementResidual", 0))) __PYX_ERR(0, 1067, __pyx_L1_error)
11125  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_vAverage), __pyx_ptype_5numpy_ndarray, 1, "vAverage", 0))) __PYX_ERR(0, 1068, __pyx_L1_error)
11126  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dx), __pyx_ptype_5numpy_ndarray, 1, "dx", 0))) __PYX_ERR(0, 1069, __pyx_L1_error)
11127  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_w), __pyx_ptype_5numpy_ndarray, 1, "w", 0))) __PYX_ERR(0, 1070, __pyx_L1_error)
11128  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_n), __pyx_ptype_5numpy_ndarray, 1, "n", 0))) __PYX_ERR(0, 1071, __pyx_L1_error)
11129  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarFactor), __pyx_ptype_15cpostprocessing_NodeStarFactor, 1, "nodeStarFactor", 0))) __PYX_ERR(0, 1072, __pyx_L1_error)
11130  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_conservationResidual), __pyx_ptype_5numpy_ndarray, 1, "conservationResidual", 0))) __PYX_ERR(0, 1073, __pyx_L1_error)
11131  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_vConservative), __pyx_ptype_5numpy_ndarray, 1, "vConservative", 0))) __PYX_ERR(0, 1074, __pyx_L1_error)
11132  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_vConservative_element), __pyx_ptype_5numpy_ndarray, 1, "vConservative_element", 0))) __PYX_ERR(0, 1075, __pyx_L1_error)
11133  __pyx_r = __pyx_pf_15cpostprocessing_84calculateConservationResidualPWL_interiorBoundaries(__pyx_self, __pyx_v_interiorElementBoundaries, __pyx_v_exteriorElementBoundaries, __pyx_v_elementBoundaryElements, __pyx_v_elementBoundaryLocalElementBoundaries, __pyx_v_elementNodes, __pyx_v_nodeStarElements, __pyx_v_nodeStarElementNeighbors, __pyx_v_nElements_node, __pyx_v_fluxElementBoundaries, __pyx_v_elementResidual, __pyx_v_vAverage, __pyx_v_dx, __pyx_v_w, __pyx_v_n, __pyx_v_nodeStarFactor, __pyx_v_conservationResidual, __pyx_v_vConservative, __pyx_v_vConservative_element);
11134 
11135  /* function exit code */
11136  goto __pyx_L0;
11137  __pyx_L1_error:;
11138  __pyx_r = NULL;
11139  __pyx_L0:;
11140  __Pyx_RefNannyFinishContext();
11141  return __pyx_r;
11142 }
11143 
11144 static PyObject *__pyx_pf_15cpostprocessing_84calculateConservationResidualPWL_interiorBoundaries(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_interiorElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries, PyArrayObject *__pyx_v_elementNodes, PyArrayObject *__pyx_v_nodeStarElements, PyArrayObject *__pyx_v_nodeStarElementNeighbors, PyArrayObject *__pyx_v_nElements_node, PyArrayObject *__pyx_v_fluxElementBoundaries, PyArrayObject *__pyx_v_elementResidual, PyArrayObject *__pyx_v_vAverage, PyArrayObject *__pyx_v_dx, PyArrayObject *__pyx_v_w, PyArrayObject *__pyx_v_n, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor, PyArrayObject *__pyx_v_conservationResidual, PyArrayObject *__pyx_v_vConservative, PyArrayObject *__pyx_v_vConservative_element) {
11145  PyObject *__pyx_r = NULL;
11146  __Pyx_RefNannyDeclarations
11147  int __pyx_lineno = 0;
11148  const char *__pyx_filename = NULL;
11149  int __pyx_clineno = 0;
11150  __Pyx_RefNannySetupContext("calculateConservationResidualPWL_interiorBoundaries", 0);
11151 
11152  /* "cpostprocessing.pyx":1076
11153  * np.ndarray vConservative,
11154  * np.ndarray vConservative_element):
11155  * assert fluxElementBoundaries.shape[0] == elementBoundaryLocalElementBoundaries.shape[0] # <<<<<<<<<<<<<<
11156  * pp.calculateConservationResidualPWL_interiorBoundaries(w.shape[0],
11157  * interiorElementBoundaries.shape[0],
11158  */
11159  #ifndef CYTHON_WITHOUT_ASSERTIONS
11160  if (unlikely(!Py_OptimizeFlag)) {
11161  if (unlikely(!(((__pyx_v_fluxElementBoundaries->dimensions[0]) == (__pyx_v_elementBoundaryLocalElementBoundaries->dimensions[0])) != 0))) {
11162  PyErr_SetNone(PyExc_AssertionError);
11163  __PYX_ERR(0, 1076, __pyx_L1_error)
11164  }
11165  }
11166  #endif
11167 
11168  /* "cpostprocessing.pyx":1077
11169  * np.ndarray vConservative_element):
11170  * assert fluxElementBoundaries.shape[0] == elementBoundaryLocalElementBoundaries.shape[0]
11171  * pp.calculateConservationResidualPWL_interiorBoundaries(w.shape[0], # <<<<<<<<<<<<<<
11172  * interiorElementBoundaries.shape[0],
11173  * exteriorElementBoundaries.shape[0],
11174  */
11175  calculateConservationResidualPWL_interiorBoundaries((__pyx_v_w->dimensions[0]), (__pyx_v_interiorElementBoundaries->dimensions[0]), (__pyx_v_exteriorElementBoundaries->dimensions[0]), (__pyx_v_w->dimensions[1]), (__pyx_v_w->dimensions[2]), (__pyx_v_w->dimensions[3]), (__pyx_v_n->dimensions[2]), ((int *)__pyx_v_interiorElementBoundaries->data), ((int *)__pyx_v_exteriorElementBoundaries->data), ((int *)__pyx_v_elementBoundaryElements->data), ((int *)__pyx_v_elementBoundaryLocalElementBoundaries->data), ((int *)__pyx_v_elementNodes->data), ((int *)__pyx_v_nodeStarElements->data), ((int *)__pyx_v_nodeStarElementNeighbors->data), ((int *)__pyx_v_nElements_node->data), ((int *)__pyx_v_fluxElementBoundaries->data), ((double *)__pyx_v_elementResidual->data), ((double *)__pyx_v_vAverage->data), ((double *)__pyx_v_dx->data), ((double *)__pyx_v_w->data), ((double *)__pyx_v_n->data), (&__pyx_v_nodeStarFactor->nsf), ((double *)__pyx_v_conservationResidual->data), ((double *)__pyx_v_vConservative->data), ((double *)__pyx_v_vConservative_element->data));
11176 
11177  /* "cpostprocessing.pyx":1058
11178  * &nodeStarFactor.nsf)
11179  *
11180  * def calculateConservationResidualPWL_interiorBoundaries(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
11181  * np.ndarray exteriorElementBoundaries,
11182  * np.ndarray elementBoundaryElements,
11183  */
11184 
11185  /* function exit code */
11186  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
11187  goto __pyx_L0;
11188  __pyx_L1_error:;
11189  __Pyx_AddTraceback("cpostprocessing.calculateConservationResidualPWL_interiorBoundaries", __pyx_clineno, __pyx_lineno, __pyx_filename);
11190  __pyx_r = NULL;
11191  __pyx_L0:;
11192  __Pyx_XGIVEREF(__pyx_r);
11193  __Pyx_RefNannyFinishContext();
11194  return __pyx_r;
11195 }
11196 
11197 /* "cpostprocessing.pyx":1103
11198  * <double*>(vConservative_element.data))
11199  *
11200  * def calculateConservationJacobianPWL_interiorBoundaries(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
11201  * np.ndarray exteriorElementBoundaries,
11202  * np.ndarray elementBoundaryElements,
11203  */
11204 
11205 /* Python wrapper */
11206 static PyObject *__pyx_pw_15cpostprocessing_87calculateConservationJacobianPWL_interiorBoundaries(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
11207 static PyMethodDef __pyx_mdef_15cpostprocessing_87calculateConservationJacobianPWL_interiorBoundaries = {"calculateConservationJacobianPWL_interiorBoundaries", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_87calculateConservationJacobianPWL_interiorBoundaries, METH_VARARGS|METH_KEYWORDS, 0};
11208 static PyObject *__pyx_pw_15cpostprocessing_87calculateConservationJacobianPWL_interiorBoundaries(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
11209  PyArrayObject *__pyx_v_interiorElementBoundaries = 0;
11210  PyArrayObject *__pyx_v_exteriorElementBoundaries = 0;
11211  PyArrayObject *__pyx_v_elementBoundaryElements = 0;
11212  PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries = 0;
11213  PyArrayObject *__pyx_v_elementNodes = 0;
11214  PyArrayObject *__pyx_v_nodeStarElements = 0;
11215  PyArrayObject *__pyx_v_nodeStarElementNeighbors = 0;
11216  PyArrayObject *__pyx_v_nElements_node = 0;
11217  PyArrayObject *__pyx_v_fluxElementBoundaries = 0;
11218  PyArrayObject *__pyx_v_w = 0;
11219  PyArrayObject *__pyx_v_n = 0;
11220  struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor = 0;
11221  int __pyx_lineno = 0;
11222  const char *__pyx_filename = NULL;
11223  int __pyx_clineno = 0;
11224  PyObject *__pyx_r = 0;
11225  __Pyx_RefNannyDeclarations
11226  __Pyx_RefNannySetupContext("calculateConservationJacobianPWL_interiorBoundaries (wrapper)", 0);
11227  {
11228  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_interiorElementBoundaries,&__pyx_n_s_exteriorElementBoundaries,&__pyx_n_s_elementBoundaryElements,&__pyx_n_s_elementBoundaryLocalElementBound,&__pyx_n_s_elementNodes,&__pyx_n_s_nodeStarElements,&__pyx_n_s_nodeStarElementNeighbors,&__pyx_n_s_nElements_node,&__pyx_n_s_fluxElementBoundaries,&__pyx_n_s_w,&__pyx_n_s_n,&__pyx_n_s_nodeStarFactor,0};
11229  PyObject* values[12] = {0,0,0,0,0,0,0,0,0,0,0,0};
11230  if (unlikely(__pyx_kwds)) {
11231  Py_ssize_t kw_args;
11232  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
11233  switch (pos_args) {
11234  case 12: values[11] = PyTuple_GET_ITEM(__pyx_args, 11);
11235  CYTHON_FALLTHROUGH;
11236  case 11: values[10] = PyTuple_GET_ITEM(__pyx_args, 10);
11237  CYTHON_FALLTHROUGH;
11238  case 10: values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
11239  CYTHON_FALLTHROUGH;
11240  case 9: values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
11241  CYTHON_FALLTHROUGH;
11242  case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
11243  CYTHON_FALLTHROUGH;
11244  case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
11245  CYTHON_FALLTHROUGH;
11246  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
11247  CYTHON_FALLTHROUGH;
11248  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
11249  CYTHON_FALLTHROUGH;
11250  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
11251  CYTHON_FALLTHROUGH;
11252  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
11253  CYTHON_FALLTHROUGH;
11254  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
11255  CYTHON_FALLTHROUGH;
11256  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
11257  CYTHON_FALLTHROUGH;
11258  case 0: break;
11259  default: goto __pyx_L5_argtuple_error;
11260  }
11261  kw_args = PyDict_Size(__pyx_kwds);
11262  switch (pos_args) {
11263  case 0:
11264  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_interiorElementBoundaries)) != 0)) kw_args--;
11265  else goto __pyx_L5_argtuple_error;
11266  CYTHON_FALLTHROUGH;
11267  case 1:
11268  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_exteriorElementBoundaries)) != 0)) kw_args--;
11269  else {
11270  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_interiorBoundaries", 1, 12, 12, 1); __PYX_ERR(0, 1103, __pyx_L3_error)
11271  }
11272  CYTHON_FALLTHROUGH;
11273  case 2:
11274  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryElements)) != 0)) kw_args--;
11275  else {
11276  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_interiorBoundaries", 1, 12, 12, 2); __PYX_ERR(0, 1103, __pyx_L3_error)
11277  }
11278  CYTHON_FALLTHROUGH;
11279  case 3:
11280  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryLocalElementBound)) != 0)) kw_args--;
11281  else {
11282  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_interiorBoundaries", 1, 12, 12, 3); __PYX_ERR(0, 1103, __pyx_L3_error)
11283  }
11284  CYTHON_FALLTHROUGH;
11285  case 4:
11286  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementNodes)) != 0)) kw_args--;
11287  else {
11288  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_interiorBoundaries", 1, 12, 12, 4); __PYX_ERR(0, 1103, __pyx_L3_error)
11289  }
11290  CYTHON_FALLTHROUGH;
11291  case 5:
11292  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarElements)) != 0)) kw_args--;
11293  else {
11294  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_interiorBoundaries", 1, 12, 12, 5); __PYX_ERR(0, 1103, __pyx_L3_error)
11295  }
11296  CYTHON_FALLTHROUGH;
11297  case 6:
11298  if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarElementNeighbors)) != 0)) kw_args--;
11299  else {
11300  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_interiorBoundaries", 1, 12, 12, 6); __PYX_ERR(0, 1103, __pyx_L3_error)
11301  }
11302  CYTHON_FALLTHROUGH;
11303  case 7:
11304  if (likely((values[7] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nElements_node)) != 0)) kw_args--;
11305  else {
11306  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_interiorBoundaries", 1, 12, 12, 7); __PYX_ERR(0, 1103, __pyx_L3_error)
11307  }
11308  CYTHON_FALLTHROUGH;
11309  case 8:
11310  if (likely((values[8] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_fluxElementBoundaries)) != 0)) kw_args--;
11311  else {
11312  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_interiorBoundaries", 1, 12, 12, 8); __PYX_ERR(0, 1103, __pyx_L3_error)
11313  }
11314  CYTHON_FALLTHROUGH;
11315  case 9:
11316  if (likely((values[9] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_w)) != 0)) kw_args--;
11317  else {
11318  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_interiorBoundaries", 1, 12, 12, 9); __PYX_ERR(0, 1103, __pyx_L3_error)
11319  }
11320  CYTHON_FALLTHROUGH;
11321  case 10:
11322  if (likely((values[10] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_n)) != 0)) kw_args--;
11323  else {
11324  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_interiorBoundaries", 1, 12, 12, 10); __PYX_ERR(0, 1103, __pyx_L3_error)
11325  }
11326  CYTHON_FALLTHROUGH;
11327  case 11:
11328  if (likely((values[11] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarFactor)) != 0)) kw_args--;
11329  else {
11330  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_interiorBoundaries", 1, 12, 12, 11); __PYX_ERR(0, 1103, __pyx_L3_error)
11331  }
11332  }
11333  if (unlikely(kw_args > 0)) {
11334  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "calculateConservationJacobianPWL_interiorBoundaries") < 0)) __PYX_ERR(0, 1103, __pyx_L3_error)
11335  }
11336  } else if (PyTuple_GET_SIZE(__pyx_args) != 12) {
11337  goto __pyx_L5_argtuple_error;
11338  } else {
11339  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
11340  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
11341  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
11342  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
11343  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
11344  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
11345  values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
11346  values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
11347  values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
11348  values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
11349  values[10] = PyTuple_GET_ITEM(__pyx_args, 10);
11350  values[11] = PyTuple_GET_ITEM(__pyx_args, 11);
11351  }
11352  __pyx_v_interiorElementBoundaries = ((PyArrayObject *)values[0]);
11353  __pyx_v_exteriorElementBoundaries = ((PyArrayObject *)values[1]);
11354  __pyx_v_elementBoundaryElements = ((PyArrayObject *)values[2]);
11355  __pyx_v_elementBoundaryLocalElementBoundaries = ((PyArrayObject *)values[3]);
11356  __pyx_v_elementNodes = ((PyArrayObject *)values[4]);
11357  __pyx_v_nodeStarElements = ((PyArrayObject *)values[5]);
11358  __pyx_v_nodeStarElementNeighbors = ((PyArrayObject *)values[6]);
11359  __pyx_v_nElements_node = ((PyArrayObject *)values[7]);
11360  __pyx_v_fluxElementBoundaries = ((PyArrayObject *)values[8]);
11361  __pyx_v_w = ((PyArrayObject *)values[9]);
11362  __pyx_v_n = ((PyArrayObject *)values[10]);
11363  __pyx_v_nodeStarFactor = ((struct __pyx_obj_15cpostprocessing_NodeStarFactor *)values[11]);
11364  }
11365  goto __pyx_L4_argument_unpacking_done;
11366  __pyx_L5_argtuple_error:;
11367  __Pyx_RaiseArgtupleInvalid("calculateConservationJacobianPWL_interiorBoundaries", 1, 12, 12, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 1103, __pyx_L3_error)
11368  __pyx_L3_error:;
11369  __Pyx_AddTraceback("cpostprocessing.calculateConservationJacobianPWL_interiorBoundaries", __pyx_clineno, __pyx_lineno, __pyx_filename);
11370  __Pyx_RefNannyFinishContext();
11371  return NULL;
11372  __pyx_L4_argument_unpacking_done:;
11373  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_interiorElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "interiorElementBoundaries", 0))) __PYX_ERR(0, 1103, __pyx_L1_error)
11374  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_exteriorElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "exteriorElementBoundaries", 0))) __PYX_ERR(0, 1104, __pyx_L1_error)
11375  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryElements), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryElements", 0))) __PYX_ERR(0, 1105, __pyx_L1_error)
11376  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryLocalElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryLocalElementBoundaries", 0))) __PYX_ERR(0, 1106, __pyx_L1_error)
11377  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementNodes), __pyx_ptype_5numpy_ndarray, 1, "elementNodes", 0))) __PYX_ERR(0, 1107, __pyx_L1_error)
11378  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarElements), __pyx_ptype_5numpy_ndarray, 1, "nodeStarElements", 0))) __PYX_ERR(0, 1108, __pyx_L1_error)
11379  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarElementNeighbors), __pyx_ptype_5numpy_ndarray, 1, "nodeStarElementNeighbors", 0))) __PYX_ERR(0, 1109, __pyx_L1_error)
11380  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nElements_node), __pyx_ptype_5numpy_ndarray, 1, "nElements_node", 0))) __PYX_ERR(0, 1110, __pyx_L1_error)
11381  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_fluxElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "fluxElementBoundaries", 0))) __PYX_ERR(0, 1111, __pyx_L1_error)
11382  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_w), __pyx_ptype_5numpy_ndarray, 1, "w", 0))) __PYX_ERR(0, 1112, __pyx_L1_error)
11383  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_n), __pyx_ptype_5numpy_ndarray, 1, "n", 0))) __PYX_ERR(0, 1113, __pyx_L1_error)
11384  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarFactor), __pyx_ptype_15cpostprocessing_NodeStarFactor, 1, "nodeStarFactor", 0))) __PYX_ERR(0, 1114, __pyx_L1_error)
11385  __pyx_r = __pyx_pf_15cpostprocessing_86calculateConservationJacobianPWL_interiorBoundaries(__pyx_self, __pyx_v_interiorElementBoundaries, __pyx_v_exteriorElementBoundaries, __pyx_v_elementBoundaryElements, __pyx_v_elementBoundaryLocalElementBoundaries, __pyx_v_elementNodes, __pyx_v_nodeStarElements, __pyx_v_nodeStarElementNeighbors, __pyx_v_nElements_node, __pyx_v_fluxElementBoundaries, __pyx_v_w, __pyx_v_n, __pyx_v_nodeStarFactor);
11386 
11387  /* function exit code */
11388  goto __pyx_L0;
11389  __pyx_L1_error:;
11390  __pyx_r = NULL;
11391  __pyx_L0:;
11392  __Pyx_RefNannyFinishContext();
11393  return __pyx_r;
11394 }
11395 
11396 static PyObject *__pyx_pf_15cpostprocessing_86calculateConservationJacobianPWL_interiorBoundaries(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_interiorElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries, PyArrayObject *__pyx_v_elementNodes, PyArrayObject *__pyx_v_nodeStarElements, PyArrayObject *__pyx_v_nodeStarElementNeighbors, PyArrayObject *__pyx_v_nElements_node, PyArrayObject *__pyx_v_fluxElementBoundaries, PyArrayObject *__pyx_v_w, PyArrayObject *__pyx_v_n, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor) {
11397  PyObject *__pyx_r = NULL;
11398  __Pyx_RefNannyDeclarations
11399  int __pyx_lineno = 0;
11400  const char *__pyx_filename = NULL;
11401  int __pyx_clineno = 0;
11402  __Pyx_RefNannySetupContext("calculateConservationJacobianPWL_interiorBoundaries", 0);
11403 
11404  /* "cpostprocessing.pyx":1115
11405  * np.ndarray n,
11406  * NodeStarFactor nodeStarFactor):
11407  * assert fluxElementBoundaries.shape[0] == elementBoundaryLocalElementBoundaries.shape[0] # <<<<<<<<<<<<<<
11408  * pp.calculateConservationJacobianPWL_interiorBoundaries(nElements_node.shape[0],
11409  * w.shape[0],
11410  */
11411  #ifndef CYTHON_WITHOUT_ASSERTIONS
11412  if (unlikely(!Py_OptimizeFlag)) {
11413  if (unlikely(!(((__pyx_v_fluxElementBoundaries->dimensions[0]) == (__pyx_v_elementBoundaryLocalElementBoundaries->dimensions[0])) != 0))) {
11414  PyErr_SetNone(PyExc_AssertionError);
11415  __PYX_ERR(0, 1115, __pyx_L1_error)
11416  }
11417  }
11418  #endif
11419 
11420  /* "cpostprocessing.pyx":1116
11421  * NodeStarFactor nodeStarFactor):
11422  * assert fluxElementBoundaries.shape[0] == elementBoundaryLocalElementBoundaries.shape[0]
11423  * pp.calculateConservationJacobianPWL_interiorBoundaries(nElements_node.shape[0], # <<<<<<<<<<<<<<
11424  * w.shape[0],
11425  * interiorElementBoundaries.shape[0],
11426  */
11427  calculateConservationJacobianPWL_interiorBoundaries((__pyx_v_nElements_node->dimensions[0]), (__pyx_v_w->dimensions[0]), (__pyx_v_interiorElementBoundaries->dimensions[0]), (__pyx_v_exteriorElementBoundaries->dimensions[0]), (__pyx_v_w->dimensions[1]), (__pyx_v_w->dimensions[2]), (__pyx_v_w->dimensions[3]), (__pyx_v_n->dimensions[2]), ((int *)__pyx_v_interiorElementBoundaries->data), ((int *)__pyx_v_exteriorElementBoundaries->data), ((int *)__pyx_v_elementBoundaryElements->data), ((int *)__pyx_v_elementBoundaryLocalElementBoundaries->data), ((int *)__pyx_v_elementNodes->data), ((int *)__pyx_v_nodeStarElements->data), ((int *)__pyx_v_nodeStarElementNeighbors->data), ((int *)__pyx_v_nElements_node->data), ((int *)__pyx_v_fluxElementBoundaries->data), ((double *)__pyx_v_w->data), ((double *)__pyx_v_n->data), (&__pyx_v_nodeStarFactor->nsf));
11428 
11429  /* "cpostprocessing.pyx":1103
11430  * <double*>(vConservative_element.data))
11431  *
11432  * def calculateConservationJacobianPWL_interiorBoundaries(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
11433  * np.ndarray exteriorElementBoundaries,
11434  * np.ndarray elementBoundaryElements,
11435  */
11436 
11437  /* function exit code */
11438  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
11439  goto __pyx_L0;
11440  __pyx_L1_error:;
11441  __Pyx_AddTraceback("cpostprocessing.calculateConservationJacobianPWL_interiorBoundaries", __pyx_clineno, __pyx_lineno, __pyx_filename);
11442  __pyx_r = NULL;
11443  __pyx_L0:;
11444  __Pyx_XGIVEREF(__pyx_r);
11445  __Pyx_RefNannyFinishContext();
11446  return __pyx_r;
11447 }
11448 
11449 /* "cpostprocessing.pyx":1137
11450  * &nodeStarFactor.nsf)
11451  *
11452  * def _subdomain_U_copy_global2local(int max_nN_owned, # <<<<<<<<<<<<<<
11453  * np.ndarray elementNodes,
11454  * np.ndarray nodeStarElements,
11455  */
11456 
11457 /* Python wrapper */
11458 static PyObject *__pyx_pw_15cpostprocessing_89_subdomain_U_copy_global2local(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
11459 static PyMethodDef __pyx_mdef_15cpostprocessing_89_subdomain_U_copy_global2local = {"_subdomain_U_copy_global2local", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_89_subdomain_U_copy_global2local, METH_VARARGS|METH_KEYWORDS, 0};
11460 static PyObject *__pyx_pw_15cpostprocessing_89_subdomain_U_copy_global2local(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
11461  int __pyx_v_max_nN_owned;
11462  PyArrayObject *__pyx_v_elementNodes = 0;
11463  PyArrayObject *__pyx_v_nodeStarElements = 0;
11464  struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor = 0;
11465  PyArrayObject *__pyx_v_subdomain_U = 0;
11466  int __pyx_lineno = 0;
11467  const char *__pyx_filename = NULL;
11468  int __pyx_clineno = 0;
11469  PyObject *__pyx_r = 0;
11470  __Pyx_RefNannyDeclarations
11471  __Pyx_RefNannySetupContext("_subdomain_U_copy_global2local (wrapper)", 0);
11472  {
11473  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_max_nN_owned,&__pyx_n_s_elementNodes,&__pyx_n_s_nodeStarElements,&__pyx_n_s_nodeStarFactor,&__pyx_n_s_subdomain_U,0};
11474  PyObject* values[5] = {0,0,0,0,0};
11475  if (unlikely(__pyx_kwds)) {
11476  Py_ssize_t kw_args;
11477  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
11478  switch (pos_args) {
11479  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
11480  CYTHON_FALLTHROUGH;
11481  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
11482  CYTHON_FALLTHROUGH;
11483  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
11484  CYTHON_FALLTHROUGH;
11485  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
11486  CYTHON_FALLTHROUGH;
11487  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
11488  CYTHON_FALLTHROUGH;
11489  case 0: break;
11490  default: goto __pyx_L5_argtuple_error;
11491  }
11492  kw_args = PyDict_Size(__pyx_kwds);
11493  switch (pos_args) {
11494  case 0:
11495  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_max_nN_owned)) != 0)) kw_args--;
11496  else goto __pyx_L5_argtuple_error;
11497  CYTHON_FALLTHROUGH;
11498  case 1:
11499  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementNodes)) != 0)) kw_args--;
11500  else {
11501  __Pyx_RaiseArgtupleInvalid("_subdomain_U_copy_global2local", 1, 5, 5, 1); __PYX_ERR(0, 1137, __pyx_L3_error)
11502  }
11503  CYTHON_FALLTHROUGH;
11504  case 2:
11505  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarElements)) != 0)) kw_args--;
11506  else {
11507  __Pyx_RaiseArgtupleInvalid("_subdomain_U_copy_global2local", 1, 5, 5, 2); __PYX_ERR(0, 1137, __pyx_L3_error)
11508  }
11509  CYTHON_FALLTHROUGH;
11510  case 3:
11511  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarFactor)) != 0)) kw_args--;
11512  else {
11513  __Pyx_RaiseArgtupleInvalid("_subdomain_U_copy_global2local", 1, 5, 5, 3); __PYX_ERR(0, 1137, __pyx_L3_error)
11514  }
11515  CYTHON_FALLTHROUGH;
11516  case 4:
11517  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_subdomain_U)) != 0)) kw_args--;
11518  else {
11519  __Pyx_RaiseArgtupleInvalid("_subdomain_U_copy_global2local", 1, 5, 5, 4); __PYX_ERR(0, 1137, __pyx_L3_error)
11520  }
11521  }
11522  if (unlikely(kw_args > 0)) {
11523  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_subdomain_U_copy_global2local") < 0)) __PYX_ERR(0, 1137, __pyx_L3_error)
11524  }
11525  } else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
11526  goto __pyx_L5_argtuple_error;
11527  } else {
11528  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
11529  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
11530  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
11531  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
11532  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
11533  }
11534  __pyx_v_max_nN_owned = __Pyx_PyInt_As_int(values[0]); if (unlikely((__pyx_v_max_nN_owned == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 1137, __pyx_L3_error)
11535  __pyx_v_elementNodes = ((PyArrayObject *)values[1]);
11536  __pyx_v_nodeStarElements = ((PyArrayObject *)values[2]);
11537  __pyx_v_nodeStarFactor = ((struct __pyx_obj_15cpostprocessing_NodeStarFactor *)values[3]);
11538  __pyx_v_subdomain_U = ((PyArrayObject *)values[4]);
11539  }
11540  goto __pyx_L4_argument_unpacking_done;
11541  __pyx_L5_argtuple_error:;
11542  __Pyx_RaiseArgtupleInvalid("_subdomain_U_copy_global2local", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 1137, __pyx_L3_error)
11543  __pyx_L3_error:;
11544  __Pyx_AddTraceback("cpostprocessing._subdomain_U_copy_global2local", __pyx_clineno, __pyx_lineno, __pyx_filename);
11545  __Pyx_RefNannyFinishContext();
11546  return NULL;
11547  __pyx_L4_argument_unpacking_done:;
11548  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementNodes), __pyx_ptype_5numpy_ndarray, 1, "elementNodes", 0))) __PYX_ERR(0, 1138, __pyx_L1_error)
11549  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarElements), __pyx_ptype_5numpy_ndarray, 1, "nodeStarElements", 0))) __PYX_ERR(0, 1139, __pyx_L1_error)
11550  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarFactor), __pyx_ptype_15cpostprocessing_NodeStarFactor, 1, "nodeStarFactor", 0))) __PYX_ERR(0, 1140, __pyx_L1_error)
11551  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_subdomain_U), __pyx_ptype_5numpy_ndarray, 1, "subdomain_U", 0))) __PYX_ERR(0, 1141, __pyx_L1_error)
11552  __pyx_r = __pyx_pf_15cpostprocessing_88_subdomain_U_copy_global2local(__pyx_self, __pyx_v_max_nN_owned, __pyx_v_elementNodes, __pyx_v_nodeStarElements, __pyx_v_nodeStarFactor, __pyx_v_subdomain_U);
11553 
11554  /* function exit code */
11555  goto __pyx_L0;
11556  __pyx_L1_error:;
11557  __pyx_r = NULL;
11558  __pyx_L0:;
11559  __Pyx_RefNannyFinishContext();
11560  return __pyx_r;
11561 }
11562 
11563 static PyObject *__pyx_pf_15cpostprocessing_88_subdomain_U_copy_global2local(CYTHON_UNUSED PyObject *__pyx_self, int __pyx_v_max_nN_owned, PyArrayObject *__pyx_v_elementNodes, PyArrayObject *__pyx_v_nodeStarElements, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor, PyArrayObject *__pyx_v_subdomain_U) {
11564  PyObject *__pyx_r = NULL;
11565  __Pyx_RefNannyDeclarations
11566  __Pyx_RefNannySetupContext("_subdomain_U_copy_global2local", 0);
11567 
11568  /* "cpostprocessing.pyx":1142
11569  * NodeStarFactor nodeStarFactor,
11570  * np.ndarray subdomain_U):
11571  * pp.subdomain_U_copy_global2local(max_nN_owned, # <<<<<<<<<<<<<<
11572  * subdomain_U.shape[0],
11573  * subdomain_U.shape[1],
11574  */
11575  subdomain_U_copy_global2local(__pyx_v_max_nN_owned, (__pyx_v_subdomain_U->dimensions[0]), (__pyx_v_subdomain_U->dimensions[1]), ((int *)__pyx_v_elementNodes->data), ((int *)__pyx_v_nodeStarElements->data), (&__pyx_v_nodeStarFactor->nsf), ((double *)__pyx_v_subdomain_U->data));
11576 
11577  /* "cpostprocessing.pyx":1137
11578  * &nodeStarFactor.nsf)
11579  *
11580  * def _subdomain_U_copy_global2local(int max_nN_owned, # <<<<<<<<<<<<<<
11581  * np.ndarray elementNodes,
11582  * np.ndarray nodeStarElements,
11583  */
11584 
11585  /* function exit code */
11586  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
11587  __Pyx_XGIVEREF(__pyx_r);
11588  __Pyx_RefNannyFinishContext();
11589  return __pyx_r;
11590 }
11591 
11592 /* "cpostprocessing.pyx":1150
11593  * <double*>(subdomain_U.data))
11594  *
11595  * def _subdomain_U_copy_local2global(int max_nN_owned, # <<<<<<<<<<<<<<
11596  * np.ndarray elementNodes,
11597  * np.ndarray nodeStarElements,
11598  */
11599 
11600 /* Python wrapper */
11601 static PyObject *__pyx_pw_15cpostprocessing_91_subdomain_U_copy_local2global(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
11602 static PyMethodDef __pyx_mdef_15cpostprocessing_91_subdomain_U_copy_local2global = {"_subdomain_U_copy_local2global", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_91_subdomain_U_copy_local2global, METH_VARARGS|METH_KEYWORDS, 0};
11603 static PyObject *__pyx_pw_15cpostprocessing_91_subdomain_U_copy_local2global(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
11604  int __pyx_v_max_nN_owned;
11605  PyArrayObject *__pyx_v_elementNodes = 0;
11606  PyArrayObject *__pyx_v_nodeStarElements = 0;
11607  struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor = 0;
11608  PyArrayObject *__pyx_v_subdomain_U = 0;
11609  int __pyx_lineno = 0;
11610  const char *__pyx_filename = NULL;
11611  int __pyx_clineno = 0;
11612  PyObject *__pyx_r = 0;
11613  __Pyx_RefNannyDeclarations
11614  __Pyx_RefNannySetupContext("_subdomain_U_copy_local2global (wrapper)", 0);
11615  {
11616  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_max_nN_owned,&__pyx_n_s_elementNodes,&__pyx_n_s_nodeStarElements,&__pyx_n_s_nodeStarFactor,&__pyx_n_s_subdomain_U,0};
11617  PyObject* values[5] = {0,0,0,0,0};
11618  if (unlikely(__pyx_kwds)) {
11619  Py_ssize_t kw_args;
11620  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
11621  switch (pos_args) {
11622  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
11623  CYTHON_FALLTHROUGH;
11624  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
11625  CYTHON_FALLTHROUGH;
11626  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
11627  CYTHON_FALLTHROUGH;
11628  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
11629  CYTHON_FALLTHROUGH;
11630  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
11631  CYTHON_FALLTHROUGH;
11632  case 0: break;
11633  default: goto __pyx_L5_argtuple_error;
11634  }
11635  kw_args = PyDict_Size(__pyx_kwds);
11636  switch (pos_args) {
11637  case 0:
11638  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_max_nN_owned)) != 0)) kw_args--;
11639  else goto __pyx_L5_argtuple_error;
11640  CYTHON_FALLTHROUGH;
11641  case 1:
11642  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementNodes)) != 0)) kw_args--;
11643  else {
11644  __Pyx_RaiseArgtupleInvalid("_subdomain_U_copy_local2global", 1, 5, 5, 1); __PYX_ERR(0, 1150, __pyx_L3_error)
11645  }
11646  CYTHON_FALLTHROUGH;
11647  case 2:
11648  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarElements)) != 0)) kw_args--;
11649  else {
11650  __Pyx_RaiseArgtupleInvalid("_subdomain_U_copy_local2global", 1, 5, 5, 2); __PYX_ERR(0, 1150, __pyx_L3_error)
11651  }
11652  CYTHON_FALLTHROUGH;
11653  case 3:
11654  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nodeStarFactor)) != 0)) kw_args--;
11655  else {
11656  __Pyx_RaiseArgtupleInvalid("_subdomain_U_copy_local2global", 1, 5, 5, 3); __PYX_ERR(0, 1150, __pyx_L3_error)
11657  }
11658  CYTHON_FALLTHROUGH;
11659  case 4:
11660  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_subdomain_U)) != 0)) kw_args--;
11661  else {
11662  __Pyx_RaiseArgtupleInvalid("_subdomain_U_copy_local2global", 1, 5, 5, 4); __PYX_ERR(0, 1150, __pyx_L3_error)
11663  }
11664  }
11665  if (unlikely(kw_args > 0)) {
11666  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_subdomain_U_copy_local2global") < 0)) __PYX_ERR(0, 1150, __pyx_L3_error)
11667  }
11668  } else if (PyTuple_GET_SIZE(__pyx_args) != 5) {
11669  goto __pyx_L5_argtuple_error;
11670  } else {
11671  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
11672  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
11673  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
11674  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
11675  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
11676  }
11677  __pyx_v_max_nN_owned = __Pyx_PyInt_As_int(values[0]); if (unlikely((__pyx_v_max_nN_owned == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 1150, __pyx_L3_error)
11678  __pyx_v_elementNodes = ((PyArrayObject *)values[1]);
11679  __pyx_v_nodeStarElements = ((PyArrayObject *)values[2]);
11680  __pyx_v_nodeStarFactor = ((struct __pyx_obj_15cpostprocessing_NodeStarFactor *)values[3]);
11681  __pyx_v_subdomain_U = ((PyArrayObject *)values[4]);
11682  }
11683  goto __pyx_L4_argument_unpacking_done;
11684  __pyx_L5_argtuple_error:;
11685  __Pyx_RaiseArgtupleInvalid("_subdomain_U_copy_local2global", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 1150, __pyx_L3_error)
11686  __pyx_L3_error:;
11687  __Pyx_AddTraceback("cpostprocessing._subdomain_U_copy_local2global", __pyx_clineno, __pyx_lineno, __pyx_filename);
11688  __Pyx_RefNannyFinishContext();
11689  return NULL;
11690  __pyx_L4_argument_unpacking_done:;
11691  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementNodes), __pyx_ptype_5numpy_ndarray, 1, "elementNodes", 0))) __PYX_ERR(0, 1151, __pyx_L1_error)
11692  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarElements), __pyx_ptype_5numpy_ndarray, 1, "nodeStarElements", 0))) __PYX_ERR(0, 1152, __pyx_L1_error)
11693  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_nodeStarFactor), __pyx_ptype_15cpostprocessing_NodeStarFactor, 1, "nodeStarFactor", 0))) __PYX_ERR(0, 1153, __pyx_L1_error)
11694  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_subdomain_U), __pyx_ptype_5numpy_ndarray, 1, "subdomain_U", 0))) __PYX_ERR(0, 1154, __pyx_L1_error)
11695  __pyx_r = __pyx_pf_15cpostprocessing_90_subdomain_U_copy_local2global(__pyx_self, __pyx_v_max_nN_owned, __pyx_v_elementNodes, __pyx_v_nodeStarElements, __pyx_v_nodeStarFactor, __pyx_v_subdomain_U);
11696 
11697  /* function exit code */
11698  goto __pyx_L0;
11699  __pyx_L1_error:;
11700  __pyx_r = NULL;
11701  __pyx_L0:;
11702  __Pyx_RefNannyFinishContext();
11703  return __pyx_r;
11704 }
11705 
11706 static PyObject *__pyx_pf_15cpostprocessing_90_subdomain_U_copy_local2global(CYTHON_UNUSED PyObject *__pyx_self, int __pyx_v_max_nN_owned, PyArrayObject *__pyx_v_elementNodes, PyArrayObject *__pyx_v_nodeStarElements, struct __pyx_obj_15cpostprocessing_NodeStarFactor *__pyx_v_nodeStarFactor, PyArrayObject *__pyx_v_subdomain_U) {
11707  PyObject *__pyx_r = NULL;
11708  __Pyx_RefNannyDeclarations
11709  __Pyx_RefNannySetupContext("_subdomain_U_copy_local2global", 0);
11710 
11711  /* "cpostprocessing.pyx":1155
11712  * NodeStarFactor nodeStarFactor,
11713  * np.ndarray subdomain_U):
11714  * pp.subdomain_U_copy_local2global(max_nN_owned, # <<<<<<<<<<<<<<
11715  * subdomain_U.shape[0],
11716  * subdomain_U.shape[1],
11717  */
11718  subdomain_U_copy_local2global(__pyx_v_max_nN_owned, (__pyx_v_subdomain_U->dimensions[0]), (__pyx_v_subdomain_U->dimensions[1]), ((int *)__pyx_v_elementNodes->data), ((int *)__pyx_v_nodeStarElements->data), (&__pyx_v_nodeStarFactor->nsf), ((double *)__pyx_v_subdomain_U->data));
11719 
11720  /* "cpostprocessing.pyx":1150
11721  * <double*>(subdomain_U.data))
11722  *
11723  * def _subdomain_U_copy_local2global(int max_nN_owned, # <<<<<<<<<<<<<<
11724  * np.ndarray elementNodes,
11725  * np.ndarray nodeStarElements,
11726  */
11727 
11728  /* function exit code */
11729  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
11730  __Pyx_XGIVEREF(__pyx_r);
11731  __Pyx_RefNannyFinishContext();
11732  return __pyx_r;
11733 }
11734 
11735 /* "cpostprocessing.pyx":1163
11736  * <double*>(subdomain_U.data))
11737  *
11738  * def calculateConservationResidualGlobalBoundaries(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
11739  * np.ndarray exteriorElementBoundaries,
11740  * np.ndarray elementBoundaryElements,
11741  */
11742 
11743 /* Python wrapper */
11744 static PyObject *__pyx_pw_15cpostprocessing_93calculateConservationResidualGlobalBoundaries(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
11745 static PyMethodDef __pyx_mdef_15cpostprocessing_93calculateConservationResidualGlobalBoundaries = {"calculateConservationResidualGlobalBoundaries", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_93calculateConservationResidualGlobalBoundaries, METH_VARARGS|METH_KEYWORDS, 0};
11746 static PyObject *__pyx_pw_15cpostprocessing_93calculateConservationResidualGlobalBoundaries(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
11747  PyArrayObject *__pyx_v_interiorElementBoundaries = 0;
11748  PyArrayObject *__pyx_v_exteriorElementBoundaries = 0;
11749  PyArrayObject *__pyx_v_elementBoundaryElements = 0;
11750  PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries = 0;
11751  PyArrayObject *__pyx_v_exteriorElementBoundariesToSkip = 0;
11752  PyArrayObject *__pyx_v_dS = 0;
11753  PyArrayObject *__pyx_v_n = 0;
11754  PyArrayObject *__pyx_v_elementResidual = 0;
11755  PyArrayObject *__pyx_v_velocity = 0;
11756  PyArrayObject *__pyx_v_conservationResidual = 0;
11757  int __pyx_lineno = 0;
11758  const char *__pyx_filename = NULL;
11759  int __pyx_clineno = 0;
11760  PyObject *__pyx_r = 0;
11761  __Pyx_RefNannyDeclarations
11762  __Pyx_RefNannySetupContext("calculateConservationResidualGlobalBoundaries (wrapper)", 0);
11763  {
11764  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_interiorElementBoundaries,&__pyx_n_s_exteriorElementBoundaries,&__pyx_n_s_elementBoundaryElements,&__pyx_n_s_elementBoundaryLocalElementBound,&__pyx_n_s_exteriorElementBoundariesToSkip,&__pyx_n_s_dS,&__pyx_n_s_n,&__pyx_n_s_elementResidual,&__pyx_n_s_velocity,&__pyx_n_s_conservationResidual,0};
11765  PyObject* values[10] = {0,0,0,0,0,0,0,0,0,0};
11766  if (unlikely(__pyx_kwds)) {
11767  Py_ssize_t kw_args;
11768  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
11769  switch (pos_args) {
11770  case 10: values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
11771  CYTHON_FALLTHROUGH;
11772  case 9: values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
11773  CYTHON_FALLTHROUGH;
11774  case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
11775  CYTHON_FALLTHROUGH;
11776  case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
11777  CYTHON_FALLTHROUGH;
11778  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
11779  CYTHON_FALLTHROUGH;
11780  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
11781  CYTHON_FALLTHROUGH;
11782  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
11783  CYTHON_FALLTHROUGH;
11784  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
11785  CYTHON_FALLTHROUGH;
11786  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
11787  CYTHON_FALLTHROUGH;
11788  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
11789  CYTHON_FALLTHROUGH;
11790  case 0: break;
11791  default: goto __pyx_L5_argtuple_error;
11792  }
11793  kw_args = PyDict_Size(__pyx_kwds);
11794  switch (pos_args) {
11795  case 0:
11796  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_interiorElementBoundaries)) != 0)) kw_args--;
11797  else goto __pyx_L5_argtuple_error;
11798  CYTHON_FALLTHROUGH;
11799  case 1:
11800  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_exteriorElementBoundaries)) != 0)) kw_args--;
11801  else {
11802  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualGlobalBoundaries", 1, 10, 10, 1); __PYX_ERR(0, 1163, __pyx_L3_error)
11803  }
11804  CYTHON_FALLTHROUGH;
11805  case 2:
11806  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryElements)) != 0)) kw_args--;
11807  else {
11808  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualGlobalBoundaries", 1, 10, 10, 2); __PYX_ERR(0, 1163, __pyx_L3_error)
11809  }
11810  CYTHON_FALLTHROUGH;
11811  case 3:
11812  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryLocalElementBound)) != 0)) kw_args--;
11813  else {
11814  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualGlobalBoundaries", 1, 10, 10, 3); __PYX_ERR(0, 1163, __pyx_L3_error)
11815  }
11816  CYTHON_FALLTHROUGH;
11817  case 4:
11818  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_exteriorElementBoundariesToSkip)) != 0)) kw_args--;
11819  else {
11820  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualGlobalBoundaries", 1, 10, 10, 4); __PYX_ERR(0, 1163, __pyx_L3_error)
11821  }
11822  CYTHON_FALLTHROUGH;
11823  case 5:
11824  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_dS)) != 0)) kw_args--;
11825  else {
11826  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualGlobalBoundaries", 1, 10, 10, 5); __PYX_ERR(0, 1163, __pyx_L3_error)
11827  }
11828  CYTHON_FALLTHROUGH;
11829  case 6:
11830  if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_n)) != 0)) kw_args--;
11831  else {
11832  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualGlobalBoundaries", 1, 10, 10, 6); __PYX_ERR(0, 1163, __pyx_L3_error)
11833  }
11834  CYTHON_FALLTHROUGH;
11835  case 7:
11836  if (likely((values[7] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementResidual)) != 0)) kw_args--;
11837  else {
11838  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualGlobalBoundaries", 1, 10, 10, 7); __PYX_ERR(0, 1163, __pyx_L3_error)
11839  }
11840  CYTHON_FALLTHROUGH;
11841  case 8:
11842  if (likely((values[8] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_velocity)) != 0)) kw_args--;
11843  else {
11844  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualGlobalBoundaries", 1, 10, 10, 8); __PYX_ERR(0, 1163, __pyx_L3_error)
11845  }
11846  CYTHON_FALLTHROUGH;
11847  case 9:
11848  if (likely((values[9] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_conservationResidual)) != 0)) kw_args--;
11849  else {
11850  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualGlobalBoundaries", 1, 10, 10, 9); __PYX_ERR(0, 1163, __pyx_L3_error)
11851  }
11852  }
11853  if (unlikely(kw_args > 0)) {
11854  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "calculateConservationResidualGlobalBoundaries") < 0)) __PYX_ERR(0, 1163, __pyx_L3_error)
11855  }
11856  } else if (PyTuple_GET_SIZE(__pyx_args) != 10) {
11857  goto __pyx_L5_argtuple_error;
11858  } else {
11859  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
11860  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
11861  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
11862  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
11863  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
11864  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
11865  values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
11866  values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
11867  values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
11868  values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
11869  }
11870  __pyx_v_interiorElementBoundaries = ((PyArrayObject *)values[0]);
11871  __pyx_v_exteriorElementBoundaries = ((PyArrayObject *)values[1]);
11872  __pyx_v_elementBoundaryElements = ((PyArrayObject *)values[2]);
11873  __pyx_v_elementBoundaryLocalElementBoundaries = ((PyArrayObject *)values[3]);
11874  __pyx_v_exteriorElementBoundariesToSkip = ((PyArrayObject *)values[4]);
11875  __pyx_v_dS = ((PyArrayObject *)values[5]);
11876  __pyx_v_n = ((PyArrayObject *)values[6]);
11877  __pyx_v_elementResidual = ((PyArrayObject *)values[7]);
11878  __pyx_v_velocity = ((PyArrayObject *)values[8]);
11879  __pyx_v_conservationResidual = ((PyArrayObject *)values[9]);
11880  }
11881  goto __pyx_L4_argument_unpacking_done;
11882  __pyx_L5_argtuple_error:;
11883  __Pyx_RaiseArgtupleInvalid("calculateConservationResidualGlobalBoundaries", 1, 10, 10, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 1163, __pyx_L3_error)
11884  __pyx_L3_error:;
11885  __Pyx_AddTraceback("cpostprocessing.calculateConservationResidualGlobalBoundaries", __pyx_clineno, __pyx_lineno, __pyx_filename);
11886  __Pyx_RefNannyFinishContext();
11887  return NULL;
11888  __pyx_L4_argument_unpacking_done:;
11889  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_interiorElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "interiorElementBoundaries", 0))) __PYX_ERR(0, 1163, __pyx_L1_error)
11890  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_exteriorElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "exteriorElementBoundaries", 0))) __PYX_ERR(0, 1164, __pyx_L1_error)
11891  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryElements), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryElements", 0))) __PYX_ERR(0, 1165, __pyx_L1_error)
11892  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryLocalElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryLocalElementBoundaries", 0))) __PYX_ERR(0, 1166, __pyx_L1_error)
11893  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_exteriorElementBoundariesToSkip), __pyx_ptype_5numpy_ndarray, 1, "exteriorElementBoundariesToSkip", 0))) __PYX_ERR(0, 1167, __pyx_L1_error)
11894  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dS), __pyx_ptype_5numpy_ndarray, 1, "dS", 0))) __PYX_ERR(0, 1168, __pyx_L1_error)
11895  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_n), __pyx_ptype_5numpy_ndarray, 1, "n", 0))) __PYX_ERR(0, 1169, __pyx_L1_error)
11896  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementResidual), __pyx_ptype_5numpy_ndarray, 1, "elementResidual", 0))) __PYX_ERR(0, 1170, __pyx_L1_error)
11897  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_velocity), __pyx_ptype_5numpy_ndarray, 1, "velocity", 0))) __PYX_ERR(0, 1171, __pyx_L1_error)
11898  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_conservationResidual), __pyx_ptype_5numpy_ndarray, 1, "conservationResidual", 0))) __PYX_ERR(0, 1172, __pyx_L1_error)
11899  __pyx_r = __pyx_pf_15cpostprocessing_92calculateConservationResidualGlobalBoundaries(__pyx_self, __pyx_v_interiorElementBoundaries, __pyx_v_exteriorElementBoundaries, __pyx_v_elementBoundaryElements, __pyx_v_elementBoundaryLocalElementBoundaries, __pyx_v_exteriorElementBoundariesToSkip, __pyx_v_dS, __pyx_v_n, __pyx_v_elementResidual, __pyx_v_velocity, __pyx_v_conservationResidual);
11900 
11901  /* function exit code */
11902  goto __pyx_L0;
11903  __pyx_L1_error:;
11904  __pyx_r = NULL;
11905  __pyx_L0:;
11906  __Pyx_RefNannyFinishContext();
11907  return __pyx_r;
11908 }
11909 
11910 static PyObject *__pyx_pf_15cpostprocessing_92calculateConservationResidualGlobalBoundaries(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_interiorElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries, PyArrayObject *__pyx_v_exteriorElementBoundariesToSkip, PyArrayObject *__pyx_v_dS, PyArrayObject *__pyx_v_n, PyArrayObject *__pyx_v_elementResidual, PyArrayObject *__pyx_v_velocity, PyArrayObject *__pyx_v_conservationResidual) {
11911  PyObject *__pyx_r = NULL;
11912  __Pyx_RefNannyDeclarations
11913  __Pyx_RefNannySetupContext("calculateConservationResidualGlobalBoundaries", 0);
11914 
11915  /* "cpostprocessing.pyx":1173
11916  * np.ndarray velocity,
11917  * np.ndarray conservationResidual):
11918  * pp.calculateConservationResidualGlobalBoundaries(conservationResidual.shape[0], # <<<<<<<<<<<<<<
11919  * interiorElementBoundaries.shape[0],
11920  * exteriorElementBoundaries.shape[0],
11921  */
11922  calculateConservationResidualGlobalBoundaries((__pyx_v_conservationResidual->dimensions[0]), (__pyx_v_interiorElementBoundaries->dimensions[0]), (__pyx_v_exteriorElementBoundaries->dimensions[0]), (__pyx_v_dS->dimensions[1]), (__pyx_v_dS->dimensions[2]), (__pyx_v_elementResidual->dimensions[1]), (__pyx_v_velocity->dimensions[2]), ((int *)__pyx_v_interiorElementBoundaries->data), ((int *)__pyx_v_exteriorElementBoundaries->data), ((int *)__pyx_v_elementBoundaryElements->data), ((int *)__pyx_v_elementBoundaryLocalElementBoundaries->data), ((int *)__pyx_v_exteriorElementBoundariesToSkip->data), ((double *)__pyx_v_dS->data), ((double *)__pyx_v_n->data), ((double *)__pyx_v_elementResidual->data), ((double *)__pyx_v_velocity->data), ((double *)__pyx_v_conservationResidual->data));
11923 
11924  /* "cpostprocessing.pyx":1163
11925  * <double*>(subdomain_U.data))
11926  *
11927  * def calculateConservationResidualGlobalBoundaries(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
11928  * np.ndarray exteriorElementBoundaries,
11929  * np.ndarray elementBoundaryElements,
11930  */
11931 
11932  /* function exit code */
11933  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
11934  __Pyx_XGIVEREF(__pyx_r);
11935  __Pyx_RefNannyFinishContext();
11936  return __pyx_r;
11937 }
11938 
11939 /* "cpostprocessing.pyx":1191
11940  * <double*>(conservationResidual.data))
11941  *
11942  * def updateSelectedExteriorElementBoundaryFlux(np.ndarray exteriorElementBoundaries, # <<<<<<<<<<<<<<
11943  * np.ndarray elementBoundaryElements,
11944  * np.ndarray elementBoundaryLocalElementBoundaries,
11945  */
11946 
11947 /* Python wrapper */
11948 static PyObject *__pyx_pw_15cpostprocessing_95updateSelectedExteriorElementBoundaryFlux(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
11949 static PyMethodDef __pyx_mdef_15cpostprocessing_95updateSelectedExteriorElementBoundaryFlux = {"updateSelectedExteriorElementBoundaryFlux", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_95updateSelectedExteriorElementBoundaryFlux, METH_VARARGS|METH_KEYWORDS, 0};
11950 static PyObject *__pyx_pw_15cpostprocessing_95updateSelectedExteriorElementBoundaryFlux(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
11951  PyArrayObject *__pyx_v_exteriorElementBoundaries = 0;
11952  PyArrayObject *__pyx_v_elementBoundaryElements = 0;
11953  PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries = 0;
11954  PyArrayObject *__pyx_v_skipflag_elementBoundaries = 0;
11955  PyArrayObject *__pyx_v_flux = 0;
11956  PyArrayObject *__pyx_v_w = 0;
11957  PyArrayObject *__pyx_v_residual = 0;
11958  int __pyx_lineno = 0;
11959  const char *__pyx_filename = NULL;
11960  int __pyx_clineno = 0;
11961  PyObject *__pyx_r = 0;
11962  __Pyx_RefNannyDeclarations
11963  __Pyx_RefNannySetupContext("updateSelectedExteriorElementBoundaryFlux (wrapper)", 0);
11964  {
11965  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_exteriorElementBoundaries,&__pyx_n_s_elementBoundaryElements,&__pyx_n_s_elementBoundaryLocalElementBound,&__pyx_n_s_skipflag_elementBoundaries,&__pyx_n_s_flux,&__pyx_n_s_w,&__pyx_n_s_residual,0};
11966  PyObject* values[7] = {0,0,0,0,0,0,0};
11967  if (unlikely(__pyx_kwds)) {
11968  Py_ssize_t kw_args;
11969  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
11970  switch (pos_args) {
11971  case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
11972  CYTHON_FALLTHROUGH;
11973  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
11974  CYTHON_FALLTHROUGH;
11975  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
11976  CYTHON_FALLTHROUGH;
11977  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
11978  CYTHON_FALLTHROUGH;
11979  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
11980  CYTHON_FALLTHROUGH;
11981  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
11982  CYTHON_FALLTHROUGH;
11983  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
11984  CYTHON_FALLTHROUGH;
11985  case 0: break;
11986  default: goto __pyx_L5_argtuple_error;
11987  }
11988  kw_args = PyDict_Size(__pyx_kwds);
11989  switch (pos_args) {
11990  case 0:
11991  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_exteriorElementBoundaries)) != 0)) kw_args--;
11992  else goto __pyx_L5_argtuple_error;
11993  CYTHON_FALLTHROUGH;
11994  case 1:
11995  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryElements)) != 0)) kw_args--;
11996  else {
11997  __Pyx_RaiseArgtupleInvalid("updateSelectedExteriorElementBoundaryFlux", 1, 7, 7, 1); __PYX_ERR(0, 1191, __pyx_L3_error)
11998  }
11999  CYTHON_FALLTHROUGH;
12000  case 2:
12001  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementBoundaryLocalElementBound)) != 0)) kw_args--;
12002  else {
12003  __Pyx_RaiseArgtupleInvalid("updateSelectedExteriorElementBoundaryFlux", 1, 7, 7, 2); __PYX_ERR(0, 1191, __pyx_L3_error)
12004  }
12005  CYTHON_FALLTHROUGH;
12006  case 3:
12007  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_skipflag_elementBoundaries)) != 0)) kw_args--;
12008  else {
12009  __Pyx_RaiseArgtupleInvalid("updateSelectedExteriorElementBoundaryFlux", 1, 7, 7, 3); __PYX_ERR(0, 1191, __pyx_L3_error)
12010  }
12011  CYTHON_FALLTHROUGH;
12012  case 4:
12013  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_flux)) != 0)) kw_args--;
12014  else {
12015  __Pyx_RaiseArgtupleInvalid("updateSelectedExteriorElementBoundaryFlux", 1, 7, 7, 4); __PYX_ERR(0, 1191, __pyx_L3_error)
12016  }
12017  CYTHON_FALLTHROUGH;
12018  case 5:
12019  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_w)) != 0)) kw_args--;
12020  else {
12021  __Pyx_RaiseArgtupleInvalid("updateSelectedExteriorElementBoundaryFlux", 1, 7, 7, 5); __PYX_ERR(0, 1191, __pyx_L3_error)
12022  }
12023  CYTHON_FALLTHROUGH;
12024  case 6:
12025  if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_residual)) != 0)) kw_args--;
12026  else {
12027  __Pyx_RaiseArgtupleInvalid("updateSelectedExteriorElementBoundaryFlux", 1, 7, 7, 6); __PYX_ERR(0, 1191, __pyx_L3_error)
12028  }
12029  }
12030  if (unlikely(kw_args > 0)) {
12031  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "updateSelectedExteriorElementBoundaryFlux") < 0)) __PYX_ERR(0, 1191, __pyx_L3_error)
12032  }
12033  } else if (PyTuple_GET_SIZE(__pyx_args) != 7) {
12034  goto __pyx_L5_argtuple_error;
12035  } else {
12036  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
12037  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
12038  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
12039  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
12040  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
12041  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
12042  values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
12043  }
12044  __pyx_v_exteriorElementBoundaries = ((PyArrayObject *)values[0]);
12045  __pyx_v_elementBoundaryElements = ((PyArrayObject *)values[1]);
12046  __pyx_v_elementBoundaryLocalElementBoundaries = ((PyArrayObject *)values[2]);
12047  __pyx_v_skipflag_elementBoundaries = ((PyArrayObject *)values[3]);
12048  __pyx_v_flux = ((PyArrayObject *)values[4]);
12049  __pyx_v_w = ((PyArrayObject *)values[5]);
12050  __pyx_v_residual = ((PyArrayObject *)values[6]);
12051  }
12052  goto __pyx_L4_argument_unpacking_done;
12053  __pyx_L5_argtuple_error:;
12054  __Pyx_RaiseArgtupleInvalid("updateSelectedExteriorElementBoundaryFlux", 1, 7, 7, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 1191, __pyx_L3_error)
12055  __pyx_L3_error:;
12056  __Pyx_AddTraceback("cpostprocessing.updateSelectedExteriorElementBoundaryFlux", __pyx_clineno, __pyx_lineno, __pyx_filename);
12057  __Pyx_RefNannyFinishContext();
12058  return NULL;
12059  __pyx_L4_argument_unpacking_done:;
12060  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_exteriorElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "exteriorElementBoundaries", 0))) __PYX_ERR(0, 1191, __pyx_L1_error)
12061  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryElements), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryElements", 0))) __PYX_ERR(0, 1192, __pyx_L1_error)
12062  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementBoundaryLocalElementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "elementBoundaryLocalElementBoundaries", 0))) __PYX_ERR(0, 1193, __pyx_L1_error)
12063  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_skipflag_elementBoundaries), __pyx_ptype_5numpy_ndarray, 1, "skipflag_elementBoundaries", 0))) __PYX_ERR(0, 1194, __pyx_L1_error)
12064  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_flux), __pyx_ptype_5numpy_ndarray, 1, "flux", 0))) __PYX_ERR(0, 1195, __pyx_L1_error)
12065  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_w), __pyx_ptype_5numpy_ndarray, 1, "w", 0))) __PYX_ERR(0, 1196, __pyx_L1_error)
12066  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_residual), __pyx_ptype_5numpy_ndarray, 1, "residual", 0))) __PYX_ERR(0, 1197, __pyx_L1_error)
12067  __pyx_r = __pyx_pf_15cpostprocessing_94updateSelectedExteriorElementBoundaryFlux(__pyx_self, __pyx_v_exteriorElementBoundaries, __pyx_v_elementBoundaryElements, __pyx_v_elementBoundaryLocalElementBoundaries, __pyx_v_skipflag_elementBoundaries, __pyx_v_flux, __pyx_v_w, __pyx_v_residual);
12068 
12069  /* function exit code */
12070  goto __pyx_L0;
12071  __pyx_L1_error:;
12072  __pyx_r = NULL;
12073  __pyx_L0:;
12074  __Pyx_RefNannyFinishContext();
12075  return __pyx_r;
12076 }
12077 
12078 static PyObject *__pyx_pf_15cpostprocessing_94updateSelectedExteriorElementBoundaryFlux(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_exteriorElementBoundaries, PyArrayObject *__pyx_v_elementBoundaryElements, PyArrayObject *__pyx_v_elementBoundaryLocalElementBoundaries, PyArrayObject *__pyx_v_skipflag_elementBoundaries, PyArrayObject *__pyx_v_flux, PyArrayObject *__pyx_v_w, PyArrayObject *__pyx_v_residual) {
12079  PyObject *__pyx_r = NULL;
12080  __Pyx_RefNannyDeclarations
12081  __Pyx_RefNannySetupContext("updateSelectedExteriorElementBoundaryFlux", 0);
12082 
12083  /* "cpostprocessing.pyx":1198
12084  * np.ndarray w,
12085  * np.ndarray residual):
12086  * pp.updateSelectedExteriorElementBoundaryFlux(exteriorElementBoundaries.shape[0], # <<<<<<<<<<<<<<
12087  * w.shape[1],
12088  * w.shape[2],
12089  */
12090  updateSelectedExteriorElementBoundaryFlux((__pyx_v_exteriorElementBoundaries->dimensions[0]), (__pyx_v_w->dimensions[1]), (__pyx_v_w->dimensions[2]), (__pyx_v_w->dimensions[3]), ((int *)__pyx_v_exteriorElementBoundaries->data), ((int *)__pyx_v_elementBoundaryElements->data), ((int *)__pyx_v_elementBoundaryLocalElementBoundaries->data), ((int *)__pyx_v_skipflag_elementBoundaries->data), ((double *)__pyx_v_flux->data), ((double *)__pyx_v_w->data), ((double *)__pyx_v_residual->data));
12091 
12092  /* "cpostprocessing.pyx":1191
12093  * <double*>(conservationResidual.data))
12094  *
12095  * def updateSelectedExteriorElementBoundaryFlux(np.ndarray exteriorElementBoundaries, # <<<<<<<<<<<<<<
12096  * np.ndarray elementBoundaryElements,
12097  * np.ndarray elementBoundaryLocalElementBoundaries,
12098  */
12099 
12100  /* function exit code */
12101  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
12102  __Pyx_XGIVEREF(__pyx_r);
12103  __Pyx_RefNannyFinishContext();
12104  return __pyx_r;
12105 }
12106 
12107 /* "cpostprocessing.pyx":1210
12108  * <double*>(residual.data))
12109  *
12110  * def updateAdvectiveVelocityPointEval(double updateCoef, # <<<<<<<<<<<<<<
12111  * np.ndarray advectiveVelocity,
12112  * np.ndarray velocity):
12113  */
12114 
12115 /* Python wrapper */
12116 static PyObject *__pyx_pw_15cpostprocessing_97updateAdvectiveVelocityPointEval(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
12117 static PyMethodDef __pyx_mdef_15cpostprocessing_97updateAdvectiveVelocityPointEval = {"updateAdvectiveVelocityPointEval", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_97updateAdvectiveVelocityPointEval, METH_VARARGS|METH_KEYWORDS, 0};
12118 static PyObject *__pyx_pw_15cpostprocessing_97updateAdvectiveVelocityPointEval(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
12119  double __pyx_v_updateCoef;
12120  PyArrayObject *__pyx_v_advectiveVelocity = 0;
12121  PyArrayObject *__pyx_v_velocity = 0;
12122  int __pyx_lineno = 0;
12123  const char *__pyx_filename = NULL;
12124  int __pyx_clineno = 0;
12125  PyObject *__pyx_r = 0;
12126  __Pyx_RefNannyDeclarations
12127  __Pyx_RefNannySetupContext("updateAdvectiveVelocityPointEval (wrapper)", 0);
12128  {
12129  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_updateCoef,&__pyx_n_s_advectiveVelocity,&__pyx_n_s_velocity,0};
12130  PyObject* values[3] = {0,0,0};
12131  if (unlikely(__pyx_kwds)) {
12132  Py_ssize_t kw_args;
12133  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
12134  switch (pos_args) {
12135  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
12136  CYTHON_FALLTHROUGH;
12137  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
12138  CYTHON_FALLTHROUGH;
12139  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
12140  CYTHON_FALLTHROUGH;
12141  case 0: break;
12142  default: goto __pyx_L5_argtuple_error;
12143  }
12144  kw_args = PyDict_Size(__pyx_kwds);
12145  switch (pos_args) {
12146  case 0:
12147  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_updateCoef)) != 0)) kw_args--;
12148  else goto __pyx_L5_argtuple_error;
12149  CYTHON_FALLTHROUGH;
12150  case 1:
12151  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_advectiveVelocity)) != 0)) kw_args--;
12152  else {
12153  __Pyx_RaiseArgtupleInvalid("updateAdvectiveVelocityPointEval", 1, 3, 3, 1); __PYX_ERR(0, 1210, __pyx_L3_error)
12154  }
12155  CYTHON_FALLTHROUGH;
12156  case 2:
12157  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_velocity)) != 0)) kw_args--;
12158  else {
12159  __Pyx_RaiseArgtupleInvalid("updateAdvectiveVelocityPointEval", 1, 3, 3, 2); __PYX_ERR(0, 1210, __pyx_L3_error)
12160  }
12161  }
12162  if (unlikely(kw_args > 0)) {
12163  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "updateAdvectiveVelocityPointEval") < 0)) __PYX_ERR(0, 1210, __pyx_L3_error)
12164  }
12165  } else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
12166  goto __pyx_L5_argtuple_error;
12167  } else {
12168  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
12169  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
12170  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
12171  }
12172  __pyx_v_updateCoef = __pyx_PyFloat_AsDouble(values[0]); if (unlikely((__pyx_v_updateCoef == (double)-1) && PyErr_Occurred())) __PYX_ERR(0, 1210, __pyx_L3_error)
12173  __pyx_v_advectiveVelocity = ((PyArrayObject *)values[1]);
12174  __pyx_v_velocity = ((PyArrayObject *)values[2]);
12175  }
12176  goto __pyx_L4_argument_unpacking_done;
12177  __pyx_L5_argtuple_error:;
12178  __Pyx_RaiseArgtupleInvalid("updateAdvectiveVelocityPointEval", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 1210, __pyx_L3_error)
12179  __pyx_L3_error:;
12180  __Pyx_AddTraceback("cpostprocessing.updateAdvectiveVelocityPointEval", __pyx_clineno, __pyx_lineno, __pyx_filename);
12181  __Pyx_RefNannyFinishContext();
12182  return NULL;
12183  __pyx_L4_argument_unpacking_done:;
12184  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_advectiveVelocity), __pyx_ptype_5numpy_ndarray, 1, "advectiveVelocity", 0))) __PYX_ERR(0, 1211, __pyx_L1_error)
12185  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_velocity), __pyx_ptype_5numpy_ndarray, 1, "velocity", 0))) __PYX_ERR(0, 1212, __pyx_L1_error)
12186  __pyx_r = __pyx_pf_15cpostprocessing_96updateAdvectiveVelocityPointEval(__pyx_self, __pyx_v_updateCoef, __pyx_v_advectiveVelocity, __pyx_v_velocity);
12187 
12188  /* function exit code */
12189  goto __pyx_L0;
12190  __pyx_L1_error:;
12191  __pyx_r = NULL;
12192  __pyx_L0:;
12193  __Pyx_RefNannyFinishContext();
12194  return __pyx_r;
12195 }
12196 
12197 static PyObject *__pyx_pf_15cpostprocessing_96updateAdvectiveVelocityPointEval(CYTHON_UNUSED PyObject *__pyx_self, double __pyx_v_updateCoef, PyArrayObject *__pyx_v_advectiveVelocity, PyArrayObject *__pyx_v_velocity) {
12198  int __pyx_v_nPoints;
12199  PyObject *__pyx_r = NULL;
12200  __Pyx_RefNannyDeclarations
12201  PyObject *__pyx_t_1 = NULL;
12202  PyObject *__pyx_t_2 = NULL;
12203  PyObject *__pyx_t_3 = NULL;
12204  int __pyx_t_4;
12205  int __pyx_lineno = 0;
12206  const char *__pyx_filename = NULL;
12207  int __pyx_clineno = 0;
12208  __Pyx_RefNannySetupContext("updateAdvectiveVelocityPointEval", 0);
12209 
12210  /* "cpostprocessing.pyx":1213
12211  * np.ndarray advectiveVelocity,
12212  * np.ndarray velocity):
12213  * cdef int nPoints = velocity.size/velocity.shape[velocity.ndim-1] # <<<<<<<<<<<<<<
12214  * pp.postprocessAdvectiveVelocityPointEval(nPoints,
12215  * velocity.shape[velocity.ndim-1],
12216  */
12217  __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_velocity), __pyx_n_s_size); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1213, __pyx_L1_error)
12218  __Pyx_GOTREF(__pyx_t_1);
12219  __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_velocity->dimensions[(__pyx_v_velocity->nd - 1)])); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1213, __pyx_L1_error)
12220  __Pyx_GOTREF(__pyx_t_2);
12221  __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1213, __pyx_L1_error)
12222  __Pyx_GOTREF(__pyx_t_3);
12223  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
12224  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
12225  __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3); if (unlikely((__pyx_t_4 == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 1213, __pyx_L1_error)
12226  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
12227  __pyx_v_nPoints = __pyx_t_4;
12228 
12229  /* "cpostprocessing.pyx":1214
12230  * np.ndarray velocity):
12231  * cdef int nPoints = velocity.size/velocity.shape[velocity.ndim-1]
12232  * pp.postprocessAdvectiveVelocityPointEval(nPoints, # <<<<<<<<<<<<<<
12233  * velocity.shape[velocity.ndim-1],
12234  * updateCoef,
12235  */
12236  postprocessAdvectiveVelocityPointEval(__pyx_v_nPoints, (__pyx_v_velocity->dimensions[(__pyx_v_velocity->nd - 1)]), __pyx_v_updateCoef, ((double *)__pyx_v_advectiveVelocity->data), ((double *)__pyx_v_velocity->data));
12237 
12238  /* "cpostprocessing.pyx":1210
12239  * <double*>(residual.data))
12240  *
12241  * def updateAdvectiveVelocityPointEval(double updateCoef, # <<<<<<<<<<<<<<
12242  * np.ndarray advectiveVelocity,
12243  * np.ndarray velocity):
12244  */
12245 
12246  /* function exit code */
12247  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
12248  goto __pyx_L0;
12249  __pyx_L1_error:;
12250  __Pyx_XDECREF(__pyx_t_1);
12251  __Pyx_XDECREF(__pyx_t_2);
12252  __Pyx_XDECREF(__pyx_t_3);
12253  __Pyx_AddTraceback("cpostprocessing.updateAdvectiveVelocityPointEval", __pyx_clineno, __pyx_lineno, __pyx_filename);
12254  __pyx_r = NULL;
12255  __pyx_L0:;
12256  __Pyx_XGIVEREF(__pyx_r);
12257  __Pyx_RefNannyFinishContext();
12258  return __pyx_r;
12259 }
12260 
12261 /* "cpostprocessing.pyx":1220
12262  * <double*>(velocity.data))
12263  *
12264  * def updateDiffusiveVelocityPointEval(double updateCoef, # <<<<<<<<<<<<<<
12265  * np.ndarray diffusionTensor,
12266  * np.ndarray grad_phi,
12267  */
12268 
12269 /* Python wrapper */
12270 static PyObject *__pyx_pw_15cpostprocessing_99updateDiffusiveVelocityPointEval(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
12271 static PyMethodDef __pyx_mdef_15cpostprocessing_99updateDiffusiveVelocityPointEval = {"updateDiffusiveVelocityPointEval", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_99updateDiffusiveVelocityPointEval, METH_VARARGS|METH_KEYWORDS, 0};
12272 static PyObject *__pyx_pw_15cpostprocessing_99updateDiffusiveVelocityPointEval(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
12273  double __pyx_v_updateCoef;
12274  PyArrayObject *__pyx_v_diffusionTensor = 0;
12275  PyArrayObject *__pyx_v_grad_phi = 0;
12276  PyArrayObject *__pyx_v_velocity = 0;
12277  int __pyx_lineno = 0;
12278  const char *__pyx_filename = NULL;
12279  int __pyx_clineno = 0;
12280  PyObject *__pyx_r = 0;
12281  __Pyx_RefNannyDeclarations
12282  __Pyx_RefNannySetupContext("updateDiffusiveVelocityPointEval (wrapper)", 0);
12283  {
12284  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_updateCoef,&__pyx_n_s_diffusionTensor,&__pyx_n_s_grad_phi,&__pyx_n_s_velocity,0};
12285  PyObject* values[4] = {0,0,0,0};
12286  if (unlikely(__pyx_kwds)) {
12287  Py_ssize_t kw_args;
12288  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
12289  switch (pos_args) {
12290  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
12291  CYTHON_FALLTHROUGH;
12292  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
12293  CYTHON_FALLTHROUGH;
12294  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
12295  CYTHON_FALLTHROUGH;
12296  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
12297  CYTHON_FALLTHROUGH;
12298  case 0: break;
12299  default: goto __pyx_L5_argtuple_error;
12300  }
12301  kw_args = PyDict_Size(__pyx_kwds);
12302  switch (pos_args) {
12303  case 0:
12304  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_updateCoef)) != 0)) kw_args--;
12305  else goto __pyx_L5_argtuple_error;
12306  CYTHON_FALLTHROUGH;
12307  case 1:
12308  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_diffusionTensor)) != 0)) kw_args--;
12309  else {
12310  __Pyx_RaiseArgtupleInvalid("updateDiffusiveVelocityPointEval", 1, 4, 4, 1); __PYX_ERR(0, 1220, __pyx_L3_error)
12311  }
12312  CYTHON_FALLTHROUGH;
12313  case 2:
12314  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_grad_phi)) != 0)) kw_args--;
12315  else {
12316  __Pyx_RaiseArgtupleInvalid("updateDiffusiveVelocityPointEval", 1, 4, 4, 2); __PYX_ERR(0, 1220, __pyx_L3_error)
12317  }
12318  CYTHON_FALLTHROUGH;
12319  case 3:
12320  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_velocity)) != 0)) kw_args--;
12321  else {
12322  __Pyx_RaiseArgtupleInvalid("updateDiffusiveVelocityPointEval", 1, 4, 4, 3); __PYX_ERR(0, 1220, __pyx_L3_error)
12323  }
12324  }
12325  if (unlikely(kw_args > 0)) {
12326  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "updateDiffusiveVelocityPointEval") < 0)) __PYX_ERR(0, 1220, __pyx_L3_error)
12327  }
12328  } else if (PyTuple_GET_SIZE(__pyx_args) != 4) {
12329  goto __pyx_L5_argtuple_error;
12330  } else {
12331  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
12332  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
12333  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
12334  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
12335  }
12336  __pyx_v_updateCoef = __pyx_PyFloat_AsDouble(values[0]); if (unlikely((__pyx_v_updateCoef == (double)-1) && PyErr_Occurred())) __PYX_ERR(0, 1220, __pyx_L3_error)
12337  __pyx_v_diffusionTensor = ((PyArrayObject *)values[1]);
12338  __pyx_v_grad_phi = ((PyArrayObject *)values[2]);
12339  __pyx_v_velocity = ((PyArrayObject *)values[3]);
12340  }
12341  goto __pyx_L4_argument_unpacking_done;
12342  __pyx_L5_argtuple_error:;
12343  __Pyx_RaiseArgtupleInvalid("updateDiffusiveVelocityPointEval", 1, 4, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 1220, __pyx_L3_error)
12344  __pyx_L3_error:;
12345  __Pyx_AddTraceback("cpostprocessing.updateDiffusiveVelocityPointEval", __pyx_clineno, __pyx_lineno, __pyx_filename);
12346  __Pyx_RefNannyFinishContext();
12347  return NULL;
12348  __pyx_L4_argument_unpacking_done:;
12349  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_diffusionTensor), __pyx_ptype_5numpy_ndarray, 1, "diffusionTensor", 0))) __PYX_ERR(0, 1221, __pyx_L1_error)
12350  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_grad_phi), __pyx_ptype_5numpy_ndarray, 1, "grad_phi", 0))) __PYX_ERR(0, 1222, __pyx_L1_error)
12351  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_velocity), __pyx_ptype_5numpy_ndarray, 1, "velocity", 0))) __PYX_ERR(0, 1223, __pyx_L1_error)
12352  __pyx_r = __pyx_pf_15cpostprocessing_98updateDiffusiveVelocityPointEval(__pyx_self, __pyx_v_updateCoef, __pyx_v_diffusionTensor, __pyx_v_grad_phi, __pyx_v_velocity);
12353 
12354  /* function exit code */
12355  goto __pyx_L0;
12356  __pyx_L1_error:;
12357  __pyx_r = NULL;
12358  __pyx_L0:;
12359  __Pyx_RefNannyFinishContext();
12360  return __pyx_r;
12361 }
12362 
12363 static PyObject *__pyx_pf_15cpostprocessing_98updateDiffusiveVelocityPointEval(CYTHON_UNUSED PyObject *__pyx_self, double __pyx_v_updateCoef, PyArrayObject *__pyx_v_diffusionTensor, PyArrayObject *__pyx_v_grad_phi, PyArrayObject *__pyx_v_velocity) {
12364  int __pyx_v_nPoints;
12365  PyObject *__pyx_r = NULL;
12366  __Pyx_RefNannyDeclarations
12367  PyObject *__pyx_t_1 = NULL;
12368  PyObject *__pyx_t_2 = NULL;
12369  PyObject *__pyx_t_3 = NULL;
12370  int __pyx_t_4;
12371  int __pyx_lineno = 0;
12372  const char *__pyx_filename = NULL;
12373  int __pyx_clineno = 0;
12374  __Pyx_RefNannySetupContext("updateDiffusiveVelocityPointEval", 0);
12375 
12376  /* "cpostprocessing.pyx":1224
12377  * np.ndarray grad_phi,
12378  * np.ndarray velocity):
12379  * cdef int nPoints = velocity.size/velocity.shape[velocity.ndim-1] # <<<<<<<<<<<<<<
12380  * pp.postprocessDiffusiveVelocityPointEval(nPoints,
12381  * velocity.shape[velocity.ndim-1],
12382  */
12383  __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_velocity), __pyx_n_s_size); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1224, __pyx_L1_error)
12384  __Pyx_GOTREF(__pyx_t_1);
12385  __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_velocity->dimensions[(__pyx_v_velocity->nd - 1)])); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1224, __pyx_L1_error)
12386  __Pyx_GOTREF(__pyx_t_2);
12387  __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1224, __pyx_L1_error)
12388  __Pyx_GOTREF(__pyx_t_3);
12389  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
12390  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
12391  __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3); if (unlikely((__pyx_t_4 == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 1224, __pyx_L1_error)
12392  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
12393  __pyx_v_nPoints = __pyx_t_4;
12394 
12395  /* "cpostprocessing.pyx":1225
12396  * np.ndarray velocity):
12397  * cdef int nPoints = velocity.size/velocity.shape[velocity.ndim-1]
12398  * pp.postprocessDiffusiveVelocityPointEval(nPoints, # <<<<<<<<<<<<<<
12399  * velocity.shape[velocity.ndim-1],
12400  * updateCoef,
12401  */
12402  postprocessDiffusiveVelocityPointEval(__pyx_v_nPoints, (__pyx_v_velocity->dimensions[(__pyx_v_velocity->nd - 1)]), __pyx_v_updateCoef, ((double *)__pyx_v_diffusionTensor->data), ((double *)__pyx_v_grad_phi->data), ((double *)__pyx_v_velocity->data));
12403 
12404  /* "cpostprocessing.pyx":1220
12405  * <double*>(velocity.data))
12406  *
12407  * def updateDiffusiveVelocityPointEval(double updateCoef, # <<<<<<<<<<<<<<
12408  * np.ndarray diffusionTensor,
12409  * np.ndarray grad_phi,
12410  */
12411 
12412  /* function exit code */
12413  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
12414  goto __pyx_L0;
12415  __pyx_L1_error:;
12416  __Pyx_XDECREF(__pyx_t_1);
12417  __Pyx_XDECREF(__pyx_t_2);
12418  __Pyx_XDECREF(__pyx_t_3);
12419  __Pyx_AddTraceback("cpostprocessing.updateDiffusiveVelocityPointEval", __pyx_clineno, __pyx_lineno, __pyx_filename);
12420  __pyx_r = NULL;
12421  __pyx_L0:;
12422  __Pyx_XGIVEREF(__pyx_r);
12423  __Pyx_RefNannyFinishContext();
12424  return __pyx_r;
12425 }
12426 
12427 /* "cpostprocessing.pyx":1232
12428  * <double*>(velocity.data))
12429  *
12430  * def updateDiffusiveVelocityPointEval_sd(double updateCoef, # <<<<<<<<<<<<<<
12431  * np.ndarray rowptr,
12432  * np.ndarray colind,
12433  */
12434 
12435 /* Python wrapper */
12436 static PyObject *__pyx_pw_15cpostprocessing_101updateDiffusiveVelocityPointEval_sd(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
12437 static PyMethodDef __pyx_mdef_15cpostprocessing_101updateDiffusiveVelocityPointEval_sd = {"updateDiffusiveVelocityPointEval_sd", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_101updateDiffusiveVelocityPointEval_sd, METH_VARARGS|METH_KEYWORDS, 0};
12438 static PyObject *__pyx_pw_15cpostprocessing_101updateDiffusiveVelocityPointEval_sd(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
12439  double __pyx_v_updateCoef;
12440  PyArrayObject *__pyx_v_rowptr = 0;
12441  PyArrayObject *__pyx_v_colind = 0;
12442  PyArrayObject *__pyx_v_diffusionTensor = 0;
12443  PyArrayObject *__pyx_v_grad_phi = 0;
12444  PyArrayObject *__pyx_v_velocity = 0;
12445  int __pyx_lineno = 0;
12446  const char *__pyx_filename = NULL;
12447  int __pyx_clineno = 0;
12448  PyObject *__pyx_r = 0;
12449  __Pyx_RefNannyDeclarations
12450  __Pyx_RefNannySetupContext("updateDiffusiveVelocityPointEval_sd (wrapper)", 0);
12451  {
12452  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_updateCoef,&__pyx_n_s_rowptr,&__pyx_n_s_colind,&__pyx_n_s_diffusionTensor,&__pyx_n_s_grad_phi,&__pyx_n_s_velocity,0};
12453  PyObject* values[6] = {0,0,0,0,0,0};
12454  if (unlikely(__pyx_kwds)) {
12455  Py_ssize_t kw_args;
12456  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
12457  switch (pos_args) {
12458  case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
12459  CYTHON_FALLTHROUGH;
12460  case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
12461  CYTHON_FALLTHROUGH;
12462  case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
12463  CYTHON_FALLTHROUGH;
12464  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
12465  CYTHON_FALLTHROUGH;
12466  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
12467  CYTHON_FALLTHROUGH;
12468  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
12469  CYTHON_FALLTHROUGH;
12470  case 0: break;
12471  default: goto __pyx_L5_argtuple_error;
12472  }
12473  kw_args = PyDict_Size(__pyx_kwds);
12474  switch (pos_args) {
12475  case 0:
12476  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_updateCoef)) != 0)) kw_args--;
12477  else goto __pyx_L5_argtuple_error;
12478  CYTHON_FALLTHROUGH;
12479  case 1:
12480  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rowptr)) != 0)) kw_args--;
12481  else {
12482  __Pyx_RaiseArgtupleInvalid("updateDiffusiveVelocityPointEval_sd", 1, 6, 6, 1); __PYX_ERR(0, 1232, __pyx_L3_error)
12483  }
12484  CYTHON_FALLTHROUGH;
12485  case 2:
12486  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_colind)) != 0)) kw_args--;
12487  else {
12488  __Pyx_RaiseArgtupleInvalid("updateDiffusiveVelocityPointEval_sd", 1, 6, 6, 2); __PYX_ERR(0, 1232, __pyx_L3_error)
12489  }
12490  CYTHON_FALLTHROUGH;
12491  case 3:
12492  if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_diffusionTensor)) != 0)) kw_args--;
12493  else {
12494  __Pyx_RaiseArgtupleInvalid("updateDiffusiveVelocityPointEval_sd", 1, 6, 6, 3); __PYX_ERR(0, 1232, __pyx_L3_error)
12495  }
12496  CYTHON_FALLTHROUGH;
12497  case 4:
12498  if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_grad_phi)) != 0)) kw_args--;
12499  else {
12500  __Pyx_RaiseArgtupleInvalid("updateDiffusiveVelocityPointEval_sd", 1, 6, 6, 4); __PYX_ERR(0, 1232, __pyx_L3_error)
12501  }
12502  CYTHON_FALLTHROUGH;
12503  case 5:
12504  if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_velocity)) != 0)) kw_args--;
12505  else {
12506  __Pyx_RaiseArgtupleInvalid("updateDiffusiveVelocityPointEval_sd", 1, 6, 6, 5); __PYX_ERR(0, 1232, __pyx_L3_error)
12507  }
12508  }
12509  if (unlikely(kw_args > 0)) {
12510  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "updateDiffusiveVelocityPointEval_sd") < 0)) __PYX_ERR(0, 1232, __pyx_L3_error)
12511  }
12512  } else if (PyTuple_GET_SIZE(__pyx_args) != 6) {
12513  goto __pyx_L5_argtuple_error;
12514  } else {
12515  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
12516  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
12517  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
12518  values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
12519  values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
12520  values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
12521  }
12522  __pyx_v_updateCoef = __pyx_PyFloat_AsDouble(values[0]); if (unlikely((__pyx_v_updateCoef == (double)-1) && PyErr_Occurred())) __PYX_ERR(0, 1232, __pyx_L3_error)
12523  __pyx_v_rowptr = ((PyArrayObject *)values[1]);
12524  __pyx_v_colind = ((PyArrayObject *)values[2]);
12525  __pyx_v_diffusionTensor = ((PyArrayObject *)values[3]);
12526  __pyx_v_grad_phi = ((PyArrayObject *)values[4]);
12527  __pyx_v_velocity = ((PyArrayObject *)values[5]);
12528  }
12529  goto __pyx_L4_argument_unpacking_done;
12530  __pyx_L5_argtuple_error:;
12531  __Pyx_RaiseArgtupleInvalid("updateDiffusiveVelocityPointEval_sd", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 1232, __pyx_L3_error)
12532  __pyx_L3_error:;
12533  __Pyx_AddTraceback("cpostprocessing.updateDiffusiveVelocityPointEval_sd", __pyx_clineno, __pyx_lineno, __pyx_filename);
12534  __Pyx_RefNannyFinishContext();
12535  return NULL;
12536  __pyx_L4_argument_unpacking_done:;
12537  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_rowptr), __pyx_ptype_5numpy_ndarray, 1, "rowptr", 0))) __PYX_ERR(0, 1233, __pyx_L1_error)
12538  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_colind), __pyx_ptype_5numpy_ndarray, 1, "colind", 0))) __PYX_ERR(0, 1234, __pyx_L1_error)
12539  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_diffusionTensor), __pyx_ptype_5numpy_ndarray, 1, "diffusionTensor", 0))) __PYX_ERR(0, 1235, __pyx_L1_error)
12540  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_grad_phi), __pyx_ptype_5numpy_ndarray, 1, "grad_phi", 0))) __PYX_ERR(0, 1236, __pyx_L1_error)
12541  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_velocity), __pyx_ptype_5numpy_ndarray, 1, "velocity", 0))) __PYX_ERR(0, 1237, __pyx_L1_error)
12542  __pyx_r = __pyx_pf_15cpostprocessing_100updateDiffusiveVelocityPointEval_sd(__pyx_self, __pyx_v_updateCoef, __pyx_v_rowptr, __pyx_v_colind, __pyx_v_diffusionTensor, __pyx_v_grad_phi, __pyx_v_velocity);
12543 
12544  /* function exit code */
12545  goto __pyx_L0;
12546  __pyx_L1_error:;
12547  __pyx_r = NULL;
12548  __pyx_L0:;
12549  __Pyx_RefNannyFinishContext();
12550  return __pyx_r;
12551 }
12552 
12553 static PyObject *__pyx_pf_15cpostprocessing_100updateDiffusiveVelocityPointEval_sd(CYTHON_UNUSED PyObject *__pyx_self, double __pyx_v_updateCoef, PyArrayObject *__pyx_v_rowptr, PyArrayObject *__pyx_v_colind, PyArrayObject *__pyx_v_diffusionTensor, PyArrayObject *__pyx_v_grad_phi, PyArrayObject *__pyx_v_velocity) {
12554  int __pyx_v_nPoints;
12555  PyObject *__pyx_r = NULL;
12556  __Pyx_RefNannyDeclarations
12557  PyObject *__pyx_t_1 = NULL;
12558  PyObject *__pyx_t_2 = NULL;
12559  PyObject *__pyx_t_3 = NULL;
12560  int __pyx_t_4;
12561  int __pyx_lineno = 0;
12562  const char *__pyx_filename = NULL;
12563  int __pyx_clineno = 0;
12564  __Pyx_RefNannySetupContext("updateDiffusiveVelocityPointEval_sd", 0);
12565 
12566  /* "cpostprocessing.pyx":1238
12567  * np.ndarray grad_phi,
12568  * np.ndarray velocity):
12569  * cdef int nPoints = velocity.size/velocity.shape[velocity.ndim-1] # <<<<<<<<<<<<<<
12570  * pp.postprocessDiffusiveVelocityPointEval_sd(nPoints,
12571  * velocity.shape[velocity.ndim-1],
12572  */
12573  __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_velocity), __pyx_n_s_size); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1238, __pyx_L1_error)
12574  __Pyx_GOTREF(__pyx_t_1);
12575  __pyx_t_2 = __Pyx_PyInt_From_Py_intptr_t((__pyx_v_velocity->dimensions[(__pyx_v_velocity->nd - 1)])); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1238, __pyx_L1_error)
12576  __Pyx_GOTREF(__pyx_t_2);
12577  __pyx_t_3 = __Pyx_PyNumber_Divide(__pyx_t_1, __pyx_t_2); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1238, __pyx_L1_error)
12578  __Pyx_GOTREF(__pyx_t_3);
12579  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
12580  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
12581  __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3); if (unlikely((__pyx_t_4 == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 1238, __pyx_L1_error)
12582  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
12583  __pyx_v_nPoints = __pyx_t_4;
12584 
12585  /* "cpostprocessing.pyx":1239
12586  * np.ndarray velocity):
12587  * cdef int nPoints = velocity.size/velocity.shape[velocity.ndim-1]
12588  * pp.postprocessDiffusiveVelocityPointEval_sd(nPoints, # <<<<<<<<<<<<<<
12589  * velocity.shape[velocity.ndim-1],
12590  * updateCoef,
12591  */
12592  postprocessDiffusiveVelocityPointEval_sd(__pyx_v_nPoints, (__pyx_v_velocity->dimensions[(__pyx_v_velocity->nd - 1)]), __pyx_v_updateCoef, ((int *)__pyx_v_rowptr->data), ((int *)__pyx_v_colind->data), ((double *)__pyx_v_diffusionTensor->data), ((double *)__pyx_v_grad_phi->data), ((double *)__pyx_v_velocity->data));
12593 
12594  /* "cpostprocessing.pyx":1232
12595  * <double*>(velocity.data))
12596  *
12597  * def updateDiffusiveVelocityPointEval_sd(double updateCoef, # <<<<<<<<<<<<<<
12598  * np.ndarray rowptr,
12599  * np.ndarray colind,
12600  */
12601 
12602  /* function exit code */
12603  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
12604  goto __pyx_L0;
12605  __pyx_L1_error:;
12606  __Pyx_XDECREF(__pyx_t_1);
12607  __Pyx_XDECREF(__pyx_t_2);
12608  __Pyx_XDECREF(__pyx_t_3);
12609  __Pyx_AddTraceback("cpostprocessing.updateDiffusiveVelocityPointEval_sd", __pyx_clineno, __pyx_lineno, __pyx_filename);
12610  __pyx_r = NULL;
12611  __pyx_L0:;
12612  __Pyx_XGIVEREF(__pyx_r);
12613  __Pyx_RefNannyFinishContext();
12614  return __pyx_r;
12615 }
12616 
12617 /* "cpostprocessing.pyx":1248
12618  * <double*>(velocity.data))
12619  *
12620  * def calculateElementResidualPWL(np.ndarray alpha, # <<<<<<<<<<<<<<
12621  * np.ndarray elementResidual,
12622  * np.ndarray elementResidualPWL):
12623  */
12624 
12625 /* Python wrapper */
12626 static PyObject *__pyx_pw_15cpostprocessing_103calculateElementResidualPWL(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
12627 static PyMethodDef __pyx_mdef_15cpostprocessing_103calculateElementResidualPWL = {"calculateElementResidualPWL", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_103calculateElementResidualPWL, METH_VARARGS|METH_KEYWORDS, 0};
12628 static PyObject *__pyx_pw_15cpostprocessing_103calculateElementResidualPWL(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
12629  PyArrayObject *__pyx_v_alpha = 0;
12630  PyArrayObject *__pyx_v_elementResidual = 0;
12631  PyArrayObject *__pyx_v_elementResidualPWL = 0;
12632  int __pyx_lineno = 0;
12633  const char *__pyx_filename = NULL;
12634  int __pyx_clineno = 0;
12635  PyObject *__pyx_r = 0;
12636  __Pyx_RefNannyDeclarations
12637  __Pyx_RefNannySetupContext("calculateElementResidualPWL (wrapper)", 0);
12638  {
12639  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_alpha,&__pyx_n_s_elementResidual,&__pyx_n_s_elementResidualPWL,0};
12640  PyObject* values[3] = {0,0,0};
12641  if (unlikely(__pyx_kwds)) {
12642  Py_ssize_t kw_args;
12643  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
12644  switch (pos_args) {
12645  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
12646  CYTHON_FALLTHROUGH;
12647  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
12648  CYTHON_FALLTHROUGH;
12649  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
12650  CYTHON_FALLTHROUGH;
12651  case 0: break;
12652  default: goto __pyx_L5_argtuple_error;
12653  }
12654  kw_args = PyDict_Size(__pyx_kwds);
12655  switch (pos_args) {
12656  case 0:
12657  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_alpha)) != 0)) kw_args--;
12658  else goto __pyx_L5_argtuple_error;
12659  CYTHON_FALLTHROUGH;
12660  case 1:
12661  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementResidual)) != 0)) kw_args--;
12662  else {
12663  __Pyx_RaiseArgtupleInvalid("calculateElementResidualPWL", 1, 3, 3, 1); __PYX_ERR(0, 1248, __pyx_L3_error)
12664  }
12665  CYTHON_FALLTHROUGH;
12666  case 2:
12667  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementResidualPWL)) != 0)) kw_args--;
12668  else {
12669  __Pyx_RaiseArgtupleInvalid("calculateElementResidualPWL", 1, 3, 3, 2); __PYX_ERR(0, 1248, __pyx_L3_error)
12670  }
12671  }
12672  if (unlikely(kw_args > 0)) {
12673  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "calculateElementResidualPWL") < 0)) __PYX_ERR(0, 1248, __pyx_L3_error)
12674  }
12675  } else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
12676  goto __pyx_L5_argtuple_error;
12677  } else {
12678  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
12679  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
12680  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
12681  }
12682  __pyx_v_alpha = ((PyArrayObject *)values[0]);
12683  __pyx_v_elementResidual = ((PyArrayObject *)values[1]);
12684  __pyx_v_elementResidualPWL = ((PyArrayObject *)values[2]);
12685  }
12686  goto __pyx_L4_argument_unpacking_done;
12687  __pyx_L5_argtuple_error:;
12688  __Pyx_RaiseArgtupleInvalid("calculateElementResidualPWL", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 1248, __pyx_L3_error)
12689  __pyx_L3_error:;
12690  __Pyx_AddTraceback("cpostprocessing.calculateElementResidualPWL", __pyx_clineno, __pyx_lineno, __pyx_filename);
12691  __Pyx_RefNannyFinishContext();
12692  return NULL;
12693  __pyx_L4_argument_unpacking_done:;
12694  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_alpha), __pyx_ptype_5numpy_ndarray, 1, "alpha", 0))) __PYX_ERR(0, 1248, __pyx_L1_error)
12695  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementResidual), __pyx_ptype_5numpy_ndarray, 1, "elementResidual", 0))) __PYX_ERR(0, 1249, __pyx_L1_error)
12696  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementResidualPWL), __pyx_ptype_5numpy_ndarray, 1, "elementResidualPWL", 0))) __PYX_ERR(0, 1250, __pyx_L1_error)
12697  __pyx_r = __pyx_pf_15cpostprocessing_102calculateElementResidualPWL(__pyx_self, __pyx_v_alpha, __pyx_v_elementResidual, __pyx_v_elementResidualPWL);
12698 
12699  /* function exit code */
12700  goto __pyx_L0;
12701  __pyx_L1_error:;
12702  __pyx_r = NULL;
12703  __pyx_L0:;
12704  __Pyx_RefNannyFinishContext();
12705  return __pyx_r;
12706 }
12707 
12708 static PyObject *__pyx_pf_15cpostprocessing_102calculateElementResidualPWL(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_alpha, PyArrayObject *__pyx_v_elementResidual, PyArrayObject *__pyx_v_elementResidualPWL) {
12709  PyObject *__pyx_r = NULL;
12710  __Pyx_RefNannyDeclarations
12711  __Pyx_RefNannySetupContext("calculateElementResidualPWL", 0);
12712 
12713  /* "cpostprocessing.pyx":1251
12714  * np.ndarray elementResidual,
12715  * np.ndarray elementResidualPWL):
12716  * pp.calculateElementResidualPWL(elementResidual.shape[0], # <<<<<<<<<<<<<<
12717  * elementResidual.shape[1],
12718  * elementResidualPWL.shape[1],
12719  */
12720  calculateElementResidualPWL((__pyx_v_elementResidual->dimensions[0]), (__pyx_v_elementResidual->dimensions[1]), (__pyx_v_elementResidualPWL->dimensions[1]), ((double *)__pyx_v_alpha->data), ((double *)__pyx_v_elementResidual->data), ((double *)__pyx_v_elementResidualPWL->data));
12721 
12722  /* "cpostprocessing.pyx":1248
12723  * <double*>(velocity.data))
12724  *
12725  * def calculateElementResidualPWL(np.ndarray alpha, # <<<<<<<<<<<<<<
12726  * np.ndarray elementResidual,
12727  * np.ndarray elementResidualPWL):
12728  */
12729 
12730  /* function exit code */
12731  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
12732  __Pyx_XGIVEREF(__pyx_r);
12733  __Pyx_RefNannyFinishContext();
12734  return __pyx_r;
12735 }
12736 
12737 /* "cpostprocessing.pyx":1258
12738  * <double*>(elementResidualPWL.data))
12739  *
12740  * def copyElementBoundaryVelocityToParVec(np.ndarray ebq_velocity, # <<<<<<<<<<<<<<
12741  * np.ndarray[int, ndim=2] permutations,
12742  * np.ndarray ebq_v_par_local):
12743  */
12744 
12745 /* Python wrapper */
12746 static PyObject *__pyx_pw_15cpostprocessing_105copyElementBoundaryVelocityToParVec(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
12747 static PyMethodDef __pyx_mdef_15cpostprocessing_105copyElementBoundaryVelocityToParVec = {"copyElementBoundaryVelocityToParVec", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_105copyElementBoundaryVelocityToParVec, METH_VARARGS|METH_KEYWORDS, 0};
12748 static PyObject *__pyx_pw_15cpostprocessing_105copyElementBoundaryVelocityToParVec(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
12749  PyArrayObject *__pyx_v_ebq_velocity = 0;
12750  PyArrayObject *__pyx_v_permutations = 0;
12751  PyArrayObject *__pyx_v_ebq_v_par_local = 0;
12752  int __pyx_lineno = 0;
12753  const char *__pyx_filename = NULL;
12754  int __pyx_clineno = 0;
12755  PyObject *__pyx_r = 0;
12756  __Pyx_RefNannyDeclarations
12757  __Pyx_RefNannySetupContext("copyElementBoundaryVelocityToParVec (wrapper)", 0);
12758  {
12759  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_ebq_velocity,&__pyx_n_s_permutations,&__pyx_n_s_ebq_v_par_local,0};
12760  PyObject* values[3] = {0,0,0};
12761  if (unlikely(__pyx_kwds)) {
12762  Py_ssize_t kw_args;
12763  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
12764  switch (pos_args) {
12765  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
12766  CYTHON_FALLTHROUGH;
12767  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
12768  CYTHON_FALLTHROUGH;
12769  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
12770  CYTHON_FALLTHROUGH;
12771  case 0: break;
12772  default: goto __pyx_L5_argtuple_error;
12773  }
12774  kw_args = PyDict_Size(__pyx_kwds);
12775  switch (pos_args) {
12776  case 0:
12777  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ebq_velocity)) != 0)) kw_args--;
12778  else goto __pyx_L5_argtuple_error;
12779  CYTHON_FALLTHROUGH;
12780  case 1:
12781  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_permutations)) != 0)) kw_args--;
12782  else {
12783  __Pyx_RaiseArgtupleInvalid("copyElementBoundaryVelocityToParVec", 1, 3, 3, 1); __PYX_ERR(0, 1258, __pyx_L3_error)
12784  }
12785  CYTHON_FALLTHROUGH;
12786  case 2:
12787  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ebq_v_par_local)) != 0)) kw_args--;
12788  else {
12789  __Pyx_RaiseArgtupleInvalid("copyElementBoundaryVelocityToParVec", 1, 3, 3, 2); __PYX_ERR(0, 1258, __pyx_L3_error)
12790  }
12791  }
12792  if (unlikely(kw_args > 0)) {
12793  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "copyElementBoundaryVelocityToParVec") < 0)) __PYX_ERR(0, 1258, __pyx_L3_error)
12794  }
12795  } else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
12796  goto __pyx_L5_argtuple_error;
12797  } else {
12798  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
12799  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
12800  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
12801  }
12802  __pyx_v_ebq_velocity = ((PyArrayObject *)values[0]);
12803  __pyx_v_permutations = ((PyArrayObject *)values[1]);
12804  __pyx_v_ebq_v_par_local = ((PyArrayObject *)values[2]);
12805  }
12806  goto __pyx_L4_argument_unpacking_done;
12807  __pyx_L5_argtuple_error:;
12808  __Pyx_RaiseArgtupleInvalid("copyElementBoundaryVelocityToParVec", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 1258, __pyx_L3_error)
12809  __pyx_L3_error:;
12810  __Pyx_AddTraceback("cpostprocessing.copyElementBoundaryVelocityToParVec", __pyx_clineno, __pyx_lineno, __pyx_filename);
12811  __Pyx_RefNannyFinishContext();
12812  return NULL;
12813  __pyx_L4_argument_unpacking_done:;
12814  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ebq_velocity), __pyx_ptype_5numpy_ndarray, 1, "ebq_velocity", 0))) __PYX_ERR(0, 1258, __pyx_L1_error)
12815  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_permutations), __pyx_ptype_5numpy_ndarray, 1, "permutations", 0))) __PYX_ERR(0, 1259, __pyx_L1_error)
12816  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ebq_v_par_local), __pyx_ptype_5numpy_ndarray, 1, "ebq_v_par_local", 0))) __PYX_ERR(0, 1260, __pyx_L1_error)
12817  __pyx_r = __pyx_pf_15cpostprocessing_104copyElementBoundaryVelocityToParVec(__pyx_self, __pyx_v_ebq_velocity, __pyx_v_permutations, __pyx_v_ebq_v_par_local);
12818 
12819  /* function exit code */
12820  goto __pyx_L0;
12821  __pyx_L1_error:;
12822  __pyx_r = NULL;
12823  __pyx_L0:;
12824  __Pyx_RefNannyFinishContext();
12825  return __pyx_r;
12826 }
12827 
12828 static PyObject *__pyx_pf_15cpostprocessing_104copyElementBoundaryVelocityToParVec(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_ebq_velocity, PyArrayObject *__pyx_v_permutations, PyArrayObject *__pyx_v_ebq_v_par_local) {
12829  int __pyx_v_ebN;
12830  int __pyx_v_k;
12831  int __pyx_v_I;
12832  int __pyx_v_nElementBoundaries;
12833  int __pyx_v_nQuadraturePoints;
12834  int __pyx_v_nSpace;
12835  __Pyx_LocalBuf_ND __pyx_pybuffernd_permutations;
12836  __Pyx_Buffer __pyx_pybuffer_permutations;
12837  PyObject *__pyx_r = NULL;
12838  __Pyx_RefNannyDeclarations
12839  int __pyx_t_1;
12840  int __pyx_t_2;
12841  int __pyx_t_3;
12842  int __pyx_t_4;
12843  int __pyx_t_5;
12844  int __pyx_t_6;
12845  int __pyx_t_7;
12846  int __pyx_t_8;
12847  int __pyx_t_9;
12848  PyObject *__pyx_t_10 = NULL;
12849  PyObject *__pyx_t_11 = NULL;
12850  PyObject *__pyx_t_12 = NULL;
12851  PyObject *__pyx_t_13 = NULL;
12852  Py_ssize_t __pyx_t_14;
12853  Py_ssize_t __pyx_t_15;
12854  int __pyx_t_16;
12855  PyObject *__pyx_t_17 = NULL;
12856  int __pyx_lineno = 0;
12857  const char *__pyx_filename = NULL;
12858  int __pyx_clineno = 0;
12859  __Pyx_RefNannySetupContext("copyElementBoundaryVelocityToParVec", 0);
12860  __pyx_pybuffer_permutations.pybuffer.buf = NULL;
12861  __pyx_pybuffer_permutations.refcount = 0;
12862  __pyx_pybuffernd_permutations.data = NULL;
12863  __pyx_pybuffernd_permutations.rcbuffer = &__pyx_pybuffer_permutations;
12864  {
12865  __Pyx_BufFmt_StackElem __pyx_stack[1];
12866  if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_permutations.rcbuffer->pybuffer, (PyObject*)__pyx_v_permutations, &__Pyx_TypeInfo_int, PyBUF_FORMAT| PyBUF_STRIDES, 2, 0, __pyx_stack) == -1)) __PYX_ERR(0, 1258, __pyx_L1_error)
12867  }
12868  __pyx_pybuffernd_permutations.diminfo[0].strides = __pyx_pybuffernd_permutations.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_permutations.diminfo[0].shape = __pyx_pybuffernd_permutations.rcbuffer->pybuffer.shape[0]; __pyx_pybuffernd_permutations.diminfo[1].strides = __pyx_pybuffernd_permutations.rcbuffer->pybuffer.strides[1]; __pyx_pybuffernd_permutations.diminfo[1].shape = __pyx_pybuffernd_permutations.rcbuffer->pybuffer.shape[1];
12869 
12870  /* "cpostprocessing.pyx":1264
12871  * cdef int k
12872  * cdef int I
12873  * cdef int nElementBoundaries=ebq_v_par_local.shape[0] # <<<<<<<<<<<<<<
12874  * cdef int nQuadraturePoints=ebq_v_par_local.shape[1]
12875  * cdef int nSpace=ebq_v_par_local.shape[2]
12876  */
12877  __pyx_v_nElementBoundaries = (__pyx_v_ebq_v_par_local->dimensions[0]);
12878 
12879  /* "cpostprocessing.pyx":1265
12880  * cdef int I
12881  * cdef int nElementBoundaries=ebq_v_par_local.shape[0]
12882  * cdef int nQuadraturePoints=ebq_v_par_local.shape[1] # <<<<<<<<<<<<<<
12883  * cdef int nSpace=ebq_v_par_local.shape[2]
12884  * for ebN in range(nElementBoundaries):
12885  */
12886  __pyx_v_nQuadraturePoints = (__pyx_v_ebq_v_par_local->dimensions[1]);
12887 
12888  /* "cpostprocessing.pyx":1266
12889  * cdef int nElementBoundaries=ebq_v_par_local.shape[0]
12890  * cdef int nQuadraturePoints=ebq_v_par_local.shape[1]
12891  * cdef int nSpace=ebq_v_par_local.shape[2] # <<<<<<<<<<<<<<
12892  * for ebN in range(nElementBoundaries):
12893  * for k in range(nQuadraturePoints):
12894  */
12895  __pyx_v_nSpace = (__pyx_v_ebq_v_par_local->dimensions[2]);
12896 
12897  /* "cpostprocessing.pyx":1267
12898  * cdef int nQuadraturePoints=ebq_v_par_local.shape[1]
12899  * cdef int nSpace=ebq_v_par_local.shape[2]
12900  * for ebN in range(nElementBoundaries): # <<<<<<<<<<<<<<
12901  * for k in range(nQuadraturePoints):
12902  * for I in range(nSpace):
12903  */
12904  __pyx_t_1 = __pyx_v_nElementBoundaries;
12905  __pyx_t_2 = __pyx_t_1;
12906  for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
12907  __pyx_v_ebN = __pyx_t_3;
12908 
12909  /* "cpostprocessing.pyx":1268
12910  * cdef int nSpace=ebq_v_par_local.shape[2]
12911  * for ebN in range(nElementBoundaries):
12912  * for k in range(nQuadraturePoints): # <<<<<<<<<<<<<<
12913  * for I in range(nSpace):
12914  * ebq_v_par_local[ebN,permutations[ebN,k],I] = ebq_velocity[ebN,k,I]
12915  */
12916  __pyx_t_4 = __pyx_v_nQuadraturePoints;
12917  __pyx_t_5 = __pyx_t_4;
12918  for (__pyx_t_6 = 0; __pyx_t_6 < __pyx_t_5; __pyx_t_6+=1) {
12919  __pyx_v_k = __pyx_t_6;
12920 
12921  /* "cpostprocessing.pyx":1269
12922  * for ebN in range(nElementBoundaries):
12923  * for k in range(nQuadraturePoints):
12924  * for I in range(nSpace): # <<<<<<<<<<<<<<
12925  * ebq_v_par_local[ebN,permutations[ebN,k],I] = ebq_velocity[ebN,k,I]
12926  *
12927  */
12928  __pyx_t_7 = __pyx_v_nSpace;
12929  __pyx_t_8 = __pyx_t_7;
12930  for (__pyx_t_9 = 0; __pyx_t_9 < __pyx_t_8; __pyx_t_9+=1) {
12931  __pyx_v_I = __pyx_t_9;
12932 
12933  /* "cpostprocessing.pyx":1270
12934  * for k in range(nQuadraturePoints):
12935  * for I in range(nSpace):
12936  * ebq_v_par_local[ebN,permutations[ebN,k],I] = ebq_velocity[ebN,k,I] # <<<<<<<<<<<<<<
12937  *
12938  * def addAverageToParVec(np.ndarray ebq_velocityAverage,
12939  */
12940  __pyx_t_10 = __Pyx_PyInt_From_int(__pyx_v_ebN); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 1270, __pyx_L1_error)
12941  __Pyx_GOTREF(__pyx_t_10);
12942  __pyx_t_11 = __Pyx_PyInt_From_int(__pyx_v_k); if (unlikely(!__pyx_t_11)) __PYX_ERR(0, 1270, __pyx_L1_error)
12943  __Pyx_GOTREF(__pyx_t_11);
12944  __pyx_t_12 = __Pyx_PyInt_From_int(__pyx_v_I); if (unlikely(!__pyx_t_12)) __PYX_ERR(0, 1270, __pyx_L1_error)
12945  __Pyx_GOTREF(__pyx_t_12);
12946  __pyx_t_13 = PyTuple_New(3); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 1270, __pyx_L1_error)
12947  __Pyx_GOTREF(__pyx_t_13);
12948  __Pyx_GIVEREF(__pyx_t_10);
12949  PyTuple_SET_ITEM(__pyx_t_13, 0, __pyx_t_10);
12950  __Pyx_GIVEREF(__pyx_t_11);
12951  PyTuple_SET_ITEM(__pyx_t_13, 1, __pyx_t_11);
12952  __Pyx_GIVEREF(__pyx_t_12);
12953  PyTuple_SET_ITEM(__pyx_t_13, 2, __pyx_t_12);
12954  __pyx_t_10 = 0;
12955  __pyx_t_11 = 0;
12956  __pyx_t_12 = 0;
12957  __pyx_t_12 = __Pyx_PyObject_GetItem(((PyObject *)__pyx_v_ebq_velocity), __pyx_t_13); if (unlikely(!__pyx_t_12)) __PYX_ERR(0, 1270, __pyx_L1_error)
12958  __Pyx_GOTREF(__pyx_t_12);
12959  __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
12960  __pyx_t_13 = __Pyx_PyInt_From_int(__pyx_v_ebN); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 1270, __pyx_L1_error)
12961  __Pyx_GOTREF(__pyx_t_13);
12962  __pyx_t_14 = __pyx_v_ebN;
12963  __pyx_t_15 = __pyx_v_k;
12964  __pyx_t_16 = -1;
12965  if (__pyx_t_14 < 0) {
12966  __pyx_t_14 += __pyx_pybuffernd_permutations.diminfo[0].shape;
12967  if (unlikely(__pyx_t_14 < 0)) __pyx_t_16 = 0;
12968  } else if (unlikely(__pyx_t_14 >= __pyx_pybuffernd_permutations.diminfo[0].shape)) __pyx_t_16 = 0;
12969  if (__pyx_t_15 < 0) {
12970  __pyx_t_15 += __pyx_pybuffernd_permutations.diminfo[1].shape;
12971  if (unlikely(__pyx_t_15 < 0)) __pyx_t_16 = 1;
12972  } else if (unlikely(__pyx_t_15 >= __pyx_pybuffernd_permutations.diminfo[1].shape)) __pyx_t_16 = 1;
12973  if (unlikely(__pyx_t_16 != -1)) {
12974  __Pyx_RaiseBufferIndexError(__pyx_t_16);
12975  __PYX_ERR(0, 1270, __pyx_L1_error)
12976  }
12977  __pyx_t_11 = __Pyx_PyInt_From_int((*__Pyx_BufPtrStrided2d(int *, __pyx_pybuffernd_permutations.rcbuffer->pybuffer.buf, __pyx_t_14, __pyx_pybuffernd_permutations.diminfo[0].strides, __pyx_t_15, __pyx_pybuffernd_permutations.diminfo[1].strides))); if (unlikely(!__pyx_t_11)) __PYX_ERR(0, 1270, __pyx_L1_error)
12978  __Pyx_GOTREF(__pyx_t_11);
12979  __pyx_t_10 = __Pyx_PyInt_From_int(__pyx_v_I); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 1270, __pyx_L1_error)
12980  __Pyx_GOTREF(__pyx_t_10);
12981  __pyx_t_17 = PyTuple_New(3); if (unlikely(!__pyx_t_17)) __PYX_ERR(0, 1270, __pyx_L1_error)
12982  __Pyx_GOTREF(__pyx_t_17);
12983  __Pyx_GIVEREF(__pyx_t_13);
12984  PyTuple_SET_ITEM(__pyx_t_17, 0, __pyx_t_13);
12985  __Pyx_GIVEREF(__pyx_t_11);
12986  PyTuple_SET_ITEM(__pyx_t_17, 1, __pyx_t_11);
12987  __Pyx_GIVEREF(__pyx_t_10);
12988  PyTuple_SET_ITEM(__pyx_t_17, 2, __pyx_t_10);
12989  __pyx_t_13 = 0;
12990  __pyx_t_11 = 0;
12991  __pyx_t_10 = 0;
12992  if (unlikely(PyObject_SetItem(((PyObject *)__pyx_v_ebq_v_par_local), __pyx_t_17, __pyx_t_12) < 0)) __PYX_ERR(0, 1270, __pyx_L1_error)
12993  __Pyx_DECREF(__pyx_t_17); __pyx_t_17 = 0;
12994  __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0;
12995  }
12996  }
12997  }
12998 
12999  /* "cpostprocessing.pyx":1258
13000  * <double*>(elementResidualPWL.data))
13001  *
13002  * def copyElementBoundaryVelocityToParVec(np.ndarray ebq_velocity, # <<<<<<<<<<<<<<
13003  * np.ndarray[int, ndim=2] permutations,
13004  * np.ndarray ebq_v_par_local):
13005  */
13006 
13007  /* function exit code */
13008  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
13009  goto __pyx_L0;
13010  __pyx_L1_error:;
13011  __Pyx_XDECREF(__pyx_t_10);
13012  __Pyx_XDECREF(__pyx_t_11);
13013  __Pyx_XDECREF(__pyx_t_12);
13014  __Pyx_XDECREF(__pyx_t_13);
13015  __Pyx_XDECREF(__pyx_t_17);
13016  { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
13017  __Pyx_PyThreadState_declare
13018  __Pyx_PyThreadState_assign
13019  __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
13020  __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_permutations.rcbuffer->pybuffer);
13021  __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
13022  __Pyx_AddTraceback("cpostprocessing.copyElementBoundaryVelocityToParVec", __pyx_clineno, __pyx_lineno, __pyx_filename);
13023  __pyx_r = NULL;
13024  goto __pyx_L2;
13025  __pyx_L0:;
13026  __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_permutations.rcbuffer->pybuffer);
13027  __pyx_L2:;
13028  __Pyx_XGIVEREF(__pyx_r);
13029  __Pyx_RefNannyFinishContext();
13030  return __pyx_r;
13031 }
13032 
13033 /* "cpostprocessing.pyx":1272
13034  * ebq_v_par_local[ebN,permutations[ebN,k],I] = ebq_velocity[ebN,k,I]
13035  *
13036  * def addAverageToParVec(np.ndarray ebq_velocityAverage, # <<<<<<<<<<<<<<
13037  * np.ndarray[int, ndim=2] permutations,
13038  * np.ndarray ebq_v_par_local):
13039  */
13040 
13041 /* Python wrapper */
13042 static PyObject *__pyx_pw_15cpostprocessing_107addAverageToParVec(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
13043 static PyMethodDef __pyx_mdef_15cpostprocessing_107addAverageToParVec = {"addAverageToParVec", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_107addAverageToParVec, METH_VARARGS|METH_KEYWORDS, 0};
13044 static PyObject *__pyx_pw_15cpostprocessing_107addAverageToParVec(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
13045  PyArrayObject *__pyx_v_ebq_velocityAverage = 0;
13046  PyArrayObject *__pyx_v_permutations = 0;
13047  PyArrayObject *__pyx_v_ebq_v_par_local = 0;
13048  int __pyx_lineno = 0;
13049  const char *__pyx_filename = NULL;
13050  int __pyx_clineno = 0;
13051  PyObject *__pyx_r = 0;
13052  __Pyx_RefNannyDeclarations
13053  __Pyx_RefNannySetupContext("addAverageToParVec (wrapper)", 0);
13054  {
13055  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_ebq_velocityAverage,&__pyx_n_s_permutations,&__pyx_n_s_ebq_v_par_local,0};
13056  PyObject* values[3] = {0,0,0};
13057  if (unlikely(__pyx_kwds)) {
13058  Py_ssize_t kw_args;
13059  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
13060  switch (pos_args) {
13061  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
13062  CYTHON_FALLTHROUGH;
13063  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
13064  CYTHON_FALLTHROUGH;
13065  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
13066  CYTHON_FALLTHROUGH;
13067  case 0: break;
13068  default: goto __pyx_L5_argtuple_error;
13069  }
13070  kw_args = PyDict_Size(__pyx_kwds);
13071  switch (pos_args) {
13072  case 0:
13073  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ebq_velocityAverage)) != 0)) kw_args--;
13074  else goto __pyx_L5_argtuple_error;
13075  CYTHON_FALLTHROUGH;
13076  case 1:
13077  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_permutations)) != 0)) kw_args--;
13078  else {
13079  __Pyx_RaiseArgtupleInvalid("addAverageToParVec", 1, 3, 3, 1); __PYX_ERR(0, 1272, __pyx_L3_error)
13080  }
13081  CYTHON_FALLTHROUGH;
13082  case 2:
13083  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ebq_v_par_local)) != 0)) kw_args--;
13084  else {
13085  __Pyx_RaiseArgtupleInvalid("addAverageToParVec", 1, 3, 3, 2); __PYX_ERR(0, 1272, __pyx_L3_error)
13086  }
13087  }
13088  if (unlikely(kw_args > 0)) {
13089  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "addAverageToParVec") < 0)) __PYX_ERR(0, 1272, __pyx_L3_error)
13090  }
13091  } else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
13092  goto __pyx_L5_argtuple_error;
13093  } else {
13094  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
13095  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
13096  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
13097  }
13098  __pyx_v_ebq_velocityAverage = ((PyArrayObject *)values[0]);
13099  __pyx_v_permutations = ((PyArrayObject *)values[1]);
13100  __pyx_v_ebq_v_par_local = ((PyArrayObject *)values[2]);
13101  }
13102  goto __pyx_L4_argument_unpacking_done;
13103  __pyx_L5_argtuple_error:;
13104  __Pyx_RaiseArgtupleInvalid("addAverageToParVec", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 1272, __pyx_L3_error)
13105  __pyx_L3_error:;
13106  __Pyx_AddTraceback("cpostprocessing.addAverageToParVec", __pyx_clineno, __pyx_lineno, __pyx_filename);
13107  __Pyx_RefNannyFinishContext();
13108  return NULL;
13109  __pyx_L4_argument_unpacking_done:;
13110  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ebq_velocityAverage), __pyx_ptype_5numpy_ndarray, 1, "ebq_velocityAverage", 0))) __PYX_ERR(0, 1272, __pyx_L1_error)
13111  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_permutations), __pyx_ptype_5numpy_ndarray, 1, "permutations", 0))) __PYX_ERR(0, 1273, __pyx_L1_error)
13112  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ebq_v_par_local), __pyx_ptype_5numpy_ndarray, 1, "ebq_v_par_local", 0))) __PYX_ERR(0, 1274, __pyx_L1_error)
13113  __pyx_r = __pyx_pf_15cpostprocessing_106addAverageToParVec(__pyx_self, __pyx_v_ebq_velocityAverage, __pyx_v_permutations, __pyx_v_ebq_v_par_local);
13114 
13115  /* function exit code */
13116  goto __pyx_L0;
13117  __pyx_L1_error:;
13118  __pyx_r = NULL;
13119  __pyx_L0:;
13120  __Pyx_RefNannyFinishContext();
13121  return __pyx_r;
13122 }
13123 
13124 static PyObject *__pyx_pf_15cpostprocessing_106addAverageToParVec(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_ebq_velocityAverage, PyArrayObject *__pyx_v_permutations, PyArrayObject *__pyx_v_ebq_v_par_local) {
13125  int __pyx_v_ebN;
13126  int __pyx_v_k;
13127  int __pyx_v_I;
13128  int __pyx_v_nElementBoundaries;
13129  int __pyx_v_nQuadraturePoints;
13130  int __pyx_v_nSpace;
13131  __Pyx_LocalBuf_ND __pyx_pybuffernd_permutations;
13132  __Pyx_Buffer __pyx_pybuffer_permutations;
13133  PyObject *__pyx_r = NULL;
13134  __Pyx_RefNannyDeclarations
13135  int __pyx_t_1;
13136  int __pyx_t_2;
13137  int __pyx_t_3;
13138  int __pyx_t_4;
13139  int __pyx_t_5;
13140  int __pyx_t_6;
13141  int __pyx_t_7;
13142  int __pyx_t_8;
13143  int __pyx_t_9;
13144  PyObject *__pyx_t_10 = NULL;
13145  Py_ssize_t __pyx_t_11;
13146  Py_ssize_t __pyx_t_12;
13147  int __pyx_t_13;
13148  PyObject *__pyx_t_14 = NULL;
13149  PyObject *__pyx_t_15 = NULL;
13150  PyObject *__pyx_t_16 = NULL;
13151  PyObject *__pyx_t_17 = NULL;
13152  PyObject *__pyx_t_18 = NULL;
13153  int __pyx_lineno = 0;
13154  const char *__pyx_filename = NULL;
13155  int __pyx_clineno = 0;
13156  __Pyx_RefNannySetupContext("addAverageToParVec", 0);
13157  __pyx_pybuffer_permutations.pybuffer.buf = NULL;
13158  __pyx_pybuffer_permutations.refcount = 0;
13159  __pyx_pybuffernd_permutations.data = NULL;
13160  __pyx_pybuffernd_permutations.rcbuffer = &__pyx_pybuffer_permutations;
13161  {
13162  __Pyx_BufFmt_StackElem __pyx_stack[1];
13163  if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_permutations.rcbuffer->pybuffer, (PyObject*)__pyx_v_permutations, &__Pyx_TypeInfo_int, PyBUF_FORMAT| PyBUF_STRIDES, 2, 0, __pyx_stack) == -1)) __PYX_ERR(0, 1272, __pyx_L1_error)
13164  }
13165  __pyx_pybuffernd_permutations.diminfo[0].strides = __pyx_pybuffernd_permutations.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_permutations.diminfo[0].shape = __pyx_pybuffernd_permutations.rcbuffer->pybuffer.shape[0]; __pyx_pybuffernd_permutations.diminfo[1].strides = __pyx_pybuffernd_permutations.rcbuffer->pybuffer.strides[1]; __pyx_pybuffernd_permutations.diminfo[1].shape = __pyx_pybuffernd_permutations.rcbuffer->pybuffer.shape[1];
13166 
13167  /* "cpostprocessing.pyx":1278
13168  * cdef int k
13169  * cdef int I
13170  * cdef int nElementBoundaries=ebq_v_par_local.shape[0] # <<<<<<<<<<<<<<
13171  * cdef int nQuadraturePoints=ebq_v_par_local.shape[1]
13172  * cdef int nSpace=ebq_v_par_local.shape[2]
13173  */
13174  __pyx_v_nElementBoundaries = (__pyx_v_ebq_v_par_local->dimensions[0]);
13175 
13176  /* "cpostprocessing.pyx":1279
13177  * cdef int I
13178  * cdef int nElementBoundaries=ebq_v_par_local.shape[0]
13179  * cdef int nQuadraturePoints=ebq_v_par_local.shape[1] # <<<<<<<<<<<<<<
13180  * cdef int nSpace=ebq_v_par_local.shape[2]
13181  * for ebN in range(nElementBoundaries):
13182  */
13183  __pyx_v_nQuadraturePoints = (__pyx_v_ebq_v_par_local->dimensions[1]);
13184 
13185  /* "cpostprocessing.pyx":1280
13186  * cdef int nElementBoundaries=ebq_v_par_local.shape[0]
13187  * cdef int nQuadraturePoints=ebq_v_par_local.shape[1]
13188  * cdef int nSpace=ebq_v_par_local.shape[2] # <<<<<<<<<<<<<<
13189  * for ebN in range(nElementBoundaries):
13190  * for k in range(nQuadraturePoints):
13191  */
13192  __pyx_v_nSpace = (__pyx_v_ebq_v_par_local->dimensions[2]);
13193 
13194  /* "cpostprocessing.pyx":1281
13195  * cdef int nQuadraturePoints=ebq_v_par_local.shape[1]
13196  * cdef int nSpace=ebq_v_par_local.shape[2]
13197  * for ebN in range(nElementBoundaries): # <<<<<<<<<<<<<<
13198  * for k in range(nQuadraturePoints):
13199  * for I in range(nSpace):
13200  */
13201  __pyx_t_1 = __pyx_v_nElementBoundaries;
13202  __pyx_t_2 = __pyx_t_1;
13203  for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
13204  __pyx_v_ebN = __pyx_t_3;
13205 
13206  /* "cpostprocessing.pyx":1282
13207  * cdef int nSpace=ebq_v_par_local.shape[2]
13208  * for ebN in range(nElementBoundaries):
13209  * for k in range(nQuadraturePoints): # <<<<<<<<<<<<<<
13210  * for I in range(nSpace):
13211  * ebq_v_par_local[ebN, permutations[ebN,k], I] += ebq_velocityAverage[ebN, k, I]
13212  */
13213  __pyx_t_4 = __pyx_v_nQuadraturePoints;
13214  __pyx_t_5 = __pyx_t_4;
13215  for (__pyx_t_6 = 0; __pyx_t_6 < __pyx_t_5; __pyx_t_6+=1) {
13216  __pyx_v_k = __pyx_t_6;
13217 
13218  /* "cpostprocessing.pyx":1283
13219  * for ebN in range(nElementBoundaries):
13220  * for k in range(nQuadraturePoints):
13221  * for I in range(nSpace): # <<<<<<<<<<<<<<
13222  * ebq_v_par_local[ebN, permutations[ebN,k], I] += ebq_velocityAverage[ebN, k, I]
13223  *
13224  */
13225  __pyx_t_7 = __pyx_v_nSpace;
13226  __pyx_t_8 = __pyx_t_7;
13227  for (__pyx_t_9 = 0; __pyx_t_9 < __pyx_t_8; __pyx_t_9+=1) {
13228  __pyx_v_I = __pyx_t_9;
13229 
13230  /* "cpostprocessing.pyx":1284
13231  * for k in range(nQuadraturePoints):
13232  * for I in range(nSpace):
13233  * ebq_v_par_local[ebN, permutations[ebN,k], I] += ebq_velocityAverage[ebN, k, I] # <<<<<<<<<<<<<<
13234  *
13235  * def copyParVecToElementBoundaryVelocity(np.ndarray ebq_velocity,
13236  */
13237  __pyx_t_10 = __Pyx_PyInt_From_int(__pyx_v_ebN); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 1284, __pyx_L1_error)
13238  __Pyx_GOTREF(__pyx_t_10);
13239  __pyx_t_11 = __pyx_v_ebN;
13240  __pyx_t_12 = __pyx_v_k;
13241  __pyx_t_13 = -1;
13242  if (__pyx_t_11 < 0) {
13243  __pyx_t_11 += __pyx_pybuffernd_permutations.diminfo[0].shape;
13244  if (unlikely(__pyx_t_11 < 0)) __pyx_t_13 = 0;
13245  } else if (unlikely(__pyx_t_11 >= __pyx_pybuffernd_permutations.diminfo[0].shape)) __pyx_t_13 = 0;
13246  if (__pyx_t_12 < 0) {
13247  __pyx_t_12 += __pyx_pybuffernd_permutations.diminfo[1].shape;
13248  if (unlikely(__pyx_t_12 < 0)) __pyx_t_13 = 1;
13249  } else if (unlikely(__pyx_t_12 >= __pyx_pybuffernd_permutations.diminfo[1].shape)) __pyx_t_13 = 1;
13250  if (unlikely(__pyx_t_13 != -1)) {
13251  __Pyx_RaiseBufferIndexError(__pyx_t_13);
13252  __PYX_ERR(0, 1284, __pyx_L1_error)
13253  }
13254  __pyx_t_14 = __Pyx_PyInt_From_int((*__Pyx_BufPtrStrided2d(int *, __pyx_pybuffernd_permutations.rcbuffer->pybuffer.buf, __pyx_t_11, __pyx_pybuffernd_permutations.diminfo[0].strides, __pyx_t_12, __pyx_pybuffernd_permutations.diminfo[1].strides))); if (unlikely(!__pyx_t_14)) __PYX_ERR(0, 1284, __pyx_L1_error)
13255  __Pyx_GOTREF(__pyx_t_14);
13256  __pyx_t_15 = __Pyx_PyInt_From_int(__pyx_v_I); if (unlikely(!__pyx_t_15)) __PYX_ERR(0, 1284, __pyx_L1_error)
13257  __Pyx_GOTREF(__pyx_t_15);
13258  __pyx_t_16 = PyTuple_New(3); if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 1284, __pyx_L1_error)
13259  __Pyx_GOTREF(__pyx_t_16);
13260  __Pyx_GIVEREF(__pyx_t_10);
13261  PyTuple_SET_ITEM(__pyx_t_16, 0, __pyx_t_10);
13262  __Pyx_GIVEREF(__pyx_t_14);
13263  PyTuple_SET_ITEM(__pyx_t_16, 1, __pyx_t_14);
13264  __Pyx_GIVEREF(__pyx_t_15);
13265  PyTuple_SET_ITEM(__pyx_t_16, 2, __pyx_t_15);
13266  __pyx_t_10 = 0;
13267  __pyx_t_14 = 0;
13268  __pyx_t_15 = 0;
13269  __pyx_t_15 = __Pyx_PyObject_GetItem(((PyObject *)__pyx_v_ebq_v_par_local), __pyx_t_16); if (unlikely(!__pyx_t_15)) __PYX_ERR(0, 1284, __pyx_L1_error)
13270  __Pyx_GOTREF(__pyx_t_15);
13271  __pyx_t_14 = __Pyx_PyInt_From_int(__pyx_v_ebN); if (unlikely(!__pyx_t_14)) __PYX_ERR(0, 1284, __pyx_L1_error)
13272  __Pyx_GOTREF(__pyx_t_14);
13273  __pyx_t_10 = __Pyx_PyInt_From_int(__pyx_v_k); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 1284, __pyx_L1_error)
13274  __Pyx_GOTREF(__pyx_t_10);
13275  __pyx_t_17 = __Pyx_PyInt_From_int(__pyx_v_I); if (unlikely(!__pyx_t_17)) __PYX_ERR(0, 1284, __pyx_L1_error)
13276  __Pyx_GOTREF(__pyx_t_17);
13277  __pyx_t_18 = PyTuple_New(3); if (unlikely(!__pyx_t_18)) __PYX_ERR(0, 1284, __pyx_L1_error)
13278  __Pyx_GOTREF(__pyx_t_18);
13279  __Pyx_GIVEREF(__pyx_t_14);
13280  PyTuple_SET_ITEM(__pyx_t_18, 0, __pyx_t_14);
13281  __Pyx_GIVEREF(__pyx_t_10);
13282  PyTuple_SET_ITEM(__pyx_t_18, 1, __pyx_t_10);
13283  __Pyx_GIVEREF(__pyx_t_17);
13284  PyTuple_SET_ITEM(__pyx_t_18, 2, __pyx_t_17);
13285  __pyx_t_14 = 0;
13286  __pyx_t_10 = 0;
13287  __pyx_t_17 = 0;
13288  __pyx_t_17 = __Pyx_PyObject_GetItem(((PyObject *)__pyx_v_ebq_velocityAverage), __pyx_t_18); if (unlikely(!__pyx_t_17)) __PYX_ERR(0, 1284, __pyx_L1_error)
13289  __Pyx_GOTREF(__pyx_t_17);
13290  __Pyx_DECREF(__pyx_t_18); __pyx_t_18 = 0;
13291  __pyx_t_18 = PyNumber_InPlaceAdd(__pyx_t_15, __pyx_t_17); if (unlikely(!__pyx_t_18)) __PYX_ERR(0, 1284, __pyx_L1_error)
13292  __Pyx_GOTREF(__pyx_t_18);
13293  __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0;
13294  __Pyx_DECREF(__pyx_t_17); __pyx_t_17 = 0;
13295  if (unlikely(PyObject_SetItem(((PyObject *)__pyx_v_ebq_v_par_local), __pyx_t_16, __pyx_t_18) < 0)) __PYX_ERR(0, 1284, __pyx_L1_error)
13296  __Pyx_DECREF(__pyx_t_18); __pyx_t_18 = 0;
13297  __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
13298  }
13299  }
13300  }
13301 
13302  /* "cpostprocessing.pyx":1272
13303  * ebq_v_par_local[ebN,permutations[ebN,k],I] = ebq_velocity[ebN,k,I]
13304  *
13305  * def addAverageToParVec(np.ndarray ebq_velocityAverage, # <<<<<<<<<<<<<<
13306  * np.ndarray[int, ndim=2] permutations,
13307  * np.ndarray ebq_v_par_local):
13308  */
13309 
13310  /* function exit code */
13311  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
13312  goto __pyx_L0;
13313  __pyx_L1_error:;
13314  __Pyx_XDECREF(__pyx_t_10);
13315  __Pyx_XDECREF(__pyx_t_14);
13316  __Pyx_XDECREF(__pyx_t_15);
13317  __Pyx_XDECREF(__pyx_t_16);
13318  __Pyx_XDECREF(__pyx_t_17);
13319  __Pyx_XDECREF(__pyx_t_18);
13320  { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
13321  __Pyx_PyThreadState_declare
13322  __Pyx_PyThreadState_assign
13323  __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
13324  __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_permutations.rcbuffer->pybuffer);
13325  __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
13326  __Pyx_AddTraceback("cpostprocessing.addAverageToParVec", __pyx_clineno, __pyx_lineno, __pyx_filename);
13327  __pyx_r = NULL;
13328  goto __pyx_L2;
13329  __pyx_L0:;
13330  __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_permutations.rcbuffer->pybuffer);
13331  __pyx_L2:;
13332  __Pyx_XGIVEREF(__pyx_r);
13333  __Pyx_RefNannyFinishContext();
13334  return __pyx_r;
13335 }
13336 
13337 /* "cpostprocessing.pyx":1286
13338  * ebq_v_par_local[ebN, permutations[ebN,k], I] += ebq_velocityAverage[ebN, k, I]
13339  *
13340  * def copyParVecToElementBoundaryVelocity(np.ndarray ebq_velocity, # <<<<<<<<<<<<<<
13341  * np.ndarray[int, ndim=2] permutations,
13342  * np.ndarray ebq_v_par_local):
13343  */
13344 
13345 /* Python wrapper */
13346 static PyObject *__pyx_pw_15cpostprocessing_109copyParVecToElementBoundaryVelocity(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
13347 static PyMethodDef __pyx_mdef_15cpostprocessing_109copyParVecToElementBoundaryVelocity = {"copyParVecToElementBoundaryVelocity", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_15cpostprocessing_109copyParVecToElementBoundaryVelocity, METH_VARARGS|METH_KEYWORDS, 0};
13348 static PyObject *__pyx_pw_15cpostprocessing_109copyParVecToElementBoundaryVelocity(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
13349  PyArrayObject *__pyx_v_ebq_velocity = 0;
13350  PyArrayObject *__pyx_v_permutations = 0;
13351  PyArrayObject *__pyx_v_ebq_v_par_local = 0;
13352  int __pyx_lineno = 0;
13353  const char *__pyx_filename = NULL;
13354  int __pyx_clineno = 0;
13355  PyObject *__pyx_r = 0;
13356  __Pyx_RefNannyDeclarations
13357  __Pyx_RefNannySetupContext("copyParVecToElementBoundaryVelocity (wrapper)", 0);
13358  {
13359  static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_ebq_velocity,&__pyx_n_s_permutations,&__pyx_n_s_ebq_v_par_local,0};
13360  PyObject* values[3] = {0,0,0};
13361  if (unlikely(__pyx_kwds)) {
13362  Py_ssize_t kw_args;
13363  const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
13364  switch (pos_args) {
13365  case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
13366  CYTHON_FALLTHROUGH;
13367  case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
13368  CYTHON_FALLTHROUGH;
13369  case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
13370  CYTHON_FALLTHROUGH;
13371  case 0: break;
13372  default: goto __pyx_L5_argtuple_error;
13373  }
13374  kw_args = PyDict_Size(__pyx_kwds);
13375  switch (pos_args) {
13376  case 0:
13377  if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ebq_velocity)) != 0)) kw_args--;
13378  else goto __pyx_L5_argtuple_error;
13379  CYTHON_FALLTHROUGH;
13380  case 1:
13381  if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_permutations)) != 0)) kw_args--;
13382  else {
13383  __Pyx_RaiseArgtupleInvalid("copyParVecToElementBoundaryVelocity", 1, 3, 3, 1); __PYX_ERR(0, 1286, __pyx_L3_error)
13384  }
13385  CYTHON_FALLTHROUGH;
13386  case 2:
13387  if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ebq_v_par_local)) != 0)) kw_args--;
13388  else {
13389  __Pyx_RaiseArgtupleInvalid("copyParVecToElementBoundaryVelocity", 1, 3, 3, 2); __PYX_ERR(0, 1286, __pyx_L3_error)
13390  }
13391  }
13392  if (unlikely(kw_args > 0)) {
13393  if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "copyParVecToElementBoundaryVelocity") < 0)) __PYX_ERR(0, 1286, __pyx_L3_error)
13394  }
13395  } else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
13396  goto __pyx_L5_argtuple_error;
13397  } else {
13398  values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
13399  values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
13400  values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
13401  }
13402  __pyx_v_ebq_velocity = ((PyArrayObject *)values[0]);
13403  __pyx_v_permutations = ((PyArrayObject *)values[1]);
13404  __pyx_v_ebq_v_par_local = ((PyArrayObject *)values[2]);
13405  }
13406  goto __pyx_L4_argument_unpacking_done;
13407  __pyx_L5_argtuple_error:;
13408  __Pyx_RaiseArgtupleInvalid("copyParVecToElementBoundaryVelocity", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 1286, __pyx_L3_error)
13409  __pyx_L3_error:;
13410  __Pyx_AddTraceback("cpostprocessing.copyParVecToElementBoundaryVelocity", __pyx_clineno, __pyx_lineno, __pyx_filename);
13411  __Pyx_RefNannyFinishContext();
13412  return NULL;
13413  __pyx_L4_argument_unpacking_done:;
13414  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ebq_velocity), __pyx_ptype_5numpy_ndarray, 1, "ebq_velocity", 0))) __PYX_ERR(0, 1286, __pyx_L1_error)
13415  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_permutations), __pyx_ptype_5numpy_ndarray, 1, "permutations", 0))) __PYX_ERR(0, 1287, __pyx_L1_error)
13416  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ebq_v_par_local), __pyx_ptype_5numpy_ndarray, 1, "ebq_v_par_local", 0))) __PYX_ERR(0, 1288, __pyx_L1_error)
13417  __pyx_r = __pyx_pf_15cpostprocessing_108copyParVecToElementBoundaryVelocity(__pyx_self, __pyx_v_ebq_velocity, __pyx_v_permutations, __pyx_v_ebq_v_par_local);
13418 
13419  /* function exit code */
13420  goto __pyx_L0;
13421  __pyx_L1_error:;
13422  __pyx_r = NULL;
13423  __pyx_L0:;
13424  __Pyx_RefNannyFinishContext();
13425  return __pyx_r;
13426 }
13427 
13428 static PyObject *__pyx_pf_15cpostprocessing_108copyParVecToElementBoundaryVelocity(CYTHON_UNUSED PyObject *__pyx_self, PyArrayObject *__pyx_v_ebq_velocity, PyArrayObject *__pyx_v_permutations, PyArrayObject *__pyx_v_ebq_v_par_local) {
13429  int __pyx_v_ebN;
13430  int __pyx_v_k;
13431  int __pyx_v_I;
13432  int __pyx_v_nElementBoundaries;
13433  int __pyx_v_nQuadraturePoints;
13434  int __pyx_v_nSpace;
13435  __Pyx_LocalBuf_ND __pyx_pybuffernd_permutations;
13436  __Pyx_Buffer __pyx_pybuffer_permutations;
13437  PyObject *__pyx_r = NULL;
13438  __Pyx_RefNannyDeclarations
13439  int __pyx_t_1;
13440  int __pyx_t_2;
13441  int __pyx_t_3;
13442  int __pyx_t_4;
13443  int __pyx_t_5;
13444  int __pyx_t_6;
13445  int __pyx_t_7;
13446  int __pyx_t_8;
13447  int __pyx_t_9;
13448  PyObject *__pyx_t_10 = NULL;
13449  Py_ssize_t __pyx_t_11;
13450  Py_ssize_t __pyx_t_12;
13451  int __pyx_t_13;
13452  PyObject *__pyx_t_14 = NULL;
13453  PyObject *__pyx_t_15 = NULL;
13454  PyObject *__pyx_t_16 = NULL;
13455  PyObject *__pyx_t_17 = NULL;
13456  int __pyx_lineno = 0;
13457  const char *__pyx_filename = NULL;
13458  int __pyx_clineno = 0;
13459  __Pyx_RefNannySetupContext("copyParVecToElementBoundaryVelocity", 0);
13460  __pyx_pybuffer_permutations.pybuffer.buf = NULL;
13461  __pyx_pybuffer_permutations.refcount = 0;
13462  __pyx_pybuffernd_permutations.data = NULL;
13463  __pyx_pybuffernd_permutations.rcbuffer = &__pyx_pybuffer_permutations;
13464  {
13465  __Pyx_BufFmt_StackElem __pyx_stack[1];
13466  if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_pybuffernd_permutations.rcbuffer->pybuffer, (PyObject*)__pyx_v_permutations, &__Pyx_TypeInfo_int, PyBUF_FORMAT| PyBUF_STRIDES, 2, 0, __pyx_stack) == -1)) __PYX_ERR(0, 1286, __pyx_L1_error)
13467  }
13468  __pyx_pybuffernd_permutations.diminfo[0].strides = __pyx_pybuffernd_permutations.rcbuffer->pybuffer.strides[0]; __pyx_pybuffernd_permutations.diminfo[0].shape = __pyx_pybuffernd_permutations.rcbuffer->pybuffer.shape[0]; __pyx_pybuffernd_permutations.diminfo[1].strides = __pyx_pybuffernd_permutations.rcbuffer->pybuffer.strides[1]; __pyx_pybuffernd_permutations.diminfo[1].shape = __pyx_pybuffernd_permutations.rcbuffer->pybuffer.shape[1];
13469 
13470  /* "cpostprocessing.pyx":1292
13471  * cdef int k
13472  * cdef int I
13473  * cdef int nElementBoundaries=ebq_v_par_local.shape[0] # <<<<<<<<<<<<<<
13474  * cdef int nQuadraturePoints=ebq_v_par_local.shape[1]
13475  * cdef int nSpace=ebq_v_par_local.shape[2]
13476  */
13477  __pyx_v_nElementBoundaries = (__pyx_v_ebq_v_par_local->dimensions[0]);
13478 
13479  /* "cpostprocessing.pyx":1293
13480  * cdef int I
13481  * cdef int nElementBoundaries=ebq_v_par_local.shape[0]
13482  * cdef int nQuadraturePoints=ebq_v_par_local.shape[1] # <<<<<<<<<<<<<<
13483  * cdef int nSpace=ebq_v_par_local.shape[2]
13484  * for ebN in range(nElementBoundaries):
13485  */
13486  __pyx_v_nQuadraturePoints = (__pyx_v_ebq_v_par_local->dimensions[1]);
13487 
13488  /* "cpostprocessing.pyx":1294
13489  * cdef int nElementBoundaries=ebq_v_par_local.shape[0]
13490  * cdef int nQuadraturePoints=ebq_v_par_local.shape[1]
13491  * cdef int nSpace=ebq_v_par_local.shape[2] # <<<<<<<<<<<<<<
13492  * for ebN in range(nElementBoundaries):
13493  * for k in range(nQuadraturePoints):
13494  */
13495  __pyx_v_nSpace = (__pyx_v_ebq_v_par_local->dimensions[2]);
13496 
13497  /* "cpostprocessing.pyx":1295
13498  * cdef int nQuadraturePoints=ebq_v_par_local.shape[1]
13499  * cdef int nSpace=ebq_v_par_local.shape[2]
13500  * for ebN in range(nElementBoundaries): # <<<<<<<<<<<<<<
13501  * for k in range(nQuadraturePoints):
13502  * for I in range(nSpace):
13503  */
13504  __pyx_t_1 = __pyx_v_nElementBoundaries;
13505  __pyx_t_2 = __pyx_t_1;
13506  for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
13507  __pyx_v_ebN = __pyx_t_3;
13508 
13509  /* "cpostprocessing.pyx":1296
13510  * cdef int nSpace=ebq_v_par_local.shape[2]
13511  * for ebN in range(nElementBoundaries):
13512  * for k in range(nQuadraturePoints): # <<<<<<<<<<<<<<
13513  * for I in range(nSpace):
13514  * ebq_velocity[ebN, k, I] = ebq_v_par_local[ebN, permutations[ebN, k], I]
13515  */
13516  __pyx_t_4 = __pyx_v_nQuadraturePoints;
13517  __pyx_t_5 = __pyx_t_4;
13518  for (__pyx_t_6 = 0; __pyx_t_6 < __pyx_t_5; __pyx_t_6+=1) {
13519  __pyx_v_k = __pyx_t_6;
13520 
13521  /* "cpostprocessing.pyx":1297
13522  * for ebN in range(nElementBoundaries):
13523  * for k in range(nQuadraturePoints):
13524  * for I in range(nSpace): # <<<<<<<<<<<<<<
13525  * ebq_velocity[ebN, k, I] = ebq_v_par_local[ebN, permutations[ebN, k], I]
13526  */
13527  __pyx_t_7 = __pyx_v_nSpace;
13528  __pyx_t_8 = __pyx_t_7;
13529  for (__pyx_t_9 = 0; __pyx_t_9 < __pyx_t_8; __pyx_t_9+=1) {
13530  __pyx_v_I = __pyx_t_9;
13531 
13532  /* "cpostprocessing.pyx":1298
13533  * for k in range(nQuadraturePoints):
13534  * for I in range(nSpace):
13535  * ebq_velocity[ebN, k, I] = ebq_v_par_local[ebN, permutations[ebN, k], I] # <<<<<<<<<<<<<<
13536  */
13537  __pyx_t_10 = __Pyx_PyInt_From_int(__pyx_v_ebN); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 1298, __pyx_L1_error)
13538  __Pyx_GOTREF(__pyx_t_10);
13539  __pyx_t_11 = __pyx_v_ebN;
13540  __pyx_t_12 = __pyx_v_k;
13541  __pyx_t_13 = -1;
13542  if (__pyx_t_11 < 0) {
13543  __pyx_t_11 += __pyx_pybuffernd_permutations.diminfo[0].shape;
13544  if (unlikely(__pyx_t_11 < 0)) __pyx_t_13 = 0;
13545  } else if (unlikely(__pyx_t_11 >= __pyx_pybuffernd_permutations.diminfo[0].shape)) __pyx_t_13 = 0;
13546  if (__pyx_t_12 < 0) {
13547  __pyx_t_12 += __pyx_pybuffernd_permutations.diminfo[1].shape;
13548  if (unlikely(__pyx_t_12 < 0)) __pyx_t_13 = 1;
13549  } else if (unlikely(__pyx_t_12 >= __pyx_pybuffernd_permutations.diminfo[1].shape)) __pyx_t_13 = 1;
13550  if (unlikely(__pyx_t_13 != -1)) {
13551  __Pyx_RaiseBufferIndexError(__pyx_t_13);
13552  __PYX_ERR(0, 1298, __pyx_L1_error)
13553  }
13554  __pyx_t_14 = __Pyx_PyInt_From_int((*__Pyx_BufPtrStrided2d(int *, __pyx_pybuffernd_permutations.rcbuffer->pybuffer.buf, __pyx_t_11, __pyx_pybuffernd_permutations.diminfo[0].strides, __pyx_t_12, __pyx_pybuffernd_permutations.diminfo[1].strides))); if (unlikely(!__pyx_t_14)) __PYX_ERR(0, 1298, __pyx_L1_error)
13555  __Pyx_GOTREF(__pyx_t_14);
13556  __pyx_t_15 = __Pyx_PyInt_From_int(__pyx_v_I); if (unlikely(!__pyx_t_15)) __PYX_ERR(0, 1298, __pyx_L1_error)
13557  __Pyx_GOTREF(__pyx_t_15);
13558  __pyx_t_16 = PyTuple_New(3); if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 1298, __pyx_L1_error)
13559  __Pyx_GOTREF(__pyx_t_16);
13560  __Pyx_GIVEREF(__pyx_t_10);
13561  PyTuple_SET_ITEM(__pyx_t_16, 0, __pyx_t_10);
13562  __Pyx_GIVEREF(__pyx_t_14);
13563  PyTuple_SET_ITEM(__pyx_t_16, 1, __pyx_t_14);
13564  __Pyx_GIVEREF(__pyx_t_15);
13565  PyTuple_SET_ITEM(__pyx_t_16, 2, __pyx_t_15);
13566  __pyx_t_10 = 0;
13567  __pyx_t_14 = 0;
13568  __pyx_t_15 = 0;
13569  __pyx_t_15 = __Pyx_PyObject_GetItem(((PyObject *)__pyx_v_ebq_v_par_local), __pyx_t_16); if (unlikely(!__pyx_t_15)) __PYX_ERR(0, 1298, __pyx_L1_error)
13570  __Pyx_GOTREF(__pyx_t_15);
13571  __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
13572  __pyx_t_16 = __Pyx_PyInt_From_int(__pyx_v_ebN); if (unlikely(!__pyx_t_16)) __PYX_ERR(0, 1298, __pyx_L1_error)
13573  __Pyx_GOTREF(__pyx_t_16);
13574  __pyx_t_14 = __Pyx_PyInt_From_int(__pyx_v_k); if (unlikely(!__pyx_t_14)) __PYX_ERR(0, 1298, __pyx_L1_error)
13575  __Pyx_GOTREF(__pyx_t_14);
13576  __pyx_t_10 = __Pyx_PyInt_From_int(__pyx_v_I); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 1298, __pyx_L1_error)
13577  __Pyx_GOTREF(__pyx_t_10);
13578  __pyx_t_17 = PyTuple_New(3); if (unlikely(!__pyx_t_17)) __PYX_ERR(0, 1298, __pyx_L1_error)
13579  __Pyx_GOTREF(__pyx_t_17);
13580  __Pyx_GIVEREF(__pyx_t_16);
13581  PyTuple_SET_ITEM(__pyx_t_17, 0, __pyx_t_16);
13582  __Pyx_GIVEREF(__pyx_t_14);
13583  PyTuple_SET_ITEM(__pyx_t_17, 1, __pyx_t_14);
13584  __Pyx_GIVEREF(__pyx_t_10);
13585  PyTuple_SET_ITEM(__pyx_t_17, 2, __pyx_t_10);
13586  __pyx_t_16 = 0;
13587  __pyx_t_14 = 0;
13588  __pyx_t_10 = 0;
13589  if (unlikely(PyObject_SetItem(((PyObject *)__pyx_v_ebq_velocity), __pyx_t_17, __pyx_t_15) < 0)) __PYX_ERR(0, 1298, __pyx_L1_error)
13590  __Pyx_DECREF(__pyx_t_17); __pyx_t_17 = 0;
13591  __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0;
13592  }
13593  }
13594  }
13595 
13596  /* "cpostprocessing.pyx":1286
13597  * ebq_v_par_local[ebN, permutations[ebN,k], I] += ebq_velocityAverage[ebN, k, I]
13598  *
13599  * def copyParVecToElementBoundaryVelocity(np.ndarray ebq_velocity, # <<<<<<<<<<<<<<
13600  * np.ndarray[int, ndim=2] permutations,
13601  * np.ndarray ebq_v_par_local):
13602  */
13603 
13604  /* function exit code */
13605  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
13606  goto __pyx_L0;
13607  __pyx_L1_error:;
13608  __Pyx_XDECREF(__pyx_t_10);
13609  __Pyx_XDECREF(__pyx_t_14);
13610  __Pyx_XDECREF(__pyx_t_15);
13611  __Pyx_XDECREF(__pyx_t_16);
13612  __Pyx_XDECREF(__pyx_t_17);
13613  { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
13614  __Pyx_PyThreadState_declare
13615  __Pyx_PyThreadState_assign
13616  __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
13617  __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_permutations.rcbuffer->pybuffer);
13618  __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
13619  __Pyx_AddTraceback("cpostprocessing.copyParVecToElementBoundaryVelocity", __pyx_clineno, __pyx_lineno, __pyx_filename);
13620  __pyx_r = NULL;
13621  goto __pyx_L2;
13622  __pyx_L0:;
13623  __Pyx_SafeReleaseBuffer(&__pyx_pybuffernd_permutations.rcbuffer->pybuffer);
13624  __pyx_L2:;
13625  __Pyx_XGIVEREF(__pyx_r);
13626  __Pyx_RefNannyFinishContext();
13627  return __pyx_r;
13628 }
13629 
13630 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":735
13631  * ctypedef npy_cdouble complex_t
13632  *
13633  * cdef inline object PyArray_MultiIterNew1(a): # <<<<<<<<<<<<<<
13634  * return PyArray_MultiIterNew(1, <void*>a)
13635  *
13636  */
13637 
13638 static CYTHON_INLINE PyObject *__pyx_f_5numpy_PyArray_MultiIterNew1(PyObject *__pyx_v_a) {
13639  PyObject *__pyx_r = NULL;
13640  __Pyx_RefNannyDeclarations
13641  PyObject *__pyx_t_1 = NULL;
13642  int __pyx_lineno = 0;
13643  const char *__pyx_filename = NULL;
13644  int __pyx_clineno = 0;
13645  __Pyx_RefNannySetupContext("PyArray_MultiIterNew1", 0);
13646 
13647  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":736
13648  *
13649  * cdef inline object PyArray_MultiIterNew1(a):
13650  * return PyArray_MultiIterNew(1, <void*>a) # <<<<<<<<<<<<<<
13651  *
13652  * cdef inline object PyArray_MultiIterNew2(a, b):
13653  */
13654  __Pyx_XDECREF(__pyx_r);
13655  __pyx_t_1 = PyArray_MultiIterNew(1, ((void *)__pyx_v_a)); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 736, __pyx_L1_error)
13656  __Pyx_GOTREF(__pyx_t_1);
13657  __pyx_r = __pyx_t_1;
13658  __pyx_t_1 = 0;
13659  goto __pyx_L0;
13660 
13661  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":735
13662  * ctypedef npy_cdouble complex_t
13663  *
13664  * cdef inline object PyArray_MultiIterNew1(a): # <<<<<<<<<<<<<<
13665  * return PyArray_MultiIterNew(1, <void*>a)
13666  *
13667  */
13668 
13669  /* function exit code */
13670  __pyx_L1_error:;
13671  __Pyx_XDECREF(__pyx_t_1);
13672  __Pyx_AddTraceback("numpy.PyArray_MultiIterNew1", __pyx_clineno, __pyx_lineno, __pyx_filename);
13673  __pyx_r = 0;
13674  __pyx_L0:;
13675  __Pyx_XGIVEREF(__pyx_r);
13676  __Pyx_RefNannyFinishContext();
13677  return __pyx_r;
13678 }
13679 
13680 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":738
13681  * return PyArray_MultiIterNew(1, <void*>a)
13682  *
13683  * cdef inline object PyArray_MultiIterNew2(a, b): # <<<<<<<<<<<<<<
13684  * return PyArray_MultiIterNew(2, <void*>a, <void*>b)
13685  *
13686  */
13687 
13688 static CYTHON_INLINE PyObject *__pyx_f_5numpy_PyArray_MultiIterNew2(PyObject *__pyx_v_a, PyObject *__pyx_v_b) {
13689  PyObject *__pyx_r = NULL;
13690  __Pyx_RefNannyDeclarations
13691  PyObject *__pyx_t_1 = NULL;
13692  int __pyx_lineno = 0;
13693  const char *__pyx_filename = NULL;
13694  int __pyx_clineno = 0;
13695  __Pyx_RefNannySetupContext("PyArray_MultiIterNew2", 0);
13696 
13697  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":739
13698  *
13699  * cdef inline object PyArray_MultiIterNew2(a, b):
13700  * return PyArray_MultiIterNew(2, <void*>a, <void*>b) # <<<<<<<<<<<<<<
13701  *
13702  * cdef inline object PyArray_MultiIterNew3(a, b, c):
13703  */
13704  __Pyx_XDECREF(__pyx_r);
13705  __pyx_t_1 = PyArray_MultiIterNew(2, ((void *)__pyx_v_a), ((void *)__pyx_v_b)); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 739, __pyx_L1_error)
13706  __Pyx_GOTREF(__pyx_t_1);
13707  __pyx_r = __pyx_t_1;
13708  __pyx_t_1 = 0;
13709  goto __pyx_L0;
13710 
13711  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":738
13712  * return PyArray_MultiIterNew(1, <void*>a)
13713  *
13714  * cdef inline object PyArray_MultiIterNew2(a, b): # <<<<<<<<<<<<<<
13715  * return PyArray_MultiIterNew(2, <void*>a, <void*>b)
13716  *
13717  */
13718 
13719  /* function exit code */
13720  __pyx_L1_error:;
13721  __Pyx_XDECREF(__pyx_t_1);
13722  __Pyx_AddTraceback("numpy.PyArray_MultiIterNew2", __pyx_clineno, __pyx_lineno, __pyx_filename);
13723  __pyx_r = 0;
13724  __pyx_L0:;
13725  __Pyx_XGIVEREF(__pyx_r);
13726  __Pyx_RefNannyFinishContext();
13727  return __pyx_r;
13728 }
13729 
13730 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":741
13731  * return PyArray_MultiIterNew(2, <void*>a, <void*>b)
13732  *
13733  * cdef inline object PyArray_MultiIterNew3(a, b, c): # <<<<<<<<<<<<<<
13734  * return PyArray_MultiIterNew(3, <void*>a, <void*>b, <void*> c)
13735  *
13736  */
13737 
13738 static CYTHON_INLINE PyObject *__pyx_f_5numpy_PyArray_MultiIterNew3(PyObject *__pyx_v_a, PyObject *__pyx_v_b, PyObject *__pyx_v_c) {
13739  PyObject *__pyx_r = NULL;
13740  __Pyx_RefNannyDeclarations
13741  PyObject *__pyx_t_1 = NULL;
13742  int __pyx_lineno = 0;
13743  const char *__pyx_filename = NULL;
13744  int __pyx_clineno = 0;
13745  __Pyx_RefNannySetupContext("PyArray_MultiIterNew3", 0);
13746 
13747  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":742
13748  *
13749  * cdef inline object PyArray_MultiIterNew3(a, b, c):
13750  * return PyArray_MultiIterNew(3, <void*>a, <void*>b, <void*> c) # <<<<<<<<<<<<<<
13751  *
13752  * cdef inline object PyArray_MultiIterNew4(a, b, c, d):
13753  */
13754  __Pyx_XDECREF(__pyx_r);
13755  __pyx_t_1 = PyArray_MultiIterNew(3, ((void *)__pyx_v_a), ((void *)__pyx_v_b), ((void *)__pyx_v_c)); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 742, __pyx_L1_error)
13756  __Pyx_GOTREF(__pyx_t_1);
13757  __pyx_r = __pyx_t_1;
13758  __pyx_t_1 = 0;
13759  goto __pyx_L0;
13760 
13761  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":741
13762  * return PyArray_MultiIterNew(2, <void*>a, <void*>b)
13763  *
13764  * cdef inline object PyArray_MultiIterNew3(a, b, c): # <<<<<<<<<<<<<<
13765  * return PyArray_MultiIterNew(3, <void*>a, <void*>b, <void*> c)
13766  *
13767  */
13768 
13769  /* function exit code */
13770  __pyx_L1_error:;
13771  __Pyx_XDECREF(__pyx_t_1);
13772  __Pyx_AddTraceback("numpy.PyArray_MultiIterNew3", __pyx_clineno, __pyx_lineno, __pyx_filename);
13773  __pyx_r = 0;
13774  __pyx_L0:;
13775  __Pyx_XGIVEREF(__pyx_r);
13776  __Pyx_RefNannyFinishContext();
13777  return __pyx_r;
13778 }
13779 
13780 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":744
13781  * return PyArray_MultiIterNew(3, <void*>a, <void*>b, <void*> c)
13782  *
13783  * cdef inline object PyArray_MultiIterNew4(a, b, c, d): # <<<<<<<<<<<<<<
13784  * return PyArray_MultiIterNew(4, <void*>a, <void*>b, <void*>c, <void*> d)
13785  *
13786  */
13787 
13788 static CYTHON_INLINE PyObject *__pyx_f_5numpy_PyArray_MultiIterNew4(PyObject *__pyx_v_a, PyObject *__pyx_v_b, PyObject *__pyx_v_c, PyObject *__pyx_v_d) {
13789  PyObject *__pyx_r = NULL;
13790  __Pyx_RefNannyDeclarations
13791  PyObject *__pyx_t_1 = NULL;
13792  int __pyx_lineno = 0;
13793  const char *__pyx_filename = NULL;
13794  int __pyx_clineno = 0;
13795  __Pyx_RefNannySetupContext("PyArray_MultiIterNew4", 0);
13796 
13797  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":745
13798  *
13799  * cdef inline object PyArray_MultiIterNew4(a, b, c, d):
13800  * return PyArray_MultiIterNew(4, <void*>a, <void*>b, <void*>c, <void*> d) # <<<<<<<<<<<<<<
13801  *
13802  * cdef inline object PyArray_MultiIterNew5(a, b, c, d, e):
13803  */
13804  __Pyx_XDECREF(__pyx_r);
13805  __pyx_t_1 = PyArray_MultiIterNew(4, ((void *)__pyx_v_a), ((void *)__pyx_v_b), ((void *)__pyx_v_c), ((void *)__pyx_v_d)); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 745, __pyx_L1_error)
13806  __Pyx_GOTREF(__pyx_t_1);
13807  __pyx_r = __pyx_t_1;
13808  __pyx_t_1 = 0;
13809  goto __pyx_L0;
13810 
13811  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":744
13812  * return PyArray_MultiIterNew(3, <void*>a, <void*>b, <void*> c)
13813  *
13814  * cdef inline object PyArray_MultiIterNew4(a, b, c, d): # <<<<<<<<<<<<<<
13815  * return PyArray_MultiIterNew(4, <void*>a, <void*>b, <void*>c, <void*> d)
13816  *
13817  */
13818 
13819  /* function exit code */
13820  __pyx_L1_error:;
13821  __Pyx_XDECREF(__pyx_t_1);
13822  __Pyx_AddTraceback("numpy.PyArray_MultiIterNew4", __pyx_clineno, __pyx_lineno, __pyx_filename);
13823  __pyx_r = 0;
13824  __pyx_L0:;
13825  __Pyx_XGIVEREF(__pyx_r);
13826  __Pyx_RefNannyFinishContext();
13827  return __pyx_r;
13828 }
13829 
13830 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":747
13831  * return PyArray_MultiIterNew(4, <void*>a, <void*>b, <void*>c, <void*> d)
13832  *
13833  * cdef inline object PyArray_MultiIterNew5(a, b, c, d, e): # <<<<<<<<<<<<<<
13834  * return PyArray_MultiIterNew(5, <void*>a, <void*>b, <void*>c, <void*> d, <void*> e)
13835  *
13836  */
13837 
13838 static CYTHON_INLINE PyObject *__pyx_f_5numpy_PyArray_MultiIterNew5(PyObject *__pyx_v_a, PyObject *__pyx_v_b, PyObject *__pyx_v_c, PyObject *__pyx_v_d, PyObject *__pyx_v_e) {
13839  PyObject *__pyx_r = NULL;
13840  __Pyx_RefNannyDeclarations
13841  PyObject *__pyx_t_1 = NULL;
13842  int __pyx_lineno = 0;
13843  const char *__pyx_filename = NULL;
13844  int __pyx_clineno = 0;
13845  __Pyx_RefNannySetupContext("PyArray_MultiIterNew5", 0);
13846 
13847  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":748
13848  *
13849  * cdef inline object PyArray_MultiIterNew5(a, b, c, d, e):
13850  * return PyArray_MultiIterNew(5, <void*>a, <void*>b, <void*>c, <void*> d, <void*> e) # <<<<<<<<<<<<<<
13851  *
13852  * cdef inline tuple PyDataType_SHAPE(dtype d):
13853  */
13854  __Pyx_XDECREF(__pyx_r);
13855  __pyx_t_1 = PyArray_MultiIterNew(5, ((void *)__pyx_v_a), ((void *)__pyx_v_b), ((void *)__pyx_v_c), ((void *)__pyx_v_d), ((void *)__pyx_v_e)); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 748, __pyx_L1_error)
13856  __Pyx_GOTREF(__pyx_t_1);
13857  __pyx_r = __pyx_t_1;
13858  __pyx_t_1 = 0;
13859  goto __pyx_L0;
13860 
13861  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":747
13862  * return PyArray_MultiIterNew(4, <void*>a, <void*>b, <void*>c, <void*> d)
13863  *
13864  * cdef inline object PyArray_MultiIterNew5(a, b, c, d, e): # <<<<<<<<<<<<<<
13865  * return PyArray_MultiIterNew(5, <void*>a, <void*>b, <void*>c, <void*> d, <void*> e)
13866  *
13867  */
13868 
13869  /* function exit code */
13870  __pyx_L1_error:;
13871  __Pyx_XDECREF(__pyx_t_1);
13872  __Pyx_AddTraceback("numpy.PyArray_MultiIterNew5", __pyx_clineno, __pyx_lineno, __pyx_filename);
13873  __pyx_r = 0;
13874  __pyx_L0:;
13875  __Pyx_XGIVEREF(__pyx_r);
13876  __Pyx_RefNannyFinishContext();
13877  return __pyx_r;
13878 }
13879 
13880 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":750
13881  * return PyArray_MultiIterNew(5, <void*>a, <void*>b, <void*>c, <void*> d, <void*> e)
13882  *
13883  * cdef inline tuple PyDataType_SHAPE(dtype d): # <<<<<<<<<<<<<<
13884  * if PyDataType_HASSUBARRAY(d):
13885  * return <tuple>d.subarray.shape
13886  */
13887 
13888 static CYTHON_INLINE PyObject *__pyx_f_5numpy_PyDataType_SHAPE(PyArray_Descr *__pyx_v_d) {
13889  PyObject *__pyx_r = NULL;
13890  __Pyx_RefNannyDeclarations
13891  int __pyx_t_1;
13892  __Pyx_RefNannySetupContext("PyDataType_SHAPE", 0);
13893 
13894  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":751
13895  *
13896  * cdef inline tuple PyDataType_SHAPE(dtype d):
13897  * if PyDataType_HASSUBARRAY(d): # <<<<<<<<<<<<<<
13898  * return <tuple>d.subarray.shape
13899  * else:
13900  */
13901  __pyx_t_1 = (PyDataType_HASSUBARRAY(__pyx_v_d) != 0);
13902  if (__pyx_t_1) {
13903 
13904  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":752
13905  * cdef inline tuple PyDataType_SHAPE(dtype d):
13906  * if PyDataType_HASSUBARRAY(d):
13907  * return <tuple>d.subarray.shape # <<<<<<<<<<<<<<
13908  * else:
13909  * return ()
13910  */
13911  __Pyx_XDECREF(__pyx_r);
13912  __Pyx_INCREF(((PyObject*)__pyx_v_d->subarray->shape));
13913  __pyx_r = ((PyObject*)__pyx_v_d->subarray->shape);
13914  goto __pyx_L0;
13915 
13916  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":751
13917  *
13918  * cdef inline tuple PyDataType_SHAPE(dtype d):
13919  * if PyDataType_HASSUBARRAY(d): # <<<<<<<<<<<<<<
13920  * return <tuple>d.subarray.shape
13921  * else:
13922  */
13923  }
13924 
13925  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":754
13926  * return <tuple>d.subarray.shape
13927  * else:
13928  * return () # <<<<<<<<<<<<<<
13929  *
13930  *
13931  */
13932  /*else*/ {
13933  __Pyx_XDECREF(__pyx_r);
13934  __Pyx_INCREF(__pyx_empty_tuple);
13935  __pyx_r = __pyx_empty_tuple;
13936  goto __pyx_L0;
13937  }
13938 
13939  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":750
13940  * return PyArray_MultiIterNew(5, <void*>a, <void*>b, <void*>c, <void*> d, <void*> e)
13941  *
13942  * cdef inline tuple PyDataType_SHAPE(dtype d): # <<<<<<<<<<<<<<
13943  * if PyDataType_HASSUBARRAY(d):
13944  * return <tuple>d.subarray.shape
13945  */
13946 
13947  /* function exit code */
13948  __pyx_L0:;
13949  __Pyx_XGIVEREF(__pyx_r);
13950  __Pyx_RefNannyFinishContext();
13951  return __pyx_r;
13952 }
13953 
13954 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":929
13955  * int _import_umath() except -1
13956  *
13957  * cdef inline void set_array_base(ndarray arr, object base): # <<<<<<<<<<<<<<
13958  * Py_INCREF(base) # important to do this before stealing the reference below!
13959  * PyArray_SetBaseObject(arr, base)
13960  */
13961 
13962 static CYTHON_INLINE void __pyx_f_5numpy_set_array_base(PyArrayObject *__pyx_v_arr, PyObject *__pyx_v_base) {
13963  __Pyx_RefNannyDeclarations
13964  __Pyx_RefNannySetupContext("set_array_base", 0);
13965 
13966  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":930
13967  *
13968  * cdef inline void set_array_base(ndarray arr, object base):
13969  * Py_INCREF(base) # important to do this before stealing the reference below! # <<<<<<<<<<<<<<
13970  * PyArray_SetBaseObject(arr, base)
13971  *
13972  */
13973  Py_INCREF(__pyx_v_base);
13974 
13975  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":931
13976  * cdef inline void set_array_base(ndarray arr, object base):
13977  * Py_INCREF(base) # important to do this before stealing the reference below!
13978  * PyArray_SetBaseObject(arr, base) # <<<<<<<<<<<<<<
13979  *
13980  * cdef inline object get_array_base(ndarray arr):
13981  */
13982  (void)(PyArray_SetBaseObject(__pyx_v_arr, __pyx_v_base));
13983 
13984  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":929
13985  * int _import_umath() except -1
13986  *
13987  * cdef inline void set_array_base(ndarray arr, object base): # <<<<<<<<<<<<<<
13988  * Py_INCREF(base) # important to do this before stealing the reference below!
13989  * PyArray_SetBaseObject(arr, base)
13990  */
13991 
13992  /* function exit code */
13993  __Pyx_RefNannyFinishContext();
13994 }
13995 
13996 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":933
13997  * PyArray_SetBaseObject(arr, base)
13998  *
13999  * cdef inline object get_array_base(ndarray arr): # <<<<<<<<<<<<<<
14000  * base = PyArray_BASE(arr)
14001  * if base is NULL:
14002  */
14003 
14004 static CYTHON_INLINE PyObject *__pyx_f_5numpy_get_array_base(PyArrayObject *__pyx_v_arr) {
14005  PyObject *__pyx_v_base;
14006  PyObject *__pyx_r = NULL;
14007  __Pyx_RefNannyDeclarations
14008  int __pyx_t_1;
14009  __Pyx_RefNannySetupContext("get_array_base", 0);
14010 
14011  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":934
14012  *
14013  * cdef inline object get_array_base(ndarray arr):
14014  * base = PyArray_BASE(arr) # <<<<<<<<<<<<<<
14015  * if base is NULL:
14016  * return None
14017  */
14018  __pyx_v_base = PyArray_BASE(__pyx_v_arr);
14019 
14020  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":935
14021  * cdef inline object get_array_base(ndarray arr):
14022  * base = PyArray_BASE(arr)
14023  * if base is NULL: # <<<<<<<<<<<<<<
14024  * return None
14025  * return <object>base
14026  */
14027  __pyx_t_1 = ((__pyx_v_base == NULL) != 0);
14028  if (__pyx_t_1) {
14029 
14030  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":936
14031  * base = PyArray_BASE(arr)
14032  * if base is NULL:
14033  * return None # <<<<<<<<<<<<<<
14034  * return <object>base
14035  *
14036  */
14037  __Pyx_XDECREF(__pyx_r);
14038  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
14039  goto __pyx_L0;
14040 
14041  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":935
14042  * cdef inline object get_array_base(ndarray arr):
14043  * base = PyArray_BASE(arr)
14044  * if base is NULL: # <<<<<<<<<<<<<<
14045  * return None
14046  * return <object>base
14047  */
14048  }
14049 
14050  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":937
14051  * if base is NULL:
14052  * return None
14053  * return <object>base # <<<<<<<<<<<<<<
14054  *
14055  * # Versions of the import_* functions which are more suitable for
14056  */
14057  __Pyx_XDECREF(__pyx_r);
14058  __Pyx_INCREF(((PyObject *)__pyx_v_base));
14059  __pyx_r = ((PyObject *)__pyx_v_base);
14060  goto __pyx_L0;
14061 
14062  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":933
14063  * PyArray_SetBaseObject(arr, base)
14064  *
14065  * cdef inline object get_array_base(ndarray arr): # <<<<<<<<<<<<<<
14066  * base = PyArray_BASE(arr)
14067  * if base is NULL:
14068  */
14069 
14070  /* function exit code */
14071  __pyx_L0:;
14072  __Pyx_XGIVEREF(__pyx_r);
14073  __Pyx_RefNannyFinishContext();
14074  return __pyx_r;
14075 }
14076 
14077 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":941
14078  * # Versions of the import_* functions which are more suitable for
14079  * # Cython code.
14080  * cdef inline int import_array() except -1: # <<<<<<<<<<<<<<
14081  * try:
14082  * __pyx_import_array()
14083  */
14084 
14085 static CYTHON_INLINE int __pyx_f_5numpy_import_array(void) {
14086  int __pyx_r;
14087  __Pyx_RefNannyDeclarations
14088  PyObject *__pyx_t_1 = NULL;
14089  PyObject *__pyx_t_2 = NULL;
14090  PyObject *__pyx_t_3 = NULL;
14091  int __pyx_t_4;
14092  PyObject *__pyx_t_5 = NULL;
14093  PyObject *__pyx_t_6 = NULL;
14094  PyObject *__pyx_t_7 = NULL;
14095  PyObject *__pyx_t_8 = NULL;
14096  int __pyx_lineno = 0;
14097  const char *__pyx_filename = NULL;
14098  int __pyx_clineno = 0;
14099  __Pyx_RefNannySetupContext("import_array", 0);
14100 
14101  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":942
14102  * # Cython code.
14103  * cdef inline int import_array() except -1:
14104  * try: # <<<<<<<<<<<<<<
14105  * __pyx_import_array()
14106  * except Exception:
14107  */
14108  {
14109  __Pyx_PyThreadState_declare
14110  __Pyx_PyThreadState_assign
14111  __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3);
14112  __Pyx_XGOTREF(__pyx_t_1);
14113  __Pyx_XGOTREF(__pyx_t_2);
14114  __Pyx_XGOTREF(__pyx_t_3);
14115  /*try:*/ {
14116 
14117  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":943
14118  * cdef inline int import_array() except -1:
14119  * try:
14120  * __pyx_import_array() # <<<<<<<<<<<<<<
14121  * except Exception:
14122  * raise ImportError("numpy.core.multiarray failed to import")
14123  */
14124  __pyx_t_4 = _import_array(); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 943, __pyx_L3_error)
14125 
14126  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":942
14127  * # Cython code.
14128  * cdef inline int import_array() except -1:
14129  * try: # <<<<<<<<<<<<<<
14130  * __pyx_import_array()
14131  * except Exception:
14132  */
14133  }
14134  __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
14135  __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
14136  __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
14137  goto __pyx_L8_try_end;
14138  __pyx_L3_error:;
14139 
14140  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":944
14141  * try:
14142  * __pyx_import_array()
14143  * except Exception: # <<<<<<<<<<<<<<
14144  * raise ImportError("numpy.core.multiarray failed to import")
14145  *
14146  */
14147  __pyx_t_4 = __Pyx_PyErr_ExceptionMatches(((PyObject *)(&((PyTypeObject*)PyExc_Exception)[0])));
14148  if (__pyx_t_4) {
14149  __Pyx_AddTraceback("numpy.import_array", __pyx_clineno, __pyx_lineno, __pyx_filename);
14150  if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_6, &__pyx_t_7) < 0) __PYX_ERR(2, 944, __pyx_L5_except_error)
14151  __Pyx_GOTREF(__pyx_t_5);
14152  __Pyx_GOTREF(__pyx_t_6);
14153  __Pyx_GOTREF(__pyx_t_7);
14154 
14155  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":945
14156  * __pyx_import_array()
14157  * except Exception:
14158  * raise ImportError("numpy.core.multiarray failed to import") # <<<<<<<<<<<<<<
14159  *
14160  * cdef inline int import_umath() except -1:
14161  */
14162  __pyx_t_8 = __Pyx_PyObject_Call(__pyx_builtin_ImportError, __pyx_tuple__3, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 945, __pyx_L5_except_error)
14163  __Pyx_GOTREF(__pyx_t_8);
14164  __Pyx_Raise(__pyx_t_8, 0, 0, 0);
14165  __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
14166  __PYX_ERR(2, 945, __pyx_L5_except_error)
14167  }
14168  goto __pyx_L5_except_error;
14169  __pyx_L5_except_error:;
14170 
14171  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":942
14172  * # Cython code.
14173  * cdef inline int import_array() except -1:
14174  * try: # <<<<<<<<<<<<<<
14175  * __pyx_import_array()
14176  * except Exception:
14177  */
14178  __Pyx_XGIVEREF(__pyx_t_1);
14179  __Pyx_XGIVEREF(__pyx_t_2);
14180  __Pyx_XGIVEREF(__pyx_t_3);
14181  __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
14182  goto __pyx_L1_error;
14183  __pyx_L8_try_end:;
14184  }
14185 
14186  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":941
14187  * # Versions of the import_* functions which are more suitable for
14188  * # Cython code.
14189  * cdef inline int import_array() except -1: # <<<<<<<<<<<<<<
14190  * try:
14191  * __pyx_import_array()
14192  */
14193 
14194  /* function exit code */
14195  __pyx_r = 0;
14196  goto __pyx_L0;
14197  __pyx_L1_error:;
14198  __Pyx_XDECREF(__pyx_t_5);
14199  __Pyx_XDECREF(__pyx_t_6);
14200  __Pyx_XDECREF(__pyx_t_7);
14201  __Pyx_XDECREF(__pyx_t_8);
14202  __Pyx_AddTraceback("numpy.import_array", __pyx_clineno, __pyx_lineno, __pyx_filename);
14203  __pyx_r = -1;
14204  __pyx_L0:;
14205  __Pyx_RefNannyFinishContext();
14206  return __pyx_r;
14207 }
14208 
14209 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":947
14210  * raise ImportError("numpy.core.multiarray failed to import")
14211  *
14212  * cdef inline int import_umath() except -1: # <<<<<<<<<<<<<<
14213  * try:
14214  * _import_umath()
14215  */
14216 
14217 static CYTHON_INLINE int __pyx_f_5numpy_import_umath(void) {
14218  int __pyx_r;
14219  __Pyx_RefNannyDeclarations
14220  PyObject *__pyx_t_1 = NULL;
14221  PyObject *__pyx_t_2 = NULL;
14222  PyObject *__pyx_t_3 = NULL;
14223  int __pyx_t_4;
14224  PyObject *__pyx_t_5 = NULL;
14225  PyObject *__pyx_t_6 = NULL;
14226  PyObject *__pyx_t_7 = NULL;
14227  PyObject *__pyx_t_8 = NULL;
14228  int __pyx_lineno = 0;
14229  const char *__pyx_filename = NULL;
14230  int __pyx_clineno = 0;
14231  __Pyx_RefNannySetupContext("import_umath", 0);
14232 
14233  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":948
14234  *
14235  * cdef inline int import_umath() except -1:
14236  * try: # <<<<<<<<<<<<<<
14237  * _import_umath()
14238  * except Exception:
14239  */
14240  {
14241  __Pyx_PyThreadState_declare
14242  __Pyx_PyThreadState_assign
14243  __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3);
14244  __Pyx_XGOTREF(__pyx_t_1);
14245  __Pyx_XGOTREF(__pyx_t_2);
14246  __Pyx_XGOTREF(__pyx_t_3);
14247  /*try:*/ {
14248 
14249  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":949
14250  * cdef inline int import_umath() except -1:
14251  * try:
14252  * _import_umath() # <<<<<<<<<<<<<<
14253  * except Exception:
14254  * raise ImportError("numpy.core.umath failed to import")
14255  */
14256  __pyx_t_4 = _import_umath(); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 949, __pyx_L3_error)
14257 
14258  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":948
14259  *
14260  * cdef inline int import_umath() except -1:
14261  * try: # <<<<<<<<<<<<<<
14262  * _import_umath()
14263  * except Exception:
14264  */
14265  }
14266  __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
14267  __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
14268  __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
14269  goto __pyx_L8_try_end;
14270  __pyx_L3_error:;
14271 
14272  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":950
14273  * try:
14274  * _import_umath()
14275  * except Exception: # <<<<<<<<<<<<<<
14276  * raise ImportError("numpy.core.umath failed to import")
14277  *
14278  */
14279  __pyx_t_4 = __Pyx_PyErr_ExceptionMatches(((PyObject *)(&((PyTypeObject*)PyExc_Exception)[0])));
14280  if (__pyx_t_4) {
14281  __Pyx_AddTraceback("numpy.import_umath", __pyx_clineno, __pyx_lineno, __pyx_filename);
14282  if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_6, &__pyx_t_7) < 0) __PYX_ERR(2, 950, __pyx_L5_except_error)
14283  __Pyx_GOTREF(__pyx_t_5);
14284  __Pyx_GOTREF(__pyx_t_6);
14285  __Pyx_GOTREF(__pyx_t_7);
14286 
14287  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":951
14288  * _import_umath()
14289  * except Exception:
14290  * raise ImportError("numpy.core.umath failed to import") # <<<<<<<<<<<<<<
14291  *
14292  * cdef inline int import_ufunc() except -1:
14293  */
14294  __pyx_t_8 = __Pyx_PyObject_Call(__pyx_builtin_ImportError, __pyx_tuple__4, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 951, __pyx_L5_except_error)
14295  __Pyx_GOTREF(__pyx_t_8);
14296  __Pyx_Raise(__pyx_t_8, 0, 0, 0);
14297  __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
14298  __PYX_ERR(2, 951, __pyx_L5_except_error)
14299  }
14300  goto __pyx_L5_except_error;
14301  __pyx_L5_except_error:;
14302 
14303  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":948
14304  *
14305  * cdef inline int import_umath() except -1:
14306  * try: # <<<<<<<<<<<<<<
14307  * _import_umath()
14308  * except Exception:
14309  */
14310  __Pyx_XGIVEREF(__pyx_t_1);
14311  __Pyx_XGIVEREF(__pyx_t_2);
14312  __Pyx_XGIVEREF(__pyx_t_3);
14313  __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
14314  goto __pyx_L1_error;
14315  __pyx_L8_try_end:;
14316  }
14317 
14318  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":947
14319  * raise ImportError("numpy.core.multiarray failed to import")
14320  *
14321  * cdef inline int import_umath() except -1: # <<<<<<<<<<<<<<
14322  * try:
14323  * _import_umath()
14324  */
14325 
14326  /* function exit code */
14327  __pyx_r = 0;
14328  goto __pyx_L0;
14329  __pyx_L1_error:;
14330  __Pyx_XDECREF(__pyx_t_5);
14331  __Pyx_XDECREF(__pyx_t_6);
14332  __Pyx_XDECREF(__pyx_t_7);
14333  __Pyx_XDECREF(__pyx_t_8);
14334  __Pyx_AddTraceback("numpy.import_umath", __pyx_clineno, __pyx_lineno, __pyx_filename);
14335  __pyx_r = -1;
14336  __pyx_L0:;
14337  __Pyx_RefNannyFinishContext();
14338  return __pyx_r;
14339 }
14340 
14341 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":953
14342  * raise ImportError("numpy.core.umath failed to import")
14343  *
14344  * cdef inline int import_ufunc() except -1: # <<<<<<<<<<<<<<
14345  * try:
14346  * _import_umath()
14347  */
14348 
14349 static CYTHON_INLINE int __pyx_f_5numpy_import_ufunc(void) {
14350  int __pyx_r;
14351  __Pyx_RefNannyDeclarations
14352  PyObject *__pyx_t_1 = NULL;
14353  PyObject *__pyx_t_2 = NULL;
14354  PyObject *__pyx_t_3 = NULL;
14355  int __pyx_t_4;
14356  PyObject *__pyx_t_5 = NULL;
14357  PyObject *__pyx_t_6 = NULL;
14358  PyObject *__pyx_t_7 = NULL;
14359  PyObject *__pyx_t_8 = NULL;
14360  int __pyx_lineno = 0;
14361  const char *__pyx_filename = NULL;
14362  int __pyx_clineno = 0;
14363  __Pyx_RefNannySetupContext("import_ufunc", 0);
14364 
14365  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":954
14366  *
14367  * cdef inline int import_ufunc() except -1:
14368  * try: # <<<<<<<<<<<<<<
14369  * _import_umath()
14370  * except Exception:
14371  */
14372  {
14373  __Pyx_PyThreadState_declare
14374  __Pyx_PyThreadState_assign
14375  __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3);
14376  __Pyx_XGOTREF(__pyx_t_1);
14377  __Pyx_XGOTREF(__pyx_t_2);
14378  __Pyx_XGOTREF(__pyx_t_3);
14379  /*try:*/ {
14380 
14381  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":955
14382  * cdef inline int import_ufunc() except -1:
14383  * try:
14384  * _import_umath() # <<<<<<<<<<<<<<
14385  * except Exception:
14386  * raise ImportError("numpy.core.umath failed to import")
14387  */
14388  __pyx_t_4 = _import_umath(); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(2, 955, __pyx_L3_error)
14389 
14390  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":954
14391  *
14392  * cdef inline int import_ufunc() except -1:
14393  * try: # <<<<<<<<<<<<<<
14394  * _import_umath()
14395  * except Exception:
14396  */
14397  }
14398  __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
14399  __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
14400  __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
14401  goto __pyx_L8_try_end;
14402  __pyx_L3_error:;
14403 
14404  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":956
14405  * try:
14406  * _import_umath()
14407  * except Exception: # <<<<<<<<<<<<<<
14408  * raise ImportError("numpy.core.umath failed to import")
14409  *
14410  */
14411  __pyx_t_4 = __Pyx_PyErr_ExceptionMatches(((PyObject *)(&((PyTypeObject*)PyExc_Exception)[0])));
14412  if (__pyx_t_4) {
14413  __Pyx_AddTraceback("numpy.import_ufunc", __pyx_clineno, __pyx_lineno, __pyx_filename);
14414  if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_6, &__pyx_t_7) < 0) __PYX_ERR(2, 956, __pyx_L5_except_error)
14415  __Pyx_GOTREF(__pyx_t_5);
14416  __Pyx_GOTREF(__pyx_t_6);
14417  __Pyx_GOTREF(__pyx_t_7);
14418 
14419  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":957
14420  * _import_umath()
14421  * except Exception:
14422  * raise ImportError("numpy.core.umath failed to import") # <<<<<<<<<<<<<<
14423  *
14424  * cdef extern from *:
14425  */
14426  __pyx_t_8 = __Pyx_PyObject_Call(__pyx_builtin_ImportError, __pyx_tuple__4, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 957, __pyx_L5_except_error)
14427  __Pyx_GOTREF(__pyx_t_8);
14428  __Pyx_Raise(__pyx_t_8, 0, 0, 0);
14429  __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
14430  __PYX_ERR(2, 957, __pyx_L5_except_error)
14431  }
14432  goto __pyx_L5_except_error;
14433  __pyx_L5_except_error:;
14434 
14435  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":954
14436  *
14437  * cdef inline int import_ufunc() except -1:
14438  * try: # <<<<<<<<<<<<<<
14439  * _import_umath()
14440  * except Exception:
14441  */
14442  __Pyx_XGIVEREF(__pyx_t_1);
14443  __Pyx_XGIVEREF(__pyx_t_2);
14444  __Pyx_XGIVEREF(__pyx_t_3);
14445  __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
14446  goto __pyx_L1_error;
14447  __pyx_L8_try_end:;
14448  }
14449 
14450  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":953
14451  * raise ImportError("numpy.core.umath failed to import")
14452  *
14453  * cdef inline int import_ufunc() except -1: # <<<<<<<<<<<<<<
14454  * try:
14455  * _import_umath()
14456  */
14457 
14458  /* function exit code */
14459  __pyx_r = 0;
14460  goto __pyx_L0;
14461  __pyx_L1_error:;
14462  __Pyx_XDECREF(__pyx_t_5);
14463  __Pyx_XDECREF(__pyx_t_6);
14464  __Pyx_XDECREF(__pyx_t_7);
14465  __Pyx_XDECREF(__pyx_t_8);
14466  __Pyx_AddTraceback("numpy.import_ufunc", __pyx_clineno, __pyx_lineno, __pyx_filename);
14467  __pyx_r = -1;
14468  __pyx_L0:;
14469  __Pyx_RefNannyFinishContext();
14470  return __pyx_r;
14471 }
14472 
14473 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":967
14474  *
14475  *
14476  * cdef inline bint is_timedelta64_object(object obj): # <<<<<<<<<<<<<<
14477  * """
14478  * Cython equivalent of `isinstance(obj, np.timedelta64)`
14479  */
14480 
14481 static CYTHON_INLINE int __pyx_f_5numpy_is_timedelta64_object(PyObject *__pyx_v_obj) {
14482  int __pyx_r;
14483  __Pyx_RefNannyDeclarations
14484  __Pyx_RefNannySetupContext("is_timedelta64_object", 0);
14485 
14486  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":979
14487  * bool
14488  * """
14489  * return PyObject_TypeCheck(obj, &PyTimedeltaArrType_Type) # <<<<<<<<<<<<<<
14490  *
14491  *
14492  */
14493  __pyx_r = PyObject_TypeCheck(__pyx_v_obj, (&PyTimedeltaArrType_Type));
14494  goto __pyx_L0;
14495 
14496  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":967
14497  *
14498  *
14499  * cdef inline bint is_timedelta64_object(object obj): # <<<<<<<<<<<<<<
14500  * """
14501  * Cython equivalent of `isinstance(obj, np.timedelta64)`
14502  */
14503 
14504  /* function exit code */
14505  __pyx_L0:;
14506  __Pyx_RefNannyFinishContext();
14507  return __pyx_r;
14508 }
14509 
14510 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":982
14511  *
14512  *
14513  * cdef inline bint is_datetime64_object(object obj): # <<<<<<<<<<<<<<
14514  * """
14515  * Cython equivalent of `isinstance(obj, np.datetime64)`
14516  */
14517 
14518 static CYTHON_INLINE int __pyx_f_5numpy_is_datetime64_object(PyObject *__pyx_v_obj) {
14519  int __pyx_r;
14520  __Pyx_RefNannyDeclarations
14521  __Pyx_RefNannySetupContext("is_datetime64_object", 0);
14522 
14523  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":994
14524  * bool
14525  * """
14526  * return PyObject_TypeCheck(obj, &PyDatetimeArrType_Type) # <<<<<<<<<<<<<<
14527  *
14528  *
14529  */
14530  __pyx_r = PyObject_TypeCheck(__pyx_v_obj, (&PyDatetimeArrType_Type));
14531  goto __pyx_L0;
14532 
14533  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":982
14534  *
14535  *
14536  * cdef inline bint is_datetime64_object(object obj): # <<<<<<<<<<<<<<
14537  * """
14538  * Cython equivalent of `isinstance(obj, np.datetime64)`
14539  */
14540 
14541  /* function exit code */
14542  __pyx_L0:;
14543  __Pyx_RefNannyFinishContext();
14544  return __pyx_r;
14545 }
14546 
14547 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":997
14548  *
14549  *
14550  * cdef inline npy_datetime get_datetime64_value(object obj) nogil: # <<<<<<<<<<<<<<
14551  * """
14552  * returns the int64 value underlying scalar numpy datetime64 object
14553  */
14554 
14555 static CYTHON_INLINE npy_datetime __pyx_f_5numpy_get_datetime64_value(PyObject *__pyx_v_obj) {
14556  npy_datetime __pyx_r;
14557 
14558  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":1004
14559  * also needed. That can be found using `get_datetime64_unit`.
14560  * """
14561  * return (<PyDatetimeScalarObject*>obj).obval # <<<<<<<<<<<<<<
14562  *
14563  *
14564  */
14565  __pyx_r = ((PyDatetimeScalarObject *)__pyx_v_obj)->obval;
14566  goto __pyx_L0;
14567 
14568  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":997
14569  *
14570  *
14571  * cdef inline npy_datetime get_datetime64_value(object obj) nogil: # <<<<<<<<<<<<<<
14572  * """
14573  * returns the int64 value underlying scalar numpy datetime64 object
14574  */
14575 
14576  /* function exit code */
14577  __pyx_L0:;
14578  return __pyx_r;
14579 }
14580 
14581 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":1007
14582  *
14583  *
14584  * cdef inline npy_timedelta get_timedelta64_value(object obj) nogil: # <<<<<<<<<<<<<<
14585  * """
14586  * returns the int64 value underlying scalar numpy timedelta64 object
14587  */
14588 
14589 static CYTHON_INLINE npy_timedelta __pyx_f_5numpy_get_timedelta64_value(PyObject *__pyx_v_obj) {
14590  npy_timedelta __pyx_r;
14591 
14592  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":1011
14593  * returns the int64 value underlying scalar numpy timedelta64 object
14594  * """
14595  * return (<PyTimedeltaScalarObject*>obj).obval # <<<<<<<<<<<<<<
14596  *
14597  *
14598  */
14599  __pyx_r = ((PyTimedeltaScalarObject *)__pyx_v_obj)->obval;
14600  goto __pyx_L0;
14601 
14602  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":1007
14603  *
14604  *
14605  * cdef inline npy_timedelta get_timedelta64_value(object obj) nogil: # <<<<<<<<<<<<<<
14606  * """
14607  * returns the int64 value underlying scalar numpy timedelta64 object
14608  */
14609 
14610  /* function exit code */
14611  __pyx_L0:;
14612  return __pyx_r;
14613 }
14614 
14615 /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":1014
14616  *
14617  *
14618  * cdef inline NPY_DATETIMEUNIT get_datetime64_unit(object obj) nogil: # <<<<<<<<<<<<<<
14619  * """
14620  * returns the unit part of the dtype for a numpy datetime64 object.
14621  */
14622 
14623 static CYTHON_INLINE NPY_DATETIMEUNIT __pyx_f_5numpy_get_datetime64_unit(PyObject *__pyx_v_obj) {
14624  NPY_DATETIMEUNIT __pyx_r;
14625 
14626  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":1018
14627  * returns the unit part of the dtype for a numpy datetime64 object.
14628  * """
14629  * return <NPY_DATETIMEUNIT>(<PyDatetimeScalarObject*>obj).obmeta.base # <<<<<<<<<<<<<<
14630  */
14631  __pyx_r = ((NPY_DATETIMEUNIT)((PyDatetimeScalarObject *)__pyx_v_obj)->obmeta.base);
14632  goto __pyx_L0;
14633 
14634  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":1014
14635  *
14636  *
14637  * cdef inline NPY_DATETIMEUNIT get_datetime64_unit(object obj) nogil: # <<<<<<<<<<<<<<
14638  * """
14639  * returns the unit part of the dtype for a numpy datetime64 object.
14640  */
14641 
14642  /* function exit code */
14643  __pyx_L0:;
14644  return __pyx_r;
14645 }
14646 
14647 static PyObject *__pyx_tp_new_15cpostprocessing_NodeStarFactor(PyTypeObject *t, PyObject *a, PyObject *k) {
14648  PyObject *o;
14649  if (likely((t->tp_flags & Py_TPFLAGS_IS_ABSTRACT) == 0)) {
14650  o = (*t->tp_alloc)(t, 0);
14651  } else {
14652  o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0);
14653  }
14654  if (unlikely(!o)) return 0;
14655  if (unlikely(__pyx_pw_15cpostprocessing_14NodeStarFactor_1__cinit__(o, a, k) < 0)) goto bad;
14656  return o;
14657  bad:
14658  Py_DECREF(o); o = 0;
14659  return NULL;
14660 }
14661 
14662 static void __pyx_tp_dealloc_15cpostprocessing_NodeStarFactor(PyObject *o) {
14663  #if CYTHON_USE_TP_FINALIZE
14664  if (unlikely(PyType_HasFeature(Py_TYPE(o), Py_TPFLAGS_HAVE_FINALIZE) && Py_TYPE(o)->tp_finalize) && (!PyType_IS_GC(Py_TYPE(o)) || !_PyGC_FINALIZED(o))) {
14665  if (PyObject_CallFinalizerFromDealloc(o)) return;
14666  }
14667  #endif
14668  {
14669  PyObject *etype, *eval, *etb;
14670  PyErr_Fetch(&etype, &eval, &etb);
14671  __Pyx_SET_REFCNT(o, Py_REFCNT(o) + 1);
14672  __pyx_pw_15cpostprocessing_14NodeStarFactor_3__dealloc__(o);
14673  __Pyx_SET_REFCNT(o, Py_REFCNT(o) - 1);
14674  PyErr_Restore(etype, eval, etb);
14675  }
14676  (*Py_TYPE(o)->tp_free)(o);
14677 }
14678 
14679 static PyMethodDef __pyx_methods_15cpostprocessing_NodeStarFactor[] = {
14680  {"setU", (PyCFunction)__pyx_pw_15cpostprocessing_14NodeStarFactor_5setU, METH_O, 0},
14681  {"copyData", (PyCFunction)__pyx_pw_15cpostprocessing_14NodeStarFactor_7copyData, METH_O, 0},
14682  {"__reduce_cython__", (PyCFunction)__pyx_pw_15cpostprocessing_14NodeStarFactor_9__reduce_cython__, METH_NOARGS, 0},
14683  {"__setstate_cython__", (PyCFunction)__pyx_pw_15cpostprocessing_14NodeStarFactor_11__setstate_cython__, METH_O, 0},
14684  {0, 0, 0, 0}
14685 };
14686 
14687 static PyTypeObject __pyx_type_15cpostprocessing_NodeStarFactor = {
14688  PyVarObject_HEAD_INIT(0, 0)
14689  "cpostprocessing.NodeStarFactor", /*tp_name*/
14690  sizeof(struct __pyx_obj_15cpostprocessing_NodeStarFactor), /*tp_basicsize*/
14691  0, /*tp_itemsize*/
14692  __pyx_tp_dealloc_15cpostprocessing_NodeStarFactor, /*tp_dealloc*/
14693  #if PY_VERSION_HEX < 0x030800b4
14694  0, /*tp_print*/
14695  #endif
14696  #if PY_VERSION_HEX >= 0x030800b4
14697  0, /*tp_vectorcall_offset*/
14698  #endif
14699  0, /*tp_getattr*/
14700  0, /*tp_setattr*/
14701  #if PY_MAJOR_VERSION < 3
14702  0, /*tp_compare*/
14703  #endif
14704  #if PY_MAJOR_VERSION >= 3
14705  0, /*tp_as_async*/
14706  #endif
14707  0, /*tp_repr*/
14708  0, /*tp_as_number*/
14709  0, /*tp_as_sequence*/
14710  0, /*tp_as_mapping*/
14711  0, /*tp_hash*/
14712  0, /*tp_call*/
14713  0, /*tp_str*/
14714  0, /*tp_getattro*/
14715  0, /*tp_setattro*/
14716  0, /*tp_as_buffer*/
14717  Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE, /*tp_flags*/
14718  0, /*tp_doc*/
14719  0, /*tp_traverse*/
14720  0, /*tp_clear*/
14721  0, /*tp_richcompare*/
14722  0, /*tp_weaklistoffset*/
14723  0, /*tp_iter*/
14724  0, /*tp_iternext*/
14725  __pyx_methods_15cpostprocessing_NodeStarFactor, /*tp_methods*/
14726  0, /*tp_members*/
14727  0, /*tp_getset*/
14728  0, /*tp_base*/
14729  0, /*tp_dict*/
14730  0, /*tp_descr_get*/
14731  0, /*tp_descr_set*/
14732  0, /*tp_dictoffset*/
14733  0, /*tp_init*/
14734  0, /*tp_alloc*/
14735  __pyx_tp_new_15cpostprocessing_NodeStarFactor, /*tp_new*/
14736  0, /*tp_free*/
14737  0, /*tp_is_gc*/
14738  0, /*tp_bases*/
14739  0, /*tp_mro*/
14740  0, /*tp_cache*/
14741  0, /*tp_subclasses*/
14742  0, /*tp_weaklist*/
14743  0, /*tp_del*/
14744  0, /*tp_version_tag*/
14745  #if PY_VERSION_HEX >= 0x030400a1
14746  0, /*tp_finalize*/
14747  #endif
14748  #if PY_VERSION_HEX >= 0x030800b1 && (!CYTHON_COMPILING_IN_PYPY || PYPY_VERSION_NUM >= 0x07030800)
14749  0, /*tp_vectorcall*/
14750  #endif
14751  #if PY_VERSION_HEX >= 0x030800b4 && PY_VERSION_HEX < 0x03090000
14752  0, /*tp_print*/
14753  #endif
14754  #if CYTHON_COMPILING_IN_PYPY && PY_VERSION_HEX >= 0x03090000
14755  0, /*tp_pypy_flags*/
14756  #endif
14757 };
14758 
14759 static PyMethodDef __pyx_methods[] = {
14760  {0, 0, 0, 0}
14761 };
14762 
14763 #if PY_MAJOR_VERSION >= 3
14764 #if CYTHON_PEP489_MULTI_PHASE_INIT
14765 static PyObject* __pyx_pymod_create(PyObject *spec, PyModuleDef *def); /*proto*/
14766 static int __pyx_pymod_exec_cpostprocessing(PyObject* module); /*proto*/
14767 static PyModuleDef_Slot __pyx_moduledef_slots[] = {
14768  {Py_mod_create, (void*)__pyx_pymod_create},
14769  {Py_mod_exec, (void*)__pyx_pymod_exec_cpostprocessing},
14770  {0, NULL}
14771 };
14772 #endif
14773 
14774 static struct PyModuleDef __pyx_moduledef = {
14775  PyModuleDef_HEAD_INIT,
14776  "cpostprocessing",
14777  0, /* m_doc */
14778  #if CYTHON_PEP489_MULTI_PHASE_INIT
14779  0, /* m_size */
14780  #else
14781  -1, /* m_size */
14782  #endif
14783  __pyx_methods /* m_methods */,
14784  #if CYTHON_PEP489_MULTI_PHASE_INIT
14785  __pyx_moduledef_slots, /* m_slots */
14786  #else
14787  NULL, /* m_reload */
14788  #endif
14789  NULL, /* m_traverse */
14790  NULL, /* m_clear */
14791  NULL /* m_free */
14792 };
14793 #endif
14794 #ifndef CYTHON_SMALL_CODE
14795 #if defined(__clang__)
14796  #define CYTHON_SMALL_CODE
14797 #elif defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 3))
14798  #define CYTHON_SMALL_CODE __attribute__((cold))
14799 #else
14800  #define CYTHON_SMALL_CODE
14801 #endif
14802 #endif
14803 
14804 static __Pyx_StringTabEntry __pyx_string_tab[] = {
14805  {&__pyx_n_s_BDMmatPivots_element, __pyx_k_BDMmatPivots_element, sizeof(__pyx_k_BDMmatPivots_element), 0, 0, 1, 1},
14806  {&__pyx_n_s_BDMmat_element, __pyx_k_BDMmat_element, sizeof(__pyx_k_BDMmat_element), 0, 0, 1, 1},
14807  {&__pyx_n_s_I, __pyx_k_I, sizeof(__pyx_k_I), 0, 0, 1, 1},
14808  {&__pyx_n_s_ImportError, __pyx_k_ImportError, sizeof(__pyx_k_ImportError), 0, 0, 1, 1},
14809  {&__pyx_n_s_NodeStarFactor, __pyx_k_NodeStarFactor, sizeof(__pyx_k_NodeStarFactor), 0, 0, 1, 1},
14810  {&__pyx_n_s_TypeError, __pyx_k_TypeError, sizeof(__pyx_k_TypeError), 0, 0, 1, 1},
14811  {&__pyx_n_s_a, __pyx_k_a, sizeof(__pyx_k_a), 0, 0, 1, 1},
14812  {&__pyx_n_s_aElementQuadWeights, __pyx_k_aElementQuadWeights, sizeof(__pyx_k_aElementQuadWeights), 0, 0, 1, 1},
14813  {&__pyx_n_s_abs_det_J, __pyx_k_abs_det_J, sizeof(__pyx_k_abs_det_J), 0, 0, 1, 1},
14814  {&__pyx_n_s_addAverageToParVec, __pyx_k_addAverageToParVec, sizeof(__pyx_k_addAverageToParVec), 0, 0, 1, 1},
14815  {&__pyx_n_s_advectiveVelocity, __pyx_k_advectiveVelocity, sizeof(__pyx_k_advectiveVelocity), 0, 0, 1, 1},
14816  {&__pyx_n_s_alpha, __pyx_k_alpha, sizeof(__pyx_k_alpha), 0, 0, 1, 1},
14817  {&__pyx_n_s_alphaFactor, __pyx_k_alphaFactor, sizeof(__pyx_k_alphaFactor), 0, 0, 1, 1},
14818  {&__pyx_n_s_buildBDM2rhs, __pyx_k_buildBDM2rhs, sizeof(__pyx_k_buildBDM2rhs), 0, 0, 1, 1},
14819  {&__pyx_n_s_buildLocalBDM1projectionMatrices, __pyx_k_buildLocalBDM1projectionMatrices, sizeof(__pyx_k_buildLocalBDM1projectionMatrices), 0, 0, 1, 1},
14820  {&__pyx_n_s_buildLocalBDM2projectionMatrices, __pyx_k_buildLocalBDM2projectionMatrices, sizeof(__pyx_k_buildLocalBDM2projectionMatrices), 0, 0, 1, 1},
14821  {&__pyx_n_s_calculateConservationFluxPWL, __pyx_k_calculateConservationFluxPWL, sizeof(__pyx_k_calculateConservationFluxPWL), 0, 0, 1, 1},
14822  {&__pyx_n_s_calculateConservationFluxPWL_noN, __pyx_k_calculateConservationFluxPWL_noN, sizeof(__pyx_k_calculateConservationFluxPWL_noN), 0, 0, 1, 1},
14823  {&__pyx_n_s_calculateConservationFluxPWL_opt, __pyx_k_calculateConservationFluxPWL_opt, sizeof(__pyx_k_calculateConservationFluxPWL_opt), 0, 0, 1, 1},
14824  {&__pyx_n_s_calculateConservationJacobianPWL, __pyx_k_calculateConservationJacobianPWL, sizeof(__pyx_k_calculateConservationJacobianPWL), 0, 0, 1, 1},
14825  {&__pyx_n_s_calculateConservationJacobianPWL_2, __pyx_k_calculateConservationJacobianPWL_2, sizeof(__pyx_k_calculateConservationJacobianPWL_2), 0, 0, 1, 1},
14826  {&__pyx_n_s_calculateConservationJacobianPWL_3, __pyx_k_calculateConservationJacobianPWL_3, sizeof(__pyx_k_calculateConservationJacobianPWL_3), 0, 0, 1, 1},
14827  {&__pyx_n_s_calculateConservationResidualGlo, __pyx_k_calculateConservationResidualGlo, sizeof(__pyx_k_calculateConservationResidualGlo), 0, 0, 1, 1},
14828  {&__pyx_n_s_calculateConservationResidualPWL, __pyx_k_calculateConservationResidualPWL, sizeof(__pyx_k_calculateConservationResidualPWL), 0, 0, 1, 1},
14829  {&__pyx_n_s_calculateConservationResidualPWL_2, __pyx_k_calculateConservationResidualPWL_2, sizeof(__pyx_k_calculateConservationResidualPWL_2), 0, 0, 1, 1},
14830  {&__pyx_n_s_calculateConservationResidualPWL_3, __pyx_k_calculateConservationResidualPWL_3, sizeof(__pyx_k_calculateConservationResidualPWL_3), 0, 0, 1, 1},
14831  {&__pyx_n_s_calculateConservationResidualPWL_4, __pyx_k_calculateConservationResidualPWL_4, sizeof(__pyx_k_calculateConservationResidualPWL_4), 0, 0, 1, 1},
14832  {&__pyx_n_s_calculateElementResidualPWL, __pyx_k_calculateElementResidualPWL, sizeof(__pyx_k_calculateElementResidualPWL), 0, 0, 1, 1},
14833  {&__pyx_n_s_cline_in_traceback, __pyx_k_cline_in_traceback, sizeof(__pyx_k_cline_in_traceback), 0, 0, 1, 1},
14834  {&__pyx_n_s_colind, __pyx_k_colind, sizeof(__pyx_k_colind), 0, 0, 1, 1},
14835  {&__pyx_n_s_computeFluxCorrectionPWC, __pyx_k_computeFluxCorrectionPWC, sizeof(__pyx_k_computeFluxCorrectionPWC), 0, 0, 1, 1},
14836  {&__pyx_n_s_conservationResidual, __pyx_k_conservationResidual, sizeof(__pyx_k_conservationResidual), 0, 0, 1, 1},
14837  {&__pyx_n_s_copyElementBoundaryVelocityToPar, __pyx_k_copyElementBoundaryVelocityToPar, sizeof(__pyx_k_copyElementBoundaryVelocityToPar), 0, 0, 1, 1},
14838  {&__pyx_n_s_copyParVecToElementBoundaryVeloc, __pyx_k_copyParVecToElementBoundaryVeloc, sizeof(__pyx_k_copyParVecToElementBoundaryVeloc), 0, 0, 1, 1},
14839  {&__pyx_n_s_cpostprocessing, __pyx_k_cpostprocessing, sizeof(__pyx_k_cpostprocessing), 0, 0, 1, 1},
14840  {&__pyx_n_s_dS, __pyx_k_dS, sizeof(__pyx_k_dS), 0, 0, 1, 1},
14841  {&__pyx_n_s_degree, __pyx_k_degree, sizeof(__pyx_k_degree), 0, 0, 1, 1},
14842  {&__pyx_n_s_detJ, __pyx_k_detJ, sizeof(__pyx_k_detJ), 0, 0, 1, 1},
14843  {&__pyx_n_s_diffusionTensor, __pyx_k_diffusionTensor, sizeof(__pyx_k_diffusionTensor), 0, 0, 1, 1},
14844  {&__pyx_n_s_dofMapl2g, __pyx_k_dofMapl2g, sizeof(__pyx_k_dofMapl2g), 0, 0, 1, 1},
14845  {&__pyx_n_s_dofStarElementNeighbors, __pyx_k_dofStarElementNeighbors, sizeof(__pyx_k_dofStarElementNeighbors), 0, 0, 1, 1},
14846  {&__pyx_n_s_dofStarElements, __pyx_k_dofStarElements, sizeof(__pyx_k_dofStarElements), 0, 0, 1, 1},
14847  {&__pyx_n_s_dx, __pyx_k_dx, sizeof(__pyx_k_dx), 0, 0, 1, 1},
14848  {&__pyx_n_s_ebN, __pyx_k_ebN, sizeof(__pyx_k_ebN), 0, 0, 1, 1},
14849  {&__pyx_n_s_ebq_global_flux, __pyx_k_ebq_global_flux, sizeof(__pyx_k_ebq_global_flux), 0, 0, 1, 1},
14850  {&__pyx_n_s_ebq_global_velocity, __pyx_k_ebq_global_velocity, sizeof(__pyx_k_ebq_global_velocity), 0, 0, 1, 1},
14851  {&__pyx_n_s_ebq_n, __pyx_k_ebq_n, sizeof(__pyx_k_ebq_n), 0, 0, 1, 1},
14852  {&__pyx_n_s_ebq_v, __pyx_k_ebq_v, sizeof(__pyx_k_ebq_v), 0, 0, 1, 1},
14853  {&__pyx_n_s_ebq_v_par_local, __pyx_k_ebq_v_par_local, sizeof(__pyx_k_ebq_v_par_local), 0, 0, 1, 1},
14854  {&__pyx_n_s_ebq_velocity, __pyx_k_ebq_velocity, sizeof(__pyx_k_ebq_velocity), 0, 0, 1, 1},
14855  {&__pyx_n_s_ebq_velocityAverage, __pyx_k_ebq_velocityAverage, sizeof(__pyx_k_ebq_velocityAverage), 0, 0, 1, 1},
14856  {&__pyx_n_s_ebqe_v, __pyx_k_ebqe_v, sizeof(__pyx_k_ebqe_v), 0, 0, 1, 1},
14857  {&__pyx_n_s_ebqe_velocity, __pyx_k_ebqe_velocity, sizeof(__pyx_k_ebqe_velocity), 0, 0, 1, 1},
14858  {&__pyx_n_s_edgeFlags, __pyx_k_edgeFlags, sizeof(__pyx_k_edgeFlags), 0, 0, 1, 1},
14859  {&__pyx_n_s_elementBarycenters, __pyx_k_elementBarycenters, sizeof(__pyx_k_elementBarycenters), 0, 0, 1, 1},
14860  {&__pyx_n_s_elementBoundariesArray, __pyx_k_elementBoundariesArray, sizeof(__pyx_k_elementBoundariesArray), 0, 0, 1, 1},
14861  {&__pyx_n_s_elementBoundaryElements, __pyx_k_elementBoundaryElements, sizeof(__pyx_k_elementBoundaryElements), 0, 0, 1, 1},
14862  {&__pyx_n_s_elementBoundaryElementsArray, __pyx_k_elementBoundaryElementsArray, sizeof(__pyx_k_elementBoundaryElementsArray), 0, 0, 1, 1},
14863  {&__pyx_n_s_elementBoundaryLocalElementBound, __pyx_k_elementBoundaryLocalElementBound, sizeof(__pyx_k_elementBoundaryLocalElementBound), 0, 0, 1, 1},
14864  {&__pyx_n_s_elementBoundaryQuadratureWeights, __pyx_k_elementBoundaryQuadratureWeights, sizeof(__pyx_k_elementBoundaryQuadratureWeights), 0, 0, 1, 1},
14865  {&__pyx_n_s_elementNodes, __pyx_k_elementNodes, sizeof(__pyx_k_elementNodes), 0, 0, 1, 1},
14866  {&__pyx_n_s_elementNodesArray, __pyx_k_elementNodesArray, sizeof(__pyx_k_elementNodesArray), 0, 0, 1, 1},
14867  {&__pyx_n_s_elementResidual, __pyx_k_elementResidual, sizeof(__pyx_k_elementResidual), 0, 0, 1, 1},
14868  {&__pyx_n_s_elementResidualPWL, __pyx_k_elementResidualPWL, sizeof(__pyx_k_elementResidualPWL), 0, 0, 1, 1},
14869  {&__pyx_n_s_element_locations, __pyx_k_element_locations, sizeof(__pyx_k_element_locations), 0, 0, 1, 1},
14870  {&__pyx_n_s_exteriorElementBoundaries, __pyx_k_exteriorElementBoundaries, sizeof(__pyx_k_exteriorElementBoundaries), 0, 0, 1, 1},
14871  {&__pyx_n_s_exteriorElementBoundariesArray, __pyx_k_exteriorElementBoundariesArray, sizeof(__pyx_k_exteriorElementBoundariesArray), 0, 0, 1, 1},
14872  {&__pyx_n_s_exteriorElementBoundariesToSkip, __pyx_k_exteriorElementBoundariesToSkip, sizeof(__pyx_k_exteriorElementBoundariesToSkip), 0, 0, 1, 1},
14873  {&__pyx_n_s_f, __pyx_k_f, sizeof(__pyx_k_f), 0, 0, 1, 1},
14874  {&__pyx_n_s_factorLocalBDM1projectionMatrice, __pyx_k_factorLocalBDM1projectionMatrice, sizeof(__pyx_k_factorLocalBDM1projectionMatrice), 0, 0, 1, 1},
14875  {&__pyx_n_s_factorLocalBDM2projectionMatrice, __pyx_k_factorLocalBDM2projectionMatrice, sizeof(__pyx_k_factorLocalBDM2projectionMatrice), 0, 0, 1, 1},
14876  {&__pyx_n_s_flux, __pyx_k_flux, sizeof(__pyx_k_flux), 0, 0, 1, 1},
14877  {&__pyx_n_s_fluxBoundaryNodes, __pyx_k_fluxBoundaryNodes, sizeof(__pyx_k_fluxBoundaryNodes), 0, 0, 1, 1},
14878  {&__pyx_n_s_fluxCorrection, __pyx_k_fluxCorrection, sizeof(__pyx_k_fluxCorrection), 0, 0, 1, 1},
14879  {&__pyx_n_s_fluxCorrectionVelocityUpdate, __pyx_k_fluxCorrectionVelocityUpdate, sizeof(__pyx_k_fluxCorrectionVelocityUpdate), 0, 0, 1, 1},
14880  {&__pyx_n_s_fluxElementBoundaries, __pyx_k_fluxElementBoundaries, sizeof(__pyx_k_fluxElementBoundaries), 0, 0, 1, 1},
14881  {&__pyx_n_s_flux_elementBoundary, __pyx_k_flux_elementBoundary, sizeof(__pyx_k_flux_elementBoundary), 0, 0, 1, 1},
14882  {&__pyx_n_s_freeLocal_element, __pyx_k_freeLocal_element, sizeof(__pyx_k_freeLocal_element), 0, 0, 1, 1},
14883  {&__pyx_n_s_getElementBDM1velocityValuesLagr, __pyx_k_getElementBDM1velocityValuesLagr, sizeof(__pyx_k_getElementBDM1velocityValuesLagr), 0, 0, 1, 1},
14884  {&__pyx_n_s_getElementBDM2velocityValuesLagr, __pyx_k_getElementBDM2velocityValuesLagr, sizeof(__pyx_k_getElementBDM2velocityValuesLagr), 0, 0, 1, 1},
14885  {&__pyx_n_s_getElementBoundaryBDM1velocityVa, __pyx_k_getElementBoundaryBDM1velocityVa, sizeof(__pyx_k_getElementBoundaryBDM1velocityVa), 0, 0, 1, 1},
14886  {&__pyx_n_s_getElementBoundaryRT0velocityVal, __pyx_k_getElementBoundaryRT0velocityVal, sizeof(__pyx_k_getElementBoundaryRT0velocityVal), 0, 0, 1, 1},
14887  {&__pyx_n_s_getElementBoundaryRT0velocityVal_2, __pyx_k_getElementBoundaryRT0velocityVal_2, sizeof(__pyx_k_getElementBoundaryRT0velocityVal_2), 0, 0, 1, 1},
14888  {&__pyx_n_s_getElementLDGvelocityValuesLagra, __pyx_k_getElementLDGvelocityValuesLagra, sizeof(__pyx_k_getElementLDGvelocityValuesLagra), 0, 0, 1, 1},
14889  {&__pyx_n_s_getElementRT0velocityValues, __pyx_k_getElementRT0velocityValues, sizeof(__pyx_k_getElementRT0velocityValues), 0, 0, 1, 1},
14890  {&__pyx_n_s_getElementRT0velocityValuesFluxR, __pyx_k_getElementRT0velocityValuesFluxR, sizeof(__pyx_k_getElementRT0velocityValuesFluxR), 0, 0, 1, 1},
14891  {&__pyx_n_s_getGlobalElementBoundaryBDM1velo, __pyx_k_getGlobalElementBoundaryBDM1velo, sizeof(__pyx_k_getGlobalElementBoundaryBDM1velo), 0, 0, 1, 1},
14892  {&__pyx_n_s_getGlobalElementBoundaryRT0veloc, __pyx_k_getGlobalElementBoundaryRT0veloc, sizeof(__pyx_k_getGlobalElementBoundaryRT0veloc), 0, 0, 1, 1},
14893  {&__pyx_n_s_getGlobalElementBoundaryRT0veloc_2, __pyx_k_getGlobalElementBoundaryRT0veloc_2, sizeof(__pyx_k_getGlobalElementBoundaryRT0veloc_2), 0, 0, 1, 1},
14894  {&__pyx_n_s_getGlobalExteriorElementBoundary, __pyx_k_getGlobalExteriorElementBoundary, sizeof(__pyx_k_getGlobalExteriorElementBoundary), 0, 0, 1, 1},
14895  {&__pyx_n_s_getGlobalExteriorElementBoundary_2, __pyx_k_getGlobalExteriorElementBoundary_2, sizeof(__pyx_k_getGlobalExteriorElementBoundary_2), 0, 0, 1, 1},
14896  {&__pyx_n_s_getGlobalExteriorElementBoundary_3, __pyx_k_getGlobalExteriorElementBoundary_3, sizeof(__pyx_k_getGlobalExteriorElementBoundary_3), 0, 0, 1, 1},
14897  {&__pyx_n_s_getRT0velocityValuesFluxRep_arbi, __pyx_k_getRT0velocityValuesFluxRep_arbi, sizeof(__pyx_k_getRT0velocityValuesFluxRep_arbi), 0, 0, 1, 1},
14898  {&__pyx_n_s_getstate, __pyx_k_getstate, sizeof(__pyx_k_getstate), 0, 0, 1, 1},
14899  {&__pyx_n_s_grad_phi, __pyx_k_grad_phi, sizeof(__pyx_k_grad_phi), 0, 0, 1, 1},
14900  {&__pyx_n_s_gradphi, __pyx_k_gradphi, sizeof(__pyx_k_gradphi), 0, 0, 1, 1},
14901  {&__pyx_n_s_gradu, __pyx_k_gradu, sizeof(__pyx_k_gradu), 0, 0, 1, 1},
14902  {&__pyx_n_s_import, __pyx_k_import, sizeof(__pyx_k_import), 0, 0, 1, 1},
14903  {&__pyx_n_s_interiorElementBoundaries, __pyx_k_interiorElementBoundaries, sizeof(__pyx_k_interiorElementBoundaries), 0, 0, 1, 1},
14904  {&__pyx_n_s_internalNodes, __pyx_k_internalNodes, sizeof(__pyx_k_internalNodes), 0, 0, 1, 1},
14905  {&__pyx_n_s_k, __pyx_k_k, sizeof(__pyx_k_k), 0, 0, 1, 1},
14906  {&__pyx_n_s_main, __pyx_k_main, sizeof(__pyx_k_main), 0, 0, 1, 1},
14907  {&__pyx_n_s_max_nN_owned, __pyx_k_max_nN_owned, sizeof(__pyx_k_max_nN_owned), 0, 0, 1, 1},
14908  {&__pyx_n_s_mt, __pyx_k_mt, sizeof(__pyx_k_mt), 0, 0, 1, 1},
14909  {&__pyx_n_s_n, __pyx_k_n, sizeof(__pyx_k_n), 0, 0, 1, 1},
14910  {&__pyx_n_s_nDOF_trial_element, __pyx_k_nDOF_trial_element, sizeof(__pyx_k_nDOF_trial_element), 0, 0, 1, 1},
14911  {&__pyx_n_s_nElementBoundaries, __pyx_k_nElementBoundaries, sizeof(__pyx_k_nElementBoundaries), 0, 0, 1, 1},
14912  {&__pyx_n_s_nElements_dof, __pyx_k_nElements_dof, sizeof(__pyx_k_nElements_dof), 0, 0, 1, 1},
14913  {&__pyx_n_s_nElements_node, __pyx_k_nElements_node, sizeof(__pyx_k_nElements_node), 0, 0, 1, 1},
14914  {&__pyx_n_s_nFreeDOF_element, __pyx_k_nFreeDOF_element, sizeof(__pyx_k_nFreeDOF_element), 0, 0, 1, 1},
14915  {&__pyx_n_s_nNodes_owned, __pyx_k_nNodes_owned, sizeof(__pyx_k_nNodes_owned), 0, 0, 1, 1},
14916  {&__pyx_n_s_nPoints, __pyx_k_nPoints, sizeof(__pyx_k_nPoints), 0, 0, 1, 1},
14917  {&__pyx_n_s_nQuadraturePoints, __pyx_k_nQuadraturePoints, sizeof(__pyx_k_nQuadraturePoints), 0, 0, 1, 1},
14918  {&__pyx_n_s_nSpace, __pyx_k_nSpace, sizeof(__pyx_k_nSpace), 0, 0, 1, 1},
14919  {&__pyx_n_s_nVDOF_element, __pyx_k_nVDOF_element, sizeof(__pyx_k_nVDOF_element), 0, 0, 1, 1},
14920  {&__pyx_n_s_nVDOFs_element, __pyx_k_nVDOFs_element, sizeof(__pyx_k_nVDOFs_element), 0, 0, 1, 1},
14921  {&__pyx_n_s_name, __pyx_k_name, sizeof(__pyx_k_name), 0, 0, 1, 1},
14922  {&__pyx_kp_s_no_default___reduce___due_to_non, __pyx_k_no_default___reduce___due_to_non, sizeof(__pyx_k_no_default___reduce___due_to_non), 0, 0, 1, 0},
14923  {&__pyx_n_s_nodeArray, __pyx_k_nodeArray, sizeof(__pyx_k_nodeArray), 0, 0, 1, 1},
14924  {&__pyx_n_s_nodeStarElementNeighbors, __pyx_k_nodeStarElementNeighbors, sizeof(__pyx_k_nodeStarElementNeighbors), 0, 0, 1, 1},
14925  {&__pyx_n_s_nodeStarElements, __pyx_k_nodeStarElements, sizeof(__pyx_k_nodeStarElements), 0, 0, 1, 1},
14926  {&__pyx_n_s_nodeStarElementsArray, __pyx_k_nodeStarElementsArray, sizeof(__pyx_k_nodeStarElementsArray), 0, 0, 1, 1},
14927  {&__pyx_n_s_nodeStarElementsNeighborsArray, __pyx_k_nodeStarElementsNeighborsArray, sizeof(__pyx_k_nodeStarElementsNeighborsArray), 0, 0, 1, 1},
14928  {&__pyx_n_s_nodeStarFactor, __pyx_k_nodeStarFactor, sizeof(__pyx_k_nodeStarFactor), 0, 0, 1, 1},
14929  {&__pyx_n_s_np, __pyx_k_np, sizeof(__pyx_k_np), 0, 0, 1, 1},
14930  {&__pyx_n_s_numpy, __pyx_k_numpy, sizeof(__pyx_k_numpy), 0, 0, 1, 1},
14931  {&__pyx_kp_s_numpy_core_multiarray_failed_to, __pyx_k_numpy_core_multiarray_failed_to, sizeof(__pyx_k_numpy_core_multiarray_failed_to), 0, 0, 1, 0},
14932  {&__pyx_kp_s_numpy_core_umath_failed_to_impor, __pyx_k_numpy_core_umath_failed_to_impor, sizeof(__pyx_k_numpy_core_umath_failed_to_impor), 0, 0, 1, 0},
14933  {&__pyx_n_s_p1_vdofs, __pyx_k_p1_vdofs, sizeof(__pyx_k_p1_vdofs), 0, 0, 1, 1},
14934  {&__pyx_n_s_permutations, __pyx_k_permutations, sizeof(__pyx_k_permutations), 0, 0, 1, 1},
14935  {&__pyx_n_s_phi, __pyx_k_phi, sizeof(__pyx_k_phi), 0, 0, 1, 1},
14936  {&__pyx_n_s_piola_trial_fun, __pyx_k_piola_trial_fun, sizeof(__pyx_k_piola_trial_fun), 0, 0, 1, 1},
14937  {&__pyx_n_s_postProcessRT0potentialFromP1nc, __pyx_k_postProcessRT0potentialFromP1nc, sizeof(__pyx_k_postProcessRT0potentialFromP1nc), 0, 0, 1, 1},
14938  {&__pyx_n_s_postProcessRT0potentialFromP1nc_2, __pyx_k_postProcessRT0potentialFromP1nc_2, sizeof(__pyx_k_postProcessRT0potentialFromP1nc_2), 0, 0, 1, 1},
14939  {&__pyx_n_s_postProcessRT0velocityFromP1nc, __pyx_k_postProcessRT0velocityFromP1nc, sizeof(__pyx_k_postProcessRT0velocityFromP1nc), 0, 0, 1, 1},
14940  {&__pyx_n_s_postProcessRT0velocityFromP1nc_s, __pyx_k_postProcessRT0velocityFromP1nc_s, sizeof(__pyx_k_postProcessRT0velocityFromP1nc_s), 0, 0, 1, 1},
14941  {&__pyx_n_s_projectElementBoundaryFluxToRT0f, __pyx_k_projectElementBoundaryFluxToRT0f, sizeof(__pyx_k_projectElementBoundaryFluxToRT0f), 0, 0, 1, 1},
14942  {&__pyx_n_s_projectElementBoundaryVelocityTo, __pyx_k_projectElementBoundaryVelocityTo, sizeof(__pyx_k_projectElementBoundaryVelocityTo), 0, 0, 1, 1},
14943  {&__pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_k_proteus_cpostprocessing_pyx, sizeof(__pyx_k_proteus_cpostprocessing_pyx), 0, 0, 1, 0},
14944  {&__pyx_n_s_pwcV, __pyx_k_pwcV, sizeof(__pyx_k_pwcV), 0, 0, 1, 1},
14945  {&__pyx_n_s_pwcW, __pyx_k_pwcW, sizeof(__pyx_k_pwcW), 0, 0, 1, 1},
14946  {&__pyx_n_s_q_basis_vals, __pyx_k_q_basis_vals, sizeof(__pyx_k_q_basis_vals), 0, 0, 1, 1},
14947  {&__pyx_n_s_q_v, __pyx_k_q_v, sizeof(__pyx_k_q_v), 0, 0, 1, 1},
14948  {&__pyx_n_s_q_vdofs, __pyx_k_q_vdofs, sizeof(__pyx_k_q_vdofs), 0, 0, 1, 1},
14949  {&__pyx_n_s_q_velocity, __pyx_k_q_velocity, sizeof(__pyx_k_q_velocity), 0, 0, 1, 1},
14950  {&__pyx_n_s_quad_a, __pyx_k_quad_a, sizeof(__pyx_k_quad_a), 0, 0, 1, 1},
14951  {&__pyx_n_s_quad_f, __pyx_k_quad_f, sizeof(__pyx_k_quad_f), 0, 0, 1, 1},
14952  {&__pyx_n_s_r, __pyx_k_r, sizeof(__pyx_k_r), 0, 0, 1, 1},
14953  {&__pyx_n_s_range, __pyx_k_range, sizeof(__pyx_k_range), 0, 0, 1, 1},
14954  {&__pyx_n_s_reduce, __pyx_k_reduce, sizeof(__pyx_k_reduce), 0, 0, 1, 1},
14955  {&__pyx_n_s_reduce_cython, __pyx_k_reduce_cython, sizeof(__pyx_k_reduce_cython), 0, 0, 1, 1},
14956  {&__pyx_n_s_reduce_ex, __pyx_k_reduce_ex, sizeof(__pyx_k_reduce_ex), 0, 0, 1, 1},
14957  {&__pyx_n_s_residual, __pyx_k_residual, sizeof(__pyx_k_residual), 0, 0, 1, 1},
14958  {&__pyx_n_s_rowptr, __pyx_k_rowptr, sizeof(__pyx_k_rowptr), 0, 0, 1, 1},
14959  {&__pyx_n_s_rt0potential, __pyx_k_rt0potential, sizeof(__pyx_k_rt0potential), 0, 0, 1, 1},
14960  {&__pyx_n_s_rt0vdofs, __pyx_k_rt0vdofs, sizeof(__pyx_k_rt0vdofs), 0, 0, 1, 1},
14961  {&__pyx_n_s_rt0vdofs_element, __pyx_k_rt0vdofs_element, sizeof(__pyx_k_rt0vdofs_element), 0, 0, 1, 1},
14962  {&__pyx_n_s_setstate, __pyx_k_setstate, sizeof(__pyx_k_setstate), 0, 0, 1, 1},
14963  {&__pyx_n_s_setstate_cython, __pyx_k_setstate_cython, sizeof(__pyx_k_setstate_cython), 0, 0, 1, 1},
14964  {&__pyx_n_s_size, __pyx_k_size, sizeof(__pyx_k_size), 0, 0, 1, 1},
14965  {&__pyx_n_s_skipflag_elementBoundaries, __pyx_k_skipflag_elementBoundaries, sizeof(__pyx_k_skipflag_elementBoundaries), 0, 0, 1, 1},
14966  {&__pyx_n_s_solveLocalBDM1projection, __pyx_k_solveLocalBDM1projection, sizeof(__pyx_k_solveLocalBDM1projection), 0, 0, 1, 1},
14967  {&__pyx_n_s_solveLocalBDM1projectionFromFlux, __pyx_k_solveLocalBDM1projectionFromFlux, sizeof(__pyx_k_solveLocalBDM1projectionFromFlux), 0, 0, 1, 1},
14968  {&__pyx_n_s_solveLocalBDM2projection, __pyx_k_solveLocalBDM2projection, sizeof(__pyx_k_solveLocalBDM2projection), 0, 0, 1, 1},
14969  {&__pyx_n_s_sqrt_det_g, __pyx_k_sqrt_det_g, sizeof(__pyx_k_sqrt_det_g), 0, 0, 1, 1},
14970  {&__pyx_n_s_subdomain_U, __pyx_k_subdomain_U, sizeof(__pyx_k_subdomain_U), 0, 0, 1, 1},
14971  {&__pyx_n_s_subdomain_U_copy_global2local, __pyx_k_subdomain_U_copy_global2local, sizeof(__pyx_k_subdomain_U_copy_global2local), 0, 0, 1, 1},
14972  {&__pyx_n_s_subdomain_U_copy_local2global, __pyx_k_subdomain_U_copy_local2global, sizeof(__pyx_k_subdomain_U_copy_local2global), 0, 0, 1, 1},
14973  {&__pyx_n_s_sunWheelerGSsweep, __pyx_k_sunWheelerGSsweep, sizeof(__pyx_k_sunWheelerGSsweep), 0, 0, 1, 1},
14974  {&__pyx_n_s_test, __pyx_k_test, sizeof(__pyx_k_test), 0, 0, 1, 1},
14975  {&__pyx_n_s_u, __pyx_k_u, sizeof(__pyx_k_u), 0, 0, 1, 1},
14976  {&__pyx_n_s_uQuadratureWeights_element, __pyx_k_uQuadratureWeights_element, sizeof(__pyx_k_uQuadratureWeights_element), 0, 0, 1, 1},
14977  {&__pyx_n_s_uQuadratureWeights_elementBounda, __pyx_k_uQuadratureWeights_elementBounda, sizeof(__pyx_k_uQuadratureWeights_elementBounda), 0, 0, 1, 1},
14978  {&__pyx_n_s_u_elementBoundary, __pyx_k_u_elementBoundary, sizeof(__pyx_k_u_elementBoundary), 0, 0, 1, 1},
14979  {&__pyx_n_s_updateAdvectiveVelocityPointEval, __pyx_k_updateAdvectiveVelocityPointEval, sizeof(__pyx_k_updateAdvectiveVelocityPointEval), 0, 0, 1, 1},
14980  {&__pyx_n_s_updateCoef, __pyx_k_updateCoef, sizeof(__pyx_k_updateCoef), 0, 0, 1, 1},
14981  {&__pyx_n_s_updateDiffusiveVelocityPointEval, __pyx_k_updateDiffusiveVelocityPointEval, sizeof(__pyx_k_updateDiffusiveVelocityPointEval), 0, 0, 1, 1},
14982  {&__pyx_n_s_updateDiffusiveVelocityPointEval_2, __pyx_k_updateDiffusiveVelocityPointEval_2, sizeof(__pyx_k_updateDiffusiveVelocityPointEval_2), 0, 0, 1, 1},
14983  {&__pyx_n_s_updateRT0velocityWithAveragedPot, __pyx_k_updateRT0velocityWithAveragedPot, sizeof(__pyx_k_updateRT0velocityWithAveragedPot), 0, 0, 1, 1},
14984  {&__pyx_n_s_updateRT0velocityWithAveragedPot_2, __pyx_k_updateRT0velocityWithAveragedPot_2, sizeof(__pyx_k_updateRT0velocityWithAveragedPot_2), 0, 0, 1, 1},
14985  {&__pyx_n_s_updateSelectedExteriorElementBou, __pyx_k_updateSelectedExteriorElementBou, sizeof(__pyx_k_updateSelectedExteriorElementBou), 0, 0, 1, 1},
14986  {&__pyx_n_s_vAverage, __pyx_k_vAverage, sizeof(__pyx_k_vAverage), 0, 0, 1, 1},
14987  {&__pyx_n_s_vConservative, __pyx_k_vConservative, sizeof(__pyx_k_vConservative), 0, 0, 1, 1},
14988  {&__pyx_n_s_vConservative_element, __pyx_k_vConservative_element, sizeof(__pyx_k_vConservative_element), 0, 0, 1, 1},
14989  {&__pyx_n_s_v_ebqe, __pyx_k_v_ebqe, sizeof(__pyx_k_v_ebqe), 0, 0, 1, 1},
14990  {&__pyx_n_s_v_element, __pyx_k_v_element, sizeof(__pyx_k_v_element), 0, 0, 1, 1},
14991  {&__pyx_n_s_v_elementBoundary, __pyx_k_v_elementBoundary, sizeof(__pyx_k_v_elementBoundary), 0, 0, 1, 1},
14992  {&__pyx_n_s_v_elementBoundary_global, __pyx_k_v_elementBoundary_global, sizeof(__pyx_k_v_elementBoundary_global), 0, 0, 1, 1},
14993  {&__pyx_n_s_vdofs, __pyx_k_vdofs, sizeof(__pyx_k_vdofs), 0, 0, 1, 1},
14994  {&__pyx_n_s_velocity, __pyx_k_velocity, sizeof(__pyx_k_velocity), 0, 0, 1, 1},
14995  {&__pyx_n_s_velocity_element, __pyx_k_velocity_element, sizeof(__pyx_k_velocity_element), 0, 0, 1, 1},
14996  {&__pyx_n_s_w, __pyx_k_w, sizeof(__pyx_k_w), 0, 0, 1, 1},
14997  {&__pyx_n_s_w_dS_f, __pyx_k_w_dS_f, sizeof(__pyx_k_w_dS_f), 0, 0, 1, 1},
14998  {&__pyx_n_s_w_dV_m, __pyx_k_w_dV_m, sizeof(__pyx_k_w_dV_m), 0, 0, 1, 1},
14999  {&__pyx_n_s_w_dV_r, __pyx_k_w_dV_r, sizeof(__pyx_k_w_dV_r), 0, 0, 1, 1},
15000  {&__pyx_n_s_w_int_div_free, __pyx_k_w_int_div_free, sizeof(__pyx_k_w_int_div_free), 0, 0, 1, 1},
15001  {&__pyx_n_s_w_int_test_grads, __pyx_k_w_int_test_grads, sizeof(__pyx_k_w_int_test_grads), 0, 0, 1, 1},
15002  {&__pyx_n_s_w_interior_divfree, __pyx_k_w_interior_divfree, sizeof(__pyx_k_w_interior_divfree), 0, 0, 1, 1},
15003  {&__pyx_n_s_w_interior_gradients, __pyx_k_w_interior_gradients, sizeof(__pyx_k_w_interior_gradients), 0, 0, 1, 1},
15004  {&__pyx_n_s_x, __pyx_k_x, sizeof(__pyx_k_x), 0, 0, 1, 1},
15005  {&__pyx_n_s_x_ebqe, __pyx_k_x_ebqe, sizeof(__pyx_k_x_ebqe), 0, 0, 1, 1},
15006  {&__pyx_n_s_x_element, __pyx_k_x_element, sizeof(__pyx_k_x_element), 0, 0, 1, 1},
15007  {&__pyx_n_s_x_elementBoundary, __pyx_k_x_elementBoundary, sizeof(__pyx_k_x_elementBoundary), 0, 0, 1, 1},
15008  {&__pyx_n_s_x_elementBoundary_global, __pyx_k_x_elementBoundary_global, sizeof(__pyx_k_x_elementBoundary_global), 0, 0, 1, 1},
15009  {0, 0, 0, 0, 0, 0, 0}
15010 };
15011 static CYTHON_SMALL_CODE int __Pyx_InitCachedBuiltins(void) {
15012  __pyx_builtin_range = __Pyx_GetBuiltinName(__pyx_n_s_range); if (!__pyx_builtin_range) __PYX_ERR(0, 797, __pyx_L1_error)
15013  __pyx_builtin_TypeError = __Pyx_GetBuiltinName(__pyx_n_s_TypeError); if (!__pyx_builtin_TypeError) __PYX_ERR(1, 2, __pyx_L1_error)
15014  __pyx_builtin_ImportError = __Pyx_GetBuiltinName(__pyx_n_s_ImportError); if (!__pyx_builtin_ImportError) __PYX_ERR(2, 945, __pyx_L1_error)
15015  return 0;
15016  __pyx_L1_error:;
15017  return -1;
15018 }
15019 
15020 static CYTHON_SMALL_CODE int __Pyx_InitCachedConstants(void) {
15021  __Pyx_RefNannyDeclarations
15022  __Pyx_RefNannySetupContext("__Pyx_InitCachedConstants", 0);
15023 
15024  /* "(tree fragment)":2
15025  * def __reduce_cython__(self):
15026  * raise TypeError("no default __reduce__ due to non-trivial __cinit__") # <<<<<<<<<<<<<<
15027  * def __setstate_cython__(self, __pyx_state):
15028  * raise TypeError("no default __reduce__ due to non-trivial __cinit__")
15029  */
15030  __pyx_tuple_ = PyTuple_Pack(1, __pyx_kp_s_no_default___reduce___due_to_non); if (unlikely(!__pyx_tuple_)) __PYX_ERR(1, 2, __pyx_L1_error)
15031  __Pyx_GOTREF(__pyx_tuple_);
15032  __Pyx_GIVEREF(__pyx_tuple_);
15033 
15034  /* "(tree fragment)":4
15035  * raise TypeError("no default __reduce__ due to non-trivial __cinit__")
15036  * def __setstate_cython__(self, __pyx_state):
15037  * raise TypeError("no default __reduce__ due to non-trivial __cinit__") # <<<<<<<<<<<<<<
15038  */
15039  __pyx_tuple__2 = PyTuple_Pack(1, __pyx_kp_s_no_default___reduce___due_to_non); if (unlikely(!__pyx_tuple__2)) __PYX_ERR(1, 4, __pyx_L1_error)
15040  __Pyx_GOTREF(__pyx_tuple__2);
15041  __Pyx_GIVEREF(__pyx_tuple__2);
15042 
15043  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":945
15044  * __pyx_import_array()
15045  * except Exception:
15046  * raise ImportError("numpy.core.multiarray failed to import") # <<<<<<<<<<<<<<
15047  *
15048  * cdef inline int import_umath() except -1:
15049  */
15050  __pyx_tuple__3 = PyTuple_Pack(1, __pyx_kp_s_numpy_core_multiarray_failed_to); if (unlikely(!__pyx_tuple__3)) __PYX_ERR(2, 945, __pyx_L1_error)
15051  __Pyx_GOTREF(__pyx_tuple__3);
15052  __Pyx_GIVEREF(__pyx_tuple__3);
15053 
15054  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":951
15055  * _import_umath()
15056  * except Exception:
15057  * raise ImportError("numpy.core.umath failed to import") # <<<<<<<<<<<<<<
15058  *
15059  * cdef inline int import_ufunc() except -1:
15060  */
15061  __pyx_tuple__4 = PyTuple_Pack(1, __pyx_kp_s_numpy_core_umath_failed_to_impor); if (unlikely(!__pyx_tuple__4)) __PYX_ERR(2, 951, __pyx_L1_error)
15062  __Pyx_GOTREF(__pyx_tuple__4);
15063  __Pyx_GIVEREF(__pyx_tuple__4);
15064 
15065  /* "cpostprocessing.pyx":6
15066  * cimport postprocessing as pp
15067  *
15068  * def postProcessRT0velocityFromP1nc(np.ndarray nFreeDOF_element, # <<<<<<<<<<<<<<
15069  * np.ndarray freeLocal_element,
15070  * np.ndarray detJ,
15071  */
15072  __pyx_tuple__5 = PyTuple_Pack(17, __pyx_n_s_nFreeDOF_element, __pyx_n_s_freeLocal_element, __pyx_n_s_detJ, __pyx_n_s_sqrt_det_g, __pyx_n_s_n, __pyx_n_s_elementBarycenters, __pyx_n_s_quad_a, __pyx_n_s_quad_f, __pyx_n_s_w_dV_r, __pyx_n_s_u, __pyx_n_s_gradu, __pyx_n_s_a, __pyx_n_s_f, __pyx_n_s_r, __pyx_n_s_rt0vdofs, __pyx_n_s_w_dV_m, __pyx_n_s_mt); if (unlikely(!__pyx_tuple__5)) __PYX_ERR(0, 6, __pyx_L1_error)
15073  __Pyx_GOTREF(__pyx_tuple__5);
15074  __Pyx_GIVEREF(__pyx_tuple__5);
15075  __pyx_codeobj__6 = (PyObject*)__Pyx_PyCode_New(17, 0, 17, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__5, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_postProcessRT0velocityFromP1nc, 6, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__6)) __PYX_ERR(0, 6, __pyx_L1_error)
15076 
15077  /* "cpostprocessing.pyx":70
15078  * <double*>(rt0vdofs.data))
15079  *
15080  * def postProcessRT0velocityFromP1nc_sd(np.ndarray rowptr, # <<<<<<<<<<<<<<
15081  * np.ndarray colind,
15082  * np.ndarray nFreeDOF_element,
15083  */
15084  __pyx_tuple__7 = PyTuple_Pack(19, __pyx_n_s_rowptr, __pyx_n_s_colind, __pyx_n_s_nFreeDOF_element, __pyx_n_s_freeLocal_element, __pyx_n_s_detJ, __pyx_n_s_sqrt_det_g, __pyx_n_s_n, __pyx_n_s_elementBarycenters, __pyx_n_s_quad_a, __pyx_n_s_quad_f, __pyx_n_s_w_dV_r, __pyx_n_s_u, __pyx_n_s_gradu, __pyx_n_s_a, __pyx_n_s_f, __pyx_n_s_r, __pyx_n_s_rt0vdofs, __pyx_n_s_w_dV_m, __pyx_n_s_mt); if (unlikely(!__pyx_tuple__7)) __PYX_ERR(0, 70, __pyx_L1_error)
15085  __Pyx_GOTREF(__pyx_tuple__7);
15086  __Pyx_GIVEREF(__pyx_tuple__7);
15087  __pyx_codeobj__8 = (PyObject*)__Pyx_PyCode_New(19, 0, 19, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__7, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_postProcessRT0velocityFromP1nc_s, 70, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__8)) __PYX_ERR(0, 70, __pyx_L1_error)
15088 
15089  /* "cpostprocessing.pyx":140
15090  * <double*>(rt0vdofs.data))
15091  *
15092  * def updateRT0velocityWithAveragedPotentialP1nc(np.ndarray detJ, # <<<<<<<<<<<<<<
15093  * np.ndarray quad_a,
15094  * np.ndarray phi,
15095  */
15096  __pyx_tuple__9 = PyTuple_Pack(6, __pyx_n_s_detJ, __pyx_n_s_quad_a, __pyx_n_s_phi, __pyx_n_s_gradphi, __pyx_n_s_a, __pyx_n_s_rt0vdofs_element); if (unlikely(!__pyx_tuple__9)) __PYX_ERR(0, 140, __pyx_L1_error)
15097  __Pyx_GOTREF(__pyx_tuple__9);
15098  __Pyx_GIVEREF(__pyx_tuple__9);
15099  __pyx_codeobj__10 = (PyObject*)__Pyx_PyCode_New(6, 0, 6, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__9, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_updateRT0velocityWithAveragedPot, 140, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__10)) __PYX_ERR(0, 140, __pyx_L1_error)
15100 
15101  /* "cpostprocessing.pyx":156
15102  * <double*>(rt0vdofs_element.data))
15103  *
15104  * def updateRT0velocityWithAveragedPotentialP1nc_sd(np.ndarray rowptr, # <<<<<<<<<<<<<<
15105  * np.ndarray colind,
15106  * np.ndarray detJ,
15107  */
15108  __pyx_tuple__11 = PyTuple_Pack(8, __pyx_n_s_rowptr, __pyx_n_s_colind, __pyx_n_s_detJ, __pyx_n_s_quad_a, __pyx_n_s_phi, __pyx_n_s_gradphi, __pyx_n_s_a, __pyx_n_s_rt0vdofs_element); if (unlikely(!__pyx_tuple__11)) __PYX_ERR(0, 156, __pyx_L1_error)
15109  __Pyx_GOTREF(__pyx_tuple__11);
15110  __Pyx_GIVEREF(__pyx_tuple__11);
15111  __pyx_codeobj__12 = (PyObject*)__Pyx_PyCode_New(8, 0, 8, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__11, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_updateRT0velocityWithAveragedPot_2, 156, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__12)) __PYX_ERR(0, 156, __pyx_L1_error)
15112 
15113  /* "cpostprocessing.pyx":176
15114  * <double*>(rt0vdofs_element.data))
15115  *
15116  * def getElementRT0velocityValues(np.ndarray x_element, # <<<<<<<<<<<<<<
15117  * np.ndarray rt0vdofs_element,
15118  * np.ndarray v_element):
15119  */
15120  __pyx_tuple__13 = PyTuple_Pack(3, __pyx_n_s_x_element, __pyx_n_s_rt0vdofs_element, __pyx_n_s_v_element); if (unlikely(!__pyx_tuple__13)) __PYX_ERR(0, 176, __pyx_L1_error)
15121  __Pyx_GOTREF(__pyx_tuple__13);
15122  __Pyx_GIVEREF(__pyx_tuple__13);
15123  __pyx_codeobj__14 = (PyObject*)__Pyx_PyCode_New(3, 0, 3, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__13, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_getElementRT0velocityValues, 176, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__14)) __PYX_ERR(0, 176, __pyx_L1_error)
15124 
15125  /* "cpostprocessing.pyx":186
15126  * <double*>(v_element.data))
15127  *
15128  * def getElementBoundaryRT0velocityValues(np.ndarray x_elementBoundary, # <<<<<<<<<<<<<<
15129  * np.ndarray rt0vdofs_element,
15130  * np.ndarray v_elementBoundary):
15131  */
15132  __pyx_tuple__15 = PyTuple_Pack(3, __pyx_n_s_x_elementBoundary, __pyx_n_s_rt0vdofs_element, __pyx_n_s_v_elementBoundary); if (unlikely(!__pyx_tuple__15)) __PYX_ERR(0, 186, __pyx_L1_error)
15133  __Pyx_GOTREF(__pyx_tuple__15);
15134  __Pyx_GIVEREF(__pyx_tuple__15);
15135  __pyx_codeobj__16 = (PyObject*)__Pyx_PyCode_New(3, 0, 3, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__15, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_getElementBoundaryRT0velocityVal, 186, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__16)) __PYX_ERR(0, 186, __pyx_L1_error)
15136 
15137  /* "cpostprocessing.pyx":197
15138  * <double*>(v_elementBoundary.data))
15139  *
15140  * def getGlobalElementBoundaryRT0velocityValues(np.ndarray elementBoundaryElementsArray, # <<<<<<<<<<<<<<
15141  * np.ndarray x_elementBoundary_global,
15142  * np.ndarray rt0vdofs_element,
15143  */
15144  __pyx_tuple__17 = PyTuple_Pack(4, __pyx_n_s_elementBoundaryElementsArray, __pyx_n_s_x_elementBoundary_global, __pyx_n_s_rt0vdofs_element, __pyx_n_s_v_elementBoundary_global); if (unlikely(!__pyx_tuple__17)) __PYX_ERR(0, 197, __pyx_L1_error)
15145  __Pyx_GOTREF(__pyx_tuple__17);
15146  __Pyx_GIVEREF(__pyx_tuple__17);
15147  __pyx_codeobj__18 = (PyObject*)__Pyx_PyCode_New(4, 0, 4, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__17, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_getGlobalElementBoundaryRT0veloc, 197, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__18)) __PYX_ERR(0, 197, __pyx_L1_error)
15148 
15149  /* "cpostprocessing.pyx":209
15150  * <double*>(v_elementBoundary_global.data))
15151  *
15152  * def getGlobalExteriorElementBoundaryRT0velocityValues(np.ndarray exteriorElementBoundariesArray, # <<<<<<<<<<<<<<
15153  * np.ndarray elementBoundaryElementsArray,
15154  * np.ndarray x_elementBoundary_global,
15155  */
15156  __pyx_tuple__19 = PyTuple_Pack(5, __pyx_n_s_exteriorElementBoundariesArray, __pyx_n_s_elementBoundaryElementsArray, __pyx_n_s_x_elementBoundary_global, __pyx_n_s_rt0vdofs_element, __pyx_n_s_v_elementBoundary_global); if (unlikely(!__pyx_tuple__19)) __PYX_ERR(0, 209, __pyx_L1_error)
15157  __Pyx_GOTREF(__pyx_tuple__19);
15158  __Pyx_GIVEREF(__pyx_tuple__19);
15159  __pyx_codeobj__20 = (PyObject*)__Pyx_PyCode_New(5, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__19, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_getGlobalExteriorElementBoundary, 209, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__20)) __PYX_ERR(0, 209, __pyx_L1_error)
15160 
15161  /* "cpostprocessing.pyx":223
15162  * <double*>(v_elementBoundary_global.data))
15163  *
15164  * def postProcessRT0potentialFromP1nc(np.ndarray uQuadratureWeights_element, # <<<<<<<<<<<<<<
15165  * np.ndarray elementBarycenters,
15166  * np.ndarray aElementQuadWeights,
15167  */
15168  __pyx_tuple__21 = PyTuple_Pack(16, __pyx_n_s_uQuadratureWeights_element, __pyx_n_s_elementBarycenters, __pyx_n_s_aElementQuadWeights, __pyx_n_s_detJ, __pyx_n_s_uQuadratureWeights_elementBounda, __pyx_n_s_x, __pyx_n_s_u, __pyx_n_s_gradu, __pyx_n_s_x_elementBoundary, __pyx_n_s_u_elementBoundary, __pyx_n_s_n, __pyx_n_s_a, __pyx_n_s_f, __pyx_n_s_r, __pyx_n_s_rt0vdofs, __pyx_n_s_rt0potential); if (unlikely(!__pyx_tuple__21)) __PYX_ERR(0, 223, __pyx_L1_error)
15169  __Pyx_GOTREF(__pyx_tuple__21);
15170  __Pyx_GIVEREF(__pyx_tuple__21);
15171  __pyx_codeobj__22 = (PyObject*)__Pyx_PyCode_New(16, 0, 16, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__21, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_postProcessRT0potentialFromP1nc, 223, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__22)) __PYX_ERR(0, 223, __pyx_L1_error)
15172 
15173  /* "cpostprocessing.pyx":261
15174  * <double*>(rt0potential.data))
15175  *
15176  * def postProcessRT0potentialFromP1nc_sd(np.ndarray rowptr, # <<<<<<<<<<<<<<
15177  * np.ndarray colind,
15178  * np.ndarray uQuadratureWeights_element,
15179  */
15180  __pyx_tuple__23 = PyTuple_Pack(18, __pyx_n_s_rowptr, __pyx_n_s_colind, __pyx_n_s_uQuadratureWeights_element, __pyx_n_s_elementBarycenters, __pyx_n_s_aElementQuadWeights, __pyx_n_s_detJ, __pyx_n_s_uQuadratureWeights_elementBounda, __pyx_n_s_x, __pyx_n_s_u, __pyx_n_s_gradu, __pyx_n_s_x_elementBoundary, __pyx_n_s_u_elementBoundary, __pyx_n_s_n, __pyx_n_s_a, __pyx_n_s_f, __pyx_n_s_r, __pyx_n_s_rt0vdofs, __pyx_n_s_rt0potential); if (unlikely(!__pyx_tuple__23)) __PYX_ERR(0, 261, __pyx_L1_error)
15181  __Pyx_GOTREF(__pyx_tuple__23);
15182  __Pyx_GIVEREF(__pyx_tuple__23);
15183  __pyx_codeobj__24 = (PyObject*)__Pyx_PyCode_New(18, 0, 18, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__23, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_postProcessRT0potentialFromP1nc_2, 261, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__24)) __PYX_ERR(0, 261, __pyx_L1_error)
15184 
15185  /* "cpostprocessing.pyx":303
15186  * <double*>(rt0potential.data))
15187  *
15188  * def buildLocalBDM1projectionMatrices(np.ndarray w_dS_f, # <<<<<<<<<<<<<<
15189  * np.ndarray ebq_n,
15190  * np.ndarray ebq_v,
15191  */
15192  __pyx_tuple__25 = PyTuple_Pack(4, __pyx_n_s_w_dS_f, __pyx_n_s_ebq_n, __pyx_n_s_ebq_v, __pyx_n_s_BDMmat_element); if (unlikely(!__pyx_tuple__25)) __PYX_ERR(0, 303, __pyx_L1_error)
15193  __Pyx_GOTREF(__pyx_tuple__25);
15194  __Pyx_GIVEREF(__pyx_tuple__25);
15195  __pyx_codeobj__26 = (PyObject*)__Pyx_PyCode_New(4, 0, 4, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__25, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_buildLocalBDM1projectionMatrices, 303, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__26)) __PYX_ERR(0, 303, __pyx_L1_error)
15196 
15197  /* "cpostprocessing.pyx":319
15198  * <double*>(BDMmat_element.data))
15199  *
15200  * def buildLocalBDM2projectionMatrices(int degree, # <<<<<<<<<<<<<<
15201  * np.ndarray w_dS_f,
15202  * np.ndarray ebq_n,
15203  */
15204  __pyx_tuple__27 = PyTuple_Pack(10, __pyx_n_s_degree, __pyx_n_s_w_dS_f, __pyx_n_s_ebq_n, __pyx_n_s_ebq_v, __pyx_n_s_q_basis_vals, __pyx_n_s_w_int_test_grads, __pyx_n_s_w_int_div_free, __pyx_n_s_piola_trial_fun, __pyx_n_s_edgeFlags, __pyx_n_s_BDMmat_element); if (unlikely(!__pyx_tuple__27)) __PYX_ERR(0, 319, __pyx_L1_error)
15205  __Pyx_GOTREF(__pyx_tuple__27);
15206  __Pyx_GIVEREF(__pyx_tuple__27);
15207  __pyx_codeobj__28 = (PyObject*)__Pyx_PyCode_New(10, 0, 10, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__27, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_buildLocalBDM2projectionMatrices, 319, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__28)) __PYX_ERR(0, 319, __pyx_L1_error)
15208 
15209  /* "cpostprocessing.pyx":349
15210  * <double*>(piola_trial_fun.data))
15211  *
15212  * def factorLocalBDM1projectionMatrices(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
15213  * np.ndarray BDMmatPivots_element):
15214  * pp.factorLocalBDM1projectionMatrices(BDMmat_element.shape[0],
15215  */
15216  __pyx_tuple__29 = PyTuple_Pack(2, __pyx_n_s_BDMmat_element, __pyx_n_s_BDMmatPivots_element); if (unlikely(!__pyx_tuple__29)) __PYX_ERR(0, 349, __pyx_L1_error)
15217  __Pyx_GOTREF(__pyx_tuple__29);
15218  __Pyx_GIVEREF(__pyx_tuple__29);
15219  __pyx_codeobj__30 = (PyObject*)__Pyx_PyCode_New(2, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__29, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_factorLocalBDM1projectionMatrice, 349, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__30)) __PYX_ERR(0, 349, __pyx_L1_error)
15220 
15221  /* "cpostprocessing.pyx":356
15222  * <int*>(BDMmatPivots_element.data))
15223  *
15224  * def factorLocalBDM2projectionMatrices(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
15225  * np.ndarray BDMmatPivots_element):
15226  * pp.factorLocalBDM2projectionMatrices(BDMmat_element.shape[0],
15227  */
15228  __pyx_tuple__31 = PyTuple_Pack(2, __pyx_n_s_BDMmat_element, __pyx_n_s_BDMmatPivots_element); if (unlikely(!__pyx_tuple__31)) __PYX_ERR(0, 356, __pyx_L1_error)
15229  __Pyx_GOTREF(__pyx_tuple__31);
15230  __Pyx_GIVEREF(__pyx_tuple__31);
15231  __pyx_codeobj__32 = (PyObject*)__Pyx_PyCode_New(2, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__31, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_factorLocalBDM2projectionMatrice, 356, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__32)) __PYX_ERR(0, 356, __pyx_L1_error)
15232 
15233  /* "cpostprocessing.pyx":363
15234  * <int*>(BDMmatPivots_element.data))
15235  *
15236  * def solveLocalBDM1projection(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
15237  * np.ndarray BDMmatPivots_element,
15238  * np.ndarray w_dS_f,
15239  */
15240  __pyx_tuple__33 = PyTuple_Pack(6, __pyx_n_s_BDMmat_element, __pyx_n_s_BDMmatPivots_element, __pyx_n_s_w_dS_f, __pyx_n_s_ebq_n, __pyx_n_s_ebq_velocity, __pyx_n_s_q_vdofs); if (unlikely(!__pyx_tuple__33)) __PYX_ERR(0, 363, __pyx_L1_error)
15241  __Pyx_GOTREF(__pyx_tuple__33);
15242  __Pyx_GIVEREF(__pyx_tuple__33);
15243  __pyx_codeobj__34 = (PyObject*)__Pyx_PyCode_New(6, 0, 6, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__33, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_solveLocalBDM1projection, 363, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__34)) __PYX_ERR(0, 363, __pyx_L1_error)
15244 
15245  /* "cpostprocessing.pyx":382
15246  * <double*>(q_vdofs.data))
15247  *
15248  * def solveLocalBDM2projection(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
15249  * np.ndarray BDMmatPivots_element,
15250  * np.ndarray w_dS_f,
15251  */
15252  __pyx_tuple__35 = PyTuple_Pack(8, __pyx_n_s_BDMmat_element, __pyx_n_s_BDMmatPivots_element, __pyx_n_s_w_dS_f, __pyx_n_s_ebq_n, __pyx_n_s_w_interior_gradients, __pyx_n_s_ebq_velocity, __pyx_n_s_q_velocity, __pyx_n_s_q_vdofs); if (unlikely(!__pyx_tuple__35)) __PYX_ERR(0, 382, __pyx_L1_error)
15253  __Pyx_GOTREF(__pyx_tuple__35);
15254  __Pyx_GIVEREF(__pyx_tuple__35);
15255  __pyx_codeobj__36 = (PyObject*)__Pyx_PyCode_New(8, 0, 8, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__35, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_solveLocalBDM2projection, 382, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__36)) __PYX_ERR(0, 382, __pyx_L1_error)
15256 
15257  /* "cpostprocessing.pyx":405
15258  * <double*>(q_vdofs.data))
15259  *
15260  * def buildBDM2rhs(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
15261  * np.ndarray BDMmatPivots_element,
15262  * np.ndarray w_dS_f,
15263  */
15264  __pyx_tuple__37 = PyTuple_Pack(10, __pyx_n_s_BDMmat_element, __pyx_n_s_BDMmatPivots_element, __pyx_n_s_w_dS_f, __pyx_n_s_ebq_n, __pyx_n_s_w_interior_gradients, __pyx_n_s_w_interior_divfree, __pyx_n_s_ebq_velocity, __pyx_n_s_q_velocity, __pyx_n_s_q_vdofs, __pyx_n_s_edgeFlags); if (unlikely(!__pyx_tuple__37)) __PYX_ERR(0, 405, __pyx_L1_error)
15265  __Pyx_GOTREF(__pyx_tuple__37);
15266  __Pyx_GIVEREF(__pyx_tuple__37);
15267  __pyx_codeobj__38 = (PyObject*)__Pyx_PyCode_New(10, 0, 10, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__37, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_buildBDM2rhs, 405, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__38)) __PYX_ERR(0, 405, __pyx_L1_error)
15268 
15269  /* "cpostprocessing.pyx":434
15270  * <double*>(q_vdofs.data))
15271  *
15272  * def solveLocalBDM1projectionFromFlux(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
15273  * np.ndarray BDMmatPivots_element,
15274  * np.ndarray elementBoundaryElementsArray,
15275  */
15276  __pyx_tuple__39 = PyTuple_Pack(7, __pyx_n_s_BDMmat_element, __pyx_n_s_BDMmatPivots_element, __pyx_n_s_elementBoundaryElementsArray, __pyx_n_s_elementBoundariesArray, __pyx_n_s_w_dS_f, __pyx_n_s_ebq_global_flux, __pyx_n_s_q_vdofs); if (unlikely(!__pyx_tuple__39)) __PYX_ERR(0, 434, __pyx_L1_error)
15277  __Pyx_GOTREF(__pyx_tuple__39);
15278  __Pyx_GIVEREF(__pyx_tuple__39);
15279  __pyx_codeobj__40 = (PyObject*)__Pyx_PyCode_New(7, 0, 7, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__39, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_solveLocalBDM1projectionFromFlux, 434, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__40)) __PYX_ERR(0, 434, __pyx_L1_error)
15280 
15281  /* "cpostprocessing.pyx":454
15282  * <double*>(q_vdofs.data))
15283  *
15284  * def getElementBDM1velocityValuesLagrangeRep(np.ndarray q_v, # <<<<<<<<<<<<<<
15285  * np.ndarray p1_vdofs,
15286  * np.ndarray q_velocity):
15287  */
15288  __pyx_tuple__41 = PyTuple_Pack(4, __pyx_n_s_q_v, __pyx_n_s_p1_vdofs, __pyx_n_s_q_velocity, __pyx_n_s_nVDOFs_element); if (unlikely(!__pyx_tuple__41)) __PYX_ERR(0, 454, __pyx_L1_error)
15289  __Pyx_GOTREF(__pyx_tuple__41);
15290  __Pyx_GIVEREF(__pyx_tuple__41);
15291  __pyx_codeobj__42 = (PyObject*)__Pyx_PyCode_New(3, 0, 4, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__41, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_getElementBDM1velocityValuesLagr, 454, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__42)) __PYX_ERR(0, 454, __pyx_L1_error)
15292 
15293  /* "cpostprocessing.pyx":470
15294  * <double*>(q_velocity.data))
15295  *
15296  * def getElementBDM2velocityValuesLagrangeRep(np.ndarray q_v, # <<<<<<<<<<<<<<
15297  * np.ndarray p1_vdofs,
15298  * np.ndarray q_velocity):
15299  */
15300  __pyx_tuple__43 = PyTuple_Pack(4, __pyx_n_s_q_v, __pyx_n_s_p1_vdofs, __pyx_n_s_q_velocity, __pyx_n_s_nVDOFs_element); if (unlikely(!__pyx_tuple__43)) __PYX_ERR(0, 470, __pyx_L1_error)
15301  __Pyx_GOTREF(__pyx_tuple__43);
15302  __Pyx_GIVEREF(__pyx_tuple__43);
15303  __pyx_codeobj__44 = (PyObject*)__Pyx_PyCode_New(3, 0, 4, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__43, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_getElementBDM2velocityValuesLagr, 470, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__44)) __PYX_ERR(0, 470, __pyx_L1_error)
15304 
15305  /* "cpostprocessing.pyx":492
15306  * <double*>(q_velocity.data))
15307  *
15308  * def getElementLDGvelocityValuesLagrangeRep(np.ndarray q_v, # <<<<<<<<<<<<<<
15309  * np.ndarray vdofs,
15310  * np.ndarray q_velocity):
15311  */
15312  __pyx_tuple__45 = PyTuple_Pack(5, __pyx_n_s_q_v, __pyx_n_s_vdofs, __pyx_n_s_q_velocity, __pyx_n_s_nVDOF_element, __pyx_n_s_nDOF_trial_element); if (unlikely(!__pyx_tuple__45)) __PYX_ERR(0, 492, __pyx_L1_error)
15313  __Pyx_GOTREF(__pyx_tuple__45);
15314  __Pyx_GIVEREF(__pyx_tuple__45);
15315  __pyx_codeobj__46 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__45, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_getElementLDGvelocityValuesLagra, 492, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__46)) __PYX_ERR(0, 492, __pyx_L1_error)
15316 
15317  /* "cpostprocessing.pyx":508
15318  * <double*>(q_velocity.data))
15319  *
15320  * def getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep(np.ndarray elementBoundaryElementsArray, # <<<<<<<<<<<<<<
15321  * np.ndarray exteriorElementBoundariesArray,
15322  * np.ndarray ebqe_v,
15323  */
15324  __pyx_tuple__47 = PyTuple_Pack(6, __pyx_n_s_elementBoundaryElementsArray, __pyx_n_s_exteriorElementBoundariesArray, __pyx_n_s_ebqe_v, __pyx_n_s_p1_vdofs, __pyx_n_s_ebqe_velocity, __pyx_n_s_nVDOFs_element); if (unlikely(!__pyx_tuple__47)) __PYX_ERR(0, 508, __pyx_L1_error)
15325  __Pyx_GOTREF(__pyx_tuple__47);
15326  __Pyx_GIVEREF(__pyx_tuple__47);
15327  __pyx_codeobj__48 = (PyObject*)__Pyx_PyCode_New(5, 0, 6, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__47, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_getGlobalExteriorElementBoundary_2, 508, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__48)) __PYX_ERR(0, 508, __pyx_L1_error)
15328 
15329  /* "cpostprocessing.pyx":527
15330  * <double*>(ebqe_velocity.data))
15331  *
15332  * def getGlobalElementBoundaryBDM1velocityValuesLagrangeRep(np.ndarray elementBoundaryElementsArray, # <<<<<<<<<<<<<<
15333  * np.ndarray exteriorElementBoundariesArray,
15334  * np.ndarray ebqe_v,
15335  */
15336  __pyx_tuple__49 = PyTuple_Pack(6, __pyx_n_s_elementBoundaryElementsArray, __pyx_n_s_exteriorElementBoundariesArray, __pyx_n_s_ebqe_v, __pyx_n_s_p1_vdofs, __pyx_n_s_ebq_global_velocity, __pyx_n_s_nVDOFs_element); if (unlikely(!__pyx_tuple__49)) __PYX_ERR(0, 527, __pyx_L1_error)
15337  __Pyx_GOTREF(__pyx_tuple__49);
15338  __Pyx_GIVEREF(__pyx_tuple__49);
15339  __pyx_codeobj__50 = (PyObject*)__Pyx_PyCode_New(5, 0, 6, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__49, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_getGlobalElementBoundaryBDM1velo, 527, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__50)) __PYX_ERR(0, 527, __pyx_L1_error)
15340 
15341  /* "cpostprocessing.pyx":546
15342  * <double*>(ebq_global_velocity.data))
15343  *
15344  * def getElementBoundaryBDM1velocityValuesLagrangeRep(np.ndarray elementBoundaryElementsArray, # <<<<<<<<<<<<<<
15345  * np.ndarray exteriorElementBoundariesArray,
15346  * np.ndarray ebq_v,
15347  */
15348  __pyx_tuple__51 = PyTuple_Pack(6, __pyx_n_s_elementBoundaryElementsArray, __pyx_n_s_exteriorElementBoundariesArray, __pyx_n_s_ebq_v, __pyx_n_s_p1_vdofs, __pyx_n_s_ebq_velocity, __pyx_n_s_nVDOFs_element); if (unlikely(!__pyx_tuple__51)) __PYX_ERR(0, 546, __pyx_L1_error)
15349  __Pyx_GOTREF(__pyx_tuple__51);
15350  __Pyx_GIVEREF(__pyx_tuple__51);
15351  __pyx_codeobj__52 = (PyObject*)__Pyx_PyCode_New(5, 0, 6, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__51, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_getElementBoundaryBDM1velocityVa, 546, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__52)) __PYX_ERR(0, 546, __pyx_L1_error)
15352 
15353  /* "cpostprocessing.pyx":566
15354  * <double*>(ebq_velocity.data))
15355  *
15356  * def projectElementBoundaryVelocityToRT0fluxRep(np.ndarray elementBoundaryQuadratureWeights, # <<<<<<<<<<<<<<
15357  * np.ndarray n,
15358  * np.ndarray v_elementBoundary,
15359  */
15360  __pyx_tuple__53 = PyTuple_Pack(4, __pyx_n_s_elementBoundaryQuadratureWeights, __pyx_n_s_n, __pyx_n_s_v_elementBoundary, __pyx_n_s_rt0vdofs_element); if (unlikely(!__pyx_tuple__53)) __PYX_ERR(0, 566, __pyx_L1_error)
15361  __Pyx_GOTREF(__pyx_tuple__53);
15362  __Pyx_GIVEREF(__pyx_tuple__53);
15363  __pyx_codeobj__54 = (PyObject*)__Pyx_PyCode_New(4, 0, 4, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__53, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_projectElementBoundaryVelocityTo, 566, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__54)) __PYX_ERR(0, 566, __pyx_L1_error)
15364 
15365  /* "cpostprocessing.pyx":579
15366  * <double*>(rt0vdofs_element.data))
15367  *
15368  * def projectElementBoundaryFluxToRT0fluxRep(np.ndarray elementBoundaryElementsArray, # <<<<<<<<<<<<<<
15369  * np.ndarray elementBoundariesArray,
15370  * np.ndarray elementBoundaryQuadratureWeights,
15371  */
15372  __pyx_tuple__55 = PyTuple_Pack(5, __pyx_n_s_elementBoundaryElementsArray, __pyx_n_s_elementBoundariesArray, __pyx_n_s_elementBoundaryQuadratureWeights, __pyx_n_s_flux_elementBoundary, __pyx_n_s_rt0vdofs_element); if (unlikely(!__pyx_tuple__55)) __PYX_ERR(0, 579, __pyx_L1_error)
15373  __Pyx_GOTREF(__pyx_tuple__55);
15374  __Pyx_GIVEREF(__pyx_tuple__55);
15375  __pyx_codeobj__56 = (PyObject*)__Pyx_PyCode_New(5, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__55, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_projectElementBoundaryFluxToRT0f, 579, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__56)) __PYX_ERR(0, 579, __pyx_L1_error)
15376 
15377  /* "cpostprocessing.pyx":594
15378  * <double*>(rt0vdofs_element.data))
15379  *
15380  * def getElementRT0velocityValuesFluxRep(np.ndarray nodeArray, # <<<<<<<<<<<<<<
15381  * np.ndarray elementNodesArray,
15382  * np.ndarray abs_det_J,
15383  */
15384  __pyx_tuple__57 = PyTuple_Pack(6, __pyx_n_s_nodeArray, __pyx_n_s_elementNodesArray, __pyx_n_s_abs_det_J, __pyx_n_s_x_element, __pyx_n_s_rt0vdofs_element, __pyx_n_s_v_element); if (unlikely(!__pyx_tuple__57)) __PYX_ERR(0, 594, __pyx_L1_error)
15385  __Pyx_GOTREF(__pyx_tuple__57);
15386  __Pyx_GIVEREF(__pyx_tuple__57);
15387  __pyx_codeobj__58 = (PyObject*)__Pyx_PyCode_New(6, 0, 6, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__57, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_getElementRT0velocityValuesFluxR, 594, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__58)) __PYX_ERR(0, 594, __pyx_L1_error)
15388 
15389  /* "cpostprocessing.pyx":612
15390  * <double*>(v_element.data))
15391  *
15392  * def getElementBoundaryRT0velocityValuesFluxRep(np.ndarray nodeArray, # <<<<<<<<<<<<<<
15393  * np.ndarray elementNodesArray,
15394  * np.ndarray abs_det_J,
15395  */
15396  __pyx_tuple__59 = PyTuple_Pack(6, __pyx_n_s_nodeArray, __pyx_n_s_elementNodesArray, __pyx_n_s_abs_det_J, __pyx_n_s_x_elementBoundary, __pyx_n_s_rt0vdofs_element, __pyx_n_s_v_elementBoundary); if (unlikely(!__pyx_tuple__59)) __PYX_ERR(0, 612, __pyx_L1_error)
15397  __Pyx_GOTREF(__pyx_tuple__59);
15398  __Pyx_GIVEREF(__pyx_tuple__59);
15399  __pyx_codeobj__60 = (PyObject*)__Pyx_PyCode_New(6, 0, 6, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__59, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_getElementBoundaryRT0velocityVal_2, 612, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__60)) __PYX_ERR(0, 612, __pyx_L1_error)
15400 
15401  /* "cpostprocessing.pyx":630
15402  * <double*>(v_elementBoundary.data))
15403  *
15404  * def getGlobalElementBoundaryRT0velocityValuesFluxRep(np.ndarray nodeArray, # <<<<<<<<<<<<<<
15405  * np.ndarray elementNodesArray,
15406  * np.ndarray elementBoundaryElementsArray,
15407  */
15408  __pyx_tuple__61 = PyTuple_Pack(7, __pyx_n_s_nodeArray, __pyx_n_s_elementNodesArray, __pyx_n_s_elementBoundaryElementsArray, __pyx_n_s_abs_det_J, __pyx_n_s_x_elementBoundary_global, __pyx_n_s_rt0vdofs_element, __pyx_n_s_v_elementBoundary_global); if (unlikely(!__pyx_tuple__61)) __PYX_ERR(0, 630, __pyx_L1_error)
15409  __Pyx_GOTREF(__pyx_tuple__61);
15410  __Pyx_GIVEREF(__pyx_tuple__61);
15411  __pyx_codeobj__62 = (PyObject*)__Pyx_PyCode_New(7, 0, 7, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__61, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_getGlobalElementBoundaryRT0veloc_2, 630, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__62)) __PYX_ERR(0, 630, __pyx_L1_error)
15412 
15413  /* "cpostprocessing.pyx":649
15414  * <double*>(v_elementBoundary_global.data))
15415  *
15416  * def getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep(np.ndarray nodeArray, # <<<<<<<<<<<<<<
15417  * np.ndarray elementNodesArray,
15418  * np.ndarray elementBoundaryElementsArray,
15419  */
15420  __pyx_tuple__63 = PyTuple_Pack(8, __pyx_n_s_nodeArray, __pyx_n_s_elementNodesArray, __pyx_n_s_elementBoundaryElementsArray, __pyx_n_s_exteriorElementBoundariesArray, __pyx_n_s_abs_det_J, __pyx_n_s_x_ebqe, __pyx_n_s_rt0vdofs_element, __pyx_n_s_v_ebqe); if (unlikely(!__pyx_tuple__63)) __PYX_ERR(0, 649, __pyx_L1_error)
15421  __Pyx_GOTREF(__pyx_tuple__63);
15422  __Pyx_GIVEREF(__pyx_tuple__63);
15423  __pyx_codeobj__64 = (PyObject*)__Pyx_PyCode_New(8, 0, 8, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__63, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_getGlobalExteriorElementBoundary_3, 649, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__64)) __PYX_ERR(0, 649, __pyx_L1_error)
15424 
15425  /* "cpostprocessing.pyx":670
15426  * <double*>(v_ebqe.data))
15427  *
15428  * def getRT0velocityValuesFluxRep_arbitraryElementMembership(np.ndarray nodeArray, # <<<<<<<<<<<<<<
15429  * np.ndarray elementNodesArray,
15430  * np.ndarray abs_det_J,
15431  */
15432  __pyx_tuple__65 = PyTuple_Pack(8, __pyx_n_s_nodeArray, __pyx_n_s_elementNodesArray, __pyx_n_s_abs_det_J, __pyx_n_s_x, __pyx_n_s_element_locations, __pyx_n_s_rt0vdofs_element, __pyx_n_s_v_element, __pyx_n_s_nPoints); if (unlikely(!__pyx_tuple__65)) __PYX_ERR(0, 670, __pyx_L1_error)
15433  __Pyx_GOTREF(__pyx_tuple__65);
15434  __Pyx_GIVEREF(__pyx_tuple__65);
15435  __pyx_codeobj__66 = (PyObject*)__Pyx_PyCode_New(7, 0, 8, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__65, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_getRT0velocityValuesFluxRep_arbi, 670, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__66)) __PYX_ERR(0, 670, __pyx_L1_error)
15436 
15437  /* "cpostprocessing.pyx":691
15438  * <double*>(v_element.data))
15439  *
15440  * def fluxCorrectionVelocityUpdate(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
15441  * np.ndarray exteriorElementBoundaries,
15442  * np.ndarray elementBoundaryElements,
15443  */
15444  __pyx_tuple__67 = PyTuple_Pack(9, __pyx_n_s_interiorElementBoundaries, __pyx_n_s_exteriorElementBoundaries, __pyx_n_s_elementBoundaryElements, __pyx_n_s_elementBoundaryLocalElementBound, __pyx_n_s_dS, __pyx_n_s_n, __pyx_n_s_fluxCorrection, __pyx_n_s_velocity, __pyx_n_s_velocity_element); if (unlikely(!__pyx_tuple__67)) __PYX_ERR(0, 691, __pyx_L1_error)
15445  __Pyx_GOTREF(__pyx_tuple__67);
15446  __Pyx_GIVEREF(__pyx_tuple__67);
15447  __pyx_codeobj__68 = (PyObject*)__Pyx_PyCode_New(9, 0, 9, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__67, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_fluxCorrectionVelocityUpdate, 691, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__68)) __PYX_ERR(0, 691, __pyx_L1_error)
15448 
15449  /* "cpostprocessing.pyx":717
15450  * <double*>(velocity_element.data))
15451  *
15452  * def computeFluxCorrectionPWC(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
15453  * np.ndarray exteriorElementBoundaries,
15454  * np.ndarray elementBoundaryElements,
15455  */
15456  __pyx_tuple__69 = PyTuple_Pack(6, __pyx_n_s_interiorElementBoundaries, __pyx_n_s_exteriorElementBoundaries, __pyx_n_s_elementBoundaryElements, __pyx_n_s_pwcW, __pyx_n_s_pwcV, __pyx_n_s_fluxCorrection); if (unlikely(!__pyx_tuple__69)) __PYX_ERR(0, 717, __pyx_L1_error)
15457  __Pyx_GOTREF(__pyx_tuple__69);
15458  __Pyx_GIVEREF(__pyx_tuple__69);
15459  __pyx_codeobj__70 = (PyObject*)__Pyx_PyCode_New(6, 0, 6, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__69, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_computeFluxCorrectionPWC, 717, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__70)) __PYX_ERR(0, 717, __pyx_L1_error)
15460 
15461  /* "cpostprocessing.pyx":733
15462  * <double*>(fluxCorrection.data))
15463  *
15464  * def sunWheelerGSsweep(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
15465  * np.ndarray exteriorElementBoundaries,
15466  * np.ndarray elementBoundaryElements,
15467  */
15468  __pyx_tuple__71 = PyTuple_Pack(10, __pyx_n_s_interiorElementBoundaries, __pyx_n_s_exteriorElementBoundaries, __pyx_n_s_elementBoundaryElements, __pyx_n_s_elementBoundaryLocalElementBound, __pyx_n_s_dS, __pyx_n_s_n, __pyx_n_s_sqrt_det_g, __pyx_n_s_alphaFactor, __pyx_n_s_fluxCorrection, __pyx_n_s_conservationResidual); if (unlikely(!__pyx_tuple__71)) __PYX_ERR(0, 733, __pyx_L1_error)
15469  __Pyx_GOTREF(__pyx_tuple__71);
15470  __Pyx_GIVEREF(__pyx_tuple__71);
15471  __pyx_codeobj__72 = (PyObject*)__Pyx_PyCode_New(10, 0, 10, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__71, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_sunWheelerGSsweep, 733, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__72)) __PYX_ERR(0, 733, __pyx_L1_error)
15472 
15473  /* "cpostprocessing.pyx":818
15474  * &self.nsf.subdomain_column_pivots)
15475  *
15476  * def calculateConservationResidualPWL(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
15477  * np.ndarray exteriorElementBoundaries,
15478  * np.ndarray elementBoundaryElements,
15479  */
15480  __pyx_tuple__73 = PyTuple_Pack(19, __pyx_n_s_interiorElementBoundaries, __pyx_n_s_exteriorElementBoundaries, __pyx_n_s_elementBoundaryElements, __pyx_n_s_elementBoundaryLocalElementBound, __pyx_n_s_elementNodes, __pyx_n_s_dofMapl2g, __pyx_n_s_nodeStarElements, __pyx_n_s_nodeStarElementNeighbors, __pyx_n_s_nElements_node, __pyx_n_s_fluxElementBoundaries, __pyx_n_s_elementResidual, __pyx_n_s_vAverage, __pyx_n_s_dx, __pyx_n_s_w, __pyx_n_s_n, __pyx_n_s_nodeStarFactor, __pyx_n_s_conservationResidual, __pyx_n_s_vConservative, __pyx_n_s_vConservative_element); if (unlikely(!__pyx_tuple__73)) __PYX_ERR(0, 818, __pyx_L1_error)
15481  __Pyx_GOTREF(__pyx_tuple__73);
15482  __Pyx_GIVEREF(__pyx_tuple__73);
15483  __pyx_codeobj__74 = (PyObject*)__Pyx_PyCode_New(19, 0, 19, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__73, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_calculateConservationResidualPWL, 818, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__74)) __PYX_ERR(0, 818, __pyx_L1_error)
15484 
15485  /* "cpostprocessing.pyx":873
15486  * <double*>(vConservative_element.data))
15487  *
15488  * def calculateConservationJacobianPWL(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
15489  * np.ndarray exteriorElementBoundaries,
15490  * np.ndarray elementBoundaryElements,
15491  */
15492  __pyx_tuple__75 = PyTuple_Pack(15, __pyx_n_s_interiorElementBoundaries, __pyx_n_s_exteriorElementBoundaries, __pyx_n_s_elementBoundaryElements, __pyx_n_s_elementBoundaryLocalElementBound, __pyx_n_s_elementNodes, __pyx_n_s_dofMapl2g, __pyx_n_s_dofStarElements, __pyx_n_s_dofStarElementNeighbors, __pyx_n_s_nElements_dof, __pyx_n_s_internalNodes, __pyx_n_s_fluxElementBoundaries, __pyx_n_s_fluxBoundaryNodes, __pyx_n_s_w, __pyx_n_s_n, __pyx_n_s_nodeStarFactor); if (unlikely(!__pyx_tuple__75)) __PYX_ERR(0, 873, __pyx_L1_error)
15493  __Pyx_GOTREF(__pyx_tuple__75);
15494  __Pyx_GIVEREF(__pyx_tuple__75);
15495  __pyx_codeobj__76 = (PyObject*)__Pyx_PyCode_New(15, 0, 15, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__75, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_calculateConservationJacobianPWL, 873, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__76)) __PYX_ERR(0, 873, __pyx_L1_error)
15496 
15497  /* "cpostprocessing.pyx":914
15498  * &nodeStarFactor.nsf)
15499  *
15500  * def calculateConservationFluxPWL(np.ndarray nElements_node, # <<<<<<<<<<<<<<
15501  * np.ndarray internalNodes,
15502  * np.ndarray fluxBoundaryNodes,
15503  */
15504  __pyx_tuple__77 = PyTuple_Pack(4, __pyx_n_s_nElements_node, __pyx_n_s_internalNodes, __pyx_n_s_fluxBoundaryNodes, __pyx_n_s_nodeStarFactor); if (unlikely(!__pyx_tuple__77)) __PYX_ERR(0, 914, __pyx_L1_error)
15505  __Pyx_GOTREF(__pyx_tuple__77);
15506  __Pyx_GIVEREF(__pyx_tuple__77);
15507  __pyx_codeobj__78 = (PyObject*)__Pyx_PyCode_New(4, 0, 4, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__77, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_calculateConservationFluxPWL, 914, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__78)) __PYX_ERR(0, 914, __pyx_L1_error)
15508 
15509  /* "cpostprocessing.pyx":925
15510  * &nodeStarFactor.nsf)
15511  *
15512  * def calculateConservationFluxPWL_noNeumannFix(np.ndarray nElements_node, # <<<<<<<<<<<<<<
15513  * NodeStarFactor nodeStarFactor):
15514  * pp.calculateConservationFluxPWL_noNeumannFix(nElements_node.shape[0],
15515  */
15516  __pyx_tuple__79 = PyTuple_Pack(2, __pyx_n_s_nElements_node, __pyx_n_s_nodeStarFactor); if (unlikely(!__pyx_tuple__79)) __PYX_ERR(0, 925, __pyx_L1_error)
15517  __Pyx_GOTREF(__pyx_tuple__79);
15518  __Pyx_GIVEREF(__pyx_tuple__79);
15519  __pyx_codeobj__80 = (PyObject*)__Pyx_PyCode_New(2, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__79, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_calculateConservationFluxPWL_noN, 925, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__80)) __PYX_ERR(0, 925, __pyx_L1_error)
15520 
15521  /* "cpostprocessing.pyx":931
15522  * &nodeStarFactor.nsf)
15523  *
15524  * def calculateConservationResidualPWL_opt(int nNodes_owned, # <<<<<<<<<<<<<<
15525  * np.ndarray interiorElementBoundaries,
15526  * np.ndarray exteriorElementBoundaries,
15527  */
15528  __pyx_tuple__81 = PyTuple_Pack(19, __pyx_n_s_nNodes_owned, __pyx_n_s_interiorElementBoundaries, __pyx_n_s_exteriorElementBoundaries, __pyx_n_s_elementBoundaryElements, __pyx_n_s_elementBoundaryLocalElementBound, __pyx_n_s_elementNodes, __pyx_n_s_nodeStarElements, __pyx_n_s_nodeStarElementNeighbors, __pyx_n_s_nElements_node, __pyx_n_s_fluxElementBoundaries, __pyx_n_s_elementResidual, __pyx_n_s_vAverage, __pyx_n_s_dx, __pyx_n_s_w, __pyx_n_s_n, __pyx_n_s_nodeStarFactor, __pyx_n_s_conservationResidual, __pyx_n_s_vConservative, __pyx_n_s_vConservative_element); if (unlikely(!__pyx_tuple__81)) __PYX_ERR(0, 931, __pyx_L1_error)
15529  __Pyx_GOTREF(__pyx_tuple__81);
15530  __Pyx_GIVEREF(__pyx_tuple__81);
15531  __pyx_codeobj__82 = (PyObject*)__Pyx_PyCode_New(19, 0, 19, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__81, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_calculateConservationResidualPWL_2, 931, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__82)) __PYX_ERR(0, 931, __pyx_L1_error)
15532 
15533  /* "cpostprocessing.pyx":977
15534  * <double*>(vConservative_element.data))
15535  *
15536  * def calculateConservationResidualPWL_primative(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
15537  * np.ndarray exteriorElementBoundaries,
15538  * np.ndarray elementBoundaryElements,
15539  */
15540  __pyx_tuple__83 = PyTuple_Pack(10, __pyx_n_s_interiorElementBoundaries, __pyx_n_s_exteriorElementBoundaries, __pyx_n_s_elementBoundaryElements, __pyx_n_s_elementBoundaryLocalElementBound, __pyx_n_s_skipflag_elementBoundaries, __pyx_n_s_elementResidual, __pyx_n_s_dx, __pyx_n_s_n, __pyx_n_s_conservationResidual, __pyx_n_s_vConservative); if (unlikely(!__pyx_tuple__83)) __PYX_ERR(0, 977, __pyx_L1_error)
15541  __Pyx_GOTREF(__pyx_tuple__83);
15542  __Pyx_GIVEREF(__pyx_tuple__83);
15543  __pyx_codeobj__84 = (PyObject*)__Pyx_PyCode_New(10, 0, 10, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__83, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_calculateConservationResidualPWL_3, 977, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__84)) __PYX_ERR(0, 977, __pyx_L1_error)
15544 
15545  /* "cpostprocessing.pyx":1005
15546  * <double*>(vConservative.data))
15547  *
15548  * def calculateConservationJacobianPWL_opt(int nNodes_owned, # <<<<<<<<<<<<<<
15549  * np.ndarray interiorElementBoundaries,
15550  * np.ndarray exteriorElementBoundaries,
15551  */
15552  __pyx_tuple__85 = PyTuple_Pack(15, __pyx_n_s_nNodes_owned, __pyx_n_s_interiorElementBoundaries, __pyx_n_s_exteriorElementBoundaries, __pyx_n_s_elementBoundaryElements, __pyx_n_s_elementBoundaryLocalElementBound, __pyx_n_s_elementNodes, __pyx_n_s_nodeStarElements, __pyx_n_s_nodeStarElementNeighbors, __pyx_n_s_nElements_node, __pyx_n_s_internalNodes, __pyx_n_s_fluxElementBoundaries, __pyx_n_s_fluxBoundaryNodes, __pyx_n_s_w, __pyx_n_s_n, __pyx_n_s_nodeStarFactor); if (unlikely(!__pyx_tuple__85)) __PYX_ERR(0, 1005, __pyx_L1_error)
15553  __Pyx_GOTREF(__pyx_tuple__85);
15554  __Pyx_GIVEREF(__pyx_tuple__85);
15555  __pyx_codeobj__86 = (PyObject*)__Pyx_PyCode_New(15, 0, 15, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__85, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_calculateConservationJacobianPWL_2, 1005, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__86)) __PYX_ERR(0, 1005, __pyx_L1_error)
15556 
15557  /* "cpostprocessing.pyx":1045
15558  * &nodeStarFactor.nsf)
15559  *
15560  * def calculateConservationFluxPWL_opt(int nNodes_owned, # <<<<<<<<<<<<<<
15561  * np.ndarray nElements_node,
15562  * np.ndarray internalNodes,
15563  */
15564  __pyx_tuple__87 = PyTuple_Pack(5, __pyx_n_s_nNodes_owned, __pyx_n_s_nElements_node, __pyx_n_s_internalNodes, __pyx_n_s_fluxBoundaryNodes, __pyx_n_s_nodeStarFactor); if (unlikely(!__pyx_tuple__87)) __PYX_ERR(0, 1045, __pyx_L1_error)
15565  __Pyx_GOTREF(__pyx_tuple__87);
15566  __Pyx_GIVEREF(__pyx_tuple__87);
15567  __pyx_codeobj__88 = (PyObject*)__Pyx_PyCode_New(5, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__87, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_calculateConservationFluxPWL_opt, 1045, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__88)) __PYX_ERR(0, 1045, __pyx_L1_error)
15568 
15569  /* "cpostprocessing.pyx":1058
15570  * &nodeStarFactor.nsf)
15571  *
15572  * def calculateConservationResidualPWL_interiorBoundaries(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
15573  * np.ndarray exteriorElementBoundaries,
15574  * np.ndarray elementBoundaryElements,
15575  */
15576  __pyx_tuple__89 = PyTuple_Pack(18, __pyx_n_s_interiorElementBoundaries, __pyx_n_s_exteriorElementBoundaries, __pyx_n_s_elementBoundaryElements, __pyx_n_s_elementBoundaryLocalElementBound, __pyx_n_s_elementNodes, __pyx_n_s_nodeStarElements, __pyx_n_s_nodeStarElementNeighbors, __pyx_n_s_nElements_node, __pyx_n_s_fluxElementBoundaries, __pyx_n_s_elementResidual, __pyx_n_s_vAverage, __pyx_n_s_dx, __pyx_n_s_w, __pyx_n_s_n, __pyx_n_s_nodeStarFactor, __pyx_n_s_conservationResidual, __pyx_n_s_vConservative, __pyx_n_s_vConservative_element); if (unlikely(!__pyx_tuple__89)) __PYX_ERR(0, 1058, __pyx_L1_error)
15577  __Pyx_GOTREF(__pyx_tuple__89);
15578  __Pyx_GIVEREF(__pyx_tuple__89);
15579  __pyx_codeobj__90 = (PyObject*)__Pyx_PyCode_New(18, 0, 18, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__89, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_calculateConservationResidualPWL_4, 1058, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__90)) __PYX_ERR(0, 1058, __pyx_L1_error)
15580 
15581  /* "cpostprocessing.pyx":1103
15582  * <double*>(vConservative_element.data))
15583  *
15584  * def calculateConservationJacobianPWL_interiorBoundaries(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
15585  * np.ndarray exteriorElementBoundaries,
15586  * np.ndarray elementBoundaryElements,
15587  */
15588  __pyx_tuple__91 = PyTuple_Pack(12, __pyx_n_s_interiorElementBoundaries, __pyx_n_s_exteriorElementBoundaries, __pyx_n_s_elementBoundaryElements, __pyx_n_s_elementBoundaryLocalElementBound, __pyx_n_s_elementNodes, __pyx_n_s_nodeStarElements, __pyx_n_s_nodeStarElementNeighbors, __pyx_n_s_nElements_node, __pyx_n_s_fluxElementBoundaries, __pyx_n_s_w, __pyx_n_s_n, __pyx_n_s_nodeStarFactor); if (unlikely(!__pyx_tuple__91)) __PYX_ERR(0, 1103, __pyx_L1_error)
15589  __Pyx_GOTREF(__pyx_tuple__91);
15590  __Pyx_GIVEREF(__pyx_tuple__91);
15591  __pyx_codeobj__92 = (PyObject*)__Pyx_PyCode_New(12, 0, 12, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__91, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_calculateConservationJacobianPWL_3, 1103, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__92)) __PYX_ERR(0, 1103, __pyx_L1_error)
15592 
15593  /* "cpostprocessing.pyx":1137
15594  * &nodeStarFactor.nsf)
15595  *
15596  * def _subdomain_U_copy_global2local(int max_nN_owned, # <<<<<<<<<<<<<<
15597  * np.ndarray elementNodes,
15598  * np.ndarray nodeStarElements,
15599  */
15600  __pyx_tuple__93 = PyTuple_Pack(5, __pyx_n_s_max_nN_owned, __pyx_n_s_elementNodes, __pyx_n_s_nodeStarElements, __pyx_n_s_nodeStarFactor, __pyx_n_s_subdomain_U); if (unlikely(!__pyx_tuple__93)) __PYX_ERR(0, 1137, __pyx_L1_error)
15601  __Pyx_GOTREF(__pyx_tuple__93);
15602  __Pyx_GIVEREF(__pyx_tuple__93);
15603  __pyx_codeobj__94 = (PyObject*)__Pyx_PyCode_New(5, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__93, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_subdomain_U_copy_global2local, 1137, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__94)) __PYX_ERR(0, 1137, __pyx_L1_error)
15604 
15605  /* "cpostprocessing.pyx":1150
15606  * <double*>(subdomain_U.data))
15607  *
15608  * def _subdomain_U_copy_local2global(int max_nN_owned, # <<<<<<<<<<<<<<
15609  * np.ndarray elementNodes,
15610  * np.ndarray nodeStarElements,
15611  */
15612  __pyx_tuple__95 = PyTuple_Pack(5, __pyx_n_s_max_nN_owned, __pyx_n_s_elementNodes, __pyx_n_s_nodeStarElements, __pyx_n_s_nodeStarFactor, __pyx_n_s_subdomain_U); if (unlikely(!__pyx_tuple__95)) __PYX_ERR(0, 1150, __pyx_L1_error)
15613  __Pyx_GOTREF(__pyx_tuple__95);
15614  __Pyx_GIVEREF(__pyx_tuple__95);
15615  __pyx_codeobj__96 = (PyObject*)__Pyx_PyCode_New(5, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__95, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_subdomain_U_copy_local2global, 1150, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__96)) __PYX_ERR(0, 1150, __pyx_L1_error)
15616 
15617  /* "cpostprocessing.pyx":1163
15618  * <double*>(subdomain_U.data))
15619  *
15620  * def calculateConservationResidualGlobalBoundaries(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
15621  * np.ndarray exteriorElementBoundaries,
15622  * np.ndarray elementBoundaryElements,
15623  */
15624  __pyx_tuple__97 = PyTuple_Pack(10, __pyx_n_s_interiorElementBoundaries, __pyx_n_s_exteriorElementBoundaries, __pyx_n_s_elementBoundaryElements, __pyx_n_s_elementBoundaryLocalElementBound, __pyx_n_s_exteriorElementBoundariesToSkip, __pyx_n_s_dS, __pyx_n_s_n, __pyx_n_s_elementResidual, __pyx_n_s_velocity, __pyx_n_s_conservationResidual); if (unlikely(!__pyx_tuple__97)) __PYX_ERR(0, 1163, __pyx_L1_error)
15625  __Pyx_GOTREF(__pyx_tuple__97);
15626  __Pyx_GIVEREF(__pyx_tuple__97);
15627  __pyx_codeobj__98 = (PyObject*)__Pyx_PyCode_New(10, 0, 10, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__97, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_calculateConservationResidualGlo, 1163, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__98)) __PYX_ERR(0, 1163, __pyx_L1_error)
15628 
15629  /* "cpostprocessing.pyx":1191
15630  * <double*>(conservationResidual.data))
15631  *
15632  * def updateSelectedExteriorElementBoundaryFlux(np.ndarray exteriorElementBoundaries, # <<<<<<<<<<<<<<
15633  * np.ndarray elementBoundaryElements,
15634  * np.ndarray elementBoundaryLocalElementBoundaries,
15635  */
15636  __pyx_tuple__99 = PyTuple_Pack(7, __pyx_n_s_exteriorElementBoundaries, __pyx_n_s_elementBoundaryElements, __pyx_n_s_elementBoundaryLocalElementBound, __pyx_n_s_skipflag_elementBoundaries, __pyx_n_s_flux, __pyx_n_s_w, __pyx_n_s_residual); if (unlikely(!__pyx_tuple__99)) __PYX_ERR(0, 1191, __pyx_L1_error)
15637  __Pyx_GOTREF(__pyx_tuple__99);
15638  __Pyx_GIVEREF(__pyx_tuple__99);
15639  __pyx_codeobj__100 = (PyObject*)__Pyx_PyCode_New(7, 0, 7, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__99, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_updateSelectedExteriorElementBou, 1191, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__100)) __PYX_ERR(0, 1191, __pyx_L1_error)
15640 
15641  /* "cpostprocessing.pyx":1210
15642  * <double*>(residual.data))
15643  *
15644  * def updateAdvectiveVelocityPointEval(double updateCoef, # <<<<<<<<<<<<<<
15645  * np.ndarray advectiveVelocity,
15646  * np.ndarray velocity):
15647  */
15648  __pyx_tuple__101 = PyTuple_Pack(4, __pyx_n_s_updateCoef, __pyx_n_s_advectiveVelocity, __pyx_n_s_velocity, __pyx_n_s_nPoints); if (unlikely(!__pyx_tuple__101)) __PYX_ERR(0, 1210, __pyx_L1_error)
15649  __Pyx_GOTREF(__pyx_tuple__101);
15650  __Pyx_GIVEREF(__pyx_tuple__101);
15651  __pyx_codeobj__102 = (PyObject*)__Pyx_PyCode_New(3, 0, 4, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__101, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_updateAdvectiveVelocityPointEval, 1210, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__102)) __PYX_ERR(0, 1210, __pyx_L1_error)
15652 
15653  /* "cpostprocessing.pyx":1220
15654  * <double*>(velocity.data))
15655  *
15656  * def updateDiffusiveVelocityPointEval(double updateCoef, # <<<<<<<<<<<<<<
15657  * np.ndarray diffusionTensor,
15658  * np.ndarray grad_phi,
15659  */
15660  __pyx_tuple__103 = PyTuple_Pack(5, __pyx_n_s_updateCoef, __pyx_n_s_diffusionTensor, __pyx_n_s_grad_phi, __pyx_n_s_velocity, __pyx_n_s_nPoints); if (unlikely(!__pyx_tuple__103)) __PYX_ERR(0, 1220, __pyx_L1_error)
15661  __Pyx_GOTREF(__pyx_tuple__103);
15662  __Pyx_GIVEREF(__pyx_tuple__103);
15663  __pyx_codeobj__104 = (PyObject*)__Pyx_PyCode_New(4, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__103, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_updateDiffusiveVelocityPointEval, 1220, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__104)) __PYX_ERR(0, 1220, __pyx_L1_error)
15664 
15665  /* "cpostprocessing.pyx":1232
15666  * <double*>(velocity.data))
15667  *
15668  * def updateDiffusiveVelocityPointEval_sd(double updateCoef, # <<<<<<<<<<<<<<
15669  * np.ndarray rowptr,
15670  * np.ndarray colind,
15671  */
15672  __pyx_tuple__105 = PyTuple_Pack(7, __pyx_n_s_updateCoef, __pyx_n_s_rowptr, __pyx_n_s_colind, __pyx_n_s_diffusionTensor, __pyx_n_s_grad_phi, __pyx_n_s_velocity, __pyx_n_s_nPoints); if (unlikely(!__pyx_tuple__105)) __PYX_ERR(0, 1232, __pyx_L1_error)
15673  __Pyx_GOTREF(__pyx_tuple__105);
15674  __Pyx_GIVEREF(__pyx_tuple__105);
15675  __pyx_codeobj__106 = (PyObject*)__Pyx_PyCode_New(6, 0, 7, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__105, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_updateDiffusiveVelocityPointEval_2, 1232, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__106)) __PYX_ERR(0, 1232, __pyx_L1_error)
15676 
15677  /* "cpostprocessing.pyx":1248
15678  * <double*>(velocity.data))
15679  *
15680  * def calculateElementResidualPWL(np.ndarray alpha, # <<<<<<<<<<<<<<
15681  * np.ndarray elementResidual,
15682  * np.ndarray elementResidualPWL):
15683  */
15684  __pyx_tuple__107 = PyTuple_Pack(3, __pyx_n_s_alpha, __pyx_n_s_elementResidual, __pyx_n_s_elementResidualPWL); if (unlikely(!__pyx_tuple__107)) __PYX_ERR(0, 1248, __pyx_L1_error)
15685  __Pyx_GOTREF(__pyx_tuple__107);
15686  __Pyx_GIVEREF(__pyx_tuple__107);
15687  __pyx_codeobj__108 = (PyObject*)__Pyx_PyCode_New(3, 0, 3, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__107, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_calculateElementResidualPWL, 1248, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__108)) __PYX_ERR(0, 1248, __pyx_L1_error)
15688 
15689  /* "cpostprocessing.pyx":1258
15690  * <double*>(elementResidualPWL.data))
15691  *
15692  * def copyElementBoundaryVelocityToParVec(np.ndarray ebq_velocity, # <<<<<<<<<<<<<<
15693  * np.ndarray[int, ndim=2] permutations,
15694  * np.ndarray ebq_v_par_local):
15695  */
15696  __pyx_tuple__109 = PyTuple_Pack(9, __pyx_n_s_ebq_velocity, __pyx_n_s_permutations, __pyx_n_s_ebq_v_par_local, __pyx_n_s_ebN, __pyx_n_s_k, __pyx_n_s_I, __pyx_n_s_nElementBoundaries, __pyx_n_s_nQuadraturePoints, __pyx_n_s_nSpace); if (unlikely(!__pyx_tuple__109)) __PYX_ERR(0, 1258, __pyx_L1_error)
15697  __Pyx_GOTREF(__pyx_tuple__109);
15698  __Pyx_GIVEREF(__pyx_tuple__109);
15699  __pyx_codeobj__110 = (PyObject*)__Pyx_PyCode_New(3, 0, 9, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__109, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_copyElementBoundaryVelocityToPar, 1258, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__110)) __PYX_ERR(0, 1258, __pyx_L1_error)
15700 
15701  /* "cpostprocessing.pyx":1272
15702  * ebq_v_par_local[ebN,permutations[ebN,k],I] = ebq_velocity[ebN,k,I]
15703  *
15704  * def addAverageToParVec(np.ndarray ebq_velocityAverage, # <<<<<<<<<<<<<<
15705  * np.ndarray[int, ndim=2] permutations,
15706  * np.ndarray ebq_v_par_local):
15707  */
15708  __pyx_tuple__111 = PyTuple_Pack(9, __pyx_n_s_ebq_velocityAverage, __pyx_n_s_permutations, __pyx_n_s_ebq_v_par_local, __pyx_n_s_ebN, __pyx_n_s_k, __pyx_n_s_I, __pyx_n_s_nElementBoundaries, __pyx_n_s_nQuadraturePoints, __pyx_n_s_nSpace); if (unlikely(!__pyx_tuple__111)) __PYX_ERR(0, 1272, __pyx_L1_error)
15709  __Pyx_GOTREF(__pyx_tuple__111);
15710  __Pyx_GIVEREF(__pyx_tuple__111);
15711  __pyx_codeobj__112 = (PyObject*)__Pyx_PyCode_New(3, 0, 9, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__111, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_addAverageToParVec, 1272, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__112)) __PYX_ERR(0, 1272, __pyx_L1_error)
15712 
15713  /* "cpostprocessing.pyx":1286
15714  * ebq_v_par_local[ebN, permutations[ebN,k], I] += ebq_velocityAverage[ebN, k, I]
15715  *
15716  * def copyParVecToElementBoundaryVelocity(np.ndarray ebq_velocity, # <<<<<<<<<<<<<<
15717  * np.ndarray[int, ndim=2] permutations,
15718  * np.ndarray ebq_v_par_local):
15719  */
15720  __pyx_tuple__113 = PyTuple_Pack(9, __pyx_n_s_ebq_velocity, __pyx_n_s_permutations, __pyx_n_s_ebq_v_par_local, __pyx_n_s_ebN, __pyx_n_s_k, __pyx_n_s_I, __pyx_n_s_nElementBoundaries, __pyx_n_s_nQuadraturePoints, __pyx_n_s_nSpace); if (unlikely(!__pyx_tuple__113)) __PYX_ERR(0, 1286, __pyx_L1_error)
15721  __Pyx_GOTREF(__pyx_tuple__113);
15722  __Pyx_GIVEREF(__pyx_tuple__113);
15723  __pyx_codeobj__114 = (PyObject*)__Pyx_PyCode_New(3, 0, 9, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__113, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cpostprocessing_pyx, __pyx_n_s_copyParVecToElementBoundaryVeloc, 1286, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__114)) __PYX_ERR(0, 1286, __pyx_L1_error)
15724  __Pyx_RefNannyFinishContext();
15725  return 0;
15726  __pyx_L1_error:;
15727  __Pyx_RefNannyFinishContext();
15728  return -1;
15729 }
15730 
15731 static CYTHON_SMALL_CODE int __Pyx_InitGlobals(void) {
15732  if (__Pyx_InitStrings(__pyx_string_tab) < 0) __PYX_ERR(0, 1, __pyx_L1_error);
15733  return 0;
15734  __pyx_L1_error:;
15735  return -1;
15736 }
15737 
15738 static CYTHON_SMALL_CODE int __Pyx_modinit_global_init_code(void); /*proto*/
15739 static CYTHON_SMALL_CODE int __Pyx_modinit_variable_export_code(void); /*proto*/
15740 static CYTHON_SMALL_CODE int __Pyx_modinit_function_export_code(void); /*proto*/
15741 static CYTHON_SMALL_CODE int __Pyx_modinit_type_init_code(void); /*proto*/
15742 static CYTHON_SMALL_CODE int __Pyx_modinit_type_import_code(void); /*proto*/
15743 static CYTHON_SMALL_CODE int __Pyx_modinit_variable_import_code(void); /*proto*/
15744 static CYTHON_SMALL_CODE int __Pyx_modinit_function_import_code(void); /*proto*/
15745 
15746 static int __Pyx_modinit_global_init_code(void) {
15747  __Pyx_RefNannyDeclarations
15748  __Pyx_RefNannySetupContext("__Pyx_modinit_global_init_code", 0);
15749  /*--- Global init code ---*/
15750  __Pyx_RefNannyFinishContext();
15751  return 0;
15752 }
15753 
15754 static int __Pyx_modinit_variable_export_code(void) {
15755  __Pyx_RefNannyDeclarations
15756  __Pyx_RefNannySetupContext("__Pyx_modinit_variable_export_code", 0);
15757  /*--- Variable export code ---*/
15758  __Pyx_RefNannyFinishContext();
15759  return 0;
15760 }
15761 
15762 static int __Pyx_modinit_function_export_code(void) {
15763  __Pyx_RefNannyDeclarations
15764  __Pyx_RefNannySetupContext("__Pyx_modinit_function_export_code", 0);
15765  /*--- Function export code ---*/
15766  __Pyx_RefNannyFinishContext();
15767  return 0;
15768 }
15769 
15770 static int __Pyx_modinit_type_init_code(void) {
15771  __Pyx_RefNannyDeclarations
15772  int __pyx_lineno = 0;
15773  const char *__pyx_filename = NULL;
15774  int __pyx_clineno = 0;
15775  __Pyx_RefNannySetupContext("__Pyx_modinit_type_init_code", 0);
15776  /*--- Type init code ---*/
15777  if (PyType_Ready(&__pyx_type_15cpostprocessing_NodeStarFactor) < 0) __PYX_ERR(0, 762, __pyx_L1_error)
15778  #if PY_VERSION_HEX < 0x030800B1
15779  __pyx_type_15cpostprocessing_NodeStarFactor.tp_print = 0;
15780  #endif
15781  if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_type_15cpostprocessing_NodeStarFactor.tp_dictoffset && __pyx_type_15cpostprocessing_NodeStarFactor.tp_getattro == PyObject_GenericGetAttr)) {
15782  __pyx_type_15cpostprocessing_NodeStarFactor.tp_getattro = __Pyx_PyObject_GenericGetAttr;
15783  }
15784  if (PyObject_SetAttr(__pyx_m, __pyx_n_s_NodeStarFactor, (PyObject *)&__pyx_type_15cpostprocessing_NodeStarFactor) < 0) __PYX_ERR(0, 762, __pyx_L1_error)
15785  if (__Pyx_setup_reduce((PyObject*)&__pyx_type_15cpostprocessing_NodeStarFactor) < 0) __PYX_ERR(0, 762, __pyx_L1_error)
15786  __pyx_ptype_15cpostprocessing_NodeStarFactor = &__pyx_type_15cpostprocessing_NodeStarFactor;
15787  __Pyx_RefNannyFinishContext();
15788  return 0;
15789  __pyx_L1_error:;
15790  __Pyx_RefNannyFinishContext();
15791  return -1;
15792 }
15793 
15794 static int __Pyx_modinit_type_import_code(void) {
15795  __Pyx_RefNannyDeclarations
15796  PyObject *__pyx_t_1 = NULL;
15797  int __pyx_lineno = 0;
15798  const char *__pyx_filename = NULL;
15799  int __pyx_clineno = 0;
15800  __Pyx_RefNannySetupContext("__Pyx_modinit_type_import_code", 0);
15801  /*--- Type import code ---*/
15802  __pyx_t_1 = PyImport_ImportModule(__Pyx_BUILTIN_MODULE_NAME); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 9, __pyx_L1_error)
15803  __Pyx_GOTREF(__pyx_t_1);
15804  __pyx_ptype_7cpython_4type_type = __Pyx_ImportType(__pyx_t_1, __Pyx_BUILTIN_MODULE_NAME, "type",
15805  #if defined(PYPY_VERSION_NUM) && PYPY_VERSION_NUM < 0x050B0000
15806  sizeof(PyTypeObject),
15807  #else
15808  sizeof(PyHeapTypeObject),
15809  #endif
15810  __Pyx_ImportType_CheckSize_Warn);
15811  if (!__pyx_ptype_7cpython_4type_type) __PYX_ERR(3, 9, __pyx_L1_error)
15812  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
15813  __pyx_t_1 = PyImport_ImportModule("numpy"); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 200, __pyx_L1_error)
15814  __Pyx_GOTREF(__pyx_t_1);
15815  __pyx_ptype_5numpy_dtype = __Pyx_ImportType(__pyx_t_1, "numpy", "dtype", sizeof(PyArray_Descr), __Pyx_ImportType_CheckSize_Ignore);
15816  if (!__pyx_ptype_5numpy_dtype) __PYX_ERR(2, 200, __pyx_L1_error)
15817  __pyx_ptype_5numpy_flatiter = __Pyx_ImportType(__pyx_t_1, "numpy", "flatiter", sizeof(PyArrayIterObject), __Pyx_ImportType_CheckSize_Ignore);
15818  if (!__pyx_ptype_5numpy_flatiter) __PYX_ERR(2, 223, __pyx_L1_error)
15819  __pyx_ptype_5numpy_broadcast = __Pyx_ImportType(__pyx_t_1, "numpy", "broadcast", sizeof(PyArrayMultiIterObject), __Pyx_ImportType_CheckSize_Ignore);
15820  if (!__pyx_ptype_5numpy_broadcast) __PYX_ERR(2, 227, __pyx_L1_error)
15821  __pyx_ptype_5numpy_ndarray = __Pyx_ImportType(__pyx_t_1, "numpy", "ndarray", sizeof(PyArrayObject), __Pyx_ImportType_CheckSize_Ignore);
15822  if (!__pyx_ptype_5numpy_ndarray) __PYX_ERR(2, 239, __pyx_L1_error)
15823  __pyx_ptype_5numpy_generic = __Pyx_ImportType(__pyx_t_1, "numpy", "generic", sizeof(PyObject), __Pyx_ImportType_CheckSize_Warn);
15824  if (!__pyx_ptype_5numpy_generic) __PYX_ERR(2, 771, __pyx_L1_error)
15825  __pyx_ptype_5numpy_number = __Pyx_ImportType(__pyx_t_1, "numpy", "number", sizeof(PyObject), __Pyx_ImportType_CheckSize_Warn);
15826  if (!__pyx_ptype_5numpy_number) __PYX_ERR(2, 773, __pyx_L1_error)
15827  __pyx_ptype_5numpy_integer = __Pyx_ImportType(__pyx_t_1, "numpy", "integer", sizeof(PyObject), __Pyx_ImportType_CheckSize_Warn);
15828  if (!__pyx_ptype_5numpy_integer) __PYX_ERR(2, 775, __pyx_L1_error)
15829  __pyx_ptype_5numpy_signedinteger = __Pyx_ImportType(__pyx_t_1, "numpy", "signedinteger", sizeof(PyObject), __Pyx_ImportType_CheckSize_Warn);
15830  if (!__pyx_ptype_5numpy_signedinteger) __PYX_ERR(2, 777, __pyx_L1_error)
15831  __pyx_ptype_5numpy_unsignedinteger = __Pyx_ImportType(__pyx_t_1, "numpy", "unsignedinteger", sizeof(PyObject), __Pyx_ImportType_CheckSize_Warn);
15832  if (!__pyx_ptype_5numpy_unsignedinteger) __PYX_ERR(2, 779, __pyx_L1_error)
15833  __pyx_ptype_5numpy_inexact = __Pyx_ImportType(__pyx_t_1, "numpy", "inexact", sizeof(PyObject), __Pyx_ImportType_CheckSize_Warn);
15834  if (!__pyx_ptype_5numpy_inexact) __PYX_ERR(2, 781, __pyx_L1_error)
15835  __pyx_ptype_5numpy_floating = __Pyx_ImportType(__pyx_t_1, "numpy", "floating", sizeof(PyObject), __Pyx_ImportType_CheckSize_Warn);
15836  if (!__pyx_ptype_5numpy_floating) __PYX_ERR(2, 783, __pyx_L1_error)
15837  __pyx_ptype_5numpy_complexfloating = __Pyx_ImportType(__pyx_t_1, "numpy", "complexfloating", sizeof(PyObject), __Pyx_ImportType_CheckSize_Warn);
15838  if (!__pyx_ptype_5numpy_complexfloating) __PYX_ERR(2, 785, __pyx_L1_error)
15839  __pyx_ptype_5numpy_flexible = __Pyx_ImportType(__pyx_t_1, "numpy", "flexible", sizeof(PyObject), __Pyx_ImportType_CheckSize_Warn);
15840  if (!__pyx_ptype_5numpy_flexible) __PYX_ERR(2, 787, __pyx_L1_error)
15841  __pyx_ptype_5numpy_character = __Pyx_ImportType(__pyx_t_1, "numpy", "character", sizeof(PyObject), __Pyx_ImportType_CheckSize_Warn);
15842  if (!__pyx_ptype_5numpy_character) __PYX_ERR(2, 789, __pyx_L1_error)
15843  __pyx_ptype_5numpy_ufunc = __Pyx_ImportType(__pyx_t_1, "numpy", "ufunc", sizeof(PyUFuncObject), __Pyx_ImportType_CheckSize_Ignore);
15844  if (!__pyx_ptype_5numpy_ufunc) __PYX_ERR(2, 827, __pyx_L1_error)
15845  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
15846  __Pyx_RefNannyFinishContext();
15847  return 0;
15848  __pyx_L1_error:;
15849  __Pyx_XDECREF(__pyx_t_1);
15850  __Pyx_RefNannyFinishContext();
15851  return -1;
15852 }
15853 
15854 static int __Pyx_modinit_variable_import_code(void) {
15855  __Pyx_RefNannyDeclarations
15856  __Pyx_RefNannySetupContext("__Pyx_modinit_variable_import_code", 0);
15857  /*--- Variable import code ---*/
15858  __Pyx_RefNannyFinishContext();
15859  return 0;
15860 }
15861 
15862 static int __Pyx_modinit_function_import_code(void) {
15863  __Pyx_RefNannyDeclarations
15864  __Pyx_RefNannySetupContext("__Pyx_modinit_function_import_code", 0);
15865  /*--- Function import code ---*/
15866  __Pyx_RefNannyFinishContext();
15867  return 0;
15868 }
15869 
15870 
15871 #ifndef CYTHON_NO_PYINIT_EXPORT
15872 #define __Pyx_PyMODINIT_FUNC PyMODINIT_FUNC
15873 #elif PY_MAJOR_VERSION < 3
15874 #ifdef __cplusplus
15875 #define __Pyx_PyMODINIT_FUNC extern "C" void
15876 #else
15877 #define __Pyx_PyMODINIT_FUNC void
15878 #endif
15879 #else
15880 #ifdef __cplusplus
15881 #define __Pyx_PyMODINIT_FUNC extern "C" PyObject *
15882 #else
15883 #define __Pyx_PyMODINIT_FUNC PyObject *
15884 #endif
15885 #endif
15886 
15887 
15888 #if PY_MAJOR_VERSION < 3
15889 __Pyx_PyMODINIT_FUNC initcpostprocessing(void) CYTHON_SMALL_CODE; /*proto*/
15890 __Pyx_PyMODINIT_FUNC initcpostprocessing(void)
15891 #else
15892 __Pyx_PyMODINIT_FUNC PyInit_cpostprocessing(void) CYTHON_SMALL_CODE; /*proto*/
15893 __Pyx_PyMODINIT_FUNC PyInit_cpostprocessing(void)
15894 #if CYTHON_PEP489_MULTI_PHASE_INIT
15895 {
15896  return PyModuleDef_Init(&__pyx_moduledef);
15897 }
15898 static CYTHON_SMALL_CODE int __Pyx_check_single_interpreter(void) {
15899  #if PY_VERSION_HEX >= 0x030700A1
15900  static PY_INT64_T main_interpreter_id = -1;
15901  PY_INT64_T current_id = PyInterpreterState_GetID(PyThreadState_Get()->interp);
15902  if (main_interpreter_id == -1) {
15903  main_interpreter_id = current_id;
15904  return (unlikely(current_id == -1)) ? -1 : 0;
15905  } else if (unlikely(main_interpreter_id != current_id))
15906  #else
15907  static PyInterpreterState *main_interpreter = NULL;
15908  PyInterpreterState *current_interpreter = PyThreadState_Get()->interp;
15909  if (!main_interpreter) {
15910  main_interpreter = current_interpreter;
15911  } else if (unlikely(main_interpreter != current_interpreter))
15912  #endif
15913  {
15914  PyErr_SetString(
15915  PyExc_ImportError,
15916  "Interpreter change detected - this module can only be loaded into one interpreter per process.");
15917  return -1;
15918  }
15919  return 0;
15920 }
15921 static CYTHON_SMALL_CODE int __Pyx_copy_spec_to_module(PyObject *spec, PyObject *moddict, const char* from_name, const char* to_name, int allow_none) {
15922  PyObject *value = PyObject_GetAttrString(spec, from_name);
15923  int result = 0;
15924  if (likely(value)) {
15925  if (allow_none || value != Py_None) {
15926  result = PyDict_SetItemString(moddict, to_name, value);
15927  }
15928  Py_DECREF(value);
15929  } else if (PyErr_ExceptionMatches(PyExc_AttributeError)) {
15930  PyErr_Clear();
15931  } else {
15932  result = -1;
15933  }
15934  return result;
15935 }
15936 static CYTHON_SMALL_CODE PyObject* __pyx_pymod_create(PyObject *spec, CYTHON_UNUSED PyModuleDef *def) {
15937  PyObject *module = NULL, *moddict, *modname;
15938  if (__Pyx_check_single_interpreter())
15939  return NULL;
15940  if (__pyx_m)
15941  return __Pyx_NewRef(__pyx_m);
15942  modname = PyObject_GetAttrString(spec, "name");
15943  if (unlikely(!modname)) goto bad;
15944  module = PyModule_NewObject(modname);
15945  Py_DECREF(modname);
15946  if (unlikely(!module)) goto bad;
15947  moddict = PyModule_GetDict(module);
15948  if (unlikely(!moddict)) goto bad;
15949  if (unlikely(__Pyx_copy_spec_to_module(spec, moddict, "loader", "__loader__", 1) < 0)) goto bad;
15950  if (unlikely(__Pyx_copy_spec_to_module(spec, moddict, "origin", "__file__", 1) < 0)) goto bad;
15951  if (unlikely(__Pyx_copy_spec_to_module(spec, moddict, "parent", "__package__", 1) < 0)) goto bad;
15952  if (unlikely(__Pyx_copy_spec_to_module(spec, moddict, "submodule_search_locations", "__path__", 0) < 0)) goto bad;
15953  return module;
15954 bad:
15955  Py_XDECREF(module);
15956  return NULL;
15957 }
15958 
15959 
15960 static CYTHON_SMALL_CODE int __pyx_pymod_exec_cpostprocessing(PyObject *__pyx_pyinit_module)
15961 #endif
15962 #endif
15963 {
15964  PyObject *__pyx_t_1 = NULL;
15965  int __pyx_lineno = 0;
15966  const char *__pyx_filename = NULL;
15967  int __pyx_clineno = 0;
15968  __Pyx_RefNannyDeclarations
15969  #if CYTHON_PEP489_MULTI_PHASE_INIT
15970  if (__pyx_m) {
15971  if (__pyx_m == __pyx_pyinit_module) return 0;
15972  PyErr_SetString(PyExc_RuntimeError, "Module 'cpostprocessing' has already been imported. Re-initialisation is not supported.");
15973  return -1;
15974  }
15975  #elif PY_MAJOR_VERSION >= 3
15976  if (__pyx_m) return __Pyx_NewRef(__pyx_m);
15977  #endif
15978  #if CYTHON_REFNANNY
15979 __Pyx_RefNanny = __Pyx_RefNannyImportAPI("refnanny");
15980 if (!__Pyx_RefNanny) {
15981  PyErr_Clear();
15982  __Pyx_RefNanny = __Pyx_RefNannyImportAPI("Cython.Runtime.refnanny");
15983  if (!__Pyx_RefNanny)
15984  Py_FatalError("failed to import 'refnanny' module");
15985 }
15986 #endif
15987  __Pyx_RefNannySetupContext("__Pyx_PyMODINIT_FUNC PyInit_cpostprocessing(void)", 0);
15988  if (__Pyx_check_binary_version() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
15989  #ifdef __Pxy_PyFrame_Initialize_Offsets
15990  __Pxy_PyFrame_Initialize_Offsets();
15991  #endif
15992  __pyx_empty_tuple = PyTuple_New(0); if (unlikely(!__pyx_empty_tuple)) __PYX_ERR(0, 1, __pyx_L1_error)
15993  __pyx_empty_bytes = PyBytes_FromStringAndSize("", 0); if (unlikely(!__pyx_empty_bytes)) __PYX_ERR(0, 1, __pyx_L1_error)
15994  __pyx_empty_unicode = PyUnicode_FromStringAndSize("", 0); if (unlikely(!__pyx_empty_unicode)) __PYX_ERR(0, 1, __pyx_L1_error)
15995  #ifdef __Pyx_CyFunction_USED
15996  if (__pyx_CyFunction_init() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
15997  #endif
15998  #ifdef __Pyx_FusedFunction_USED
15999  if (__pyx_FusedFunction_init() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
16000  #endif
16001  #ifdef __Pyx_Coroutine_USED
16002  if (__pyx_Coroutine_init() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
16003  #endif
16004  #ifdef __Pyx_Generator_USED
16005  if (__pyx_Generator_init() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
16006  #endif
16007  #ifdef __Pyx_AsyncGen_USED
16008  if (__pyx_AsyncGen_init() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
16009  #endif
16010  #ifdef __Pyx_StopAsyncIteration_USED
16011  if (__pyx_StopAsyncIteration_init() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
16012  #endif
16013  /*--- Library function declarations ---*/
16014  /*--- Threads initialization code ---*/
16015  #if defined(WITH_THREAD) && PY_VERSION_HEX < 0x030700F0 && defined(__PYX_FORCE_INIT_THREADS) && __PYX_FORCE_INIT_THREADS
16016  PyEval_InitThreads();
16017  #endif
16018  /*--- Module creation code ---*/
16019  #if CYTHON_PEP489_MULTI_PHASE_INIT
16020  __pyx_m = __pyx_pyinit_module;
16021  Py_INCREF(__pyx_m);
16022  #else
16023  #if PY_MAJOR_VERSION < 3
16024  __pyx_m = Py_InitModule4("cpostprocessing", __pyx_methods, 0, 0, PYTHON_API_VERSION); Py_XINCREF(__pyx_m);
16025  #else
16026  __pyx_m = PyModule_Create(&__pyx_moduledef);
16027  #endif
16028  if (unlikely(!__pyx_m)) __PYX_ERR(0, 1, __pyx_L1_error)
16029  #endif
16030  __pyx_d = PyModule_GetDict(__pyx_m); if (unlikely(!__pyx_d)) __PYX_ERR(0, 1, __pyx_L1_error)
16031  Py_INCREF(__pyx_d);
16032  __pyx_b = PyImport_AddModule(__Pyx_BUILTIN_MODULE_NAME); if (unlikely(!__pyx_b)) __PYX_ERR(0, 1, __pyx_L1_error)
16033  Py_INCREF(__pyx_b);
16034  __pyx_cython_runtime = PyImport_AddModule((char *) "cython_runtime"); if (unlikely(!__pyx_cython_runtime)) __PYX_ERR(0, 1, __pyx_L1_error)
16035  Py_INCREF(__pyx_cython_runtime);
16036  if (PyObject_SetAttrString(__pyx_m, "__builtins__", __pyx_b) < 0) __PYX_ERR(0, 1, __pyx_L1_error);
16037  /*--- Initialize various global constants etc. ---*/
16038  if (__Pyx_InitGlobals() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
16039  #if PY_MAJOR_VERSION < 3 && (__PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT)
16040  if (__Pyx_init_sys_getdefaultencoding_params() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
16041  #endif
16042  if (__pyx_module_is_main_cpostprocessing) {
16043  if (PyObject_SetAttr(__pyx_m, __pyx_n_s_name, __pyx_n_s_main) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
16044  }
16045  #if PY_MAJOR_VERSION >= 3
16046  {
16047  PyObject *modules = PyImport_GetModuleDict(); if (unlikely(!modules)) __PYX_ERR(0, 1, __pyx_L1_error)
16048  if (!PyDict_GetItemString(modules, "cpostprocessing")) {
16049  if (unlikely(PyDict_SetItemString(modules, "cpostprocessing", __pyx_m) < 0)) __PYX_ERR(0, 1, __pyx_L1_error)
16050  }
16051  }
16052  #endif
16053  /*--- Builtin init code ---*/
16054  if (__Pyx_InitCachedBuiltins() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
16055  /*--- Constants init code ---*/
16056  if (__Pyx_InitCachedConstants() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
16057  /*--- Global type/function init code ---*/
16058  (void)__Pyx_modinit_global_init_code();
16059  (void)__Pyx_modinit_variable_export_code();
16060  (void)__Pyx_modinit_function_export_code();
16061  if (unlikely(__Pyx_modinit_type_init_code() < 0)) __PYX_ERR(0, 1, __pyx_L1_error)
16062  if (unlikely(__Pyx_modinit_type_import_code() < 0)) __PYX_ERR(0, 1, __pyx_L1_error)
16063  (void)__Pyx_modinit_variable_import_code();
16064  (void)__Pyx_modinit_function_import_code();
16065  /*--- Execution code ---*/
16066  #if defined(__Pyx_Generator_USED) || defined(__Pyx_Coroutine_USED)
16067  if (__Pyx_patch_abc() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
16068  #endif
16069 
16070  /* "cpostprocessing.pyx":2
16071  * # A type of -*- python -*- file
16072  * import numpy as np # <<<<<<<<<<<<<<
16073  * cimport numpy as np
16074  * cimport postprocessing as pp
16075  */
16076  __pyx_t_1 = __Pyx_Import(__pyx_n_s_numpy, 0, -1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 2, __pyx_L1_error)
16077  __Pyx_GOTREF(__pyx_t_1);
16078  if (PyDict_SetItem(__pyx_d, __pyx_n_s_np, __pyx_t_1) < 0) __PYX_ERR(0, 2, __pyx_L1_error)
16079  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16080 
16081  /* "cpostprocessing.pyx":6
16082  * cimport postprocessing as pp
16083  *
16084  * def postProcessRT0velocityFromP1nc(np.ndarray nFreeDOF_element, # <<<<<<<<<<<<<<
16085  * np.ndarray freeLocal_element,
16086  * np.ndarray detJ,
16087  */
16088  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_1postProcessRT0velocityFromP1nc, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 6, __pyx_L1_error)
16089  __Pyx_GOTREF(__pyx_t_1);
16090  if (PyDict_SetItem(__pyx_d, __pyx_n_s_postProcessRT0velocityFromP1nc, __pyx_t_1) < 0) __PYX_ERR(0, 6, __pyx_L1_error)
16091  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16092 
16093  /* "cpostprocessing.pyx":70
16094  * <double*>(rt0vdofs.data))
16095  *
16096  * def postProcessRT0velocityFromP1nc_sd(np.ndarray rowptr, # <<<<<<<<<<<<<<
16097  * np.ndarray colind,
16098  * np.ndarray nFreeDOF_element,
16099  */
16100  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_3postProcessRT0velocityFromP1nc_sd, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 70, __pyx_L1_error)
16101  __Pyx_GOTREF(__pyx_t_1);
16102  if (PyDict_SetItem(__pyx_d, __pyx_n_s_postProcessRT0velocityFromP1nc_s, __pyx_t_1) < 0) __PYX_ERR(0, 70, __pyx_L1_error)
16103  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16104 
16105  /* "cpostprocessing.pyx":140
16106  * <double*>(rt0vdofs.data))
16107  *
16108  * def updateRT0velocityWithAveragedPotentialP1nc(np.ndarray detJ, # <<<<<<<<<<<<<<
16109  * np.ndarray quad_a,
16110  * np.ndarray phi,
16111  */
16112  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_5updateRT0velocityWithAveragedPotentialP1nc, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 140, __pyx_L1_error)
16113  __Pyx_GOTREF(__pyx_t_1);
16114  if (PyDict_SetItem(__pyx_d, __pyx_n_s_updateRT0velocityWithAveragedPot, __pyx_t_1) < 0) __PYX_ERR(0, 140, __pyx_L1_error)
16115  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16116 
16117  /* "cpostprocessing.pyx":156
16118  * <double*>(rt0vdofs_element.data))
16119  *
16120  * def updateRT0velocityWithAveragedPotentialP1nc_sd(np.ndarray rowptr, # <<<<<<<<<<<<<<
16121  * np.ndarray colind,
16122  * np.ndarray detJ,
16123  */
16124  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_7updateRT0velocityWithAveragedPotentialP1nc_sd, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 156, __pyx_L1_error)
16125  __Pyx_GOTREF(__pyx_t_1);
16126  if (PyDict_SetItem(__pyx_d, __pyx_n_s_updateRT0velocityWithAveragedPot_2, __pyx_t_1) < 0) __PYX_ERR(0, 156, __pyx_L1_error)
16127  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16128 
16129  /* "cpostprocessing.pyx":176
16130  * <double*>(rt0vdofs_element.data))
16131  *
16132  * def getElementRT0velocityValues(np.ndarray x_element, # <<<<<<<<<<<<<<
16133  * np.ndarray rt0vdofs_element,
16134  * np.ndarray v_element):
16135  */
16136  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_9getElementRT0velocityValues, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 176, __pyx_L1_error)
16137  __Pyx_GOTREF(__pyx_t_1);
16138  if (PyDict_SetItem(__pyx_d, __pyx_n_s_getElementRT0velocityValues, __pyx_t_1) < 0) __PYX_ERR(0, 176, __pyx_L1_error)
16139  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16140 
16141  /* "cpostprocessing.pyx":186
16142  * <double*>(v_element.data))
16143  *
16144  * def getElementBoundaryRT0velocityValues(np.ndarray x_elementBoundary, # <<<<<<<<<<<<<<
16145  * np.ndarray rt0vdofs_element,
16146  * np.ndarray v_elementBoundary):
16147  */
16148  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_11getElementBoundaryRT0velocityValues, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 186, __pyx_L1_error)
16149  __Pyx_GOTREF(__pyx_t_1);
16150  if (PyDict_SetItem(__pyx_d, __pyx_n_s_getElementBoundaryRT0velocityVal, __pyx_t_1) < 0) __PYX_ERR(0, 186, __pyx_L1_error)
16151  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16152 
16153  /* "cpostprocessing.pyx":197
16154  * <double*>(v_elementBoundary.data))
16155  *
16156  * def getGlobalElementBoundaryRT0velocityValues(np.ndarray elementBoundaryElementsArray, # <<<<<<<<<<<<<<
16157  * np.ndarray x_elementBoundary_global,
16158  * np.ndarray rt0vdofs_element,
16159  */
16160  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_13getGlobalElementBoundaryRT0velocityValues, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 197, __pyx_L1_error)
16161  __Pyx_GOTREF(__pyx_t_1);
16162  if (PyDict_SetItem(__pyx_d, __pyx_n_s_getGlobalElementBoundaryRT0veloc, __pyx_t_1) < 0) __PYX_ERR(0, 197, __pyx_L1_error)
16163  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16164 
16165  /* "cpostprocessing.pyx":209
16166  * <double*>(v_elementBoundary_global.data))
16167  *
16168  * def getGlobalExteriorElementBoundaryRT0velocityValues(np.ndarray exteriorElementBoundariesArray, # <<<<<<<<<<<<<<
16169  * np.ndarray elementBoundaryElementsArray,
16170  * np.ndarray x_elementBoundary_global,
16171  */
16172  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_15getGlobalExteriorElementBoundaryRT0velocityValues, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 209, __pyx_L1_error)
16173  __Pyx_GOTREF(__pyx_t_1);
16174  if (PyDict_SetItem(__pyx_d, __pyx_n_s_getGlobalExteriorElementBoundary, __pyx_t_1) < 0) __PYX_ERR(0, 209, __pyx_L1_error)
16175  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16176 
16177  /* "cpostprocessing.pyx":223
16178  * <double*>(v_elementBoundary_global.data))
16179  *
16180  * def postProcessRT0potentialFromP1nc(np.ndarray uQuadratureWeights_element, # <<<<<<<<<<<<<<
16181  * np.ndarray elementBarycenters,
16182  * np.ndarray aElementQuadWeights,
16183  */
16184  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_17postProcessRT0potentialFromP1nc, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 223, __pyx_L1_error)
16185  __Pyx_GOTREF(__pyx_t_1);
16186  if (PyDict_SetItem(__pyx_d, __pyx_n_s_postProcessRT0potentialFromP1nc, __pyx_t_1) < 0) __PYX_ERR(0, 223, __pyx_L1_error)
16187  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16188 
16189  /* "cpostprocessing.pyx":261
16190  * <double*>(rt0potential.data))
16191  *
16192  * def postProcessRT0potentialFromP1nc_sd(np.ndarray rowptr, # <<<<<<<<<<<<<<
16193  * np.ndarray colind,
16194  * np.ndarray uQuadratureWeights_element,
16195  */
16196  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_19postProcessRT0potentialFromP1nc_sd, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 261, __pyx_L1_error)
16197  __Pyx_GOTREF(__pyx_t_1);
16198  if (PyDict_SetItem(__pyx_d, __pyx_n_s_postProcessRT0potentialFromP1nc_2, __pyx_t_1) < 0) __PYX_ERR(0, 261, __pyx_L1_error)
16199  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16200 
16201  /* "cpostprocessing.pyx":303
16202  * <double*>(rt0potential.data))
16203  *
16204  * def buildLocalBDM1projectionMatrices(np.ndarray w_dS_f, # <<<<<<<<<<<<<<
16205  * np.ndarray ebq_n,
16206  * np.ndarray ebq_v,
16207  */
16208  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_21buildLocalBDM1projectionMatrices, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 303, __pyx_L1_error)
16209  __Pyx_GOTREF(__pyx_t_1);
16210  if (PyDict_SetItem(__pyx_d, __pyx_n_s_buildLocalBDM1projectionMatrices, __pyx_t_1) < 0) __PYX_ERR(0, 303, __pyx_L1_error)
16211  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16212 
16213  /* "cpostprocessing.pyx":319
16214  * <double*>(BDMmat_element.data))
16215  *
16216  * def buildLocalBDM2projectionMatrices(int degree, # <<<<<<<<<<<<<<
16217  * np.ndarray w_dS_f,
16218  * np.ndarray ebq_n,
16219  */
16220  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_23buildLocalBDM2projectionMatrices, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 319, __pyx_L1_error)
16221  __Pyx_GOTREF(__pyx_t_1);
16222  if (PyDict_SetItem(__pyx_d, __pyx_n_s_buildLocalBDM2projectionMatrices, __pyx_t_1) < 0) __PYX_ERR(0, 319, __pyx_L1_error)
16223  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16224 
16225  /* "cpostprocessing.pyx":349
16226  * <double*>(piola_trial_fun.data))
16227  *
16228  * def factorLocalBDM1projectionMatrices(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
16229  * np.ndarray BDMmatPivots_element):
16230  * pp.factorLocalBDM1projectionMatrices(BDMmat_element.shape[0],
16231  */
16232  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_25factorLocalBDM1projectionMatrices, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 349, __pyx_L1_error)
16233  __Pyx_GOTREF(__pyx_t_1);
16234  if (PyDict_SetItem(__pyx_d, __pyx_n_s_factorLocalBDM1projectionMatrice, __pyx_t_1) < 0) __PYX_ERR(0, 349, __pyx_L1_error)
16235  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16236 
16237  /* "cpostprocessing.pyx":356
16238  * <int*>(BDMmatPivots_element.data))
16239  *
16240  * def factorLocalBDM2projectionMatrices(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
16241  * np.ndarray BDMmatPivots_element):
16242  * pp.factorLocalBDM2projectionMatrices(BDMmat_element.shape[0],
16243  */
16244  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_27factorLocalBDM2projectionMatrices, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 356, __pyx_L1_error)
16245  __Pyx_GOTREF(__pyx_t_1);
16246  if (PyDict_SetItem(__pyx_d, __pyx_n_s_factorLocalBDM2projectionMatrice, __pyx_t_1) < 0) __PYX_ERR(0, 356, __pyx_L1_error)
16247  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16248 
16249  /* "cpostprocessing.pyx":363
16250  * <int*>(BDMmatPivots_element.data))
16251  *
16252  * def solveLocalBDM1projection(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
16253  * np.ndarray BDMmatPivots_element,
16254  * np.ndarray w_dS_f,
16255  */
16256  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_29solveLocalBDM1projection, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 363, __pyx_L1_error)
16257  __Pyx_GOTREF(__pyx_t_1);
16258  if (PyDict_SetItem(__pyx_d, __pyx_n_s_solveLocalBDM1projection, __pyx_t_1) < 0) __PYX_ERR(0, 363, __pyx_L1_error)
16259  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16260 
16261  /* "cpostprocessing.pyx":382
16262  * <double*>(q_vdofs.data))
16263  *
16264  * def solveLocalBDM2projection(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
16265  * np.ndarray BDMmatPivots_element,
16266  * np.ndarray w_dS_f,
16267  */
16268  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_31solveLocalBDM2projection, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 382, __pyx_L1_error)
16269  __Pyx_GOTREF(__pyx_t_1);
16270  if (PyDict_SetItem(__pyx_d, __pyx_n_s_solveLocalBDM2projection, __pyx_t_1) < 0) __PYX_ERR(0, 382, __pyx_L1_error)
16271  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16272 
16273  /* "cpostprocessing.pyx":405
16274  * <double*>(q_vdofs.data))
16275  *
16276  * def buildBDM2rhs(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
16277  * np.ndarray BDMmatPivots_element,
16278  * np.ndarray w_dS_f,
16279  */
16280  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_33buildBDM2rhs, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 405, __pyx_L1_error)
16281  __Pyx_GOTREF(__pyx_t_1);
16282  if (PyDict_SetItem(__pyx_d, __pyx_n_s_buildBDM2rhs, __pyx_t_1) < 0) __PYX_ERR(0, 405, __pyx_L1_error)
16283  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16284 
16285  /* "cpostprocessing.pyx":434
16286  * <double*>(q_vdofs.data))
16287  *
16288  * def solveLocalBDM1projectionFromFlux(np.ndarray BDMmat_element, # <<<<<<<<<<<<<<
16289  * np.ndarray BDMmatPivots_element,
16290  * np.ndarray elementBoundaryElementsArray,
16291  */
16292  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_35solveLocalBDM1projectionFromFlux, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 434, __pyx_L1_error)
16293  __Pyx_GOTREF(__pyx_t_1);
16294  if (PyDict_SetItem(__pyx_d, __pyx_n_s_solveLocalBDM1projectionFromFlux, __pyx_t_1) < 0) __PYX_ERR(0, 434, __pyx_L1_error)
16295  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16296 
16297  /* "cpostprocessing.pyx":454
16298  * <double*>(q_vdofs.data))
16299  *
16300  * def getElementBDM1velocityValuesLagrangeRep(np.ndarray q_v, # <<<<<<<<<<<<<<
16301  * np.ndarray p1_vdofs,
16302  * np.ndarray q_velocity):
16303  */
16304  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_37getElementBDM1velocityValuesLagrangeRep, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 454, __pyx_L1_error)
16305  __Pyx_GOTREF(__pyx_t_1);
16306  if (PyDict_SetItem(__pyx_d, __pyx_n_s_getElementBDM1velocityValuesLagr, __pyx_t_1) < 0) __PYX_ERR(0, 454, __pyx_L1_error)
16307  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16308 
16309  /* "cpostprocessing.pyx":470
16310  * <double*>(q_velocity.data))
16311  *
16312  * def getElementBDM2velocityValuesLagrangeRep(np.ndarray q_v, # <<<<<<<<<<<<<<
16313  * np.ndarray p1_vdofs,
16314  * np.ndarray q_velocity):
16315  */
16316  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_39getElementBDM2velocityValuesLagrangeRep, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 470, __pyx_L1_error)
16317  __Pyx_GOTREF(__pyx_t_1);
16318  if (PyDict_SetItem(__pyx_d, __pyx_n_s_getElementBDM2velocityValuesLagr, __pyx_t_1) < 0) __PYX_ERR(0, 470, __pyx_L1_error)
16319  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16320 
16321  /* "cpostprocessing.pyx":492
16322  * <double*>(q_velocity.data))
16323  *
16324  * def getElementLDGvelocityValuesLagrangeRep(np.ndarray q_v, # <<<<<<<<<<<<<<
16325  * np.ndarray vdofs,
16326  * np.ndarray q_velocity):
16327  */
16328  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_41getElementLDGvelocityValuesLagrangeRep, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 492, __pyx_L1_error)
16329  __Pyx_GOTREF(__pyx_t_1);
16330  if (PyDict_SetItem(__pyx_d, __pyx_n_s_getElementLDGvelocityValuesLagra, __pyx_t_1) < 0) __PYX_ERR(0, 492, __pyx_L1_error)
16331  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16332 
16333  /* "cpostprocessing.pyx":508
16334  * <double*>(q_velocity.data))
16335  *
16336  * def getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep(np.ndarray elementBoundaryElementsArray, # <<<<<<<<<<<<<<
16337  * np.ndarray exteriorElementBoundariesArray,
16338  * np.ndarray ebqe_v,
16339  */
16340  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_43getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 508, __pyx_L1_error)
16341  __Pyx_GOTREF(__pyx_t_1);
16342  if (PyDict_SetItem(__pyx_d, __pyx_n_s_getGlobalExteriorElementBoundary_2, __pyx_t_1) < 0) __PYX_ERR(0, 508, __pyx_L1_error)
16343  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16344 
16345  /* "cpostprocessing.pyx":527
16346  * <double*>(ebqe_velocity.data))
16347  *
16348  * def getGlobalElementBoundaryBDM1velocityValuesLagrangeRep(np.ndarray elementBoundaryElementsArray, # <<<<<<<<<<<<<<
16349  * np.ndarray exteriorElementBoundariesArray,
16350  * np.ndarray ebqe_v,
16351  */
16352  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_45getGlobalElementBoundaryBDM1velocityValuesLagrangeRep, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 527, __pyx_L1_error)
16353  __Pyx_GOTREF(__pyx_t_1);
16354  if (PyDict_SetItem(__pyx_d, __pyx_n_s_getGlobalElementBoundaryBDM1velo, __pyx_t_1) < 0) __PYX_ERR(0, 527, __pyx_L1_error)
16355  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16356 
16357  /* "cpostprocessing.pyx":546
16358  * <double*>(ebq_global_velocity.data))
16359  *
16360  * def getElementBoundaryBDM1velocityValuesLagrangeRep(np.ndarray elementBoundaryElementsArray, # <<<<<<<<<<<<<<
16361  * np.ndarray exteriorElementBoundariesArray,
16362  * np.ndarray ebq_v,
16363  */
16364  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_47getElementBoundaryBDM1velocityValuesLagrangeRep, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 546, __pyx_L1_error)
16365  __Pyx_GOTREF(__pyx_t_1);
16366  if (PyDict_SetItem(__pyx_d, __pyx_n_s_getElementBoundaryBDM1velocityVa, __pyx_t_1) < 0) __PYX_ERR(0, 546, __pyx_L1_error)
16367  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16368 
16369  /* "cpostprocessing.pyx":566
16370  * <double*>(ebq_velocity.data))
16371  *
16372  * def projectElementBoundaryVelocityToRT0fluxRep(np.ndarray elementBoundaryQuadratureWeights, # <<<<<<<<<<<<<<
16373  * np.ndarray n,
16374  * np.ndarray v_elementBoundary,
16375  */
16376  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_49projectElementBoundaryVelocityToRT0fluxRep, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 566, __pyx_L1_error)
16377  __Pyx_GOTREF(__pyx_t_1);
16378  if (PyDict_SetItem(__pyx_d, __pyx_n_s_projectElementBoundaryVelocityTo, __pyx_t_1) < 0) __PYX_ERR(0, 566, __pyx_L1_error)
16379  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16380 
16381  /* "cpostprocessing.pyx":579
16382  * <double*>(rt0vdofs_element.data))
16383  *
16384  * def projectElementBoundaryFluxToRT0fluxRep(np.ndarray elementBoundaryElementsArray, # <<<<<<<<<<<<<<
16385  * np.ndarray elementBoundariesArray,
16386  * np.ndarray elementBoundaryQuadratureWeights,
16387  */
16388  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_51projectElementBoundaryFluxToRT0fluxRep, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 579, __pyx_L1_error)
16389  __Pyx_GOTREF(__pyx_t_1);
16390  if (PyDict_SetItem(__pyx_d, __pyx_n_s_projectElementBoundaryFluxToRT0f, __pyx_t_1) < 0) __PYX_ERR(0, 579, __pyx_L1_error)
16391  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16392 
16393  /* "cpostprocessing.pyx":594
16394  * <double*>(rt0vdofs_element.data))
16395  *
16396  * def getElementRT0velocityValuesFluxRep(np.ndarray nodeArray, # <<<<<<<<<<<<<<
16397  * np.ndarray elementNodesArray,
16398  * np.ndarray abs_det_J,
16399  */
16400  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_53getElementRT0velocityValuesFluxRep, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 594, __pyx_L1_error)
16401  __Pyx_GOTREF(__pyx_t_1);
16402  if (PyDict_SetItem(__pyx_d, __pyx_n_s_getElementRT0velocityValuesFluxR, __pyx_t_1) < 0) __PYX_ERR(0, 594, __pyx_L1_error)
16403  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16404 
16405  /* "cpostprocessing.pyx":612
16406  * <double*>(v_element.data))
16407  *
16408  * def getElementBoundaryRT0velocityValuesFluxRep(np.ndarray nodeArray, # <<<<<<<<<<<<<<
16409  * np.ndarray elementNodesArray,
16410  * np.ndarray abs_det_J,
16411  */
16412  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_55getElementBoundaryRT0velocityValuesFluxRep, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 612, __pyx_L1_error)
16413  __Pyx_GOTREF(__pyx_t_1);
16414  if (PyDict_SetItem(__pyx_d, __pyx_n_s_getElementBoundaryRT0velocityVal_2, __pyx_t_1) < 0) __PYX_ERR(0, 612, __pyx_L1_error)
16415  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16416 
16417  /* "cpostprocessing.pyx":630
16418  * <double*>(v_elementBoundary.data))
16419  *
16420  * def getGlobalElementBoundaryRT0velocityValuesFluxRep(np.ndarray nodeArray, # <<<<<<<<<<<<<<
16421  * np.ndarray elementNodesArray,
16422  * np.ndarray elementBoundaryElementsArray,
16423  */
16424  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_57getGlobalElementBoundaryRT0velocityValuesFluxRep, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 630, __pyx_L1_error)
16425  __Pyx_GOTREF(__pyx_t_1);
16426  if (PyDict_SetItem(__pyx_d, __pyx_n_s_getGlobalElementBoundaryRT0veloc_2, __pyx_t_1) < 0) __PYX_ERR(0, 630, __pyx_L1_error)
16427  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16428 
16429  /* "cpostprocessing.pyx":649
16430  * <double*>(v_elementBoundary_global.data))
16431  *
16432  * def getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep(np.ndarray nodeArray, # <<<<<<<<<<<<<<
16433  * np.ndarray elementNodesArray,
16434  * np.ndarray elementBoundaryElementsArray,
16435  */
16436  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_59getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 649, __pyx_L1_error)
16437  __Pyx_GOTREF(__pyx_t_1);
16438  if (PyDict_SetItem(__pyx_d, __pyx_n_s_getGlobalExteriorElementBoundary_3, __pyx_t_1) < 0) __PYX_ERR(0, 649, __pyx_L1_error)
16439  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16440 
16441  /* "cpostprocessing.pyx":670
16442  * <double*>(v_ebqe.data))
16443  *
16444  * def getRT0velocityValuesFluxRep_arbitraryElementMembership(np.ndarray nodeArray, # <<<<<<<<<<<<<<
16445  * np.ndarray elementNodesArray,
16446  * np.ndarray abs_det_J,
16447  */
16448  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_61getRT0velocityValuesFluxRep_arbitraryElementMembership, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 670, __pyx_L1_error)
16449  __Pyx_GOTREF(__pyx_t_1);
16450  if (PyDict_SetItem(__pyx_d, __pyx_n_s_getRT0velocityValuesFluxRep_arbi, __pyx_t_1) < 0) __PYX_ERR(0, 670, __pyx_L1_error)
16451  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16452 
16453  /* "cpostprocessing.pyx":691
16454  * <double*>(v_element.data))
16455  *
16456  * def fluxCorrectionVelocityUpdate(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
16457  * np.ndarray exteriorElementBoundaries,
16458  * np.ndarray elementBoundaryElements,
16459  */
16460  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_63fluxCorrectionVelocityUpdate, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 691, __pyx_L1_error)
16461  __Pyx_GOTREF(__pyx_t_1);
16462  if (PyDict_SetItem(__pyx_d, __pyx_n_s_fluxCorrectionVelocityUpdate, __pyx_t_1) < 0) __PYX_ERR(0, 691, __pyx_L1_error)
16463  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16464 
16465  /* "cpostprocessing.pyx":717
16466  * <double*>(velocity_element.data))
16467  *
16468  * def computeFluxCorrectionPWC(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
16469  * np.ndarray exteriorElementBoundaries,
16470  * np.ndarray elementBoundaryElements,
16471  */
16472  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_65computeFluxCorrectionPWC, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 717, __pyx_L1_error)
16473  __Pyx_GOTREF(__pyx_t_1);
16474  if (PyDict_SetItem(__pyx_d, __pyx_n_s_computeFluxCorrectionPWC, __pyx_t_1) < 0) __PYX_ERR(0, 717, __pyx_L1_error)
16475  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16476 
16477  /* "cpostprocessing.pyx":733
16478  * <double*>(fluxCorrection.data))
16479  *
16480  * def sunWheelerGSsweep(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
16481  * np.ndarray exteriorElementBoundaries,
16482  * np.ndarray elementBoundaryElements,
16483  */
16484  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_67sunWheelerGSsweep, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 733, __pyx_L1_error)
16485  __Pyx_GOTREF(__pyx_t_1);
16486  if (PyDict_SetItem(__pyx_d, __pyx_n_s_sunWheelerGSsweep, __pyx_t_1) < 0) __PYX_ERR(0, 733, __pyx_L1_error)
16487  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16488 
16489  /* "cpostprocessing.pyx":818
16490  * &self.nsf.subdomain_column_pivots)
16491  *
16492  * def calculateConservationResidualPWL(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
16493  * np.ndarray exteriorElementBoundaries,
16494  * np.ndarray elementBoundaryElements,
16495  */
16496  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_69calculateConservationResidualPWL, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 818, __pyx_L1_error)
16497  __Pyx_GOTREF(__pyx_t_1);
16498  if (PyDict_SetItem(__pyx_d, __pyx_n_s_calculateConservationResidualPWL, __pyx_t_1) < 0) __PYX_ERR(0, 818, __pyx_L1_error)
16499  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16500 
16501  /* "cpostprocessing.pyx":873
16502  * <double*>(vConservative_element.data))
16503  *
16504  * def calculateConservationJacobianPWL(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
16505  * np.ndarray exteriorElementBoundaries,
16506  * np.ndarray elementBoundaryElements,
16507  */
16508  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_71calculateConservationJacobianPWL, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 873, __pyx_L1_error)
16509  __Pyx_GOTREF(__pyx_t_1);
16510  if (PyDict_SetItem(__pyx_d, __pyx_n_s_calculateConservationJacobianPWL, __pyx_t_1) < 0) __PYX_ERR(0, 873, __pyx_L1_error)
16511  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16512 
16513  /* "cpostprocessing.pyx":914
16514  * &nodeStarFactor.nsf)
16515  *
16516  * def calculateConservationFluxPWL(np.ndarray nElements_node, # <<<<<<<<<<<<<<
16517  * np.ndarray internalNodes,
16518  * np.ndarray fluxBoundaryNodes,
16519  */
16520  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_73calculateConservationFluxPWL, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 914, __pyx_L1_error)
16521  __Pyx_GOTREF(__pyx_t_1);
16522  if (PyDict_SetItem(__pyx_d, __pyx_n_s_calculateConservationFluxPWL, __pyx_t_1) < 0) __PYX_ERR(0, 914, __pyx_L1_error)
16523  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16524 
16525  /* "cpostprocessing.pyx":925
16526  * &nodeStarFactor.nsf)
16527  *
16528  * def calculateConservationFluxPWL_noNeumannFix(np.ndarray nElements_node, # <<<<<<<<<<<<<<
16529  * NodeStarFactor nodeStarFactor):
16530  * pp.calculateConservationFluxPWL_noNeumannFix(nElements_node.shape[0],
16531  */
16532  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_75calculateConservationFluxPWL_noNeumannFix, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 925, __pyx_L1_error)
16533  __Pyx_GOTREF(__pyx_t_1);
16534  if (PyDict_SetItem(__pyx_d, __pyx_n_s_calculateConservationFluxPWL_noN, __pyx_t_1) < 0) __PYX_ERR(0, 925, __pyx_L1_error)
16535  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16536 
16537  /* "cpostprocessing.pyx":931
16538  * &nodeStarFactor.nsf)
16539  *
16540  * def calculateConservationResidualPWL_opt(int nNodes_owned, # <<<<<<<<<<<<<<
16541  * np.ndarray interiorElementBoundaries,
16542  * np.ndarray exteriorElementBoundaries,
16543  */
16544  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_77calculateConservationResidualPWL_opt, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 931, __pyx_L1_error)
16545  __Pyx_GOTREF(__pyx_t_1);
16546  if (PyDict_SetItem(__pyx_d, __pyx_n_s_calculateConservationResidualPWL_2, __pyx_t_1) < 0) __PYX_ERR(0, 931, __pyx_L1_error)
16547  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16548 
16549  /* "cpostprocessing.pyx":977
16550  * <double*>(vConservative_element.data))
16551  *
16552  * def calculateConservationResidualPWL_primative(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
16553  * np.ndarray exteriorElementBoundaries,
16554  * np.ndarray elementBoundaryElements,
16555  */
16556  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_79calculateConservationResidualPWL_primative, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 977, __pyx_L1_error)
16557  __Pyx_GOTREF(__pyx_t_1);
16558  if (PyDict_SetItem(__pyx_d, __pyx_n_s_calculateConservationResidualPWL_3, __pyx_t_1) < 0) __PYX_ERR(0, 977, __pyx_L1_error)
16559  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16560 
16561  /* "cpostprocessing.pyx":1005
16562  * <double*>(vConservative.data))
16563  *
16564  * def calculateConservationJacobianPWL_opt(int nNodes_owned, # <<<<<<<<<<<<<<
16565  * np.ndarray interiorElementBoundaries,
16566  * np.ndarray exteriorElementBoundaries,
16567  */
16568  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_81calculateConservationJacobianPWL_opt, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1005, __pyx_L1_error)
16569  __Pyx_GOTREF(__pyx_t_1);
16570  if (PyDict_SetItem(__pyx_d, __pyx_n_s_calculateConservationJacobianPWL_2, __pyx_t_1) < 0) __PYX_ERR(0, 1005, __pyx_L1_error)
16571  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16572 
16573  /* "cpostprocessing.pyx":1045
16574  * &nodeStarFactor.nsf)
16575  *
16576  * def calculateConservationFluxPWL_opt(int nNodes_owned, # <<<<<<<<<<<<<<
16577  * np.ndarray nElements_node,
16578  * np.ndarray internalNodes,
16579  */
16580  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_83calculateConservationFluxPWL_opt, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1045, __pyx_L1_error)
16581  __Pyx_GOTREF(__pyx_t_1);
16582  if (PyDict_SetItem(__pyx_d, __pyx_n_s_calculateConservationFluxPWL_opt, __pyx_t_1) < 0) __PYX_ERR(0, 1045, __pyx_L1_error)
16583  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16584 
16585  /* "cpostprocessing.pyx":1058
16586  * &nodeStarFactor.nsf)
16587  *
16588  * def calculateConservationResidualPWL_interiorBoundaries(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
16589  * np.ndarray exteriorElementBoundaries,
16590  * np.ndarray elementBoundaryElements,
16591  */
16592  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_85calculateConservationResidualPWL_interiorBoundaries, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1058, __pyx_L1_error)
16593  __Pyx_GOTREF(__pyx_t_1);
16594  if (PyDict_SetItem(__pyx_d, __pyx_n_s_calculateConservationResidualPWL_4, __pyx_t_1) < 0) __PYX_ERR(0, 1058, __pyx_L1_error)
16595  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16596 
16597  /* "cpostprocessing.pyx":1103
16598  * <double*>(vConservative_element.data))
16599  *
16600  * def calculateConservationJacobianPWL_interiorBoundaries(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
16601  * np.ndarray exteriorElementBoundaries,
16602  * np.ndarray elementBoundaryElements,
16603  */
16604  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_87calculateConservationJacobianPWL_interiorBoundaries, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1103, __pyx_L1_error)
16605  __Pyx_GOTREF(__pyx_t_1);
16606  if (PyDict_SetItem(__pyx_d, __pyx_n_s_calculateConservationJacobianPWL_3, __pyx_t_1) < 0) __PYX_ERR(0, 1103, __pyx_L1_error)
16607  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16608 
16609  /* "cpostprocessing.pyx":1137
16610  * &nodeStarFactor.nsf)
16611  *
16612  * def _subdomain_U_copy_global2local(int max_nN_owned, # <<<<<<<<<<<<<<
16613  * np.ndarray elementNodes,
16614  * np.ndarray nodeStarElements,
16615  */
16616  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_89_subdomain_U_copy_global2local, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1137, __pyx_L1_error)
16617  __Pyx_GOTREF(__pyx_t_1);
16618  if (PyDict_SetItem(__pyx_d, __pyx_n_s_subdomain_U_copy_global2local, __pyx_t_1) < 0) __PYX_ERR(0, 1137, __pyx_L1_error)
16619  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16620 
16621  /* "cpostprocessing.pyx":1150
16622  * <double*>(subdomain_U.data))
16623  *
16624  * def _subdomain_U_copy_local2global(int max_nN_owned, # <<<<<<<<<<<<<<
16625  * np.ndarray elementNodes,
16626  * np.ndarray nodeStarElements,
16627  */
16628  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_91_subdomain_U_copy_local2global, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1150, __pyx_L1_error)
16629  __Pyx_GOTREF(__pyx_t_1);
16630  if (PyDict_SetItem(__pyx_d, __pyx_n_s_subdomain_U_copy_local2global, __pyx_t_1) < 0) __PYX_ERR(0, 1150, __pyx_L1_error)
16631  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16632 
16633  /* "cpostprocessing.pyx":1163
16634  * <double*>(subdomain_U.data))
16635  *
16636  * def calculateConservationResidualGlobalBoundaries(np.ndarray interiorElementBoundaries, # <<<<<<<<<<<<<<
16637  * np.ndarray exteriorElementBoundaries,
16638  * np.ndarray elementBoundaryElements,
16639  */
16640  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_93calculateConservationResidualGlobalBoundaries, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1163, __pyx_L1_error)
16641  __Pyx_GOTREF(__pyx_t_1);
16642  if (PyDict_SetItem(__pyx_d, __pyx_n_s_calculateConservationResidualGlo, __pyx_t_1) < 0) __PYX_ERR(0, 1163, __pyx_L1_error)
16643  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16644 
16645  /* "cpostprocessing.pyx":1191
16646  * <double*>(conservationResidual.data))
16647  *
16648  * def updateSelectedExteriorElementBoundaryFlux(np.ndarray exteriorElementBoundaries, # <<<<<<<<<<<<<<
16649  * np.ndarray elementBoundaryElements,
16650  * np.ndarray elementBoundaryLocalElementBoundaries,
16651  */
16652  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_95updateSelectedExteriorElementBoundaryFlux, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1191, __pyx_L1_error)
16653  __Pyx_GOTREF(__pyx_t_1);
16654  if (PyDict_SetItem(__pyx_d, __pyx_n_s_updateSelectedExteriorElementBou, __pyx_t_1) < 0) __PYX_ERR(0, 1191, __pyx_L1_error)
16655  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16656 
16657  /* "cpostprocessing.pyx":1210
16658  * <double*>(residual.data))
16659  *
16660  * def updateAdvectiveVelocityPointEval(double updateCoef, # <<<<<<<<<<<<<<
16661  * np.ndarray advectiveVelocity,
16662  * np.ndarray velocity):
16663  */
16664  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_97updateAdvectiveVelocityPointEval, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1210, __pyx_L1_error)
16665  __Pyx_GOTREF(__pyx_t_1);
16666  if (PyDict_SetItem(__pyx_d, __pyx_n_s_updateAdvectiveVelocityPointEval, __pyx_t_1) < 0) __PYX_ERR(0, 1210, __pyx_L1_error)
16667  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16668 
16669  /* "cpostprocessing.pyx":1220
16670  * <double*>(velocity.data))
16671  *
16672  * def updateDiffusiveVelocityPointEval(double updateCoef, # <<<<<<<<<<<<<<
16673  * np.ndarray diffusionTensor,
16674  * np.ndarray grad_phi,
16675  */
16676  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_99updateDiffusiveVelocityPointEval, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1220, __pyx_L1_error)
16677  __Pyx_GOTREF(__pyx_t_1);
16678  if (PyDict_SetItem(__pyx_d, __pyx_n_s_updateDiffusiveVelocityPointEval, __pyx_t_1) < 0) __PYX_ERR(0, 1220, __pyx_L1_error)
16679  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16680 
16681  /* "cpostprocessing.pyx":1232
16682  * <double*>(velocity.data))
16683  *
16684  * def updateDiffusiveVelocityPointEval_sd(double updateCoef, # <<<<<<<<<<<<<<
16685  * np.ndarray rowptr,
16686  * np.ndarray colind,
16687  */
16688  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_101updateDiffusiveVelocityPointEval_sd, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1232, __pyx_L1_error)
16689  __Pyx_GOTREF(__pyx_t_1);
16690  if (PyDict_SetItem(__pyx_d, __pyx_n_s_updateDiffusiveVelocityPointEval_2, __pyx_t_1) < 0) __PYX_ERR(0, 1232, __pyx_L1_error)
16691  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16692 
16693  /* "cpostprocessing.pyx":1248
16694  * <double*>(velocity.data))
16695  *
16696  * def calculateElementResidualPWL(np.ndarray alpha, # <<<<<<<<<<<<<<
16697  * np.ndarray elementResidual,
16698  * np.ndarray elementResidualPWL):
16699  */
16700  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_103calculateElementResidualPWL, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1248, __pyx_L1_error)
16701  __Pyx_GOTREF(__pyx_t_1);
16702  if (PyDict_SetItem(__pyx_d, __pyx_n_s_calculateElementResidualPWL, __pyx_t_1) < 0) __PYX_ERR(0, 1248, __pyx_L1_error)
16703  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16704 
16705  /* "cpostprocessing.pyx":1258
16706  * <double*>(elementResidualPWL.data))
16707  *
16708  * def copyElementBoundaryVelocityToParVec(np.ndarray ebq_velocity, # <<<<<<<<<<<<<<
16709  * np.ndarray[int, ndim=2] permutations,
16710  * np.ndarray ebq_v_par_local):
16711  */
16712  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_105copyElementBoundaryVelocityToParVec, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1258, __pyx_L1_error)
16713  __Pyx_GOTREF(__pyx_t_1);
16714  if (PyDict_SetItem(__pyx_d, __pyx_n_s_copyElementBoundaryVelocityToPar, __pyx_t_1) < 0) __PYX_ERR(0, 1258, __pyx_L1_error)
16715  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16716 
16717  /* "cpostprocessing.pyx":1272
16718  * ebq_v_par_local[ebN,permutations[ebN,k],I] = ebq_velocity[ebN,k,I]
16719  *
16720  * def addAverageToParVec(np.ndarray ebq_velocityAverage, # <<<<<<<<<<<<<<
16721  * np.ndarray[int, ndim=2] permutations,
16722  * np.ndarray ebq_v_par_local):
16723  */
16724  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_107addAverageToParVec, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1272, __pyx_L1_error)
16725  __Pyx_GOTREF(__pyx_t_1);
16726  if (PyDict_SetItem(__pyx_d, __pyx_n_s_addAverageToParVec, __pyx_t_1) < 0) __PYX_ERR(0, 1272, __pyx_L1_error)
16727  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16728 
16729  /* "cpostprocessing.pyx":1286
16730  * ebq_v_par_local[ebN, permutations[ebN,k], I] += ebq_velocityAverage[ebN, k, I]
16731  *
16732  * def copyParVecToElementBoundaryVelocity(np.ndarray ebq_velocity, # <<<<<<<<<<<<<<
16733  * np.ndarray[int, ndim=2] permutations,
16734  * np.ndarray ebq_v_par_local):
16735  */
16736  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15cpostprocessing_109copyParVecToElementBoundaryVelocity, NULL, __pyx_n_s_cpostprocessing); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1286, __pyx_L1_error)
16737  __Pyx_GOTREF(__pyx_t_1);
16738  if (PyDict_SetItem(__pyx_d, __pyx_n_s_copyParVecToElementBoundaryVeloc, __pyx_t_1) < 0) __PYX_ERR(0, 1286, __pyx_L1_error)
16739  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16740 
16741  /* "cpostprocessing.pyx":1
16742  * # A type of -*- python -*- file # <<<<<<<<<<<<<<
16743  * import numpy as np
16744  * cimport numpy as np
16745  */
16746  __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1, __pyx_L1_error)
16747  __Pyx_GOTREF(__pyx_t_1);
16748  if (PyDict_SetItem(__pyx_d, __pyx_n_s_test, __pyx_t_1) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
16749  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16750 
16751  /* "../miniconda3/envs/proteus-dev-up/lib/python3.10/site-packages/numpy/__init__.pxd":1014
16752  *
16753  *
16754  * cdef inline NPY_DATETIMEUNIT get_datetime64_unit(object obj) nogil: # <<<<<<<<<<<<<<
16755  * """
16756  * returns the unit part of the dtype for a numpy datetime64 object.
16757  */
16758 
16759  /*--- Wrapped vars code ---*/
16760 
16761  goto __pyx_L0;
16762  __pyx_L1_error:;
16763  __Pyx_XDECREF(__pyx_t_1);
16764  if (__pyx_m) {
16765  if (__pyx_d) {
16766  __Pyx_AddTraceback("init cpostprocessing", __pyx_clineno, __pyx_lineno, __pyx_filename);
16767  }
16768  Py_CLEAR(__pyx_m);
16769  } else if (!PyErr_Occurred()) {
16770  PyErr_SetString(PyExc_ImportError, "init cpostprocessing");
16771  }
16772  __pyx_L0:;
16773  __Pyx_RefNannyFinishContext();
16774  #if CYTHON_PEP489_MULTI_PHASE_INIT
16775  return (__pyx_m != NULL) ? 0 : -1;
16776  #elif PY_MAJOR_VERSION >= 3
16777  return __pyx_m;
16778  #else
16779  return;
16780  #endif
16781 }
16782 
16783 /* --- Runtime support code --- */
16784 /* Refnanny */
16785 #if CYTHON_REFNANNY
16786 static __Pyx_RefNannyAPIStruct *__Pyx_RefNannyImportAPI(const char *modname) {
16787  PyObject *m = NULL, *p = NULL;
16788  void *r = NULL;
16789  m = PyImport_ImportModule(modname);
16790  if (!m) goto end;
16791  p = PyObject_GetAttrString(m, "RefNannyAPI");
16792  if (!p) goto end;
16793  r = PyLong_AsVoidPtr(p);
16794 end:
16795  Py_XDECREF(p);
16796  Py_XDECREF(m);
16797  return (__Pyx_RefNannyAPIStruct *)r;
16798 }
16799 #endif
16800 
16801 /* PyObjectGetAttrStr */
16802 #if CYTHON_USE_TYPE_SLOTS
16803 static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStr(PyObject* obj, PyObject* attr_name) {
16804  PyTypeObject* tp = Py_TYPE(obj);
16805  if (likely(tp->tp_getattro))
16806  return tp->tp_getattro(obj, attr_name);
16807 #if PY_MAJOR_VERSION < 3
16808  if (likely(tp->tp_getattr))
16809  return tp->tp_getattr(obj, PyString_AS_STRING(attr_name));
16810 #endif
16811  return PyObject_GetAttr(obj, attr_name);
16812 }
16813 #endif
16814 
16815 /* GetBuiltinName */
16816 static PyObject *__Pyx_GetBuiltinName(PyObject *name) {
16817  PyObject* result = __Pyx_PyObject_GetAttrStr(__pyx_b, name);
16818  if (unlikely(!result)) {
16819  PyErr_Format(PyExc_NameError,
16820 #if PY_MAJOR_VERSION >= 3
16821  "name '%U' is not defined", name);
16822 #else
16823  "name '%.200s' is not defined", PyString_AS_STRING(name));
16824 #endif
16825  }
16826  return result;
16827 }
16828 
16829 /* RaiseArgTupleInvalid */
16830 static void __Pyx_RaiseArgtupleInvalid(
16831  const char* func_name,
16832  int exact,
16833  Py_ssize_t num_min,
16834  Py_ssize_t num_max,
16835  Py_ssize_t num_found)
16836 {
16837  Py_ssize_t num_expected;
16838  const char *more_or_less;
16839  if (num_found < num_min) {
16840  num_expected = num_min;
16841  more_or_less = "at least";
16842  } else {
16843  num_expected = num_max;
16844  more_or_less = "at most";
16845  }
16846  if (exact) {
16847  more_or_less = "exactly";
16848  }
16849  PyErr_Format(PyExc_TypeError,
16850  "%.200s() takes %.8s %" CYTHON_FORMAT_SSIZE_T "d positional argument%.1s (%" CYTHON_FORMAT_SSIZE_T "d given)",
16851  func_name, more_or_less, num_expected,
16852  (num_expected == 1) ? "" : "s", num_found);
16853 }
16854 
16855 /* RaiseDoubleKeywords */
16856 static void __Pyx_RaiseDoubleKeywordsError(
16857  const char* func_name,
16858  PyObject* kw_name)
16859 {
16860  PyErr_Format(PyExc_TypeError,
16861  #if PY_MAJOR_VERSION >= 3
16862  "%s() got multiple values for keyword argument '%U'", func_name, kw_name);
16863  #else
16864  "%s() got multiple values for keyword argument '%s'", func_name,
16865  PyString_AsString(kw_name));
16866  #endif
16867 }
16868 
16869 /* ParseKeywords */
16870 static int __Pyx_ParseOptionalKeywords(
16871  PyObject *kwds,
16872  PyObject **argnames[],
16873  PyObject *kwds2,
16874  PyObject *values[],
16875  Py_ssize_t num_pos_args,
16876  const char* function_name)
16877 {
16878  PyObject *key = 0, *value = 0;
16879  Py_ssize_t pos = 0;
16880  PyObject*** name;
16881  PyObject*** first_kw_arg = argnames + num_pos_args;
16882  while (PyDict_Next(kwds, &pos, &key, &value)) {
16883  name = first_kw_arg;
16884  while (*name && (**name != key)) name++;
16885  if (*name) {
16886  values[name-argnames] = value;
16887  continue;
16888  }
16889  name = first_kw_arg;
16890  #if PY_MAJOR_VERSION < 3
16891  if (likely(PyString_Check(key))) {
16892  while (*name) {
16893  if ((CYTHON_COMPILING_IN_PYPY || PyString_GET_SIZE(**name) == PyString_GET_SIZE(key))
16894  && _PyString_Eq(**name, key)) {
16895  values[name-argnames] = value;
16896  break;
16897  }
16898  name++;
16899  }
16900  if (*name) continue;
16901  else {
16902  PyObject*** argname = argnames;
16903  while (argname != first_kw_arg) {
16904  if ((**argname == key) || (
16905  (CYTHON_COMPILING_IN_PYPY || PyString_GET_SIZE(**argname) == PyString_GET_SIZE(key))
16906  && _PyString_Eq(**argname, key))) {
16907  goto arg_passed_twice;
16908  }
16909  argname++;
16910  }
16911  }
16912  } else
16913  #endif
16914  if (likely(PyUnicode_Check(key))) {
16915  while (*name) {
16916  int cmp = (**name == key) ? 0 :
16917  #if !CYTHON_COMPILING_IN_PYPY && PY_MAJOR_VERSION >= 3
16918  (__Pyx_PyUnicode_GET_LENGTH(**name) != __Pyx_PyUnicode_GET_LENGTH(key)) ? 1 :
16919  #endif
16920  PyUnicode_Compare(**name, key);
16921  if (cmp < 0 && unlikely(PyErr_Occurred())) goto bad;
16922  if (cmp == 0) {
16923  values[name-argnames] = value;
16924  break;
16925  }
16926  name++;
16927  }
16928  if (*name) continue;
16929  else {
16930  PyObject*** argname = argnames;
16931  while (argname != first_kw_arg) {
16932  int cmp = (**argname == key) ? 0 :
16933  #if !CYTHON_COMPILING_IN_PYPY && PY_MAJOR_VERSION >= 3
16934  (__Pyx_PyUnicode_GET_LENGTH(**argname) != __Pyx_PyUnicode_GET_LENGTH(key)) ? 1 :
16935  #endif
16936  PyUnicode_Compare(**argname, key);
16937  if (cmp < 0 && unlikely(PyErr_Occurred())) goto bad;
16938  if (cmp == 0) goto arg_passed_twice;
16939  argname++;
16940  }
16941  }
16942  } else
16943  goto invalid_keyword_type;
16944  if (kwds2) {
16945  if (unlikely(PyDict_SetItem(kwds2, key, value))) goto bad;
16946  } else {
16947  goto invalid_keyword;
16948  }
16949  }
16950  return 0;
16951 arg_passed_twice:
16952  __Pyx_RaiseDoubleKeywordsError(function_name, key);
16953  goto bad;
16954 invalid_keyword_type:
16955  PyErr_Format(PyExc_TypeError,
16956  "%.200s() keywords must be strings", function_name);
16957  goto bad;
16958 invalid_keyword:
16959  PyErr_Format(PyExc_TypeError,
16960  #if PY_MAJOR_VERSION < 3
16961  "%.200s() got an unexpected keyword argument '%.200s'",
16962  function_name, PyString_AsString(key));
16963  #else
16964  "%s() got an unexpected keyword argument '%U'",
16965  function_name, key);
16966  #endif
16967 bad:
16968  return -1;
16969 }
16970 
16971 /* ArgTypeTest */
16972 static int __Pyx__ArgTypeTest(PyObject *obj, PyTypeObject *type, const char *name, int exact)
16973 {
16974  if (unlikely(!type)) {
16975  PyErr_SetString(PyExc_SystemError, "Missing type object");
16976  return 0;
16977  }
16978  else if (exact) {
16979  #if PY_MAJOR_VERSION == 2
16980  if ((type == &PyBaseString_Type) && likely(__Pyx_PyBaseString_CheckExact(obj))) return 1;
16981  #endif
16982  }
16983  else {
16984  if (likely(__Pyx_TypeCheck(obj, type))) return 1;
16985  }
16986  PyErr_Format(PyExc_TypeError,
16987  "Argument '%.200s' has incorrect type (expected %.200s, got %.200s)",
16988  name, type->tp_name, Py_TYPE(obj)->tp_name);
16989  return 0;
16990 }
16991 
16992 /* PyObjectCall */
16993 #if CYTHON_COMPILING_IN_CPYTHON
16994 static CYTHON_INLINE PyObject* __Pyx_PyObject_Call(PyObject *func, PyObject *arg, PyObject *kw) {
16995  PyObject *result;
16996  ternaryfunc call = Py_TYPE(func)->tp_call;
16997  if (unlikely(!call))
16998  return PyObject_Call(func, arg, kw);
16999  if (unlikely(Py_EnterRecursiveCall((char*)" while calling a Python object")))
17000  return NULL;
17001  result = (*call)(func, arg, kw);
17002  Py_LeaveRecursiveCall();
17003  if (unlikely(!result) && unlikely(!PyErr_Occurred())) {
17004  PyErr_SetString(
17005  PyExc_SystemError,
17006  "NULL result without error in PyObject_Call");
17007  }
17008  return result;
17009 }
17010 #endif
17011 
17012 /* PyErrFetchRestore */
17013 #if CYTHON_FAST_THREAD_STATE
17014 static CYTHON_INLINE void __Pyx_ErrRestoreInState(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb) {
17015  PyObject *tmp_type, *tmp_value, *tmp_tb;
17016  tmp_type = tstate->curexc_type;
17017  tmp_value = tstate->curexc_value;
17018  tmp_tb = tstate->curexc_traceback;
17019  tstate->curexc_type = type;
17020  tstate->curexc_value = value;
17021  tstate->curexc_traceback = tb;
17022  Py_XDECREF(tmp_type);
17023  Py_XDECREF(tmp_value);
17024  Py_XDECREF(tmp_tb);
17025 }
17026 static CYTHON_INLINE void __Pyx_ErrFetchInState(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb) {
17027  *type = tstate->curexc_type;
17028  *value = tstate->curexc_value;
17029  *tb = tstate->curexc_traceback;
17030  tstate->curexc_type = 0;
17031  tstate->curexc_value = 0;
17032  tstate->curexc_traceback = 0;
17033 }
17034 #endif
17035 
17036 /* RaiseException */
17037 #if PY_MAJOR_VERSION < 3
17038 static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb,
17039  CYTHON_UNUSED PyObject *cause) {
17040  __Pyx_PyThreadState_declare
17041  Py_XINCREF(type);
17042  if (!value || value == Py_None)
17043  value = NULL;
17044  else
17045  Py_INCREF(value);
17046  if (!tb || tb == Py_None)
17047  tb = NULL;
17048  else {
17049  Py_INCREF(tb);
17050  if (!PyTraceBack_Check(tb)) {
17051  PyErr_SetString(PyExc_TypeError,
17052  "raise: arg 3 must be a traceback or None");
17053  goto raise_error;
17054  }
17055  }
17056  if (PyType_Check(type)) {
17057 #if CYTHON_COMPILING_IN_PYPY
17058  if (!value) {
17059  Py_INCREF(Py_None);
17060  value = Py_None;
17061  }
17062 #endif
17063  PyErr_NormalizeException(&type, &value, &tb);
17064  } else {
17065  if (value) {
17066  PyErr_SetString(PyExc_TypeError,
17067  "instance exception may not have a separate value");
17068  goto raise_error;
17069  }
17070  value = type;
17071  type = (PyObject*) Py_TYPE(type);
17072  Py_INCREF(type);
17073  if (!PyType_IsSubtype((PyTypeObject *)type, (PyTypeObject *)PyExc_BaseException)) {
17074  PyErr_SetString(PyExc_TypeError,
17075  "raise: exception class must be a subclass of BaseException");
17076  goto raise_error;
17077  }
17078  }
17079  __Pyx_PyThreadState_assign
17080  __Pyx_ErrRestore(type, value, tb);
17081  return;
17082 raise_error:
17083  Py_XDECREF(value);
17084  Py_XDECREF(type);
17085  Py_XDECREF(tb);
17086  return;
17087 }
17088 #else
17089 static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb, PyObject *cause) {
17090  PyObject* owned_instance = NULL;
17091  if (tb == Py_None) {
17092  tb = 0;
17093  } else if (tb && !PyTraceBack_Check(tb)) {
17094  PyErr_SetString(PyExc_TypeError,
17095  "raise: arg 3 must be a traceback or None");
17096  goto bad;
17097  }
17098  if (value == Py_None)
17099  value = 0;
17100  if (PyExceptionInstance_Check(type)) {
17101  if (value) {
17102  PyErr_SetString(PyExc_TypeError,
17103  "instance exception may not have a separate value");
17104  goto bad;
17105  }
17106  value = type;
17107  type = (PyObject*) Py_TYPE(value);
17108  } else if (PyExceptionClass_Check(type)) {
17109  PyObject *instance_class = NULL;
17110  if (value && PyExceptionInstance_Check(value)) {
17111  instance_class = (PyObject*) Py_TYPE(value);
17112  if (instance_class != type) {
17113  int is_subclass = PyObject_IsSubclass(instance_class, type);
17114  if (!is_subclass) {
17115  instance_class = NULL;
17116  } else if (unlikely(is_subclass == -1)) {
17117  goto bad;
17118  } else {
17119  type = instance_class;
17120  }
17121  }
17122  }
17123  if (!instance_class) {
17124  PyObject *args;
17125  if (!value)
17126  args = PyTuple_New(0);
17127  else if (PyTuple_Check(value)) {
17128  Py_INCREF(value);
17129  args = value;
17130  } else
17131  args = PyTuple_Pack(1, value);
17132  if (!args)
17133  goto bad;
17134  owned_instance = PyObject_Call(type, args, NULL);
17135  Py_DECREF(args);
17136  if (!owned_instance)
17137  goto bad;
17138  value = owned_instance;
17139  if (!PyExceptionInstance_Check(value)) {
17140  PyErr_Format(PyExc_TypeError,
17141  "calling %R should have returned an instance of "
17142  "BaseException, not %R",
17143  type, Py_TYPE(value));
17144  goto bad;
17145  }
17146  }
17147  } else {
17148  PyErr_SetString(PyExc_TypeError,
17149  "raise: exception class must be a subclass of BaseException");
17150  goto bad;
17151  }
17152  if (cause) {
17153  PyObject *fixed_cause;
17154  if (cause == Py_None) {
17155  fixed_cause = NULL;
17156  } else if (PyExceptionClass_Check(cause)) {
17157  fixed_cause = PyObject_CallObject(cause, NULL);
17158  if (fixed_cause == NULL)
17159  goto bad;
17160  } else if (PyExceptionInstance_Check(cause)) {
17161  fixed_cause = cause;
17162  Py_INCREF(fixed_cause);
17163  } else {
17164  PyErr_SetString(PyExc_TypeError,
17165  "exception causes must derive from "
17166  "BaseException");
17167  goto bad;
17168  }
17169  PyException_SetCause(value, fixed_cause);
17170  }
17171  PyErr_SetObject(type, value);
17172  if (tb) {
17173 #if CYTHON_COMPILING_IN_PYPY
17174  PyObject *tmp_type, *tmp_value, *tmp_tb;
17175  PyErr_Fetch(&tmp_type, &tmp_value, &tmp_tb);
17176  Py_INCREF(tb);
17177  PyErr_Restore(tmp_type, tmp_value, tb);
17178  Py_XDECREF(tmp_tb);
17179 #else
17180  PyThreadState *tstate = __Pyx_PyThreadState_Current;
17181  PyObject* tmp_tb = tstate->curexc_traceback;
17182  if (tb != tmp_tb) {
17183  Py_INCREF(tb);
17184  tstate->curexc_traceback = tb;
17185  Py_XDECREF(tmp_tb);
17186  }
17187 #endif
17188  }
17189 bad:
17190  Py_XDECREF(owned_instance);
17191  return;
17192 }
17193 #endif
17194 
17195 /* IsLittleEndian */
17196 static CYTHON_INLINE int __Pyx_Is_Little_Endian(void)
17197 {
17198  union {
17199  uint32_t u32;
17200  uint8_t u8[4];
17201  } S;
17202  S.u32 = 0x01020304;
17203  return S.u8[0] == 4;
17204 }
17205 
17206 /* BufferFormatCheck */
17207 static void __Pyx_BufFmt_Init(__Pyx_BufFmt_Context* ctx,
17208  __Pyx_BufFmt_StackElem* stack,
17209  __Pyx_TypeInfo* type) {
17210  stack[0].field = &ctx->root;
17211  stack[0].parent_offset = 0;
17212  ctx->root.type = type;
17213  ctx->root.name = "buffer dtype";
17214  ctx->root.offset = 0;
17215  ctx->head = stack;
17216  ctx->head->field = &ctx->root;
17217  ctx->fmt_offset = 0;
17218  ctx->head->parent_offset = 0;
17219  ctx->new_packmode = '@';
17220  ctx->enc_packmode = '@';
17221  ctx->new_count = 1;
17222  ctx->enc_count = 0;
17223  ctx->enc_type = 0;
17224  ctx->is_complex = 0;
17225  ctx->is_valid_array = 0;
17226  ctx->struct_alignment = 0;
17227  while (type->typegroup == 'S') {
17228  ++ctx->head;
17229  ctx->head->field = type->fields;
17230  ctx->head->parent_offset = 0;
17231  type = type->fields->type;
17232  }
17233 }
17234 static int __Pyx_BufFmt_ParseNumber(const char** ts) {
17235  int count;
17236  const char* t = *ts;
17237  if (*t < '0' || *t > '9') {
17238  return -1;
17239  } else {
17240  count = *t++ - '0';
17241  while (*t >= '0' && *t <= '9') {
17242  count *= 10;
17243  count += *t++ - '0';
17244  }
17245  }
17246  *ts = t;
17247  return count;
17248 }
17249 static int __Pyx_BufFmt_ExpectNumber(const char **ts) {
17250  int number = __Pyx_BufFmt_ParseNumber(ts);
17251  if (number == -1)
17252  PyErr_Format(PyExc_ValueError,\
17253  "Does not understand character buffer dtype format string ('%c')", **ts);
17254  return number;
17255 }
17256 static void __Pyx_BufFmt_RaiseUnexpectedChar(char ch) {
17257  PyErr_Format(PyExc_ValueError,
17258  "Unexpected format string character: '%c'", ch);
17259 }
17260 static const char* __Pyx_BufFmt_DescribeTypeChar(char ch, int is_complex) {
17261  switch (ch) {
17262  case '?': return "'bool'";
17263  case 'c': return "'char'";
17264  case 'b': return "'signed char'";
17265  case 'B': return "'unsigned char'";
17266  case 'h': return "'short'";
17267  case 'H': return "'unsigned short'";
17268  case 'i': return "'int'";
17269  case 'I': return "'unsigned int'";
17270  case 'l': return "'long'";
17271  case 'L': return "'unsigned long'";
17272  case 'q': return "'long long'";
17273  case 'Q': return "'unsigned long long'";
17274  case 'f': return (is_complex ? "'complex float'" : "'float'");
17275  case 'd': return (is_complex ? "'complex double'" : "'double'");
17276  case 'g': return (is_complex ? "'complex long double'" : "'long double'");
17277  case 'T': return "a struct";
17278  case 'O': return "Python object";
17279  case 'P': return "a pointer";
17280  case 's': case 'p': return "a string";
17281  case 0: return "end";
17282  default: return "unparseable format string";
17283  }
17284 }
17285 static size_t __Pyx_BufFmt_TypeCharToStandardSize(char ch, int is_complex) {
17286  switch (ch) {
17287  case '?': case 'c': case 'b': case 'B': case 's': case 'p': return 1;
17288  case 'h': case 'H': return 2;
17289  case 'i': case 'I': case 'l': case 'L': return 4;
17290  case 'q': case 'Q': return 8;
17291  case 'f': return (is_complex ? 8 : 4);
17292  case 'd': return (is_complex ? 16 : 8);
17293  case 'g': {
17294  PyErr_SetString(PyExc_ValueError, "Python does not define a standard format string size for long double ('g')..");
17295  return 0;
17296  }
17297  case 'O': case 'P': return sizeof(void*);
17298  default:
17299  __Pyx_BufFmt_RaiseUnexpectedChar(ch);
17300  return 0;
17301  }
17302 }
17303 static size_t __Pyx_BufFmt_TypeCharToNativeSize(char ch, int is_complex) {
17304  switch (ch) {
17305  case '?': case 'c': case 'b': case 'B': case 's': case 'p': return 1;
17306  case 'h': case 'H': return sizeof(short);
17307  case 'i': case 'I': return sizeof(int);
17308  case 'l': case 'L': return sizeof(long);
17309  #ifdef HAVE_LONG_LONG
17310  case 'q': case 'Q': return sizeof(PY_LONG_LONG);
17311  #endif
17312  case 'f': return sizeof(float) * (is_complex ? 2 : 1);
17313  case 'd': return sizeof(double) * (is_complex ? 2 : 1);
17314  case 'g': return sizeof(long double) * (is_complex ? 2 : 1);
17315  case 'O': case 'P': return sizeof(void*);
17316  default: {
17317  __Pyx_BufFmt_RaiseUnexpectedChar(ch);
17318  return 0;
17319  }
17320  }
17321 }
17322 typedef struct { char c; short x; } __Pyx_st_short;
17323 typedef struct { char c; int x; } __Pyx_st_int;
17324 typedef struct { char c; long x; } __Pyx_st_long;
17325 typedef struct { char c; float x; } __Pyx_st_float;
17326 typedef struct { char c; double x; } __Pyx_st_double;
17327 typedef struct { char c; long double x; } __Pyx_st_longdouble;
17328 typedef struct { char c; void *x; } __Pyx_st_void_p;
17329 #ifdef HAVE_LONG_LONG
17330 typedef struct { char c; PY_LONG_LONG x; } __Pyx_st_longlong;
17331 #endif
17332 static size_t __Pyx_BufFmt_TypeCharToAlignment(char ch, CYTHON_UNUSED int is_complex) {
17333  switch (ch) {
17334  case '?': case 'c': case 'b': case 'B': case 's': case 'p': return 1;
17335  case 'h': case 'H': return sizeof(__Pyx_st_short) - sizeof(short);
17336  case 'i': case 'I': return sizeof(__Pyx_st_int) - sizeof(int);
17337  case 'l': case 'L': return sizeof(__Pyx_st_long) - sizeof(long);
17338 #ifdef HAVE_LONG_LONG
17339  case 'q': case 'Q': return sizeof(__Pyx_st_longlong) - sizeof(PY_LONG_LONG);
17340 #endif
17341  case 'f': return sizeof(__Pyx_st_float) - sizeof(float);
17342  case 'd': return sizeof(__Pyx_st_double) - sizeof(double);
17343  case 'g': return sizeof(__Pyx_st_longdouble) - sizeof(long double);
17344  case 'P': case 'O': return sizeof(__Pyx_st_void_p) - sizeof(void*);
17345  default:
17346  __Pyx_BufFmt_RaiseUnexpectedChar(ch);
17347  return 0;
17348  }
17349 }
17350 /* These are for computing the padding at the end of the struct to align
17351  on the first member of the struct. This will probably the same as above,
17352  but we don't have any guarantees.
17353  */
17354 typedef struct { short x; char c; } __Pyx_pad_short;
17355 typedef struct { int x; char c; } __Pyx_pad_int;
17356 typedef struct { long x; char c; } __Pyx_pad_long;
17357 typedef struct { float x; char c; } __Pyx_pad_float;
17358 typedef struct { double x; char c; } __Pyx_pad_double;
17359 typedef struct { long double x; char c; } __Pyx_pad_longdouble;
17360 typedef struct { void *x; char c; } __Pyx_pad_void_p;
17361 #ifdef HAVE_LONG_LONG
17362 typedef struct { PY_LONG_LONG x; char c; } __Pyx_pad_longlong;
17363 #endif
17364 static size_t __Pyx_BufFmt_TypeCharToPadding(char ch, CYTHON_UNUSED int is_complex) {
17365  switch (ch) {
17366  case '?': case 'c': case 'b': case 'B': case 's': case 'p': return 1;
17367  case 'h': case 'H': return sizeof(__Pyx_pad_short) - sizeof(short);
17368  case 'i': case 'I': return sizeof(__Pyx_pad_int) - sizeof(int);
17369  case 'l': case 'L': return sizeof(__Pyx_pad_long) - sizeof(long);
17370 #ifdef HAVE_LONG_LONG
17371  case 'q': case 'Q': return sizeof(__Pyx_pad_longlong) - sizeof(PY_LONG_LONG);
17372 #endif
17373  case 'f': return sizeof(__Pyx_pad_float) - sizeof(float);
17374  case 'd': return sizeof(__Pyx_pad_double) - sizeof(double);
17375  case 'g': return sizeof(__Pyx_pad_longdouble) - sizeof(long double);
17376  case 'P': case 'O': return sizeof(__Pyx_pad_void_p) - sizeof(void*);
17377  default:
17378  __Pyx_BufFmt_RaiseUnexpectedChar(ch);
17379  return 0;
17380  }
17381 }
17382 static char __Pyx_BufFmt_TypeCharToGroup(char ch, int is_complex) {
17383  switch (ch) {
17384  case 'c':
17385  return 'H';
17386  case 'b': case 'h': case 'i':
17387  case 'l': case 'q': case 's': case 'p':
17388  return 'I';
17389  case '?': case 'B': case 'H': case 'I': case 'L': case 'Q':
17390  return 'U';
17391  case 'f': case 'd': case 'g':
17392  return (is_complex ? 'C' : 'R');
17393  case 'O':
17394  return 'O';
17395  case 'P':
17396  return 'P';
17397  default: {
17398  __Pyx_BufFmt_RaiseUnexpectedChar(ch);
17399  return 0;
17400  }
17401  }
17402 }
17403 static void __Pyx_BufFmt_RaiseExpected(__Pyx_BufFmt_Context* ctx) {
17404  if (ctx->head == NULL || ctx->head->field == &ctx->root) {
17405  const char* expected;
17406  const char* quote;
17407  if (ctx->head == NULL) {
17408  expected = "end";
17409  quote = "";
17410  } else {
17411  expected = ctx->head->field->type->name;
17412  quote = "'";
17413  }
17414  PyErr_Format(PyExc_ValueError,
17415  "Buffer dtype mismatch, expected %s%s%s but got %s",
17416  quote, expected, quote,
17417  __Pyx_BufFmt_DescribeTypeChar(ctx->enc_type, ctx->is_complex));
17418  } else {
17419  __Pyx_StructField* field = ctx->head->field;
17420  __Pyx_StructField* parent = (ctx->head - 1)->field;
17421  PyErr_Format(PyExc_ValueError,
17422  "Buffer dtype mismatch, expected '%s' but got %s in '%s.%s'",
17423  field->type->name, __Pyx_BufFmt_DescribeTypeChar(ctx->enc_type, ctx->is_complex),
17424  parent->type->name, field->name);
17425  }
17426 }
17427 static int __Pyx_BufFmt_ProcessTypeChunk(__Pyx_BufFmt_Context* ctx) {
17428  char group;
17429  size_t size, offset, arraysize = 1;
17430  if (ctx->enc_type == 0) return 0;
17431  if (ctx->head->field->type->arraysize[0]) {
17432  int i, ndim = 0;
17433  if (ctx->enc_type == 's' || ctx->enc_type == 'p') {
17434  ctx->is_valid_array = ctx->head->field->type->ndim == 1;
17435  ndim = 1;
17436  if (ctx->enc_count != ctx->head->field->type->arraysize[0]) {
17437  PyErr_Format(PyExc_ValueError,
17438  "Expected a dimension of size %zu, got %zu",
17439  ctx->head->field->type->arraysize[0], ctx->enc_count);
17440  return -1;
17441  }
17442  }
17443  if (!ctx->is_valid_array) {
17444  PyErr_Format(PyExc_ValueError, "Expected %d dimensions, got %d",
17445  ctx->head->field->type->ndim, ndim);
17446  return -1;
17447  }
17448  for (i = 0; i < ctx->head->field->type->ndim; i++) {
17449  arraysize *= ctx->head->field->type->arraysize[i];
17450  }
17451  ctx->is_valid_array = 0;
17452  ctx->enc_count = 1;
17453  }
17454  group = __Pyx_BufFmt_TypeCharToGroup(ctx->enc_type, ctx->is_complex);
17455  do {
17456  __Pyx_StructField* field = ctx->head->field;
17457  __Pyx_TypeInfo* type = field->type;
17458  if (ctx->enc_packmode == '@' || ctx->enc_packmode == '^') {
17459  size = __Pyx_BufFmt_TypeCharToNativeSize(ctx->enc_type, ctx->is_complex);
17460  } else {
17461  size = __Pyx_BufFmt_TypeCharToStandardSize(ctx->enc_type, ctx->is_complex);
17462  }
17463  if (ctx->enc_packmode == '@') {
17464  size_t align_at = __Pyx_BufFmt_TypeCharToAlignment(ctx->enc_type, ctx->is_complex);
17465  size_t align_mod_offset;
17466  if (align_at == 0) return -1;
17467  align_mod_offset = ctx->fmt_offset % align_at;
17468  if (align_mod_offset > 0) ctx->fmt_offset += align_at - align_mod_offset;
17469  if (ctx->struct_alignment == 0)
17470  ctx->struct_alignment = __Pyx_BufFmt_TypeCharToPadding(ctx->enc_type,
17471  ctx->is_complex);
17472  }
17473  if (type->size != size || type->typegroup != group) {
17474  if (type->typegroup == 'C' && type->fields != NULL) {
17475  size_t parent_offset = ctx->head->parent_offset + field->offset;
17476  ++ctx->head;
17477  ctx->head->field = type->fields;
17478  ctx->head->parent_offset = parent_offset;
17479  continue;
17480  }
17481  if ((type->typegroup == 'H' || group == 'H') && type->size == size) {
17482  } else {
17483  __Pyx_BufFmt_RaiseExpected(ctx);
17484  return -1;
17485  }
17486  }
17487  offset = ctx->head->parent_offset + field->offset;
17488  if (ctx->fmt_offset != offset) {
17489  PyErr_Format(PyExc_ValueError,
17490  "Buffer dtype mismatch; next field is at offset %" CYTHON_FORMAT_SSIZE_T "d but %" CYTHON_FORMAT_SSIZE_T "d expected",
17491  (Py_ssize_t)ctx->fmt_offset, (Py_ssize_t)offset);
17492  return -1;
17493  }
17494  ctx->fmt_offset += size;
17495  if (arraysize)
17496  ctx->fmt_offset += (arraysize - 1) * size;
17497  --ctx->enc_count;
17498  while (1) {
17499  if (field == &ctx->root) {
17500  ctx->head = NULL;
17501  if (ctx->enc_count != 0) {
17502  __Pyx_BufFmt_RaiseExpected(ctx);
17503  return -1;
17504  }
17505  break;
17506  }
17507  ctx->head->field = ++field;
17508  if (field->type == NULL) {
17509  --ctx->head;
17510  field = ctx->head->field;
17511  continue;
17512  } else if (field->type->typegroup == 'S') {
17513  size_t parent_offset = ctx->head->parent_offset + field->offset;
17514  if (field->type->fields->type == NULL) continue;
17515  field = field->type->fields;
17516  ++ctx->head;
17517  ctx->head->field = field;
17518  ctx->head->parent_offset = parent_offset;
17519  break;
17520  } else {
17521  break;
17522  }
17523  }
17524  } while (ctx->enc_count);
17525  ctx->enc_type = 0;
17526  ctx->is_complex = 0;
17527  return 0;
17528 }
17529 static PyObject *
17530 __pyx_buffmt_parse_array(__Pyx_BufFmt_Context* ctx, const char** tsp)
17531 {
17532  const char *ts = *tsp;
17533  int i = 0, number, ndim;
17534  ++ts;
17535  if (ctx->new_count != 1) {
17536  PyErr_SetString(PyExc_ValueError,
17537  "Cannot handle repeated arrays in format string");
17538  return NULL;
17539  }
17540  if (__Pyx_BufFmt_ProcessTypeChunk(ctx) == -1) return NULL;
17541  ndim = ctx->head->field->type->ndim;
17542  while (*ts && *ts != ')') {
17543  switch (*ts) {
17544  case ' ': case '\f': case '\r': case '\n': case '\t': case '\v': continue;
17545  default: break;
17546  }
17547  number = __Pyx_BufFmt_ExpectNumber(&ts);
17548  if (number == -1) return NULL;
17549  if (i < ndim && (size_t) number != ctx->head->field->type->arraysize[i])
17550  return PyErr_Format(PyExc_ValueError,
17551  "Expected a dimension of size %zu, got %d",
17552  ctx->head->field->type->arraysize[i], number);
17553  if (*ts != ',' && *ts != ')')
17554  return PyErr_Format(PyExc_ValueError,
17555  "Expected a comma in format string, got '%c'", *ts);
17556  if (*ts == ',') ts++;
17557  i++;
17558  }
17559  if (i != ndim)
17560  return PyErr_Format(PyExc_ValueError, "Expected %d dimension(s), got %d",
17561  ctx->head->field->type->ndim, i);
17562  if (!*ts) {
17563  PyErr_SetString(PyExc_ValueError,
17564  "Unexpected end of format string, expected ')'");
17565  return NULL;
17566  }
17567  ctx->is_valid_array = 1;
17568  ctx->new_count = 1;
17569  *tsp = ++ts;
17570  return Py_None;
17571 }
17572 static const char* __Pyx_BufFmt_CheckString(__Pyx_BufFmt_Context* ctx, const char* ts) {
17573  int got_Z = 0;
17574  while (1) {
17575  switch(*ts) {
17576  case 0:
17577  if (ctx->enc_type != 0 && ctx->head == NULL) {
17578  __Pyx_BufFmt_RaiseExpected(ctx);
17579  return NULL;
17580  }
17581  if (__Pyx_BufFmt_ProcessTypeChunk(ctx) == -1) return NULL;
17582  if (ctx->head != NULL) {
17583  __Pyx_BufFmt_RaiseExpected(ctx);
17584  return NULL;
17585  }
17586  return ts;
17587  case ' ':
17588  case '\r':
17589  case '\n':
17590  ++ts;
17591  break;
17592  case '<':
17593  if (!__Pyx_Is_Little_Endian()) {
17594  PyErr_SetString(PyExc_ValueError, "Little-endian buffer not supported on big-endian compiler");
17595  return NULL;
17596  }
17597  ctx->new_packmode = '=';
17598  ++ts;
17599  break;
17600  case '>':
17601  case '!':
17602  if (__Pyx_Is_Little_Endian()) {
17603  PyErr_SetString(PyExc_ValueError, "Big-endian buffer not supported on little-endian compiler");
17604  return NULL;
17605  }
17606  ctx->new_packmode = '=';
17607  ++ts;
17608  break;
17609  case '=':
17610  case '@':
17611  case '^':
17612  ctx->new_packmode = *ts++;
17613  break;
17614  case 'T':
17615  {
17616  const char* ts_after_sub;
17617  size_t i, struct_count = ctx->new_count;
17618  size_t struct_alignment = ctx->struct_alignment;
17619  ctx->new_count = 1;
17620  ++ts;
17621  if (*ts != '{') {
17622  PyErr_SetString(PyExc_ValueError, "Buffer acquisition: Expected '{' after 'T'");
17623  return NULL;
17624  }
17625  if (__Pyx_BufFmt_ProcessTypeChunk(ctx) == -1) return NULL;
17626  ctx->enc_type = 0;
17627  ctx->enc_count = 0;
17628  ctx->struct_alignment = 0;
17629  ++ts;
17630  ts_after_sub = ts;
17631  for (i = 0; i != struct_count; ++i) {
17632  ts_after_sub = __Pyx_BufFmt_CheckString(ctx, ts);
17633  if (!ts_after_sub) return NULL;
17634  }
17635  ts = ts_after_sub;
17636  if (struct_alignment) ctx->struct_alignment = struct_alignment;
17637  }
17638  break;
17639  case '}':
17640  {
17641  size_t alignment = ctx->struct_alignment;
17642  ++ts;
17643  if (__Pyx_BufFmt_ProcessTypeChunk(ctx) == -1) return NULL;
17644  ctx->enc_type = 0;
17645  if (alignment && ctx->fmt_offset % alignment) {
17646  ctx->fmt_offset += alignment - (ctx->fmt_offset % alignment);
17647  }
17648  }
17649  return ts;
17650  case 'x':
17651  if (__Pyx_BufFmt_ProcessTypeChunk(ctx) == -1) return NULL;
17652  ctx->fmt_offset += ctx->new_count;
17653  ctx->new_count = 1;
17654  ctx->enc_count = 0;
17655  ctx->enc_type = 0;
17656  ctx->enc_packmode = ctx->new_packmode;
17657  ++ts;
17658  break;
17659  case 'Z':
17660  got_Z = 1;
17661  ++ts;
17662  if (*ts != 'f' && *ts != 'd' && *ts != 'g') {
17663  __Pyx_BufFmt_RaiseUnexpectedChar('Z');
17664  return NULL;
17665  }
17666  CYTHON_FALLTHROUGH;
17667  case '?': case 'c': case 'b': case 'B': case 'h': case 'H': case 'i': case 'I':
17668  case 'l': case 'L': case 'q': case 'Q':
17669  case 'f': case 'd': case 'g':
17670  case 'O': case 'p':
17671  if ((ctx->enc_type == *ts) && (got_Z == ctx->is_complex) &&
17672  (ctx->enc_packmode == ctx->new_packmode) && (!ctx->is_valid_array)) {
17673  ctx->enc_count += ctx->new_count;
17674  ctx->new_count = 1;
17675  got_Z = 0;
17676  ++ts;
17677  break;
17678  }
17679  CYTHON_FALLTHROUGH;
17680  case 's':
17681  if (__Pyx_BufFmt_ProcessTypeChunk(ctx) == -1) return NULL;
17682  ctx->enc_count = ctx->new_count;
17683  ctx->enc_packmode = ctx->new_packmode;
17684  ctx->enc_type = *ts;
17685  ctx->is_complex = got_Z;
17686  ++ts;
17687  ctx->new_count = 1;
17688  got_Z = 0;
17689  break;
17690  case ':':
17691  ++ts;
17692  while(*ts != ':') ++ts;
17693  ++ts;
17694  break;
17695  case '(':
17696  if (!__pyx_buffmt_parse_array(ctx, &ts)) return NULL;
17697  break;
17698  default:
17699  {
17700  int number = __Pyx_BufFmt_ExpectNumber(&ts);
17701  if (number == -1) return NULL;
17702  ctx->new_count = (size_t)number;
17703  }
17704  }
17705  }
17706 }
17707 
17708 /* BufferGetAndValidate */
17709  static CYTHON_INLINE void __Pyx_SafeReleaseBuffer(Py_buffer* info) {
17710  if (unlikely(info->buf == NULL)) return;
17711  if (info->suboffsets == __Pyx_minusones) info->suboffsets = NULL;
17712  __Pyx_ReleaseBuffer(info);
17713 }
17714 static void __Pyx_ZeroBuffer(Py_buffer* buf) {
17715  buf->buf = NULL;
17716  buf->obj = NULL;
17717  buf->strides = __Pyx_zeros;
17718  buf->shape = __Pyx_zeros;
17719  buf->suboffsets = __Pyx_minusones;
17720 }
17721 static int __Pyx__GetBufferAndValidate(
17722  Py_buffer* buf, PyObject* obj, __Pyx_TypeInfo* dtype, int flags,
17723  int nd, int cast, __Pyx_BufFmt_StackElem* stack)
17724 {
17725  buf->buf = NULL;
17726  if (unlikely(__Pyx_GetBuffer(obj, buf, flags) == -1)) {
17727  __Pyx_ZeroBuffer(buf);
17728  return -1;
17729  }
17730  if (unlikely(buf->ndim != nd)) {
17731  PyErr_Format(PyExc_ValueError,
17732  "Buffer has wrong number of dimensions (expected %d, got %d)",
17733  nd, buf->ndim);
17734  goto fail;
17735  }
17736  if (!cast) {
17737  __Pyx_BufFmt_Context ctx;
17738  __Pyx_BufFmt_Init(&ctx, stack, dtype);
17739  if (!__Pyx_BufFmt_CheckString(&ctx, buf->format)) goto fail;
17740  }
17741  if (unlikely((size_t)buf->itemsize != dtype->size)) {
17742  PyErr_Format(PyExc_ValueError,
17743  "Item size of buffer (%" CYTHON_FORMAT_SSIZE_T "d byte%s) does not match size of '%s' (%" CYTHON_FORMAT_SSIZE_T "d byte%s)",
17744  buf->itemsize, (buf->itemsize > 1) ? "s" : "",
17745  dtype->name, (Py_ssize_t)dtype->size, (dtype->size > 1) ? "s" : "");
17746  goto fail;
17747  }
17748  if (buf->suboffsets == NULL) buf->suboffsets = __Pyx_minusones;
17749  return 0;
17750 fail:;
17751  __Pyx_SafeReleaseBuffer(buf);
17752  return -1;
17753 }
17754 
17755 /* GetItemInt */
17756  static PyObject *__Pyx_GetItemInt_Generic(PyObject *o, PyObject* j) {
17757  PyObject *r;
17758  if (!j) return NULL;
17759  r = PyObject_GetItem(o, j);
17760  Py_DECREF(j);
17761  return r;
17762 }
17763 static CYTHON_INLINE PyObject *__Pyx_GetItemInt_List_Fast(PyObject *o, Py_ssize_t i,
17764  CYTHON_NCP_UNUSED int wraparound,
17765  CYTHON_NCP_UNUSED int boundscheck) {
17766 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
17767  Py_ssize_t wrapped_i = i;
17768  if (wraparound & unlikely(i < 0)) {
17769  wrapped_i += PyList_GET_SIZE(o);
17770  }
17771  if ((!boundscheck) || likely(__Pyx_is_valid_index(wrapped_i, PyList_GET_SIZE(o)))) {
17772  PyObject *r = PyList_GET_ITEM(o, wrapped_i);
17773  Py_INCREF(r);
17774  return r;
17775  }
17776  return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i));
17777 #else
17778  return PySequence_GetItem(o, i);
17779 #endif
17780 }
17781 static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Tuple_Fast(PyObject *o, Py_ssize_t i,
17782  CYTHON_NCP_UNUSED int wraparound,
17783  CYTHON_NCP_UNUSED int boundscheck) {
17784 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
17785  Py_ssize_t wrapped_i = i;
17786  if (wraparound & unlikely(i < 0)) {
17787  wrapped_i += PyTuple_GET_SIZE(o);
17788  }
17789  if ((!boundscheck) || likely(__Pyx_is_valid_index(wrapped_i, PyTuple_GET_SIZE(o)))) {
17790  PyObject *r = PyTuple_GET_ITEM(o, wrapped_i);
17791  Py_INCREF(r);
17792  return r;
17793  }
17794  return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i));
17795 #else
17796  return PySequence_GetItem(o, i);
17797 #endif
17798 }
17799 static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Fast(PyObject *o, Py_ssize_t i, int is_list,
17800  CYTHON_NCP_UNUSED int wraparound,
17801  CYTHON_NCP_UNUSED int boundscheck) {
17802 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS && CYTHON_USE_TYPE_SLOTS
17803  if (is_list || PyList_CheckExact(o)) {
17804  Py_ssize_t n = ((!wraparound) | likely(i >= 0)) ? i : i + PyList_GET_SIZE(o);
17805  if ((!boundscheck) || (likely(__Pyx_is_valid_index(n, PyList_GET_SIZE(o))))) {
17806  PyObject *r = PyList_GET_ITEM(o, n);
17807  Py_INCREF(r);
17808  return r;
17809  }
17810  }
17811  else if (PyTuple_CheckExact(o)) {
17812  Py_ssize_t n = ((!wraparound) | likely(i >= 0)) ? i : i + PyTuple_GET_SIZE(o);
17813  if ((!boundscheck) || likely(__Pyx_is_valid_index(n, PyTuple_GET_SIZE(o)))) {
17814  PyObject *r = PyTuple_GET_ITEM(o, n);
17815  Py_INCREF(r);
17816  return r;
17817  }
17818  } else {
17819  PySequenceMethods *m = Py_TYPE(o)->tp_as_sequence;
17820  if (likely(m && m->sq_item)) {
17821  if (wraparound && unlikely(i < 0) && likely(m->sq_length)) {
17822  Py_ssize_t l = m->sq_length(o);
17823  if (likely(l >= 0)) {
17824  i += l;
17825  } else {
17826  if (!PyErr_ExceptionMatches(PyExc_OverflowError))
17827  return NULL;
17828  PyErr_Clear();
17829  }
17830  }
17831  return m->sq_item(o, i);
17832  }
17833  }
17834 #else
17835  if (is_list || PySequence_Check(o)) {
17836  return PySequence_GetItem(o, i);
17837  }
17838 #endif
17839  return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i));
17840 }
17841 
17842 /* ObjectGetItem */
17843  #if CYTHON_USE_TYPE_SLOTS
17844 static PyObject *__Pyx_PyObject_GetIndex(PyObject *obj, PyObject* index) {
17845  PyObject *runerr;
17846  Py_ssize_t key_value;
17847  PySequenceMethods *m = Py_TYPE(obj)->tp_as_sequence;
17848  if (unlikely(!(m && m->sq_item))) {
17849  PyErr_Format(PyExc_TypeError, "'%.200s' object is not subscriptable", Py_TYPE(obj)->tp_name);
17850  return NULL;
17851  }
17852  key_value = __Pyx_PyIndex_AsSsize_t(index);
17853  if (likely(key_value != -1 || !(runerr = PyErr_Occurred()))) {
17854  return __Pyx_GetItemInt_Fast(obj, key_value, 0, 1, 1);
17855  }
17856  if (PyErr_GivenExceptionMatches(runerr, PyExc_OverflowError)) {
17857  PyErr_Clear();
17858  PyErr_Format(PyExc_IndexError, "cannot fit '%.200s' into an index-sized integer", Py_TYPE(index)->tp_name);
17859  }
17860  return NULL;
17861 }
17862 static PyObject *__Pyx_PyObject_GetItem(PyObject *obj, PyObject* key) {
17863  PyMappingMethods *m = Py_TYPE(obj)->tp_as_mapping;
17864  if (likely(m && m->mp_subscript)) {
17865  return m->mp_subscript(obj, key);
17866  }
17867  return __Pyx_PyObject_GetIndex(obj, key);
17868 }
17869 #endif
17870 
17871 /* BufferIndexError */
17872  static void __Pyx_RaiseBufferIndexError(int axis) {
17873  PyErr_Format(PyExc_IndexError,
17874  "Out of bounds on buffer access (axis %d)", axis);
17875 }
17876 
17877 /* GetTopmostException */
17878  #if CYTHON_USE_EXC_INFO_STACK
17879 static _PyErr_StackItem *
17880 __Pyx_PyErr_GetTopmostException(PyThreadState *tstate)
17881 {
17882  _PyErr_StackItem *exc_info = tstate->exc_info;
17883  while ((exc_info->exc_type == NULL || exc_info->exc_type == Py_None) &&
17884  exc_info->previous_item != NULL)
17885  {
17886  exc_info = exc_info->previous_item;
17887  }
17888  return exc_info;
17889 }
17890 #endif
17891 
17892 /* SaveResetException */
17893  #if CYTHON_FAST_THREAD_STATE
17894 static CYTHON_INLINE void __Pyx__ExceptionSave(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb) {
17895  #if CYTHON_USE_EXC_INFO_STACK
17896  _PyErr_StackItem *exc_info = __Pyx_PyErr_GetTopmostException(tstate);
17897  *type = exc_info->exc_type;
17898  *value = exc_info->exc_value;
17899  *tb = exc_info->exc_traceback;
17900  #else
17901  *type = tstate->exc_type;
17902  *value = tstate->exc_value;
17903  *tb = tstate->exc_traceback;
17904  #endif
17905  Py_XINCREF(*type);
17906  Py_XINCREF(*value);
17907  Py_XINCREF(*tb);
17908 }
17909 static CYTHON_INLINE void __Pyx__ExceptionReset(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb) {
17910  PyObject *tmp_type, *tmp_value, *tmp_tb;
17911  #if CYTHON_USE_EXC_INFO_STACK
17912  _PyErr_StackItem *exc_info = tstate->exc_info;
17913  tmp_type = exc_info->exc_type;
17914  tmp_value = exc_info->exc_value;
17915  tmp_tb = exc_info->exc_traceback;
17916  exc_info->exc_type = type;
17917  exc_info->exc_value = value;
17918  exc_info->exc_traceback = tb;
17919  #else
17920  tmp_type = tstate->exc_type;
17921  tmp_value = tstate->exc_value;
17922  tmp_tb = tstate->exc_traceback;
17923  tstate->exc_type = type;
17924  tstate->exc_value = value;
17925  tstate->exc_traceback = tb;
17926  #endif
17927  Py_XDECREF(tmp_type);
17928  Py_XDECREF(tmp_value);
17929  Py_XDECREF(tmp_tb);
17930 }
17931 #endif
17932 
17933 /* PyErrExceptionMatches */
17934  #if CYTHON_FAST_THREAD_STATE
17935 static int __Pyx_PyErr_ExceptionMatchesTuple(PyObject *exc_type, PyObject *tuple) {
17936  Py_ssize_t i, n;
17937  n = PyTuple_GET_SIZE(tuple);
17938 #if PY_MAJOR_VERSION >= 3
17939  for (i=0; i<n; i++) {
17940  if (exc_type == PyTuple_GET_ITEM(tuple, i)) return 1;
17941  }
17942 #endif
17943  for (i=0; i<n; i++) {
17944  if (__Pyx_PyErr_GivenExceptionMatches(exc_type, PyTuple_GET_ITEM(tuple, i))) return 1;
17945  }
17946  return 0;
17947 }
17948 static CYTHON_INLINE int __Pyx_PyErr_ExceptionMatchesInState(PyThreadState* tstate, PyObject* err) {
17949  PyObject *exc_type = tstate->curexc_type;
17950  if (exc_type == err) return 1;
17951  if (unlikely(!exc_type)) return 0;
17952  if (unlikely(PyTuple_Check(err)))
17953  return __Pyx_PyErr_ExceptionMatchesTuple(exc_type, err);
17954  return __Pyx_PyErr_GivenExceptionMatches(exc_type, err);
17955 }
17956 #endif
17957 
17958 /* GetException */
17959  #if CYTHON_FAST_THREAD_STATE
17960 static int __Pyx__GetException(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb)
17961 #else
17962 static int __Pyx_GetException(PyObject **type, PyObject **value, PyObject **tb)
17963 #endif
17964 {
17965  PyObject *local_type, *local_value, *local_tb;
17966 #if CYTHON_FAST_THREAD_STATE
17967  PyObject *tmp_type, *tmp_value, *tmp_tb;
17968  local_type = tstate->curexc_type;
17969  local_value = tstate->curexc_value;
17970  local_tb = tstate->curexc_traceback;
17971  tstate->curexc_type = 0;
17972  tstate->curexc_value = 0;
17973  tstate->curexc_traceback = 0;
17974 #else
17975  PyErr_Fetch(&local_type, &local_value, &local_tb);
17976 #endif
17977  PyErr_NormalizeException(&local_type, &local_value, &local_tb);
17978 #if CYTHON_FAST_THREAD_STATE
17979  if (unlikely(tstate->curexc_type))
17980 #else
17981  if (unlikely(PyErr_Occurred()))
17982 #endif
17983  goto bad;
17984  #if PY_MAJOR_VERSION >= 3
17985  if (local_tb) {
17986  if (unlikely(PyException_SetTraceback(local_value, local_tb) < 0))
17987  goto bad;
17988  }
17989  #endif
17990  Py_XINCREF(local_tb);
17991  Py_XINCREF(local_type);
17992  Py_XINCREF(local_value);
17993  *type = local_type;
17994  *value = local_value;
17995  *tb = local_tb;
17996 #if CYTHON_FAST_THREAD_STATE
17997  #if CYTHON_USE_EXC_INFO_STACK
17998  {
17999  _PyErr_StackItem *exc_info = tstate->exc_info;
18000  tmp_type = exc_info->exc_type;
18001  tmp_value = exc_info->exc_value;
18002  tmp_tb = exc_info->exc_traceback;
18003  exc_info->exc_type = local_type;
18004  exc_info->exc_value = local_value;
18005  exc_info->exc_traceback = local_tb;
18006  }
18007  #else
18008  tmp_type = tstate->exc_type;
18009  tmp_value = tstate->exc_value;
18010  tmp_tb = tstate->exc_traceback;
18011  tstate->exc_type = local_type;
18012  tstate->exc_value = local_value;
18013  tstate->exc_traceback = local_tb;
18014  #endif
18015  Py_XDECREF(tmp_type);
18016  Py_XDECREF(tmp_value);
18017  Py_XDECREF(tmp_tb);
18018 #else
18019  PyErr_SetExcInfo(local_type, local_value, local_tb);
18020 #endif
18021  return 0;
18022 bad:
18023  *type = 0;
18024  *value = 0;
18025  *tb = 0;
18026  Py_XDECREF(local_type);
18027  Py_XDECREF(local_value);
18028  Py_XDECREF(local_tb);
18029  return -1;
18030 }
18031 
18032 /* PyObject_GenericGetAttrNoDict */
18033  #if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000
18034 static PyObject *__Pyx_RaiseGenericGetAttributeError(PyTypeObject *tp, PyObject *attr_name) {
18035  PyErr_Format(PyExc_AttributeError,
18036 #if PY_MAJOR_VERSION >= 3
18037  "'%.50s' object has no attribute '%U'",
18038  tp->tp_name, attr_name);
18039 #else
18040  "'%.50s' object has no attribute '%.400s'",
18041  tp->tp_name, PyString_AS_STRING(attr_name));
18042 #endif
18043  return NULL;
18044 }
18045 static CYTHON_INLINE PyObject* __Pyx_PyObject_GenericGetAttrNoDict(PyObject* obj, PyObject* attr_name) {
18046  PyObject *descr;
18047  PyTypeObject *tp = Py_TYPE(obj);
18048  if (unlikely(!PyString_Check(attr_name))) {
18049  return PyObject_GenericGetAttr(obj, attr_name);
18050  }
18051  assert(!tp->tp_dictoffset);
18052  descr = _PyType_Lookup(tp, attr_name);
18053  if (unlikely(!descr)) {
18054  return __Pyx_RaiseGenericGetAttributeError(tp, attr_name);
18055  }
18056  Py_INCREF(descr);
18057  #if PY_MAJOR_VERSION < 3
18058  if (likely(PyType_HasFeature(Py_TYPE(descr), Py_TPFLAGS_HAVE_CLASS)))
18059  #endif
18060  {
18061  descrgetfunc f = Py_TYPE(descr)->tp_descr_get;
18062  if (unlikely(f)) {
18063  PyObject *res = f(descr, obj, (PyObject *)tp);
18064  Py_DECREF(descr);
18065  return res;
18066  }
18067  }
18068  return descr;
18069 }
18070 #endif
18071 
18072 /* PyObject_GenericGetAttr */
18073  #if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000
18074 static PyObject* __Pyx_PyObject_GenericGetAttr(PyObject* obj, PyObject* attr_name) {
18075  if (unlikely(Py_TYPE(obj)->tp_dictoffset)) {
18076  return PyObject_GenericGetAttr(obj, attr_name);
18077  }
18078  return __Pyx_PyObject_GenericGetAttrNoDict(obj, attr_name);
18079 }
18080 #endif
18081 
18082 /* PyObjectGetAttrStrNoError */
18083  static void __Pyx_PyObject_GetAttrStr_ClearAttributeError(void) {
18084  __Pyx_PyThreadState_declare
18085  __Pyx_PyThreadState_assign
18086  if (likely(__Pyx_PyErr_ExceptionMatches(PyExc_AttributeError)))
18087  __Pyx_PyErr_Clear();
18088 }
18089 static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStrNoError(PyObject* obj, PyObject* attr_name) {
18090  PyObject *result;
18091 #if CYTHON_COMPILING_IN_CPYTHON && CYTHON_USE_TYPE_SLOTS && PY_VERSION_HEX >= 0x030700B1
18092  PyTypeObject* tp = Py_TYPE(obj);
18093  if (likely(tp->tp_getattro == PyObject_GenericGetAttr)) {
18094  return _PyObject_GenericGetAttrWithDict(obj, attr_name, NULL, 1);
18095  }
18096 #endif
18097  result = __Pyx_PyObject_GetAttrStr(obj, attr_name);
18098  if (unlikely(!result)) {
18099  __Pyx_PyObject_GetAttrStr_ClearAttributeError();
18100  }
18101  return result;
18102 }
18103 
18104 /* SetupReduce */
18105  static int __Pyx_setup_reduce_is_named(PyObject* meth, PyObject* name) {
18106  int ret;
18107  PyObject *name_attr;
18108  name_attr = __Pyx_PyObject_GetAttrStr(meth, __pyx_n_s_name);
18109  if (likely(name_attr)) {
18110  ret = PyObject_RichCompareBool(name_attr, name, Py_EQ);
18111  } else {
18112  ret = -1;
18113  }
18114  if (unlikely(ret < 0)) {
18115  PyErr_Clear();
18116  ret = 0;
18117  }
18118  Py_XDECREF(name_attr);
18119  return ret;
18120 }
18121 static int __Pyx_setup_reduce(PyObject* type_obj) {
18122  int ret = 0;
18123  PyObject *object_reduce = NULL;
18124  PyObject *object_getstate = NULL;
18125  PyObject *object_reduce_ex = NULL;
18126  PyObject *reduce = NULL;
18127  PyObject *reduce_ex = NULL;
18128  PyObject *reduce_cython = NULL;
18129  PyObject *setstate = NULL;
18130  PyObject *setstate_cython = NULL;
18131  PyObject *getstate = NULL;
18132 #if CYTHON_USE_PYTYPE_LOOKUP
18133  getstate = _PyType_Lookup((PyTypeObject*)type_obj, __pyx_n_s_getstate);
18134 #else
18135  getstate = __Pyx_PyObject_GetAttrStrNoError(type_obj, __pyx_n_s_getstate);
18136  if (!getstate && PyErr_Occurred()) {
18137  goto __PYX_BAD;
18138  }
18139 #endif
18140  if (getstate) {
18141 #if CYTHON_USE_PYTYPE_LOOKUP
18142  object_getstate = _PyType_Lookup(&PyBaseObject_Type, __pyx_n_s_getstate);
18143 #else
18144  object_getstate = __Pyx_PyObject_GetAttrStrNoError((PyObject*)&PyBaseObject_Type, __pyx_n_s_getstate);
18145  if (!object_getstate && PyErr_Occurred()) {
18146  goto __PYX_BAD;
18147  }
18148 #endif
18149  if (object_getstate != getstate) {
18150  goto __PYX_GOOD;
18151  }
18152  }
18153 #if CYTHON_USE_PYTYPE_LOOKUP
18154  object_reduce_ex = _PyType_Lookup(&PyBaseObject_Type, __pyx_n_s_reduce_ex); if (!object_reduce_ex) goto __PYX_BAD;
18155 #else
18156  object_reduce_ex = __Pyx_PyObject_GetAttrStr((PyObject*)&PyBaseObject_Type, __pyx_n_s_reduce_ex); if (!object_reduce_ex) goto __PYX_BAD;
18157 #endif
18158  reduce_ex = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_reduce_ex); if (unlikely(!reduce_ex)) goto __PYX_BAD;
18159  if (reduce_ex == object_reduce_ex) {
18160 #if CYTHON_USE_PYTYPE_LOOKUP
18161  object_reduce = _PyType_Lookup(&PyBaseObject_Type, __pyx_n_s_reduce); if (!object_reduce) goto __PYX_BAD;
18162 #else
18163  object_reduce = __Pyx_PyObject_GetAttrStr((PyObject*)&PyBaseObject_Type, __pyx_n_s_reduce); if (!object_reduce) goto __PYX_BAD;
18164 #endif
18165  reduce = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_reduce); if (unlikely(!reduce)) goto __PYX_BAD;
18166  if (reduce == object_reduce || __Pyx_setup_reduce_is_named(reduce, __pyx_n_s_reduce_cython)) {
18167  reduce_cython = __Pyx_PyObject_GetAttrStrNoError(type_obj, __pyx_n_s_reduce_cython);
18168  if (likely(reduce_cython)) {
18169  ret = PyDict_SetItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_reduce, reduce_cython); if (unlikely(ret < 0)) goto __PYX_BAD;
18170  ret = PyDict_DelItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_reduce_cython); if (unlikely(ret < 0)) goto __PYX_BAD;
18171  } else if (reduce == object_reduce || PyErr_Occurred()) {
18172  goto __PYX_BAD;
18173  }
18174  setstate = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_setstate);
18175  if (!setstate) PyErr_Clear();
18176  if (!setstate || __Pyx_setup_reduce_is_named(setstate, __pyx_n_s_setstate_cython)) {
18177  setstate_cython = __Pyx_PyObject_GetAttrStrNoError(type_obj, __pyx_n_s_setstate_cython);
18178  if (likely(setstate_cython)) {
18179  ret = PyDict_SetItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_setstate, setstate_cython); if (unlikely(ret < 0)) goto __PYX_BAD;
18180  ret = PyDict_DelItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_setstate_cython); if (unlikely(ret < 0)) goto __PYX_BAD;
18181  } else if (!setstate || PyErr_Occurred()) {
18182  goto __PYX_BAD;
18183  }
18184  }
18185  PyType_Modified((PyTypeObject*)type_obj);
18186  }
18187  }
18188  goto __PYX_GOOD;
18189 __PYX_BAD:
18190  if (!PyErr_Occurred())
18191  PyErr_Format(PyExc_RuntimeError, "Unable to initialize pickling for %s", ((PyTypeObject*)type_obj)->tp_name);
18192  ret = -1;
18193 __PYX_GOOD:
18194 #if !CYTHON_USE_PYTYPE_LOOKUP
18195  Py_XDECREF(object_reduce);
18196  Py_XDECREF(object_reduce_ex);
18197  Py_XDECREF(object_getstate);
18198  Py_XDECREF(getstate);
18199 #endif
18200  Py_XDECREF(reduce);
18201  Py_XDECREF(reduce_ex);
18202  Py_XDECREF(reduce_cython);
18203  Py_XDECREF(setstate);
18204  Py_XDECREF(setstate_cython);
18205  return ret;
18206 }
18207 
18208 /* TypeImport */
18209  #ifndef __PYX_HAVE_RT_ImportType
18210 #define __PYX_HAVE_RT_ImportType
18211 static PyTypeObject *__Pyx_ImportType(PyObject *module, const char *module_name, const char *class_name,
18212  size_t size, enum __Pyx_ImportType_CheckSize check_size)
18213 {
18214  PyObject *result = 0;
18215  char warning[200];
18216  Py_ssize_t basicsize;
18217 #ifdef Py_LIMITED_API
18218  PyObject *py_basicsize;
18219 #endif
18220  result = PyObject_GetAttrString(module, class_name);
18221  if (!result)
18222  goto bad;
18223  if (!PyType_Check(result)) {
18224  PyErr_Format(PyExc_TypeError,
18225  "%.200s.%.200s is not a type object",
18226  module_name, class_name);
18227  goto bad;
18228  }
18229 #ifndef Py_LIMITED_API
18230  basicsize = ((PyTypeObject *)result)->tp_basicsize;
18231 #else
18232  py_basicsize = PyObject_GetAttrString(result, "__basicsize__");
18233  if (!py_basicsize)
18234  goto bad;
18235  basicsize = PyLong_AsSsize_t(py_basicsize);
18236  Py_DECREF(py_basicsize);
18237  py_basicsize = 0;
18238  if (basicsize == (Py_ssize_t)-1 && PyErr_Occurred())
18239  goto bad;
18240 #endif
18241  if ((size_t)basicsize < size) {
18242  PyErr_Format(PyExc_ValueError,
18243  "%.200s.%.200s size changed, may indicate binary incompatibility. "
18244  "Expected %zd from C header, got %zd from PyObject",
18245  module_name, class_name, size, basicsize);
18246  goto bad;
18247  }
18248  if (check_size == __Pyx_ImportType_CheckSize_Error && (size_t)basicsize != size) {
18249  PyErr_Format(PyExc_ValueError,
18250  "%.200s.%.200s size changed, may indicate binary incompatibility. "
18251  "Expected %zd from C header, got %zd from PyObject",
18252  module_name, class_name, size, basicsize);
18253  goto bad;
18254  }
18255  else if (check_size == __Pyx_ImportType_CheckSize_Warn && (size_t)basicsize > size) {
18256  PyOS_snprintf(warning, sizeof(warning),
18257  "%s.%s size changed, may indicate binary incompatibility. "
18258  "Expected %zd from C header, got %zd from PyObject",
18259  module_name, class_name, size, basicsize);
18260  if (PyErr_WarnEx(NULL, warning, 0) < 0) goto bad;
18261  }
18262  return (PyTypeObject *)result;
18263 bad:
18264  Py_XDECREF(result);
18265  return NULL;
18266 }
18267 #endif
18268 
18269 /* Import */
18270  static PyObject *__Pyx_Import(PyObject *name, PyObject *from_list, int level) {
18271  PyObject *empty_list = 0;
18272  PyObject *module = 0;
18273  PyObject *global_dict = 0;
18274  PyObject *empty_dict = 0;
18275  PyObject *list;
18276  #if PY_MAJOR_VERSION < 3
18277  PyObject *py_import;
18278  py_import = __Pyx_PyObject_GetAttrStr(__pyx_b, __pyx_n_s_import);
18279  if (!py_import)
18280  goto bad;
18281  #endif
18282  if (from_list)
18283  list = from_list;
18284  else {
18285  empty_list = PyList_New(0);
18286  if (!empty_list)
18287  goto bad;
18288  list = empty_list;
18289  }
18290  global_dict = PyModule_GetDict(__pyx_m);
18291  if (!global_dict)
18292  goto bad;
18293  empty_dict = PyDict_New();
18294  if (!empty_dict)
18295  goto bad;
18296  {
18297  #if PY_MAJOR_VERSION >= 3
18298  if (level == -1) {
18299  if ((1) && (strchr(__Pyx_MODULE_NAME, '.'))) {
18300  module = PyImport_ImportModuleLevelObject(
18301  name, global_dict, empty_dict, list, 1);
18302  if (!module) {
18303  if (!PyErr_ExceptionMatches(PyExc_ImportError))
18304  goto bad;
18305  PyErr_Clear();
18306  }
18307  }
18308  level = 0;
18309  }
18310  #endif
18311  if (!module) {
18312  #if PY_MAJOR_VERSION < 3
18313  PyObject *py_level = PyInt_FromLong(level);
18314  if (!py_level)
18315  goto bad;
18316  module = PyObject_CallFunctionObjArgs(py_import,
18317  name, global_dict, empty_dict, list, py_level, (PyObject *)NULL);
18318  Py_DECREF(py_level);
18319  #else
18320  module = PyImport_ImportModuleLevelObject(
18321  name, global_dict, empty_dict, list, level);
18322  #endif
18323  }
18324  }
18325 bad:
18326  #if PY_MAJOR_VERSION < 3
18327  Py_XDECREF(py_import);
18328  #endif
18329  Py_XDECREF(empty_list);
18330  Py_XDECREF(empty_dict);
18331  return module;
18332 }
18333 
18334 /* PyDictVersioning */
18335  #if CYTHON_USE_DICT_VERSIONS && CYTHON_USE_TYPE_SLOTS
18336 static CYTHON_INLINE PY_UINT64_T __Pyx_get_tp_dict_version(PyObject *obj) {
18337  PyObject *dict = Py_TYPE(obj)->tp_dict;
18338  return likely(dict) ? __PYX_GET_DICT_VERSION(dict) : 0;
18339 }
18340 static CYTHON_INLINE PY_UINT64_T __Pyx_get_object_dict_version(PyObject *obj) {
18341  PyObject **dictptr = NULL;
18342  Py_ssize_t offset = Py_TYPE(obj)->tp_dictoffset;
18343  if (offset) {
18344 #if CYTHON_COMPILING_IN_CPYTHON
18345  dictptr = (likely(offset > 0)) ? (PyObject **) ((char *)obj + offset) : _PyObject_GetDictPtr(obj);
18346 #else
18347  dictptr = _PyObject_GetDictPtr(obj);
18348 #endif
18349  }
18350  return (dictptr && *dictptr) ? __PYX_GET_DICT_VERSION(*dictptr) : 0;
18351 }
18352 static CYTHON_INLINE int __Pyx_object_dict_version_matches(PyObject* obj, PY_UINT64_T tp_dict_version, PY_UINT64_T obj_dict_version) {
18353  PyObject *dict = Py_TYPE(obj)->tp_dict;
18354  if (unlikely(!dict) || unlikely(tp_dict_version != __PYX_GET_DICT_VERSION(dict)))
18355  return 0;
18356  return obj_dict_version == __Pyx_get_object_dict_version(obj);
18357 }
18358 #endif
18359 
18360 /* CLineInTraceback */
18361  #ifndef CYTHON_CLINE_IN_TRACEBACK
18362 static int __Pyx_CLineForTraceback(CYTHON_NCP_UNUSED PyThreadState *tstate, int c_line) {
18363  PyObject *use_cline;
18364  PyObject *ptype, *pvalue, *ptraceback;
18365 #if CYTHON_COMPILING_IN_CPYTHON
18366  PyObject **cython_runtime_dict;
18367 #endif
18368  if (unlikely(!__pyx_cython_runtime)) {
18369  return c_line;
18370  }
18371  __Pyx_ErrFetchInState(tstate, &ptype, &pvalue, &ptraceback);
18372 #if CYTHON_COMPILING_IN_CPYTHON
18373  cython_runtime_dict = _PyObject_GetDictPtr(__pyx_cython_runtime);
18374  if (likely(cython_runtime_dict)) {
18375  __PYX_PY_DICT_LOOKUP_IF_MODIFIED(
18376  use_cline, *cython_runtime_dict,
18377  __Pyx_PyDict_GetItemStr(*cython_runtime_dict, __pyx_n_s_cline_in_traceback))
18378  } else
18379 #endif
18380  {
18381  PyObject *use_cline_obj = __Pyx_PyObject_GetAttrStr(__pyx_cython_runtime, __pyx_n_s_cline_in_traceback);
18382  if (use_cline_obj) {
18383  use_cline = PyObject_Not(use_cline_obj) ? Py_False : Py_True;
18384  Py_DECREF(use_cline_obj);
18385  } else {
18386  PyErr_Clear();
18387  use_cline = NULL;
18388  }
18389  }
18390  if (!use_cline) {
18391  c_line = 0;
18392  (void) PyObject_SetAttr(__pyx_cython_runtime, __pyx_n_s_cline_in_traceback, Py_False);
18393  }
18394  else if (use_cline == Py_False || (use_cline != Py_True && PyObject_Not(use_cline) != 0)) {
18395  c_line = 0;
18396  }
18397  __Pyx_ErrRestoreInState(tstate, ptype, pvalue, ptraceback);
18398  return c_line;
18399 }
18400 #endif
18401 
18402 /* CodeObjectCache */
18403  static int __pyx_bisect_code_objects(__Pyx_CodeObjectCacheEntry* entries, int count, int code_line) {
18404  int start = 0, mid = 0, end = count - 1;
18405  if (end >= 0 && code_line > entries[end].code_line) {
18406  return count;
18407  }
18408  while (start < end) {
18409  mid = start + (end - start) / 2;
18410  if (code_line < entries[mid].code_line) {
18411  end = mid;
18412  } else if (code_line > entries[mid].code_line) {
18413  start = mid + 1;
18414  } else {
18415  return mid;
18416  }
18417  }
18418  if (code_line <= entries[mid].code_line) {
18419  return mid;
18420  } else {
18421  return mid + 1;
18422  }
18423 }
18424 static PyCodeObject *__pyx_find_code_object(int code_line) {
18425  PyCodeObject* code_object;
18426  int pos;
18427  if (unlikely(!code_line) || unlikely(!__pyx_code_cache.entries)) {
18428  return NULL;
18429  }
18430  pos = __pyx_bisect_code_objects(__pyx_code_cache.entries, __pyx_code_cache.count, code_line);
18431  if (unlikely(pos >= __pyx_code_cache.count) || unlikely(__pyx_code_cache.entries[pos].code_line != code_line)) {
18432  return NULL;
18433  }
18434  code_object = __pyx_code_cache.entries[pos].code_object;
18435  Py_INCREF(code_object);
18436  return code_object;
18437 }
18438 static void __pyx_insert_code_object(int code_line, PyCodeObject* code_object) {
18439  int pos, i;
18440  __Pyx_CodeObjectCacheEntry* entries = __pyx_code_cache.entries;
18441  if (unlikely(!code_line)) {
18442  return;
18443  }
18444  if (unlikely(!entries)) {
18445  entries = (__Pyx_CodeObjectCacheEntry*)PyMem_Malloc(64*sizeof(__Pyx_CodeObjectCacheEntry));
18446  if (likely(entries)) {
18447  __pyx_code_cache.entries = entries;
18448  __pyx_code_cache.max_count = 64;
18449  __pyx_code_cache.count = 1;
18450  entries[0].code_line = code_line;
18451  entries[0].code_object = code_object;
18452  Py_INCREF(code_object);
18453  }
18454  return;
18455  }
18456  pos = __pyx_bisect_code_objects(__pyx_code_cache.entries, __pyx_code_cache.count, code_line);
18457  if ((pos < __pyx_code_cache.count) && unlikely(__pyx_code_cache.entries[pos].code_line == code_line)) {
18458  PyCodeObject* tmp = entries[pos].code_object;
18459  entries[pos].code_object = code_object;
18460  Py_DECREF(tmp);
18461  return;
18462  }
18463  if (__pyx_code_cache.count == __pyx_code_cache.max_count) {
18464  int new_max = __pyx_code_cache.max_count + 64;
18465  entries = (__Pyx_CodeObjectCacheEntry*)PyMem_Realloc(
18466  __pyx_code_cache.entries, ((size_t)new_max) * sizeof(__Pyx_CodeObjectCacheEntry));
18467  if (unlikely(!entries)) {
18468  return;
18469  }
18470  __pyx_code_cache.entries = entries;
18471  __pyx_code_cache.max_count = new_max;
18472  }
18473  for (i=__pyx_code_cache.count; i>pos; i--) {
18474  entries[i] = entries[i-1];
18475  }
18476  entries[pos].code_line = code_line;
18477  entries[pos].code_object = code_object;
18478  __pyx_code_cache.count++;
18479  Py_INCREF(code_object);
18480 }
18481 
18482 /* AddTraceback */
18483  #include "compile.h"
18484 #include "frameobject.h"
18485 #include "traceback.h"
18486 #if PY_VERSION_HEX >= 0x030b00a6
18487  #ifndef Py_BUILD_CORE
18488  #define Py_BUILD_CORE 1
18489  #endif
18490  #include "internal/pycore_frame.h"
18491 #endif
18492 static PyCodeObject* __Pyx_CreateCodeObjectForTraceback(
18493  const char *funcname, int c_line,
18494  int py_line, const char *filename) {
18495  PyCodeObject *py_code = NULL;
18496  PyObject *py_funcname = NULL;
18497  #if PY_MAJOR_VERSION < 3
18498  PyObject *py_srcfile = NULL;
18499  py_srcfile = PyString_FromString(filename);
18500  if (!py_srcfile) goto bad;
18501  #endif
18502  if (c_line) {
18503  #if PY_MAJOR_VERSION < 3
18504  py_funcname = PyString_FromFormat( "%s (%s:%d)", funcname, __pyx_cfilenm, c_line);
18505  if (!py_funcname) goto bad;
18506  #else
18507  py_funcname = PyUnicode_FromFormat( "%s (%s:%d)", funcname, __pyx_cfilenm, c_line);
18508  if (!py_funcname) goto bad;
18509  funcname = PyUnicode_AsUTF8(py_funcname);
18510  if (!funcname) goto bad;
18511  #endif
18512  }
18513  else {
18514  #if PY_MAJOR_VERSION < 3
18515  py_funcname = PyString_FromString(funcname);
18516  if (!py_funcname) goto bad;
18517  #endif
18518  }
18519  #if PY_MAJOR_VERSION < 3
18520  py_code = __Pyx_PyCode_New(
18521  0,
18522  0,
18523  0,
18524  0,
18525  0,
18526  __pyx_empty_bytes, /*PyObject *code,*/
18527  __pyx_empty_tuple, /*PyObject *consts,*/
18528  __pyx_empty_tuple, /*PyObject *names,*/
18529  __pyx_empty_tuple, /*PyObject *varnames,*/
18530  __pyx_empty_tuple, /*PyObject *freevars,*/
18531  __pyx_empty_tuple, /*PyObject *cellvars,*/
18532  py_srcfile, /*PyObject *filename,*/
18533  py_funcname, /*PyObject *name,*/
18534  py_line,
18535  __pyx_empty_bytes /*PyObject *lnotab*/
18536  );
18537  Py_DECREF(py_srcfile);
18538  #else
18539  py_code = PyCode_NewEmpty(filename, funcname, py_line);
18540  #endif
18541  Py_XDECREF(py_funcname); // XDECREF since it's only set on Py3 if cline
18542  return py_code;
18543 bad:
18544  Py_XDECREF(py_funcname);
18545  #if PY_MAJOR_VERSION < 3
18546  Py_XDECREF(py_srcfile);
18547  #endif
18548  return NULL;
18549 }
18550 static void __Pyx_AddTraceback(const char *funcname, int c_line,
18551  int py_line, const char *filename) {
18552  PyCodeObject *py_code = 0;
18553  PyFrameObject *py_frame = 0;
18554  PyThreadState *tstate = __Pyx_PyThreadState_Current;
18555  PyObject *ptype, *pvalue, *ptraceback;
18556  if (c_line) {
18557  c_line = __Pyx_CLineForTraceback(tstate, c_line);
18558  }
18559  py_code = __pyx_find_code_object(c_line ? -c_line : py_line);
18560  if (!py_code) {
18561  __Pyx_ErrFetchInState(tstate, &ptype, &pvalue, &ptraceback);
18562  py_code = __Pyx_CreateCodeObjectForTraceback(
18563  funcname, c_line, py_line, filename);
18564  if (!py_code) {
18565  /* If the code object creation fails, then we should clear the
18566  fetched exception references and propagate the new exception */
18567  Py_XDECREF(ptype);
18568  Py_XDECREF(pvalue);
18569  Py_XDECREF(ptraceback);
18570  goto bad;
18571  }
18572  __Pyx_ErrRestoreInState(tstate, ptype, pvalue, ptraceback);
18573  __pyx_insert_code_object(c_line ? -c_line : py_line, py_code);
18574  }
18575  py_frame = PyFrame_New(
18576  tstate, /*PyThreadState *tstate,*/
18577  py_code, /*PyCodeObject *code,*/
18578  __pyx_d, /*PyObject *globals,*/
18579  0 /*PyObject *locals*/
18580  );
18581  if (!py_frame) goto bad;
18582  __Pyx_PyFrame_SetLineNumber(py_frame, py_line);
18583  PyTraceBack_Here(py_frame);
18584 bad:
18585  Py_XDECREF(py_code);
18586  Py_XDECREF(py_frame);
18587 }
18588 
18589 #if PY_MAJOR_VERSION < 3
18590 static int __Pyx_GetBuffer(PyObject *obj, Py_buffer *view, int flags) {
18591  if (PyObject_CheckBuffer(obj)) return PyObject_GetBuffer(obj, view, flags);
18592  PyErr_Format(PyExc_TypeError, "'%.200s' does not have the buffer interface", Py_TYPE(obj)->tp_name);
18593  return -1;
18594 }
18595 static void __Pyx_ReleaseBuffer(Py_buffer *view) {
18596  PyObject *obj = view->obj;
18597  if (!obj) return;
18598  if (PyObject_CheckBuffer(obj)) {
18599  PyBuffer_Release(view);
18600  return;
18601  }
18602  if ((0)) {}
18603  view->obj = NULL;
18604  Py_DECREF(obj);
18605 }
18606 #endif
18607 
18608 
18609  /* CIntFromPyVerify */
18610  #define __PYX_VERIFY_RETURN_INT(target_type, func_type, func_value)\
18611  __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, 0)
18612 #define __PYX_VERIFY_RETURN_INT_EXC(target_type, func_type, func_value)\
18613  __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, 1)
18614 #define __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, exc)\
18615  {\
18616  func_type value = func_value;\
18617  if (sizeof(target_type) < sizeof(func_type)) {\
18618  if (unlikely(value != (func_type) (target_type) value)) {\
18619  func_type zero = 0;\
18620  if (exc && unlikely(value == (func_type)-1 && PyErr_Occurred()))\
18621  return (target_type) -1;\
18622  if (is_unsigned && unlikely(value < zero))\
18623  goto raise_neg_overflow;\
18624  else\
18625  goto raise_overflow;\
18626  }\
18627  }\
18628  return (target_type) value;\
18629  }
18630 
18631 /* Declarations */
18632  #if CYTHON_CCOMPLEX
18633  #ifdef __cplusplus
18634  static CYTHON_INLINE __pyx_t_float_complex __pyx_t_float_complex_from_parts(float x, float y) {
18635  return ::std::complex< float >(x, y);
18636  }
18637  #else
18638  static CYTHON_INLINE __pyx_t_float_complex __pyx_t_float_complex_from_parts(float x, float y) {
18639  return x + y*(__pyx_t_float_complex)_Complex_I;
18640  }
18641  #endif
18642 #else
18643  static CYTHON_INLINE __pyx_t_float_complex __pyx_t_float_complex_from_parts(float x, float y) {
18644  __pyx_t_float_complex z;
18645  z.real = x;
18646  z.imag = y;
18647  return z;
18648  }
18649 #endif
18650 
18651 /* Arithmetic */
18652  #if CYTHON_CCOMPLEX
18653 #else
18654  static CYTHON_INLINE int __Pyx_c_eq_float(__pyx_t_float_complex a, __pyx_t_float_complex b) {
18655  return (a.real == b.real) && (a.imag == b.imag);
18656  }
18657  static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_sum_float(__pyx_t_float_complex a, __pyx_t_float_complex b) {
18658  __pyx_t_float_complex z;
18659  z.real = a.real + b.real;
18660  z.imag = a.imag + b.imag;
18661  return z;
18662  }
18663  static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_diff_float(__pyx_t_float_complex a, __pyx_t_float_complex b) {
18664  __pyx_t_float_complex z;
18665  z.real = a.real - b.real;
18666  z.imag = a.imag - b.imag;
18667  return z;
18668  }
18669  static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_prod_float(__pyx_t_float_complex a, __pyx_t_float_complex b) {
18670  __pyx_t_float_complex z;
18671  z.real = a.real * b.real - a.imag * b.imag;
18672  z.imag = a.real * b.imag + a.imag * b.real;
18673  return z;
18674  }
18675  #if 1
18676  static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_quot_float(__pyx_t_float_complex a, __pyx_t_float_complex b) {
18677  if (b.imag == 0) {
18678  return __pyx_t_float_complex_from_parts(a.real / b.real, a.imag / b.real);
18679  } else if (fabsf(b.real) >= fabsf(b.imag)) {
18680  if (b.real == 0 && b.imag == 0) {
18681  return __pyx_t_float_complex_from_parts(a.real / b.real, a.imag / b.imag);
18682  } else {
18683  float r = b.imag / b.real;
18684  float s = (float)(1.0) / (b.real + b.imag * r);
18685  return __pyx_t_float_complex_from_parts(
18686  (a.real + a.imag * r) * s, (a.imag - a.real * r) * s);
18687  }
18688  } else {
18689  float r = b.real / b.imag;
18690  float s = (float)(1.0) / (b.imag + b.real * r);
18691  return __pyx_t_float_complex_from_parts(
18692  (a.real * r + a.imag) * s, (a.imag * r - a.real) * s);
18693  }
18694  }
18695  #else
18696  static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_quot_float(__pyx_t_float_complex a, __pyx_t_float_complex b) {
18697  if (b.imag == 0) {
18698  return __pyx_t_float_complex_from_parts(a.real / b.real, a.imag / b.real);
18699  } else {
18700  float denom = b.real * b.real + b.imag * b.imag;
18701  return __pyx_t_float_complex_from_parts(
18702  (a.real * b.real + a.imag * b.imag) / denom,
18703  (a.imag * b.real - a.real * b.imag) / denom);
18704  }
18705  }
18706  #endif
18707  static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_neg_float(__pyx_t_float_complex a) {
18708  __pyx_t_float_complex z;
18709  z.real = -a.real;
18710  z.imag = -a.imag;
18711  return z;
18712  }
18713  static CYTHON_INLINE int __Pyx_c_is_zero_float(__pyx_t_float_complex a) {
18714  return (a.real == 0) && (a.imag == 0);
18715  }
18716  static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_conj_float(__pyx_t_float_complex a) {
18717  __pyx_t_float_complex z;
18718  z.real = a.real;
18719  z.imag = -a.imag;
18720  return z;
18721  }
18722  #if 1
18723  static CYTHON_INLINE float __Pyx_c_abs_float(__pyx_t_float_complex z) {
18724  #if !defined(HAVE_HYPOT) || defined(_MSC_VER)
18725  return sqrtf(z.real*z.real + z.imag*z.imag);
18726  #else
18727  return hypotf(z.real, z.imag);
18728  #endif
18729  }
18730  static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_pow_float(__pyx_t_float_complex a, __pyx_t_float_complex b) {
18731  __pyx_t_float_complex z;
18732  float r, lnr, theta, z_r, z_theta;
18733  if (b.imag == 0 && b.real == (int)b.real) {
18734  if (b.real < 0) {
18735  float denom = a.real * a.real + a.imag * a.imag;
18736  a.real = a.real / denom;
18737  a.imag = -a.imag / denom;
18738  b.real = -b.real;
18739  }
18740  switch ((int)b.real) {
18741  case 0:
18742  z.real = 1;
18743  z.imag = 0;
18744  return z;
18745  case 1:
18746  return a;
18747  case 2:
18748  return __Pyx_c_prod_float(a, a);
18749  case 3:
18750  z = __Pyx_c_prod_float(a, a);
18751  return __Pyx_c_prod_float(z, a);
18752  case 4:
18753  z = __Pyx_c_prod_float(a, a);
18754  return __Pyx_c_prod_float(z, z);
18755  }
18756  }
18757  if (a.imag == 0) {
18758  if (a.real == 0) {
18759  return a;
18760  } else if (b.imag == 0) {
18761  z.real = powf(a.real, b.real);
18762  z.imag = 0;
18763  return z;
18764  } else if (a.real > 0) {
18765  r = a.real;
18766  theta = 0;
18767  } else {
18768  r = -a.real;
18769  theta = atan2f(0.0, -1.0);
18770  }
18771  } else {
18772  r = __Pyx_c_abs_float(a);
18773  theta = atan2f(a.imag, a.real);
18774  }
18775  lnr = logf(r);
18776  z_r = expf(lnr * b.real - theta * b.imag);
18777  z_theta = theta * b.real + lnr * b.imag;
18778  z.real = z_r * cosf(z_theta);
18779  z.imag = z_r * sinf(z_theta);
18780  return z;
18781  }
18782  #endif
18783 #endif
18784 
18785 /* Declarations */
18786  #if CYTHON_CCOMPLEX
18787  #ifdef __cplusplus
18788  static CYTHON_INLINE __pyx_t_double_complex __pyx_t_double_complex_from_parts(double x, double y) {
18789  return ::std::complex< double >(x, y);
18790  }
18791  #else
18792  static CYTHON_INLINE __pyx_t_double_complex __pyx_t_double_complex_from_parts(double x, double y) {
18793  return x + y*(__pyx_t_double_complex)_Complex_I;
18794  }
18795  #endif
18796 #else
18797  static CYTHON_INLINE __pyx_t_double_complex __pyx_t_double_complex_from_parts(double x, double y) {
18798  __pyx_t_double_complex z;
18799  z.real = x;
18800  z.imag = y;
18801  return z;
18802  }
18803 #endif
18804 
18805 /* Arithmetic */
18806  #if CYTHON_CCOMPLEX
18807 #else
18808  static CYTHON_INLINE int __Pyx_c_eq_double(__pyx_t_double_complex a, __pyx_t_double_complex b) {
18809  return (a.real == b.real) && (a.imag == b.imag);
18810  }
18811  static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_sum_double(__pyx_t_double_complex a, __pyx_t_double_complex b) {
18812  __pyx_t_double_complex z;
18813  z.real = a.real + b.real;
18814  z.imag = a.imag + b.imag;
18815  return z;
18816  }
18817  static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_diff_double(__pyx_t_double_complex a, __pyx_t_double_complex b) {
18818  __pyx_t_double_complex z;
18819  z.real = a.real - b.real;
18820  z.imag = a.imag - b.imag;
18821  return z;
18822  }
18823  static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_prod_double(__pyx_t_double_complex a, __pyx_t_double_complex b) {
18824  __pyx_t_double_complex z;
18825  z.real = a.real * b.real - a.imag * b.imag;
18826  z.imag = a.real * b.imag + a.imag * b.real;
18827  return z;
18828  }
18829  #if 1
18830  static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_quot_double(__pyx_t_double_complex a, __pyx_t_double_complex b) {
18831  if (b.imag == 0) {
18832  return __pyx_t_double_complex_from_parts(a.real / b.real, a.imag / b.real);
18833  } else if (fabs(b.real) >= fabs(b.imag)) {
18834  if (b.real == 0 && b.imag == 0) {
18835  return __pyx_t_double_complex_from_parts(a.real / b.real, a.imag / b.imag);
18836  } else {
18837  double r = b.imag / b.real;
18838  double s = (double)(1.0) / (b.real + b.imag * r);
18839  return __pyx_t_double_complex_from_parts(
18840  (a.real + a.imag * r) * s, (a.imag - a.real * r) * s);
18841  }
18842  } else {
18843  double r = b.real / b.imag;
18844  double s = (double)(1.0) / (b.imag + b.real * r);
18845  return __pyx_t_double_complex_from_parts(
18846  (a.real * r + a.imag) * s, (a.imag * r - a.real) * s);
18847  }
18848  }
18849  #else
18850  static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_quot_double(__pyx_t_double_complex a, __pyx_t_double_complex b) {
18851  if (b.imag == 0) {
18852  return __pyx_t_double_complex_from_parts(a.real / b.real, a.imag / b.real);
18853  } else {
18854  double denom = b.real * b.real + b.imag * b.imag;
18855  return __pyx_t_double_complex_from_parts(
18856  (a.real * b.real + a.imag * b.imag) / denom,
18857  (a.imag * b.real - a.real * b.imag) / denom);
18858  }
18859  }
18860  #endif
18861  static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_neg_double(__pyx_t_double_complex a) {
18862  __pyx_t_double_complex z;
18863  z.real = -a.real;
18864  z.imag = -a.imag;
18865  return z;
18866  }
18867  static CYTHON_INLINE int __Pyx_c_is_zero_double(__pyx_t_double_complex a) {
18868  return (a.real == 0) && (a.imag == 0);
18869  }
18870  static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_conj_double(__pyx_t_double_complex a) {
18871  __pyx_t_double_complex z;
18872  z.real = a.real;
18873  z.imag = -a.imag;
18874  return z;
18875  }
18876  #if 1
18877  static CYTHON_INLINE double __Pyx_c_abs_double(__pyx_t_double_complex z) {
18878  #if !defined(HAVE_HYPOT) || defined(_MSC_VER)
18879  return sqrt(z.real*z.real + z.imag*z.imag);
18880  #else
18881  return hypot(z.real, z.imag);
18882  #endif
18883  }
18884  static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_pow_double(__pyx_t_double_complex a, __pyx_t_double_complex b) {
18885  __pyx_t_double_complex z;
18886  double r, lnr, theta, z_r, z_theta;
18887  if (b.imag == 0 && b.real == (int)b.real) {
18888  if (b.real < 0) {
18889  double denom = a.real * a.real + a.imag * a.imag;
18890  a.real = a.real / denom;
18891  a.imag = -a.imag / denom;
18892  b.real = -b.real;
18893  }
18894  switch ((int)b.real) {
18895  case 0:
18896  z.real = 1;
18897  z.imag = 0;
18898  return z;
18899  case 1:
18900  return a;
18901  case 2:
18902  return __Pyx_c_prod_double(a, a);
18903  case 3:
18904  z = __Pyx_c_prod_double(a, a);
18905  return __Pyx_c_prod_double(z, a);
18906  case 4:
18907  z = __Pyx_c_prod_double(a, a);
18908  return __Pyx_c_prod_double(z, z);
18909  }
18910  }
18911  if (a.imag == 0) {
18912  if (a.real == 0) {
18913  return a;
18914  } else if (b.imag == 0) {
18915  z.real = pow(a.real, b.real);
18916  z.imag = 0;
18917  return z;
18918  } else if (a.real > 0) {
18919  r = a.real;
18920  theta = 0;
18921  } else {
18922  r = -a.real;
18923  theta = atan2(0.0, -1.0);
18924  }
18925  } else {
18926  r = __Pyx_c_abs_double(a);
18927  theta = atan2(a.imag, a.real);
18928  }
18929  lnr = log(r);
18930  z_r = exp(lnr * b.real - theta * b.imag);
18931  z_theta = theta * b.real + lnr * b.imag;
18932  z.real = z_r * cos(z_theta);
18933  z.imag = z_r * sin(z_theta);
18934  return z;
18935  }
18936  #endif
18937 #endif
18938 
18939 /* CIntFromPy */
18940  static CYTHON_INLINE int __Pyx_PyInt_As_int(PyObject *x) {
18941 #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
18942 #pragma GCC diagnostic push
18943 #pragma GCC diagnostic ignored "-Wconversion"
18944 #endif
18945  const int neg_one = (int) -1, const_zero = (int) 0;
18946 #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
18947 #pragma GCC diagnostic pop
18948 #endif
18949  const int is_unsigned = neg_one > const_zero;
18950 #if PY_MAJOR_VERSION < 3
18951  if (likely(PyInt_Check(x))) {
18952  if (sizeof(int) < sizeof(long)) {
18953  __PYX_VERIFY_RETURN_INT(int, long, PyInt_AS_LONG(x))
18954  } else {
18955  long val = PyInt_AS_LONG(x);
18956  if (is_unsigned && unlikely(val < 0)) {
18957  goto raise_neg_overflow;
18958  }
18959  return (int) val;
18960  }
18961  } else
18962 #endif
18963  if (likely(PyLong_Check(x))) {
18964  if (is_unsigned) {
18965 #if CYTHON_USE_PYLONG_INTERNALS
18966  const digit* digits = ((PyLongObject*)x)->ob_digit;
18967  switch (Py_SIZE(x)) {
18968  case 0: return (int) 0;
18969  case 1: __PYX_VERIFY_RETURN_INT(int, digit, digits[0])
18970  case 2:
18971  if (8 * sizeof(int) > 1 * PyLong_SHIFT) {
18972  if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
18973  __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
18974  } else if (8 * sizeof(int) >= 2 * PyLong_SHIFT) {
18975  return (int) (((((int)digits[1]) << PyLong_SHIFT) | (int)digits[0]));
18976  }
18977  }
18978  break;
18979  case 3:
18980  if (8 * sizeof(int) > 2 * PyLong_SHIFT) {
18981  if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
18982  __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
18983  } else if (8 * sizeof(int) >= 3 * PyLong_SHIFT) {
18984  return (int) (((((((int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0]));
18985  }
18986  }
18987  break;
18988  case 4:
18989  if (8 * sizeof(int) > 3 * PyLong_SHIFT) {
18990  if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
18991  __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
18992  } else if (8 * sizeof(int) >= 4 * PyLong_SHIFT) {
18993  return (int) (((((((((int)digits[3]) << PyLong_SHIFT) | (int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0]));
18994  }
18995  }
18996  break;
18997  }
18998 #endif
18999 #if CYTHON_COMPILING_IN_CPYTHON
19000  if (unlikely(Py_SIZE(x) < 0)) {
19001  goto raise_neg_overflow;
19002  }
19003 #else
19004  {
19005  int result = PyObject_RichCompareBool(x, Py_False, Py_LT);
19006  if (unlikely(result < 0))
19007  return (int) -1;
19008  if (unlikely(result == 1))
19009  goto raise_neg_overflow;
19010  }
19011 #endif
19012  if (sizeof(int) <= sizeof(unsigned long)) {
19013  __PYX_VERIFY_RETURN_INT_EXC(int, unsigned long, PyLong_AsUnsignedLong(x))
19014 #ifdef HAVE_LONG_LONG
19015  } else if (sizeof(int) <= sizeof(unsigned PY_LONG_LONG)) {
19016  __PYX_VERIFY_RETURN_INT_EXC(int, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x))
19017 #endif
19018  }
19019  } else {
19020 #if CYTHON_USE_PYLONG_INTERNALS
19021  const digit* digits = ((PyLongObject*)x)->ob_digit;
19022  switch (Py_SIZE(x)) {
19023  case 0: return (int) 0;
19024  case -1: __PYX_VERIFY_RETURN_INT(int, sdigit, (sdigit) (-(sdigit)digits[0]))
19025  case 1: __PYX_VERIFY_RETURN_INT(int, digit, +digits[0])
19026  case -2:
19027  if (8 * sizeof(int) - 1 > 1 * PyLong_SHIFT) {
19028  if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
19029  __PYX_VERIFY_RETURN_INT(int, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
19030  } else if (8 * sizeof(int) - 1 > 2 * PyLong_SHIFT) {
19031  return (int) (((int)-1)*(((((int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
19032  }
19033  }
19034  break;
19035  case 2:
19036  if (8 * sizeof(int) > 1 * PyLong_SHIFT) {
19037  if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
19038  __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
19039  } else if (8 * sizeof(int) - 1 > 2 * PyLong_SHIFT) {
19040  return (int) ((((((int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
19041  }
19042  }
19043  break;
19044  case -3:
19045  if (8 * sizeof(int) - 1 > 2 * PyLong_SHIFT) {
19046  if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
19047  __PYX_VERIFY_RETURN_INT(int, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
19048  } else if (8 * sizeof(int) - 1 > 3 * PyLong_SHIFT) {
19049  return (int) (((int)-1)*(((((((int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
19050  }
19051  }
19052  break;
19053  case 3:
19054  if (8 * sizeof(int) > 2 * PyLong_SHIFT) {
19055  if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
19056  __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
19057  } else if (8 * sizeof(int) - 1 > 3 * PyLong_SHIFT) {
19058  return (int) ((((((((int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
19059  }
19060  }
19061  break;
19062  case -4:
19063  if (8 * sizeof(int) - 1 > 3 * PyLong_SHIFT) {
19064  if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
19065  __PYX_VERIFY_RETURN_INT(int, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
19066  } else if (8 * sizeof(int) - 1 > 4 * PyLong_SHIFT) {
19067  return (int) (((int)-1)*(((((((((int)digits[3]) << PyLong_SHIFT) | (int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
19068  }
19069  }
19070  break;
19071  case 4:
19072  if (8 * sizeof(int) > 3 * PyLong_SHIFT) {
19073  if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
19074  __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
19075  } else if (8 * sizeof(int) - 1 > 4 * PyLong_SHIFT) {
19076  return (int) ((((((((((int)digits[3]) << PyLong_SHIFT) | (int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
19077  }
19078  }
19079  break;
19080  }
19081 #endif
19082  if (sizeof(int) <= sizeof(long)) {
19083  __PYX_VERIFY_RETURN_INT_EXC(int, long, PyLong_AsLong(x))
19084 #ifdef HAVE_LONG_LONG
19085  } else if (sizeof(int) <= sizeof(PY_LONG_LONG)) {
19086  __PYX_VERIFY_RETURN_INT_EXC(int, PY_LONG_LONG, PyLong_AsLongLong(x))
19087 #endif
19088  }
19089  }
19090  {
19091 #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray)
19092  PyErr_SetString(PyExc_RuntimeError,
19093  "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers");
19094 #else
19095  int val;
19096  PyObject *v = __Pyx_PyNumber_IntOrLong(x);
19097  #if PY_MAJOR_VERSION < 3
19098  if (likely(v) && !PyLong_Check(v)) {
19099  PyObject *tmp = v;
19100  v = PyNumber_Long(tmp);
19101  Py_DECREF(tmp);
19102  }
19103  #endif
19104  if (likely(v)) {
19105  int one = 1; int is_little = (int)*(unsigned char *)&one;
19106  unsigned char *bytes = (unsigned char *)&val;
19107  int ret = _PyLong_AsByteArray((PyLongObject *)v,
19108  bytes, sizeof(val),
19109  is_little, !is_unsigned);
19110  Py_DECREF(v);
19111  if (likely(!ret))
19112  return val;
19113  }
19114 #endif
19115  return (int) -1;
19116  }
19117  } else {
19118  int val;
19119  PyObject *tmp = __Pyx_PyNumber_IntOrLong(x);
19120  if (!tmp) return (int) -1;
19121  val = __Pyx_PyInt_As_int(tmp);
19122  Py_DECREF(tmp);
19123  return val;
19124  }
19125 raise_overflow:
19126  PyErr_SetString(PyExc_OverflowError,
19127  "value too large to convert to int");
19128  return (int) -1;
19129 raise_neg_overflow:
19130  PyErr_SetString(PyExc_OverflowError,
19131  "can't convert negative value to int");
19132  return (int) -1;
19133 }
19134 
19135 /* CIntToPy */
19136  static CYTHON_INLINE PyObject* __Pyx_PyInt_From_Py_intptr_t(Py_intptr_t value) {
19137 #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
19138 #pragma GCC diagnostic push
19139 #pragma GCC diagnostic ignored "-Wconversion"
19140 #endif
19141  const Py_intptr_t neg_one = (Py_intptr_t) -1, const_zero = (Py_intptr_t) 0;
19142 #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
19143 #pragma GCC diagnostic pop
19144 #endif
19145  const int is_unsigned = neg_one > const_zero;
19146  if (is_unsigned) {
19147  if (sizeof(Py_intptr_t) < sizeof(long)) {
19148  return PyInt_FromLong((long) value);
19149  } else if (sizeof(Py_intptr_t) <= sizeof(unsigned long)) {
19150  return PyLong_FromUnsignedLong((unsigned long) value);
19151 #ifdef HAVE_LONG_LONG
19152  } else if (sizeof(Py_intptr_t) <= sizeof(unsigned PY_LONG_LONG)) {
19153  return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value);
19154 #endif
19155  }
19156  } else {
19157  if (sizeof(Py_intptr_t) <= sizeof(long)) {
19158  return PyInt_FromLong((long) value);
19159 #ifdef HAVE_LONG_LONG
19160  } else if (sizeof(Py_intptr_t) <= sizeof(PY_LONG_LONG)) {
19161  return PyLong_FromLongLong((PY_LONG_LONG) value);
19162 #endif
19163  }
19164  }
19165  {
19166  int one = 1; int little = (int)*(unsigned char *)&one;
19167  unsigned char *bytes = (unsigned char *)&value;
19168  return _PyLong_FromByteArray(bytes, sizeof(Py_intptr_t),
19169  little, !is_unsigned);
19170  }
19171 }
19172 
19173 /* CIntToPy */
19174  static CYTHON_INLINE PyObject* __Pyx_PyInt_From_int(int value) {
19175 #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
19176 #pragma GCC diagnostic push
19177 #pragma GCC diagnostic ignored "-Wconversion"
19178 #endif
19179  const int neg_one = (int) -1, const_zero = (int) 0;
19180 #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
19181 #pragma GCC diagnostic pop
19182 #endif
19183  const int is_unsigned = neg_one > const_zero;
19184  if (is_unsigned) {
19185  if (sizeof(int) < sizeof(long)) {
19186  return PyInt_FromLong((long) value);
19187  } else if (sizeof(int) <= sizeof(unsigned long)) {
19188  return PyLong_FromUnsignedLong((unsigned long) value);
19189 #ifdef HAVE_LONG_LONG
19190  } else if (sizeof(int) <= sizeof(unsigned PY_LONG_LONG)) {
19191  return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value);
19192 #endif
19193  }
19194  } else {
19195  if (sizeof(int) <= sizeof(long)) {
19196  return PyInt_FromLong((long) value);
19197 #ifdef HAVE_LONG_LONG
19198  } else if (sizeof(int) <= sizeof(PY_LONG_LONG)) {
19199  return PyLong_FromLongLong((PY_LONG_LONG) value);
19200 #endif
19201  }
19202  }
19203  {
19204  int one = 1; int little = (int)*(unsigned char *)&one;
19205  unsigned char *bytes = (unsigned char *)&value;
19206  return _PyLong_FromByteArray(bytes, sizeof(int),
19207  little, !is_unsigned);
19208  }
19209 }
19210 
19211 /* CIntToPy */
19212  static CYTHON_INLINE PyObject* __Pyx_PyInt_From_long(long value) {
19213 #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
19214 #pragma GCC diagnostic push
19215 #pragma GCC diagnostic ignored "-Wconversion"
19216 #endif
19217  const long neg_one = (long) -1, const_zero = (long) 0;
19218 #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
19219 #pragma GCC diagnostic pop
19220 #endif
19221  const int is_unsigned = neg_one > const_zero;
19222  if (is_unsigned) {
19223  if (sizeof(long) < sizeof(long)) {
19224  return PyInt_FromLong((long) value);
19225  } else if (sizeof(long) <= sizeof(unsigned long)) {
19226  return PyLong_FromUnsignedLong((unsigned long) value);
19227 #ifdef HAVE_LONG_LONG
19228  } else if (sizeof(long) <= sizeof(unsigned PY_LONG_LONG)) {
19229  return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value);
19230 #endif
19231  }
19232  } else {
19233  if (sizeof(long) <= sizeof(long)) {
19234  return PyInt_FromLong((long) value);
19235 #ifdef HAVE_LONG_LONG
19236  } else if (sizeof(long) <= sizeof(PY_LONG_LONG)) {
19237  return PyLong_FromLongLong((PY_LONG_LONG) value);
19238 #endif
19239  }
19240  }
19241  {
19242  int one = 1; int little = (int)*(unsigned char *)&one;
19243  unsigned char *bytes = (unsigned char *)&value;
19244  return _PyLong_FromByteArray(bytes, sizeof(long),
19245  little, !is_unsigned);
19246  }
19247 }
19248 
19249 /* CIntFromPy */
19250  static CYTHON_INLINE long __Pyx_PyInt_As_long(PyObject *x) {
19251 #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
19252 #pragma GCC diagnostic push
19253 #pragma GCC diagnostic ignored "-Wconversion"
19254 #endif
19255  const long neg_one = (long) -1, const_zero = (long) 0;
19256 #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
19257 #pragma GCC diagnostic pop
19258 #endif
19259  const int is_unsigned = neg_one > const_zero;
19260 #if PY_MAJOR_VERSION < 3
19261  if (likely(PyInt_Check(x))) {
19262  if (sizeof(long) < sizeof(long)) {
19263  __PYX_VERIFY_RETURN_INT(long, long, PyInt_AS_LONG(x))
19264  } else {
19265  long val = PyInt_AS_LONG(x);
19266  if (is_unsigned && unlikely(val < 0)) {
19267  goto raise_neg_overflow;
19268  }
19269  return (long) val;
19270  }
19271  } else
19272 #endif
19273  if (likely(PyLong_Check(x))) {
19274  if (is_unsigned) {
19275 #if CYTHON_USE_PYLONG_INTERNALS
19276  const digit* digits = ((PyLongObject*)x)->ob_digit;
19277  switch (Py_SIZE(x)) {
19278  case 0: return (long) 0;
19279  case 1: __PYX_VERIFY_RETURN_INT(long, digit, digits[0])
19280  case 2:
19281  if (8 * sizeof(long) > 1 * PyLong_SHIFT) {
19282  if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
19283  __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
19284  } else if (8 * sizeof(long) >= 2 * PyLong_SHIFT) {
19285  return (long) (((((long)digits[1]) << PyLong_SHIFT) | (long)digits[0]));
19286  }
19287  }
19288  break;
19289  case 3:
19290  if (8 * sizeof(long) > 2 * PyLong_SHIFT) {
19291  if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
19292  __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
19293  } else if (8 * sizeof(long) >= 3 * PyLong_SHIFT) {
19294  return (long) (((((((long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0]));
19295  }
19296  }
19297  break;
19298  case 4:
19299  if (8 * sizeof(long) > 3 * PyLong_SHIFT) {
19300  if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
19301  __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
19302  } else if (8 * sizeof(long) >= 4 * PyLong_SHIFT) {
19303  return (long) (((((((((long)digits[3]) << PyLong_SHIFT) | (long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0]));
19304  }
19305  }
19306  break;
19307  }
19308 #endif
19309 #if CYTHON_COMPILING_IN_CPYTHON
19310  if (unlikely(Py_SIZE(x) < 0)) {
19311  goto raise_neg_overflow;
19312  }
19313 #else
19314  {
19315  int result = PyObject_RichCompareBool(x, Py_False, Py_LT);
19316  if (unlikely(result < 0))
19317  return (long) -1;
19318  if (unlikely(result == 1))
19319  goto raise_neg_overflow;
19320  }
19321 #endif
19322  if (sizeof(long) <= sizeof(unsigned long)) {
19323  __PYX_VERIFY_RETURN_INT_EXC(long, unsigned long, PyLong_AsUnsignedLong(x))
19324 #ifdef HAVE_LONG_LONG
19325  } else if (sizeof(long) <= sizeof(unsigned PY_LONG_LONG)) {
19326  __PYX_VERIFY_RETURN_INT_EXC(long, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x))
19327 #endif
19328  }
19329  } else {
19330 #if CYTHON_USE_PYLONG_INTERNALS
19331  const digit* digits = ((PyLongObject*)x)->ob_digit;
19332  switch (Py_SIZE(x)) {
19333  case 0: return (long) 0;
19334  case -1: __PYX_VERIFY_RETURN_INT(long, sdigit, (sdigit) (-(sdigit)digits[0]))
19335  case 1: __PYX_VERIFY_RETURN_INT(long, digit, +digits[0])
19336  case -2:
19337  if (8 * sizeof(long) - 1 > 1 * PyLong_SHIFT) {
19338  if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
19339  __PYX_VERIFY_RETURN_INT(long, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
19340  } else if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) {
19341  return (long) (((long)-1)*(((((long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
19342  }
19343  }
19344  break;
19345  case 2:
19346  if (8 * sizeof(long) > 1 * PyLong_SHIFT) {
19347  if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
19348  __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
19349  } else if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) {
19350  return (long) ((((((long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
19351  }
19352  }
19353  break;
19354  case -3:
19355  if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) {
19356  if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
19357  __PYX_VERIFY_RETURN_INT(long, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
19358  } else if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) {
19359  return (long) (((long)-1)*(((((((long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
19360  }
19361  }
19362  break;
19363  case 3:
19364  if (8 * sizeof(long) > 2 * PyLong_SHIFT) {
19365  if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
19366  __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
19367  } else if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) {
19368  return (long) ((((((((long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
19369  }
19370  }
19371  break;
19372  case -4:
19373  if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) {
19374  if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
19375  __PYX_VERIFY_RETURN_INT(long, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
19376  } else if (8 * sizeof(long) - 1 > 4 * PyLong_SHIFT) {
19377  return (long) (((long)-1)*(((((((((long)digits[3]) << PyLong_SHIFT) | (long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
19378  }
19379  }
19380  break;
19381  case 4:
19382  if (8 * sizeof(long) > 3 * PyLong_SHIFT) {
19383  if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
19384  __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
19385  } else if (8 * sizeof(long) - 1 > 4 * PyLong_SHIFT) {
19386  return (long) ((((((((((long)digits[3]) << PyLong_SHIFT) | (long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
19387  }
19388  }
19389  break;
19390  }
19391 #endif
19392  if (sizeof(long) <= sizeof(long)) {
19393  __PYX_VERIFY_RETURN_INT_EXC(long, long, PyLong_AsLong(x))
19394 #ifdef HAVE_LONG_LONG
19395  } else if (sizeof(long) <= sizeof(PY_LONG_LONG)) {
19396  __PYX_VERIFY_RETURN_INT_EXC(long, PY_LONG_LONG, PyLong_AsLongLong(x))
19397 #endif
19398  }
19399  }
19400  {
19401 #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray)
19402  PyErr_SetString(PyExc_RuntimeError,
19403  "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers");
19404 #else
19405  long val;
19406  PyObject *v = __Pyx_PyNumber_IntOrLong(x);
19407  #if PY_MAJOR_VERSION < 3
19408  if (likely(v) && !PyLong_Check(v)) {
19409  PyObject *tmp = v;
19410  v = PyNumber_Long(tmp);
19411  Py_DECREF(tmp);
19412  }
19413  #endif
19414  if (likely(v)) {
19415  int one = 1; int is_little = (int)*(unsigned char *)&one;
19416  unsigned char *bytes = (unsigned char *)&val;
19417  int ret = _PyLong_AsByteArray((PyLongObject *)v,
19418  bytes, sizeof(val),
19419  is_little, !is_unsigned);
19420  Py_DECREF(v);
19421  if (likely(!ret))
19422  return val;
19423  }
19424 #endif
19425  return (long) -1;
19426  }
19427  } else {
19428  long val;
19429  PyObject *tmp = __Pyx_PyNumber_IntOrLong(x);
19430  if (!tmp) return (long) -1;
19431  val = __Pyx_PyInt_As_long(tmp);
19432  Py_DECREF(tmp);
19433  return val;
19434  }
19435 raise_overflow:
19436  PyErr_SetString(PyExc_OverflowError,
19437  "value too large to convert to long");
19438  return (long) -1;
19439 raise_neg_overflow:
19440  PyErr_SetString(PyExc_OverflowError,
19441  "can't convert negative value to long");
19442  return (long) -1;
19443 }
19444 
19445 /* FastTypeChecks */
19446  #if CYTHON_COMPILING_IN_CPYTHON
19447 static int __Pyx_InBases(PyTypeObject *a, PyTypeObject *b) {
19448  while (a) {
19449  a = a->tp_base;
19450  if (a == b)
19451  return 1;
19452  }
19453  return b == &PyBaseObject_Type;
19454 }
19455 static CYTHON_INLINE int __Pyx_IsSubtype(PyTypeObject *a, PyTypeObject *b) {
19456  PyObject *mro;
19457  if (a == b) return 1;
19458  mro = a->tp_mro;
19459  if (likely(mro)) {
19460  Py_ssize_t i, n;
19461  n = PyTuple_GET_SIZE(mro);
19462  for (i = 0; i < n; i++) {
19463  if (PyTuple_GET_ITEM(mro, i) == (PyObject *)b)
19464  return 1;
19465  }
19466  return 0;
19467  }
19468  return __Pyx_InBases(a, b);
19469 }
19470 #if PY_MAJOR_VERSION == 2
19471 static int __Pyx_inner_PyErr_GivenExceptionMatches2(PyObject *err, PyObject* exc_type1, PyObject* exc_type2) {
19472  PyObject *exception, *value, *tb;
19473  int res;
19474  __Pyx_PyThreadState_declare
19475  __Pyx_PyThreadState_assign
19476  __Pyx_ErrFetch(&exception, &value, &tb);
19477  res = exc_type1 ? PyObject_IsSubclass(err, exc_type1) : 0;
19478  if (unlikely(res == -1)) {
19479  PyErr_WriteUnraisable(err);
19480  res = 0;
19481  }
19482  if (!res) {
19483  res = PyObject_IsSubclass(err, exc_type2);
19484  if (unlikely(res == -1)) {
19485  PyErr_WriteUnraisable(err);
19486  res = 0;
19487  }
19488  }
19489  __Pyx_ErrRestore(exception, value, tb);
19490  return res;
19491 }
19492 #else
19493 static CYTHON_INLINE int __Pyx_inner_PyErr_GivenExceptionMatches2(PyObject *err, PyObject* exc_type1, PyObject *exc_type2) {
19494  int res = exc_type1 ? __Pyx_IsSubtype((PyTypeObject*)err, (PyTypeObject*)exc_type1) : 0;
19495  if (!res) {
19496  res = __Pyx_IsSubtype((PyTypeObject*)err, (PyTypeObject*)exc_type2);
19497  }
19498  return res;
19499 }
19500 #endif
19501 static int __Pyx_PyErr_GivenExceptionMatchesTuple(PyObject *exc_type, PyObject *tuple) {
19502  Py_ssize_t i, n;
19503  assert(PyExceptionClass_Check(exc_type));
19504  n = PyTuple_GET_SIZE(tuple);
19505 #if PY_MAJOR_VERSION >= 3
19506  for (i=0; i<n; i++) {
19507  if (exc_type == PyTuple_GET_ITEM(tuple, i)) return 1;
19508  }
19509 #endif
19510  for (i=0; i<n; i++) {
19511  PyObject *t = PyTuple_GET_ITEM(tuple, i);
19512  #if PY_MAJOR_VERSION < 3
19513  if (likely(exc_type == t)) return 1;
19514  #endif
19515  if (likely(PyExceptionClass_Check(t))) {
19516  if (__Pyx_inner_PyErr_GivenExceptionMatches2(exc_type, NULL, t)) return 1;
19517  } else {
19518  }
19519  }
19520  return 0;
19521 }
19522 static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches(PyObject *err, PyObject* exc_type) {
19523  if (likely(err == exc_type)) return 1;
19524  if (likely(PyExceptionClass_Check(err))) {
19525  if (likely(PyExceptionClass_Check(exc_type))) {
19526  return __Pyx_inner_PyErr_GivenExceptionMatches2(err, NULL, exc_type);
19527  } else if (likely(PyTuple_Check(exc_type))) {
19528  return __Pyx_PyErr_GivenExceptionMatchesTuple(err, exc_type);
19529  } else {
19530  }
19531  }
19532  return PyErr_GivenExceptionMatches(err, exc_type);
19533 }
19534 static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches2(PyObject *err, PyObject *exc_type1, PyObject *exc_type2) {
19535  assert(PyExceptionClass_Check(exc_type1));
19536  assert(PyExceptionClass_Check(exc_type2));
19537  if (likely(err == exc_type1 || err == exc_type2)) return 1;
19538  if (likely(PyExceptionClass_Check(err))) {
19539  return __Pyx_inner_PyErr_GivenExceptionMatches2(err, exc_type1, exc_type2);
19540  }
19541  return (PyErr_GivenExceptionMatches(err, exc_type1) || PyErr_GivenExceptionMatches(err, exc_type2));
19542 }
19543 #endif
19544 
19545 /* CheckBinaryVersion */
19546  static int __Pyx_check_binary_version(void) {
19547  char ctversion[5];
19548  int same=1, i, found_dot;
19549  const char* rt_from_call = Py_GetVersion();
19550  PyOS_snprintf(ctversion, 5, "%d.%d", PY_MAJOR_VERSION, PY_MINOR_VERSION);
19551  found_dot = 0;
19552  for (i = 0; i < 4; i++) {
19553  if (!ctversion[i]) {
19554  same = (rt_from_call[i] < '0' || rt_from_call[i] > '9');
19555  break;
19556  }
19557  if (rt_from_call[i] != ctversion[i]) {
19558  same = 0;
19559  break;
19560  }
19561  }
19562  if (!same) {
19563  char rtversion[5] = {'\0'};
19564  char message[200];
19565  for (i=0; i<4; ++i) {
19566  if (rt_from_call[i] == '.') {
19567  if (found_dot) break;
19568  found_dot = 1;
19569  } else if (rt_from_call[i] < '0' || rt_from_call[i] > '9') {
19570  break;
19571  }
19572  rtversion[i] = rt_from_call[i];
19573  }
19574  PyOS_snprintf(message, sizeof(message),
19575  "compiletime version %s of module '%.100s' "
19576  "does not match runtime version %s",
19577  ctversion, __Pyx_MODULE_NAME, rtversion);
19578  return PyErr_WarnEx(NULL, message, 1);
19579  }
19580  return 0;
19581 }
19582 
19583 /* InitStrings */
19584  static int __Pyx_InitStrings(__Pyx_StringTabEntry *t) {
19585  while (t->p) {
19586  #if PY_MAJOR_VERSION < 3
19587  if (t->is_unicode) {
19588  *t->p = PyUnicode_DecodeUTF8(t->s, t->n - 1, NULL);
19589  } else if (t->intern) {
19590  *t->p = PyString_InternFromString(t->s);
19591  } else {
19592  *t->p = PyString_FromStringAndSize(t->s, t->n - 1);
19593  }
19594  #else
19595  if (t->is_unicode | t->is_str) {
19596  if (t->intern) {
19597  *t->p = PyUnicode_InternFromString(t->s);
19598  } else if (t->encoding) {
19599  *t->p = PyUnicode_Decode(t->s, t->n - 1, t->encoding, NULL);
19600  } else {
19601  *t->p = PyUnicode_FromStringAndSize(t->s, t->n - 1);
19602  }
19603  } else {
19604  *t->p = PyBytes_FromStringAndSize(t->s, t->n - 1);
19605  }
19606  #endif
19607  if (!*t->p)
19608  return -1;
19609  if (PyObject_Hash(*t->p) == -1)
19610  return -1;
19611  ++t;
19612  }
19613  return 0;
19614 }
19615 
19616 static CYTHON_INLINE PyObject* __Pyx_PyUnicode_FromString(const char* c_str) {
19617  return __Pyx_PyUnicode_FromStringAndSize(c_str, (Py_ssize_t)strlen(c_str));
19618 }
19619 static CYTHON_INLINE const char* __Pyx_PyObject_AsString(PyObject* o) {
19620  Py_ssize_t ignore;
19621  return __Pyx_PyObject_AsStringAndSize(o, &ignore);
19622 }
19623 #if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT
19624 #if !CYTHON_PEP393_ENABLED
19625 static const char* __Pyx_PyUnicode_AsStringAndSize(PyObject* o, Py_ssize_t *length) {
19626  char* defenc_c;
19627  PyObject* defenc = _PyUnicode_AsDefaultEncodedString(o, NULL);
19628  if (!defenc) return NULL;
19629  defenc_c = PyBytes_AS_STRING(defenc);
19630 #if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
19631  {
19632  char* end = defenc_c + PyBytes_GET_SIZE(defenc);
19633  char* c;
19634  for (c = defenc_c; c < end; c++) {
19635  if ((unsigned char) (*c) >= 128) {
19636  PyUnicode_AsASCIIString(o);
19637  return NULL;
19638  }
19639  }
19640  }
19641 #endif
19642  *length = PyBytes_GET_SIZE(defenc);
19643  return defenc_c;
19644 }
19645 #else
19646 static CYTHON_INLINE const char* __Pyx_PyUnicode_AsStringAndSize(PyObject* o, Py_ssize_t *length) {
19647  if (unlikely(__Pyx_PyUnicode_READY(o) == -1)) return NULL;
19648 #if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
19649  if (likely(PyUnicode_IS_ASCII(o))) {
19650  *length = PyUnicode_GET_LENGTH(o);
19651  return PyUnicode_AsUTF8(o);
19652  } else {
19653  PyUnicode_AsASCIIString(o);
19654  return NULL;
19655  }
19656 #else
19657  return PyUnicode_AsUTF8AndSize(o, length);
19658 #endif
19659 }
19660 #endif
19661 #endif
19662 static CYTHON_INLINE const char* __Pyx_PyObject_AsStringAndSize(PyObject* o, Py_ssize_t *length) {
19663 #if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT
19664  if (
19665 #if PY_MAJOR_VERSION < 3 && __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
19666  __Pyx_sys_getdefaultencoding_not_ascii &&
19667 #endif
19668  PyUnicode_Check(o)) {
19669  return __Pyx_PyUnicode_AsStringAndSize(o, length);
19670  } else
19671 #endif
19672 #if (!CYTHON_COMPILING_IN_PYPY) || (defined(PyByteArray_AS_STRING) && defined(PyByteArray_GET_SIZE))
19673  if (PyByteArray_Check(o)) {
19674  *length = PyByteArray_GET_SIZE(o);
19675  return PyByteArray_AS_STRING(o);
19676  } else
19677 #endif
19678  {
19679  char* result;
19680  int r = PyBytes_AsStringAndSize(o, &result, length);
19681  if (unlikely(r < 0)) {
19682  return NULL;
19683  } else {
19684  return result;
19685  }
19686  }
19687 }
19688 static CYTHON_INLINE int __Pyx_PyObject_IsTrue(PyObject* x) {
19689  int is_true = x == Py_True;
19690  if (is_true | (x == Py_False) | (x == Py_None)) return is_true;
19691  else return PyObject_IsTrue(x);
19692 }
19693 static CYTHON_INLINE int __Pyx_PyObject_IsTrueAndDecref(PyObject* x) {
19694  int retval;
19695  if (unlikely(!x)) return -1;
19696  retval = __Pyx_PyObject_IsTrue(x);
19697  Py_DECREF(x);
19698  return retval;
19699 }
19700 static PyObject* __Pyx_PyNumber_IntOrLongWrongResultType(PyObject* result, const char* type_name) {
19701 #if PY_MAJOR_VERSION >= 3
19702  if (PyLong_Check(result)) {
19703  if (PyErr_WarnFormat(PyExc_DeprecationWarning, 1,
19704  "__int__ returned non-int (type %.200s). "
19705  "The ability to return an instance of a strict subclass of int "
19706  "is deprecated, and may be removed in a future version of Python.",
19707  Py_TYPE(result)->tp_name)) {
19708  Py_DECREF(result);
19709  return NULL;
19710  }
19711  return result;
19712  }
19713 #endif
19714  PyErr_Format(PyExc_TypeError,
19715  "__%.4s__ returned non-%.4s (type %.200s)",
19716  type_name, type_name, Py_TYPE(result)->tp_name);
19717  Py_DECREF(result);
19718  return NULL;
19719 }
19720 static CYTHON_INLINE PyObject* __Pyx_PyNumber_IntOrLong(PyObject* x) {
19721 #if CYTHON_USE_TYPE_SLOTS
19722  PyNumberMethods *m;
19723 #endif
19724  const char *name = NULL;
19725  PyObject *res = NULL;
19726 #if PY_MAJOR_VERSION < 3
19727  if (likely(PyInt_Check(x) || PyLong_Check(x)))
19728 #else
19729  if (likely(PyLong_Check(x)))
19730 #endif
19731  return __Pyx_NewRef(x);
19732 #if CYTHON_USE_TYPE_SLOTS
19733  m = Py_TYPE(x)->tp_as_number;
19734  #if PY_MAJOR_VERSION < 3
19735  if (m && m->nb_int) {
19736  name = "int";
19737  res = m->nb_int(x);
19738  }
19739  else if (m && m->nb_long) {
19740  name = "long";
19741  res = m->nb_long(x);
19742  }
19743  #else
19744  if (likely(m && m->nb_int)) {
19745  name = "int";
19746  res = m->nb_int(x);
19747  }
19748  #endif
19749 #else
19750  if (!PyBytes_CheckExact(x) && !PyUnicode_CheckExact(x)) {
19751  res = PyNumber_Int(x);
19752  }
19753 #endif
19754  if (likely(res)) {
19755 #if PY_MAJOR_VERSION < 3
19756  if (unlikely(!PyInt_Check(res) && !PyLong_Check(res))) {
19757 #else
19758  if (unlikely(!PyLong_CheckExact(res))) {
19759 #endif
19760  return __Pyx_PyNumber_IntOrLongWrongResultType(res, name);
19761  }
19762  }
19763  else if (!PyErr_Occurred()) {
19764  PyErr_SetString(PyExc_TypeError,
19765  "an integer is required");
19766  }
19767  return res;
19768 }
19769 static CYTHON_INLINE Py_ssize_t __Pyx_PyIndex_AsSsize_t(PyObject* b) {
19770  Py_ssize_t ival;
19771  PyObject *x;
19772 #if PY_MAJOR_VERSION < 3
19773  if (likely(PyInt_CheckExact(b))) {
19774  if (sizeof(Py_ssize_t) >= sizeof(long))
19775  return PyInt_AS_LONG(b);
19776  else
19777  return PyInt_AsSsize_t(b);
19778  }
19779 #endif
19780  if (likely(PyLong_CheckExact(b))) {
19781  #if CYTHON_USE_PYLONG_INTERNALS
19782  const digit* digits = ((PyLongObject*)b)->ob_digit;
19783  const Py_ssize_t size = Py_SIZE(b);
19784  if (likely(__Pyx_sst_abs(size) <= 1)) {
19785  ival = likely(size) ? digits[0] : 0;
19786  if (size == -1) ival = -ival;
19787  return ival;
19788  } else {
19789  switch (size) {
19790  case 2:
19791  if (8 * sizeof(Py_ssize_t) > 2 * PyLong_SHIFT) {
19792  return (Py_ssize_t) (((((size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
19793  }
19794  break;
19795  case -2:
19796  if (8 * sizeof(Py_ssize_t) > 2 * PyLong_SHIFT) {
19797  return -(Py_ssize_t) (((((size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
19798  }
19799  break;
19800  case 3:
19801  if (8 * sizeof(Py_ssize_t) > 3 * PyLong_SHIFT) {
19802  return (Py_ssize_t) (((((((size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
19803  }
19804  break;
19805  case -3:
19806  if (8 * sizeof(Py_ssize_t) > 3 * PyLong_SHIFT) {
19807  return -(Py_ssize_t) (((((((size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
19808  }
19809  break;
19810  case 4:
19811  if (8 * sizeof(Py_ssize_t) > 4 * PyLong_SHIFT) {
19812  return (Py_ssize_t) (((((((((size_t)digits[3]) << PyLong_SHIFT) | (size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
19813  }
19814  break;
19815  case -4:
19816  if (8 * sizeof(Py_ssize_t) > 4 * PyLong_SHIFT) {
19817  return -(Py_ssize_t) (((((((((size_t)digits[3]) << PyLong_SHIFT) | (size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
19818  }
19819  break;
19820  }
19821  }
19822  #endif
19823  return PyLong_AsSsize_t(b);
19824  }
19825  x = PyNumber_Index(b);
19826  if (!x) return -1;
19827  ival = PyInt_AsSsize_t(x);
19828  Py_DECREF(x);
19829  return ival;
19830 }
19831 static CYTHON_INLINE Py_hash_t __Pyx_PyIndex_AsHash_t(PyObject* o) {
19832  if (sizeof(Py_hash_t) == sizeof(Py_ssize_t)) {
19833  return (Py_hash_t) __Pyx_PyIndex_AsSsize_t(o);
19834 #if PY_MAJOR_VERSION < 3
19835  } else if (likely(PyInt_CheckExact(o))) {
19836  return PyInt_AS_LONG(o);
19837 #endif
19838  } else {
19839  Py_ssize_t ival;
19840  PyObject *x;
19841  x = PyNumber_Index(o);
19842  if (!x) return -1;
19843  ival = PyInt_AsLong(x);
19844  Py_DECREF(x);
19845  return ival;
19846  }
19847 }
19848 static CYTHON_INLINE PyObject * __Pyx_PyBool_FromLong(long b) {
19849  return b ? __Pyx_NewRef(Py_True) : __Pyx_NewRef(Py_False);
19850 }
19851 static CYTHON_INLINE PyObject * __Pyx_PyInt_FromSize_t(size_t ival) {
19852  return PyInt_FromSize_t(ival);
19853 }
19854 
19855 
19856 #endif /* Py_PYTHON_H */
sunWheelerGSsweep
void sunWheelerGSsweep(int nElements_global, int nElementBoundaries_global, int nInteriorElementBoundaries_global, int nExteriorElementBoundaries_global, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nSpace, int *interiorElementBoundaries, int *exteriorElementBoundaries, int *elementBoundaryElements, int *elementBoundaryLocalElementBoundaries, double *dS, double *normal, double *sqrt_det_g, double *alpha, double *fluxCorrection, double *conservationResidual)
Definition: postprocessing.c:3746
getGlobalExteriorElementBoundaryRT0velocityValues
void getGlobalExteriorElementBoundaryRT0velocityValues(int nExteriorElementBoundaries_global, int nPoints_elementBoundary, int nSpace, int *elementBoundaryElementsArray, int *exteriorElementBoundariesArray, double *x_elementBoundary_global, double *rt0vdofs_element, double *v_elementBoundary_global)
Definition: postprocessing.c:1636
solveLocalBDM1projection
void solveLocalBDM1projection(int nElements_global, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nSpace, int nDOFs_test_element, int nVDOFs_element, double *BDMprojectionMatFact_element, int *BDMprojectionMatPivots_element, double *w_dS_f, double *ebq_n, double *ebq_velocity, double *p1_velocity_dofs)
Definition: postprocessing.c:2964
calculateConservationJacobianPWL
void calculateConservationJacobianPWL(int nNodes_global, int nNodes_internal, int nElements_global, int nInteriorElementBoundaries_global, int nExteriorElementBoundaries_global, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nNodes_element, int nSpace, int *interiorElementBoundaries, int *exteriorElementBoundaries, int *elementBoundaryElements, int *elementBoundaryLocalElementBoundaries, int *elementNodes, int *nodeStarElements, int *nodeStarElementNeighbors, int *nodeStarOffsets, int *nodeStarJacobianOffsets, int *nElements_node, int *internalNodes, double *w, double *normal, double *starJacobian)
postProcessRT0potentialFromP1nc
void postProcessRT0potentialFromP1nc(int nElements_global, int nQuadraturePoints_element, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nSpace, double *uQuadratureWeights_element, double *elementBarycenters, double *aElementQuadratureWeights, double *detJ, double *uQuadratureWeights_elementBoundary, double *x, double *u, double *gradu, double *x_elementBoundary, double *u_elementBoundary, double *n, double *a, double *f, double *r, double *rt0vdofs, double *rt0potential)
Definition: postprocessing.c:1682
getElementBoundaryBDM1velocityValuesLagrangeRep
void getElementBoundaryBDM1velocityValuesLagrangeRep(int nElements_global, int nBoundaries_Element, int nQuadraturePoints_elementBoundary, int nSpace, int nDOF_trial_element, int nVDOF_element, int *elementBoundaryElementsArray, int *exteriorElementBoundariesArray, double *ebq_v, double *p1_velocity_dofs, double *ebq_velocity)
Definition: postprocessing.c:3597
calculateConservationJacobianPWL_opt
void calculateConservationJacobianPWL_opt(int nNodes_owned, int nNodes_global, int nNodes_internal, int nElements_global, int nInteriorElementBoundaries_global, int nExteriorElementBoundaries_global, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nNodes_element, int nSpace, int *interiorElementBoundaries, int *exteriorElementBoundaries, int *elementBoundaryElements, int *elementBoundaryLocalElementBoundaries, int *elementNodes, int *nodeStarElements, int *nodeStarElementNeighbors, int *nElements_node, int *internalNodes, int *fluxElementBoundaries, int *fluxBoundaryNodes, double *w, double *normal, NodeStarFactorStruct *nodeStarFactor)
Definition: postprocessing.c:5170
updateRT0velocityWithAveragedPotentialP1nc_sd
void updateRT0velocityWithAveragedPotentialP1nc_sd(int nElements_global, int nQuadraturePoints_element, int nSpace, int *rowptr, int *colind, double *detJ, double *quad_a, double *phi, double *gradphi, double *a, double *rt0vdofs)
Definition: postprocessing.c:1409
postprocessAdvectiveVelocityPointEval
void postprocessAdvectiveVelocityPointEval(int nPoints, int nSpace, double updateCoef, const double *f, double *velocity)
Definition: postprocessing.c:5529
getGlobalElementBoundaryRT0velocityValues
void getGlobalElementBoundaryRT0velocityValues(int nElementBoundaries_global, int nPoints_elementBoundary, int nSpace, int *elementBoundaryElementsArray, double *x_elementBoundary_global, double *rt0vdofs_element, double *v_elementBoundary_global)
Definition: postprocessing.c:1593
getElementBoundaryRT0velocityValuesFluxRep
void getElementBoundaryRT0velocityValuesFluxRep(int nElements_global, int nElementBoundaries_element, int nPoints_elementBoundary, int nSpace, int nDetVals_element, double *nodeArray, int *elementNodesArray, double *abs_det_J, double *x_elementBoundary, double *rt0vdofs_element, double *v_elementBoundary)
Definition: postprocessing.c:2209
factorLocalBDM1projectionMatrices
void factorLocalBDM1projectionMatrices(int nElements_global, int nVDOFs_element, double *BDMprojectionMat_element, int *BDMprojectionMatPivots_element)
Definition: postprocessing.c:2906
subdomain_U_copy_global2local
void subdomain_U_copy_global2local(int max_nN_owned, int nElements_global, int nNodes_element, int *elementNodes, int *nodeStarElements, NodeStarFactorStruct *nodeStarFactor, double *subdomain_U)
Definition: postprocessing.c:5425
f
Double f
Definition: Headers.h:64
number
Int number
Definition: Headers.h:33
nodeStar_copy
int nodeStar_copy(int other_N, int *other_subdomain_dim, double **other_subdomain_L, double **other_subdomain_R, double **other_subdomain_U, PROTEUS_LAPACK_INTEGER **other_subdomain_pivots, PROTEUS_LAPACK_INTEGER **other_subdomain_column_pivots, int *N_p, int **subdomain_dim_p, double ***subdomain_L_p, double ***subdomain_R_p, double ***subdomain_U_p, PROTEUS_LAPACK_INTEGER ***subdomain_pivots_p, PROTEUS_LAPACK_INTEGER ***subdomain_column_pivots_p)
Definition: postprocessing.c:4038
calculateElementResidualPWL
void calculateElementResidualPWL(int nElements, int nDOF_element_res, int nDOF_element_resPWL, double *alpha, double *elementResidual, double *elementResidualPWL)
Definition: postprocessing.c:5616
s
Double s
Definition: Headers.h:84
subdomain_U_copy_local2global
void subdomain_U_copy_local2global(int max_nN_owned, int nElements_global, int nNodes_element, int *elementNodes, int *nodeStarElements, NodeStarFactorStruct *nodeStarFactor, double *subdomain_U)
Definition: postprocessing.c:5449
postprocessDiffusiveVelocityPointEval
void postprocessDiffusiveVelocityPointEval(int nPoints, int nSpace, double updateCoef, const double *a, const double *grad_phi, double *velocity)
Definition: postprocessing.c:5552
n
Int n
Definition: Headers.h:28
calculateConservationFluxPWL_noNeumannFix
void calculateConservationFluxPWL_noNeumannFix(int nNodes_global, int *nElements_node, NodeStarFactorStruct *nodeStarFactor)
Definition: postprocessing.c:4801
postProcessRT0velocityFromP1nc_sd
void postProcessRT0velocityFromP1nc_sd(int nElements_global, int nQuadraturePoints_element, int nDOF_test_element, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nSpace, int *rowptr, int *colind, int *nFreeDOF_element, int *freeLocal_element, double *detJ, double *sqrt_det_g, double *n, double *elementBarycenters, double *quad_a, double *quad_f, double *w_dV_r, double *w_dV_m, double *u, double *gradu, double *a, double *f, double *r, double *mt, double *rt0vdofs)
Definition: postprocessing.c:414
getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep
void getGlobalExteriorElementBoundaryRT0velocityValuesFluxRep(int nExteriorElementBoundaries_global, int nPoints_elementBoundary_global, int nSpace, int nDetVals_element, double *nodeArray, int *elementNodesArray, int *elementBoundaryElementsArray, int *exteriorElementBoundariesArray, double *abs_det_J, double *x_ebqe, double *rt0vdofs_element, double *v_ebqe)
Definition: postprocessing.c:2340
getElementRT0velocityValues
void getElementRT0velocityValues(int nElements_global, int nPoints_element, int nSpace, double *x_element, double *rt0vdofs_element, double *v_element)
Definition: postprocessing.c:1504
postProcessRT0velocityFromP1ncNoMass_sd
void postProcessRT0velocityFromP1ncNoMass_sd(int nElements_global, int nQuadraturePoints_element, int nDOF_test_element, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nSpace, int *rowptr, int *colind, int *nFreeDOF_element, int *freeLocal_element, double *detJ, double *sqrt_det_g, double *n, double *elementBarycenters, double *quad_a, double *quad_f, double *w_dV_r, double *u, double *gradu, double *a, double *f, double *r, double *rt0vdofs)
Definition: postprocessing.c:1046
v
Double v
Definition: Headers.h:95
getElementBDM2velocityValuesLagrangeRep
void getElementBDM2velocityValuesLagrangeRep(int nElements_global, int nQuadraturePoints_element, int nSpace, int nDOF_trial_element, int nVDOF_element, double *q_v, double *p1_velocity_dofs, double *q_velocity)
Definition: postprocessing.c:3427
postProcessRT0velocityFromP1nc
void postProcessRT0velocityFromP1nc(int nElements_global, int nQuadraturePoints_element, int nDOF_test_element, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nSpace, int *nFreeDOF_element, int *freeLocal_element, double *detJ, double *sqrt_det_g, double *n, double *elementBarycenters, double *quad_a, double *quad_f, double *w_dV_r, double *w_dV_m, double *u, double *gradu, double *a, double *f, double *r, double *mt, double *rt0vdofs)
Definition: postprocessing.c:51
getElementBoundaryRT0velocityValues
void getElementBoundaryRT0velocityValues(int nElements_global, int nElementBoundaries_element, int nPoints_elementBoundary, int nSpace, double *x_elementBoundary, double *rt0vdofs_element, double *v_elementBoundary)
Definition: postprocessing.c:1543
calculateConservationResidualPWL_opt
void calculateConservationResidualPWL_opt(int nNodes_owned, int nElements_global, int nInteriorElementBoundaries_global, int nExteriorElementBoundaries_global, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nNodes_element, int nSpace, int *interiorElementBoundaries, int *exteriorElementBoundaries, int *elementBoundaryElements, int *elementBoundaryLocalElementBoundaries, int *elementNodes, int *nodeStarElements, int *nodeStarElementNeighbors, int *nElements_node, int *fluxElementBoundaries, double *elementResidual, double *vAverage, double *dX, double *w, double *normal, NodeStarFactorStruct *nodeStarFactor, double *conservationResidual, double *vConservative, double *vConservative_element)
Definition: postprocessing.c:4834
getGlobalElementBoundaryRT0velocityValuesFluxRep
void getGlobalElementBoundaryRT0velocityValuesFluxRep(int nElementBoundaries_global, int nPoints_elementBoundary_global, int nSpace, int nDetVals_element, double *nodeArray, int *elementNodesArray, int *elementBoundaryElementsArray, double *abs_det_J, double *x_elementBoundary_global, double *rt0vdofs_element, double *v_elementBoundary_global)
Definition: postprocessing.c:2277
calculateConservationFluxPWL
void calculateConservationFluxPWL(int nNodes_global, int nNodes_internal, int *nElements_node, int *nodeStarOffsets, int *nodeStarJacobianOffsets, int *internalNodes, double *starR, double *starJ, double *starU)
postprocessing.h
Python interface to velocity postprocessing library.
calculateConservationResidualPWL
void calculateConservationResidualPWL(int nElements_global, int nInteriorElementBoundaries_global, int nExteriorElementBoundaries_global, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nNodes_element, int nSpace, int *interiorElementBoundaries, int *exteriorElementBoundaries, int *elementBoundaryElements, int *elementBoundaryLocalElementBoundaries, int *elementNodes, int *nodeStarElements, int *nodeStarElementNeighbors, int *nodeStarOffsets, int *nElements_node, double *elementResidual, double *vAverage, double *starU, double *dX, double *w, double *normal, double *conservationResidual, double *starR, double *vConservative, double *vConservative_element)
updateSelectedExteriorElementBoundaryFlux
void updateSelectedExteriorElementBoundaryFlux(int nExteriorElementBoundaries_global, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nDOF_test_element, int *exteriorElementBoundaries, int *elementBoundaryElements, int *elementBoundaryLocalElementBoundaries, int *skipflag_elementBoundaries, double *flux, double *w_dS, double *residual)
Update the element boundary flux on exterior element boundaries.
Definition: postprocessing.c:5482
T
Double T
Definition: Headers.h:87
calculateConservationResidualPWL_interiorBoundaries
void calculateConservationResidualPWL_interiorBoundaries(int nElements_global, int nInteriorElementBoundaries_global, int nExteriorElementBoundaries_global, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nNodes_element, int nSpace, int *interiorElementBoundaries, int *exteriorElementBoundaries, int *elementBoundaryElements, int *elementBoundaryLocalElementBoundaries, int *elementNodes, int *nodeStarElements, int *nodeStarElementNeighbors, int *nElements_node, int *fluxElementBoundaries, double *elementResidual, double *vAverage, double *dX, double *w, double *normal, NodeStarFactorStruct *nodeStarFactor, double *conservationResidual, double *vConservative, double *vConservative_element)
Definition: postprocessing.c:5649
z
Double * z
Definition: Headers.h:49
u
Double u
Definition: Headers.h:89
c
Double c
Definition: Headers.h:54
updateRT0velocityWithAveragedPotentialP1nc
void updateRT0velocityWithAveragedPotentialP1nc(int nElements_global, int nQuadraturePoints_element, int nSpace, double *detJ, double *quad_a, double *phi, double *gradphi, double *a, double *rt0vdofs)
Definition: postprocessing.c:1315
getElementBDM1velocityValuesLagrangeRep
void getElementBDM1velocityValuesLagrangeRep(int nElements_global, int nQuadraturePoints_element, int nSpace, int nDOF_trial_element, int nVDOF_element, double *q_v, double *p1_velocity_dofs, double *q_velocity)
Definition: postprocessing.c:3386
calculateConservationResidualPWL_primative
void calculateConservationResidualPWL_primative(int nElements_global, int nInteriorElementBoundaries_global, int nExteriorElementBoundaries_global, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nNodes_element, int nSpace, int *interiorElementBoundaries, int *exteriorElementBoundaries, int *elementBoundaryElements, int *elementBoundaryLocalElementBoundaries, int *skipflag_elementBoundaries, double *elementResidual, double *dX, double *normal, double *conservationResidual, double *vConservative)
Definition: postprocessing.c:5079
postProcessRT0potentialFromP1nc_sd
void postProcessRT0potentialFromP1nc_sd(int nElements_global, int nQuadraturePoints_element, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nSpace, int *rowptr, int *colind, double *uQuadratureWeights_element, double *elementBarycenters, double *aElementQuadratureWeights, double *detJ, double *uQuadratureWeights_elementBoundary, double *x, double *u, double *gradu, double *x_elementBoundary, double *u_elementBoundary, double *n, double *a, double *f, double *r, double *rt0vdofs, double *rt0potential)
Definition: postprocessing.c:1842
postProcessRT0velocityFromP1ncNoMass
void postProcessRT0velocityFromP1ncNoMass(int nElements_global, int nQuadraturePoints_element, int nDOF_test_element, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nSpace, int *nFreeDOF_element, int *freeLocal_element, double *detJ, double *sqrt_det_g, double *n, double *elementBarycenters, double *quad_a, double *quad_f, double *w_dV_r, double *u, double *gradu, double *a, double *f, double *r, double *rt0vdofs)
Definition: postprocessing.c:778
NodeStarFactorStruct
Definition: postprocessing.h:20
getRT0velocityValuesFluxRep_arbitraryElementMembership
void getRT0velocityValuesFluxRep_arbitraryElementMembership(int nElements_global, int nElementBoundaries_element, int nPoints, int nSpace, int nDetVals_element, const double *nodeArray, const int *elementNodesArray, const double *abs_det_J, const double *x, const int *element_locations, const double *rt0vdofs_element, double *v_element)
Definition: postprocessing.c:2405
calculateConservationFluxPWL_opt
void calculateConservationFluxPWL_opt(int nNodes_owned, int nNodes_global, int nNodes_internal, int *nElements_node, int *internalNodes, int *fluxBoundaryNodes, NodeStarFactorStruct *nodeStarFactor)
Definition: postprocessing.c:5361
getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep
void getGlobalExteriorElementBoundaryBDM1velocityValuesLagrangeRep(int nExteriorElementBoundaries_global, int nQuadraturePoints_elementBoundary, int nSpace, int nDOF_trial_element, int nVDOF_element, int *elementBoundaryElementsArray, int *exteriorElementBoundariesArray, double *ebqe_v, double *p1_velocity_dofs, double *ebqe_velocity)
Definition: postprocessing.c:3506
postprocessDiffusiveVelocityPointEval_sd
void postprocessDiffusiveVelocityPointEval_sd(int nPoints, int nSpace, double updateCoef, int *rowptr, int *colind, const double *a, const double *grad_phi, double *velocity)
Definition: postprocessing.c:5583
buildLocalBDM2projectionMatrices
void buildLocalBDM2projectionMatrices(int degree, int nElements_global, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nQuadraturePoints_elementInterior, int nSpace, int nDOFs_test_element, int nDOFs_trial_boundary_element, int nDOFs_trial_interior_element, int nVDOFs_element, int *edgeFlags, double *w_dS_f, double *ebq_n, double *ebq_v, double *BDMprojectionMat_element, double *q_basis_vals, double *w_int_test_grads, double *w_int_div_free, double *piola_trial_fun)
Definition: postprocessing.c:2709
calculateConservationResidualGlobalBoundaries
void calculateConservationResidualGlobalBoundaries(int nElements_global, int nInteriorElementBoundaries_global, int nExteriorElementBoundaries_global, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nNodes_element, int nSpace, int *interiorElementBoundaries, int *exteriorElementBoundaries, int *elementBoundaryElements, int *elementBoundaryLocalElementBoundaries, double *dS, double *normal, double *elementResidual, double *velocity, double *conservationResidual)
solveLocalBDM1projectionFromFlux
void solveLocalBDM1projectionFromFlux(int nElements_global, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nDOFs_test_element, int nVDOFs_element, double *BDMprojectionMatFact_element, int *BDMprojectionMatPivots_element, int *elementBoundaryElementsArray, int *elementBoundariesArray, double *w_dS_f, double *ebq_global_flux, double *p1_velocity_dofs)
Definition: postprocessing.c:3261
computeFluxCorrectionPWC
void computeFluxCorrectionPWC(int nElementBoundaries_global, int nInteriorElementBoundaries_global, int nExteriorElementBoundaries_global, int *interiorElementBoundaries, int *exteriorElementBoundaries, int *elementBoundaryElements, double *pwcW, double *pwcV, double *fluxCorrection)
Definition: postprocessing.c:3877
projectElementBoundaryVelocityToRT0fluxRep
void projectElementBoundaryVelocityToRT0fluxRep(int nElements_global, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nSpace, double *elementBoundaryQuadratureWeights, double *n, double *v_elementBoundary, double *rt0vdofs_element)
Definition: postprocessing.c:2003
r
Double r
Definition: Headers.h:83
buildLocalBDM1projectionMatrices
void buildLocalBDM1projectionMatrices(int nElements_global, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nSpace, int nDOFs_test_element, int nDOFs_trial_element, int nVDOFs_element, double *w_dS_f, double *ebq_n, double *ebq_v, double *BDMprojectionMat_element)
Definition: postprocessing.c:2571
nodeStar_free
int nodeStar_free(int N, int *subdomain_dim, double **subdomain_L, double **subdomain_R, double **subdomain_U, PROTEUS_LAPACK_INTEGER **subdomain_pivots, PROTEUS_LAPACK_INTEGER **subdomain_column_pivots)
Definition: postprocessing.c:3996
pos
double pos(double a)
Definition: testFMMandFSW.cpp:8
factorLocalBDM2projectionMatrices
void factorLocalBDM2projectionMatrices(int nElements_global, int nVDOFs_element, double *BDMprojectionMat_element, int *BDMprojectionMatPivots_element)
Definition: postprocessing.c:2935
calculateConservationJacobianPWL_interiorBoundaries
void calculateConservationJacobianPWL_interiorBoundaries(int nNodes_global, int nElements_global, int nInteriorElementBoundaries_global, int nExteriorElementBoundaries_global, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nNodes_element, int nSpace, int *interiorElementBoundaries, int *exteriorElementBoundaries, int *elementBoundaryElements, int *elementBoundaryLocalElementBoundaries, int *elementNodes, int *nodeStarElements, int *nodeStarElementNeighbors, int *nElements_node, int *fluxElementBoundaries, double *w, double *normal, NodeStarFactorStruct *nodeStarFactor)
Definition: postprocessing.c:6005
buildBDM2rhs
void buildBDM2rhs(int nElements_global, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nQuadraturePoints_elementInterior, int nSpace, int nDOFs_test_element, int nVDOFs_element, int nDOFs_trial_interior_element, double *BDMprojectionMatFact_element, int *BDMprojectionMatPivots_element, int *edgeFlags, double *w_dS_f, double *ebq_n, double *w_interior_grads, double *w_interior_divfree, double *ebq_velocity, double *q_velocity, double *p1_velocity_dofs)
Definition: postprocessing.c:3054
nodeStar_init
int nodeStar_init(int nElements_global, int nNodes_element, int nNodes_global, int *nElements_node, int *nodeStarElementsArray, int *nodeStarElementNeighborsArray, int *N_p, int **subdomain_dim_p, double ***subdomain_L_p, double ***subdomain_R_p, double ***subdomain_U_p, PROTEUS_LAPACK_INTEGER ***subdomain_pivots_p, PROTEUS_LAPACK_INTEGER ***subdomain_column_pivots_p)
Definition: postprocessing.c:3921
solveLocalBDM2projection
void solveLocalBDM2projection(int nElements_global, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nSpace, int nDOFs_test_element, int nVDOFs_element, double *BDMprojectionMatFact_element, int *BDMprojectionMatPivots_element, double *w_dS_f, double *ebq_n, double *w_interior_gradients, double *q_velocity, double *ebq_velocity, double *p1_velocity_dofs)
Definition: postprocessing.c:3213
fluxCorrectionVelocityUpdate
void fluxCorrectionVelocityUpdate(int nElements_global, int nElementBoundaries_global, int nInteriorElementBoundaries_global, int nExteriorElementBoundaries_global, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nSpace, int *interiorElementBoundaries, int *exteriorElementBoundaries, int *elementBoundaryElements, int *elementBoundaryLocalElementBoundaries, double *dS, double *normal, double *fluxCorrection, double *vConservative, double *vConservative_element)
Definition: postprocessing.c:3795
getElementRT0velocityValuesFluxRep
void getElementRT0velocityValuesFluxRep(int nElements_global, int nElementBoundaries_element, int nPoints_element, int nSpace, int nDetVals_element, double *nodeArray, int *elementNodesArray, double *abs_det_J, double *x_element, double *rt0vdofs_element, double *v_element)
Definition: postprocessing.c:2143
getElementLDGvelocityValuesLagrangeRep
void getElementLDGvelocityValuesLagrangeRep(int nElements_global, int nQuadraturePoints_element, int nSpace, int nDOF_trial_element, int nVDOF_element, double *q_v, double *velocity_dofs, double *q_velocity)
Definition: postprocessing.c:3468
projectElementBoundaryFluxToRT0fluxRep
void projectElementBoundaryFluxToRT0fluxRep(int nElements_global, int nElementBoundaries_element, int nQuadraturePoints_elementBoundary, int nDOF_RT0V_element, int *elementBoundaryElementsArray, int *elementBoundariesArray, double *elementBoundaryQuadratureWeights, double *flux_elementBoundary, double *rt0vdofs_element)
Definition: postprocessing.c:2084