proteus  1.8.1
C/C++/Fortran libraries
SW2DCV.cpp
Go to the documentation of this file.
1 #include "pybind11/pybind11.h"
2 #include "pybind11/stl_bind.h"
3 
4 #define FORCE_IMPORT_ARRAY
5 #include "SW2DCV.h"
6 
7 #if defined(__GNUC__) && !defined(__clang__)
8 namespace workaround {
9 inline void define_allocators() {
10  std::allocator<int> a0;
11  std::allocator<double> a1;
12 }
13 } // namespace workaround
14 #endif
15 
16 namespace py = pybind11;
18 using pybind11::return_value_policy;
19 
20 PYBIND11_MODULE(cSW2DCV, m) {
21  xt::import_numpy();
22 
23  py::class_<SW2DCV_base>(m, "cSW2DCV_base")
25  .def("convexLimiting", &SW2DCV_base::convexLimiting)
26  .def("calculateEdgeBasedCFL", &SW2DCV_base::calculateEdgeBasedCFL,
27  return_value_policy::take_ownership)
28  .def("calculateEV", &SW2DCV_base::calculateEV)
29  .def("calculateResidual", &SW2DCV_base::calculateResidual)
30  .def("calculateMassMatrix", &SW2DCV_base::calculateMassMatrix)
31  .def("calculateLumpedMassMatrix",
32  &SW2DCV_base::calculateLumpedMassMatrix);
33 }
proteus::SW2DCV_base
Definition: SW2DCV.h:132
proteus::newSW2DCV
SW2DCV_base * newSW2DCV(int nSpaceIn, int nQuadraturePoints_elementIn, int nDOF_mesh_trial_elementIn, int nDOF_trial_elementIn, int nDOF_test_elementIn, int nQuadraturePoints_elementBoundaryIn, int CompKernelFlag)
Definition: SW2DCV.h:2155
init
void init(void)
PYBIND11_MODULE
PYBIND11_MODULE(cSW2DCV, m)
Definition: SW2DCV.cpp:20
SW2DCV.h