58 m_session->MatchSolverInfo(
"MappingImplicitPressure",
"True",
60 m_session->MatchSolverInfo(
"MappingImplicitViscous",
"True",
81 int physTot =
m_fields[0]->GetTotPoints();
106 for (
int i = 0; i < nvel; i++)
114 for (
int i = 0; i < nvel; ++i)
120 m_fields[0]->HomogeneousBwdTrans(gradP[i], wk[i]);
132 for (
int i = 0; i < nvel; ++i)
134 Vmath::Vmul(physTot, correction[i], 1, Jac, 1, correction[i],
138 for (
int i = 0; i < nvel; ++i)
146 for (
int i = 0; i < nvel; ++i)
148 m_pressure->HomogeneousFwdTrans(correction[i], correction[i]);
152 for (
int i = 0; i < nvel; ++i)
154 Vmath::Vsub(physTot, gradP[i], 1, correction[i], 1, correction[i],
165 if (boost::iequals(
m_PBndConds[n]->GetUserDefined(),
"H"))
167 m_fields[0]->GetBndElmtExpansion(n, BndElmtExp);
172 m_fields[0]->ExtractPhysToBndElmt(n, correction[i],
180 m_fields[0]->ExtractElmtToBndPhys(n, correctionElmt[i],
183 m_PBndExp[n]->NormVectorIProductWRTBase(BndValues, Vals);
215 int physTot =
m_fields[0]->GetTotPoints();
240 for (
int i = 0; i < nvel; i++)
251 m_fields[0]->HomogeneousBwdTrans(N[i], N_new[i]);
257 Vmath::Vmul(physTot, Jac, 1, N_new[i], 1, N_new[i], 1);
260 m_fields[0]->HomogeneousFwdTrans(N_new[i], N_new[i]);
265 for (i = 0; i < nvel; i++)
269 m_fields[0]->HomogeneousBwdTrans(fields[i], fields_new[i]);
284 m_mapping->DotGradJacobian(fields_new, tmp);
287 bool wavespace =
m_fields[0]->GetWaveSpace();
293 Vmath::Vadd(physTot, Q_field[i], 1, tmp2, 1, Q_field[i], 1);
295 m_fields[0]->SetWaveSpace(wavespace);
301 Vmath::Vmul(physTot, Jac, 1, fields_new[i], 1, fields_new[i], 1);
302 Vmath::Vmul(physTot, Jac, 1, Q_field[i], 1, Q_field[i], 1);
305 m_fields[0]->HomogeneousFwdTrans(fields_new[i], fields_new[i]);
306 m_fields[0]->HomogeneousFwdTrans(Q_field[i], Q_field[i]);
314 if (boost::iequals(
m_PBndConds[n]->GetUserDefined(),
"H"))
316 m_fields[0]->GetBndElmtExpansion(n, BndElmtExp);
317 int nq = BndElmtExp->GetTotPoints();
322 m_fields[0]->ExtractPhysToBndElmt(n, fields_new[i],
324 m_fields[0]->ExtractPhysToBndElmt(n, N_new[i],
326 m_fields[0]->ExtractPhysToBndElmt(n, Q_field[i], Q[i]);
343 m_fields[0]->ExtractElmtToBndPhys(n, Q[i], BndValues[i]);
345 m_PBndExp[n]->NormVectorIProductWRTBase(BndValues, Pvals);
349 m_fields[0]->ExtractElmtToBndPhys(n, Velocity[i],
352 m_PBndExp[n]->NormVectorIProductWRTBase(BndValues, Uvals);
static GLOBAL_MAPPING_EXPORT MappingSharedPtr Load(const LibUtilities::SessionReaderSharedPtr &pSession, const Array< OneD, MultiRegions::ExpListSharedPtr > &pFields)
Return a pointer to the mapping, creating it on first call.
tKey RegisterCreatorFunction(tKey idKey, CreatorFunction classCreator, std::string pDesc="")
Register a class with the factory.
An abstract base class encapsulating the concept of advection of a vector field.
std::shared_ptr< SessionReader > SessionReaderSharedPtr
MultiRegions::Direction const DirCartesianMap[]
std::shared_ptr< ExpList > ExpListSharedPtr
Shared pointer to an ExpList object.
std::shared_ptr< Advection > AdvectionSharedPtr
A shared pointer to an Advection object.
The above copyright notice and this permission notice shall be included.
ExtrapolateFactory & GetExtrapolateFactory()
void Vmul(int n, const T *x, const int incx, const T *y, const int incy, T *z, const int incz)
Multiply vector z = x*y.
void Vadd(int n, const T *x, const int incx, const T *y, const int incy, T *z, const int incz)
Add vector z = x+y.
void Smul(int n, const T alpha, const T *x, const int incx, T *y, const int incy)
Scalar multiply y = alpha*x.
void Vdiv(int n, const T *x, const int incx, const T *y, const int incy, T *z, const int incz)
Multiply vector z = x/y.
void Vcopy(int n, const T *x, const int incx, T *y, const int incy)
void Vsub(int n, const T *x, const int incx, const T *y, const int incy, T *z, const int incz)
Subtract vector z = x-y.