69 inherited::read_archive(
n, sym_lst);
73 if (
n.find_unsigned(
"param", u, i))
84 inherited::archive(
n);
87 n.add_unsigned(
"param", *i);
118 c.s <<
"\\partial_{";
127 c.s <<
"^{" <<
order <<
"}";
145 c.s << std::string(level,
' ') << class_name() <<
" " 147 << std::hex <<
", hash=0x" <<
hashvalue <<
", flags=0x" <<
flags << std::dec
148 <<
", nops=" <<
nops()
154 c.s << *i << std::endl;
156 i.print(
c, level +
c.delta_indent);
157 c.s << std::string(level +
c.delta_indent,
' ') <<
"=====" << std::endl;
195 for (
size_t i=0; i<
seq.size(); i++) {
196 ex arg_diff =
seq[i].diff(s);
214 return inherited::compare_same_type(o);
225 return inherited::is_equal_same_type(o);
unsigned precedence() const override
Return relative operator precedence (for parenthezing output).
This class represents the (abstract) derivative of a symbolic function.
unsigned hashvalue
hash value
void do_print(const print_context &c, unsigned level) const
const basic & hold() const
Stop further evaluation.
virtual ex series(const relational &r, int order, unsigned options=0) const
Default implementation of ex::series().
void archive(archive_node &n) const override
Archive the object.
This class holds a relation consisting of two expressions and a logical relation between them...
ex thiscontainer(const exvector &v) const override
virtual void printseq(const print_context &c, char openbracket, char delim, char closebracket, unsigned this_precedence, unsigned upper_precedence=0) const
Print sequence of contained elements.
Archiving of GiNaC expressions.
ex eval() const override
Perform automatic non-interruptive term rewriting rules.
void read_archive(const archive_node &n, lst &syms) override
Load (deserialize) the object from an archive node.
This class is the ABC (abstract base class) of GiNaC's class hierarchy.
void do_print_csrc(const print_csrc &c, unsigned level) const
const paramset & derivatives() const
Expose this object's derivative structure.
Interface to several small and furry utilities needed within GiNaC but not of any interest to the use...
std::multiset< unsigned > paramset
void do_print_latex(const print_context &c, unsigned level) const
print_func< print_context >(&varidx::do_print). print_func< print_latex >(&varidx
size_t nops() const override
Number of operands/members.
#define GINAC_ASSERT(X)
Assertion macro for checking invariances.
static std::vector< function_options > & registered_functions()
GINAC_IMPLEMENT_REGISTERED_CLASS_OPT(add, expairseq, print_func< print_context >(&add::do_print). print_func< print_latex >(&add::do_print_latex). print_func< print_csrc >(&add::do_print_csrc). print_func< print_tree >(&add::do_print_tree). print_func< print_python_repr >(&add::do_print_python_repr)) add
ex derivative(const symbol &s) const override
Implementation of ex::diff() for derivatives.
const_iterator end() const
std::vector< ex > exvector
Interface to GiNaC's overloaded operators.
fderivative(unsigned ser, unsigned param, const exvector &args)
Construct derivative with respect to one parameter.
ex pderivative(unsigned diff_param) const
bool is_equal_same_type(const basic &other) const override
Returns true if two objects of same type are equal.
Base class for print_contexts.
unsigned precedence() const override
Return relative operator precedence (for parenthezing output).
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 print(const print_context &c, unsigned level=0) const override
Output to stream.
Interface to abstract derivatives of functions.
virtual void print(const print_context &c, unsigned level=0) const
Output to stream.
virtual int compare_same_type(const basic &other) const
Returns order relation between two objects of same type.
ex series(const relational &r, int order, unsigned options=0) const override
The series expansion of derivatives falls back to Taylor expansion.
Wrapper template for making GiNaC classes out of STL containers.
Base context for C source output.
paramset parameter_set
Set of parameter numbers with respect to which to take the derivative.
bool match_same_type(const basic &other) const override
Returns true if the attributes of two objects are similar enough for a match.
The class function is used to implement builtin functions like sin, cos...
void do_print_tree(const print_tree &c, unsigned level) const
Context for tree-like output for debugging.
unsigned flags
of type status_flags
GINAC_BIND_UNARCHIVER(add)