Search All of the Math Forum:

Views expressed in these public forums are not endorsed by NCTM or The Math Forum.

Notice: We are no longer accepting new posts, but the forums will continue to be readable.

Topic: Recursion Problem
Replies: 11   Last Post: Nov 22, 2011 9:44 PM

 Messages: [ Previous | Next ]
 MTBrenneman@gmail.com Posts: 983 Registered: 8/21/06
Re: Recursion Problem
Posted: Nov 18, 2011 8:50 PM

On Nov 18, 3:24 pm, "danhey...@yahoo.com" <danhey...@yahoo.com> wrote:
> On Nov 17, 8:32 pm, junoexpress <mtbrenne...@gmail.com> wrote:
>
>
>
>
>
>
>
>
>

> > On Nov 17, 5:22 pm, "danhey...@yahoo.com" <danhey...@yahoo.com> wrote:
>
> > > Since you discard all end of year inventory, B cannot exceed A_n.
>
> > In this problem you don't discard all end of year inventory. The place
> > where you get extra M&Ms when you need them is like a very big
> > reservoir that has some fixed capacity C. In this problem, we are
> > essentially assuming that C is large enough that it can cover the
> > deficit from all the years. We will let c(i) denote the number of M&Ms
> > in the reservoir in the ith year. The goal is to find the maximum
> > value of B such that c(n) = C. You only discard M&Ms when the excess,
> > i.e. A_i - B) + c(i-1) > C (which is the excess that the reservoir
> > cannot contain).

>
> > Matt
>
> This is what you wrote in your original message.
>
> If I have a deficit of M&Ms (i.e. F_i < 0), I add this to any deficit
> If I have a surplus of M&Ms in any yr, I cover any deficit I have, and
> then throw out the excess.
>
> This doesn't seem to agree with what you just wrote. By inventory, I
> mean the amount of M&Ms at the end of the year, not the vast supply
> used to cover deficits. If you want to include a reservoir of C M&Ms,
> change the recursion to
>
> X_(i+1)=min[C,X_i + F_i]
>
> with X_0=C.

The only thing that is thrown away are any M&Ms that when added to the
current reservoir of M&Ms, causes it to exceed C. So I agree with your
condition X_(i+1)=min[C,X_i + F_i], where X(i) denotes the number in
the reservoir in year i. Sorry for any confusion caused on my part.

You do have some upper bounds on B. A(n), as you note is one. The mean
of the A(n) is another.

Matt

Matt

Date Subject Author
11/17/11 MTBrenneman@gmail.com
11/17/11 MTBrenneman@gmail.com
11/17/11 MTBrenneman@gmail.com
11/17/11 William Elliot
11/17/11 MTBrenneman@gmail.com
11/22/11 Tim Little
11/17/11 MTBrenneman@gmail.com
11/17/11 Dan Heyman
11/17/11 MTBrenneman@gmail.com
11/18/11 Dan Heyman
11/18/11 MTBrenneman@gmail.com
11/22/11 Tim Little