Plugins
Loading...
Searching...
No Matches
ls_curvature2d.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2015: G-CSC, Goethe University Frankfurt
3 * Authors: Christian Wehner, Dmitriy Logashenko
4 *
5 * This file is part of UG4.
6 *
7 * UG4 is free software: you can redistribute it and/or modify it under the
8 * terms of the GNU Lesser General Public License version 3 (as published by the
9 * Free Software Foundation) with the following additional attribution
10 * requirements (according to LGPL/GPL v3 §7):
11 *
12 * (1) The following notice must be displayed in the Appropriate Legal Notices
13 * of covered and combined works: "Based on UG4 (www.ug4.org/license)".
14 *
15 * (2) The following notice must be displayed at a prominent place in the
16 * terminal output of covered works: "Based on UG4 (www.ug4.org/license)".
17 *
18 * (3) The following bibliography is recommended for citation and must be
19 * preserved in all covered files:
20 * "Reiter, S., Vogel, A., Heppner, I., Rupp, M., and Wittum, G. A massively
21 * parallel geometric multigrid solver on hierarchically distributed grids.
22 * Computing and visualization in science 16, 4 (2013), 151-164"
23 * "Vogel, A., Reiter, S., Rupp, M., Nägel, A., and Wittum, G. UG4 -- a novel
24 * flexible software system for simulating pde based models on high performance
25 * computers. Computing and visualization in science 16, 4 (2013), 165-179"
26 *
27 * This program is distributed in the hope that it will be useful,
28 * but WITHOUT ANY WARRANTY; without even the implied warranty of
29 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
30 * GNU Lesser General Public License for more details.
31 */
32
33#ifndef __H__UG__PLUGINS__LEVEL_SET__LS_CURVATURE2D_H__
34#define __H__UG__PLUGINS__LEVEL_SET__LS_CURVATURE2D_H__
35
36#include <vector>
37
38#include "common/common.h"
39
40namespace ug{
41namespace LevelSet{
42
46template<typename TGridFunction>
48{
50 typedef typename TGridFunction::domain_type domain_type;
51
53 typedef typename TGridFunction::algebra_type algebra_type;
54
56 static const int dim = domain_type::dim;
57
58public:
59
64
67 {
69 m_exactcurv = kappa;
70 };
71
72 bool computeElementCurvature2d(number& kappa,size_t elementnoc,const std::vector<MathVector<dim> >& co,std::vector<number> phi,size_t order);
73 bool computeElementCurvature2d2(number& kappa,size_t elementnoc,const std::vector<MathVector<dim> >& co,std::vector<number> phi,size_t order,number nodefactor);
74 bool computeElementCurvatureOnGrid2d(TGridFunction& u,size_t order,number leastSquaresFactor);
75 bool computeElementCurvatureFromSides(TGridFunction& u,size_t order,number leastSquaresFactor);
76
77private:
78
81};
82
83} // end namespace LevelSet
84} // end namespace ug
85
86// include implementation
87#include "ls_curvature2d_impl.h"
88
89#endif /* __H__UG__PLUGINS__LEVEL_SET__LS_CURVATURE2D_H__ */
90
91/* End of File */
Definition ls_curvature2d.h:48
TGridFunction::domain_type domain_type
domain type
Definition ls_curvature2d.h:50
bool computeElementCurvatureFromSides(TGridFunction &u, size_t order, number leastSquaresFactor)
Definition ls_curvature2d_impl.h:706
void exact_curvature(number kappa)
sets the exact curvature for comparisons
Definition ls_curvature2d.h:66
bool computeElementCurvature2d2(number &kappa, size_t elementnoc, const std::vector< MathVector< dim > > &co, std::vector< number > phi, size_t order, number nodefactor)
Definition ls_curvature2d_impl.h:456
TGridFunction::algebra_type algebra_type
algebra type
Definition ls_curvature2d.h:53
bool m_exactcurvatureknown
Definition ls_curvature2d.h:79
LevelSetCurvature()
class constructor
Definition ls_curvature2d.h:61
bool computeElementCurvature2d(number &kappa, size_t elementnoc, const std::vector< MathVector< dim > > &co, std::vector< number > phi, size_t order)
Definition ls_curvature2d_impl.h:305
static const int dim
world dimension
Definition ls_curvature2d.h:56
bool computeElementCurvatureOnGrid2d(TGridFunction &u, size_t order, number leastSquaresFactor)
Definition ls_curvature2d_impl.h:585
number m_exactcurv
Definition ls_curvature2d.h:80
double number