MathGroup Archive 2010

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: maximum of a series

  • To: mathgroup at smc.vnet.net
  • Subject: [mg113983] Re: maximum of a series
  • From: Bill Rowe <readnews at sbcglobal.net>
  • Date: Sat, 20 Nov 2010 06:10:21 -0500 (EST)

On 11/19/10 at 5:08 AM, olfa.mraihi at yahoo.fr (olfa) wrote:

>how can I represent for example the maximum of the summations
>:sum[a[k],{k,i,j}] where j varies from i to n?

I will take your "represent" as "determine". That is I take your
question to be how to find the maximum of the partial sums that
are (in principle) formed when evaluating

Sum[a[k],{k,i,j}]

If I have this correct, I suggest

Max@Accumulate@Table[a[k], {k,i,j}]

Evaluation of Sum only returns the final sum not any of the
intermediate sums (which Mathematica may not actually compute).
I've used Table to create each of the a[k] terms and Accumulate
to compute the partial sums.



  • Prev by Date: Re: maximum of a series
  • Next by Date: Re: Q on SparseArray representation
  • Previous by thread: Re: maximum of a series
  • Next by thread: Re: maximum of a series