DOLFIN
DOLFIN C++ interface
Toggle main menu visibility
Loading...
Searching...
No Matches
dolfin
mesh
Face.h
1
// Copyright (C) 2006-2010 Anders Logg
2
//
3
// This file is part of DOLFIN.
4
//
5
// DOLFIN is free software: you can redistribute it and/or modify
6
// it under the terms of the GNU Lesser General Public License as published by
7
// the Free Software Foundation, either version 3 of the License, or
8
// (at your option) any later version.
9
//
10
// DOLFIN is distributed in the hope that it will be useful,
11
// but WITHOUT ANY WARRANTY; without even the implied warranty of
12
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
// GNU Lesser General Public License for more details.
14
//
15
// You should have received a copy of the GNU Lesser General Public License
16
// along with DOLFIN. If not, see <http://www.gnu.org/licenses/>.
17
//
18
// Modified by Garth N. Wells, 2011
19
//
20
// First added: 2006-06-02
21
// Last changed: 2011-02-22
22
23
#ifndef __FACE_H
24
#define __FACE_H
25
26
#include <memory>
27
28
#include "MeshEntity.h"
29
#include "MeshEntityIteratorBase.h"
30
#include "MeshFunction.h"
31
32
namespace
dolfin
33
{
34
35
class
Mesh
;
36
class
Point
;
37
39
40
class
Face
:
public
MeshEntity
41
{
42
public
:
43
45
Face
(
const
Mesh
&
mesh
, std::size_t
index
) :
MeshEntity
(
mesh
, 2,
index
) {}
46
48
~Face
() {}
49
51
double
area
()
const
;
52
54
double
normal
(std::size_t i)
const
;
55
57
Point
normal
()
const
;
58
59
};
60
62
typedef
MeshEntityIteratorBase<Face>
FaceIterator
;
63
64
}
65
66
#endif
dolfin::Face::normal
Point normal() const
Compute normal to the face.
Definition
Face.cpp:97
dolfin::Face::Face
Face(const Mesh &mesh, std::size_t index)
Constructor.
Definition
Face.h:45
dolfin::Face::area
double area() const
Calculate the area of the face (triangle).
Definition
Face.cpp:30
dolfin::Face::~Face
~Face()
Destructor.
Definition
Face.h:48
dolfin::MeshEntityIteratorBase
Base class for MeshEntityIterators.
Definition
MeshEntityIteratorBase.h:37
dolfin::MeshEntity::mesh
const Mesh & mesh() const
Definition
MeshEntity.h:99
dolfin::MeshEntity::MeshEntity
MeshEntity()
Default Constructor.
Definition
MeshEntity.h:47
dolfin::MeshEntity::index
std::size_t index() const
Definition
MeshEntity.h:113
dolfin::Mesh
Definition
Mesh.h:83
dolfin::Point
Definition
Point.h:41
dolfin
Definition
adapt.h:30
dolfin::FaceIterator
MeshEntityIteratorBase< Face > FaceIterator
A FaceIterator is a MeshEntityIterator of topological dimension 2.
Definition
Face.h:62
Generated by
1.17.0