# Optimization of infinite series. Dynamic programming.

I wonder how to optimize an infinite series using Classical (Lagrangian) method. For example:$$\sum_{t=1}^{\infty}\beta^{t-1}\ln c_t$$ subject to the constraint $$c_t+b_t\leq y_t+(1-r)b_{t-1}$$ where $c_t$ is a consumption of a good at date $t$, $y_t$ is endowment at date $t$, $r$ is interest interest rate and $b_t$ is savings at date $t$.

Attempt: I know how optimize it if $t$ was $t=1,2$. Then, the problem would look like $$\underset{c_1,c_2}{\max}[\ln c_1+\beta \ln c_2]$$ subject to $$c_1+b_1=y_1+(1-r)b_0\\c_2=y_2+(1+r)b_1$$

The second constraint does not have $b_2$. There is no need to save for the third period because there are only two periods. So using the Classical method first we need to form the Lagrangian:$$L(c_1,c_2,\lambda_1,\lambda_2)=\ln(c_1)+\beta \ln(c_2)+\lambda_1[y_1+(1-r)b_0-b_1-c_1]+\lambda_2[y_2+(1+r)b_1-c_2]$$

Then I take the derivatives with respect to $(c_1,c_2,\lambda_1,\lambda_2)$ and solve for $c_1$ and $c_2$. Now, how do I approach this problem when $t\rightarrow\infty$. My professor told me solving this kind of optimization problems is called dynamic programming.

-
This doesn't make any sense to me. First, you've switched from inequalities (in the problem statement) to equations (in your attempt). Second, in either case, the problem seems trivial. In the case of equations, the $c_t$ are already determined by the equations, so there's nothing to optimize; in the case of inequalities, each summand is a monotonic function of one of the $c_t$, so the optimum is attained at the boundary. There doesn't seem to be any coupling between the terms for different $t$. Are you sure you've given a complete statement of the problem? – joriki Sep 20 '12 at 9:56
I've switched from inequalities to equations because the inequality constraints are weak(less or equal). So, I just assume that the constraints are equalities, but thats not so important.This problem is trivial for me when $t\rightarrow$some small number. I understand the langrangian method. What I dont understand is how to use Langrangian method when I need to optimize infinite series aka dynamic programming. Bellman's approach works best. But how do I go with creating a langrangian for the infinite series and then solve for $c_t$? How does the constraint will look like? – Koba Sep 20 '12 at 20:19
Sorry, I don't understand. What I wrote has nothing to do with small numbers. Why isn't each $c_t$ determined by the equation it's in? What's left to optimize? – joriki Sep 20 '12 at 20:21
Yo are you saying that all c's are determined by the constraints? Man I need to find c's in terms of $b_t,y_t$ and $\beta$ which is a discount factor(economics). I need to optimize the log function which is constrained by a linear inequality. I thought I was clear in the description of the problem. I dont really understand how optimize infinite series using Lagrangian, even though this problem is trivial, so if you could show I would really appreciate it. – Koba Sep 20 '12 at 20:34
Unfortunately I don't understand how to view this problem as a simplified version of a non-trivial problem. I think you're going to have to exhibit the non-trivial problem itself. I don't see how you could learn how to use Lagrangian multipliers from a problem in which all the variables are already determined by the constraints. Also you say that you know how to do this for a finite number of variables but not for an infinite series; but the series is irrelevant here because there's no coupling between the terms; so again you'll have to exhibit an example with coupling for this to make sense. – joriki Sep 20 '12 at 21:21