Rheolef  7.1
an efficient C++ finite element environment
basis_raw_list.cc
Go to the documentation of this file.
1 // TODO: how to a user's defined basis to the list ?
22 #include "rheolef/basis_raw.h"
23 #include "basis_raw_monomial.h"
24 #include "basis_raw_bernstein.h"
25 #include "basis_raw_dubiner.h"
26 namespace rheolef {
27 using namespace std;
28 
29 template<class T>
30 basis_raw_rep<T>*
32 {
33  if (name == "") return 0;
34  if (name[0] == 'M') return new_macro(basis_raw_monomial<T>(name));
35  if (name[0] == 'B') return new_macro(basis_raw_bernstein<T>(name));
36  if (name[0] == 'D') return new_macro(basis_raw_dubiner<T>(name));
37  error_macro ("undefined raw basis `" << name << "'");
38  return 0;
39 }
40 // instanciation in library:
42 
43 } // namespace rheolef
static basis_raw_rep * make_ptr(std::string name)
This file is part of Rheolef.