Branch data Line data Source code
1 : : /* *****************************************************************
2 : : MESQUITE -- The Mesh Quality Improvement Toolkit
3 : :
4 : : Copyright 2004 Sandia Corporation and Argonne National
5 : : Laboratory. Under the terms of Contract DE-AC04-94AL85000
6 : : with Sandia Corporation, the U.S. Government retains certain
7 : : rights in this software.
8 : :
9 : : This library is free software; you can redistribute it and/or
10 : : modify it under the terms of the GNU Lesser General Public
11 : : License as published by the Free Software Foundation; either
12 : : version 2.1 of the License, or (at your option) any later version.
13 : :
14 : : This library is distributed in the hope that it will be useful,
15 : : but WITHOUT ANY WARRANTY; without even the implied warranty of
16 : : MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17 : : Lesser General Public License for more details.
18 : :
19 : : You should have received a copy of the GNU Lesser General Public License
20 : : (lgpl.txt) along with this library; if not, write to the Free Software
21 : : Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
22 : :
23 : : [email protected], [email protected], [email protected],
24 : : [email protected], [email protected], [email protected]
25 : :
26 : : ***************************************************************** */
27 : : /*!
28 : : \file LaplacianSmoother.hpp
29 : : \brief
30 : :
31 : : The LaplacianSmoother Class implements the Laplacian smoothing
32 : : for a patch with one free vertex.
33 : :
34 : : \author Thomas Leurent
35 : : \date 2002-01-17
36 : : */
37 : :
38 : : #ifndef Mesquite_LaplacianSmoother_hpp
39 : : #define Mesquite_LaplacianSmoother_hpp
40 : :
41 : : #include "Mesquite.hpp"
42 : : #include "RelaxationSmoother.hpp"
43 : :
44 : : namespace MBMesquite
45 : : {
46 : :
47 : : /*! \class LaplacianSmoother
48 : : Moves free center vertex to the average of the neighboring vertices.
49 : : */
50 : : class LaplacianSmoother : public RelaxationSmoother
51 : : {
52 : : public:
53 : : /**
54 : : *\param OF ObjectiveFunction used by some termination criteria
55 : : */
56 [ + - ]: 6 : MESQUITE_EXPORT LaplacianSmoother( ObjectiveFunction* OF = NULL ) : RelaxationSmoother( OF ) {}
57 : :
58 : : MESQUITE_EXPORT virtual ~LaplacianSmoother();
59 : : MESQUITE_EXPORT virtual std::string get_name() const;
60 : :
61 : : protected:
62 : : MESQUITE_EXPORT virtual void optimize_vertex_positions( PatchData& pd, MsqError& err );
63 : :
64 : : private:
65 : : std::vector< size_t > adjVtxList;
66 : : };
67 : : } // namespace MBMesquite
68 : :
69 : : #endif
|