23 #ifndef GINAC_SYMBOL_H 24 #define GINAC_SYMBOL_H 43 explicit symbol(
const std::string & initname);
44 symbol(
const std::string & initname,
const std::string & texname);
48 bool info(
unsigned inf)
const override;
49 ex eval()
const override {
return *
this; }
50 ex evalf()
const override {
return *
this; }
102 explicit realsymbol(
const std::string & initname);
103 realsymbol(
const std::string & initname,
const std::string & texname);
126 explicit possymbol(
const std::string & initname);
127 possymbol(
const std::string & initname,
const std::string & texname);
142 #endif // ndef GINAC_SYMBOL_H std::string get_name() const
ex conjugate() const override
bool is_equal_same_type(const basic &other) const override
Returns true if two objects of same type are equal.
Reference-counted pointer template.
void read_archive(const archive_node &n, lst &syms) override
Read (a.k.a.
ex to_polynomial(exmap &repl) const override
Implementation of ex::to_polynomial() for symbols.
void do_print(const print_context &c, unsigned level) const
ex normal(exmap &repl, exmap &rev_lookup, lst &modifier) const override
Implementation of ex::normal() for symbols.
const basic & setflag(unsigned f) const
Set some status_flags.
This class holds a relation consisting of two expressions and a logical relation between them...
unsigned calchash() const override
Compute the hash value of an object and if it makes sense to store it in the objects status_flags...
Archiving of GiNaC expressions.
This class is the ABC (abstract base class) of GiNaC's class hierarchy.
Context for python-parsable output.
possymbol * duplicate() const override
Create a clone of this object on the heap.
realsymbol * duplicate() const override
Create a clone of this object on the heap.
ex derivative(const symbol &s) const override
Implementation of ex::diff() for single differentiation of a symbol.
virtual unsigned get_domain() const
bool info(unsigned inf) const override
Information about the object.
void do_print_latex(const print_latex &c, unsigned level) const
void set_name(const std::string &n)
Context for latex-parsable output.
std::string name
printname of this symbol
Specialization of symbol to real domain.
unsigned serial
unique serial number for comparison
unsigned get_domain() const override
ex to_rational(exmap &repl) const override
Implementation of ex::to_rational() for symbols.
ex subs_one_level(const exmap &m, unsigned options) const
Helper function for subs().
ex subs(const exmap &m, unsigned options=0) const override
Substitute a set of objects by arbitrary expressions.
ex imag_part() const override
ex conjugate() const override
void set_TeX_name(const std::string &n)
symbol(const std::string &initname)
void do_print_python_repr(const print_python_repr &c, unsigned level) const
std::map< ex, ex, ex_is_less > exmap
std::string TeX_name
LaTeX name of this symbol.
void archive(archive_node &n) const override
Save (a.k.a.
ex evalf() const override
Evaluate object numerically.
Interface to GiNaC's light-weight expression handles.
Base class for print_contexts.
static unsigned next_serial
ex real_part() const override
ex real_part() const override
Interface to GiNaC's ABC.
This class stores all properties needed to record/retrieve the state of one object of class basic (or...
Lightweight wrapper for GiNaC's symbolic objects.
void do_print_tree(const print_tree &c, unsigned level) const
Specialization of symbol to real positive domain.
unsigned get_domain() const override
std::string get_TeX_name() const
Wrapper template for making GiNaC classes out of STL containers.
#define GINAC_DECLARE_REGISTERED_CLASS(classname, supername)
Macro for inclusion in the declaration of each registered class.
GINAC_DECLARE_UNARCHIVER(add)
ex eval() const override
Perform automatic non-interruptive term rewriting rules.
ex imag_part() const override
heap-allocated (i.e. created by new if we want to be clever and bypass the stack, ...
ex series(const relational &s, int order, unsigned options=0) const override
Implementation of ex::series() for symbols.
Context for tree-like output for debugging.
bool is_polynomial(const ex &var) const override
Check whether this is a polynomial in the given variables.