basic.h File Reference

The base class for SymEngine. More...

#include <sstream>
#include <typeinfo>
#include <map>
#include <vector>
#include <set>
#include <unordered_map>
#include <unordered_set>
#include <cassert>
#include <cmath>
#include <complex>
#include <type_traits>
#include <functional>
#include <algorithm>
#include <symengine/symengine_config.h>
#include <symengine/symengine_exception.h>
#include <symengine/dict.h>
#include "symengine/type_codes.inc"
#include "basic-methods.inc"
#include "basic-inl.h"
#include <symengine/tribool.h>
+ Include dependency graph for basic.h:

Go to the source code of this file.

Data Structures

class  SymEngine::Basic
 The lowest unit of symbolic representation. More...
 
struct  SymEngine::RCPBasicHash
 Our hash: More...
 
struct  SymEngine::RCPBasicKeyEq
 Our comparison (==) More...
 
struct  SymEngine::RCPBasicKeyLess
 Our less operator (<): More...
 

Namespaces

 SymEngine
 Main namespace for SymEngine package.
 
 std
 STL namespace.
 

Macros

#define SYMENGINE_INCLUDE_ALL
 
#define SYMENGINE_ENUM(type, Class)   type,
 
#define IMPLEMENT_TYPEID(SYMENGINE_ID)
 Inline members and functions. More...
 
#define SYMENGINE_ASSIGN_TYPEID()   this->type_code_ = type_code_id;
 

Enumerations

enum  SymEngine::TypeID { SymEngine::TypeID_Count }
 

Functions

std::string SymEngine::type_code_name (TypeID id)
 
bool SymEngine::eq (const Basic &a, const Basic &b)
 Checks equality for a and b More...
 
bool SymEngine::neq (const Basic &a, const Basic &b)
 Checks inequality for a and b More...
 
template<class T >
bool SymEngine::is_a (const Basic &b)
 Templatised version to check is_a type. More...
 
bool SymEngine::is_a_Atom (const Basic &b)
 Returns true if b is an atom. i.e. b.get_args returns an empty vector.
 
template<class T >
bool SymEngine::is_a_sub (const Basic &b)
 
bool SymEngine::is_same_type (const Basic &a, const Basic &b)
 Returns true if a and b are exactly the same type T.
 
RCP< const Basic > SymEngine::expand (const RCP< const Basic > &self, bool deep=true)
 Expands self
 
void SymEngine::as_numer_denom (const RCP< const Basic > &x, const Ptr< RCP< const Basic >> &numer, const Ptr< RCP< const Basic >> &denom)
 
void SymEngine::as_real_imag (const RCP< const Basic > &x, const Ptr< RCP< const Basic >> &real, const Ptr< RCP< const Basic >> &imag)
 
RCP< const Basic > SymEngine::rewrite_as_exp (const RCP< const Basic > &x)
 
RCP< const Basic > SymEngine::rewrite_as_sin (const RCP< const Basic > &x)
 
RCP< const Basic > SymEngine::rewrite_as_cos (const RCP< const Basic > &x)
 
void SymEngine::cse (vec_pair &replacements, vec_basic &reduced_exprs, const vec_basic &exprs)
 
std::ostreamSymEngine::operator<< (std::ostream &out, const SymEngine::Basic &p)
 << Operator More...
 
template<class T >
void SymEngine::hash_combine (hash_t &seed, const T &v)
 
const char * SymEngine::get_version ()
 

Detailed Description

The base class for SymEngine.

Author
SymEngine Developers
Date
2021-03-01

Created on: 2012-07-11

Definition in file basic.h.

Macro Definition Documentation

◆ IMPLEMENT_TYPEID

#define IMPLEMENT_TYPEID (   SYMENGINE_ID)
Value:
\
const static TypeID type_code_id = SYMENGINE_ID; \
SYMENGINE_INCLUDE_METHODS_DERIVED()

Inline members and functions.

Definition at line 340 of file basic.h.