Loading...
Searching...
No Matches
SymEngine::UNonExprPoly< Container, Poly, Cf > Class Template Referenceabstract
+ Inheritance diagram for SymEngine::UNonExprPoly< Container, Poly, Cf >:
+ Collaboration diagram for SymEngine::UNonExprPoly< Container, Poly, Cf >:

Public Types

typedef Cf coef_type
 
- Public Types inherited from SymEngine::UPolyBase< Container, Poly >
typedef Container container_type
 

Public Member Functions

 UNonExprPoly (const RCP< const Basic > &var, Container &&container)
 
virtual Cf get_coeff (unsigned int i) const =0
 
virtual Cf eval (const Cf &x) const =0
 
std::vector< Cf > multieval (const std::vector< Cf > &v) const
 
int get_degree () const
 
Cf get_lc () const
 
- Public Member Functions inherited from SymEngine::UPolyBase< Container, Poly >
 UPolyBase (const RCP< const Basic > &var, Container &&container)
 
virtual int compare (const Basic &o) const =0
 
virtual hash_t __hash__ () const =0
 
virtual int size () const =0
 
bool __eq__ (const Basic &o) const
 
const RCP< const Basic > & get_var () const
 
const Container & get_poly () const
 
vec_basic get_args () const
 Returns the list of arguments. More...
 
- Public Member Functions inherited from SymEngine::Basic
TypeID get_type_code () const
 
 Basic ()
 Constructor. More...
 
 Basic (const Basic &)=delete
 Delete the copy constructor and assignment.
 
Basicoperator= (const Basic &)=delete
 Assignment operator in continuation with above.
 
 Basic (Basic &&)=delete
 Delete the move constructor and assignment.
 
Basicoperator= (Basic &&)=delete
 Assignment operator in continuation with above.
 
virtual hash_t __hash__ () const =0
 
hash_t hash () const
 
virtual bool __eq__ (const Basic &o) const =0
 Test equality. More...
 
bool __neq__ (const Basic &o) const
 true if this is not equal to o. More...
 
int __cmp__ (const Basic &o) const
 Comparison operator. More...
 
virtual int compare (const Basic &o) const =0
 
std::string __str__ () const
 
std::string dumps () const
 Returns a string of the instance serialized. More...
 
RCP< const Basicsubs (const map_basic_basic &subs_dict) const
 Substitutes 'subs_dict' into 'self'. More...
 
RCP< const Basicxreplace (const map_basic_basic &subs_dict) const
 
virtual RCP< const Basicexpand_as_exp () const
 expands the special function in terms of exp function More...
 
virtual vec_basic get_args () const =0
 Returns the list of arguments. More...
 
virtual void accept (Visitor &v) const =0
 
virtual void accept (EvalRealDoubleVisitorFinal &v) const =0
 
RCP< const Basicdiff (const RCP< const Symbol > &x, bool cache=true) const
 
- Public Member Functions inherited from SymEngine::EnableRCPFromThis< Basic >
RCP< Basicrcp_from_this ()
 Get RCP<T> pointer to self (it will cast the pointer to T) More...
 
RCP< const Basicrcp_from_this () const
 Get RCP<const T> pointer to self (it will cast the pointer to const T) More...
 
RCP< const T2 > rcp_from_this_cast () const
 Get RCP<T2> pointer to self (it will cast the pointer to T2) More...
 
unsigned int use_count () const
 

Static Public Member Functions

static RCP< const Poly > from_dict (const RCP< const Basic > &var, std::map< unsigned, Cf > &&d)
 
- Static Public Member Functions inherited from SymEngine::UPolyBase< Container, Poly >
static RCP< const Poly > from_container (const RCP< const Basic > &var, Container &&d)
 
- Static Public Member Functions inherited from SymEngine::Basic
static RCP< const Basicloads (const std::string &)
 Creates an instance of a serialized string. More...
 

Additional Inherited Members

- Data Fields inherited from SymEngine::Basic
TypeID type_code_
 

Detailed Description

template<typename Container, typename Poly, typename Cf>
class SymEngine::UNonExprPoly< Container, Poly, Cf >

Definition at line 458 of file upolybase.h.

Member Typedef Documentation

◆ coef_type

template<typename Container , typename Poly , typename Cf >
typedef Cf SymEngine::UNonExprPoly< Container, Poly, Cf >::coef_type

Definition at line 461 of file upolybase.h.

Constructor & Destructor Documentation

◆ UNonExprPoly()

template<typename Container , typename Poly , typename Cf >
SymEngine::UNonExprPoly< Container, Poly, Cf >::UNonExprPoly ( const RCP< const Basic > &  var,
Container &&  container 
)
inline

Definition at line 463 of file upolybase.h.

464 : UPolyBase<Container, Poly>(var, std::move(container))
465 {
466 }
T move(T... args)

Member Function Documentation

◆ from_dict()

template<typename Container , typename Poly , typename Cf >
static RCP< const Poly > SymEngine::UNonExprPoly< Container, Poly, Cf >::from_dict ( const RCP< const Basic > &  var,
std::map< unsigned, Cf > &&  d 
)
inlinestatic

Definition at line 492 of file upolybase.h.

494 {
495 return Poly::from_container(
496 var, Poly::container_from_dict(var, std::move(d)));
497 }

◆ get_degree()

template<typename Container , typename Poly , typename Cf >
int SymEngine::UNonExprPoly< Container, Poly, Cf >::get_degree ( ) const
inline

Definition at line 482 of file upolybase.h.

483 {
484 return numeric_cast<int>(this->get_poly().degree());
485 }

◆ get_lc()

template<typename Container , typename Poly , typename Cf >
Cf SymEngine::UNonExprPoly< Container, Poly, Cf >::get_lc ( ) const
inline

Definition at line 487 of file upolybase.h.

488 {
489 return get_coeff(get_degree());
490 }

◆ multieval()

template<typename Container , typename Poly , typename Cf >
std::vector< Cf > SymEngine::UNonExprPoly< Container, Poly, Cf >::multieval ( const std::vector< Cf > &  v) const
inline

Definition at line 473 of file upolybase.h.

474 {
475 // this is not the optimal algorithm
476 std::vector<Cf> res(v.size());
477 for (unsigned int i = 0; i < v.size(); ++i)
478 res[i] = eval(v[i]);
479 return res;
480 }
T size(T... args)

The documentation for this class was generated from the following file: