next | previous | forward | backward | up | top | index | toc | Macaulay2 website
Macaulay2Doc :: sum(ZZ,Function)

sum(ZZ,Function) -- sum consecutive values of a function

Synopsis

Description

sum(n,f) computes the sum f(0) + f(1) + ... + f(n-1).

i1 : sum(10, i -> i^2)

o1 = 285

See also

Ways to use this method: