Nektar++
Functions
Python/StdMatrixKey.cpp File Reference
#include <StdRegions/StdExpansion.h>
#include <StdRegions/StdMatrixKey.h>
#include <vector>
#include <LibUtilities/Python/NekPyConfig.hpp>
#include <StdRegions/Python/VarCoeffEntry.hpp>

Go to the source code of this file.

Functions

std::unique_ptr< StdMatrixKeyStdMatrixKey_Init (const MatrixType matType, const LibUtilities::ShapeType shapeType, const StdExpansionSharedPtr exp, const ConstFactorMap &constFactorMap, const VarCoeffMap &varCoeffMap)
 
void export_StdMatrixKey (py::module &m)
 Export for StdMatrixKey enumeration. More...
 

Function Documentation

◆ export_StdMatrixKey()

void export_StdMatrixKey ( py::module &  m)

Export for StdMatrixKey enumeration.

Definition at line 61 of file Python/StdMatrixKey.cpp.

62{
66
67 // Wrapper for constant factor map.
68 py::bind_map<ConstFactorMap>(m, "ConstFactorMap");
69
70 // Wrapper for variable coefficients map.
71 py::bind_map<VarCoeffMap>(m, "VarCoeffMap");
72
73 py::class_<StdMatrixKey>(m, "StdMatrixKey")
74 .def(py::init(&StdMatrixKey_Init), py::arg("matType"),
75 py::arg("shapeType"), py::arg("exp"),
76 py::arg("constFactorMap") = NullConstFactorMap,
77 py::arg("varCoeffMap") = NullVarCoeffMap)
78
79 .def("GetMatrixType", &StdMatrixKey::GetMatrixType)
80 .def("GetShapeType", &StdMatrixKey::GetShapeType)
81 .def("GetNcoeffs", &StdMatrixKey::GetNcoeffs)
82 .def("GetBasis", &StdMatrixKey::GetBasis);
83}
#define NEKPY_WRAP_ENUM(MOD, ENUMNAME, MAPNAME)
Definition: NekPyConfig.hpp:53
std::unique_ptr< StdMatrixKey > StdMatrixKey_Init(const MatrixType matType, const LibUtilities::ShapeType shapeType, const StdExpansionSharedPtr exp, const ConstFactorMap &constFactorMap, const VarCoeffMap &varCoeffMap)
const char *const VarCoeffTypeMap[]
Definition: StdRegions.hpp:234
const char *const ConstFactorTypeMap[]
Definition: StdRegions.hpp:413
const char *const MatrixTypeMap[]
Definition: StdRegions.hpp:139
static ConstFactorMap NullConstFactorMap
Definition: StdRegions.hpp:431
static VarCoeffMap NullVarCoeffMap
Definition: StdRegions.hpp:376

References Nektar::StdRegions::ConstFactorTypeMap, Nektar::StdRegions::MatrixTypeMap, NEKPY_WRAP_ENUM, Nektar::StdRegions::NullConstFactorMap, Nektar::StdRegions::NullVarCoeffMap, StdMatrixKey_Init(), and Nektar::StdRegions::VarCoeffTypeMap.

Referenced by PYBIND11_MODULE().

◆ StdMatrixKey_Init()

std::unique_ptr< StdMatrixKey > StdMatrixKey_Init ( const MatrixType  matType,
const LibUtilities::ShapeType  shapeType,
const StdExpansionSharedPtr  exp,
const ConstFactorMap constFactorMap,
const VarCoeffMap varCoeffMap 
)

Definition at line 49 of file Python/StdMatrixKey.cpp.

53{
54 return std::make_unique<StdMatrixKey>(matType, shapeType, *exp,
55 constFactorMap, varCoeffMap);
56}

Referenced by export_StdMatrixKey().