37 template<
short_t d,
class T>
51 typedef memory::shared_ptr< gsGenericTensorBasis >
Ptr;
54 typedef memory::unique_ptr< gsGenericTensorBasis >
uPtr;
57 typedef gsGenericGeometry<d,T> GeometryType;
63 typedef typename Base::const_iterator const_iterator;
71 gsGenericTensorBasis(
const Basis_t & x,
const Basis_t & y) :
74 gsGenericTensorBasis( Basis_t* x, Basis_t* y, Basis_t* z ) :
Base(x,y,z) { }
76 gsGenericTensorBasis(
const Basis_t & x,
const Basis_t & y,
const Basis_t & z ) :
79 gsGenericTensorBasis( std::vector<Basis_t*> & bb ) :
Base(bb.data())
81 GISMO_ENSURE( d == bb.size(),
"Wrong d in the constructor of gsTensorBSplineBasis." );
88 GISMO_MAKE_GEOMETRY_NEW
90 std::ostream &
print(std::ostream &os)
const
92 os <<
"GenericTensorNurbsBasis<" << this->dim()<<
">, size "<< this->
size() <<
".";
93 for (
unsigned i = 0; i!=d; ++i )
94 os <<
"\n Direction "<< i <<
": "<< this->
component(i) <<
" ";
std::vector< T * > release(std::vector< unique_ptr< T > > &cont)
Takes a vector of smart pointers, releases them and returns the corresponding raw pointers...
Definition: gsMemory.h:228
index_t size() const
Returns the number of elements in the basis.
Definition: gsTensorBasis.h:108
memory::shared_ptr< gsGenericTensorBasis > Ptr
Shared pointer for gsGenericTensorBasis.
Definition: gsGenericTensorBasis.h:51
Basis_t ** iterator
Iterators on coordinate bases.
Definition: gsTensorBasis.h:52
#define GISMO_ENSURE(cond, message)
Definition: gsDebug.h:102
GISMO_MAKE_GEOMETRY_NEW std::ostream & print(std::ostream &os) const
Prints the object as a string, pure virtual function of gsTensorBasis.
Definition: gsGenericTensorBasis.h:90
Class for a quasi-tensor B-spline basis.
Definition: gsGenericTensorBasis.h:38
memory::unique_ptr< gsGenericTensorBasis > uPtr
Unique pointer for gsGenericTensorBasis.
Definition: gsGenericTensorBasis.h:54
Basis_t & component(short_t dir)
For a tensor product basis, return the 1-d basis for the i-th parameter component.
Definition: gsTensorBasis.h:596
Interface for the set of functions defined on a domain (the total number of functions in the set equa...
Definition: gsFuncData.h:23
Abstract base class for tensor product bases.
Definition: gsTensorBasis.h:33
uPtr clone()
Clone methode. Produceds a deep copy inside a uPtr.
T Scalar_t
Coefficient type.
Definition: gsGenericTensorBasis.h:46
gsTensorBasis< d, T > Base
Base type.
Definition: gsGenericTensorBasis.h:43
Provides declaration of TensorBasis class.
A basis represents a family of scalar basis functions defined over a common parameter domain...
Definition: gsBasis.h:78