1.5.3.9 Math


v accumulate(i,i,v)
v accumulate(i,i,v,bfunc)

Add an initial value and the values in a range, return sum.



o adjacent_difference (i,i,o)
o adjacent_difference
(i,i, o, bfunc)

Calculate the difference between adjacent pairs of values, write the differences to an o, and return the end of that output range.



v inner_product (i1,i1last,i2,vInitial) v inner_product (i1,i1last,i2,v,bfunc1,bfunc2)

Calculate the inner product of two ranges and return that value plus vInitial.



o partial_sum(i,i,o)
o partial_sum(i,i,o, bfunc)

Fill a range with running totals and return an iterator pointing to.