45 "Image warping system.");
55 UnsteadySystem::v_InitObject();
87 ASSERTL0(
false,
"Implicit unsteady Advection not set up.");
103 int ncoeffs = inarray[0].num_elements();
110 "CG not implemented yet.");
121 m_fields[0]->PhysDeriv(inarray[0], dIdx1, dIdx2);
129 for (i = 0; i < 2; ++i)
131 Vmath::Vmul(npoints, &alloc[i*npoints], 1, inarray[1].
get(), 1,
132 m_fields[i+2]->UpdatePhys().
get(), 1);
134 m_fields[i+2]->UpdatePhys().
get(), 1);
144 WeakAdv[1] = WeakAdv[0]+ncoeffs;
156 dIdx2.get(), 1, inarray[0].get(), 1,
161 m_fields[0]->IProductWRTBase(dIdx1, tmp2);
165 Vmath::Vsub(npoints, WeakAdv[0], 1, tmp2, 1, WeakAdv[0], 1);
169 for(i = 0; i < 2; ++i)
171 m_fields[i]->MultiplyByElmtInvMass(WeakAdv[i], WeakAdv[i]);
172 m_fields[i]->BwdTrans(WeakAdv[i],outarray[i]);
188 int nvariables = inarray.num_elements();
198 for(i = 0; i < nvariables; ++i)
205 ASSERTL0(
false,
"Unknown projection scheme");
216 for(
int j = 0; j < flux.num_elements(); ++j)
237 for(i = 0; i < nvel; ++i)
243 for(i = 0; i < numflux.num_elements(); ++i)
245 m_fields[i]->GetFwdBwdTracePhys(physfield[i],Fwd,Bwd);
247 m_fields[i]->GetTrace()->Upwind(Vn,Fwd,Bwd,numflux[i]);
249 Vmath::Vmul(nTraceNumPoints,numflux[i],1,Vn,1,numflux[i],1);
255 UnsteadySystem::v_GenerateSummary(s);
Array< OneD, Array< OneD, NekDouble > > m_velocity
#define ASSERTL0(condition, msg)
static boost::shared_ptr< DataType > AllocateSharedPtr()
Allocate a shared pointer from the memory pool.
void DoOdeRhs(const Array< OneD, const Array< OneD, NekDouble > > &inarray, Array< OneD, Array< OneD, NekDouble > > &outarray, const NekDouble time)
LibUtilities::TimeIntegrationSchemeOperators m_ode
The time integration scheme operators to use.
std::vector< std::pair< std::string, std::string > > SummaryList
virtual void v_NumericalFlux(Array< OneD, Array< OneD, NekDouble > > &physfield, Array< OneD, Array< OneD, NekDouble > > &numflux)
virtual void v_InitObject()
Init object for UnsteadySystem class.
void Vvtvp(int n, const T *w, const int incw, const T *x, const int incx, const T *y, const int incy, T *z, const int incz)
vvtvp (vector times vector plus vector): z = w*x + y
enum MultiRegions::ProjectionType m_projectionType
Type of projection; e.g continuous or discontinuous.
static EquationSystemSharedPtr create(const LibUtilities::SessionReaderSharedPtr &pSession)
Creates an instance of this class.
boost::shared_ptr< ContField2D > ContField2DSharedPtr
std::map< ConstFactorType, NekDouble > ConstFactorMap
boost::shared_ptr< SessionReader > SessionReaderSharedPtr
virtual void v_GetFluxVector(const int i, Array< OneD, Array< OneD, NekDouble > > &physfield, Array< OneD, Array< OneD, NekDouble > > &flux)
Array< OneD, Array< OneD, NekDouble > > m_traceNormals
Array holding trace normals for DG simulations in the forwards direction.
virtual void v_GenerateSummary(SolverUtils::SummaryList &s)
Print a summary of time stepping parameters.
void DefineProjection(FuncPointerT func, ObjectPointerT obj)
void Smul(int n, const T alpha, const T *x, const int incx, T *y, const int incy)
Scalar multiply y = alpha*y.
bool m_explicitAdvection
Indicates if explicit or implicit treatment of advection is used.
virtual ~ImageWarpingSystem()
void DefineOdeRhs(FuncPointerT func, ObjectPointerT obj)
Base class for unsteady solvers.
static std::string className
Name of class.
int m_spacedim
Spatial dimension (>= expansion dim).
void Neg(int n, T *x, const int incx)
Negate x = -x.
EquationSystemFactory & GetEquationSystemFactory()
void DoOdeProjection(const Array< OneD, const Array< OneD, NekDouble > > &inarray, Array< OneD, Array< OneD, NekDouble > > &outarray, const NekDouble time)
SOLVER_UTILS_EXPORT void SetBoundaryConditions(NekDouble time)
Evaluates the boundary conditions at the given time.
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.
SOLVER_UTILS_EXPORT int GetNpoints()
void Vvtvvtp(int n, const T *v, int incv, const T *w, int incw, const T *x, int incx, const T *y, int incy, T *z, int incz)
vvtvvtp (vector times vector plus vector times vector):
Array< OneD, MultiRegions::ExpListSharedPtr > m_fields
Array holding all dependent variables.
LibUtilities::SessionReaderSharedPtr m_session
The session reader.
SOLVER_UTILS_EXPORT int GetTraceNpoints()
SpatialDomains::MeshGraphSharedPtr m_graph
Pointer to graph defining mesh.
ImageWarpingSystem(const LibUtilities::SessionReaderSharedPtr &pSession)
SOLVER_UTILS_EXPORT void WeakDGAdvection(const Array< OneD, Array< OneD, NekDouble > > &InField, Array< OneD, Array< OneD, NekDouble > > &OutField, bool NumericalFluxIncludesNormal=true, bool InFieldIsInPhysSpace=false, int nvariables=0)
Calculate the weak discontinuous Galerkin advection.
void Vcopy(int n, const T *x, const int incx, T *y, const int incy)
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.
static FlagList NullFlagList
An empty flag list.
std::vector< int > m_intVariables
tKey RegisterCreatorFunction(tKey idKey, CreatorFunction classCreator, tDescription pDesc="")
Register a class with the factory.