int Dense3d::evaluate const DblNumVec &  srcDen,
DblNumVec &  trgVal
[virtual]
 

Virtual evaluation function

Implements KnlMat3d.

Definition at line 39 of file dense3d.cpp.

References KnlMat3d::_knl, KnlMat3d::_srcNor, KnlMat3d::_srcPos, KnlMat3d::dim(), Kernel3d::kernel(), KnlMat3d::srcDOF(), and KnlMat3d::trgDOF().

00040 {
00041   //-----------------------------------
00042   iA(srcDen.m()==srcDOF()*(*_srcPos).n());  iA(trgVal.m()==trgDOF()*(*_trgPos).n());
00043   
00044   int dim  = this->dim();
00045   int srcDOF = this->srcDOF();
00046   int trgDOF = this->trgDOF();
00047   /* Number of sources */
00048   int numSrc = (*_srcPos).n();
00049   /* Number of targets */
00050   int numTrg = (*_trgPos).n();
00051   
00052   DblNumMat inter(trgDOF, numSrc*srcDOF);
00053   for(int i=0; i<numTrg; i++) {
00054          DblNumMat onePosMat(dim, 1, false, (*_trgPos).clmdata(i));
00055          DblNumVec oneValVec(trgDOF, false, trgVal.data()+trgDOF*i);
00056          iC( _knl.kernel((*_srcPos), (*_srcNor), onePosMat, inter) );
00057          iC( dgemv(1.0, inter, srcDen, 0.0, oneValVec) );
00058   }
00059   
00060   return 0;
00061 }


Generated on Sun Dec 4 19:24:40 2005 for fmm3d by  doxygen 1.4.5