Part of the multidimensional expansion bases for the shape functions of Karniadakis and Sherwin. More...
#include <karniadakis.hh>


Public Member Functions | |
| Karniadakis (const int P, const Real *xP, const int NxP, const int Q=0, const int R=0, const bool cache=true) | |
| Constructor. | |
| Karniadakis (const Karniadakis< type, mode > &arg) | |
| Copy constructor. | |
| uint | n () const |
| Returns the number of shape functions. | |
| uint | nP () const |
| Returns the number of abscissas (in which the shape functions are evaluated) | |
| const Real * | values () const |
| Returns the values of the shape functions. | |
| ~Karniadakis () | |
Static Public Member Functions | |
| static void | clearCache () |
Protected Member Functions | |
| virtual std::ostream & | info (std::ostream &os) const |
| Returns information in an output stream. | |
Protected Attributes | |
| Real * | values_ |
| Values of the shape functions. | |
Private Attributes | |
| bool | cache_ |
| Cache the results of the computations in principal_H if set to true. | |
| Orders< type > | orders_ |
| Combines polynomial degrees and number of quadrature points. | |
Static Private Attributes | |
| static __gnu_cxx::hash_map < Orders< type >, Real *, __gnu_cxx::hash< Orders < type > >, __gnu_cxx::OrdersEqual < type > > | principal_H |
| Hash of the already computed values of the principal function of this type. | |
Part of the multidimensional expansion bases for the shape functions of Karniadakis and Sherwin.
Computes one of principal functions
,
or
for given polynomial degrees and a set of points.
The constructor computes the values if necessary: they are stored in static hashes and can be reused if requested a second time. There is a method to get a pointer into the array of the computed values, use this at initialization time of the element to get a pointer to the values. The index of the points in which the shape functions are evaluated runs fastest, k is second and i is slowest.
| type | Template parameter: type of the principal function. Can take the values
|
| mode | Template parameter: normal, derivatives, divided form. Can take the values
|
Definition at line 176 of file karniadakis.hh.
| concepts::Karniadakis< type, mode >::Karniadakis | ( | const int | P, |
| const Real * | xP, | ||
| const int | NxP, | ||
| const int | Q = 0, |
||
| const int | R = 0, |
||
| const bool | cache = true |
||
| ) |
Constructor.
Computes the values of the principal function of the given order and in the given points.
(P+1)*(Q+1)*(R+1) is the number of shape functions which have to be computed in NxP points.
| P | Order of the principal function in |
| xP | Points |
| NxP | Number of points |
| Q | Order of the principal function in |
| R | Order of the principal function in |
| cache | Controls if the computed values should be taken from and stored in the cache |
| concepts::Karniadakis< type, mode >::Karniadakis | ( | const Karniadakis< type, mode > & | arg | ) |
Copy constructor.
| concepts::Karniadakis< type, mode >::~Karniadakis | ( | ) |
| static void concepts::Karniadakis< type, mode >::clearCache | ( | ) | [inline, static] |
Definition at line 197 of file karniadakis.hh.
| virtual std::ostream& concepts::Karniadakis< type, mode >::info | ( | std::ostream & | os | ) | const [protected, virtual] |
Returns information in an output stream.
Implements concepts::ShapeFunction1D< Real >.
| uint concepts::ShapeFunction1D< Real >::n | ( | ) | const [inline, inherited] |
Returns the number of shape functions.
Definition at line 33 of file shapefunction.hh.
| uint concepts::ShapeFunction1D< Real >::nP | ( | ) | const [inline, inherited] |
Returns the number of abscissas (in which the shape functions are evaluated)
Definition at line 36 of file shapefunction.hh.
| const Real * concepts::ShapeFunction1D< Real >::values | ( | ) | const [inline, inherited] |
Returns the values of the shape functions.
Definition at line 38 of file shapefunction.hh.
bool concepts::Karniadakis< type, mode >::cache_ [private] |
Cache the results of the computations in principal_H if set to true.
Definition at line 215 of file karniadakis.hh.
Orders<type> concepts::Karniadakis< type, mode >::orders_ [private] |
Combines polynomial degrees and number of quadrature points.
Definition at line 204 of file karniadakis.hh.
__gnu_cxx::hash_map<Orders<type>, Real*, __gnu_cxx::hash<Orders<type> >, __gnu_cxx::OrdersEqual<type> > concepts::Karniadakis< type, mode >::principal_H [static, private] |
Hash of the already computed values of the principal function of this type.
The hash is static, ie. the data is available to all instances of this class.
Definition at line 212 of file karniadakis.hh.
Real * concepts::ShapeFunction1D< Real >::values_ [protected, inherited] |
Values of the shape functions.
Definition at line 43 of file shapefunction.hh.