39 #ifndef __H__UG__LIB_DISC__OPERATOR__LINEAR_OPERATOR__LINE_SMOOTHERS__
40 #define __H__UG__LIB_DISC__OPERATOR__LINEAR_OPERATOR__LINE_SMOOTHERS__
63 const std::pair<MathVector<dim>,
size_t> &p2);
67 const std::pair<MathVector<dim>,
size_t> &p2);
75 indY.resize(indY.size()+vPos.size());
77 std::sort(vPos.begin(), vPos.end(), ComparePosDimYDir<dim>);
79 for (
size_t i=0; i < vPos.size(); ++i){
80 indY[i] = vPos[i].second;
84 template <
typename TDomain>
96 bool bEqualNumDoFOnEachGeomObj =
true;
97 int numDoFOnGeomObj = -1;
98 for(
int si = 0; si < dd->num_subsets(); ++si){
102 if(numDoF == 0)
continue;
104 if(numDoFOnGeomObj == -1){
105 numDoFOnGeomObj = numDoF;
108 if(numDoFOnGeomObj != numDoF)
109 bEqualNumDoFOnEachGeomObj =
false;
117 for(
size_t fct = 0; fct < dd->num_fct(); ++fct){
119 LFEID lfeID = dd->local_finite_element_id(fct);
125 if(numDoF <= 0)
continue;
127 if(vHasDoFs[roid] ==
false){
128 vHasDoFs[roid] =
true;
131 bSingleSpaceUsage[roid] =
false;
135 std::vector<bool> bSortableComp(dd->num_fct(),
true);
136 for(
size_t fct = 0; fct < dd->num_fct(); ++fct){
138 LFEID lfeID = dd->local_finite_element_id(fct);
143 if(bSingleSpaceUsage[roid] ==
false)
144 bSortableComp[fct] =
false;
150 typedef typename std::pair<MathVector<TDomain::dim>,
size_t> pos_type;
153 std::vector<pos_type> vPositions;
156 if(bEqualNumDoFOnEachGeomObj)
160 ComputeDirectionYOrder<TDomain::dim>(vPositions, indY);
166 for(
size_t fct = 0; fct < dd->num_fct(); ++fct){
167 if(bSortableComp[fct] ==
false){
174 ComputeDirectionYOrder<TDomain::dim>(vPositions, indY);
186 indZ.resize(indZ.size()+vPos.size());
187 std::sort(vPos.begin(), vPos.end(), ComparePosDimZDir<dim>);
188 for (
size_t i=0; i < vPos.size(); ++i){
189 indZ[i] = vPos[i].second;
193 template <
typename TDomain>
205 bool bEqualNumDoFOnEachGeomObj =
true;
206 int numDoFOnGeomObj = -1;
207 for(
int si = 0; si < dd->num_subsets(); ++si){
211 if(numDoF == 0)
continue;
213 if(numDoFOnGeomObj == -1){
214 numDoFOnGeomObj = numDoF;
217 if(numDoFOnGeomObj != numDoF)
218 bEqualNumDoFOnEachGeomObj =
false;
226 for(
size_t fct = 0; fct < dd->num_fct(); ++fct){
228 LFEID lfeID = dd->local_finite_element_id(fct);
234 if(numDoF <= 0)
continue;
236 if(vHasDoFs[roid] ==
false){
237 vHasDoFs[roid] =
true;
240 bSingleSpaceUsage[roid] =
false;
244 std::vector<bool> bSortableComp(dd->num_fct(),
true);
245 for(
size_t fct = 0; fct < dd->num_fct(); ++fct){
247 LFEID lfeID = dd->local_finite_element_id(fct);
252 if(bSingleSpaceUsage[roid] ==
false)
253 bSortableComp[fct] =
false;
259 typedef typename std::pair<MathVector<TDomain::dim>,
size_t> pos_type;
262 std::vector<pos_type> vPositions;
265 if(bEqualNumDoFOnEachGeomObj)
270 ComputeDirectionZOrder<TDomain::dim>(vPositions, indZ);
276 for(
size_t fct = 0; fct < dd->num_fct(); ++fct){
277 if(bSortableComp[fct] ==
false){
285 ComputeDirectionZOrder<TDomain::dim>(vPositions, indZ);
291 template <
typename TDomain,
typename TBaseElem>
297 std::vector<MathVector<TDomain::dim> > vElemPos;
300 std::vector<DoFIndex> ind;
302 const typename TDomain::position_accessor_type& aaPos = domain->position_accessor();
305 for(
int si = 0; si < dd->num_subsets(); ++si)
308 iter = dd->template begin<TBaseElem>(si);
309 iterEnd = dd->template end<TBaseElem>(si);
312 for(;iter != iterEnd; ++iter)
318 for(
size_t fct = 0; fct < dd->num_fct(); ++fct)
321 if(!dd->is_def_in_subset(fct,si))
continue;
322 std::vector<Edge*> vEdge;
324 std::vector<number> edgeLength(vEdge.size());
325 std::vector<DoFIndex> ind;
327 for (
size_t i=0;i<vEdge.size();i++){
328 for (
size_t j=0;j<2;j++) vCoord[i] = aaPos[vEdge[i]->vertex(i)];
331 number minedgelength=edgeLength[0];
332 number maxedgelength=edgeLength[1];
333 for (
size_t i=1;i<vEdge.size();i++){
334 if (edgeLength[i]<minedgelength) minedgelength=edgeLength[i];
335 if (edgeLength[i]>maxedgelength) maxedgelength=edgeLength[i];
337 if (maxedgelength/minedgelength>
alpha){
339 dd->inner_dof_indices(elem, fct, ind);
343 dd->local_finite_element_id(fct));
346 UG_ASSERT(ind.size() == vElemPos.size(),
"Num MultiIndex ("<<ind.size()
347 <<
") and Num Position ("<<vElemPos.size()<<
") must match."
351 for(
size_t sh = 0; sh < ind.size(); ++sh)
353 const size_t index = ind[sh][0];
354 indarray.push_back(index);
364 template <
typename TDomain,
typename TAlgebra>
435 size_t level=3289578756;
442 if (level==3289578756){
463 void set_num_steps(
size_t forwardx,
size_t backwardx,
size_t forwardy,
size_t backwardy,
size_t forwardz,
size_t backwardz){
472 void set_num_steps(
size_t forwardx,
size_t backwardx,
size_t forwardy,
size_t backwardy){
495 newInst->set_damp(this->
damping());
514 virtual const char*
name()
const {
return "Line Gauss-Seidel";}
525 std::vector<IndexLayout::Element> vIndex;
545 dhelp.resize(d.size()); dhelp = d;
582 for(i=0; i < x.size(); i++)
586 for(
typename matrix_type::const_row_iterator it = A.begin_row(i); it != A.end_row(i) && it.index() < i; ++it)
594 for(i=0; i < x.size(); i++)
597 for(
typename matrix_type::const_row_iterator it = A.begin_row(i); it != A.end_row(i); ++it){
598 if (it.index()==i)
continue;
610 for (i=x.size()-1; (
int)i>= 0; i--)
614 for(
typename matrix_type::const_row_iterator it = A.begin_row(i); it != A.end_row(i); ++it){
615 if (it.index()==i)
continue;
625 if (
dim==1)
return true;
636 for(
typename matrix_type::const_row_iterator it = A.begin_row(i); it != A.end_row(i); ++it){
637 if (it.index()==i)
continue;
648 for (
size_t j=
m_ind_end-1;(int)j >= 0; j--){
653 for(
typename matrix_type::const_row_iterator it = A.begin_row(i); it != A.end_row(i); ++it){
654 if (it.index()==i)
continue;
663 if (
dim==2)
return true;
672 for(
typename matrix_type::const_row_iterator it = A.begin_row(i); it != A.end_row(i) ; ++it){
673 if (it.index()==i)
continue;
684 for (
size_t j=
m_ind_end-1;(int)j >= 0; j--){
689 for(
typename matrix_type::const_row_iterator it = A.begin_row(i); it != A.end_row(i) ; ++it){
690 if (it.index()==i)
continue;
704 template <
typename TDomain,
typename TAlgebra>
784 size_t level=3289578756;
791 if (level==3289578756){
812 void set_num_steps(
size_t forwardx,
size_t backwardx,
size_t forwardy,
size_t backwardy,
size_t forwardz,
size_t backwardz){
821 void set_num_steps(
size_t forwardx,
size_t backwardx,
size_t forwardy,
size_t backwardy){
844 newInst->set_damp(this->
damping());
847 newInst->set_relax(this->
relax());
864 virtual const char*
name()
const {
return "Line Vanka";}
875 std::vector<IndexLayout::Element> vIndex;
895 dhelp.resize(d.size()); dhelp = d;
933 size_t nrofelements=0;
935 for(i=0; i < x.size(); i++)
938 if (A(i,i)==0) nrofelements++;
943 for(i=0; i < x.size(); i++){
944 if (A(i,i)!=0)
continue;
946 for(
typename matrix_type::const_row_iterator it = A.begin_row(i); it != A.end_row(i) ; ++it){
947 blockind[blocksize] = it.index();
951 mat.resize(blocksize,blocksize);
953 localx.resize(blocksize);
954 for (
size_t j=0;j<blocksize;j++){
956 for (
size_t k=0;k<blocksize;k++){
957 mat.
subassign(j,k,A(blockind[j],blockind[k]));
961 for(
typename matrix_type::const_row_iterator it = A.begin_row(blockind[j]); it != A.end_row(blockind[j]) ; ++it){
962 MatMultAdd(sj, 1.0, sj, -1.0, it.value(), x[it.index()]);
968 for (
size_t j=0;j<blocksize;j++){
969 x[blockind[j]] =
m_relax*localx[j];
975 for (i=x.size()-1;(
int)i>= 0; i--)
979 for(
typename matrix_type::const_row_iterator it = A.begin_row(i); it != A.end_row(i) ; ++it){
980 blockind[blocksize] = it.index();
984 mat.resize(blocksize,blocksize);
986 localx.resize(blocksize);
987 for (
size_t j=0;j<blocksize;j++){
989 for (
size_t k=0;k<blocksize;k++){
990 mat.
subassign(j,k,A(blockind[j],blockind[k]));
994 for(
typename matrix_type::const_row_iterator it = A.begin_row(blockind[j]); it != A.end_row(blockind[j]) ; ++it){
995 MatMultAdd(sj, 1.0, sj, -1.0, it.value(), x[it.index()]);
1001 for (
size_t j=0;j<blocksize;j++){
1002 x[blockind[j]] =
m_relax*localx[j];
1009 if (
dim==1)
return true;
1015 for (
size_t sortedi=0;sortedi <
m_ind_end; sortedi++){
1018 for(
typename matrix_type::const_row_iterator it = A.begin_row(i); it != A.end_row(i) ; ++it){
1019 blockind[blocksize] = it.index();
1023 mat.resize(blocksize,blocksize);
1024 s.resize(blocksize);
1025 localx.resize(blocksize);
1026 for (
size_t j=0;j<blocksize;j++){
1028 for (
size_t k=0;k<blocksize;k++){
1029 mat.
subassign(j,k,A(blockind[j],blockind[k]));
1033 for(
typename matrix_type::const_row_iterator it = A.begin_row(blockind[j]); it != A.end_row(blockind[j]) ; ++it){
1034 MatMultAdd(sj, 1.0, sj, -1.0, it.value(), x[it.index()]);
1040 for (
size_t j=0;j<blocksize;j++){
1041 x[blockind[j]] =
m_relax*localx[j];
1048 for (
size_t sortedi=
m_ind_end-1;(int)sortedi >= 0; sortedi--){
1051 for(
typename matrix_type::const_row_iterator it = A.begin_row(i); it != A.end_row(i) ; ++it){
1052 blockind[blocksize] = it.index();
1056 mat.resize(blocksize,blocksize);
1057 s.resize(blocksize);
1058 localx.resize(blocksize);
1059 for (
size_t j=0;j<blocksize;j++){
1061 for (
size_t k=0;k<blocksize;k++){
1062 mat.
subassign(j,k,A(blockind[j],blockind[k]));
1066 for(
typename matrix_type::const_row_iterator it = A.begin_row(blockind[j]); it != A.end_row(blockind[j]) ; ++it){
1067 MatMultAdd(sj, 1.0, sj, -1.0, it.value(), x[it.index()]);
1073 for (
size_t j=0;j<blocksize;j++){
1074 x[blockind[j]] =
m_relax*localx[j];
1076 if (sortedi==0)
break;
1079 if (
dim==2)
return true;
1083 for (
size_t sortedi=0;sortedi <
m_ind_end; sortedi++){
1086 for(
typename matrix_type::const_row_iterator it = A.begin_row(i); it != A.end_row(i) ; ++it){
1087 blockind[blocksize] = it.index();
1091 mat.resize(blocksize,blocksize);
1092 s.resize(blocksize);
1093 localx.resize(blocksize);
1094 for (
size_t j=0;j<blocksize;j++){
1096 for (
size_t k=0;k<blocksize;k++){
1097 mat.
subassign(j,k,A(blockind[j],blockind[k]));
1101 for(
typename matrix_type::const_row_iterator it = A.begin_row(blockind[j]); it != A.end_row(blockind[j]) ; ++it){
1102 MatMultAdd(sj, 1.0, sj, -1.0, it.value(), x[it.index()]);
1108 for (
size_t j=0;j<blocksize;j++){
1109 x[blockind[j]] =
m_relax*localx[j];
1116 for (
size_t sortedi=
m_ind_end-1;(int)sortedi >= 0; sortedi--){
1119 for(
typename matrix_type::const_row_iterator it = A.begin_row(i); it != A.end_row(i) ; ++it){
1120 blockind[blocksize] = it.index();
1124 mat.resize(blocksize,blocksize);
1125 s.resize(blocksize);
1126 localx.resize(blocksize);
1127 for (
size_t j=0;j<blocksize;j++){
1129 for (
size_t k=0;k<blocksize;k++){
1130 mat.
subassign(j,k,A(blockind[j],blockind[k]));
1134 for(
typename matrix_type::const_row_iterator it = A.begin_row(blockind[j]); it != A.end_row(blockind[j]) ; ++it){
1135 MatMultAdd(sj, 1.0, sj, -1.0, it.value(), x[it.index()]);
1141 for (
size_t j=0;j<blocksize;j++){
1142 x[blockind[j]] =
m_relax*localx[j];
1144 if (sortedi==0)
break;
const T * get() const
Definition: smart_pointer.h:409
Definition: smart_pointer.h:108
base class for approximation spaces without type of algebra or dof distribution
Definition: approximation_space.h:279
Definition: local_dof_set.h:195
int num_dof(ReferenceObjectID roid) const
number of dofs on a reference element type
Definition: local_dof_set.h:210
virtual void set_debug(SmartPtr< IDebugWriter< algebra_type > > spDebugWriter)
set debug writer
Definition: debug_writer.h:384
void write_debug(const matrix_type &mat, const char *filename)
write debug output for a matrix (if debug writer set)
Definition: debug_writer.h:399
TAlgebra::vector_type vector_type
type of vector
Definition: debug_writer.h:360
SmartPtr< IDebugWriter< algebra_type > > debug_writer()
returns the debug writer
Definition: debug_writer.h:391
TAlgebra::matrix_type matrix_type
type of matrix
Definition: debug_writer.h:363
Definition: densematrix.h:57
void subassign(size_t r, size_t c, const TStorage2 &t)
Definition: densematrix.h:215
Definition: densevector.h:101
Definition: grid_level.h:42
@ LEVEL
Definition: grid_level.h:48
SmartPtr< IDamping< TAlgebra::vector_type, TAlgebra::vector_type > > damping()
returns the scaling
Definition: linear_iterator.h:173
describes a linear iterator that is based on a matrix operator
Definition: preconditioner.h:103
Identifier for Local Finite Elements.
Definition: local_finite_element_id.h:98
Definition: line_smoothers.h:366
virtual bool supports_parallel() const
returns if parallel solving is supported
Definition: line_smoothers.h:502
virtual const char * name() const
returns the name of iterator
Definition: line_smoothers.h:514
bool update(size_t xsize)
Definition: line_smoothers.h:427
void set_num_steps(size_t forwardx, size_t backwardx)
Definition: line_smoothers.h:481
size_t get_num_forwardz()
Definition: line_smoothers.h:509
matrix_type m_A
Definition: line_smoothers.h:566
SmartPtr< ApproximationSpace< TDomain > > m_spApproxSpace
Definition: line_smoothers.h:393
LineGaussSeidel(SmartPtr< ApproximationSpace< TDomain > > approxSpace)
Definition: line_smoothers.h:414
TAlgebra::vector_type vector_type
Definition: line_smoothers.h:375
~LineGaussSeidel()
Definition: line_smoothers.h:458
virtual SmartPtr< ILinearIterator< vector_type > > clone()
clone
Definition: line_smoothers.h:491
size_t get_num_forwardx()
Definition: line_smoothers.h:505
TAlgebra algebra_type
Definition: line_smoothers.h:372
size_t get_num_backwardz()
Definition: line_smoothers.h:510
virtual bool step(SmartPtr< MatrixOperator< matrix_type, vector_type > > pOp, vector_type &c, const vector_type &d)
computes a new correction c = B*d
Definition: line_smoothers.h:537
TDomain domain_type
Domain.
Definition: line_smoothers.h:369
bool m_init
Definition: line_smoothers.h:410
size_t m_ind_end
Definition: line_smoothers.h:398
size_t m_nr_backwardz
Definition: line_smoothers.h:405
IPreconditioner< TAlgebra > base_type
Base type.
Definition: line_smoothers.h:384
size_t m_nr_backwardy
Definition: line_smoothers.h:403
IPreconditioner< TAlgebra >::matrix_operator_type matrix_operator_type
Matrix Operator type.
Definition: line_smoothers.h:381
size_t m_nr_forwardz
Definition: line_smoothers.h:404
static const int dim
world dimension
Definition: line_smoothers.h:408
bool linegs_step(const matrix_type &A, vector_type &x, const vector_type &b)
Definition: line_smoothers.h:569
size_t get_num_forwardy()
Definition: line_smoothers.h:507
void set_num_steps(size_t forwardx, size_t backwardx, size_t forwardy, size_t backwardy)
Definition: line_smoothers.h:472
size_t get_num_backwardy()
Definition: line_smoothers.h:508
TAlgebra::matrix_type matrix_type
Definition: line_smoothers.h:378
virtual bool preprocess(SmartPtr< MatrixOperator< matrix_type, vector_type > > pOp)
initializes the preconditioner
Definition: line_smoothers.h:517
std::vector< size_t > indZ
Definition: line_smoothers.h:397
size_t m_nr_forwardx
Definition: line_smoothers.h:400
size_t get_num_backwardx()
Definition: line_smoothers.h:506
void set_num_steps(size_t forwardx, size_t backwardx, size_t forwardy, size_t backwardy, size_t forwardz, size_t backwardz)
Definition: line_smoothers.h:463
virtual bool postprocess()
cleans the operator
Definition: line_smoothers.h:534
size_t m_nr_forwardy
Definition: line_smoothers.h:402
std::vector< size_t > indY
Definition: line_smoothers.h:396
size_t m_nr_backwardx
Definition: line_smoothers.h:401
Definition: line_smoothers.h:706
size_t m_nr_forwardx
Definition: line_smoothers.h:740
bool update(size_t xsize)
Definition: line_smoothers.h:776
IPreconditioner< TAlgebra > base_type
Base type.
Definition: line_smoothers.h:724
size_t m_nr_backwardz
Definition: line_smoothers.h:745
virtual bool preprocess(SmartPtr< MatrixOperator< matrix_type, vector_type > > pOp)
initializes the preconditioner
Definition: line_smoothers.h:867
void set_num_steps(size_t forwardx, size_t backwardx, size_t forwardy, size_t backwardy)
Definition: line_smoothers.h:821
void set_num_steps(size_t forwardx, size_t backwardx)
Definition: line_smoothers.h:830
TAlgebra::matrix_type matrix_type
Definition: line_smoothers.h:718
virtual bool step(SmartPtr< MatrixOperator< matrix_type, vector_type > > pOp, vector_type &c, const vector_type &d)
computes a new correction c = B*d
Definition: line_smoothers.h:887
size_t get_num_forwardz()
Definition: line_smoothers.h:859
TAlgebra::vector_type vector_type
Definition: line_smoothers.h:715
std::vector< size_t > indY
Definition: line_smoothers.h:736
virtual SmartPtr< ILinearIterator< vector_type > > clone()
clone
Definition: line_smoothers.h:840
size_t m_ind_end
Definition: line_smoothers.h:738
virtual bool supports_parallel() const
returns if parallel solving is supported
Definition: line_smoothers.h:852
bool m_init
Definition: line_smoothers.h:750
size_t get_num_backwardy()
Definition: line_smoothers.h:858
number m_relax
Definition: line_smoothers.h:755
size_t get_num_forwardx()
Definition: line_smoothers.h:855
SmartPtr< ApproximationSpace< TDomain > > m_spApproxSpace
Definition: line_smoothers.h:733
std::vector< size_t > indZ
Definition: line_smoothers.h:737
TAlgebra algebra_type
Definition: line_smoothers.h:712
size_t get_num_backwardx()
Definition: line_smoothers.h:856
virtual const char * name() const
returns the name of iterator
Definition: line_smoothers.h:864
IPreconditioner< TAlgebra >::matrix_operator_type matrix_operator_type
Matrix Operator type.
Definition: line_smoothers.h:721
static const int dim
world dimension
Definition: line_smoothers.h:748
TDomain domain_type
Domain.
Definition: line_smoothers.h:709
size_t m_nr_forwardz
Definition: line_smoothers.h:744
size_t get_num_backwardz()
Definition: line_smoothers.h:860
virtual bool postprocess()
cleans the operator
Definition: line_smoothers.h:884
size_t m_nr_backwardx
Definition: line_smoothers.h:741
LineVanka(SmartPtr< ApproximationSpace< TDomain > > approxSpace)
Definition: line_smoothers.h:762
~LineVanka()
Definition: line_smoothers.h:807
matrix_type m_A
Definition: line_smoothers.h:916
size_t m_nr_backwardy
Definition: line_smoothers.h:743
size_t get_num_forwardy()
Definition: line_smoothers.h:857
bool linevanka_step(const matrix_type &A, vector_type &x, const vector_type &b)
Definition: line_smoothers.h:919
void set_num_steps(size_t forwardx, size_t backwardx, size_t forwardy, size_t backwardy, size_t forwardz, size_t backwardz)
Definition: line_smoothers.h:812
number relax()
Definition: line_smoothers.h:755
void set_relax(number omega)
set m_relaxation parameter
Definition: line_smoothers.h:754
size_t m_nr_forwardy
Definition: line_smoothers.h:742
static const CommonLocalDoFSet & get_dofs(const LFEID &id, bool bCreate=true)
returns the common dof set for all reference objects of a dimension
Definition: local_finite_element_provider.cpp:730
Definition: matrix_operator.h:49
Const iterator to traverse the surface of a multi-grid hierarchy.
Definition: surface_view.h:237
Definition: grid_base_object_traits.h:68
@ PST_UNIQUE
Definition: parallel_storage_type.h:70
void SetDirichletRow(TSparseMatrix &A, size_t i, size_t alpha)
Definition: sparsematrix_util.h:796
void CollectEdgesSorted(vector< Edge * > &vEdgesOut, Grid &grid, Vertex *v, bool clearContainer)
Collects all edges of a vertex, thus, none.
Definition: grid_util.cpp:205
int NumProcs()
returns the number of processes
Definition: pcl_base.cpp:91
void CollectUniqueElements(std::vector< typename TLayout::Element > &elemsOut, const TLayout &layout)
writes all elements in the interfaces into the resulting vector. avoids doubles.
Definition: pcl_layout_util.h:142
base_type::TBaseElem TBaseElem
#define UG_ASSERT(expr, msg)
Definition: assert.h:70
double number
Definition: types.h:124
vector_t::value_type VecDistance(const vector_t &v1, const vector_t &v2)
returns the distance of two vector_ts.
Definition: math_vector_functions_common_impl.hpp:375
static const size_t MAXBLOCKSIZE
Definition: vanka.h:47
ReferenceObjectID
these ids are used to identify the shape of a geometric object.
Definition: grid_base_objects.h:74
@ NUM_REFERENCE_OBJECTS
Definition: grid_base_objects.h:85
void ComputeDirectionYOrder(std::vector< std::pair< MathVector< dim >, size_t > > &vPos, std::vector< size_t > &indY)
Definition: line_smoothers.h:73
void ExtractPositions(ConstSmartPtr< TDomain > domain, ConstSmartPtr< DoFDistribution > dd, std::vector< MathVector< TDomain::dim > > &vPos)
Definition: dof_position_util.cpp:424
bool MakeConsistent(const ParallelMatrix< matrix_type > &_mat, ParallelMatrix< matrix_type > &newMat)
Definition: parallel_matrix_overlap_impl.h:438
bool ComparePosDimYDir(const std::pair< MathVector< dim >, size_t > &p1, const std::pair< MathVector< dim >, size_t > &p2)
Definition: line_smoothers.cpp:36
void OrderDirectionZForDofDist(SmartPtr< DoFDistribution > dd, ConstSmartPtr< TDomain > domain, std::vector< size_t > &indZ)
Definition: line_smoothers.h:194
bool MatMultAdd(vector_t &dest, const number &alpha1, const vector_t &v1, const number &beta1, const matrix_t &A1, const vector_t &w1)
calculates dest = alpha1*v1 + beta1 * A1 *w1;
Definition: operations_mat.h:68
bool ComparePosDimZDir(const std::pair< MathVector< dim >, size_t > &p1, const std::pair< MathVector< dim >, size_t > &p2)
Definition: line_smoothers.cpp:82
void OrderDirectionYForDofDist(SmartPtr< DoFDistribution > dd, ConstSmartPtr< TDomain > domain, std::vector< size_t > &indY)
Definition: line_smoothers.h:85
bool InnerDoFPosition(std::vector< MathVector< dim > > &vPos, const ReferenceObjectID roid, const std::vector< MathVector< dim > > &vCornerCoord, const LFEID &lfeID)
�
Definition: dof_position_util.cpp:112
bool InverseMatMult(number &dest, const double &beta, const TMat &mat, const TVec &vec)
you can implement this function with GetInverse and MatMult
void collectStretchedElementIndices(ConstSmartPtr< TDomain > domain, ConstSmartPtr< DoFDistribution > dd, std::vector< size_t > &indarray, number alpha)
Definition: line_smoothers.h:292
void ComputeDirectionZOrder(std::vector< std::pair< MathVector< dim >, size_t > > &vPos, std::vector< size_t > &indZ)
Definition: line_smoothers.h:184
T value_type
Definition: sparsematrix_interface.h:2