v0.9.0
Public Member Functions | Public Attributes | List of all members
MoFEM::HelmholtzElement::OpHoCoordTri Struct Reference

#include <users_modules/helmholtz/src/HelmholtzElementObsolete.hpp>

Inherits UserDataOperator.

Public Member Functions

 OpHoCoordTri (const string field_name, MatrixDouble &ho_coords)
 
PetscErrorCode doWork (int side, EntityType type, DataForcesAndSurcesCore::EntData &data)
 

Public Attributes

MatrixDoublehoCoordsTri
 

Detailed Description

Definition at line 335 of file HelmholtzElementObsolete.hpp.

Constructor & Destructor Documentation

◆ OpHoCoordTri()

MoFEM::HelmholtzElement::OpHoCoordTri::OpHoCoordTri ( const string  field_name,
MatrixDouble ho_coords 
)

Definition at line 338 of file HelmholtzElementObsolete.hpp.

338  :
340  hoCoordsTri(ho_coords) {}
ForcesAndSourcesCore::UserDataOperator UserDataOperator

Member Function Documentation

◆ doWork()

PetscErrorCode MoFEM::HelmholtzElement::OpHoCoordTri::doWork ( int  side,
EntityType  type,
DataForcesAndSurcesCore::EntData data 
)

Definition at line 346 of file HelmholtzElementObsolete.hpp.

347  {
348  PetscFunctionBegin;
349 
350  try {
351 
352  if(data.getFieldData().size()==0) PetscFunctionReturn(0);
353 
354  hoCoordsTri.resize(data.getN().size1(),3);
355  if(type == MBVERTEX) {
356  hoCoordsTri.clear();
357  }
358 
359  int nb_dofs = data.getFieldData().size();
360 
361  for(unsigned int gg = 0;gg<data.getN().size1();gg++) {
362  for(int dd = 0;dd<3;dd++) {
363  hoCoordsTri(gg,dd) += cblas_ddot(nb_dofs/3,&data.getN(gg)[0],1,&data.getFieldData()[dd],3); //calculate x,y,z at each GaussPts
364  }
365  }
366 
367  } catch (const std::exception& ex) {
368  ostringstream ss;
369  ss << "throw in method: " << ex.what() << endl;
370  SETERRQ(PETSC_COMM_SELF,1,ss.str().c_str());
371  }
372 
373  PetscFunctionReturn(0);
374  }
double cblas_ddot(const int N, const double *X, const int incX, const double *Y, const int incY)
Definition: cblas_ddot.c:12
const Tensor2_symmetric_Expr< const ddTensor0< T, Dim, i, j >, typename promote< T, double >::V, Dim, i, j > dd(const Tensor0< T * > &a, const Index< i, Dim > index1, const Index< j, Dim > index2, const Tensor1< int, Dim > &d_ijk, const Tensor1< double, Dim > &d_xyz)
Definition: ddTensor0.hpp:33

Member Data Documentation

◆ hoCoordsTri

MatrixDouble& MoFEM::HelmholtzElement::OpHoCoordTri::hoCoordsTri

Definition at line 337 of file HelmholtzElementObsolete.hpp.


The documentation for this struct was generated from the following file: