39 #include <boost/core/ignore_unused.hpp>
54 ProcessNumModes::create,
55 "Computes number of modes in each direction for each element.");
70 int expdim =
m_f->m_graph->GetMeshDimension();
71 int nfields =
m_f->m_variables.size();
72 int addfields = expdim;
74 m_f->m_variables.push_back(
"P1");
77 m_f->m_variables.push_back(
"P2");
81 m_f->m_variables.push_back(
"P3");
85 if (
m_f->m_exp[0]->GetNumElmts() == 0)
90 int npoints =
m_f->m_exp[0]->GetNpoints();
94 m_f->m_session->LoadParameter(
"Strip_Z", nstrips, 1);
96 for (i = 0; i < addfields; ++i)
103 int nExp, nq, offset;
104 nExp =
m_f->m_exp[0]->GetExpSize();
106 for (
int n = 0; n < nExp; n++)
108 offset =
m_f->m_exp[0]->GetPhys_Offset(n);
109 nq =
m_f->m_exp[0]->GetExp(n)->GetTotPoints();
111 for (i = 0; i < expdim; i++)
113 int P =
m_f->m_exp[0]->GetExp(n)->GetBasis(i)->GetNumModes();
119 for (s = 0; s < nstrips; ++s)
121 for (i = 0; i < addfields; ++i)
123 Exp =
m_f->AppendExpList(
m_f->m_numHomogeneousDir);
124 Vmath::Vcopy(npoints, outfield[i], 1, Exp->UpdatePhys(), 1);
125 Exp->FwdTrans_IterPerExp(outfield[i], Exp->UpdateCoeffs());
128 m_f->m_exp.begin() + s * (nfields + addfields) + nfields + i;
129 m_f->m_exp.insert(it, Exp);
FieldSharedPtr m_f
Field object.
Abstract base class for processing modules.
virtual void Process(po::variables_map &vm)
Write mesh to output file.
virtual ~ProcessNumModes()
tKey RegisterCreatorFunction(tKey idKey, CreatorFunction classCreator, std::string pDesc="")
Register a class with the factory.
std::shared_ptr< Field > FieldSharedPtr
std::pair< ModuleType, std::string > ModuleKey
ModuleFactory & GetModuleFactory()
std::shared_ptr< ExpList > ExpListSharedPtr
Shared pointer to an ExpList object.
The above copyright notice and this permission notice shall be included.
void Fill(int n, const T alpha, T *x, const int incx)
Fill a vector with a constant value.
void Vcopy(int n, const T *x, const int incx, T *y, const int incy)