Nestedsums library
classical_polylog.h
Go to the documentation of this file.
1
8/*
9 * Copyright (C) 2001-2017 Stefan Weinzierl
10 *
11 * This program is free software; you can redistribute it and/or modify
12 * it under the terms of the GNU General Public License as published by
13 * the Free Software Foundation; either version 2 of the License, or
14 * (at your option) any later version.
15 *
16 * This program is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 * GNU General Public License for more details.
20 *
21 * You should have received a copy of the GNU General Public License
22 * along with this program; if not, write to the Free Software
23 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
24 */
25
26#ifndef __NESTEDSUMS_CLASSICAL_POLYLOG_H__
27#define __NESTEDSUMS_CLASSICAL_POLYLOG_H__
28
29#include "ginac/ginac.h"
30
31namespace nestedsums {
32
34
43 {
44 GINAC_DECLARE_REGISTERED_CLASS(classical_polylog, nielsen_polylog)
45
46 // ctors
47 public:
48 explicit classical_polylog(const GiNaC::ex & llc);
49
50 // functions overriding virtual functions from bases classes
51 public:
52 void archive(GiNaC::archive_node &node) const override;
53 void read_archive(const GiNaC::archive_node &node, GiNaC::lst &sym_lst) override;
54
55 void print(const GiNaC::print_context & c, unsigned level = 0) const override;
56 GiNaC::ex eval() const override;
57 };
58
59GINAC_DECLARE_UNARCHIVER(classical_polylog);
60
66inline GiNaC::ex create_classical_polylog(const GiNaC::ex & llc)
67 {
68 return (new classical_polylog(llc))->setflag(GiNaC::status_flags::dynallocated);
69 }
70
71} // namespace nestedsums
72
73namespace GiNaC {
74
75 // template specialization
76template<> inline const nestedsums::classical_polylog &ex_to<nestedsums::classical_polylog>(const ex &e)
77 {
78 return dynamic_cast<const nestedsums::classical_polylog &>(*e.bp);
79 }
80
81} // end namespace GiNaC
82
83#endif // ndef __NESTEDSUMS_CLASSICAL_POLYLOG_H__
A classical polylog is a special case of a Nielsen polylog.
Definition classical_polylog.h:43
GiNaC::ex eval() const override
Definition classical_polylog.cc:143
A Nielsen polylog is a special case of a harmonic polylog.
Definition nielsen_polylog.h:51
Definition basic_letter.cc:35
GiNaC::ex create_classical_polylog(const GiNaC::ex &llc)
Definition classical_polylog.h:66