Nektar++
SubSteppingExtrapolate.cpp
Go to the documentation of this file.
1///////////////////////////////////////////////////////////////////////////////
2//
3// File: SubSteppingExtrapolate.cpp
4//
5// For more information, please see: http://www.nektar.info
6//
7// The MIT License
8//
9// Copyright (c) 2006 Division of Applied Mathematics, Brown University (USA),
10// Department of Aeronautics, Imperial College London (UK), and Scientific
11// Computing and Imaging Institute, University of Utah (USA).
12//
13// Permission is hereby granted, free of charge, to any person obtaining a
14// copy of this software and associated documentation files (the "Software"),
15// to deal in the Software without restriction, including without limitation
16// the rights to use, copy, modify, merge, publish, distribute, sublicense,
17// and/or sell copies of the Software, and to permit persons to whom the
18// Software is furnished to do so, subject to the following conditions:
19//
20// The above copyright notice and this permission notice shall be included
21// in all copies or substantial portions of the Software.
22//
23// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
24// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
25// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
26// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
27// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
28// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
29// DEALINGS IN THE SOFTWARE.
30//
31// Description: Abstract base class for SubSteppingExtrapolate.
32//
33///////////////////////////////////////////////////////////////////////////////
34
37
38namespace Nektar
39{
40using namespace LibUtilities;
41
42/**
43 * Registers the class with the Factory.
44 */
47 "SubStepping", SubSteppingExtrapolate::create, "SubStepping");
48
53 const SolverUtils::AdvectionSharedPtr advObject)
54 : Extrapolate(pSession, pFields, pPressure, pVel, advObject)
55{
56 m_session->LoadParameter("IO_InfoSteps", m_infosteps, 0);
57 m_session->LoadParameter("SubStepCFL", m_cflSafetyFactor, 0.5);
58 m_session->LoadParameter("MinSubSteps", m_minsubsteps, 1);
59 m_session->LoadParameter("MaxSubSteps", m_maxsubsteps, 100);
60
61 size_t dim = m_fields[0]->GetCoordim(0);
63
64 size_t nTracePts = m_fields[0]->GetTrace()->GetNpoints();
65 for (size_t i = 0; i < dim; ++i)
66 {
68 }
69 m_fields[0]->GetTrace()->GetNormals(m_traceNormals);
70}
71
73{
74}
75
77 [[maybe_unused]] const Array<OneD, const Array<OneD, NekDouble>> &fields,
78 [[maybe_unused]] const Array<OneD, const Array<OneD, NekDouble>> &N,
79 [[maybe_unused]] NekDouble kinvis)
80{
81 ASSERTL0(false, "This method should not be called by Substepping routine");
82}
83
85 const LibUtilities::TimeIntegrationSchemeSharedPtr &IntegrationScheme)
86{
87 m_intScheme = IntegrationScheme;
88
89 size_t order = IntegrationScheme->GetOrder();
90
91 // Set to 1 for first step and it will then be increased in
92 // time advance routines
93 if ((IntegrationScheme->GetName() == "Euler" &&
94 IntegrationScheme->GetVariant() == "Backward") ||
95
96 (IntegrationScheme->GetName() == "BDFImplicit" &&
97 (order == 1 || order == 2)))
98 {
99 // Note RK first order SSP is just Forward Euler.
100 std::string vSubStepIntScheme = "RungeKutta";
101 std::string vSubStepIntSchemeVariant = "SSP";
102 int vSubStepIntSchemeOrder = order;
103
104 if (m_session->DefinesSolverInfo("SubStepIntScheme"))
105 {
106 vSubStepIntScheme = m_session->GetSolverInfo("SubStepIntScheme");
107 vSubStepIntSchemeVariant = "";
108 vSubStepIntSchemeOrder = order;
109 }
110
113 vSubStepIntScheme, vSubStepIntSchemeVariant,
114 vSubStepIntSchemeOrder, std::vector<NekDouble>());
115
116 size_t nvel = m_velocity.size();
117 size_t ndim = order + 1;
118
119 // Fields for linear/quadratic interpolation
121 int ntotpts = m_fields[0]->GetTotPoints();
122 m_previousVelFields[0] = Array<OneD, NekDouble>(ndim * nvel * ntotpts);
123
124 for (size_t i = 1; i < ndim * nvel; ++i)
125 {
126 m_previousVelFields[i] = m_previousVelFields[i - 1] + ntotpts;
127 }
128 }
129 else
130 {
131 ASSERTL0(0, "Integration method not suitable: Options include "
132 "BackwardEuler or BDFImplicitOrder{1,2}");
133 }
134
135 m_intSteps = IntegrationScheme->GetNumIntegrationPhases();
136
137 // set explicit time-integration class operators
142}
143
144/**
145 * Explicit Advection terms used by SubStepAdvance time integration
146 */
148 const Array<OneD, const Array<OneD, NekDouble>> &inarray,
149 Array<OneD, Array<OneD, NekDouble>> &outarray, const NekDouble time)
150{
151 size_t i;
152 size_t nVariables = inarray.size();
153 size_t nQuadraturePts = inarray[0].size();
154
155 /// Get the number of coefficients
156 size_t ncoeffs = m_fields[0]->GetNcoeffs();
157
158 /// Define an auxiliary variable to compute the RHS
159 Array<OneD, Array<OneD, NekDouble>> WeakAdv(nVariables);
160 WeakAdv[0] = Array<OneD, NekDouble>(ncoeffs * nVariables);
161 for (i = 1; i < nVariables; ++i)
162 {
163 WeakAdv[i] = WeakAdv[i - 1] + ncoeffs;
164 }
165
167
168 Velfields[0] = Array<OneD, NekDouble>(nQuadraturePts * m_velocity.size());
169
170 for (i = 1; i < m_velocity.size(); ++i)
171 {
172 Velfields[i] = Velfields[i - 1] + nQuadraturePts;
173 }
174
175 SubStepExtrapolateField(fmod(time, m_timestep), Velfields);
176
177 for (auto &x : m_forcing)
178 {
179 x->PreApply(m_fields, Velfields, Velfields, time);
180 }
181 m_advObject->Advect(m_velocity.size(), m_fields, Velfields, inarray,
182 outarray, time);
183 for (auto &x : m_forcing)
184 {
185 x->Apply(m_fields, outarray, outarray, time);
186 }
187
188 for (i = 0; i < nVariables; ++i)
189 {
190 m_fields[i]->IProductWRTBase(outarray[i], WeakAdv[i]);
191 // negation requried due to sign of DoAdvection term to be consistent
192 Vmath::Neg(ncoeffs, WeakAdv[i], 1);
193 }
194
195 AddAdvectionPenaltyFlux(Velfields, inarray, WeakAdv);
196
197 /// Operations to compute the RHS
198 for (i = 0; i < nVariables; ++i)
199 {
200 // Negate the RHS
201 Vmath::Neg(ncoeffs, WeakAdv[i], 1);
202
203 /// Multiply the flux by the inverse of the mass matrix
204 m_fields[i]->MultiplyByElmtInvMass(WeakAdv[i], WeakAdv[i]);
205
206 /// Store in outarray the physical values of the RHS
207 m_fields[i]->BwdTrans(WeakAdv[i], outarray[i]);
208 }
209}
210
211/**
212 * Projection used by SubStepAdvance time integration
213 */
215 const Array<OneD, const Array<OneD, NekDouble>> &inarray,
217 [[maybe_unused]] const NekDouble time)
218{
219 ASSERTL1(inarray.size() == outarray.size(),
220 "Inarray and outarray of different sizes ");
221
222 for (size_t i = 0; i < inarray.size(); ++i)
223 {
224 Vmath::Vcopy(inarray[i].size(), inarray[i], 1, outarray[i], 1);
225 }
226}
227
228/**
229 *
230 */
232 const Array<OneD, const Array<OneD, NekDouble>> &inarray,
233 [[maybe_unused]] const NekDouble Aii_Dt, NekDouble kinvis)
234{
235 // int nConvectiveFields =m_fields.size()-1;
237
239
240 // Calculate viscous BCs at current level and
241 // put in m_pressureHBCs[0]
242 CalcNeumannPressureBCs(m_previousVelFields, nullvelfields, kinvis);
243
244 // Extrapolate to m_pressureHBCs to n+1
246
247 // Add (phi,Du/Dt) term to m_presureHBC
248 AddDuDt();
249
250 // Copy m_pressureHBCs to m_PbndExp
252
253 // Evaluate High order outflow conditiosn if required.
254 CalcOutflowBCs(inarray, kinvis);
255}
256
257/**
258 * At the start, the newest value is stored in array[nlevels-1]
259 * and the previous values in the first positions
260 * At the end, the acceleration from BDF is stored in array[nlevels-1]
261 * and the storage has been updated to included the new value
262 */
265{
266 int nlevels = array.size();
267 int nPts = array[0].size();
268
269 if (nPts)
270 {
271 // Update array
272 RollOver(array);
273
274 // Calculate acceleration using Backward Differentiation Formula
275 Array<OneD, NekDouble> accelerationTerm(nPts, 0.0);
276
277 int acc_order = std::min(m_pressureCalls, m_intSteps);
278 Vmath::Smul(nPts, StifflyStable_Gamma0_Coeffs[acc_order - 1], array[0],
279 1, accelerationTerm, 1);
280
281 for (int i = 0; i < acc_order; i++)
282 {
284 nPts, -1 * StifflyStable_Alpha_Coeffs[acc_order - 1][i],
285 array[i + 1], 1, accelerationTerm, 1, accelerationTerm, 1);
286 }
287 array[nlevels - 1] = accelerationTerm;
288 }
289}
290
291/**
292 *
293 */
295{
296 size_t i, n;
297 size_t nvel = m_velocity.size();
298 size_t npts = m_fields[0]->GetTotPoints();
299
300 // rotate fields
301 size_t nblocks = m_previousVelFields.size() / nvel;
303
304 // rotate storage space
305 for (n = 0; n < nvel; ++n)
306 {
307 save = m_previousVelFields[(nblocks - 1) * nvel + n];
308
309 for (i = nblocks - 1; i > 0; --i)
310 {
311 m_previousVelFields[i * nvel + n] =
312 m_previousVelFields[(i - 1) * nvel + n];
313 }
314
315 m_previousVelFields[n] = save;
316 }
317
318 // Put previous field
319 for (i = 0; i < nvel; ++i)
320 {
321 m_fields[m_velocity[i]]->BwdTrans(
322 m_fields[m_velocity[i]]->GetCoeffs(),
323 m_fields[m_velocity[i]]->UpdatePhys());
324 Vmath::Vcopy(npts, m_fields[m_velocity[i]]->GetPhys(), 1,
325 m_previousVelFields[i], 1);
326 }
327
328 if (nstep == 0) // initialise all levels with first field
329 {
330 for (n = 0; n < nvel; ++n)
331 {
332 for (i = 1; i < nblocks; ++i)
333 {
334 Vmath::Vcopy(npts, m_fields[m_velocity[n]]->GetPhys(), 1,
335 m_previousVelFields[i * nvel + n], 1);
336 }
337 }
338 }
339}
340
341/**
342 *
343 */
345{
346 int n;
347 int nsubsteps;
348
349 NekDouble dt;
350
352
353 static int ncalls = 1;
354 size_t nint = std::min(ncalls++, m_intSteps);
355
356 // this needs to change
357 m_comm = m_fields[0]->GetComm()->GetRowComm();
358
359 // Get the proper time step with CFL control
360 dt = GetSubstepTimeStep();
361
362 nsubsteps = (m_timestep > dt) ? ((int)(m_timestep / dt) + 1) : 1;
363 nsubsteps = std::max(m_minsubsteps, nsubsteps);
364
365 ASSERTL0(nsubsteps < m_maxsubsteps,
366 "Number of substeps has exceeded maximum");
367
368 dt = m_timestep / nsubsteps;
369
370 if (m_infosteps && !((nstep + 1) % m_infosteps) && m_comm->GetRank() == 0)
371 {
372 std::cout << "Sub-integrating using " << nsubsteps
373 << " steps over Dt = " << m_timestep
374 << " (SubStep CFL=" << m_cflSafetyFactor << ")" << std::endl;
375 }
376
377 const TripleArray &solutionVector = m_intScheme->GetSolutionVector();
378
379 for (size_t m = 0; m < nint; ++m)
380 {
381 // We need to update the fields held by the m_intScheme
382 fields = solutionVector[m];
383
384 // Initialise NS solver which is set up to use a GLM method
385 // with calls to EvaluateAdvection_SetPressureBCs and
386 // SolveUnsteadyStokesSystem
387 m_subStepIntegrationScheme->InitializeScheme(dt, fields, time,
389
390 for (n = 0; n < nsubsteps; ++n)
391 {
392 fields = m_subStepIntegrationScheme->TimeIntegrate(n, dt);
393 }
394
395 // set up HBC m_acceleration field for Pressure BCs
397
398 // Reset time integrated solution in m_intScheme
399 m_intScheme->SetSolutionVector(m, fields);
400 }
401}
402
403/**
404 *
405 */
407{
408 size_t n_element = m_fields[0]->GetExpSize();
409
410 const Array<OneD, int> ExpOrder = m_fields[0]->EvalBasisNumModesMaxPerExp();
411
412 const NekDouble cLambda = 0.2; // Spencer book pag. 317
413
414 Array<OneD, NekDouble> tstep(n_element, 0.0);
415 Array<OneD, NekDouble> stdVelocity(n_element, 0.0);
417
418 for (size_t i = 0; i < m_velocity.size(); ++i)
419 {
420 velfields[i] = m_fields[m_velocity[i]]->UpdatePhys();
421 }
422 stdVelocity = GetMaxStdVelocity(velfields);
423
424 for (size_t el = 0; el < n_element; ++el)
425 {
426 tstep[el] =
427 m_cflSafetyFactor / (stdVelocity[el] * cLambda *
428 (ExpOrder[el] - 1) * (ExpOrder[el] - 1));
429 }
430
431 NekDouble TimeStep = Vmath::Vmin(n_element, tstep, 1);
432 m_comm->AllReduce(TimeStep, LibUtilities::ReduceMin);
433
434 return TimeStep;
435}
436
438 const Array<OneD, const Array<OneD, NekDouble>> &velfield,
439 const Array<OneD, const Array<OneD, NekDouble>> &physfield,
441{
442 ASSERTL1(physfield.size() == Outarray.size(),
443 "Physfield and outarray are of different dimensions");
444
445 size_t i;
446
447 /// Number of trace points
448 size_t nTracePts = m_fields[0]->GetTrace()->GetNpoints();
449
450 /// Number of spatial dimensions
451 size_t nDimensions = m_bnd_dim;
452
453 /// Forward state array
454 Array<OneD, NekDouble> Fwd(3 * nTracePts);
455
456 /// Backward state array
457 Array<OneD, NekDouble> Bwd = Fwd + nTracePts;
458
459 /// upwind numerical flux state array
460 Array<OneD, NekDouble> numflux = Bwd + nTracePts;
461
462 /// Normal velocity array
463 Array<OneD, NekDouble> Vn(nTracePts, 0.0);
464
465 // Extract velocity field along the trace space and multiply by trace
466 // normals
467 for (i = 0; i < nDimensions; ++i)
468 {
469 m_fields[0]->ExtractTracePhys(velfield[i], Fwd);
470 Vmath::Vvtvp(nTracePts, m_traceNormals[i], 1, Fwd, 1, Vn, 1, Vn, 1);
471 }
472
473 for (i = 0; i < physfield.size(); ++i)
474 {
475 /// Extract forwards/backwards trace spaces
476 /// Note it is important to use the zeroth field but with the
477 /// specialised method to use boudnary conditions from other
478 /// fields since trace spaces may not be the same if there are
479 /// mixed boundary conditions
480 std::dynamic_pointer_cast<MultiRegions::DisContField>(m_fields[0])
481 ->GetFwdBwdTracePhys(physfield[i], Fwd, Bwd,
482 m_fields[i]->GetBndConditions(),
483 m_fields[i]->GetBndCondExpansions());
484
485 /// Upwind between elements
486 m_fields[0]->GetTrace()->Upwind(Vn, Fwd, Bwd, numflux);
487
488 /// Construct difference between numflux and Fwd,Bwd
489 Vmath::Vsub(nTracePts, numflux, 1, Fwd, 1, Fwd, 1);
490 Vmath::Vsub(nTracePts, numflux, 1, Bwd, 1, Bwd, 1);
491
492 /// Calculate the numerical fluxes multipling Fwd, Bwd and
493 /// numflux by the normal advection velocity
494 Vmath::Vmul(nTracePts, Fwd, 1, Vn, 1, Fwd, 1);
495 Vmath::Vmul(nTracePts, Bwd, 1, Vn, 1, Bwd, 1);
496
497 m_fields[0]->AddFwdBwdTraceIntegral(Fwd, Bwd, Outarray[i]);
498 }
499}
500
501/**
502 * Extrapolate field using equally time spaced field un,un-1,un-2, (at
503 * dt intervals) to time n+t at order Ord
504 */
507{
508 size_t npts = m_fields[0]->GetTotPoints();
509 size_t nvel = m_velocity.size();
510 size_t i, j;
512
513 size_t ord = m_intSteps;
514
515 // calculate Lagrange interpolants
516 Vmath::Fill(4, 1.0, l, 1);
517
518 for (i = 0; i <= ord; ++i)
519 {
520 for (j = 0; j <= ord; ++j)
521 {
522 if (i != j)
523 {
524 l[i] *= (j * m_timestep + toff);
525 l[i] /= (j * m_timestep - i * m_timestep);
526 }
527 }
528 }
529
530 for (i = 0; i < nvel; ++i)
531 {
532 Vmath::Smul(npts, l[0], m_previousVelFields[i], 1, ExtVel[i], 1);
533
534 for (j = 1; j <= ord; ++j)
535 {
536 Blas::Daxpy(npts, l[j], m_previousVelFields[j * nvel + i], 1,
537 ExtVel[i], 1);
538 }
539 }
540}
541
542/**
543 *
544 */
546 int HBCdata, NekDouble kinvis, Array<OneD, NekDouble> &Q,
547 [[maybe_unused]] Array<OneD, const NekDouble> &Advection)
548{
549 Vmath::Smul(HBCdata, -kinvis, Q, 1, Q, 1);
550}
551
553{
554 return m_subStepIntegrationScheme->GetName();
555}
556
557} // namespace Nektar
#define ASSERTL0(condition, msg)
Definition: ErrorUtil.hpp:208
#define ASSERTL1(condition, msg)
Assert Level 1 – Debugging which is used whether in FULLDEBUG or DEBUG compilation mode....
Definition: ErrorUtil.hpp:242
Array< OneD, Array< OneD, NekDouble > > m_pressureHBCs
Storage for current and previous levels of high order pressure boundary conditions.
Definition: Extrapolate.h:247
int m_bnd_dim
bounday dimensionality
Definition: Extrapolate.h:220
void CopyPressureHBCsToPbndExp(void)
Array< OneD, MultiRegions::ExpListSharedPtr > m_fields
Velocity fields.
Definition: Extrapolate.h:201
Array< OneD, Array< OneD, NekDouble > > m_iprodnormvel
Storage for current and previous levels of the inner product of normal velocity.
Definition: Extrapolate.h:251
Array< OneD, NekDouble > GetMaxStdVelocity(const Array< OneD, Array< OneD, NekDouble > > inarray)
int m_intSteps
Maximum points used in pressure BC evaluation.
Definition: Extrapolate.h:241
void CalcNeumannPressureBCs(const Array< OneD, const Array< OneD, NekDouble > > &fields, const Array< OneD, const Array< OneD, NekDouble > > &N, NekDouble kinvis)
Definition: Extrapolate.h:172
void IProductNormVelocityOnHBC(const Array< OneD, const Array< OneD, NekDouble > > &Vel, Array< OneD, NekDouble > &IprodVn)
NekDouble m_timestep
Definition: Extrapolate.h:243
void ExtrapolateArray(Array< OneD, Array< OneD, NekDouble > > &array)
std::vector< SolverUtils::ForcingSharedPtr > m_forcing
Definition: Extrapolate.h:212
SolverUtils::AdvectionSharedPtr m_advObject
Definition: Extrapolate.h:210
Array< OneD, int > m_velocity
int which identifies which components of m_fields contains the velocity (u,v,w);
Definition: Extrapolate.h:208
static NekDouble StifflyStable_Alpha_Coeffs[3][3]
Definition: Extrapolate.h:257
void RollOver(Array< OneD, Array< OneD, NekDouble > > &input)
Array< OneD, Array< OneD, NekDouble > > m_traceNormals
Definition: Extrapolate.h:253
int m_pressureCalls
number of times the high-order pressure BCs have been called
Definition: Extrapolate.h:232
LibUtilities::SessionReaderSharedPtr m_session
Definition: Extrapolate.h:193
void CalcOutflowBCs(const Array< OneD, const Array< OneD, NekDouble > > &fields, NekDouble kinvis)
LibUtilities::CommSharedPtr m_comm
Definition: Extrapolate.h:195
static NekDouble StifflyStable_Gamma0_Coeffs[3]
Definition: Extrapolate.h:258
tKey RegisterCreatorFunction(tKey idKey, CreatorFunction classCreator, std::string pDesc="")
Register a class with the factory.
Definition: NekFactory.hpp:197
tBaseSharedPtr CreateInstance(tKey idKey, tParam... args)
Create an instance of the class referred to by idKey.
Definition: NekFactory.hpp:143
void DefineProjection(FuncPointerT func, ObjectPointerT obj)
void DefineOdeRhs(FuncPointerT func, ObjectPointerT obj)
An abstract base class encapsulating the concept of advection of a vector field.
Definition: Advection.h:81
LibUtilities::TimeIntegrationSchemeOperators m_subStepIntegrationOps
void v_MountHOPBCs(int HBCdata, NekDouble kinvis, Array< OneD, NekDouble > &Q, Array< OneD, const NekDouble > &Advection) override
LibUtilities::TimeIntegrationSchemeSharedPtr m_subStepIntegrationScheme
void SubStepExtrapolateField(NekDouble toff, Array< OneD, Array< OneD, NekDouble > > &ExtVel)
static std::string className
Name of class.
void v_SubStepSaveFields(int nstep) override
static ExtrapolateSharedPtr create(const LibUtilities::SessionReaderSharedPtr &pSession, Array< OneD, MultiRegions::ExpListSharedPtr > &pFields, MultiRegions::ExpListSharedPtr &pPressure, const Array< OneD, int > &pVel, const SolverUtils::AdvectionSharedPtr &advObject)
Creates an instance of this class.
void SubStepAdvection(const Array< OneD, const Array< OneD, NekDouble > > &inarray, Array< OneD, Array< OneD, NekDouble > > &outarray, const NekDouble time)
void SubStepProjection(const Array< OneD, const Array< OneD, NekDouble > > &inarray, Array< OneD, Array< OneD, NekDouble > > &outarray, const NekDouble time)
LibUtilities::TimeIntegrationSchemeSharedPtr m_intScheme
void v_SubSteppingTimeIntegration(const LibUtilities::TimeIntegrationSchemeSharedPtr &IntegrationScheme) override
void v_SubStepAdvance(int nstep, NekDouble time) override
std::string v_GetSubStepName(void) override
void v_AccelerationBDF(Array< OneD, Array< OneD, NekDouble > > &array) override
void AddAdvectionPenaltyFlux(const Array< OneD, const Array< OneD, NekDouble > > &velfield, const Array< OneD, const Array< OneD, NekDouble > > &physfield, Array< OneD, Array< OneD, NekDouble > > &outarray)
void v_SubStepSetPressureBCs(const Array< OneD, const Array< OneD, NekDouble > > &inarray, NekDouble Aii_Dt, NekDouble kinvis) override
SubSteppingExtrapolate(const LibUtilities::SessionReaderSharedPtr pSession, Array< OneD, MultiRegions::ExpListSharedPtr > pFields, MultiRegions::ExpListSharedPtr pPressure, const Array< OneD, int > pVel, const SolverUtils::AdvectionSharedPtr advObject)
Array< OneD, Array< OneD, NekDouble > > m_previousVelFields
void v_EvaluatePressureBCs(const Array< OneD, const Array< OneD, NekDouble > > &fields, const Array< OneD, const Array< OneD, NekDouble > > &N, NekDouble kinvis) override
static void Daxpy(const int &n, const double &alpha, const double *x, const int &incx, const double *y, const int &incy)
BLAS level 1: y = alpha x plus y.
Definition: Blas.hpp:135
TimeIntegrationSchemeFactory & GetTimeIntegrationSchemeFactory()
std::shared_ptr< SessionReader > SessionReaderSharedPtr
std::shared_ptr< TimeIntegrationScheme > TimeIntegrationSchemeSharedPtr
std::shared_ptr< ExpList > ExpListSharedPtr
Shared pointer to an ExpList object.
std::shared_ptr< Advection > AdvectionSharedPtr
A shared pointer to an Advection object.
Definition: Advection.h:54
ExtrapolateFactory & GetExtrapolateFactory()
Definition: Extrapolate.cpp:48
double NekDouble
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.
Definition: Vmath.hpp:72
void Svtvp(int n, const T alpha, const T *x, const int incx, const T *y, const int incy, T *z, const int incz)
Svtvp (scalar times vector plus vector): z = alpha*x + y.
Definition: Vmath.hpp:396
void Neg(int n, T *x, const int incx)
Negate x = -x.
Definition: Vmath.hpp:292
T Vmin(int n, const T *x, const int incx)
Return the minimum element in x - called vmin to avoid conflict with min.
Definition: Vmath.hpp:725
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
Definition: Vmath.hpp:366
void Smul(int n, const T alpha, const T *x, const int incx, T *y, const int incy)
Scalar multiply y = alpha*x.
Definition: Vmath.hpp:100
void Fill(int n, const T alpha, T *x, const int incx)
Fill a vector with a constant value.
Definition: Vmath.hpp:54
void Vcopy(int n, const T *x, const int incx, T *y, const int incy)
Definition: Vmath.hpp:825
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.
Definition: Vmath.hpp:220