DFT-FE 1.1.0-pre
Density Functional Theory With Finite-Elements
Loading...
Searching...
No Matches
Cell.h
Go to the documentation of this file.
1/******************************************************************************
2 * Copyright (c) 2021. *
3 * The Regents of the University of Michigan and DFT-EFE developers. *
4 * *
5 * This file is part of the DFT-EFE code. *
6 * *
7 * DFT-EFE is free software: you can redistribute it and/or modify *
8 * it under the terms of the Lesser GNU General Public License as *
9 * published by the Free Software Foundation, either version 3 of *
10 * the License, or (at your option) any later version. *
11 * *
12 * DFT-EFE is distributed in the hope that it will be useful, but *
13 * WITHOUT ANY WARRANTY; without even the implied warranty *
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. *
15 * See the Lesser GNU General Public License for more details. *
16 * *
17 * You should have received a copy of the GNU Lesser General Public *
18 * License at the top level of DFT-EFE distribution. If not, see *
19 * <https://www.gnu.org/licenses/>. *
20 ******************************************************************************/
21
22/*
23 * @author Vishal Subramanian, Bikash Kanungo
24 */
25
26
27
28#ifndef DFTFE_CELL_H
29#define DFTFE_CELL_H
30
31#include "headers.h"
32
33namespace dftfe
34{
35 namespace utils
36 {
37 /**
38 * @brief This class provides the interface that will be required while interpolating a nodal
39 * data to arbitrary set of points.
40 *
41 * @author Vishal Subramanian, Bikash Kanungo
42 */
43 template <size_type dim>
44 class Cell
45 {
46 public:
48
49 Cell(const std::vector<double> &ll, const std::vector<double> &ur);
50
51 virtual std::pair<std::vector<double>, std::vector<double>>
53
54 virtual bool
55 isPointInside(const std::vector<double> &point, const double tol) const;
56
57 virtual void
58 getVertices(std::vector<std::vector<double>> &points) const;
59
60 virtual void
61 getVertex(size_type i, std::vector<double> &point) const;
62
63 virtual std::vector<double>
64 getParametricPoint(const std::vector<double> &realPoint) const;
65
66 virtual void
67 getShapeFuncValues(unsigned int numPointsInCell,
68 const std::vector<double> &coordinatesOfPointsInCell,
69 std::vector<dataTypes::number> &shapeFuncValues,
70 unsigned int cellShapeFuncStartIndex,
71 unsigned int numDofsPerElement) const = 0;
72
73 private:
74 std::vector<double> d_lowerLeft, d_upperRight;
75 }; // end of class CellBase
76 } // end of namespace utils
77} // end of namespace dftfe
78
79#include "../utils/Cell.t.cc"
80
81#endif // DFTFE_CELL_H
virtual std::pair< std::vector< double >, std::vector< double > > getBoundingBox() const
virtual std::vector< double > getParametricPoint(const std::vector< double > &realPoint) const
virtual void getShapeFuncValues(unsigned int numPointsInCell, const std::vector< double > &coordinatesOfPointsInCell, std::vector< dataTypes::number > &shapeFuncValues, unsigned int cellShapeFuncStartIndex, unsigned int numDofsPerElement) const =0
virtual bool isPointInside(const std::vector< double > &point, const double tol) const
virtual void getVertex(size_type i, std::vector< double > &point) const
Cell(const std::vector< double > &ll, const std::vector< double > &ur)
std::vector< double > d_upperRight
Definition Cell.h:74
virtual void getVertices(std::vector< std::vector< double > > &points) const
std::vector< double > d_lowerLeft
Definition Cell.h:74
Definition Cell.h:36
Definition pseudoPotentialToDftfeConverter.cc:34
unsigned int size_type
Definition TypeConfig.h:6