Main Page | Namespace List | Class Hierarchy | Class List | File List | Namespace Members | Class Members

harmonic_sum Class Reference

A harmonic sum is a special case of a Ssum. More...

#include <harmonic_sum.h>

Inheritance diagram for harmonic_sum:

Ssum harmonic_sum_to_Infinity List of all members.

Public Member Functions

 harmonic_sum (const GiNaC::ex &nc)
 harmonic_sum (const GiNaC::ex &nc, const GiNaC::ex &llc)
void archive (GiNaC::archive_node &node) const
void read_archive (const GiNaC::archive_node &node, GiNaC::lst &sym_lst)
GiNaC::return_type_t return_type_tinfo () const
void print (const GiNaC::print_context &c, unsigned level=0) const
GiNaC::ex eval (int level=0) const
GiNaC::ex convert_to_Zsum_exvector (const GiNaC::exvector &Z0, const GiNaC::exvector &Z1) const
GiNaC::ex shuffle_exvector (const GiNaC::exvector &Z0, const GiNaC::exvector &Z1, const GiNaC::exvector &Z2) const
GiNaC::ex set_index (const GiNaC::ex &i) const
GiNaC::ex shift_plus_one (void) const
GiNaC::ex shift_minus_one (void) const
GiNaC::ex adjust_upper_limit_downwards (const GiNaC::ex &i) const
GiNaC::ex adjust_upper_limit_upwards (const GiNaC::ex &i) const
GiNaC::ex adjust_upper_limit_plus_one (void) const
GiNaC::ex remove_first_letter (void) const
GiNaC::ex remove_first_letter (const GiNaC::ex &nc) const

Detailed Description

A harmonic sum is a special case of a Ssum.

Harmonic sums are recursively defined by

\[ S_{m_1,...,m_k}(n) = \sum\limits_{i=1}^n \frac{1}{i^{m_1}} S_{m_2,...,m_k}(i) \]

with

\[ S(n) = 1 \]

for $ n > 0 $.

Harmonic sums can be converted to Euler-Zagier sums (and vice versa).


Member Function Documentation

ex adjust_upper_limit_downwards const GiNaC::ex &  i  )  const [virtual]
 

Adjusts the upper summation limit $n$ down to $i$, e.g.

\[ S(n;m_1,...;1,...) = S(i;m_1,...;1,...) + \sum\limits_{j=0}^{n-i-1} \frac{1}{(i+j+1)^{m_1}} S(i+j+1;m_2,...;1,...) \]

with $n > i $.

For the empty sum we have

\[ S(n) = S(i) \]

This routine assumes $ i \ge 1 $.

Reimplemented from Ssum.

ex adjust_upper_limit_plus_one void   )  const [virtual]
 

Adjusts the upper summation limit $n$ to $n+1$, e.g.

\[ S(n;m_1,...;1,...) = S(n+1;m_1,...;1,...) \mbox{} - \frac{1}{(n+1)^{m_1}} S(n+1;m_2,...;1,...). \]

Reimplemented from Ssum.

ex adjust_upper_limit_upwards const GiNaC::ex &  i  )  const [virtual]
 

Adjusts the upper summation limit $n$ up to $i$, e.g.

\[ S(n;m_1,...;1,...) = S(i;m_1,...;1,...) \mbox{} - \sum\limits_{j=0}^{i-n-1} \frac{1}{(i-j)^{m_1}} S(i-j;m_2,...;1,...) \]

with $n < i $.

For the empty sum we have

\[ S(n) = S(i) \]

This routine assumes $ n \ge 1 $.

This routine might give rise to poles for some values of $i$ and should be used with care.

Reimplemented from Ssum.

ex convert_to_Zsum_exvector const GiNaC::exvector &  Z0,
const GiNaC::exvector &  Z1
const [virtual]
 

A more efficient version for the conversion to Euler_Zagier_sums, based on exvector (e.g. std::vector<GiNaC::ex> ). Z0 contains the result. Z1 is reversed order, so that we can use pop_back.

Reimplemented from Ssum.

ex eval int  level = 0  )  const
 

The simplifications are done in the following order:

  • If the upper summation index is an integer, perform the sum explicitly.

Reimplemented from Ssum.

Reimplemented in harmonic_sum_to_Infinity.

ex remove_first_letter const GiNaC::ex &  nc  )  const [virtual]
 

Returns a harmonic_sum with the first letter removed from the letter_list and the upper summation index set to nc.

Reimplemented from Ssum.

ex remove_first_letter void   )  const [virtual]
 

Returns a harmonic_sum with the first letter removed from the letter_list.

Reimplemented from Ssum.

ex set_index const GiNaC::ex &  i  )  const [virtual]
 

Sets the upper summation index to $i$

Reimplemented from Ssum.

ex shift_minus_one void   )  const [virtual]
 

Returns $S(n-1,m_1,...,1,...)$

Reimplemented from Ssum.

ex shift_plus_one void   )  const [virtual]
 

Returns $S(n+1,m_1,...,1,...)$

Reimplemented from Ssum.

ex shuffle_exvector const GiNaC::exvector &  Z0,
const GiNaC::exvector &  Z1,
const GiNaC::exvector &  Z2
const [virtual]
 

A more efficient version for the multiplication of harmonic_sums, based on exvector (e.g. std::vector<GiNaC::ex> ). Z0 contains the result. Z1 and Z2 are in reversed order, so that we can use pop_back.

Reimplemented from Ssum.


The documentation for this class was generated from the following files:
Generated on Wed Jun 10 22:59:11 2009 for Nestedsums library by doxygen 1.3.7