From: wolf Date: Fri, 6 Aug 1999 17:25:22 +0000 (+0000) Subject: Remove some non-implemented functions, straighten rest of interface. X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ac514611cb74a75ff753e5917f3cf56784a1c9cf;p=dealii-svn.git Remove some non-implemented functions, straighten rest of interface. git-svn-id: https://svn.dealii.org/trunk@1629 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/lac/include/lac/sparse_vanka.h b/deal.II/lac/include/lac/sparse_vanka.h index 3f8265e8b5..a4b7cd9a32 100644 --- a/deal.II/lac/include/lac/sparse_vanka.h +++ b/deal.II/lac/include/lac/sparse_vanka.h @@ -110,38 +110,15 @@ class SparseVanka ~SparseVanka(); /** - * Do the preconditioning. This - * function contains a dispatch - * mechanism to use the - * multiplicative version by - * default and the additive version - * if requested by #set_additive#. - */ - template - void operator() (Vector &dst, - const Vector &src) const; - - /** - * Application of the Vanka operator. + * Do the preconditioning. * This function takes the residual * in #src# and returns the resulting * update vector in #dst#. */ template - void forward (Vector &dst, - const Vector &src) const; - - /** - * Application of the transpose - * Vanka operator. - * This function takes the residual - * in #src# and returns the resulting - * update vector in #dst#. - */ - template - void backward (Vector &dst, - const Vector &src) const; - + void operator() (Vector &dst, + const Vector &src) const; + /** * Minimize memory consumption. * Activating this option reduces @@ -187,19 +164,6 @@ class SparseVanka -/* ---------------------------- Inline functions -----------------------*/ - -template -template -inline -void -SparseVanka::operator() (Vector& dst, - const Vector& src) const -{ - dst = 0.; - forward(dst, src); -} - diff --git a/deal.II/lac/include/lac/sparse_vanka.templates.h b/deal.II/lac/include/lac/sparse_vanka.templates.h index 2e6ede0d2a..5d66fda67a 100644 --- a/deal.II/lac/include/lac/sparse_vanka.templates.h +++ b/deal.II/lac/include/lac/sparse_vanka.templates.h @@ -41,9 +41,11 @@ SparseVanka::~SparseVanka() template template void -SparseVanka::forward(Vector& dst, - const Vector& src) const +SparseVanka::operator ()(Vector &dst, + const Vector &src) const { + // first set output vector to zero + dst.clear (); // first define an alias to the sparsity // pattern of the matrix, since this // will be used quite often diff --git a/deal.II/lac/source/sparse_vanka.cc b/deal.II/lac/source/sparse_vanka.cc index b77c0765ae..7522b0de04 100644 --- a/deal.II/lac/source/sparse_vanka.cc +++ b/deal.II/lac/source/sparse_vanka.cc @@ -7,11 +7,7 @@ template class SparseVanka; template class SparseVanka; -template void SparseVanka::forward (Vector &dst, - const Vector &src) const; -template void SparseVanka::forward (Vector &dst, - const Vector &src) const; -template void SparseVanka::forward (Vector &dst, - const Vector &src) const; -template void SparseVanka::forward (Vector &dst, - const Vector &src) const; +template void SparseVanka::operator () (Vector &dst, + const Vector &src) const; +template void SparseVanka::operator () (Vector &dst, + const Vector &src) const;