#include <P0.h>
Public Member Functions | |
TensorP0 () | |
TensorP0 (Polygon &p, unsigned int order=0, unsigned int size=0) | |
~TensorP0 () | |
virtual void | set_size (unsigned int size_) |
virtual void | compute_basis_functions () |
def | __init__ |
def | set_size |
def | compute_basis_functions |
Public Attributes | |
this | |
Protected Attributes | |
unsigned int | size |
Static Private Attributes | |
dictionary | __swig_setmethods__ = {} |
tuple | __setattr__ = lambdaself,name,value:_swig_setattr(self, TensorP0, name, value) |
dictionary | __swig_getmethods__ = {} |
tuple | __getattr__ = lambdaself,name:_swig_getattr(self, TensorP0, name) |
__repr__ = _swig_repr | |
__swig_destroy__ = _SyFi.delete_TensorP0 | |
__del__ = lambdaself:None; |
Proxy of C++ SyFi::TensorP0 class
Definition at line 35 of file P0.h.
SyFi::TensorP0::TensorP0 | ( | ) |
Definition at line 136 of file P0.cpp.
References SyFi::StandardFE::description.
00136 : StandardFE() 00137 { 00138 description = "TensorP0"; 00139 }
SyFi::TensorP0::TensorP0 | ( | Polygon & | p, | |
unsigned int | order = 0 , |
|||
unsigned int | size = 0 | |||
) |
Definition at line 141 of file P0.cpp.
References compute_basis_functions(), SyFi::nsd, and size.
00141 : StandardFE(p, order) 00142 { 00143 size = size_ < 0 ? nsd: size_; 00144 compute_basis_functions(); 00145 }
def SyFi::TensorP0::__init__ | ( | self, | ||
args | ||||
) |
__init__(self) -> TensorP0 __init__(self, Polygon p, unsigned int order = 0, unsigned int size = 0) -> TensorP0 __init__(self, Polygon p, unsigned int order = 0) -> TensorP0 __init__(self, Polygon p) -> TensorP0
Reimplemented from SyFi::StandardFE.
Definition at line 2393 of file SyFi.py.
02393 : 02394 """ 02395 __init__(self) -> TensorP0 02396 __init__(self, Polygon p, unsigned int order = 0, unsigned int size = 0) -> TensorP0 02397 __init__(self, Polygon p, unsigned int order = 0) -> TensorP0 02398 __init__(self, Polygon p) -> TensorP0 02399 """ 02400 this = _SyFi.new_TensorP0(*args) 02401 try: self.this.append(this) 02402 except: self.this = this
def SyFi::TensorP0::compute_basis_functions | ( | self | ) |
compute_basis_functions(self)
Reimplemented from SyFi::StandardFE.
Definition at line 2409 of file SyFi.py.
02409 : 02410 """compute_basis_functions(self)""" 02411 return _SyFi.TensorP0_compute_basis_functions(self) 02412 TensorP0_swigregister = _SyFi.TensorP0_swigregister
void SyFi::TensorP0::compute_basis_functions | ( | ) | [virtual] |
Reimplemented from SyFi::StandardFE.
Definition at line 147 of file P0.cpp.
References SyFi::StandardFE::description, SyFi::StandardFE::dof(), SyFi::StandardFE::dofs, demos::crouzeixraviart::fe, SyFi::StandardFE::N(), SyFi::StandardFE::nbf(), SyFi::StandardFE::Ns, SyFi::StandardFE::p, run::s, size, and SyFi::StandardFE::str().
Referenced by TensorP0().
00148 { 00149 00150 // remove previously computed basis functions and dofs 00151 Ns.clear(); 00152 dofs.clear(); 00153 00154 if ( p == NULL ) 00155 { 00156 throw(std::logic_error("You need to set a polygon before the basisfunctions can be computed")); 00157 } 00158 00159 if ( size == 0) 00160 { 00161 throw(std::logic_error("You need to set the size of the vector before the basisfunctions can be computed")); 00162 } 00163 00164 P0 fe(*p); 00165 GiNaC::lst zero_list; 00166 for (unsigned int s=1; s<= size*size ; s++) 00167 { 00168 zero_list.append(0); 00169 } 00170 00171 for (unsigned int i=0; i< fe.nbf() ; i++) 00172 { 00173 for (unsigned int r=0; r< size ; r++) 00174 { 00175 for (unsigned int s=0; s< size ; s++) 00176 { 00177 GiNaC::lst Nis = zero_list; 00178 Nis.let_op((size)*r + s) = fe.N(i); 00179 GiNaC::ex Nmat = GiNaC::matrix(size,size,Nis); 00180 Ns.insert(Ns.end(), Nmat); 00181 00182 GiNaC::lst dof = GiNaC::lst(fe.dof(i), r, s) ; 00183 dofs.insert(dofs.end(), dof); 00184 } 00185 } 00186 } 00187 description = "Tensor" + fe.str(); 00188 }
def SyFi::TensorP0::set_size | ( | self, | ||
args | ||||
) |
set_size(self, unsigned int size_)
Definition at line 2405 of file SyFi.py.
02405 : 02406 """set_size(self, unsigned int size_)""" 02407 return _SyFi.TensorP0_set_size(self, *args) 02408 def compute_basis_functions(self):
void SyFi::TensorP0::set_size | ( | unsigned int | size_ | ) | [virtual] |
SyFi::TensorP0::__del__ = lambdaself:None; [static, private] |
tuple SyFi::TensorP0::__getattr__ = lambdaself,name:_swig_getattr(self, TensorP0, name) [static, private] |
SyFi::TensorP0::__repr__ = _swig_repr [static, private] |
tuple SyFi::TensorP0::__setattr__ = lambdaself,name,value:_swig_setattr(self, TensorP0, name, value) [static, private] |
SyFi::TensorP0::__swig_destroy__ = _SyFi.delete_TensorP0 [static, private] |
dictionary SyFi::TensorP0::__swig_getmethods__ = {} [static, private] |
dictionary SyFi::TensorP0::__swig_setmethods__ = {} [static, private] |
unsigned int SyFi::TensorP0::size [protected] |
Definition at line 38 of file P0.h.
Referenced by compute_basis_functions(), set_size(), and TensorP0().