46 UnsteadyDiffusion::UnsteadyDiffusion(
71 int npoints =
m_fields[0]->GetNpoints();
98 m_session->LoadSolverInfo(
"DiffusionType", diffName,
"LDG");
100 CreateInstance(diffName, diffName);
113 ASSERTL0(
false,
"Explicit Galerkin diffusion not set up.");
164 int nVariables = inarray.num_elements();
186 int nvariables = inarray.num_elements();
196 for(i = 0; i < nvariables; ++i)
207 for(i = 0; i < nvariables; ++i)
209 m_fields[i]->FwdTrans(inarray[i], coeffs);
210 m_fields[i]->BwdTrans_IterPerExp(coeffs, outarray[i]);
216 ASSERTL0(
false,
"Unknown projection scheme");
233 int nvariables = inarray.num_elements();
234 int npoints =
m_fields[0]->GetNpoints();
248 for (
int i = 0; i < nvariables; ++i)
269 outarray[i] =
m_fields[i]->GetPhys();
283 for(
int k = 0; k < flux.num_elements(); ++k)
NekDouble m_sVVCutoffRatio
#define ASSERTL0(condition, msg)
void GetFluxVector(const int i, const int j, const Array< OneD, Array< OneD, NekDouble > > &physfield, Array< OneD, Array< OneD, NekDouble > > &derivatives, Array< OneD, Array< OneD, NekDouble > > &flux)
Return the flux vector for the unsteady diffusion problem.
bool m_homoInitialFwd
Flag to determine if simulation should start in homogeneous forward transformed state.
bool m_explicitDiffusion
Indicates if explicit or implicit treatment of diffusion is used.
void DefineImplicitSolve(FuncPointerT func, ObjectPointerT obj)
LibUtilities::TimeIntegrationSchemeOperators m_ode
The time integration scheme operators to use.
std::vector< std::pair< std::string, std::string > > SummaryList
DiffusionFactory & GetDiffusionFactory()
enum MultiRegions::ProjectionType m_projectionType
Type of projection; e.g continuous or discontinuous.
std::map< ConstFactorType, NekDouble > ConstFactorMap
virtual void DoImplicitSolve(const Array< OneD, const Array< OneD, NekDouble > > &inarray, Array< OneD, Array< OneD, NekDouble > > &outarray, NekDouble time, NekDouble lambda)
Implicit solution of the unsteady diffusion problem.
boost::shared_ptr< SessionReader > SessionReaderSharedPtr
void DoOdeProjection(const Array< OneD, const Array< OneD, NekDouble > > &inarray, Array< OneD, Array< OneD, NekDouble > > &outarray, const NekDouble time)
Compute the projection for the unsteady diffusion problem.
void DefineProjection(FuncPointerT func, ObjectPointerT obj)
virtual SOLVER_UTILS_EXPORT void v_GenerateSummary(SummaryList &s)
Print a summary of time stepping parameters.
virtual void v_GenerateSummary(SummaryList &s)
Print a summary of time stepping parameters.
void Smul(int n, const T alpha, const T *x, const int incx, T *y, const int incy)
Scalar multiply y = alpha*y.
void DefineOdeRhs(FuncPointerT func, ObjectPointerT obj)
Base class for unsteady solvers.
void AddSummaryItem(SummaryList &l, const std::string &name, const std::string &value)
Adds a summary item to the summary info list.
virtual ~UnsteadyDiffusion()
Destructor.
virtual SOLVER_UTILS_EXPORT void v_InitObject()
Init object for UnsteadySystem class.
void DoOdeRhs(const Array< OneD, const Array< OneD, NekDouble > > &inarray, Array< OneD, Array< OneD, NekDouble > > &outarray, const NekDouble time)
EquationSystemFactory & GetEquationSystemFactory()
SOLVER_UTILS_EXPORT void SetBoundaryConditions(NekDouble time)
Evaluates the boundary conditions at the given time.
SOLVER_UTILS_EXPORT int GetNpoints()
Array< OneD, MultiRegions::ExpListSharedPtr > m_fields
Array holding all dependent variables.
LibUtilities::SessionReaderSharedPtr m_session
The session reader.
SOLVER_UTILS_EXPORT int GetNcoeffs()
SolverUtils::DiffusionSharedPtr m_diffusion
void Zero(int n, T *x, const int incx)
Zero vector.
void Vcopy(int n, const T *x, const int incx, T *y, const int incy)
virtual void v_InitObject()
Initialisation object for the unsteady diffusion problem.
StdRegions::VarCoeffMap m_varcoeff
static FlagList NullFlagList
An empty flag list.
tKey RegisterCreatorFunction(tKey idKey, CreatorFunction classCreator, tDescription pDesc="")
Register a class with the factory.