35 #include <boost/core/ignore_unused.hpp>
50 namespace LocalRegions
53 StdExpansion(),
Expansion(pGeom), StdExpansion2D()
67 "Routine only set up for two-dimensions");
88 if (edgeExp->GetRightAdjacentElementExp())
90 if (edgeExp->GetRightAdjacentElementExp()->GetGeom2D()
91 ->GetGlobalID() ==
GetGeom2D()->GetGlobalID())
103 int nquad_e = min(EdgeExp->GetNumPoints(0),
104 int(normals[0].num_elements()));
106 int nEdgePts = EdgeExp->GetTotPoints();
108 Vmath::Vmul (nquad_e, normals[0], 1, Fx, 1, edgePhys, 1);
109 Vmath::Vvtvp(nquad_e, normals[1], 1, Fy, 1, edgePhys, 1,
118 else if (locExp->GetRightAdjacentElementEdge() != -1)
120 if (locExp->GetRightAdjacentElementExp()->GetGeom2D()->GetGlobalID()
154 if (edgeExp->GetRightAdjacentElementExp())
156 if (edgeExp->GetRightAdjacentElementExp()->GetGeom2D()
157 ->GetGlobalID() ==
GetGeom2D()->GetGlobalID())
170 StdExpansion::GetIndexMap(ikey);
173 int order_e = map->num_elements();
175 int n_coeffs = EdgeExp->GetNcoeffs();
178 if(n_coeffs!=order_e)
180 EdgeExp->FwdTrans(Fn, edgeCoeffs);
190 LibUtilities::BasisKey bkey_ortho(btype,EdgeExp->GetBasis(0)->GetNumModes(),EdgeExp->GetBasis(0)->GetPointsKey());
191 LibUtilities::BasisKey bkey(EdgeExp->GetBasis(0)->GetBasisType(),EdgeExp->GetBasis(0)->GetNumModes(),EdgeExp->GetBasis(0)->GetPointsKey());
195 for(i = order_e; i < n_coeffs; i++)
203 EdgeExp->MassMatrixOp(edgeCoeffs, edgeCoeffs, masskey);
207 EdgeExp->IProductWRTBase(Fn, edgeCoeffs);
218 if(EdgeExp->GetBasis(0)->GetBasisType() !=
222 for(i = 0; i < order_e; ++i)
224 outarray[(*map)[i].index] +=
225 (*map)[i].sign * edgeCoeffs[i];
230 int nCoeffs0, nCoeffs1;
244 nCoeffs1 =
m_base[1]->GetNumModes();
246 for(i = 0; i < order_e; ++i)
248 for(j = 0; j < nCoeffs1; j++)
250 outarray[(*map)[i].index + j*order_e] +=
251 mat_gauss->GetPtr()[j]*
252 (*map)[i].sign*edgeCoeffs[i];
259 nCoeffs0 =
m_base[0]->GetNumModes();
261 for(i = 0; i < order_e; ++i)
263 for(j = 0; j < nCoeffs0; j++)
265 outarray[(*map)[i].index - j] +=
266 mat_gauss->GetPtr()[order_e - 1 -j]*
267 (*map)[i].sign*edgeCoeffs[i];
274 nCoeffs1 =
m_base[1]->GetNumModes();
276 for(i = 0; i < order_e; ++i)
278 for(j = 0; j < nCoeffs1; j++)
280 outarray[(*map)[i].index - j*order_e] +=
281 mat_gauss->GetPtr()[order_e - 1 - j]*
282 (*map)[i].sign*edgeCoeffs[i];
289 nCoeffs0 =
m_base[0]->GetNumModes();
291 for(i = 0; i < order_e; ++i)
293 for(j = 0; j < nCoeffs0; j++)
295 outarray[(*map)[i].index + j] +=
296 mat_gauss->GetPtr()[j]*
297 (*map)[i].sign*edgeCoeffs[i];
303 ASSERTL0(
false,
"edge value (< 3) is out of range");
317 for(i = 0; i < nedges; ++i)
319 EdgeExp[i]->SetCoeffsToOrientation(
GetEorient(i),
321 e_tmp = inout + cnt);
342 for(e = 0; e < nedges; ++e)
344 order_e = EdgeExp[e]->GetNcoeffs();
345 nquad_e = EdgeExp[e]->GetNumPoints(0);
352 for(i = 0; i < order_e; ++i)
354 edgeCoeffs[i] = inarray[i+cnt];
358 EdgeExp[e]->BwdTrans(edgeCoeffs, edgePhys);
412 for(e = 0; e < nedges; ++e)
414 nquad_e = EdgeExp[e]->GetNumPoints(0);
420 EdgeExp[e]->BwdTrans(edgeCoeffs[e], edgePhys);
422 Vmath::Vmul(nquad_e, normals[dir], 1, edgePhys, 1, edgePhys, 1);
445 int order_e = EdgeExp->GetNcoeffs();
446 int nquad_e = EdgeExp->GetNumPoints(0);
456 StdRegions::VarCoeffMap::const_iterator x;
459 if ((x = varcoeffs.find(VarCoeff[0])) != varcoeffs.end())
463 edge, EdgeExp, x->second, work);
464 Vmath::Vmul(nquad_e, work, 1, edgePhys, 1, edgePhys, 1);
467 EdgeExp->IProductWRTBase(edgePhys, coeff);
470 for(i = 0; i < order_e; ++i)
472 outarray[map[i]] +=
sign[i]*coeff[i];
486 ASSERTL0(&inarray[0] != &outarray[0],
487 "Input and output arrays use the same memory");
489 int e, cnt, order_e, nedges =
GetNedges();
494 for(e = 0; e < nedges; ++e)
496 order_e = EdgeExp[e]->GetNcoeffs();
500 Vmath::Vcopy(order_e, tmp = inarray + cnt, 1, edgeCoeffs, 1);
501 EdgeExp[e]->BwdTrans(edgeCoeffs, edgePhys);
503 tau, e, EdgeExp, edgePhys, dirForcing, outarray);
522 int nquad_e = EdgeExp[edge]->GetNumPoints(0);
523 int order_e = EdgeExp[edge]->GetNcoeffs();
558 StdRegions::VarCoeffMap::const_iterator x;
560 if ((x = varcoeffs.find(VarCoeff[0])) != varcoeffs.end())
564 edge, EdgeExp[edge], x->second, work);
565 Vmath::Vmul(nquad_e, work, 1, edgePhys, 1, edgePhys, 1);
571 EdgeExp[edge]->IProductWRTBase(edgePhys, outcoeff);
573 for(i = 0; i < order_e; ++i)
575 outarray[emap[i]] +=
sign[i] * tau * outcoeff[i];
585 for(n = 0; n < coordim; ++n)
603 Vmath::Vmul(nquad_e, ncdotMF_e, 1, edgePhys, 1, inval, 1);
607 Vmath::Vmul(nquad_e, normals[n], 1, edgePhys, 1, inval, 1);
625 EdgeExp[edge]->IProductWRTBase(inval, outcoeff);
628 for(i = 0; i < ncoeffs; ++i)
631 for(j = 0; j < order_e; ++j)
633 tmpcoeff[i] += (*invMass)(i,emap[j]) *
sign[j]
653 Coeffs = Coeffs + Dmat*Tmpcoeff;
657 if(varcoeffs.find(VarCoeff[n]) != varcoeffs.end())
663 Coeffs = Coeffs + Dmat*Tmpcoeff;
668 Coeffs = Coeffs + Dmat*Tmpcoeff;
696 for (
unsigned int i = 0; i < EdgeExp->GetNcoeffs(); ++i)
698 edgetmp[i] = tmp[emap[i]];
702 EdgeExp->BwdTrans(edgetmp, outarray);
723 "HybridDGHelmholtz matrix not set up "
724 "for non boundary-interior expansions");
749 DNekMat LocMat(ncoeffs,ncoeffs);
759 StdRegions::VarCoeffMap::const_iterator x;
761 for(i=0; i < coordim; ++i)
795 Mat = Mat + Dmat*invMass*
Transpose(Dmat);
811 Mat = Mat + DmatL*invMass*
Transpose(DmatR);
816 Mat = Mat + Dmat*invMass*
Transpose(Dmat);
823 Mat = Mat + lambdaval*Mass;
826 for(i = 0; i < nedges; ++i)
830 order_e = EdgeExp->GetNcoeffs();
831 int nq = EdgeExp->GetNumPoints(0);
845 for(j = 0; j < order_e; ++j)
847 for(k = 0; k < order_e; ++k)
849 Mat(emap[j],emap[k]) = Mat(emap[j],emap[k]) + tau*
sign[j]*
sign[k]*
eMass(j,k);
883 for(i = 0; i < nedges; ++i)
891 for(j = 0; j < nbndry; ++j)
908 for(k = 0; k < ncoeffs; ++k)
954 for(i = 0; i < nedges; ++i)
976 ASSERTL0(
false,
"Direction not known");
987 v_GetMF(dir,shapedim,varcoeffs);
1026 for(j = 0; j < nbndry; ++j)
1032 for(k = 0; k < ncoeffs; ++k)
1034 Ulam[k] = lamToU(k,j);
1051 Vmath::Vcopy(ncoeffs,&ulam[0],1,&(Qmat.GetPtr())[0]+j*ncoeffs,1);
1059 int order_e, nquad_e;
1064 StdRegions::VarCoeffMap::const_iterator x;
1106 for(i = 0; i < nedges; ++i)
1112 for(i = 0; i < nbndry; ++i)
1120 for(e = 0; e < nedges; ++e)
1122 order_e = EdgeExp[e]->GetNcoeffs();
1123 nquad_e = EdgeExp[e]->GetNumPoints(0);
1141 for(j = 0; j < order_e; ++j)
1143 edgeCoeffs[j] =
sign[j]*(*LamToQ[0])(emap[j],i);
1146 EdgeExp[e]->BwdTrans(edgeCoeffs, edgePhys);
1158 normals, varcoeffs);
1171 for(j = 0; j < order_e; ++j)
1173 edgeCoeffs[j] =
sign[j]*(*LamToQ[1])(emap[j],i);
1176 EdgeExp[e]->BwdTrans(edgeCoeffs, edgePhys);
1190 normals, varcoeffs);
1207 for(j = 0; j < order_e; ++j)
1209 edgeCoeffs[j] =
sign[j]*(*LamToQ[2])(emap[j],i);
1212 EdgeExp[e]->BwdTrans(edgeCoeffs, edgePhys);
1232 for(j = 0; j < order_e; ++j)
1234 edgeCoeffs[j] =
sign[j]*LamToU(emap[j],i) - lam[cnt+j];
1237 EdgeExp[e]->BwdTrans(edgeCoeffs, edgePhys);
1240 if ((x = varcoeffs.find(VarCoeff[0])) != varcoeffs.end())
1243 Vmath::Vmul(nquad_e,varcoeff_work,1,edgePhys,1,edgePhys,1);
1249 EdgeExp[e]->IProductWRTBase(work, edgeCoeffs);
1251 EdgeExp[e]->SetCoeffsToOrientation(edgeCoeffs, edgedir);
1253 for(j = 0; j < order_e; ++j)
1255 BndMat(cnt+j,i) = edgeCoeffs[j];
1282 &(lmat->GetPtr())[0],1);
1288 ASSERTL0(
false,
"This matrix type cannot be generated from this class");
1326 Out_d = InvMass*Coeffs;
1339 "Not set up for non boundary-interior expansions");
1340 ASSERTL1(inoutmat->GetRows() == inoutmat->GetColumns(),
1341 "Assuming that input matrix was square");
1345 int order_e = edgeExp->GetNcoeffs();
1354 DNekScalMat &edgemat = *edgeExp->GetLocMatrix(mkey);
1368 int rows = inoutmat->GetRows();
1383 for(i = 0; i < order_e; ++i)
1385 for(j = 0; j < nbndry; ++j)
1387 if(map[i] == bmap[j])
1393 ASSERTL1(j != nbndry,
"Did not find number in map");
1403 for(i = 0; i < edge; ++i)
1408 for(i = 0; i < order_e; ++i)
1415 switch(edgeExp->GetBasis(0)->GetBasisType())
1418 reverse( map.get() , map.get()+order_e);
1421 reverse( map.get() , map.get()+order_e);
1425 swap(map[0],map[1]);
1426 for(i = 3; i < order_e; i+=2)
1433 ASSERTL0(
false,
"Edge boundary type not valid for this method");
1439 ASSERTL0(
false,
"Could not identify matrix type from dimension");
1442 for(i = 0; i < order_e; ++i)
1445 for(j = 0; j < order_e; ++j)
1448 (*inoutmat)(id1,id2) += edgemat(i,j)*
sign[i]*
sign[j];
1464 "Not set up for non boundary-interior expansions");
1467 int order_e = edgeExp->GetNcoeffs();
1476 DNekScalMat &edgemat = *edgeExp->GetLocMatrix(mkey);
1482 for (i = 0; i < order_e; ++i)
1484 vEdgeCoeffs[i] = coeffs[map[i]]*
sign[i];
1488 vEdgeCoeffs = edgemat * vEdgeCoeffs;
1490 for (i = 0; i < order_e; ++i)
1492 coeffs[map[i]] = vEdgeCoeffs[i]*
sign[i];
1502 int nVerts, vid1, vid2, vMap1, vMap2;
1509 nVerts, nVerts, 0.0, storage);
1510 DNekMat &VertexMat = (*m_vertexmatrix);
1512 for (vid1 = 0; vid1 < nVerts; ++vid1)
1516 for (vid2 = 0; vid2 < nVerts; ++vid2)
1519 VertexValue = (*r_bnd)(vMap1, vMap2);
1520 VertexMat.SetValue(vid1, vid2, VertexValue);
1524 return m_vertexmatrix;
1539 map<int, int> invmap;
1540 for (j = 0; j < nBndCoeffs; ++j)
1542 invmap[bmap[j]] = j;
1558 for (n = 0; n < nEdgeCoeffs; ++n)
1560 edgemaparray[n] = invmap[maparray[n]];
1563 return edgemaparray;
1573 std::map<int, StdRegions::NormalVector>::const_iterator x;
1576 "Edge normal not computed.");
1607 boost::ignore_unused(nvert);
1609 if (idmap.num_elements() != nq0)
1617 for (
int i = 0; i < nq0; ++i)
1625 for (
int i = 0; i < nq0; ++i)
1632 ASSERTL0(
false,
"Unknown orientation");
1667 int nquad_e = EdgeExp_e->GetNumPoints(0);
1669 int nquad0 =
m_base[0]->GetNumPoints();
1670 int nquad1 =
m_base[1]->GetNumPoints();
1671 int nqtot = nquad0*nquad1;
1692 StdRegions::VarCoeffMap::const_iterator MFdir;
1697 for (
int k=0; k<coordim; k++)
1699 MFdir = varcoeffs.find(MMFCoeffs[dir*5+k]);
1700 tmp = MFdir->second;
1722 Vmath::Vmul (nq, &vec[0][0], 1, &normals[0][0], 1, &Fn[0], 1);
1723 Vmath::Vvtvp(nq, &vec[1][0], 1, &normals[1][0], 1, &Fn[0], 1, &Fn[0], 1);
1724 Vmath::Vvtvp(nq, &vec[2][0], 1, &normals[2][0], 1, &Fn[0], 1, &Fn[0], 1);
1726 return StdExpansion::Integral(Fn);
#define ASSERTL0(condition, msg)
#define ASSERTL1(condition, msg)
Assert Level 1 – Debugging which is used whether in FULLDEBUG or DEBUG compilation mode....
#define sign(a, b)
return the sign(b)*a
Describes the specification for a Basis.
virtual void v_DGDeriv(const int dir, const Array< OneD, const NekDouble > &incoeffs, Array< OneD, ExpansionSharedPtr > &EdgeExp, Array< OneD, Array< OneD, NekDouble > > &edgeCoeffs, Array< OneD, NekDouble > &out_d)
std::vector< bool > m_requireNeg
const StdRegions::NormalVector & v_GetEdgeNormal(const int edge) const
virtual Array< OneD, NekDouble > v_GetMFDiv(const int dir, const StdRegions::VarCoeffMap &varcoeffs)
void SetTraceToGeomOrientation(Array< OneD, ExpansionSharedPtr > &EdgeExp, Array< OneD, NekDouble > &inout)
void ReOrientEdgePhysMap(const int nvert, const StdRegions::Orientation orient, const int nq0, Array< OneD, int > &idmap)
virtual void v_AddEdgeNormBoundaryInt(const int edge, const ExpansionSharedPtr &EdgeExp, const Array< OneD, const NekDouble > &Fx, const Array< OneD, const NekDouble > &Fy, Array< OneD, NekDouble > &outarray)
Expansion3DSharedPtr GetLeftAdjacentElementExp() const
virtual bool v_EdgeNormalNegated(const int edge)
virtual Array< OneD, NekDouble > v_GetMFMag(const int dir, const StdRegions::VarCoeffMap &varcoeffs)
virtual void v_SetUpPhysNormals(const int edge)
virtual void v_AddRobinMassMatrix(const int edgeid, const Array< OneD, const NekDouble > &primCoeffs, DNekMatSharedPtr &inoutmat)
std::vector< Expansion1DWeakPtr > m_edgeExp
Array< OneD, unsigned int > v_GetEdgeInverseBoundaryMap(int eid)
void AddNormTraceInt(const int dir, Array< OneD, ExpansionSharedPtr > &EdgeExp, Array< OneD, Array< OneD, NekDouble > > &edgeCoeffs, Array< OneD, NekDouble > &outarray)
virtual DNekMatSharedPtr v_GenMatrix(const StdRegions::StdMatrixKey &mkey)
virtual Array< OneD, NekDouble > v_GetMF(const int dir, const int shapedim, const StdRegions::VarCoeffMap &varcoeffs)
SpatialDomains::Geometry2DSharedPtr GetGeom2D() const
void AddHDGHelmholtzEdgeTerms(const NekDouble tau, const int edge, Array< OneD, ExpansionSharedPtr > &EdgeExp, Array< OneD, NekDouble > &edgePhys, const StdRegions::VarCoeffMap &dirForcing, Array< OneD, NekDouble > &outarray)
Array< OneD, NekDouble > v_GetnEdgecdotMF(const int dir, const int edge, ExpansionSharedPtr &EdgeExp_e, const Array< OneD, const Array< OneD, NekDouble > > &normals, const StdRegions::VarCoeffMap &varcoeffs)
Expansion1DSharedPtr GetEdgeExp(int edge, bool SetUpNormal=true)
std::map< int, bool > m_negatedNormals
const StdRegions::NormalVector & v_GetSurfaceNormal(const int id) const
std::map< int, StdRegions::NormalVector > m_edgeNormals
virtual NekDouble v_VectorFlux(const Array< OneD, Array< OneD, NekDouble > > &vec)
virtual void v_NegateEdgeNormal(const int edge)
void GetPhysEdgeVarCoeffsFromElement(const int edge, ExpansionSharedPtr &EdgeExp, const Array< OneD, const NekDouble > &varcoeff, Array< OneD, NekDouble > &outarray)
void AddEdgeBoundaryInt(const int edge, ExpansionSharedPtr &EdgeExp, Array< OneD, NekDouble > &edgePhys, Array< OneD, NekDouble > &outarray, const StdRegions::VarCoeffMap &varcoeffs=StdRegions::NullVarCoeffMap)
int GetLeftAdjacentElementFace() const
virtual DNekMatSharedPtr v_BuildVertexMatrix(const DNekScalMatSharedPtr &r_bnd)
virtual void v_AddRobinEdgeContribution(const int edgeid, const Array< OneD, const NekDouble > &primCoeffs, Array< OneD, NekDouble > &coeffs)
void AddHDGHelmholtzTraceTerms(const NekDouble tau, const Array< OneD, const NekDouble > &inarray, Array< OneD, ExpansionSharedPtr > &EdgeExp, const StdRegions::VarCoeffMap &dirForcing, Array< OneD, NekDouble > &outarray)
Array< OneD, NekDouble > v_GetMF(const int dir, const int shapedim, const StdRegions::VarCoeffMap &varcoeffs)
Array< OneD, NekDouble > v_GetMFMag(const int dir, const StdRegions::VarCoeffMap &varcoeffs)
Array< OneD, NekDouble > v_GetMFDiv(const int dir, const StdRegions::VarCoeffMap &varcoeffs)
void AddEdgeNormBoundaryInt(const int edge, const std::shared_ptr< Expansion > &EdgeExp, const Array< OneD, const NekDouble > &Fx, const Array< OneD, const NekDouble > &Fy, Array< OneD, NekDouble > &outarray)
DNekScalMatSharedPtr GetLocMatrix(const LocalRegions::MatrixKey &mkey)
static std::shared_ptr< DataType > AllocateSharedPtr(const Args &...args)
Allocate a shared pointer from the memory pool.
void GetBoundaryMap(Array< OneD, unsigned int > &outarray)
int GetNcoeffs(void) const
This function returns the total number of coefficients used in the expansion.
int GetTotPoints() const
This function returns the total number of quadrature points used in the element.
int GetNedges() const
This function returns the number of edges of the expansion domain.
int NumBndryCoeffs(void) const
int NumDGBndryCoeffs(void) const
void ComputeEdgeNormal(const int edge)
int GetVertexMap(const int localVertexId, bool useCoeffPacking=false)
StdRegions::Orientation GetEorient(int edge)
void IProductWRTBase(const Array< OneD, const NekDouble > &inarray, Array< OneD, NekDouble > &outarray)
this function calculates the inner product of a given function f with the different modes of the expa...
int GetNverts() const
This function returns the number of vertices of the expansion domain.
const NormalVector & GetEdgeNormal(const int edge) const
virtual StdRegions::Orientation v_GetEorient(int edge)
LibUtilities::ShapeType DetShapeType() const
This function returns the shape of the expansion domain.
void GetEdgeToElementMap(const int eid, const Orientation edgeOrient, Array< OneD, unsigned int > &maparray, Array< OneD, int > &signarray, int P=-1)
int GetEdgeNcoeffs(const int i) const
This function returns the number of expansion coefficients belonging to the i-th edge.
void FwdTrans(const Array< OneD, const NekDouble > &inarray, Array< OneD, NekDouble > &outarray)
This function performs the Forward transformation from physical space to coefficient space.
bool IsBoundaryInteriorExpansion()
void GetEdgeInteriorMap(const int eid, const Orientation edgeOrient, Array< OneD, unsigned int > &maparray, Array< OneD, int > &signarray)
LibUtilities::NekManager< StdMatrixKey, DNekMat, StdMatrixKey::opLess > m_stdMatrixManager
int GetBasisNumModes(const int dir) const
This function returns the number of expansion modes in the dir direction.
Array< OneD, LibUtilities::BasisSharedPtr > m_base
const NormalVector & GetFaceNormal(const int face) const
const ConstFactorMap & GetConstFactors() const
const VarCoeffMap & GetVarCoeffs() const
MatrixType GetMatrixType() const
const Array< OneD, const NekDouble > & GetVarCoeff(const StdRegions::VarCoeffType &coeff) const
bool HasVarCoeff(const StdRegions::VarCoeffType &coeff) const
NekDouble GetConstFactor(const ConstFactorType &factor) const
const VarCoeffMap GetVarCoeffAsMap(const VarCoeffType &coeff) const
void InterpCoeff1D(const BasisKey &fbasis0, const Array< OneD, const NekDouble > &from, const BasisKey &tbasis0, Array< OneD, NekDouble > &to)
@ eGauss_Lagrange
Lagrange Polynomials using the Gauss points .
@ eGLL_Lagrange
Lagrange for SEM basis .
@ eModified_A
Principle Modified Functions .
std::shared_ptr< Expansion > ExpansionSharedPtr
std::shared_ptr< Expansion1D > Expansion1DSharedPtr
std::shared_ptr< Geometry2D > Geometry2DSharedPtr
std::shared_ptr< IndexMapValues > IndexMapValuesSharedPtr
std::map< StdRegions::VarCoeffType, Array< OneD, NekDouble > > VarCoeffMap
@ eInvLaplacianWithUnityMean
std::map< ConstFactorType, NekDouble > ConstFactorMap
static ConstFactorMap NullConstFactorMap
std::shared_ptr< DNekScalMat > DNekScalMatSharedPtr
NekMatrix< InnerMatrixType, BlockMatrixTag > Transpose(NekMatrix< InnerMatrixType, BlockMatrixTag > &rhs)
std::shared_ptr< DNekMat > DNekMatSharedPtr
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 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
void Neg(int n, T *x, const int incx)
Negate x = -x.
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
void Zero(int n, T *x, const int incx)
Zero vector.
void Fill(int n, const T alpha, T *x, const int incx)
Fill a vector with a constant value.
void Vcopy(int n, const T *x, const int incx, T *y, const int incy)