GiNaC 1.8.10
Classes | Public Member Functions | Static Public Member Functions | Static Public Attributes | Protected Member Functions | Private Member Functions | Static Private Member Functions | Private Attributes | Static Private Attributes | List of all members
GiNaC::Gt Class Reference

Elliptic Multiple Polylogarithm. More...

#include <Gt.h>

Inheritance diagram for GiNaC::Gt:
GiNaC::basic GiNaC::refcounted

Classes

struct  kernel
 

Public Member Functions

 Gt (const ex &args, const ex &z, const ex &tau)
 
const exgetTau () const
 
const exgetZ () const
 
const std::vector< kernel > & getArgs () const
 
unsigned precedence () const override
 Return relative operator precedence (for parenthezing output).
 
ex eval () const override
 Perform automatic non-interruptive term rewriting rules.
 
ex evalf () const override
 Evaluate object numerically.
 
size_t nops () const override
 Number of operands/members.
 
ex subs (const exmap &m, unsigned options=0) const override
 Substitute a set of objects by arbitrary expressions.
 
unsigned calchash () const override
 Compute the hash value of an object and if it makes sense to store it in the objects status_flags, do so.
 
bool has (const ex &other, unsigned options=0) const override
 Test for occurrence of a pattern.
 
bool match (const ex &pattern, exmap &repl_lst) const override
 Check whether the expression matches a given pattern.
 
void archive (archive_node &n) const override
 Save (a.k.a.
 
void read_archive (const archive_node &n, lst &syms) override
 Read (a.k.a.
 
ex zisToFundamental (const ex *points=nullptr) const
 
ex regularise (const ex *points=nullptr) const
 
matrix findMoebiusTransform (const ex *points=nullptr) const
 
ex tauToFundamental (const ex *points=nullptr) const
 
std::vector< exdecomposeIntegrationPath (const ex *points=nullptr) const
 
ex applyIntegrationPath (const std::vector< ex > &endpoints) const
 
numeric qExpand (const ex *points=nullptr) const
 
numeric evaluate (const ex *points=nullptr) const
 
- Public Member Functions inherited from GiNaC::basic
virtual ~basic ()
 basic destructor, virtual because class ex will delete objects of derived classes via a basic*.
 
 basic (const basic &other)
 
const basicoperator= (const basic &other)
 basic assignment operator: the other object might be of a derived class.
 
virtual basicduplicate () const
 Create a clone of this object on the heap.
 
virtual ex evalm () const
 Evaluate sums, products and integer powers of matrices.
 
virtual ex eval_integ () const
 Evaluate integrals, if result is known.
 
virtual ex eval_indexed (const basic &i) const
 Perform automatic symbolic evaluations on indexed expression that contains this object as the base expression.
 
virtual void print (const print_context &c, unsigned level=0) const
 Output to stream.
 
virtual void dbgprint () const
 Little wrapper around print to be called within a debugger.
 
virtual void dbgprinttree () const
 Little wrapper around printtree to be called within a debugger.
 
virtual bool info (unsigned inf) const
 Information about the object.
 
virtual ex op (size_t i) const
 Return operand/member at position i.
 
virtual ex operator[] (const ex &index) const
 
virtual ex operator[] (size_t i) const
 
virtual exlet_op (size_t i)
 Return modifiable operand/member at position i.
 
virtual exoperator[] (const ex &index)
 
virtual exoperator[] (size_t i)
 
virtual ex map (map_function &f) const
 Construct new expression by applying the specified function to all sub-expressions (one level only, not recursively).
 
virtual void accept (GiNaC::visitor &v) const
 
virtual bool is_polynomial (const ex &var) const
 Check whether this is a polynomial in the given variables.
 
virtual int degree (const ex &s) const
 Return degree of highest power in object s.
 
virtual int ldegree (const ex &s) const
 Return degree of lowest power in object s.
 
virtual ex coeff (const ex &s, int n=1) const
 Return coefficient of degree n in object s.
 
virtual ex expand (unsigned options=0) const
 Expand expression, i.e.
 
virtual ex collect (const ex &s, bool distributed=false) const
 Sort expanded expression in terms of powers of some object(s).
 
virtual ex series (const relational &r, int order, unsigned options=0) const
 Default implementation of ex::series().
 
virtual ex normal (exmap &repl, exmap &rev_lookup, lst &modifier) const
 Default implementation of ex::normal().
 
virtual ex to_rational (exmap &repl) const
 Default implementation of ex::to_rational().
 
virtual ex to_polynomial (exmap &repl) const
 
virtual numeric integer_content () const
 
virtual ex smod (const numeric &xi) const
 Apply symmetric modular homomorphism to an expanded multivariate polynomial.
 
virtual numeric max_coefficient () const
 Implementation ex::max_coefficient().
 
virtual exvector get_free_indices () const
 Return a vector containing the free indices of an expression.
 
virtual ex add_indexed (const ex &self, const ex &other) const
 Add two indexed expressions.
 
virtual ex scalar_mul_indexed (const ex &self, const numeric &other) const
 Multiply an indexed expression with a scalar.
 
virtual bool contract_with (exvector::iterator self, exvector::iterator other, exvector &v) const
 Try to contract two indexed expressions that appear in the same product.
 
virtual unsigned return_type () const
 
virtual return_type_t return_type_tinfo () const
 
virtual ex conjugate () const
 
virtual ex real_part () const
 
virtual ex imag_part () const
 
template<class T >
void print_dispatch (const print_context &c, unsigned level) const
 Like print(), but dispatch to the specified class.
 
void print_dispatch (const registered_class_info &ri, const print_context &c, unsigned level) const
 Like print(), but dispatch to the specified class.
 
ex subs_one_level (const exmap &m, unsigned options) const
 Helper function for subs().
 
ex diff (const symbol &s, unsigned nth=1) const
 Default interface of nth derivative ex::diff(s, n).
 
int compare (const basic &other) const
 Compare objects syntactically to establish canonical ordering.
 
bool is_equal (const basic &other) const
 Test for syntactic equality.
 
const basichold () const
 Stop further evaluation.
 
unsigned gethash () const
 
const basicsetflag (unsigned f) const
 Set some status_flags.
 
const basicclearflag (unsigned f) const
 Clear some status_flags.
 
- Public Member Functions inherited from GiNaC::refcounted
 refcounted () noexcept
 
unsigned int add_reference () noexcept
 
unsigned int remove_reference () noexcept
 
unsigned int get_refcount () const noexcept
 
void set_refcount (unsigned int r) noexcept
 

Static Public Member Functions

static ex ex_zisToFundamental (const ex &expr, const ex *points=nullptr)
 
static ex ex_regularise (const ex &expr, const ex *points=nullptr)
 
static ex ex_tauToFundamental (const ex &expr, const ex *points=nullptr)
 
static ex ex_cutIntegrationPath (const ex &expr, const ex *points=nullptr)
 
static numeric ex_qExpand (const ex &expr, const ex *points=nullptr)
 
static ex ex_prepare (const ex &expr, const ex *points=nullptr)
 
static numeric ex_evaluate (const ex &expr, const ex *points=nullptr)
 
static lst lst_evaluate (const lst &list, const ex *points=nullptr)
 
static ex ex_zisToFundamental (const ex &expr, const ex &points)
 
static ex ex_regularise (const ex &expr, const ex &points)
 
static ex ex_tauToFundamental (const ex &expr, const ex &points)
 
static ex ex_cutIntegrationPath (const ex &expr, const ex &points)
 
static numeric ex_qExpand (const ex &expr, const ex &points)
 
static ex ex_prepare (const ex &expr, const ex &points)
 
static numeric ex_evaluate (const ex &expr, const ex &points)
 
static lst lst_evaluate (const lst &list, const ex &points)
 
static ex apply_function_recursive (const ex &input, const std::function< ex(const Gt &)> &func)
 
static void clear_polylog_cache ()
 

Static Public Attributes

static double cutIntegrationPath_threshold_real = 0.4
 
static double cutIntegrationPath_threshold_imag = 0.4
 
static size_t qExpand_minOrder = 4
 
static size_t qExpand_stepSize = 4
 
static bool auto_clear_polylog_cache = false
 
static bool enable_tauToFundamental = true
 

Protected Member Functions

void do_print (const print_context &c, unsigned level) const
 
void do_print_latex (const print_latex &c, unsigned level) const
 
- Protected Member Functions inherited from GiNaC::basic
 basic ()
 
virtual ex eval_ncmul (const exvector &v) const
 
virtual bool match_same_type (const basic &other) const
 Returns true if the attributes of two objects are similar enough for a match.
 
virtual ex derivative (const symbol &s) const
 Default implementation of ex::diff().
 
virtual int compare_same_type (const basic &other) const
 Returns order relation between two objects of same type.
 
virtual bool is_equal_same_type (const basic &other) const
 Returns true if two objects of same type are equal.
 
void ensure_if_modifiable () const
 Ensure the object may be modified without hurting others, throws if this is not the case.
 
void do_print (const print_context &c, unsigned level) const
 Default output to stream.
 
void do_print_tree (const print_tree &c, unsigned level) const
 Tree output to stream.
 
void do_print_python_repr (const print_python_repr &c, unsigned level) const
 Python parsable output to stream.
 

Private Member Functions

 Gt (std::vector< kernel > args, ex z, ex tau)
 
void setArgs (const ex &args)
 

Static Private Member Functions

static numeric to_numeric (const ex &expr, const ex *points=nullptr)
 
static long to_integer (const ex &expr, const bool allow_negative)
 

Private Attributes

size_t nargs
 
std::vector< kernelargs
 
ex z
 
ex tau
 

Static Private Attributes

static Gt_detail::TransformExpressionWithCache< G2_SERIALnqexand_transformer
 

Additional Inherited Members

- Protected Attributes inherited from GiNaC::basic
unsigned flags
 of type status_flags
 
unsigned hashvalue
 hash value
 

Detailed Description

Elliptic Multiple Polylogarithm.

Definition at line 44 of file Gt.h.

Constructor & Destructor Documentation

◆ Gt() [1/2]

GiNaC::Gt::Gt ( const ex args,
const ex z,
const ex tau 
)

Definition at line 108 of file Gt.cpp.

References GiNaC::ex::evalf(), nargs, setArgs(), and tau.

◆ Gt() [2/2]

GiNaC::Gt::Gt ( std::vector< kernel args,
ex  z,
ex  tau 
)
private

Definition at line 118 of file Gt.cpp.

References args, GiNaC::ex::evalf(), k, nargs, and tau.

Member Function Documentation

◆ setArgs()

void GiNaC::Gt::setArgs ( const ex args)
private

Definition at line 133 of file Gt.cpp.

References args, nargs, GiNaC::ex::nops(), and GiNaC::ex::op().

Referenced by Gt(), and read_archive().

◆ getTau()

const ex & GiNaC::Gt::getTau ( ) const
inline

Definition at line 74 of file Gt.h.

References tau.

◆ getZ()

const ex & GiNaC::Gt::getZ ( ) const
inline

Definition at line 75 of file Gt.h.

References z.

◆ getArgs()

const std::vector< kernel > & GiNaC::Gt::getArgs ( ) const
inline

Definition at line 76 of file Gt.h.

References args.

◆ precedence()

unsigned GiNaC::Gt::precedence ( ) const
inlineoverridevirtual

Return relative operator precedence (for parenthezing output).

Reimplemented from GiNaC::basic.

Definition at line 77 of file Gt.h.

◆ eval()

ex GiNaC::Gt::eval ( ) const
overridevirtual

Perform automatic non-interruptive term rewriting rules.

Reimplemented from GiNaC::basic.

Definition at line 224 of file Gt.cpp.

References args, GiNaC::status_flags::evaluated, GiNaC::factorial(), GiNaC::basic::flags, GiNaC::basic::hold(), nargs, GiNaC::pow(), tau, and z.

◆ evalf()

ex GiNaC::Gt::evalf ( ) const
overridevirtual

Evaluate object numerically.

Reimplemented from GiNaC::basic.

Definition at line 248 of file Gt.cpp.

References GiNaC::are_ex_trivially_equal(), args, GiNaC::ex::evalf(), evaluate(), k, nargs, tau, and z.

Referenced by qExpand(), and to_numeric().

◆ nops()

size_t GiNaC::Gt::nops ( ) const
inlineoverridevirtual

Number of operands/members.

Reimplemented from GiNaC::basic.

Definition at line 83 of file Gt.h.

◆ subs()

ex GiNaC::Gt::subs ( const exmap m,
unsigned  options = 0 
) const
overridevirtual

Substitute a set of objects by arbitrary expressions.

The ex returned will already be evaluated.

Reimplemented from GiNaC::basic.

Definition at line 275 of file Gt.cpp.

References args, k, m, nargs, options, GiNaC::ex::subs(), tau, and z.

◆ calchash()

unsigned GiNaC::Gt::calchash ( ) const
overridevirtual

Compute the hash value of an object and if it makes sense to store it in the objects status_flags, do so.

The method inherited from class basic computes a hash value based on the type and hash values of possible members. For this reason it is well suited for container classes but atomic classes should override this implementation because otherwise they would all end up with the same hashvalue.

Reimplemented from GiNaC::basic.

Definition at line 285 of file Gt.cpp.

References args, GiNaC::status_flags::evaluated, GiNaC::basic::flags, GiNaC::basic::gethash(), GiNaC::ex::gethash(), GiNaC::status_flags::hash_calculated, GiNaC::basic::hashvalue, k, GiNaC::make_hash_seed(), GiNaC::rotate_left(), GiNaC::basic::setflag(), tau, and z.

◆ has()

bool GiNaC::Gt::has ( const ex pattern,
unsigned  options = 0 
) const
overridevirtual

Test for occurrence of a pattern.

An object 'has' a pattern if it matches the pattern itself or one of the children 'has' it. As a consequence (according to the definition of children) given e=x+y+z, e.has(x) is true but e.has(x+y) is false.

Reimplemented from GiNaC::basic.

Definition at line 305 of file Gt.cpp.

References args, GiNaC::ex::has(), k, options, tau, and z.

◆ match()

bool GiNaC::Gt::match ( const ex pattern,
exmap repl_lst 
) const
overridevirtual

Check whether the expression matches a given pattern.

For every wildcard object in the pattern, a pair with the wildcard as a key and matching expression as a value is added to repl_lst.

Reimplemented from GiNaC::basic.

Definition at line 313 of file Gt.cpp.

◆ archive()

void GiNaC::Gt::archive ( archive_node n) const
overridevirtual

Save (a.k.a.

serialize) object into archive.

Reimplemented from GiNaC::basic.

Definition at line 166 of file Gt.cpp.

References GiNaC::container< C >::append(), n, nargs, tau, and z.

◆ read_archive()

void GiNaC::Gt::read_archive ( const archive_node n,
lst syms 
)
overridevirtual

Read (a.k.a.

deserialize) object from archive.

Reimplemented from GiNaC::basic.

Definition at line 156 of file Gt.cpp.

References args, n, setArgs(), tau, and z.

◆ zisToFundamental()

ex GiNaC::Gt::zisToFundamental ( const ex points = nullptr) const

◆ regularise()

ex GiNaC::Gt::regularise ( const ex points = nullptr) const

Definition at line 417 of file Gt.cpp.

References args, DEBUG_GT, GiNaC::factorial(), GiNaC::is_zero(), k, n, nargs, GiNaC::pow(), tau, to_numeric(), and z.

Referenced by ex_regularise().

◆ findMoebiusTransform()

matrix GiNaC::Gt::findMoebiusTransform ( const ex points = nullptr) const

◆ tauToFundamental()

ex GiNaC::Gt::tauToFundamental ( const ex points = nullptr) const

◆ decomposeIntegrationPath()

std::vector< ex > GiNaC::Gt::decomposeIntegrationPath ( const ex points = nullptr) const

◆ applyIntegrationPath()

ex GiNaC::Gt::applyIntegrationPath ( const std::vector< ex > &  endpoints) const

Definition at line 680 of file Gt.cpp.

References args, k, and tau.

Referenced by ex_cutIntegrationPath().

◆ qExpand()

numeric GiNaC::Gt::qExpand ( const ex points = nullptr) const

◆ evaluate()

numeric GiNaC::Gt::evaluate ( const ex points = nullptr) const

Definition at line 992 of file Gt.cpp.

References ex_evaluate().

Referenced by evalf().

◆ ex_zisToFundamental() [1/2]

ex GiNaC::Gt::ex_zisToFundamental ( const ex expr,
const ex points = nullptr 
)
static

Definition at line 998 of file Gt.cpp.

References apply_function_recursive(), and zisToFundamental().

Referenced by ex_prepare(), and ex_zisToFundamental().

◆ ex_regularise() [1/2]

ex GiNaC::Gt::ex_regularise ( const ex expr,
const ex points = nullptr 
)
static

Definition at line 1004 of file Gt.cpp.

References apply_function_recursive(), and regularise().

Referenced by ex_prepare(), and ex_regularise().

◆ ex_tauToFundamental() [1/2]

ex GiNaC::Gt::ex_tauToFundamental ( const ex expr,
const ex points = nullptr 
)
static

Definition at line 1010 of file Gt.cpp.

References apply_function_recursive(), and tauToFundamental().

Referenced by ex_prepare(), and ex_tauToFundamental().

◆ ex_cutIntegrationPath() [1/2]

ex GiNaC::Gt::ex_cutIntegrationPath ( const ex expr,
const ex points = nullptr 
)
static

◆ ex_qExpand() [1/2]

numeric GiNaC::Gt::ex_qExpand ( const ex expr,
const ex points = nullptr 
)
static

Definition at line 1022 of file Gt.cpp.

References apply_function_recursive(), qExpand(), and to_numeric().

Referenced by ex_evaluate(), ex_qExpand(), and lst_evaluate().

◆ ex_prepare() [1/2]

ex GiNaC::Gt::ex_prepare ( const ex expr,
const ex points = nullptr 
)
static

◆ ex_evaluate() [1/2]

numeric GiNaC::Gt::ex_evaluate ( const ex expr,
const ex points = nullptr 
)
static

◆ lst_evaluate() [1/2]

lst GiNaC::Gt::lst_evaluate ( const lst list,
const ex points = nullptr 
)
static

◆ ex_zisToFundamental() [2/2]

ex GiNaC::Gt::ex_zisToFundamental ( const ex expr,
const ex points 
)
static

Definition at line 1099 of file Gt.cpp.

References ex_zisToFundamental().

◆ ex_regularise() [2/2]

ex GiNaC::Gt::ex_regularise ( const ex expr,
const ex points 
)
static

Definition at line 1100 of file Gt.cpp.

References ex_regularise().

◆ ex_tauToFundamental() [2/2]

ex GiNaC::Gt::ex_tauToFundamental ( const ex expr,
const ex points 
)
static

Definition at line 1101 of file Gt.cpp.

References ex_tauToFundamental().

◆ ex_cutIntegrationPath() [2/2]

ex GiNaC::Gt::ex_cutIntegrationPath ( const ex expr,
const ex points 
)
static

Definition at line 1102 of file Gt.cpp.

References ex_cutIntegrationPath().

◆ ex_qExpand() [2/2]

numeric GiNaC::Gt::ex_qExpand ( const ex expr,
const ex points 
)
static

Definition at line 1103 of file Gt.cpp.

References ex_qExpand().

◆ ex_prepare() [2/2]

ex GiNaC::Gt::ex_prepare ( const ex expr,
const ex points 
)
static

Definition at line 1104 of file Gt.cpp.

References ex_prepare().

◆ ex_evaluate() [2/2]

numeric GiNaC::Gt::ex_evaluate ( const ex expr,
const ex points 
)
static

Definition at line 1105 of file Gt.cpp.

References ex_evaluate().

◆ lst_evaluate() [2/2]

lst GiNaC::Gt::lst_evaluate ( const lst list,
const ex points 
)
static

Definition at line 1106 of file Gt.cpp.

References lst_evaluate().

◆ apply_function_recursive()

ex GiNaC::Gt::apply_function_recursive ( const ex input,
const std::function< ex(const Gt &)> &  func 
)
static

◆ clear_polylog_cache()

void GiNaC::Gt::clear_polylog_cache ( )
static

Definition at line 1115 of file Gt.cpp.

References nqexand_transformer.

Referenced by ex_evaluate(), and lst_evaluate().

◆ do_print()

void GiNaC::Gt::do_print ( const print_context c,
unsigned  level 
) const
protected

Definition at line 181 of file Gt.cpp.

References args, c, nargs, tau, and z.

◆ do_print_latex()

void GiNaC::Gt::do_print_latex ( const print_latex c,
unsigned  level 
) const
protected

Definition at line 193 of file Gt.cpp.

References args, c, nargs, tau, and z.

◆ to_numeric()

numeric GiNaC::Gt::to_numeric ( const ex expr,
const ex points = nullptr 
)
staticprivate

◆ to_integer()

long GiNaC::Gt::to_integer ( const ex expr,
const bool  allow_negative 
)
staticprivate

Definition at line 1133 of file Gt.cpp.

References n.

Referenced by GiNaC::Gt::kernel::kernel().

Member Data Documentation

◆ cutIntegrationPath_threshold_real

double GiNaC::Gt::cutIntegrationPath_threshold_real = 0.4
static

Definition at line 143 of file Gt.h.

Referenced by decomposeIntegrationPath().

◆ cutIntegrationPath_threshold_imag

double GiNaC::Gt::cutIntegrationPath_threshold_imag = 0.4
static

Definition at line 144 of file Gt.h.

Referenced by decomposeIntegrationPath().

◆ qExpand_minOrder

size_t GiNaC::Gt::qExpand_minOrder = 4
static

Definition at line 148 of file Gt.h.

Referenced by qExpand().

◆ qExpand_stepSize

size_t GiNaC::Gt::qExpand_stepSize = 4
static

Definition at line 155 of file Gt.h.

Referenced by qExpand().

◆ auto_clear_polylog_cache

bool GiNaC::Gt::auto_clear_polylog_cache = false
static

Definition at line 158 of file Gt.h.

Referenced by ex_evaluate(), and lst_evaluate().

◆ enable_tauToFundamental

bool GiNaC::Gt::enable_tauToFundamental = true
static

Definition at line 162 of file Gt.h.

Referenced by ex_prepare().

◆ nargs

size_t GiNaC::Gt::nargs
private

◆ args

std::vector<kernel> GiNaC::Gt::args
private

◆ z

ex GiNaC::Gt::z
private

◆ tau

ex GiNaC::Gt::tau
private

◆ nqexand_transformer

Gt_detail::TransformExpressionWithCache< G2_SERIAL > GiNaC::Gt::nqexand_transformer
staticprivate
Initial value:
= []()
{
Digits.add_callback([](long change) -> void {
if (change>0)Gt::clear_polylog_cache();
});
[](const ex& obj) {return obj.evalf();},
[](const ex& obj) {return obj.evalf();}
};
}()
static void clear_polylog_cache()
Definition Gt.cpp:1115
void add_callback(digits_changed_callback callback)
Add a new callback function.
Definition numeric.cpp:2567
Lightweight wrapper for GiNaC's symbolic objects.
Definition ex.h:72
_numeric_digits Digits
Accuracy in decimal digits.
Definition numeric.cpp:2590

Definition at line 170 of file Gt.h.

Referenced by clear_polylog_cache(), and qExpand().


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

This page is part of the GiNaC developer's reference. It was generated automatically by doxygen. For an introduction, see the tutorial.