43 RegisterCreatorFunction(
"NonConservative",
60 Array<OneD, MultiRegions::ExpListSharedPtr> pFields)
66 const int nConvectiveFields,
67 const Array<OneD, MultiRegions::ExpListSharedPtr> &fields,
68 const Array<
OneD, Array<OneD, NekDouble> > &advVel,
69 const Array<
OneD, Array<OneD, NekDouble> > &inarray,
70 Array<
OneD, Array<OneD, NekDouble> > &outarray)
72 int nDim = advVel.num_elements();
73 int nPointsTot = fields[0]->GetNpoints();
74 Array<OneD, NekDouble> grad0,grad1,grad2;
76 grad0 = Array<OneD, NekDouble> (nPointsTot);
80 grad1 = Array<OneD,NekDouble>(nPointsTot);
85 grad2 = Array<OneD,NekDouble>(nPointsTot);
89 for (
int i = 0; i < nConvectiveFields; ++i)
95 fields[0]->PhysDeriv(inarray[i], grad0);
103 fields[0]->PhysDeriv(inarray[i], grad0, grad1);
120 fields[0]->PhysDeriv(inarray[i], grad0, grad1, grad2);
141 ASSERTL0(
false,
"dimension unknown");