stator
A math, geometry, and utility library
point.hpp
Go to the documentation of this file.
1 /*
2  Copyright (C) 2017 Marcus N Campbell Bannerman <[email protected]>
3 
4  This file is part of stator.
5 
6  stator is free software: you can redistribute it and/or modify
7  it under the terms of the GNU General Public License as published by
8  the Free Software Foundation, either version 3 of the License, or
9  (at your option) any later version.
10 
11  stator is distributed in the hope that it will be useful,
12  but WITHOUT ANY WARRANTY; without even the implied warranty of
13  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  GNU General Public License for more details.
15 
16  You should have received a copy of the GNU General Public License
17  along with stator. If not, see <http://www.gnu.org/licenses/>.
18 */
19 
20 #pragma once
21 
22 // stator
23 #include "stator/config.hpp"
24 #include "stator/constants.hpp"
25 
26 namespace stator {
27  namespace geometry {
34  template<typename Scalar, size_t D>
35  class Point {
36  public:
44  Point() {}
45 
48 
50  const Vector<Scalar, D>& center() const { return center_; }
51 
52  protected:
55  };
56 
57  template<typename Scalar, size_t D>
58  constexpr Scalar volume(const Point<Scalar, D>& ball) { return Scalar(0); }
59 
60  template<typename Scalar, size_t D>
61  Scalar area(const Point<Scalar, D>& sphere) { return Scalar(0); }
62 
63  } // namespace geometry
64 } // namespace stator
65 
auto area(const Obj &)
Compute a Hausdorf measure of the boundary/boundaries of an object.
auto volume(const Obj &)
Compute a Hausdorf measure of the interior of an object.
Fundamental typedef&#39;s and macros for stator.
Point()
Default constructor.
Definition: point.hpp:44
Point(const Vector< Scalar, D > &center=Vector< Scalar, D >::Zero().eval())
RAII constructor.
Definition: point.hpp:47
The stator library namespace.
Definition: frontpage.dox:243
const Vector< Scalar, D > & center() const
Get function for the point&#39;s location.
Definition: point.hpp:50
Vector< Scalar, D > center_
Center of the ball.
Definition: point.hpp:54
Matrix< Scalar, D, 1 > Vector
A convenience typedef for a non-aligned Eigen Vector.
Definition: config.hpp:58